Mutation
mutation AddCustomerToTenants($input: AddCustomerToTenantsInput!) {
addCustomerToTenants(input: $input) {
customer {
id
externalId
fullName
shortName
email {
email
isVerified
verifiedAt {
__typename
}
}
avatarUrl
}
error {
message
type
code
fields {
field
message
type
}
}
}
}Variables
{
"input": {
"customerIdentifier": {},
"tenantIdentifiers": [
{}
]
}
}Response
{
"data": {
"addCustomerToTenants": {
"customer": {
"id": "id",
"externalId": "id",
"fullName": "string",
"shortName": "string",
"email": {
"email": "string",
"isVerified": true,
"verifiedAt": {
"__typename": "DateTime"
}
},
"avatarUrl": "string"
},
"error": {
"message": "string",
"type": "VALIDATION",
"code": "string",
"fields": [
{
"field": "string",
"message": "string",
"type": "VALIDATION"
}
]
}
}
}
}Mutations
addCustomerToTenants
Adds a customer to one or more tenants. The customer can be identified by their Plain ID, external ID, or email address.
If the customer is already a member of a given tenant the operation is a no-op for that tenant.
Requires the customer:edit and customerTenantMembership:create permissions.
MUTATION
addCustomerToTenants(input: AddCustomerToTenantsInput!): AddCustomerToTenantsOutput!Arguments
input
required
Returns
customer
error
Mutation
mutation AddCustomerToTenants($input: AddCustomerToTenantsInput!) {
addCustomerToTenants(input: $input) {
customer {
id
externalId
fullName
shortName
email {
email
isVerified
verifiedAt {
__typename
}
}
avatarUrl
}
error {
message
type
code
fields {
field
message
type
}
}
}
}Variables
{
"input": {
"customerIdentifier": {},
"tenantIdentifiers": [
{}
]
}
}Response
{
"data": {
"addCustomerToTenants": {
"customer": {
"id": "id",
"externalId": "id",
"fullName": "string",
"shortName": "string",
"email": {
"email": "string",
"isVerified": true,
"verifiedAt": {
"__typename": "DateTime"
}
},
"avatarUrl": "string"
},
"error": {
"message": "string",
"type": "VALIDATION",
"code": "string",
"fields": [
{
"field": "string",
"message": "string",
"type": "VALIDATION"
}
]
}
}
}
}Was this page helpful?

