Certificates REST API

Use this REST API to manage certificates.

Available HTTP Methods

Table 1. REST API for Certificates
HTTP Method URI Pattern DATA Format Success Codes Error Codes
GET
  • For stand-alone hypervisors: /resources/hypervisors/{id}/certificate
  • For a managed cloud group: /resources/clouds/{id}/certificate
application/json
200
This code returns a formatted certificate for the specified hypervisor. See the example for a sample of the data that is returned.
403
This code is returned if the requester has not been assigned the cloud administration role.
404
This code is returned if:
  • the hypervisor does not return a certificate.
  • no cloud or hypervisor with the specified ID exists
  • the specified cloud is not a managed cloud
  • if the IBM® Systems Director that manages the cloud does not return a certificate
500
This code is returned if the IBM Cloud Pak System Software encountered an internal error while processing the request.

GET /resources/hypervisors/{id}/certificate example

{
   "id": 1,
   "certificates": [
      "Certificate: 1",
      "",
      "Version: 3",
      "",
      "Subject: OID.1.2.840.113549.1.9.2=\"1233003790,564d7761726520496e632e\", 
			CN=myhypervisor.mycompany.com, OU=VMware ESX Server Certificate, 
			EMAILADDRESS=ssl-certificates@vmware.com, O=\"VMware, Inc.\", L=Palo Alto, 
			ST=California, C=US",
      "",
      "Key: ",
      " IBMJCE RSA Public Key:",
      "  modulus:",
      "   1339803331059169396205872003875740052553863051674618430116476617574249",
      "   5026411738717148849905840700453727318717943418667122434412630187079348",
      "   6873813288481494146160025627725751470887183385307527405440695734180966",
      "   8462579382022195458840146325997544446223584485323748610456300364783827",
      "   68380160577053130037267269337",
      "  public exponent:",
      "   65537",
      "",
      "Validity: ",
      " From: Mon Jan 26 16:03:11 EST 2009",
      " To: Mon Mar 27 17:03:11 EDT 2028",
      "",
      "Issuer: OID.1.2.840.113549.1.9.2=\"1233003790,564d7761726520496e632e\", 
			CN=myhypervisor.mycompany.com, OU=VMware ESX Server Certificate, 
			EMAILADDRESS=ssl-certificates@vmware.com, O=\"VMware, Inc.\", L=Palo Alto, 
			ST=California, C=US",
      "",
      "Serial Number:",
      " 0",
      "",
      "Signature: ",
      " Algorithm: MD5withRSA",
      " Algorithm OID: 1.2.840.113549.1.1.4",
      "",
      " 0000: 53 73 eb f0 f0 bb 4c 48  ea d4 23 0c 20 e1 4f b7  Ss....LH......O.",
      " 0010: aa 7d 64 aa 5f cc c7 a4  fa b0 38 73 9c 94 eb 77  ..d.......8s...w",
      " 0020: c8 2a 51 bb 34 7c 2f b6  90 c8 25 f1 e3 90 18 ea  ..Q.4...........",
      " 0030: bb 63 08 a0 2f 66 c4 36  9a d1 98 29 1f 37 d4 0d  .c...f.6.....7..",
      " 0040: 5e 10 20 ac 1c d3 bc 2f  4e e8 b4 65 3d 3e 90 ed  ........N..e....",
      " 0050: 90 64 9e f6 d0 f0 a7 31  ba 13 b3 93 69 a3 39 59  .d.....1....i.9Y",
      " 0060: 73 c9 f3 4f 22 3c 7e 3d  08 6b 09 6f ac 82 e4 bb  s..O.....k.o....",
      " 0070: d6 32 0f ba eb 29 47 20  24 78 1c d2 cb ed fb 4b  .2....G..x.....K"
   ]
}