Skip to content
For the complete documentation index, see llms.txt. Markdown versions of documentation pages are available by appending .md to the page URL.
Primary navigation
Theme

Delete certificate

client.admin.organization.certificates.delete(certificateID, options?): CertificateDeleteResponse { id, object }
DELETE
/organization/certificates/{certificate_id}

Delete a certificate from the organization.

The certificate must be inactive for the organization and all projects.

Delete certificate

import OpenAI from 'openai';

const client = new OpenAI({
  adminAPIKey: process.env['OPENAI_ADMIN_KEY'], // This is the default and can be omitted
});

const certificate = await client.admin.organization.certificates.delete('certificate_id');

console.log(certificate.id);
Response example
{
  "object": "certificate.deleted",
  "id": "cert_abc"
}
Parameters
certificateID: string
Returns
CertificateDeleteResponse { id, object }
id: string

The ID of the certificate that was deleted.

object: "certificate.deleted"

The object type, must be certificate.deleted.

Returns Examples
Response example
{
  "object": "certificate.deleted",
  "id": "cert_abc"
}