# Public Cloud › Databases API

> Part of the OVHcloud developer hub. Index of every page and section: https://developers.eu.ovhcloud.com/llms.txt
> The Public Cloud product's sections: https://developers.eu.ovhcloud.com/reference/public-cloud/llms.txt
> Everything in one file: https://developers.eu.ovhcloud.com/llms-full.txt

> 2 operations of the OVHcloud API. Calls carry `authorization: Bearer $OVH_TOKEN`; the EU host is shown, Canada and the United States answer on api.ca.ovhcloud.com and api.us.ovhcloud.com.

Page: https://developers.eu.ovhcloud.com/reference/public-cloud/databases/

OpenAPI v1: https://api.eu.ovhcloud.com/1.0/__schemas/developer-hub-navigation/public-cloud/databases.json?format=openapi3
OpenAPI v2: https://api.eu.ovhcloud.com/v2/__schemas/developer-hub-navigation/public-cloud/databases.json?format=openapi3

## Operations

- `GET /publicCloud/project/{projectId}/managedDatabase/service` — List services
- `GET /publicCloud/project/{projectId}/managedDatabase/service/{serviceId}` — Get a service

## List services

`GET /v2/publicCloud/project/{projectId}/managedDatabase/service`

Link: https://developers.eu.ovhcloud.com/reference/public-cloud/databases/#get-publiccloud-project-projectid-manageddatabase-service

**Status:** Beta version  
**IAM actions:** `publicCloudProject:apiovh:database/service/get`

Returns the database services of the project, across all engines.

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `X-Pagination-Cursor` | header | string |  | Pagination cursor |
| `X-Pagination-Size` | header | integer |  | Pagination size |
| `category` | query | publicCloud.database.CategoryEnum |  | Filter services by engine category — one of `ANALYTICS`, `DATABASE` |
| `projectId` | path | string | yes | Project ID |

### Responses

