Alokai

deleteCustomerAddress

Delete a customer address.

Signature

declare function deleteCustomerAddress(
	context: Context,
	addressId: number,
	customQuery?: CustomQuery,
	customHeaders?: CustomHeaders
): Promise<FetchResult<DeleteCustomerAddressMutation>>;

Parameters

NameRequiredTypeDescription
contextRequiredContext
addressIdRequirednumber
customQueryOptionalCustomQuery
customHeadersOptionalCustomHeaders

Referenced Types

Examples

Simple usage:

import { sdk } from '~/sdk.config.ts';

const addressId = 12;
// customer address will be removed for the currently logged in customer
const response = await sdk.magento.deleteCustomerAddress({ id: addressId });
// response.data?.deleteCustomerAddress - result is stored here, it's boolean

On this page