[{"label":"Latest (v1.0)","version":"latest"}]
nsx-intelligence-and-application-platform

Add Certificate

Description

Adds a new certificate or a chain of certificates (CAs). The certificate is used as a client certificate in the trust store depends on the Entity Type. The private key will be ignored if provided. Only NSX_UA_NODE, NSX_UA_CLUSTER, NSX_UA_TN, SUBSCRIBER_NODE, NSX_UA_KAFKA_CLIENT is allowed for this method. The certificate should be stored in PEM format. Note1: it will simply return if users are trying to upload the same pem data with same entity type. Note2: it accpets a request with an empty pem data. It could be used to synchronize services given a entity type.

Request

Request

URL

URL


post
https://api_host/napp/api/v1/platform/trust-management/certificates
Copy

Request Body

Request Body

CertificateData of type(s) application/json Required

The certificate to import in the truststore.

{}
#definitions/EntityType
used_by Required

Entity that use this Certificate


#definitions/CertificateDetail
details Optional

expand the pem data and show all its details.


string
passphrase Optional

Password for private key encryption.


string
pem_encoded Optional

Pem encoded certificate data.


string
private_key Optional

Private key data.


boolean
skip_sync_services Optional

Skip synchronizing services after certificate change. User such as nsx-config can change multiple certificates without synchronizing services and synchronizes services in the last call.


string
alias Optional

Alias of the Certificate; Unique identifier of this certificate under a Certificate Entity.


string
uuid Optional

UUID of the certificate. Generated on k8s platform. If given in post request, the API will return bad request.

Authentication

Authentication

This operation uses the following authentication methods.

Response

Response

Response Body

Response Body

200 OK

Returns CertificateData of type(s) application/json

OK and Certificate content

{
	"alias": "string",
	"passphrase": "string",
	"pem_encoded": "string",
	"private_key": "string",
	"skip_sync_services": false,
	"uuid": "string"
}
#definitions/EntityType
used_by Required

Entity that use this Certificate


#definitions/CertificateDetail
details Optional

expand the pem data and show all its details.


string
passphrase Optional

Password for private key encryption.


string
pem_encoded Optional

Pem encoded certificate data.


string
private_key Optional

Private key data.


boolean
skip_sync_services Optional

Skip synchronizing services after certificate change. User such as nsx-config can change multiple certificates without synchronizing services and synchronizes services in the last call.


string
alias Optional

Alias of the Certificate; Unique identifier of this certificate under a Certificate Entity.


string
uuid Optional

UUID of the certificate. Generated on k8s platform. If given in post request, the API will return bad request.

Errors

Errors

400

Unknown backend error

Code Samples

Code Samples

cURL Command

curl -X POST -H "Content-Type: application/json" -d '{"alias":"string","passphrase":"string","pem_encoded":"string","private_key":"string","skip_sync_services":false,"uuid":"string"}' https://api_host/napp/api/v1/platform/trust-management/certificates


[{"label":"Latest (v1.0)","version":"latest"}]
nsx-intelligence-and-application-platform
Feedback

Was this page helpful?