| Status | Type | Description |
| --- | --- | --- |
| 200 | publicCloud.database.Service[] | successful operation |

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `checksum` | string | read-only | Hash of the resource used for concurrency control |
| `createdAt` | string (date-time) | read-only | Date at which the service was created |
| `currentState` | publicCloud.database.ServiceCurrentState | read-only | Current configuration deployed on the service |
| `currentState.advancedConfiguration` | object | read-only | Current advanced configuration key-value pairs. Null for engines that do not support advanced configuration. |
| `currentState.backup` | publicCloud.database.BackupCurrentState | read-only | Current backup configuration of the service |
| `currentState.backup.pitr` | string (date-time) | read-only | Date until which point-in-time recovery is available for this service |
| `currentState.backup.regions` | common.RegionEnum[] | read-only | Regions where backups of this service are stored |
| `currentState.backup.retentionDays` | integer | read-only | Number of days backups are retained for this service |
| `currentState.backup.time` | string | read-only | Time of day at which automatic backups are scheduled, in HH:MM UTC format |
| `currentState.capabilities` | object | read-only | Map of capabilities available for this service, keyed by capability name. Each entry describes which CRUD actions are enabled or disabled. |
| `currentState.deletionProtected` | boolean | read-only | Whether deletion of this service is protected. A protected service cannot be deleted until this flag is set to false. |
| `currentState.description` | string | read-only | Human-readable description of the service |
| `currentState.endpoints` | publicCloud.database.Endpoint[] | read-only | Connection endpoints exposed by this service |
| `currentState.endpoints[].component` | publicCloud.database.EndpointComponentEnum | read-only | Component accessible through this endpoint — one of `CLICKHOUSE`, `GRAFANA`, `KAFKA`, `KAFKA_CONNECT`, `KAFKA_REST`, `KAFKA_SCHEMA_REGISTRY`, `MONGODB`, `MYSQL`, `OPENSEARCH`, `OPENSEARCH_DASHBOARDS`, `POSTGRESQL`, `VALKEY` |
| `currentState.endpoints[].domain` | string | read-only | Fully qualified domain name of the endpoint |
| `currentState.endpoints[].path` | string | read-only | URL path appended to the domain when applicable |
| `currentState.endpoints[].port` | integer | read-only | TCP port of the endpoint |
| `currentState.endpoints[].public` | boolean | read-only | True on the endpoints that use the public domain name of the service, false on the private ones. Null for an engine or a service that does not support public exposure. |
| `currentState.endpoints[].scheme` | string | read-only | URI scheme of the endpoint, for example kafka, postgresql, https |
| `currentState.endpoints[].ssl` | boolean | read-only | Whether TLS is enabled on this endpoint |
| `currentState.endpoints[].sslMode` | publicCloud.database.SSLModeEnum | read-only | TLS verification mode of the endpoint — one of `REQUIRE` |
| `currentState.endpoints[].uri` | string | read-only | Full connection URI combining scheme, domain, port, and path |
| `currentState.engineCapabilities` | publicCloud.database.ServiceEngineCapabilities | read-only | Engine-specific capabilities of this service |
| `currentState.engineCapabilities.advancedConfigurationProperties` | publicCloud.database.capabilities.AdvancedConfigurationProperty[] | read-only | Available advanced configuration properties and their constraints. Null for engines that do not support advanced configuration. |
| `currentState.engineCapabilities.backupRegions` | string[] | read-only | Available regions for backup storage. Null for engines that do not support cross-region backups. |
| `currentState.engineCapabilities.categories` | string[] | read-only | Available command categories. Only applicable to Valkey services. |
| `currentState.engineCapabilities.commands` | string[] | read-only | Available commands. Only applicable to Valkey services. |
| `currentState.engineCapabilities.connectors` | publicCloud.database.kafkaConnect.capabilities.ConnectorCapability[] | read-only | Available connector types. Only applicable to Kafka Connect services. |
| `currentState.engineCapabilities.integrations` | publicCloud.database.capabilities.IntegrationCapability[] | read-only | Available integration types and their parameters |
| `currentState.flavor` | string | read-only | Compute flavor used by the nodes of this service. Null when flavor is determined by the plan. |
| `currentState.maintenanceWindow` | publicCloud.database.MaintenanceCurrentState | read-only | Current maintenance window configuration of the service |
| `currentState.maintenanceWindow.startTimeUtc` | string | read-only | Preferred start time for maintenance windows, in HH:MM UTC format |
| `currentState.network` | publicCloud.database.NetworkCurrentState | read-only | Current network configuration of the service |
| `currentState.network.authorizedIps` | publicCloud.database.AuthorizedIps | read-only | Current IP authorization configuration of the service |
| `currentState.network.networkId` | string (uuid) | read-only | Private network identifier this service is attached to |
| `currentState.network.public` | boolean | read-only | True while the service is published on a public address, false while it is not. Null for an engine or a service that does not support public exposure. |
| `currentState.network.subnetId` | string (uuid) | read-only | Subnet identifier within the private network |
| `currentState.nodes` | publicCloud.database.Node[] | read-only | Nodes composing this service cluster |
| `currentState.nodes[].createdAt` | string (date-time) | read-only | Date at which the node was created |
| `currentState.nodes[].flavor` | string | read-only | Compute flavor of the node |
| `currentState.nodes[].id` | string (uuid) | read-only | Unique identifier of the node |
| `currentState.nodes[].location` | publicCloud.common.Location | read-only | Location of this node |
| `currentState.nodes[].name` | string | read-only | Name of the node |
| `currentState.nodes[].port` | integer | read-only | TCP port on which the node listens |
| `currentState.nodes[].role` | publicCloud.database.NodeRoleEnum | read-only | Role of this node within the cluster — one of `ANALYTICS`, `PRIMARY`, `SECONDARY`, `STANDBY` |
| `currentState.nodes[].status` | common.ResourceStatusEnum | read-only | Current readiness status of the node — one of `CREATING`, `CREATION_PLANNED`, `DELETING`, `ERROR`, `OUT_OF_SYNC`, `READY`, `SUSPENDED`, `UNKNOWN`, `UPDATING` |
| `currentState.nodesCount` | integer | read-only | Number of nodes currently composing the cluster. While the cluster is being created or scaled, this reflects the number of nodes requested rather than the number already deployed in nodes. |
| `currentState.plan` | string | read-only | Service plan currently applied |
| `currentState.prometheusEnabled` | boolean | read-only | Whether Prometheus monitoring is enabled on this service |
| `currentState.status` | publicCloud.database.service.StatusEnum | read-only | Operational status of the service as reported by the database engine — one of `CREATING`, `DELETING`, `DRAINED`, `ERROR`, `LOCKED`, `LOCKED_PENDING`, `LOCKED_UPDATING`, `PENDING`, `READY`, `SHELVED`, `TO_DRAIN`, `UPDATING` |
| `currentState.storage` | publicCloud.database.Storage | read-only | Storage configuration of the service. Null for engines that do not use block storage. |
| `currentState.storage.size` | publicCloud.database.UnitAndValue |  | Storage size allocated to the service |
| `currentState.storage.type` | publicCloud.database.StorageTypeEnum | read-only | Type of storage used by the service. Immutable after creation. — one of `HIGH_SPEED`, `HIGH_SPEED_GEN2` |
| `currentState.version` | string | read-only | Engine version currently running |
| `currentTasks` | common.CurrentTask[] | read-only | Asynchronous operations currently running on the service |
| `currentTasks[].errors` | common.TaskError[] | read-only | Errors that occurred on the task |
| `currentTasks[].errors[].message` | string | read-only | Error description |
| `currentTasks[].id` | string (uuid) | read-only | Identifier of the current task |
| `currentTasks[].link` | string | read-only | Link to the task details |
| `currentTasks[].status` | common.CurrentTaskStatusEnum | read-only | Current global status of the current task — one of `ERROR`, `PENDING`, `RUNNING`, `SCHEDULED`, `WAITING_USER_INPUT` |
| `currentTasks[].type` | string | read-only | Type of the current task |
| `id` | string (uuid) | read-only | Unique identifier of the service |
| `resourceStatus` | common.ResourceStatusEnum | read-only | Readiness status of the service. A new target specification is accepted only in READY status. — one of `CREATING`, `CREATION_PLANNED`, `DELETING`, `ERROR`, `OUT_OF_SYNC`, `READY`, `SUSPENDED`, `UNKNOWN`, `UPDATING` |
| `targetSpec` | publicCloud.database.ServiceTargetSpec | read-only | Last requested target specification for the service |
| `targetSpec.advancedConfiguration` | object | read-only | Advanced configuration key-value pairs requested for the service. Null for engines that do not support advanced configuration. |
| `targetSpec.backup` | publicCloud.database.BackupSpec | read-only | Requested backup configuration for the service |
| `targetSpec.backup.regions` | common.RegionEnum[] |  | Regions where backups should be stored. Supported values depend on the engine and plan. |
| `targetSpec.backup.time` | string |  | Preferred time of day for automatic backups, in HH:MM UTC format |
| `targetSpec.deletionProtected` | boolean | read-only | Whether deletion protection is requested on this service |
| `targetSpec.description` | string | read-only | Human-readable description of the service |
| `targetSpec.flavor` | string | read-only | Requested compute flavor for the nodes |
| `targetSpec.maintenanceWindow` | publicCloud.database.MaintenanceSpec | read-only | Requested maintenance window configuration for the service |
| `targetSpec.maintenanceWindow.startTimeUtc` | string |  | Preferred start time for maintenance windows, in HH:MM UTC format |
| `targetSpec.network` | publicCloud.database.NetworkUpdateSpec | read-only | Requested network configuration for the service. Only IP restrictions can change after creation. |
| `targetSpec.network.authorizedIps` | publicCloud.database.AuthorizedIps |  | IP authorization configuration to apply to the service |
| `targetSpec.network.public` | boolean |  | Set to true to publish the service on a public address: a public IP address in front of the service, and a public domain name with TLS. Set to false to take it off that address. The authorized IPs apply to the public address as they do to the private one. Null or absent keeps the current exposure. Engines and services that do not support public exposure ignore this field. |
| `targetSpec.nodesCount` | integer | read-only | Requested number of nodes composing the cluster |
| `targetSpec.plan` | string | read-only | Requested service plan |
| `targetSpec.prometheusEnabled` | boolean | read-only | Whether Prometheus monitoring is requested on this service. Null for engines that do not expose a Prometheus endpoint. |
| `targetSpec.storage` | publicCloud.database.StorageUpdateSpec | read-only | Requested storage configuration. Only size can change after creation. Null for engines that do not use block storage. |
| `targetSpec.storage.size` | publicCloud.database.UnitAndValue |  | Storage size allocated to the service |
| `targetSpec.version` | string | read-only | Requested engine version |
| `updatedAt` | string (date-time) | read-only | Date of the last update to the service |

