Add an SSH Public Key

post

/paas/api/v1.1/instancemgmt/{identityDomainId}/services/dbaas/instances/{serviceId}/credentials/crednames/{credentialName}

Adds an SSH public key for access to Exadata Cloud at Customer.

Request

Supported Media Types
Path Parameters
  • The value vmspublickey.
  • The value depends on the type of Exadata Cloud at Customer account that is used to make the request:

    • For a Traditional Cloud Account, specify the Identity Domain Name that is associated with the service.

    • For a Cloud Account with Identity Cloud Service, specify the Identity Service Id that is associated with the service, which is a character string beginning with idcs-.

  • Name of an existing Exadata Cloud at Customer database deployment. Note: The added SSH key provides access to the entire Exadata Cloud at Customer environment associated with the specified database deployment, not just the specified database deployment.
Header Parameters
Body ()
Root Schema : Request Body
Type: object
Title: Request Body
Show Source
  • The SSH public key value. Note that each slash (/) in the key value must be preceeded by a backslash (\), as in \/.
Back to Top

Response

Supported Media Types

202 Response

Accepted. See Status Codes for information about other possible HTTP status codes.
Headers
Body ()
Root Schema : Response Body
Type: object
Title: Response Body
Show Source
Back to Top

Examples

The following example shows how to add an SSH public key toan Exadata Cloud at Customer instance by submitting a POST request on the REST endpoint using cURL.

In this example, the identity domain is usexample and the Oracle Cloud user name and password are serviceadmin and Pa55_word. The name of the Exadata Cloud at Customer database deployment is db12c.

cURL Command

In the following cURL command, the request body is provided directly in the -d option.

curl -i -X POST --cacert ~/cacert.pem -u serviceadmin:Pa55_word -H "X-ID-TENANT-NAME:usexample" -H "Content-Type:application/json" -d '{ "public-key" : "ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAg6A0HG6VpE6OZuOoPzOh+vxA9\/rHnQFdSkQoGurVNi2RdgueHpZliVvOA2v6QO0YiomB3qBRUeIllcjFjyGKlVDbVIW3q\/dDl7OIapDSNUE+CM15+XFhh279\/zh7ko2Ze00hZJ3oeTDrZyapqxTmzvlHB8hYWfeq0Hg88dP+b7HDTj2kZ\/lFFyRARr+2Z42IXOW62VPaslo1PpBjkSyByreJuWRtXS6JNXWD1DIwD5Yfv4JMTecZOa9ENeDJ0mmX0qOeCcUqtThnePCBCemUkgOwQAAH3mQB2ZrGtXJqFYGWqck7JH\/WYiQj54+Y\/Mq40ziXZCMLgFMZTUmxjtJeAQ== rsa-key-20170531" }' https://dbaas.oraclecloud.com/paas/api/v1.1/instancemgmt/usexample/services/dbaas/instances/db12c/credentials/crednames/vmspublickey

HTTP Status Code and Response

HTTP/2.0 202
server: Oracle-Application-Server-11g
strict-transport-security: max-age=31536000;includeSubDomains
location: https://dbaas.oraclecloud.com:443/paas/api/v1.1/activitylog/usexample/job/12240309
content-language: en
access-control-allow-headers: Content-Type, api_key, Authorization, X-ID-TENANT-NAME, X-USER-IDENTITY-DOMAIN-NAME
retry-after: 5
access-control-allow-methods: GET, POST, DELETE, PUT, OPTIONS, HEAD
x-oracle-dms-ecid: 005KCX1FCAl6uHFpR0H7id00067c0004UB
x-oracle-dms-ecid: 005KCX1FCAl6uHFpR0H7id00067c0004UB
access-control-allow-origin: *
x-frame-options: DENY
content-type: application/json
vary: user-agent
date: Wed, 31 May 2017 01:58:23 GMT

{
	"status": "submitted job"
}
Back to Top