POST – Replace Certificate
Use the POST method to replace a certificate.
Request URL
GET https://<BMC_IPADDR>/redfish/v1/CertificateService/Actions/CertificateService.ReplaceCertificate
Request body
Field | Type | Description | |
---|---|---|---|
CertificateUri | Object | Required. The link to the certificate that is being replaced. | |
@odata.id | Link | The value shall be a certificate resource link. | |
CertificateType | String | Required. The format of the certificate. Only allows “PEM”. | |
CertificateString | String | Required. The string for the certificate. Line breaks should be replaced to “\n” in this parameter. |
Response body
Status code
HTTP Status Code | Error Message ID |
---|---|
400 | BadRequest, ActionParamMissing , ActionParamTypeError , ActionParamFormatError |
500 | InternalError |
Example
The POST body is filled as below:
{
"CertificateUri": {
"@odata.id": "/redfish/v1/Managers/1/NetworkProtocol/HTTPS/Certificates/1"
},
"CertificateType": "PEM",
"CertificateString": "-----BEGIN CERTIFICATE-----\n.MIIEhTCCA2... HoKwFzKGxRyrsQ \n-----END CERTIFICATE-----"
}
The following example JSON response is returned.
None.
Give documentation feedback