Skip to content

pos-delete-address ​

Method: DELETE
Path: /pos/customers/{id}/addresses/{address_id}

Tags: Addresses

Summary ​

Delete address

Pos SDK Usage ​

SDK Method: pos.deleteAddress()

Example:

typescript
const { error } = await pos.deleteAddress({
  id: "cust_123",
  address_id: "addr_456"
});

if (error) {
  console.error("Failed to delete address:", error.message);
}

TypeScript Definition ​

typescript
"pos-delete-address": {
        parameters: {
            query?: never;
            header?: never;
            path: {
                /** @description address id */
                address_id: string;
                /** @description customer id */
                id: string;
            };
            cookie?: never;
        };
        requestBody?: never;
        responses: {
            /** @description OK */
            200: {
                headers: {
                    [name: string]: unknown;
                };
                content: {
                    "application/json": {
                        message: string;
                        success: boolean;
                    };
                };
            };
            400: components["responses"]["AdminBadRequest"];
            401: components["responses"]["AdminUnauthorized"];
            403: components["responses"]["Forbidden"];
            404: components["responses"]["AdminNotFound"];
            /** @description Unsupported method. Use GET, PUT, DELETE. */
            405: components["responses"]["MethodNotAllowed"];
            408: components["responses"]["RequestTimeout"];
            500: components["responses"]["AdminInternalServerError"];
            504: components["responses"]["GatewayTimeout"];
        };
    };

Component References ​

ReferenceResolves To
components["responses"]["AdminBadRequest"]AdminBadRequest
components["responses"]["AdminUnauthorized"]AdminUnauthorized
components["responses"]["Forbidden"]Forbidden
components["responses"]["AdminNotFound"]AdminNotFound
components["responses"]["MethodNotAllowed"]MethodNotAllowed
components["responses"]["RequestTimeout"]RequestTimeout
components["responses"]["AdminInternalServerError"]AdminInternalServerError
components["responses"]["GatewayTimeout"]GatewayTimeout

Parameters ​

  • address_id (path): address id
  • id (path): customer id

Responses ​

200 ​

OK

400 ​

401 ​

403 ​

Access denied. token-required requires an authenticated session; permission-denied means the caller cannot access this resource. On POS, session-expired requires signing in again.

404 ​

405 ​

408 ​

500 ​

504 ​

The request timed out.

OpenAPI Definition ​

json
{
  "operationId": "pos-delete-address",
  "summary": "Delete address",
  "parameters": [
    {
      "name": "address_id",
      "in": "path",
      "description": "address id",
      "required": true,
      "schema": {
        "type": "string",
        "maxLength": 128,
        "minLength": 1,
        "pattern": "^[A-Za-z0-9_-]{1,128}$"
      }
    },
    {
      "name": "id",
      "in": "path",
      "description": "customer id",
      "required": true,
      "schema": {
        "type": "string",
        "maxLength": 128,
        "minLength": 1,
        "pattern": "^[A-Za-z0-9_-]{1,128}$"
      }
    }
  ],
  "responses": {
    "200": {
      "description": "OK",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "message": {
                "type": "string"
              },
              "success": {
                "type": "boolean"
              }
            },
            "required": [
              "message",
              "success"
            ]
          }
        }
      }
    },
    "400": {
      "$ref": "#/components/responses/AdminBadRequest"
    },
    "401": {
      "$ref": "#/components/responses/AdminUnauthorized"
    },
    "403": {
      "$ref": "#/components/responses/Forbidden"
    },
    "404": {
      "$ref": "#/components/responses/AdminNotFound"
    },
    "405": {
      "description": "Unsupported method. Use GET, PUT, DELETE.",
      "$ref": "#/components/responses/MethodNotAllowed"
    },
    "408": {
      "$ref": "#/components/responses/RequestTimeout"
    },
    "500": {
      "$ref": "#/components/responses/AdminInternalServerError"
    },
    "504": {
      "$ref": "#/components/responses/GatewayTimeout"
    }
  },
  "externalDocs": {
    "url": "https://llm-docs.commercengine.io/admin-pos/operations/pos-delete-address"
  },
  "security": [
    {
      "Authorization": []
    }
  ],
  "tags": [
    "Addresses"
  ],
  "x-speakeasy-group": "pos"
}

Auto-generated from OpenAPI spec and TypeScript definitions

Last updated: