---
title: "Create document from PDF"
method: POST
path: "/documents/create-from-pdf"
tags: ["General"]
---

# Create document from PDF

`POST /documents/create-from-pdf`

<small>Requires an API token with the **Document Manager** role.</small>

Creates a new [document](/#documents) from a previously uploaded PDF file.

This endpoint requires a two-step upload process:

1. Generate upload URL: Call the [Create document PDF upload URL](/operations/v1.file-uploads.document-pdf.create) endpoint to get a presigned upload URL
2. Upload PDF: Make a POST request to the returned URL with the specified form fields, followed by the PDF file contents in a `file` field
3. Create document: Call this endpoint with `file_upload_uuid` set to the `uuid` received in step 1

The PDF will be processed and converted into a fynk document with extractable content and signature fields.

For a complete guide with examples, see [How to create a document from a PDF file](/#how-to-create-a-document-from-a-pdf-file).

## Request body

- CreateDocumentFromPdfRequest
  - `file_upload_uuid` string, uuid, required — The UUID received in the [Create document PDF upload URL](/operations/v1.file-uploads.document-pdf.create) response
  - `file_name` string, required — The name of the PDF file
  - `initial_stage` string, required — The new document will be created in this stage. One of: `draft`, `done`
  - `name` string — The new document's name. If omitted, the `pdf_file_name` will be used as the new document's name
  - `template_uuid` string, uuid, nullable — Copy document settings from the [template](/#templates) with this UUID. Checkpoints, document type, metadata, parties, tags, teams, etc. will all be copied.
  - `account_party_uuid` string, uuid — UUID of the party from Settings > My Parties involved in the document
  - `ai_analysis_auto_apply` boolean — If true, AI analysis results will be automatically applied to the document. If false (the default), AI analysis results must be manually applied
  - `owner_emails` string[] — Email addresses of the user(s) from your account who should be given ownership of the new document
  - `team_uuids` string[] — UUIDs of any [teams](/operations/v1.teams.index) that should have access to the document
  - `tag_uuids` string[] — UUIDs of any [tags](/operations/v1.tags.index) to add to the document

## Response `201`

`DocumentDetailResource`

- object
  - `data` DocumentDetailResource, required
    - `uuid` string, required
    - `name` string, required
    - `signature_type` 'aes' | 'qes' | 'ses', required
    - `sequential_signing` boolean, required — When true, signatories will sign one at a time, in ascending order by their `signing_order`. When false, signatories may sign in any order
    - `origin` 'signed_pdf' | 'signed_pdf_external_account' | 'template' | 'scratch' | 'onboarding' | 'pdf', required
    - `stage` 'draft' | 'approved_draft' | 'review' | 'approved_review' | 'signing' | 'done', required
    - `locale` string, nullable, required
    - `template_uuid` string, required — UUID of the [template](/#templates) the document was created from, if any
    - `document_type_uuid` string, required — UUID of the [document type](/#document-types) assigned to the document, if any
    - `external_signatory_invitation_message` string, nullable, required — This text will be displayed in the email notification sent to users when the document is ready for signing
    - `created_at` string, date-time, nullable, required
    - `updated_at` string, date-time, nullable, required
    - `archived_at` string, date-time, nullable, required
    - `parties` DocumentPartySnippetResource[], required — The people and/or organizations that will be involved in signing the document
      - `uuid` string, required
      - `ref_uuid` string, required — If the document containing this party was created from a template, this identifier will be the same as the `ref_uuid` of the corresponding party in the source template.
      - `reference` string, nullable, required — A generic reference for the party
      - `entity_name` string, nullable, required — The actual name of the party. May be null if the party was created via a Template's "set later" option
      - `address` string, nullable, required
      - `scope` 'internal' | 'internal_and_external', required
      - `is_internal_party` boolean, required — Indicates whether this party is linked to an account party (internal) or is standalone (external)
      - `is_ready_for_signing` boolean, required — `true` indicates that an external party has indicated they are ready to sign
      - `ready_for_signing_at` string, date-time, nullable, required
      - `created_at` string, date-time, nullable, required
      - `updated_at` string, date-time, nullable, required
    - `teams` TeamSnippetResource[]
      - `uuid` string, required
      - `name` string, required
    - `integration_reference` IntegrationReferenceResource
      - `integration_type` 'salesforce' | 'hubspot' | 'pipedrive', required
      - `object_type` string, required — Indicates which type of CRM object the document is linked to. Values will vary depending on the `integration_type`
      - `external_id` string, required — The external system's ID for the specific CRM object that the document is linked to
      - `external_name` string, required — The external system's name for the specific CRM object that the document is linked to
    - `users` DocumentUserResource[] — Everyone who has access to the document, each with their access level (`role`)
      - `uuid` string, required
      - `first_name` string, nullable, required
      - `last_name` string, nullable, required
      - `email` string, nullable, required
      - `title` string, nullable, required
      - `party_uuid` string, nullable, required — UUID of the [party](/#parties) the user belongs to, if any
      - `has_account_user` boolean, required — `true` if the document user has a fynk user belonging to your account
      - `role` 'owner' | 'collaborator' | 'viewer', required — The representation of a document user's access level in the external API. Internally the access level is held in the document user's roles (where a plain viewer simply has no role); the external API always exposes it as one of these three values.
      - `is_signatory` boolean, required — `true` if the user is also a [signatory](/#signatories) of the document. Use the signatory endpoints to manage this
      - `personal_link` ShareableLinkResource
        - `uuid` string, required
        - `url` string, required — The link URL. Treat it like a secret: anyone who has the URL can access the document with it
        - `expires_at` string, date-time, nullable, required — When the link stops working. `null` means the link never expires
        - `message` string, nullable, required — A personal message shown when the link is opened. Always `null` for public links
        - `created_at` string, date-time, nullable, required
    - `signatories` SignatoryResource[] — These are the users who will sign the document during the `signing` stage
      - `uuid` string, required
      - `first_name` string, nullable, required
      - `last_name` string, nullable, required
      - `email` string, nullable, required
      - `mobile_phone` string, nullable, required — Mobile phone number, in E.164 format
      - `title` string, nullable, required
      - `profile_photo_url` string, nullable, required
      - `signing_order` integer, nullable, required — When sequential signing is enabled, signatories will sign in ascending order of their `signing_order`
      - `has_account_user` boolean, required — `true` if the signatory has a fynk user belonging to your account
      - `party_uuid` string, nullable, required — UUID of the party that the signatory signs for
    - `dynamic_fields` DynamicFieldResource[]
      - `uuid` string, required
      - `ref_uuid` string, required — A static reference identifier, allowing dynamic fields in documents to be matched their corresponding field in the document's source template.
      - `type` 'id' | 'uuid' | 'bool' | 'date' | 'duration' | 'email' | 'list' | 'number' | 'currency' | 'currency_duration' | 'clause' | 'select' | 'multi_select' | 'text' | 'textarea' | 'timestamp' | 'array' | 'enum', required
      - `name` string, required
      - `scope` 'internal' | 'internal_and_external', required
      - `settings` MultiFieldSettingsResource, required
        - `currencies` string[], required — For `currency` or `currency_duration` fields, defines the currencies that can be assigned to the field's values
      - `autofill_type` 'document_created_date' | 'document_review_date' | 'document_signing_date', required
      - `format` DynamicFieldFormatResource, required
        - `decimals` integer, required
        - `decimal_separator` string, required
        - `thousands_separator` string, required
      - `select_values` string[], nullable, required — When `type` is "select" or "multi_select", defines the possible values for `value`
      - `is_mandatory` boolean, required
      - `question` string, nullable, required
      - `question_external` string, nullable, required — Question variant for external users
      - `value` union, required — The field's value, if it has been set
        - string
        - boolean
        - unknown[]
          - unknown
      - `order` integer, nullable, required
    - `metadata_values` MetadataValueResource[]
      - `uuid` string, required
      - `metadata` MetadataResource, required
        - `uuid` string, required
        - `type` 'system_autofilled' | 'system_computed' | 'system' | 'system_reference' | 'account', required
        - `value_type` 'id' | 'uuid' | 'bool' | 'date' | 'duration' | 'email' | 'list' | 'number' | 'currency' | 'currency_duration' | 'clause' | 'select' | 'multi_select' | 'text' | 'textarea' | 'timestamp' | 'array' | 'enum', required
        - `name` string, required
        - `display_name` string, required
        - `settings` MultiFieldSettingsResource, required
          - `currencies` string[], required — For `currency` or `currency_duration` fields, defines the currencies that can be assigned to the field's values
        - `select_values` string[], nullable, required — When `value_type` is `select`, defines the possible values for the metadata's value
        - `always_exists` boolean, required
        - `description` string, nullable, required
        - `keywords` string, nullable, required — Keywords to help with metadata identification.
        - `prompt` string, nullable, required — An AI prompt used for metadata extraction.
        - `is_contract_value` boolean, required — If true, this metadata will be included in the calculated "contract value" if it is present in a document. Only relevant when the value type is one of: `currency`, `currency_duration`
        - `relevant_document_type_uuids` string[], nullable, required — UUIDs of document types this metadata is relevant for. `null` means not relevant to any. `[]` means relevant to all.
      - `reference_dynamic_field_uuid` string, nullable, required
      - `value_source` 'user' | 'ai_analysis' | 'computed' | 'autofilled' | 'dynamic_field' | 'linked_document', required
      - `value` union, required — The metadata's value
        - string
        - boolean
        - unknown[]
          - unknown
      - `value_currency_monthly` string, nullable, required
      - `value_currency_yearly` string, nullable, required
      - `computed_status` 'missing_information' | 'conflicting_information' | 'not_applicable' | 'computed', required
      - `computed_value` union, required
        - string
        - boolean
        - unknown[]
          - unknown
      - `is_attached` boolean, required
      - `computed_at` string, date-time, nullable, required
    - `tags` TagResource[]
      - `uuid` string, required
      - `name` string, nullable, required
      - `color` string, required — Hex color code for the color that the tag has been assigned

## Other responses

- `401` — Unauthenticated
- `403` — Authorization error
- `409` — The resource's current state prevents the requested change
- `422` — Validation error

---

[API](https://skmtc.dev/fynk/apis/fynk-api-reference.md) · [All operations](https://skmtc.dev/fynk/apis/fynk-api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/fynk/fynk-api-reference/revisions/9657a6757f59/schema)
