ONTAP Rest API Discussions

Setting server_enabled to true after installing SSL certificate from REST API (ONTAP 15)

aaa1
601 Views

I am automating SSL renewal procedure.

 

I have managed to install the certificate, but after installation I would like to enable it (usually done in CLI in the security ssl cmddir by parsing the -server-enabled true argument) to take over from the certificate currently enabled.

 

These are the endpoints present in the /api/docs:

GET ​/security​/certificates

POST ​/security​/certificates

GET ​/security​/certificates​/{uuid}

DELETE ​/security​/certificates​/{uuid}

 

Can someone help navigating me further to accomplish this? I have without success tried in two different ways to update by trying the PATCH method, although not present in documentation, as well as looking through the docs of svm endpoints.

4 REPLIES 4

AmitKerkar
524 Views

does this work

/security/certificates/{uuid}/enable ?

aaa1
520 Views

Thanks for the response. 

 

With POST, PATCH  or? I do not have this endpoint in the documentation. Can I ask you where you found this?

aaa1
520 Views

I tried with multiple HTTP methods and get error "Unexpected argument: "enable"

noor_buchi
400 Views

Hello Anders,

 

To update the web services security configuration and set a certificate for an SVM, the /api/svm/svms/{svm.uuid}/web endpoint should be used.

Please refer to the official REST API documentation for more information on this endpoint: https://docs.netapp.com/us-en/ontap-restapi/ontap/svm_svms_svm.uuid_web_endpoint_overview.html#updating-the-web-services-security-configuration

 

As for the Python Client Library, the WebSvm object can be used. For more information, refer to the official library documentation here: https://library.netapp.com/ecmdocs/ECMLP3331665/html/resources/web_svm.html

 

I hope this is helpful.

 

Best,

Noor Buchi

Public