Skip to content

Key and Secret Manager

All operations require authentication.

3 operationsv2/okms/resource
Agent setup

List OKMS servicesProduction

GET
/v2/okms/resource

Returns the OKMS services of the account, with their region, KMIP and REST endpoints, and counts of keys, secrets and KMIP objects.

Query parameters

iamTags
object

Filter resources on IAM tags

Headers

X-Pagination-Cursor
string

Pagination cursor

X-Pagination-Size
integer

Pagination size

Response

200ResponseWithIAM[]successful operation
iam
read-only
ResourceMetadata

IAM resource metadata

id
read-only
stringuuid

Unique identifier of the OKMS

kmipEndpoint
read-only
string

KMS kmip API endpoint

kmipObjectCount
read-only
integer

Number of KMIP objects (non destroyed)

kmipRsaEndpoint
read-only
string

KMS kmip RSA API endpoint

pciDssEnabled
read-only
boolean

Whether PCI-DSS compliance is enabled on the service

pciDssEnabledAt
read-only
stringdate-time

Tells when PCI-DSS compliance was enabled

publicCA
read-only
string

KMS public CA (Certificate Authority)

publicRsaCA
read-only
string

KMS public RSA CA (Certificate Authority)

region
read-only
RegionEnum

Region the key management service runs in, which is where your keys and secrets are stored

Valuesap-south-mumap-southeast-sgpap-southeast-sydca-east-bhsca-east-toreu-central-waweu-south-mileu-west-erieu-west-graeu-west-limeu-west-pareu-west-rbxeu-west-sbg
restEndpoint
read-only
string

KMS rest API endpoint

secretCount
read-only
integer

Number of secrets

secretVersionCount
read-only
integer

Number of secret versions

serviceKeyCount
read-only
integer

Number of service keys

serviceKeyCountDetails
read-only
ServiceKeyCountDetails

Number of service keys per protection level

swaggerEndpoint
read-only
string

KMS rest API swagger UI

Reads your token from $OVH_TOKEN

$ curl https://api.eu.ovhcloud.com/v2/okms/resource \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
[ { "iam": { "displayName": "string", "id": "00000000-0000-0000-0000-000000000000", "state": "EXPIRED", "tags": { "key": "string" }, "urn": "string" }, "id": "00000000-0000-0000-0000-000000000000", "kmipEndpoint": "string", "kmipObjectCount": 0, "kmipRsaEndpoint": "string", "pciDssEnabled": true, "pciDssEnabledAt": "2024-01-01T12:00:00Z", "publicCA": "string", "publicRsaCA": "string", "region": "ap-south-mum", "restEndpoint": "string", "secretCount": 0, "secretVersionCount": 0, "serviceKeyCount": 0, "serviceKeyCountDetails": { "hsm": 0, "software": 0 }, "swaggerEndpoint": "string" }]

Get an OKMS serviceProduction

GET
/v2/okms/resource/{okmsId}

Returns the OKMS service with its endpoints and resource counts. Set publicCA to true to include the KMS public CA certificate.

Path parameters

okmsId
required
stringuuid

Okms ID

Query parameters

publicCA
boolean

Add KMS public CA (Certificate Authority) in the output

Response

200ResponseWithIAMsuccessful operation
iam
read-only
ResourceMetadata

IAM resource metadata

id
read-only
stringuuid

Unique identifier of the OKMS

kmipEndpoint
read-only
string

KMS kmip API endpoint

kmipObjectCount
read-only
integer

Number of KMIP objects (non destroyed)

kmipRsaEndpoint
read-only
string

KMS kmip RSA API endpoint

pciDssEnabled
read-only
boolean

Whether PCI-DSS compliance is enabled on the service

pciDssEnabledAt
read-only
stringdate-time

Tells when PCI-DSS compliance was enabled

publicCA
read-only
string

KMS public CA (Certificate Authority)

publicRsaCA
read-only
string

KMS public RSA CA (Certificate Authority)

region
read-only
RegionEnum

Region the key management service runs in, which is where your keys and secrets are stored

