Using the SSL Certificates REST API
Using the SSL Certificates REST API is straight forward.
POST request
To POST a certificate, specify a name and the public certificate. There are input validations in place to avoid duplicates of name or certificate data. In practice this means that no two certificates can be uploaded with the same SHA-256 fingerprint hash.
{
"name": "example",
"certificate": "-----BEGIN CERTIFICATE-----\nMIIDHTCCAgWgAwIBAgIEKndOLDANBgkqhkiG9w0BAQsFADA/MRswGQYDVQQKExJPcmFjbGUgQ29y\ncG9yYXRpb24xIDAeBgNVBAMTF25jdWxsLWF1My5hdS5vcmFjbGUuY29tMB4XDTE3MDIwNjA0MzI1\nMFoXDTE3MDUwNzA0MzI1MFowPzEbMBkGA1UEChMST3JhY2xlIENvcnBvcmF0aW9uMSAwHgYDVQQD\nExduY3VsbC1hdTMuYXUub3JhY2xlLmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB\nAI3ej9WvMlIpvHeXkl3xJFmVEvksAeLoMh3jnf2Ybp+w8WEgH5tQuptJ6fNvZrn8u/D2J3xAu7L9\nKJLmHKOqrhaUI4S2zBUl2/ykQCozPTHSQS3Xpzqc3aD7RWIyTrX4of5AuFJaPowbXhpserVpQHNl\nYdYkA9eAJ8ALb4MK6i6uxtz3hh2wIHMr1w2b7qTGibYX2gFBY4PXjtFEGhxLWEHLR6+npMm0yYra\nKRsAV9m+a31d01kWUbG1DzZhuKSMuplsfz09nza1GJI43FBi4CiAE5afBVAWBFCRWK1pxBJfaMPn\nWi7iG9nrpQDi0NTQixugx1U1Ncr8IbYLkX86yKECAwEAAaMhMB8wHQYDVR0OBBYEFEqTn4C2Kz9+\nYIry99v0P5n/8nU1MA0GCSqGSIb3DQEBCwUAA4IBAQBJLRgrMImAbHr4JJVnr66C/OECnBtN2yCm\nu3taktRDsKoaOWtmD7MpSAHBT2U3YQb4iGh/l7lIF/wnrFQ0nMzXn5aSudq3TrascSowE7EGbZsW\n9j9DshI+Xr5JojAmXuzLWY64vu3pLHASObuUPXzMZE+H8rRGumBWwdYpI2V5UB6S8+Cg7c32kj3d\nhZ5cLP0kKqe/AxSU7hhVwxfbuhLDCXzJTKvamk1vkpzW0FpagJZayGvxtA2atJ5YA9Z2U3Iu6frS\nJUeP4oEOUYa5KlzU9GcxE677UNEgpJ+oy37LkSUQBUXNv+oDRtMGeW/Zcv8lwqKePLB1rhxIX733\nNHb7\n-----END CERTIFICATE-----\n"
}
POST response
The response adds additional read-only fields, extracted from the certificate data.
{
"name": "example",
"certificate": "-----BEGIN CERTIFICATE-----\nMIIDHTCCAgWgAwIBAgIEKndOLDANBgkqhkiG9w0BAQsFADA/MRswGQYDVQQKExJPcmFjbGUgQ29y\ncG9yYXRpb24xIDAeBgNVBAMTF25jdWxsLWF1My5hdS5vcmFjbGUuY29tMB4XDTE3MDIwNjA0MzI1\nMFoXDTE3MDUwNzA0MzI1MFowPzEbMBkGA1UEChMST3JhY2xlIENvcnBvcmF0aW9uMSAwHgYDVQQD\nExduY3VsbC1hdTMuYXUub3JhY2xlLmNvbTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB\nAI3ej9WvMlIpvHeXkl3xJFmVEvksAeLoMh3jnf2Ybp+w8WEgH5tQuptJ6fNvZrn8u/D2J3xAu7L9\nKJLmHKOqrhaUI4S2zBUl2/ykQCozPTHSQS3Xpzqc3aD7RWIyTrX4of5AuFJaPowbXhpserVpQHNl\nYdYkA9eAJ8ALb4MK6i6uxtz3hh2wIHMr1w2b7qTGibYX2gFBY4PXjtFEGhxLWEHLR6+npMm0yYra\nKRsAV9m+a31d01kWUbG1DzZhuKSMuplsfz09nza1GJI43FBi4CiAE5afBVAWBFCRWK1pxBJfaMPn\nWi7iG9nrpQDi0NTQixugx1U1Ncr8IbYLkX86yKECAwEAAaMhMB8wHQYDVR0OBBYEFEqTn4C2Kz9+\nYIry99v0P5n/8nU1MA0GCSqGSIb3DQEBCwUAA4IBAQBJLRgrMImAbHr4JJVnr66C/OECnBtN2yCm\nu3taktRDsKoaOWtmD7MpSAHBT2U3YQb4iGh/l7lIF/wnrFQ0nMzXn5aSudq3TrascSowE7EGbZsW\n9j9DshI+Xr5JojAmXuzLWY64vu3pLHASObuUPXzMZE+H8rRGumBWwdYpI2V5UB6S8+Cg7c32kj3d\nhZ5cLP0kKqe/AxSU7hhVwxfbuhLDCXzJTKvamk1vkpzW0FpagJZayGvxtA2atJ5YA9Z2U3Iu6frS\nJUeP4oEOUYa5KlzU9GcxE677UNEgpJ+oy37LkSUQBUXNv+oDRtMGeW/Zcv8lwqKePLB1rhxIX733\nNHb7\n-----END CERTIFICATE-----\n",
"fingerprintSHA256": "4A:13:E7:AD:2E:37:A4:0D:EE:F8:8D:1B:2A:A4:E3:5E:83:3A:A2:8A:E7:C3:57:36:CE:CB:75:A7:31:B4:1D:40",
"fingerprintSHA1": "14:67:40:78:6F:EF:C5:6D:30:94:0A:68:C9:08:E5:38:04:E5:C3:A8",
"validFrom": "2017-02-05T13:00:00Z",
"validTo": "2017-05-06T14:00:00Z",
"issuer": "CN=ncull-au3.au.oracle.com,O=Oracle Corporation",
"subject": "CN=ncull-au3.au.oracle.com,O=Oracle Corporation"
}