```json
[
  {
    "checksum": "string",
    "createdAt": "2024-01-01T12:00:00Z",
    "currentState": {
      "advancedConfiguration": {
        "key": "string"
      },
      "backup": {
        "pitr": "2024-01-01T12:00:00Z",
        "regions": [
          "af-north-lz-rba"
        ],
        "retentionDays": 0,
        "time": "string"
      },
      "capabilities": {
        "key": {
          "create": "DISABLED",
          "delete": "DISABLED",
          "read": "DISABLED",
          "update": "DISABLED"
        }
      },
      "deletionProtected": true,
      "description": "string",
      "endpoints": [
        {
          "component": "CLICKHOUSE",
          "domain": "string",
          "path": "string",
          "port": 0,
          "public": true,
          "scheme": "string",
          "ssl": true,
          "sslMode": "REQUIRE",
          "uri": "string"
        }
      ],
      "engineCapabilities": {
        "advancedConfigurationProperties": [
          {
            "default": "string",
            "description": "string",
            "maximum": 0,
            "minimum": 0,
            "name": "string",
            "requiresRestart": true,
            "type": "BOOLEAN",
            "values": [
              null
            ]
          }
        ],
        "backupRegions": [
          "string"
        ],
        "categories": [
          "string"
        ],
        "commands": [
          "string"
        ],
        "connectors": [
          {
            "author": "string",
            "configuration": [
              null
            ],
  …
```

