require'time'require'ionoscloud-cert-manager'# setup authorizationIonoscloudCertManager.configuredo|config|# Configure HTTP basic authorization: basicAuth config.username='YOUR USERNAME' config.password='YOUR PASSWORD'# Configure API key authorization: tokenAuth config.api_key['Authorization'] ='YOUR API KEY'# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)# config.api_key_prefix['Authorization'] = 'Bearer'endapi_instance = IonoscloudCertManager::CertificatesApi.newcertificate_id = 'certificate_id_example'# String | begin# Delete a Certificate by ID api_instance.certificates_delete(certificate_id)rescueIonoscloudCertManager::ApiError=> eputs"Error when calling CertificatesApi->certificates_delete: #{e}"end
Using the certificates_delete_with_http_info variant
This returns an Array which contains the response data (nil in this case), status code and headers.
begin# Delete a Certificate by ID data, status_code, headers = api_instance.certificates_delete_with_http_info(certificate_id)p status_code # => 2xxp headers # => { ... }p data # => nilrescueIonoscloudCertManager::ApiError=> eputs"Error when calling CertificatesApi->certificates_delete_with_http_info: #{e}"end
Parameters
Name
Type
Description
Notes
certificate_id
String
Return type
nil (empty response body)
Authorization
basicAuth, tokenAuth
HTTP request headers
Content-Type: Not defined
Accept: Not defined
certificates_get
certificates_get(opts)
Get Certificates
Retrieves all available certificates.
Examples
require'time'require'ionoscloud-cert-manager'# setup authorizationIonoscloudCertManager.configuredo|config|# Configure HTTP basic authorization: basicAuth config.username='YOUR USERNAME' config.password='YOUR PASSWORD'# Configure API key authorization: tokenAuth config.api_key['Authorization'] ='YOUR API KEY'# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)# config.api_key_prefix['Authorization'] = 'Bearer'endapi_instance = IonoscloudCertManager::CertificatesApi.newopts = {offset:'offset_example',# String | 'Limit' and 'Offset' are optional; you can use these filter parameters to retrieve only part of the results obtained by a request. Offset is the first element (from the complete list of elements) to be included in the response.limit:'limit_example'# String | 'Limit' and 'Offset' are optional; you can use these filter parameters to retrieve only part of the results of a query. If both 'Offset' and 'Limit'are specified, the offset lines are skipped before counting the returned limit lines.}begin# Get Certificates result = api_instance.certificates_get(opts)p resultrescueIonoscloudCertManager::ApiError=> eputs"Error when calling CertificatesApi->certificates_get: #{e}"end
Using the certificates_get_with_http_info variant
This returns an Array which contains the response data, status code and headers.
begin# Get Certificates data, status_code, headers = api_instance.certificates_get_with_http_info(opts)p status_code # => 2xxp headers # => { ... }p data # => <CertificateCollectionDto>rescueIonoscloudCertManager::ApiError=> eputs"Error when calling CertificatesApi->certificates_get_with_http_info: #{e}"end
Parameters
Name
Type
Description
Notes
offset
String
'Limit' and 'Offset' are optional; you can use these filter parameters to retrieve only part of the results obtained by a request. Offset is the first element (from the complete list of elements) to be included in the response.
[optional]
limit
String
'Limit' and 'Offset' are optional; you can use these filter parameters to retrieve only part of the results of a query. If both 'Offset' and 'Limit'are specified, the offset lines are skipped before counting the returned limit lines.
require'time'require'ionoscloud-cert-manager'# setup authorizationIonoscloudCertManager.configuredo|config|# Configure HTTP basic authorization: basicAuth config.username='YOUR USERNAME' config.password='YOUR PASSWORD'# Configure API key authorization: tokenAuth config.api_key['Authorization'] ='YOUR API KEY'# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)# config.api_key_prefix['Authorization'] = 'Bearer'endapi_instance = IonoscloudCertManager::CertificatesApi.newcertificate_id = 'certificate_id_example'# String | begin# Get a Certificate by ID result = api_instance.certificates_get_by_id(certificate_id)p resultrescueIonoscloudCertManager::ApiError=> eputs"Error when calling CertificatesApi->certificates_get_by_id: #{e}"end
Using the certificates_get_by_id_with_http_info variant
This returns an Array which contains the response data, status code and headers.
begin# Get a Certificate by ID data, status_code, headers = api_instance.certificates_get_by_id_with_http_info(certificate_id)p status_code # => 2xxp headers # => { ... }p data # => <CertificateDto>rescueIonoscloudCertManager::ApiError=> eputs"Error when calling CertificatesApi->certificates_get_by_id_with_http_info: #{e}"end
require'time'require'ionoscloud-cert-manager'# setup authorizationIonoscloudCertManager.configuredo|config|# Configure HTTP basic authorization: basicAuth config.username='YOUR USERNAME' config.password='YOUR PASSWORD'# Configure API key authorization: tokenAuth config.api_key['Authorization'] ='YOUR API KEY'# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)# config.api_key_prefix['Authorization'] = 'Bearer'endapi_instance = IonoscloudCertManager::CertificatesApi.newcertificate_id = 'certificate_id_example'# String | certificate_patch_dto = IonoscloudCertManager::CertificatePatchDto.new({properties:IonoscloudCertManager::CertificatePatchPropertiesDto.new({name:'My Certificate'})}) # CertificatePatchDto | begin# Update a Certificate Name by ID result = api_instance.certificates_patch(certificate_id, certificate_patch_dto)p resultrescueIonoscloudCertManager::ApiError=> eputs"Error when calling CertificatesApi->certificates_patch: #{e}"end
Using the certificates_patch_with_http_info variant
This returns an Array which contains the response data, status code and headers.
Adds a new PEM (Privacy Enhanced Mail) file that is used to store SSL certificates and their associated private keys.
Examples
require'time'require'ionoscloud-cert-manager'# setup authorizationIonoscloudCertManager.configuredo|config|# Configure HTTP basic authorization: basicAuth config.username='YOUR USERNAME' config.password='YOUR PASSWORD'# Configure API key authorization: tokenAuth config.api_key['Authorization'] ='YOUR API KEY'# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)# config.api_key_prefix['Authorization'] = 'Bearer'endapi_instance = IonoscloudCertManager::CertificatesApi.newcertificate_post_dto = IonoscloudCertManager::CertificatePostDto.new({properties: IonoscloudCertManager::CertificatePostPropertiesDto.new({name: 'My Certificate', certificate: '-----BEGIN CERTIFICATE-----MIIE5TCCAs2gAwIBAgIBATANBgkqhkiG9w0BAQsFADA2MQswCQYDVQQGEwJSTzEK-----END CERTIFICATE-----', certificate_chain: '-----BEGIN CERTIFICATE-----MIIDoTCCAokCFDrAUWffdxWJVz2Axl9lp/4xiUteMA0GCSqGSIb3DQEBCwUAMIGG-----END CERTIFICATE-----', private_key: '-----BEGIN RSA PRIVATE KEY-----MIIJKQIBAAKCAgEAzDehfqWBr+9q0pxwCDDRph7QSPiMbkDGaGKc+Fd2h3doT8Li-----END RSA PRIVATE KEY-----'})}) # CertificatePostDto |
begin# Add a New Certificate result = api_instance.certificates_post(certificate_post_dto)p resultrescueIonoscloudCertManager::ApiError=> eputs"Error when calling CertificatesApi->certificates_post: #{e}"end
Using the certificates_post_with_http_info variant
This returns an Array which contains the response data, status code and headers.