Skip to main content

accountAddressCreate Mutation

Create a new address for the customer.

Requires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER.

Triggers the following webhook events:

  • CUSTOMER_UPDATED (async): A customer account was updated.
  • ADDRESS_CREATED (async): An address was created.
accountAddressCreate(
customerId: ID
input: AddressInput!
type: AddressTypeEnum
): AccountAddressCreate
Show return type

Arguments

customerId ● ID

ID of customer the application is impersonating. The field can be used and is required by apps only. Requires IMPERSONATE_USER and AUTHENTICATED_APP permission.

Added in Saleor 3.19

input ● AddressInput!

Fields required to create address.

type ● AddressTypeEnum

A type of address. If provided, the new address will be automatically assigned as the customer's default address of that type.

Type

AccountAddressCreate

Create a new address for the customer.

Requires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER.

Triggers the following webhook events:

  • CUSTOMER_UPDATED (async): A customer account was updated.
  • ADDRESS_CREATED (async): An address was created.