### Example

```bash
curl -X GET \
  "https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/managedDatabase/service" \
  -H "accept: application/json" \
  -H "authorization: Bearer $OVH_TOKEN"
```

```python
'''
First, install the latest release of Python wrapper: $ pip install ovh
'''
import json
import ovh

# Instantiate an OVH Client.
# You can generate new credentials with full access to your account on
# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
client = ovh.Client(
	endpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
	application_key='xxxxxxxxxx',    # Application Key
	application_secret='xxxxxxxxxx', # Application Secret
	consumer_key='xxxxxxxxxx',       # Consumer Key
)

result = client.get("/v2/publicCloud/project/{projectId}/managedDatabase/service")

# Pretty print
print(json.dumps(result, indent=4))
```

```php
<?php
/**
 * First, download the latest release of PHP wrapper on github
 * And include this script into the folder with extracted files
 */
require __DIR__ . '/vendor/autoload.php';
use \Ovh\Api;

/**
 * Instantiate an OVH Client.
 * You can generate new credentials with full access to your account on
 * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
 */
$ovh = new Api('xxxxxxxxxx',  // Application Key
               'xxxxxxxxxx',  // Application Secret
               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
               'xxxxxxxxxx'); // Consumer Key

$result = $ovh->get("/v2/publicCloud/project/{projectId}/managedDatabase/service");

print_r($result);
?>
```

## Get a service

`GET /v2/publicCloud/project/{projectId}/managedDatabase/service/{serviceId}`

Link: https://developers.eu.ovhcloud.com/reference/public-cloud/databases/#get-publiccloud-project-projectid-manageddatabase-service-serviceid

**Status:** Beta version  
**IAM actions:** `publicCloudProject:apiovh:database/service/get`

Returns a database service whatever its engine, with its target specification, current state and running tasks.

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `projectId` | path | string | yes | Project ID |
| `serviceId` | path | string (uuid) | yes | Service ID |

### Responses

