Skip to content

CreateAdminAddress ​

Type: schema

TypeScript Definition ​

typescript
CreateAdminAddress: {{
            first_name: string;
            last_name?: string | null;
            /** @default +91 */
            country_code?: string;
            /** @description Ten digits. Use country_code for the calling prefix. */
            phone: string;
            email?: string | "";
            address_line1: string;
            address_line2?: string | null;
            landmark?: string | null;
            pincode: string;
            city: string;
            state: string;
            country: string;
            gstin?: string | null;
            /** @description Use in shipping details only for third party. */
            business_name?: string | null;
            /** @default false */
            is_default_billing?: boolean;
            /** @default false */
            is_default_shipping?: boolean;
            /** @description Whether this is the customer’s primary address. */
            is_primary?: boolean;
        };
        /**
         * CreateReplacementShipmentForCollectInStore
         * @description Replacement shipment payload when the customer collects the items from a store instead of having them delivered.
         */
}

OpenAPI Schema ​

json
{
  "type": "object",
  "properties": {
    "first_name": {
      "type": "string",
      "maxLength": 128,
      "minLength": 1
    },
    "last_name": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 128
    },
    "country_code": {
      "type": "string",
      "default": "+91",
      "maxLength": 8,
      "pattern": "^\\+?\\d{1,4}$"
    },
    "phone": {
      "description": "Ten digits. Use country_code for the calling prefix.",
      "type": "string",
      "maxLength": 16,
      "pattern": "^\\d{10}$"
    },
    "email": {
      "anyOf": [
        {
          "type": "string",
          "format": "email",
          "maxLength": 128
        },
        {
          "type": "string",
          "const": ""
        }
      ]
    },
    "address_line1": {
      "type": "string",
      "maxLength": 256,
      "minLength": 1
    },
    "address_line2": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 256
    },
    "landmark": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 128
    },
    "pincode": {
      "type": "string",
      "maxLength": 6,
      "minLength": 6
    },
    "city": {
      "type": "string",
      "maxLength": 128,
      "minLength": 1
    },
    "state": {
      "type": "string",
      "maxLength": 128,
      "minLength": 1
    },
    "country": {
      "type": "string",
      "maxLength": 128,
      "minLength": 1
    },
    "gstin": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 16,
      "pattern": "^$|^[0-9]{2}[A-Z]{5}[0-9]{4}[A-Z][1-9A-Z]Z[0-9A-Z]$"
    },
    "business_name": {
      "description": "Use in shipping details only for third party.",
      "type": [
        "string",
        "null"
      ],
      "maxLength": 128
    },
    "is_default_billing": {
      "type": "boolean",
      "default": false
    },
    "is_default_shipping": {
      "type": "boolean",
      "default": false
    },
    "is_primary": {
      "description": "Whether this is the customer’s primary address.",
      "type": "boolean"
    }
  },
  "externalDocs": {
    "url": "https://llm-docs.commercengine.io/admin-pos/schemas/CreateAdminAddress"
  },
  "required": [
    "first_name",
    "phone",
    "address_line1",
    "pincode",
    "city",
    "state",
    "country"
  ],
  "title": "CreateAdminAddress"
}

Auto-generated from OpenAPI spec and TypeScript definitions

Last updated: