Description

This function deletes a certificate signing request (CSR).


To delete a private key, use the UAPI function SSL::delete_key instead.


Examples 




https://hostname.example.com:2083/cpsess##########/execute/SSL/delete_csr?friendly_name=TestCSR



$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
 
// Remove the certificate signing request TestCSR
$SSL_delete_csr = $cpanel->uapi(
    'SSL', 'delete_csr',    array(
        'friendly_name'    => 'TestCSR',
    )
);



my $cpliveapi = Cpanel::LiveAPI->new(); # Connect to cPanel - only do this once.
 
# TEMPLATE
my $SSL_delete_csr = $cpliveapi->uapi(
    'SSL', 'delete_csr',    {
        'friendly_name'    => 'TestCSR',
    }
);



<!--  List redirection info -->
[% data = execute( 'SSL', 'delete_csr', { friendly_name => 'TestCSR',} ); %]
[% FOREACH q = data %]
     <p>
         [% q %]
     </p>
[% END %]



uapi --user=username SSL delete_csr friendly_name=TestCSR



{
  "messages": null,
  "errors": null,
  "status": 1,
  "data": [
    {
      "created": "1365714527",
      "domains": [
        "example.com"
      ],
      "commonName": "example.com",
      "modulus": "a673c3b17344664b35f8791f562d3aea6bf4d8faa3ae3fc0a519380fd453964a36677c34d48677ecb7f5ed035df026f5f0f8fbfe21745e52daf1f3b9e58c73f0baefdb709320e2202e7d05250b051a59b30ff1fef22d83d7140c1c81cea314a0890ce8d2226799872181c58a74016c7aaa2cff5ac72b575cecde8f304aa572a2ea03d8b173ab76c6e8cdb9dfd0da81e1119cefd4b8b4dbfbe0e46c7f1ee2fe8b5fd5504e58ccbc0d13b4fa41ecc9ebd0dabe1d1fec5c724f748167e7c0553e997f9b77eb36abce70973f06df151748d41b758de3efd7afa6f2464a1547f5ff158469d96e248be464df9eda0e7ce854a89332a2c1278b17c425368a9604f454db",
      "id": "example_com_e095f_0ab2f_ebcbe4a571276f48562241411556647f",
      "friendly_name": "TestCSR"
    }
  ],
  "metadata": {
    "transformed": 1
  }
}



Parameters

 You must include one of the following parameters:

ParameterTypeDescriptionPossible valuesExample
idstring

The CSR's ID.

A valid string.



example_com_e095f_0ab2f_ebcbe4a571276f48562241411556647f


 

 

friendly_namestringThe CSR's friendly name.A valid string.TestCSR

Returns

ReturnTypeDescriptionPossible valuesExample
created stringThe CSR's creation date.A date in Unix time format.
1365714527
domainsstringThe domains that the CSR covers.A valid domain or domains.example.com
commonNamestringThe CSR's common name.A valid string.example.com
modulusstringThe CSR's modulus.A valid string.


                      a74f7636fa6ac93ee6836a83a995b55deb5019ea36d7ba3dafb00e38d693acdb0c81b2ff777d6b433a420fae523f127f352a68bcc8b8f2d6ee7b70395bafabd8237ada8164fdddf8376b30375c35d4d4cbcce7d33d08069c17b409176a3689f1ebc97c0b08fe6ae44c19a92ac6d68448e7f1d13f3b360affd4222a51b4f35342de99b5a1fb5548e438f2d824664562a448002eed7fce24dedc7dc3e1ed179973d1dae959b33716eeb410d172708954e00632cbf60a0e26419860c8c0bc285d6bfe4b479de0dd189772a5dae676bd2a92acccc1369821be8cffddd8a7e6ecc061f8a32a9ae0661e4e946ed8e3827b277138d3a76116567cbd129cbd869ef9dddf 


idstringThe CSR's ID.A valid string.example_com_e095f_0ab2f_ebcbe4a571276f48562241411556647f
friendly_namestringThe CSR's friendly name.A valid string.TestCSR