OnePageCRM ACTION
Update Deal
Updates an existing deal's details in OnePageCRM. See the documentation
- Action
- Writes data
- Destructive
- API key
- SDK
- MCP
IMPLEMENTATION
Call this tool
Connect a user's OnePageCRM account once, then configure and run Update Deal 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: "onepagecrm-update-deal",
externalUserId: "{external_user_id}", // any stable ID for this user in your system
configuredProps: {
onepagecrm: { authProvisionId: "apn_xxxxxxx" },
dealId: "Deal ID",
contactId: "Contact ID",
},
})
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": "onepagecrm-update-deal",
"configured_props": {
"onepagecrm": { "authProvisionId": "apn_xxxxxxx" },
"dealId": "Deal ID",
"contactId": "Contact ID"
}
}'// 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": "onepagecrm",
},
},
},
)
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: "onepagecrm-update-deal",
arguments: {
dealId: "Deal ID",
contactId: "Contact ID",
},
})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 |
|---|---|---|
dealId Deal ID | string | The unique identifier for the deal, Required Dynamic |
contactId Contact ID | string | The unique identifier for the contact Optional Dynamic |
ownerId User ID | string | ID of the user, to whom the contact belongs. Optional Dynamic |
pipelineId Pipeline ID | string | ID of a pipeline the deal belongs to. Optional Dynamic |
name Name | string | Name of the deal. Optional |
text Text | string | Extra notes related to the deal (supports [b]bold[/b] and [i]italic[/i] formatting). Optional |
stage Stage | integer | A numerical representation of the progress of a pending deal. Optional |
status Status | string | Status of the deal. Optional |
expectedCloseDate Expected Close Date | string | The date the deal is expected to close. Format: YYYY-MM-DD. (status should be pending). Optional |
closeDate Close Date | string | The date the deal actually closed. (status should be won or lost)`. Optional |
date Date | string | Creation date of the deal. Optional |
amount Amount | string | The monitary value of the deal (per month, if multi-month deal). Optional |
months Months | integer | Number of months the deal is to be paid for. (1 for regular deals, 2+ for multi-month). Optional |
cost Cost | string | The monitary cost of the deal Optional |
commissionBase Commission Base | string | Base used to calculate the commission of the deal. Optional |
commissionType Commission Type | string | Type of commission for the deal. Optional |
commission Commission | string | Commission payable for the deal. Optional |
commissionPercentage Commission Percentage | string | Commission percentage for the deal. 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
- onepagecrm-update-deal
- Version
- 0.0.2
- App
- OnePageCRM
- Authentication
- API key
- Read-only
- No
- Destructive
- Yes
- Open world
- Yes
- Source
- View on GitHub ↗