| Status | Type | Description |
| --- | --- | --- |
| 200 | publicCloud.database.Service | successful operation |

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `checksum` | string | read-only | Hash of the resource used for concurrency control |
| `createdAt` | string (date-time) | read-only | Date at which the service was created |
| `currentState` | publicCloud.database.ServiceCurrentState | read-only | Current configuration deployed on the service |
| `currentState.advancedConfiguration` | object | read-only | Current advanced configuration key-value pairs. Null for engines that do not support advanced configuration. |
| `currentState.backup` | publicCloud.database.BackupCurrentState | read-only | Current backup configuration of the service |
| `currentState.backup.pitr` | string (date-time) | read-only | Date until which point-in-time recovery is available for this service |
| `currentState.backup.regions` | common.RegionEnum[] | read-only | Regions where backups of this service are stored |
| `currentState.backup.retentionDays` | integer | read-only | Number of days backups are retained for this service |
| `currentState.backup.time` | string | read-only | Time of day at which automatic backups are scheduled, in HH:MM UTC format |
| `currentState.capabilities` | object | read-only | Map of capabilities available for this service, keyed by capability name. Each entry describes which CRUD actions are enabled or disabled. |
| `currentState.deletionProtected` | boolean | read-only | Whether deletion of this service is protected. A protected service cannot be deleted until this flag is set to false. |
| `currentState.description` | string | read-only | Human-readable description of the service |
| `currentState.endpoints` | publicCloud.database.Endpoint[] | read-only | Connection endpoints exposed by this service |
| `currentState.endpoints[].component` | publicCloud.database.EndpointComponentEnum | read-only | Component accessible through this endpoint — one of `CLICKHOUSE`, `GRAFANA`, `KAFKA`, `KAFKA_CONNECT`, `KAFKA_REST`, `KAFKA_SCHEMA_REGISTRY`, `MONGODB`, `MYSQL`, `OPENSEARCH`, `OPENSEARCH_DASHBOARDS`, `POSTGRESQL`, `VALKEY` |
| `currentState.endpoints[].domain` | string | read-only | Fully qualified domain name of the endpoint |
| `currentState.endpoints[].path` | string | read-only | URL path appended to the domain when applicable |
| `currentState.endpoints[].port` | integer | read-only | TCP port of the endpoint |
| `currentState.endpoints[].public` | boolean | read-only | True on the endpoints that use the public domain name of the service, false on the private ones. Null for an engine or a service that does not support public exposure. |
| `currentState.endpoints[].scheme` | string | read-only | URI scheme of the endpoint, for example kafka, postgresql, https |
| `currentState.endpoints[].ssl` | boolean | read-only | Whether TLS is enabled on this endpoint |
| `currentState.endpoints[].sslMode` | publicCloud.database.SSLModeEnum | read-only | TLS verification mode of the endpoint — one of `REQUIRE` |
| `currentState.endpoints[].uri` | string | read-only | Full connection URI combining scheme, domain, port, and path |
| `currentState.engineCapabilities` | publicCloud.database.ServiceEngineCapabilities | read-only | Engine-specific capabilities of this service |
| `currentState.engineCapabilities.advancedConfigurationProperties` | publicCloud.database.capabilities.AdvancedConfigurationProperty[] | read-only | Available advanced configuration properties and their constraints. Null for engines that do not support advanced configuration. |
| `currentState.engineCapabilities.backupRegions` | string[] | read-only | Available regions for backup storage. Null for engines that do not support cross-region backups. |
| `currentState.engineCapabilities.categories` | string[] | read-only | Available command categories. Only applicable to Valkey services. |
| `currentState.engineCapabilities.commands` | string[] | read-only | Available commands. Only applicable to Valkey services. |
| `currentState.engineCapabilities.connectors` | publicCloud.database.kafkaConnect.capabilities.ConnectorCapability[] | read-only | Available connector types. Only applicable to Kafka Connect services. |
| `currentState.engineCapabilities.integrations` | publicCloud.database.capabilities.IntegrationCapability[] | read-only | Available integration types and their parameters |
| `currentState.flavor` | string | read-only | Compute flavor used by the nodes of this service. Null when flavor is determined by the plan. |
| `currentState.maintenanceWindow` | publicCloud.database.MaintenanceCurrentState | read-only | Current maintenance window configuration of the service |
| `currentState.maintenanceWindow.startTimeUtc` | string | read-only | Preferred start time for maintenance windows, in HH:MM UTC format |
| `currentState.network` | publicCloud.database.NetworkCurrentState | read-only | Current network configuration of the service |
| `currentState.network.authorizedIps` | publicCloud.database.AuthorizedIps | read-only | Current IP authorization configuration of the service |
| `currentState.network.networkId` | string (uuid) | read-only | Private network identifier this service is attached to |
| `currentState.network.public` | boolean | read-only | True while the service is published on a public address, false while it is not. Null for an engine or a service that does not support public exposure. |
| `currentState.network.subnetId` | string (uuid) | read-only | Subnet identifier within the private network |
| `currentState.nodes` | publicCloud.database.Node[] | read-only | Nodes composing this service cluster |
| `currentState.nodes[].createdAt` | string (date-time) | read-only | Date at which the node was created |
| `currentState.nodes[].flavor` | string | read-only | Compute flavor of the node |
| `currentState.nodes[].id` | string (uuid) | read-only | Unique identifier of the node |
| `currentState.nodes[].location` | publicCloud.common.Location | read-only | Location of this node |
| `currentState.nodes[].name` | string | read-only | Name of the node |
| `currentState.nodes[].port` | integer | read-only | TCP port on which the node listens |
| `currentState.nodes[].role` | publicCloud.database.NodeRoleEnum | read-only | Role of this node within the cluster — one of `ANALYTICS`, `PRIMARY`, `SECONDARY`, `STANDBY` |
| `currentState.nodes[].status` | common.ResourceStatusEnum | read-only | Current readiness status of the node — one of `CREATING`, `CREATION_PLANNED`, `DELETING`, `ERROR`, `OUT_OF_SYNC`, `READY`, `SUSPENDED`, `UNKNOWN`, `UPDATING` |
| `currentState.nodesCount` | integer | read-only | Number of nodes currently composing the cluster. While the cluster is being created or scaled, this reflects the number of nodes requested rather than the number already deployed in nodes. |
| `currentState.plan` | string | read-only | Service plan currently applied |
| `currentState.prometheusEnabled` | boolean | read-only | Whether Prometheus monitoring is enabled on this service |
| `currentState.status` | publicCloud.database.service.StatusEnum | read-only | Operational status of the service as reported by the database engine — one of `CREATING`, `DELETING`, `DRAINED`, `ERROR`, `LOCKED`, `LOCKED_PENDING`, `LOCKED_UPDATING`, `PENDING`, `READY`, `SHELVED`, `TO_DRAIN`, `UPDATING` |
| `currentState.storage` | publicCloud.database.Storage | read-only | Storage configuration of the service. Null for engines that do not use block storage. |
| `currentState.storage.size` | publicCloud.database.UnitAndValue |  | Storage size allocated to the service |
| `currentState.storage.type` | publicCloud.database.StorageTypeEnum | read-only | Type of storage used by the service. Immutable after creation. — one of `HIGH_SPEED`, `HIGH_SPEED_GEN2` |
| `currentState.version` | string | read-only | Engine version currently running |
| `currentTasks` | common.CurrentTask[] | read-only | Asynchronous operations currently running on the service |
| `currentTasks[].errors` | common.TaskError[] | read-only | Errors that occurred on the task |
| `currentTasks[].errors[].message` | string | read-only | Error description |
| `currentTasks[].id` | string (uuid) | read-only | Identifier of the current task |
| `currentTasks[].link` | string | read-only | Link to the task details |
| `currentTasks[].status` | common.CurrentTaskStatusEnum | read-only | Current global status of the current task — one of `ERROR`, `PENDING`, `RUNNING`, `SCHEDULED`, `WAITING_USER_INPUT` |
| `currentTasks[].type` | string | read-only | Type of the current task |
| `id` | string (uuid) | read-only | Unique identifier of the service |
| `resourceStatus` | common.ResourceStatusEnum | read-only | Readiness status of the service. A new target specification is accepted only in READY status. — one of `CREATING`, `CREATION_PLANNED`, `DELETING`, `ERROR`, `OUT_OF_SYNC`, `READY`, `SUSPENDED`, `UNKNOWN`, `UPDATING` |
| `targetSpec` | publicCloud.database.ServiceTargetSpec | read-only | Last requested target specification for the service |
| `targetSpec.advancedConfiguration` | object | read-only | Advanced configuration key-value pairs requested for the service. Null for engines that do not support advanced configuration. |
| `targetSpec.backup` | publicCloud.database.BackupSpec | read-only | Requested backup configuration for the service |
| `targetSpec.backup.regions` | common.RegionEnum[] |  | Regions where backups should be stored. Supported values depend on the engine and plan. |
| `targetSpec.backup.time` | string |  | Preferred time of day for automatic backups, in HH:MM UTC format |
| `targetSpec.deletionProtected` | boolean | read-only | Whether deletion protection is requested on this service |
| `targetSpec.description` | string | read-only | Human-readable description of the service |
| `targetSpec.flavor` | string | read-only | Requested compute flavor for the nodes |
| `targetSpec.maintenanceWindow` | publicCloud.database.MaintenanceSpec | read-only | Requested maintenance window configuration for the service |
| `targetSpec.maintenanceWindow.startTimeUtc` | string |  | Preferred start time for maintenance windows, in HH:MM UTC format |
| `targetSpec.network` | publicCloud.database.NetworkUpdateSpec | read-only | Requested network configuration for the service. Only IP restrictions can change after creation. |
| `targetSpec.network.authorizedIps` | publicCloud.database.AuthorizedIps |  | IP authorization configuration to apply to the service |
| `targetSpec.network.public` | boolean |  | Set to true to publish the service on a public address: a public IP address in front of the service, and a public domain name with TLS. Set to false to take it off that address. The authorized IPs apply to the public address as they do to the private one. Null or absent keeps the current exposure. Engines and services that do not support public exposure ignore this field. |
| `targetSpec.nodesCount` | integer | read-only | Requested number of nodes composing the cluster |
| `targetSpec.plan` | string | read-only | Requested service plan |
| `targetSpec.prometheusEnabled` | boolean | read-only | Whether Prometheus monitoring is requested on this service. Null for engines that do not expose a Prometheus endpoint. |
| `targetSpec.storage` | publicCloud.database.StorageUpdateSpec | read-only | Requested storage configuration. Only size can change after creation. Null for engines that do not use block storage. |
| `targetSpec.storage.size` | publicCloud.database.UnitAndValue |  | Storage size allocated to the service |
| `targetSpec.version` | string | read-only | Requested engine version |
| `updatedAt` | string (date-time) | read-only | Date of the last update to the service |

