View as Markdown
ChartMogul icon

ChartMogul ACTION

Update Customer

Updates certain modifiable attributes of a customer object in your ChartMogul account. See the docs here
  • Action
  • Writes data
  • Destructive
  • API key
  • SDK
  • MCP

IMPLEMENTATION

Call this tool

Connect a user's ChartMogul account once, then configure and run Update Customer 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: "chartmogul-update-customer",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    chartmogul: { authProvisionId: "apn_xxxxxxx" },
    customerId: "Customer UUID",
    name: "Name",
  },
})

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.

Update Customer inputs
Property Type Description
customerId Customer UUID string
The ChartMogul UUID of the customer that needs to be updated. Specified as part of the URL.
Required Dynamic
name Name string
Name of the customer for display purposes. Accepts alphanumeric characters.
Optional
email Email string
Email address of the customer.
Optional
status Status string
The new status of the customer.
Optional
company Company string
The customer's company or organisation.
Optional
country Country string
Country code of customer's location as per ISO-3166 alpha-2 standard.
Optional
state State string
State code of customer's location as per ISO-3166 alpha-2 standard.
Optional
city City string
City of the customer's location.
Optional
zip Zip string
Zip code of the customer's location.
Optional
leadCreatedAt Lead Created At string
Time at which this customer was established as a lead. Must be an ISO 8601 formatted time in the past. The timezone defaults to UTC unless otherwise specified.
Optional
freeTrialStartedAt Free Trial Started At string
Time at which this customer started a free trial of your product or service. Must be an ISO 8601 formatted time in the past. The timezone defaults to UTC unless otherwise specified. This is expected to be the same as, or after the lead_created_at value.
Optional
tags Tags string[]
An Array of tags to be added to the customer.
Optional
custom Custom string[]
An Array containing the custom attributes to be added to the customer. If sending custom attributes, each custom attribute must be an object and have a type, key, and value. E.g. {"type":"String","key": "key1","value": "value1"}
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
chartmogul-update-customer
Version
0.0.3
App
ChartMogul
Authentication
API key
Read-only
No
Destructive
Yes
Open world
Yes