Mindbody ACTION
Upsert Client
Creates a new client or updates an existing client record. To create: omit
clientId. firstName, lastName, and birthDate are required for new clients. To update: provide clientId — only the fields you specify will be updated. BirthDate format: ISO datetime string YYYY-MM-DDTHH:MM:SS (e.g., 1990-05-15T00:00:00). Use Search Clients to find an existing client's ID before updating. See the documentation- Action
- Writes data
- OAuth
- SDK
- MCP
IMPLEMENTATION
Call this tool
Connect a user's Mindbody account once, then configure and run Upsert Client 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: "mindbody-upsert-client",
externalUserId: "{external_user_id}", // any stable ID for this user in your system
configuredProps: {
mindbody: { authProvisionId: "apn_xxxxxxx" },
clientId: "Client ID",
firstName: "First Name",
},
})
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": "mindbody-upsert-client",
"configured_props": {
"mindbody": { "authProvisionId": "apn_xxxxxxx" },
"clientId": "Client ID",
"firstName": "First Name"
}
}'// 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": "mindbody",
},
},
},
)
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: "mindbody-upsert-client",
arguments: {
clientId: "Client ID",
firstName: "First Name",
},
})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 |
|---|---|---|
clientId Client ID | string | Existing client ID to update. Omit to create a new client. Optional |
firstName First Name | string | Client's first name. Required when creating a new client. Optional |
lastName Last Name | string | Client's last name. Required when creating a new client. Optional |
birthDate Birth Date | string | Client's date of birth. Required when creating a new client. Format: YYYY-MM-DDTHH:MM:SS (e.g., 1990-05-15T00:00:00). Optional |
email Email | string | Client's email address. Optional |
mobilePhone Mobile Phone | string | Client's mobile phone number (digits only, e.g., 5551234567). 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
- mindbody-upsert-client
- Version
- 0.0.3
- App
- Mindbody
- Authentication
- OAuth
- Read-only
- No
- Destructive
- No
- Open world
- Yes
- Source
- View on GitHub ↗