```json
{
  "checksum": "string",
  "createdAt": "2024-01-01T12:00:00Z",
  "currentState": {
    "advancedConfiguration": {
      "key": "string"
    },
    "backup": {
      "pitr": "2024-01-01T12:00:00Z",
      "regions": [
        "af-north-lz-rba"
      ],
      "retentionDays": 0,
      "time": "string"
    },
    "capabilities": {
      "key": {
        "create": "DISABLED",
        "delete": "DISABLED",
        "read": "DISABLED",
        "update": "DISABLED"
      }
    },
    "deletionProtected": true,
    "description": "string",
    "endpoints": [
      {
        "component": "CLICKHOUSE",
        "domain": "string",
        "path": "string",
        "port": 0,
        "public": true,
        "scheme": "string",
        "ssl": true,
        "sslMode": "REQUIRE",
        "uri": "string"
      }
    ],
    "engineCapabilities": {
      "advancedConfigurationProperties": [
        {
          "default": "string",
          "description": "string",
          "maximum": 0,
          "minimum": 0,
          "name": "string",
          "requiresRestart": true,
          "type": "BOOLEAN",
          "values": [
            "string"
          ]
        }
      ],
      "backupRegions": [
        "string"
      ],
      "categories": [
        "string"
      ],
      "commands": [
        "string"
      ],
      "connectors": [
        {
          "author": "string",
          "configuration": [
            {
              "defaultValue": null,
              "description": null,
              "displayName": null,
              "group": null,
              "importance": null,
  …
```

