View as Markdown
Docupilot icon

Docupilot ACTION

Create Document

Create a document See docs here
  • Action
  • Writes data
  • API key
  • SDK
  • MCP

IMPLEMENTATION

Call this tool

Connect a user's Docupilot account once, then configure and run Create Document from your backend or agent.

import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "docupilot-create-document",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    docupilot: { authProvisionId: "apn_xxxxxxx" },
    templateUrl: "Template URL",
    tokens: "Template Tokens",
  },
})

console.log(result)

SCHEMA

Inputs

Pipedream supplies the connected account. Your application provides the operation-specific values below. Dynamic inputs are resolved against that user's account.

Create Document inputs
Property Type Description
templateUrl Template URL string
Choose a template in the Docupilot dashboard, and go to the Create tab, then to API integrations.
Copy the POST Merge URL here. Example: https://api.docupilot.app/documents/create/46ac75c3/5e7d03ec
Required
tokens Template Tokens object
The tokens used in this template (as object keys) and their values.
Objects and arrays should be in JSON-stringified format.
If you need to include characters such as {}[] in a value, and it should not be parsed as an object or array, prefix the key with $.
Required

REFERENCE

Tool details

Behavior hints are published with the component in the Pipedream registry and surface as MCP tool annotations, so an agent can reason about a tool before it calls it.

Registry key
docupilot-create-document
Version
0.0.2
App
Docupilot
Authentication
API key
Read-only
No
Destructive
No
Open world
Yes