Customer Tags Mutations

CreateCustomerTag

Create a customer tag

Parameters

input - CustomerTagInput
Data of the customer tag
mutation CreateCustomerTag($input: CustomerTagInput!) {
  CreateCustomerTag(input: $input) {
    id
    label
    active
  }
}
{
  "input": {
    "label": "Premium Customer"
  }
}
{
  "data": {
    "CreateCustomerTag": {
      "id": 100120,
      "label": "Premium Customer",
      "active": true
    }
  }
}

UpdateCustomerTag

Update a customer tag

Parameters

id - ID
Id of the customer tag
input - CustomerTagInput
Data of the customer tag
mutation UpdateCustomerTag($id: ID!, $input: CustomerTagInput!) {
  UpdateCustomerTag(id: $id, input: $input) {
    id
    label
    active
  }
}
{
  "id": 100120,
  "input": {
    "label": "VIP Customer"
  }
}
{
  "data": {
    "UpdateCustomerTag": {
      "id": 100120,
      "label": "VIP Customer",
      "active": true
    }
  }
}

DeleteCustomerTag

Delete a customer tag

Parameters

id - ID
Id of the customer tag
mutation DeleteCustomerTag($id: ID!) {
  DeleteCustomerTag(id: $id)
}
{
  "id": 100120
}
{
  "data": { "DeleteCustomerTag": true }
}

DisableCustomerTag

Disable a customer tag

Parameters

id - ID
Id of the customer tag
mutation DisableCustomerTag($id: ID!) {
  DisableCustomerTag(id: $id) {
    id
    active
  }
}
{
  "id": 100120
}
{
  "data": {
    "DisableCustomerTag": {
      "id": 100120,
      "active": false
    }
  }
}

EnableCustomerTag

Enable a customer tag

Parameters

id - ID
Id of the customer tag
mutation EnableCustomerTag($id: ID!) {
  EnableCustomerTag(id: $id) {
    id
    active
  }
}
{
  "id": 100120
}
{
  "data": {
    "EnableCustomerTag": {
      "id": 100120,
      "active": true
    }
  }
}

CustomerTagInput data type

id - ID
Identifier (optional)
label - String
Name/Label of the tag