### Example

```bash
curl -X GET \
  "https://api.eu.ovhcloud.com/v2/publicCloud/project/{projectId}/managedDatabase/service/{serviceId}" \
  -H "accept: application/json" \
  -H "authorization: Bearer $OVH_TOKEN"
```

```python
'''
First, install the latest release of Python wrapper: $ pip install ovh
'''
import json
import ovh

# Instantiate an OVH Client.
# You can generate new credentials with full access to your account on
# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
client = ovh.Client(
	endpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
	application_key='xxxxxxxxxx',    # Application Key
	application_secret='xxxxxxxxxx', # Application Secret
	consumer_key='xxxxxxxxxx',       # Consumer Key
)

result = client.get("/v2/publicCloud/project/{projectId}/managedDatabase/service/{serviceId}")

# Pretty print
print(json.dumps(result, indent=4))
```

```php
<?php
/**
 * First, download the latest release of PHP wrapper on github
 * And include this script into the folder with extracted files
 */
require __DIR__ . '/vendor/autoload.php';
use \Ovh\Api;

/**
 * Instantiate an OVH Client.
 * You can generate new credentials with full access to your account on
 * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)
 */
$ovh = new Api('xxxxxxxxxx',  // Application Key
               'xxxxxxxxxx',  // Application Secret
               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)
               'xxxxxxxxxx'); // Consumer Key

$result = $ovh->get("/v2/publicCloud/project/{projectId}/managedDatabase/service/{serviceId}");

print_r($result);
?>
```
