This API endpoint creates a client.
Notes:
Custom Fields
When creating a client with custom field values, the customFields
object will have keys that correspond to the key
entity of the Custom Field, and values that are either strings, numbers, or arrays of strings (in the case of a multiSelect
type custom field). For multiSelect
custom fields, the values in the array will correspond to the key
entity of the Custom Field Option.
For example, if you have 2 custom fields: one named Services
of type multiSelect
(with key services
), and one named Pronouns
of type text
(with key pronouns
), matching the Custom Field Object example, when creating a client, your request body might include a customFields
parameter that looks like this:
{
"customFields": {
"services": ["fileSharing", "metrics"],
"pronouns": "She/Her/Hers",
"phoneNumber": "+14441234576",
"address": {
"country": "US",
"region": "New York",
"postalCode": "10001",
"addressLine1": "1201 Broadway",
"addressLine2": "704",
"city": "New York",
"fullAddress": "1201 Broadway\n704\nNew York, New York, 10001\nUnited States"
}
}
Custom Fields: Phone Number
When creating a client with a custom field of type phoneNumber
, the format needed for a successful update is +{countryCode}{areaCode}{number}
Example: +12123456789
The countryCode
and areaCode
must be valid to be updated successfully.
Custom Fields: Address
When creating a client with a custom field of type address
, provide an that matches the schema below. Fields annotated with a question mark are optional, but can be filled out if your country
is US
, CA
, AU
, GB
, or NZ
. country
must be a two character country code.
{
fullAddress: string,
country: string,
region?: string,
postalCode?: string,
addressLine1?: string,
addressLine2?: string,
city?: string,
}
To avoid breaking changes with existing integrations with our Platform API, the API will also accept a string rather than an object. In these instances, the API will convert the string to an object, and set the full address as the provided string.