Retrieve the SSH Key Value Using Query Parameters
/paas/api/v1.1/instancemgmt/{domainName}/services/SOA/credentials
- Use the
?credname
query parameter to retrieve results for a given credential name. - Use the
?serviceName
query parameter to retrieve results for a given Oracle SOA Cloud Service instance.
Note the following:
- By default, 50 keys are returned by a given query. Use the
?limitRowCount
query parameter to control the page size (number of results returned in a single request). - Use the
?offset
query parameter to fetch additional results, if available. By default,offset
is 0 (zero).
Request
-
domainName: string
Identity domain ID for the Oracle SOA Cloud Service account.
-
credname(optional): string
Unique credential name.
Note:
vmspublickey
is the only supported credential name. This is the default if a credential name is not supplied. -
serviceName(optional): string
Name of the Oracle SOA Cloud Service instance. If a service name is not supplied, the request will return all service instances for the given identity domain ID.
-
X-ID-TENANT-NAME: string
Identity domain ID for the Oracle SOA Cloud Service account.
Response
- application/json
200 Response
object
-
componentType:
string
Type of service component. Possible values include:
WLS
,OTD
,DB
. -
computeKeyName:
string
Compute sshkey object key name.
-
credName:
string
Credential name. Currently, the only supported credential name is
vmspublickey
. -
credType:
string
Credential type. Only supported value is
SSH
. -
description:
string
Credential description of the credential name.
-
hasMore:
boolean
Flag that specifies whether the list returned by the query is full (
false
) or partial (true
).When the list is partial, use the
offset
query parameter to fetch additional results. By default,offset
is 0 (zero) andlimitRowCount
is 50. -
identityDomain:
string
Identity domain ID for the Oracle SOA Cloud Service account.
-
items:
string
Groups SSH key value details returned by the query.
-
lastUpdateMessage:
string
Message returned from the last update for the SSH key. For example:
newly created
,updated by username
. -
lastUpdateStatus:
string
Status of the last update for the SSH key.
-
lastUpdateTime:
string
Date and time the SSH key was last updated.
-
osUserName:
string
Virtual machine OS user name. Only supported value is
opc
. -
parentType:
string
Valid value is
SERVICE
. -
publicKey:
string
Public key for the secure shell (SSH). This key is used for authentication when connecting to the Oracle SOA Cloud Service instance using an SSH client.
-
serviceName:
string
Name of the Oracle SOA Cloud Service instance.
-
serviceState:
string
State of the service instance. For example,
RUNNING
. -
serviceType:
string
Cloud service type. Valid value is
jaas
for Oracle SOA Cloud Service. -
totalResults:
integer
Number of results returned by the query.
Examples
The following example shows how to retrieve SSH key values by using query parameters in a GET request on the REST resource using cURL.
-
Currently, the only supported credential name is
vmspublickey
. -
The command in this example uses the URL structure
https://rest_server_url/resource-path
, whererest_server_url
is the REST server to contact for your identity domain (or Cloud account). See Send Requests.
cURL Command
curl -i -X GET -u username:Password! -H "X-ID-TENANT-NAME:ExampleIdentityDomain" "https://rest_server_url/paas/api/v1.1/instancemgmt/{domainName}/services/SOA/credentials?credname=vmspublickey&serviceName=ExampleInstance"
Example of Response Header
The following example shows the response header.
HTTP/1.1 200 OK
Date: Tue, 30 Aug 2016 02:12:51 GMT
Transfer-Encoding: chunked
Content-Type: application/json
Example of Response Body
The following example shows the response returned in JSON format for a given credential name and service name.
{
"items":[
{
"identityDomain":"ExampleIdentityDomain",
"serviceType":"SOA",
"serviceName":"ExampleInstance",
"credName":"vmspublickey",
"credType":"SSH",
"componentType":"WLS",
"parentType":"SERVICE",
"lastUpdateTime":"2016-04-19T19:29:49.257+0000",
"lastUpdateStatus":"success",
"lastUpdateMessage":"newly created",
"osUserName":"opc",
"computeKeyName":"\/OPCWLS\/myuser\/SOA.ExampleInstance.wls.ora_user",
"publicKey":"ssh-rsa ZXZXB3NzaC1yc2EAAAABJQAAAQEAr57JqX\/vDab9T+WNxymhCIYSZhv9kVeUTtT0BhvW6WV2BQC
vN1YfiHsSvAt25YoKBOYM925CPUClbIySfwQEpNhZVtw+mUlKd1SNP3ZMgSakHQG8gbtrVwPcpxdeTiYXlEYXetZv20g2PF9JRcN6lYsjS41fhotfytW4IsZ
+Vf7PN44\/kpU\/W\/qPcePK6HlY+iLUKzN\/tBCenCBJgrRYj5FUQBf1Ujli4nl0mJ3HKC4pbZ4V0OoxL0Yt\/qRDUJOrUQilzapABzftzTstVAeaSAsp9t
r+k8+MxsI37AvJwy1PvhWW4MU1x8y7gfJPsFfJ9lFH5T6PiZasBtpPWGEeeE== rsa-key-20133333",
"description":"Service user ssh public key which can be used to access the service VM instances",
"serviceState":"RUNNING"
}],
"hasMore":false,
"totalResults":1
}