Linear ACTION
Get Document Content History
Return the revision history for a Linear document — each entry shows when the content changed and which users made the edit. Provide the document's UUID or slugId (same format as Get Document). Use Search Documents to find the document ID. Each history entry includes
id, contentDataSnapshotAt (timestamp of the snapshot), and actorIds (list of user UUIDs who contributed to that revision). contentData is a serialized TipTap rich-text snapshot — include it in fields only when you need to render or diff the raw document structure; for a quick summary, contentDataSnapshotAt and actorIds are sufficient. The tool makes two API calls internally: first it resolves the document to its content ID, then it fetches the history. Example: documentId: "10b5bc2940c7" → returns [{id: "9d3c86fd-...", contentDataSnapshotAt: "2025-03-01T14:22:10Z", actorIds: ["3fd8c25f-..."]}]. See the documentation.- Action
- Read only
- OAuth
- SDK
- MCP
IMPLEMENTATION
Call this tool
Connect a user's Linear account once, then configure and run Get Document Content History 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: "linear-get-document-content-history",
externalUserId: "{external_user_id}", // any stable ID for this user in your system
configuredProps: {
linear: { authProvisionId: "apn_xxxxxxx" },
documentId: "Document ID",
fields: ["Fields"],
},
})
console.log(result)curl -X POST https://api.pipedream.com/v1/connect/{project_id}/actions/run \
-H "Content-Type: application/json" \
-H "X-PD-Environment: production" \
-H "Authorization: Bearer {access_token}" \
-d '{
"external_user_id": "{external_user_id}",
"id": "linear-get-document-content-history",
"configured_props": {
"linear": { "authProvisionId": "apn_xxxxxxx" },
"documentId": "Document ID",
"fields": ["Fields"]
}
}'// accessToken: mint a short-lived token with the Connect SDK — see the MCP guide
const transport = new StreamableHTTPClientTransport(
new URL("https://remote.mcp.pipedream.net/v3"),
{
requestInit: {
headers: {
Authorization: `Bearer ${accessToken}`,
"x-pd-project-id": "{project_id}",
"x-pd-environment": "production",
"x-pd-external-user-id": "{external_user_id}", // any stable ID for this user in your system
"x-pd-app-slug": "linear",
},
},
},
)
const mcp = new Client({ name: "my-agent", version: "1.0.0" })
await mcp.connect(transport)
const { tools } = await mcp.listTools()
// listTools() hands your model this tool's input schema, so it can
// fill the arguments itself:
const result = await mcp.callTool({
name: "linear-get-document-content-history",
arguments: {
documentId: "Document ID",
fields: ["Fields"],
},
})SCHEMA
Inputs
Pipedream supplies the connected account. Your application provides the operation-specific values below. Dynamic inputs are resolved against that user's account.
| Property | Type | Description |
|---|---|---|
documentId Document ID | string | The UUID or slugId of the document. A UUID looks like a1b2c3d4-0000-0000-0000-000000000001; a slugId is the short alphanumeric code at the end of the document URL (e.g. 10b5bc2940c7). Use Search Documents to find document IDs. Required |
fields Fields | string[] | Field names to return for each history entry. Defaults to a compact set: id, contentDataSnapshotAt, actorIds. Add contentData only when you need the full TipTap rich-text snapshot for diffing or rendering — it is a large nested object. e.g. ["id", "contentDataSnapshotAt", "contentData"] Optional |
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
- linear-get-document-content-history
- Version
- 0.0.1
- App
- Linear
- Authentication
- OAuth
- Read-only
- Yes
- Destructive
- No
- Open world
- Yes
- Source
- View on GitHub ↗