Valuesap-south-mumap-southeast-sgpap-southeast-sydca-east-bhsca-east-toreu-central-waweu-south-mileu-west-erieu-west-graeu-west-limeu-west-pareu-west-rbxeu-west-sbg
restEndpoint
read-only
string

KMS rest API endpoint

secretCount
read-only
integer

Number of secrets

secretVersionCount
read-only
integer

Number of secret versions

serviceKeyCount
read-only
integer

Number of service keys

serviceKeyCountDetails
read-only
ServiceKeyCountDetails

Number of service keys per protection level

swaggerEndpoint
read-only
string

KMS rest API swagger UI

Example uses okmsId = 00000000-0000-0000-0000-000000000000

$ curl https://api.eu.ovhcloud.com/v2/okms/resource/{okmsId} \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
{ "iam": { "displayName": "string", "id": "00000000-0000-0000-0000-000000000000", "state": "EXPIRED", "tags": { "key": "string" }, "urn": "string" }, "id": "00000000-0000-0000-0000-000000000000", "kmipEndpoint": "string", "kmipObjectCount": 0, "kmipRsaEndpoint": "string", "pciDssEnabled": true, "pciDssEnabledAt": "2024-01-01T12:00:00Z", "publicCA": "string", "publicRsaCA": "string", "region": "ap-south-mum", "restEndpoint": "string", "secretCount": 0, "secretVersionCount": 0, "serviceKeyCount": 0, "serviceKeyCountDetails": { "hsm": 0, "software": 0 }, "swaggerEndpoint": "string"}

Update an OKMS serviceProduction

PUT
/v2/okms/resource/{okmsId}

Enables or disables PCI-DSS enforcement on the service.

Path parameters

okmsId
required
stringuuid

Okms ID

Request body (required)

pciDssEnabled
boolean

Enable or disable PCI-DSS compliance

Response

200Responsesuccessful operation
id
read-only
stringuuid

Unique identifier of the OKMS

kmipEndpoint
read-only
string

KMS kmip API endpoint

kmipObjectCount
read-only
integer

Number of KMIP objects (non destroyed)

kmipRsaEndpoint
read-only
string

KMS kmip RSA API endpoint

pciDssEnabled
read-only
boolean

Whether PCI-DSS compliance is enabled on the service

pciDssEnabledAt
read-only
stringdate-time

Tells when PCI-DSS compliance was enabled

publicCA
read-only
string

KMS public CA (Certificate Authority)

publicRsaCA
read-only
string

KMS public RSA CA (Certificate Authority)

region
read-only
RegionEnum

Region the key management service runs in, which is where your keys and secrets are stored

Valuesap-south-mumap-southeast-sgpap-southeast-sydca-east-bhsca-east-toreu-central-waweu-south-mileu-west-erieu-west-graeu-west-limeu-west-pareu-west-rbxeu-west-sbg
restEndpoint
read-only
string

KMS rest API endpoint

secretCount
read-only
integer

Number of secrets

secretVersionCount
read-only
integer

Number of secret versions

serviceKeyCount
read-only
integer

Number of service keys

serviceKeyCountDetails
read-only
ServiceKeyCountDetails

Number of service keys per protection level

swaggerEndpoint
read-only
string

KMS rest API swagger UI

Example uses okmsId = 00000000-0000-0000-0000-000000000000

$ curl https://api.eu.ovhcloud.com/v2/okms/resource/{okmsId} \
  -H "authorization: Bearer $OVH_TOKEN"
ResponseExample
{ "id": "00000000-0000-0000-0000-000000000000", "kmipEndpoint": "string", "kmipObjectCount": 0, "kmipRsaEndpoint": "string", "pciDssEnabled": true, "pciDssEnabledAt": "2024-01-01T12:00:00Z", "publicCA": "string", "publicRsaCA": "string", "region": "ap-south-mum", "restEndpoint": "string", "secretCount": 0, "secretVersionCount": 0, "serviceKeyCount": 0, "serviceKeyCountDetails": { "hsm": 0, "software": 0 }, "swaggerEndpoint": "string"}