> ## Documentation Index
> Fetch the complete documentation index at: https://api-docs.tribalhabits.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Download certificate PDF

> Step 3 of 3: download the generated certificate PDF.

<RequestExample>
  ```bash curl theme={null}
  curl -o certificate.pdf "CERTIFICATE_URL"
  ```
</RequestExample>

<ResponseExample>
  ```text 200 theme={null}
  HTTP/1.1 200 OK
  Content-Type: application/pdf

  (binary PDF file)
  ```

  ```xml 403 theme={null}
  <?xml version="1.0" encoding="UTF-8"?>
  <Error>
    <Code>AccessDenied</Code>
    <Message>Request has expired</Message>
  </Error>
  ```
</ResponseExample>

This is step 3 of 3. See [Certificates](/certificates) for the full process.

When [Poll certificate status](/api-reference/certificates/poll-certificate-status) returns `status` `complete`, download the PDF with a `GET` request to its `url`. The URL points to the file in Amazon S3, not to the Tribal Habits API.

`GET <certificate_url>`

* No `Authorization` header is needed: the URL is pre-signed. Do not send your API key with this request.
* The response body is the PDF file itself, as binary data with `Content-Type: application/pdf`. Save it to a file; do not read it as JSON or text.
* The URL expires 15 minutes after it is returned. An expired URL returns `403`. To get a fresh URL, call [Poll certificate status](/api-reference/certificates/poll-certificate-status) again with the same `job_id`, within 24 hours of requesting the certificate.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.