Order Desk ACTION
Update Order
Update Order See the documentation.
- Action
- Writes data
- Destructive
- API key
- SDK
- MCP
IMPLEMENTATION
Call this tool
Connect a user's Order Desk account once, then configure and run Update Order 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: "order_desk-update-order",
externalUserId: "{external_user_id}", // any stable ID for this user in your system
configuredProps: {
order_desk: { authProvisionId: "apn_xxxxxxx" },
order_id: "Order ID",
order_items: ["Order Items"],
},
})
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": "order_desk-update-order",
"configured_props": {
"order_desk": { "authProvisionId": "apn_xxxxxxx" },
"order_id": "Order ID",
"order_items": ["Order Items"]
}
}'// 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": "order_desk",
},
},
},
)
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: "order_desk-update-order",
arguments: {
order_id: "Order ID",
order_items: ["Order Items"],
},
})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 |
|---|---|---|
order_id Order ID | string | The ID of the order to retrieve. Required Dynamic |
order_items Order Items | string[] | A valid JSON string. Order Items Object can have the following properties: id, name, price, quantity, weight, code, delivery_type, category_code, variation_list, metadata. Please check the documentation in the description for more information. Optional |
customer_first_name Customer First Name | string | Customer first name Optional |
customer_last_name Customer Last Name | string | Customer last name Optional |
customer_company Customer Company | string | Customer company Optional |
shipping_first_name Shipping First Name | string | Shipping first name Optional |
shipping_last_name Shipping Last Name | string | Shipping last name Optional |
shipping_company Shipping Company | string | Shipping company Optional |
source_id Source ID | string | Your order ID. If blank, Order Desk's internal ID will be used read-only. Optional |
source_name Source Name | string | Pick from Available Source Names. Defaults to Order Desk. Optional |
email Email | string | Customer email address Optional |
shipping_method Shipping Method | string | Name of shipping method selected. Optional |
quantity_total Quantity Total | string | Total number of items in the order. Optional |
weight_total Weight Total | string | Total weight of the order. Optional |
product_total Product Total | string | Total cost of all items in the order. Optional |
shipping_total Shipping Total | string | Total cost of shipping. Optional |
handling_total Handling Total | string | Total cost of handling. Optional |
tax_total Tax Total | string | Total cost of tax. Optional |
discount_total Discount Total | string | Total cost of discounts. Optional |
order_total Order Total | string | Total cost of the order. Optional |
cc_number Credit Card Number | string | Obfuscated credit card number. Enter only the last four digits. Optional |
cc_exp Credit Card Expiration | string | Credit card expiration date in MM/YYYY format. Optional |
processor_response Processor Response | string | Gateway transaction ID in format <gateway_name>: <transaction_id> Optional |
payment_type Payment Type | string | Payment type. Can be Visa, Paypal, Mastercard, etc Optional |
payment_status Payment Status | string | Payment status. Can be Approved, Authorized, Captured, Fully Refunded, Partially Refunded, Pending, Rejected, Voided Optional |
processor_balance Processor Balance | string | The amount that the was charged at the processor. This amount will be decremented when refunds are made. By default it will be set the same as order_total Optional |
refund_total Refund Total | string | The amount that jhas been refunded on the order from within Order Desk. This is generally something that will be set internally. Optional |
customer_id Customer ID | string | The ID of the customer. This is generally something that will be set internally. Optional |
ip_address IP Address | string | The IP address of the customer. Optional |
fulfillment_id Fulfillment ID | string | The internal ID of the fulfillment service will be saved here for some services. Optional |
fulfillment_name Fulfillment Name | string | Once the order has been sent for fulfillment, the name of the fulfillment method is entered here. Optional |
folder_id Folder ID | string | The ID number of the folder in which the order is stored. If nothing is entered when adding an order, the folder will be the first folder in the list. 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
- order_desk-update-order
- Version
- 0.0.2
- App
- Order Desk
- Authentication
- API key
- Read-only
- No
- Destructive
- Yes
- Open world
- Yes
- Source
- View on GitHub ↗