๐Ÿ“„Create a Briefing Document

Generate NotebookLM-style briefing documents by calling /content/Create with outputType: "briefing_doc". The API supports three result formats:

  • pdf โ€” uploads a generated PDF and returns a URL

  • html โ€” returns structured HTML content

  • text โ€” returns plain text content

If you omit format, the API defaults to pdf.

Need a reusable file ID for a private PDF first? Follow Upload Private Filesarrow-up-right.

Step 1: Create the Document Request

Send a POST request to /content/Create with your source material and set outputType to briefing_doc.

curl -X POST "https://api.autocontentapi.com/content/Create" \
  -H "accept: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "outputType": "briefing_doc",
    "format": "pdf",
    "resources": [
      {
        "type": "website",
        "content": "https://example.com/enterprise-ai-market-update"
      }
    ],
    "text": "Create an executive briefing for B2B SaaS leaders. Include market shifts, key risks, and recommended actions.",
    "language": "en"
  }'

Example Response

Save the request_id. You will use it both for /content/Status/{id} and for the /documents endpoints.

Step 2: Poll for Status

Use the returned request_id to track generation progress:

While Processing

Status Values

  • 0 = Pending or queued

  • 5 = Early processing stages

  • 80 = Document generation in progress

  • 100 = Completed

Step 3: Read the Result from /content/Status/{id}

The final payload depends on the selected format.

Completed PDF Result

Completed HTML or Text Result

Use document_format to branch your client logic:

  • pdf: read briefing_doc_url or document_url

  • html: read document_content

  • text: read document_content or response_text

Step 4: Use the Documents API

The content status endpoint is enough for polling, but completed documents are also available through /documents.

List Documents

Example response:

Fetch One Document

Example PDF response:

Example HTML response:

Download the Stored Asset

The download endpoint returns the correct file type automatically:

  • PDF download for format: "pdf"

  • .html download for format: "html"

  • .txt download for format: "text"

Supported Source Types

You can generate briefing documents from the same main source types used by other content endpoints:

Type
Description
Example

website

Public web page URL

"https://example.com/report"

youtube

YouTube video URL

"https://www.youtube.com/watch?v=VIDEO_ID"

text

Direct text instructions or source material

"Internal memo content..."

pdf

Base64-encoded PDF payload

"BASE64_ENCODED_PDF"

file

"YOUR_FILE_ID"

Format Options

Format
Behavior
Best for

pdf

Generates a downloadable PDF and stores its URL

Client deliverables, handoffs, downloads

html

Returns structured HTML in the API response

CMS ingestion, rendering in apps

text

Returns plain text content

Summaries, internal automation, search indexing

Tips for Better Results

  1. Use text to specify audience, structure, and level of detail.

  2. Pick pdf when humans will download the deliverable, and html or text when another system will consume it.

  3. Poll /content/Status/{id} until status reaches 100 before calling /documents/{id}.

  4. Use /documents/get to build document history views in your app.

  5. If you need private PDFs, upload them first via Upload Private Filesarrow-up-right and reference the returned file ID with type: "file".

Error Handling

If generation fails, /content/Status/{id} returns the error metadata just like other content types:

What's Next?

Last updated