Publish a document

POST /api/v1/document/{document_uuid}/publish

This will make the document un-editable and will upload a DOCX and PDF file to the client.

Headers

Path parameters

Responses

  • 200 application/json
    Hide response attributes Show response attributes object
    • uuid string

      The UUID of the resource.

    • The timestamp of when the resource was created.

    • The timestamp of when the resource was updated.

    • version integer

      The document builder version. Used for internal purposes only. Defaults to 3

    • name string

      The name of the document.

    • status string

      The status of the document.

    • The required dependant variables of the document.

    • The dependants submitted to the document previously.

    • The download URL of the DOCX content. This is intended for the user to download if they are signed into Plannr. You can access this data via the API using the route in /api/v1.

    • The download URL of the SFDT (SyncFusion) content. This is intended for the user to download if they are signed into Plannr. You can access this data via the API using the route in /api/v1.

    • The download URL of the PDF content. This is intended for the user to download if they are signed into Plannr. You can access this data via the API using the route in /api/v1.

    • The image preview URL of the document. This is intended for the user to preview the document before opening it. You can access this data via the API using the route in /api/v1.

POST /api/v1/document/{document_uuid}/publish
curl \
 -X POST https://api.plannrcrm.com/api/v1/document/document_uuid/publish \
 -H "Authorization: Bearer {OAUTH_ACCESS_TOKEN or PERSONAL_ACCESS_TOKEN}" \
 -H "Content-Type: application/json" \
 -H "Accept: application/json" \
 -H "X-PLANNR-ACCOUNT-UUID: {YOUR_PLANNR_ACCOUNT_UUID}"
Response examples (200)
{
  "name": "Welcome Template",
  "uuid": "395ce74d-90b6-449a-8b35-d9424cbe9dbd",
  "status": "published",
  "version": 3,
  "created_at": "2024-10-16T11:10:15+01:00",
  "updated_at": "2024-10-16T11:10:15+01:00",
  "public_pdf_url": "https://plannr.valet/document/7e0b5f10-186b-432e-bc11-e59e0725a973/content/pdf?plannr_account_uuid=2d7d3f61-660e-4a1b-9662-6928f91b307f",
  "public_docx_url": "https://plannr.valet/document/ac0fa09f-58d9-4842-9b28-339e2486baff/content/docx?plannr_account_uuid=de35c89e-86f4-4fbe-9a09-16b0c0e94d5d",
  "public_sfdt_url": "https://plannr.valet/document/6d85af11-5aad-47fe-ba04-09af54c93370/content/sfdt?plannr_account_uuid=23cc9394-d30c-4491-ac19-e024e3da2050",
  "known_dependants": {
    "client-1": "d24c448c-2345-40c8-bbdc-2ced06ae368c"
  },
  "public_preview_url": "https://plannr.valet/document/9da21873-9c15-4166-ab4d-a70ebf5aed84/content/preview?plannr_account_uuid=ea7e6608-782b-4734-8feb-c564a6278015",
  "required_dependants": {
    "client-1": "client"
  }
}