{
  "openapi": "3.1.0",
  "info": {
    "title": "CE Admin APIs",
    "version": "1.0",
    "summary": "Comprehensive admin interface for managing your e-commerce platform",
    "description": "Complete administrative API suite for Commerce Engine, providing powerful tools to manage products, orders, customers, inventory, analytics, and system configuration. Designed for administrators and backend integrations requiring full platform control.",
    "license": {
      "name": "All Rights Reserved",
      "url": "https://www.commercengine.io/contact-us"
    },
    "contact": {
      "email": "support@commercengine.io",
      "url": "https://www.commercengine.io/contact-us",
      "name": "Support"
    }
  },
  "servers": [
    {
      "url": "https://staging.api.commercengine.io/api/v1/{store_id}/admin",
      "description": "Staging Server",
      "variables": {
        "store_id": {
          "default": "store_id",
          "description": "Store ID"
        }
      }
    },
    {
      "url": "https://prod.api.commercengine.io/api/v1/{store_id}/admin",
      "description": "Prod Server",
      "variables": {
        "store_id": {
          "default": "store_id",
          "description": "Store ID"
        }
      }
    }
  ],
  "tags": [
    {
      "name": "Analytics",
      "description": "Analytics"
    },
    {
      "name": "Catalog",
      "description": "Catalog"
    },
    {
      "name": "Coupons & promotions",
      "description": "Coupons & promotions"
    },
    {
      "name": "Customers",
      "description": "Customers"
    },
    {
      "name": "Filter Options",
      "description": "Filter Options"
    },
    {
      "name": "Inventories",
      "description": "Inventories"
    },
    {
      "name": "Marketplace",
      "description": "Marketplace"
    },
    {
      "name": "Marketplace Catalog",
      "description": "Marketplace Catalog"
    },
    {
      "name": "Media Gallery",
      "description": "Media Gallery"
    },
    {
      "name": "Metrics",
      "description": "Metrics"
    },
    {
      "name": "Orders",
      "description": "Orders"
    },
    {
      "name": "Payments",
      "description": "Payments"
    },
    {
      "name": "Payouts",
      "description": "Payouts"
    },
    {
      "name": "POS",
      "description": "POS"
    },
    {
      "name": "Segments",
      "description": "Segments"
    },
    {
      "name": "Shipping",
      "description": "Shipping"
    },
    {
      "name": "SSE",
      "description": "SSE"
    },
    {
      "name": "Store",
      "description": "Store"
    },
    {
      "name": "Webhooks",
      "description": "Webhooks"
    }
  ],
  "paths": {
    "/analytics/charts": {
      "get": {
        "tags": [
          "Analytics"
        ],
        "operationId": "get-analytics-charts",
        "summary": "Retrieve analytics chart data",
        "description": "Runs the chart query for the given `chart_type` and returns `content.stats`. Row shape varies by chart; `business_name` appears on `top_customers` rows only.",
        "parameters": [
          {
            "name": "chart_type",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "event_stats",
                "visitor_stats",
                "page_view_stats",
                "top_customers",
                "associated_campaigns",
                "ce_item_stats",
                "overall_shipping_performance",
                "average_time_between_subsequent_purchases",
                "product_checkout_funnel",
                "checkout_funnel"
              ]
            }
          },
          {
            "name": "date_from",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          },
          {
            "name": "preset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "query_type",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "metrics",
                "stats"
              ]
            }
          },
          {
            "name": "seller_id",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "timezone",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/AnalyticsChartsInfo"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/analytics/dynamic-query": {
      "post": {
        "tags": [
          "Analytics"
        ],
        "operationId": "execute-dynamic-query",
        "summary": "Dynamic query",
        "description": "Retrive analytics data as per dynamic query passed.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/AnalyticsStats"
                  },
                  {
                    "$ref": "#/components/schemas/AnalyticsRecords"
                  }
                ]
              },
              "examples": {
                "Example 1": {
                  "value": {
                    "schema_name": "analytics_log",
                    "query_type": "stats",
                    "query": {
                      "aggregate": [
                        {
                          "type": "COUNT",
                          "field_name": "id",
                          "alias": "events_count"
                        }
                      ],
                      "group_by": {
                        "fields": "origin_source",
                        "having_condition": [
                          {
                            "field_name": "events_count",
                            "operator": "greater",
                            "value": 2000
                          }
                        ]
                      },
                      "filters": [
                        {
                          "field_name": "origin_source",
                          "operator": "is-not-empty",
                          "value": null
                        }
                      ],
                      "sort_by": {
                        "origin_source": "asc"
                      },
                      "limit": 25,
                      "offset": 0
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "oneOf": [
                        {
                          "$ref": "#/components/schemas/DynamicQueryRecords"
                        },
                        {
                          "$ref": "#/components/schemas/DynamicQueryStatsData"
                        },
                        {
                          "$ref": "#/components/schemas/DynamicQueryMetricsData"
                        }
                      ]
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/analytics/events/{id}": {
      "get": {
        "tags": [
          "Analytics"
        ],
        "operationId": "get-analytics-event-detail",
        "summary": "Retrieve an event detail",
        "description": "Retrieve an event detail.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "event_detail": {
                          "description": "rows returned by raw query passed in request body.",
                          "$ref": "#/components/schemas/AnalyticsEventSchemaDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "event id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/analytics/raw-query": {
      "post": {
        "tags": [
          "Analytics"
        ],
        "operationId": "execute-raw-query",
        "summary": "Raw query",
        "description": "Executes the raw query and returns rows in `content.data`. Column names and values depend on the query.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "raw_query"
                ],
                "properties": {
                  "raw_query": {
                    "type": "string"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "$ref": "#/components/schemas/AnalyticsRawQueryInfo"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/analytics/sessions": {
      "get": {
        "tags": [
          "Analytics"
        ],
        "operationId": "list-analytics-sessions",
        "summary": "List analytics sessions",
        "description": "Lists analytics sessions. Optionally filter by `user_id`. Returns paginated session objects.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "name": "user_id",
            "in": "query",
            "description": "Filter sessions by the tracked user. Omit to retrieve all sessions.",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "sessions": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AnalyticsSession"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/analytics/sessions/{id}": {
      "get": {
        "tags": [
          "Analytics"
        ],
        "operationId": "get-analytics-session",
        "summary": "Retrieve a analytics session",
        "description": "Retrieves a session and its paginated activity list.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "session": {
                          "$ref": "#/components/schemas/AnalyticsSession"
                        },
                        "activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AnalyticsActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "session id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/attribute-sets": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-attribute-sets",
        "summary": "List all attribute sets",
        "description": "list all attribute sets",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute_sets": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AttributeSet"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-attribute-set",
        "summary": "Create attribute set",
        "description": "create attribute set",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateAttributeSet"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute_set": {
                          "$ref": "#/components/schemas/AttributeSet"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      }
    },
    "/catalog/attribute-sets/{id}": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-attribute-set",
        "summary": "Retrieve attribute set",
        "description": "retrieve attribute set",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute_set": {
                          "$ref": "#/components/schemas/AttributeSet"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "put": {
        "tags": [
          "Catalog"
        ],
        "operationId": "update-attribute-set",
        "summary": "Update attribute set",
        "description": "update attribute set",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateAttributeSet"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute_set": {
                          "$ref": "#/components/schemas/AttributeSet"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "delete": {
        "tags": [
          "Catalog"
        ],
        "operationId": "delete-attribute-set",
        "summary": "Delete attribute set",
        "description": "delete attribute set",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "attribute set id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/attributes": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-product-attributes",
        "summary": "List all attributes",
        "description": "list all attributes",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attributes": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Attribute"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-product-attribute",
        "summary": "Create attribute",
        "description": "create attribute",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateAttribute"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute": {
                          "$ref": "#/components/schemas/Attribute"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      }
    },
    "/catalog/attributes/{id}": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-product-attribute",
        "summary": "Retrieve attribute",
        "description": "retrieve attribute",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute": {
                          "$ref": "#/components/schemas/Attribute"
                        },
                        "products": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductBasicDetail"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "put": {
        "tags": [
          "Catalog"
        ],
        "operationId": "update-product-attribute",
        "summary": "Update attribute",
        "description": "update attribute",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Attribute"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute": {
                          "$ref": "#/components/schemas/Attribute"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "delete": {
        "tags": [
          "Catalog"
        ],
        "operationId": "delete-product-attribute",
        "summary": "Delete attribute",
        "description": "delete attribute",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "attribute ulid",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/categories": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-categories",
        "summary": "List all categories",
        "description": "list all categories",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "name": "category_name",
            "in": "query",
            "description": "use to check duplicity",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "nested_level",
            "in": "query",
            "description": "to return categories upto specified nested level",
            "schema": {
              "type": "integer"
            }
          },
          {
            "name": "parent_category_id",
            "in": "query",
            "description": "to return child categories",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "categories": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Category"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-category",
        "summary": "Create category",
        "description": "create new category",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateCategory"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "category": {
                          "$ref": "#/components/schemas/CategoryDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      }
    },
    "/catalog/categories/{id}": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-category",
        "summary": "Retrieve category",
        "description": "retrieve category",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "category": {
                          "$ref": "#/components/schemas/CategoryDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "put": {
        "tags": [
          "Catalog"
        ],
        "operationId": "update-category",
        "summary": "Update category",
        "description": "update category",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CategoryDetail"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "category": {
                          "$ref": "#/components/schemas/CategoryDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "delete": {
        "tags": [
          "Catalog"
        ],
        "operationId": "delete-category",
        "summary": "Delete category",
        "description": "delete category",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "category id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/categories/{id}/attributes": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-category-attributes",
        "summary": "Retrieve category attributes",
        "description": "retrieve category attributes",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "category_attribute": {
                          "$ref": "#/components/schemas/CategoryAttribute"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-update-category-attributes",
        "summary": "Create or update category attributes",
        "description": "create or update category attributes",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateUpdateCategoryAttribute"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "category_attribute": {
                          "$ref": "#/components/schemas/CategoryAttribute"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "category id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-catalog-filter-options",
        "summary": "List all catalog filter options",
        "description": "List all filter options for catalog listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/catalog/integration-sync": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-sync-status",
        "summary": "Retrive data sync detail",
        "description": "Retrive data sync detail",
        "parameters": [
          {
            "name": "destination",
            "in": "query",
            "description": "integration destination",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "datocms"
              ]
            }
          },
          {
            "name": "model",
            "in": "query",
            "description": "model",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "product",
                "category",
                "bundle"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/IntegrationSyncInfo"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "trigger-sync",
        "summary": "Create request for data syncing",
        "description": "Create request for data syncing",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/IntegrationSyncRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/IntegrationSyncResult"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/catalog/integration-sync/{item_id}": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-item-sync",
        "summary": "Retrive item sync detail",
        "description": "Retrive item sync detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "sync": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "destination_name": {
                                "type": "string"
                              },
                              "destination_item_id": {
                                "type": "string"
                              },
                              "last_sync_time": {
                                "type": "string",
                                "format": "date-time"
                              }
                            }
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "item_id",
          "in": "path",
          "description": "commercengine id of a product, category, variant",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/integration-sync/{item_id}/activity": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-sync-activity",
        "summary": "List all item sync activity",
        "description": "List all item sync activity",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "sync_activity": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "destination_name": {
                                "type": "string"
                              },
                              "destination_item_id": {
                                "type": "string"
                              },
                              "status": {
                                "type": "string"
                              },
                              "status_code": {
                                "type": "string"
                              },
                              "request_json": {
                                "type": "object"
                              },
                              "response_json": {
                                "type": "object"
                              },
                              "created_at": {
                                "type": "string",
                                "format": "date-time"
                              }
                            }
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "item_id",
          "in": "path",
          "description": "commercengine id of a product, category, variant",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/inventories": {
      "get": {
        "tags": [
          "Inventories"
        ],
        "operationId": "list-inventory",
        "summary": "List all inventories",
        "description": "List all inventories",
        "parameters": [
          {
            "$ref": "#/components/parameters/dataView"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventories": {
                          "type": "array",
                          "items": {
                            "oneOf": [
                              {
                                "$ref": "#/components/schemas/ItemWiseInventory"
                              },
                              {
                                "$ref": "#/components/schemas/LotBatchWiseInventory"
                              }
                            ]
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/catalog/inventories/activites": {
      "get": {
        "tags": [
          "Inventories"
        ],
        "operationId": "list-inventory-activity",
        "summary": "List all inventories activities",
        "description": "Lists all inventory related activities of stock movements. This provides a comprehensive audit trail of inventory operations such as receiving, reservations, adjustments, transfers, and sales.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/InventoryActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/catalog/inventories/detail": {
      "get": {
        "tags": [
          "Inventories"
        ],
        "operationId": "list-inventory-detail",
        "summary": "Retrieve inventory detail",
        "description": "Retrieves inventory details for a specific product, product variant, or lot/batch based on the parameters provided.",
        "parameters": [
          {
            "name": "lot_batch",
            "in": "query",
            "description": "lot batch of selected productor or variant.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "product_id",
            "in": "query",
            "description": "Product Id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "variant_id",
            "in": "query",
            "description": "Variant Id",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory": {
                          "$ref": "#/components/schemas/InventoryDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/catalog/jobs": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-catalog-jobs",
        "summary": "List catalog jobs",
        "description": "List catalog jobs",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "jobs": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CatalogJob"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-catalog-job",
        "summary": "Create catalog job",
        "description": "Create a new catalog job for bulk product import or marketplace sync.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/ImportBulkProducts"
                  },
                  {
                    "$ref": "#/components/schemas/SyncProductToMarketplace"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/CatalogJobDetail"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      }
    },
    "/catalog/jobs/{job_id}": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-catalog-job",
        "summary": "Get catalog job",
        "description": "Get catalog job",
        "parameters": [
          {
            "name": "job_id",
            "in": "path",
            "description": "Job ID",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CatalogJobDetail"
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      }
    },
    "/catalog/marketplace-listings": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-marketplace-listings",
        "summary": "List all marketplace listings",
        "description": "List all marketplace listings",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "items": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/MarketplaceItem"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-update-marketplace-listing",
        "summary": "Create or update marketplace listing",
        "description": "Create or update marketplace listing",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateUpdateMarketplaceItem"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "item": {
                          "$ref": "#/components/schemas/MarketplaceItem"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      }
    },
    "/catalog/marketplace-listings/{marketplace_id}/list": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-products-on-marketplace",
        "summary": "List products on marketplace",
        "description": "List products on marketplace",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "marketplace_id",
          "in": "path",
          "description": "Marketplace ID",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/marketplace-listings/{marketplace_id}/remove": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "remove-marketplace-listing",
        "summary": "Remove marketplace listing",
        "description": "Remove marketplace listing",
        "parameters": [
          {
            "name": "marketplace_id",
            "in": "path",
            "description": "Marketplace ID",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RemoveMarketplaceListing"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      }
    },
    "/catalog/marketplace-listings/{marketplace_id}/sync": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "sync-product-on-marketplace",
        "summary": "Sync product on marketplace",
        "description": "Sync product on marketplace",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "product_id"
                ],
                "properties": {
                  "product_id": {
                    "type": "string"
                  },
                  "variant_id": {
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "marketplace_id",
          "in": "path",
          "description": "Marketplace ID",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/marketplace-listings/{marketplace_id}/unlist": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "unlist-products-on-marketplace",
        "summary": "Unlist products on marketplace",
        "description": "Unlist products on marketplace",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "marketplace_id",
          "in": "path",
          "description": "Marketplace ID",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/marketplace/products": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "list-marketplace-products",
        "summary": "List all products",
        "description": "list all products",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "name": "active",
            "in": "query",
            "description": "active flag",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "products": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Product"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": []
    },
    "/catalog/marketplace/products-channels": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "list-marketplace-products-channels",
        "summary": "List all products channels",
        "description": "List all products associated with channels.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "items": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductChannel"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "post": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "add-marketplace-products-channels",
        "summary": "Add products channels",
        "description": "Add channels to the specified products.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id",
                    "variant_id",
                    "channel_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "channel_id": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/catalog/marketplace/products/check-inventory": {
      "post": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "check-marketplace-product-inventory",
        "summary": "Check inventory",
        "description": "Retrieve products and variants inventory as per product ids and variant ids provided. To be used in S2S API call only.",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "products"
                ],
                "properties": {
                  "products": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "required": [
                        "product_id",
                        "variant_id",
                        "quantity"
                      ],
                      "properties": {
                        "product_id": {
                          "type": "string"
                        },
                        "variant_id": {
                          "type": "string"
                        },
                        "quantity": {
                          "type": "integer"
                        }
                      }
                    }
                  },
                  "warehouse_id": {
                    "description": "Optional: Provide array of warehouse id to check inventory for a specific warehouses.",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/InventoryCheckResponse"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": []
    },
    "/catalog/marketplace/products/publish": {
      "post": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "publish-products",
        "summary": "Publish products",
        "description": "Publish products",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": []
    },
    "/catalog/marketplace/products/stock-in": {
      "post": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "stock-in-marketplace-products",
        "summary": "Stock in products or variants",
        "description": "Marks the provided products/variants as in stock for storefront availability.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id",
                    "variant_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Inventory status updated successfully."
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/catalog/marketplace/products/stock-out": {
      "post": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "stock-out-marketplace-products",
        "summary": "Stock out products or variants",
        "description": "Marks the provided products/variants as out of stock for storefront availability.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id",
                    "variant_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Inventory status updated successfully."
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/catalog/marketplace/products/unpublish": {
      "post": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "unpublish-products",
        "summary": "Unpublish products",
        "description": "Unpublish products",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": []
    },
    "/catalog/marketplace/products/{id}": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "get-marketplace-product",
        "summary": "Retrieve product details",
        "description": "Retrieve product details",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "product": {
                          "$ref": "#/components/schemas/ProductDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/marketplace/products/{id}/inventory": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "get-marketplace-inventory",
        "summary": "Retrieve product inventory",
        "description": "Retrieve product inventory",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductInventory"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "update-marketplace-inventory",
        "summary": "Update Product Inventory",
        "description": "Update product inventory",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductInventory"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductInventory"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/marketplace/products/{id}/inventory-activity": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "list-marketplace-product-inventory-activity",
        "summary": "List all inventory activities",
        "description": "List all inventory activities",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory_activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductInventoryActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "create-marketplace-inventory-activity",
        "summary": "Create inventory activity",
        "description": "Create inventory activity",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProductInventoryActivity"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory_activity": {
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/ProductInventoryActivity"
                            },
                            {
                              "type": "object",
                              "properties": {
                                "warehouse": {
                                  "$ref": "#/components/schemas/Warehouse"
                                }
                              }
                            }
                          ]
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/marketplace/products/{id}/variants": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "list-marketplace-variants",
        "summary": "List all product variants",
        "description": "List all product variants",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "variants": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Variant"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/marketplace/products/{product_id}/reviews": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "list-marketplace-reviews",
        "summary": "List product reviews",
        "description": "List product reviews",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "reviews": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductReview"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "product_id",
          "in": "path",
          "description": "product Ulid",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/marketplace/products/{product_id}/reviews/{id}": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "get-marketplace-review",
        "summary": "Retrieve product review",
        "description": "Retrieve product review",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "review": {
                          "$ref": "#/components/schemas/ProductReview"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "put": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "update-marketplace-review",
        "summary": "Update product review",
        "description": "Update product review",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "status"
                ],
                "properties": {
                  "status": {
                    "enum": [
                      "pending",
                      "approved",
                      "rejected",
                      "archived"
                    ]
                  },
                  "tags": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "is_featured": {
                    "type": "boolean"
                  },
                  "review_reply": {
                    "type": "string"
                  },
                  "images": {
                    "description": "array of file ids",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "videos": {
                    "description": "array of file ids",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "review": {
                          "$ref": "#/components/schemas/ProductReview"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "review Ulid",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "product_id",
          "in": "path",
          "description": "product Ulid",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/metrics/product-analytics": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-product-metrics",
        "summary": "Retrieve product analytics stats",
        "description": "Retrieve product analytics stats",
        "parameters": [
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "description": "for aggregating data",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          },
          {
            "name": "sku",
            "in": "query",
            "description": "To retrieve analytics stats of a particular sku.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "user_id",
            "in": "query",
            "description": "To retrieve analytics stats of a particular user. ",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "stats": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "metrics": {
                                "type": "object",
                                "$ref": "#/components/schemas/ProductAnalyticsStats"
                              }
                            }
                          }
                        },
                        "lifetime_stats": {
                          "$ref": "#/components/schemas/ProductAnalyticsStats"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/catalog/products": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-products",
        "summary": "List all products",
        "description": "list all products",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "name": "active",
            "in": "query",
            "description": "active flag",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "products": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Product"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-product",
        "summary": "Create product",
        "description": "This endpoint allows you to create a draft product by specifying its name and type. The product is created in its preliminary stage. All additional product details, including descriptions, pricing, and images, etc, can be updated using the Update Product API endpoint.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateDraftProduct"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "product": {
                          "$ref": "#/components/schemas/ProductDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": []
    },
    "/catalog/products-channels": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-products-channels",
        "summary": "List all products channels",
        "description": "List all products associated with channels.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "items": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductChannel"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "add-products-channels",
        "summary": "Add products channels",
        "description": "Add channels to the specified products. Status of product/variant are linked to the channels. When channels are added or removed, the status of the product/variant is auto updated. Only storefront type channels are supported. Marketplace channels are added/removed from the marketplace list/unlist endpoints.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id",
                    "variant_id",
                    "channel_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "channel_id": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/catalog/products/assign-category": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "assign-category-to-products",
        "summary": "Assign a category to products",
        "description": "Assigns the specified category to the selected products.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AssignCategoryToProductsRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Category assignment completed.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      }
    },
    "/catalog/products/bulk-delete": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "bulk-delete-products",
        "summary": "Bulk delete products",
        "description": "Deleting multiple products in single request.",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "product_id"
                ],
                "properties": {
                  "product_id": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": []
    },
    "/catalog/products/bulk-update": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "bulk-update-products",
        "summary": "Bulk update products",
        "description": "Update specific fields of multiple products in single request.",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "product_id"
                ],
                "properties": {
                  "product_id": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "category_id": {
                    "description": "if null value is passed, then categories will be removed from the specified products.",
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "string"
                    }
                  },
                  "status": {
                    "enum": [
                      "active",
                      "inactive"
                    ]
                  },
                  "stock_available": {
                    "type": "boolean"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": []
    },
    "/catalog/products/check-inventory": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "check-product-inventory",
        "summary": "Check inventory",
        "description": "Retrieve products and variants inventory as per product ids and variant ids provided. To be used in S2S API call only.",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "products"
                ],
                "properties": {
                  "products": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "required": [
                        "product_id",
                        "variant_id",
                        "quantity"
                      ],
                      "properties": {
                        "product_id": {
                          "type": "string"
                        },
                        "variant_id": {
                          "type": "string"
                        },
                        "quantity": {
                          "type": "integer"
                        }
                      }
                    }
                  },
                  "warehouse_id": {
                    "description": "Optional: Provide array of warehouse id to check inventory for a specific warehouses.",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/InventoryCheckResponse"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": []
    },
    "/catalog/products/stock-in": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "stock-in-products",
        "summary": "Stock in products or variants",
        "description": "Marks the provided products/variants as in stock for storefront availability.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id",
                    "variant_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Inventory status updated successfully."
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/catalog/products/stock-out": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "stock-out-products",
        "summary": "Stock out products or variants",
        "description": "Marks the provided products/variants as out of stock for storefront availability.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id",
                    "variant_id"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Inventory status updated successfully."
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/catalog/products/{id}": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-product",
        "summary": "Retrieve product details",
        "description": "Retrieve product details",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "product": {
                          "$ref": "#/components/schemas/ProductDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "put": {
        "tags": [
          "Catalog"
        ],
        "operationId": "update-product",
        "summary": "Update product details",
        "description": "This API endpoint allows for partial updates to product details, enabling you to modify specific attributes like pricing, descriptions, images, promotions, subscriptions, and more, without altering the entire product record. To optimize performance, please include only the fields that need updating. For fields that contain objects or arrays (e.g., shipping, promotions, images, pricing, categories, attributes, bundle_items, related_products), send the complete data for these fields, as the existing data will be replaced entirely.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateProduct"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "product": {
                          "$ref": "#/components/schemas/ProductDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "delete": {
        "tags": [
          "Catalog"
        ],
        "operationId": "delete-product",
        "summary": "Delete product",
        "description": "Delete product",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/products/{id}/inventory": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-inventory",
        "summary": "Retrieve product inventory",
        "description": "Retrieve product inventory",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductInventory"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "update-inventory",
        "summary": "Update Product Inventory",
        "description": "Update product inventory",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductInventory"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductInventory"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/products/{id}/inventory-activity": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-product-inventory-activity",
        "summary": "List all inventory activities",
        "description": "List all inventory activities",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory_activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductInventoryActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-inventory-activity",
        "summary": "Create inventory activity",
        "description": "Create inventory activity",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProductInventoryActivity"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory_activity": {
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/ProductInventoryActivity"
                            },
                            {
                              "type": "object",
                              "properties": {
                                "warehouse": {
                                  "$ref": "#/components/schemas/Warehouse"
                                }
                              }
                            }
                          ]
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/products/{id}/shipper-boxes": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-shipper-boxes",
        "summary": "List all shipper boxes",
        "description": "List all shipper boxes",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipper_boxes": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ShipperBox"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/products/{id}/variants": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-variants",
        "summary": "List all product variants",
        "description": "List all product variants",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "variants": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Variant"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "post": {
        "tags": [
          "Catalog"
        ],
        "operationId": "create-variant",
        "summary": "Create variant",
        "description": "Create variant",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CreateVariant"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "variants": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/VariantDetail"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/products/{id}/variants/bulk-update": {
      "put": {
        "tags": [
          "Catalog"
        ],
        "operationId": "bulk-update-variants",
        "summary": "Update variants in bulk",
        "description": "Update shipping and packaging details of multiple variants.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/VariantBulkUpdate"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "variants": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/VariantBulkUpdate"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/products/{id}/variants/{variant_id}": {
      "get": {
        "tags": [
          "Marketplace Catalog"
        ],
        "operationId": "get-marketplace-variant",
        "summary": "Retrieve a variant details",
        "description": "Retrieve a product variant details",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "variant": {
                          "$ref": "#/components/schemas/VariantDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Catalog"
        ],
        "operationId": "update-variant",
        "summary": "Update a variant",
        "description": "Update a variant",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateVariant"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "variant": {
                          "$ref": "#/components/schemas/VariantDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Catalog"
        ],
        "operationId": "delete-variant",
        "summary": "Delete a variant",
        "description": "Delete a variant",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "product id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "variant_id",
          "in": "path",
          "description": "variant id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/products/{product_id}/reviews": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-reviews",
        "summary": "List product reviews",
        "description": "List product reviews",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "reviews": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductReview"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "product_id",
          "in": "path",
          "description": "product Ulid",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/products/{product_id}/reviews/{id}": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "get-review",
        "summary": "Retrieve product review",
        "description": "Retrieve product review",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "review": {
                          "$ref": "#/components/schemas/ProductReview"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "put": {
        "tags": [
          "Catalog"
        ],
        "operationId": "update-review",
        "summary": "Update product review",
        "description": "Update product review",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "status"
                ],
                "properties": {
                  "status": {
                    "enum": [
                      "pending",
                      "approved",
                      "rejected",
                      "archived"
                    ]
                  },
                  "tags": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "is_featured": {
                    "type": "boolean"
                  },
                  "review_reply": {
                    "type": "string"
                  },
                  "images": {
                    "description": "array of file ids",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "videos": {
                    "description": "array of file ids",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "review": {
                          "$ref": "#/components/schemas/ProductReview"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Catalog"
        ],
        "operationId": "delete-review",
        "summary": "Delete product review",
        "description": "Delete product review",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Authorization": []
          }
        ]
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "review Ulid",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "product_id",
          "in": "path",
          "description": "product Ulid",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/catalog/skus": {
      "get": {
        "tags": [
          "Catalog"
        ],
        "operationId": "list-skus",
        "summary": "List all SKUs",
        "description": "List all SKUs",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "skus": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ProductBasicDetail"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/customers": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customers",
        "summary": "List all customers",
        "description": "List all customers",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customers": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CustomerListItem"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-customer",
        "summary": "Create customer",
        "description": "Creates a customer and returns the created `Customer` object. Set `customer_group_id` to place the customer in a Customer Group, which drives group-specific pricing and promotions.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateCustomer"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customer": {
                          "$ref": "#/components/schemas/Customer"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/customers/attributes": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customer-attributes",
        "summary": "List all attributes",
        "description": "List all attributes",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attributes": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CustomerAttribute"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-customer-attribute",
        "summary": "Create an attribute",
        "description": "Create an attribute",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CustomerAttribute"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute": {
                          "$ref": "#/components/schemas/CustomerAttribute"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/customers/attributes/{id}": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-customer-attribute",
        "summary": "Retrieve attribute detail",
        "description": "Retrieve attribute detail",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute": {
                          "$ref": "#/components/schemas/CustomerAttribute"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-customer-attribute",
        "summary": "Update an attribute",
        "description": "Update an attribute",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateCustomerAttribute"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attribute": {
                          "$ref": "#/components/schemas/CustomerAttribute"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Customers"
        ],
        "operationId": "delete-customer-attribute",
        "summary": "Delete an attribute",
        "description": "Delete an attribute",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "attribute id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/credit-line-eligibility": {
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "set-customer-credit-line-eligibility",
        "summary": "Set credit line eligibility",
        "description": "Bulk-provisions approved spending limits for multiple customers, making each eligible to create a mandate.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "customer_id": {
                      "description": "customer id.",
                      "type": "string"
                    },
                    "mandate_per_order_limit": {
                      "description": "Upper cap on the mandate amount the customer can authorize.",
                      "type": "number"
                    },
                    "total_credit_limit": {
                      "description": "Spending limit approved for the customer. Cannot exceed `mandate_per_order_limit`.",
                      "type": "number"
                    },
                    "is_eligible": {
                      "description": "Whether the customer is eligible to create a mandate.",
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "customer_id"
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/customers/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-customers-filter-options",
        "summary": "List all customers filter options",
        "description": "List all filter options for customers listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/customers/loyalty-members": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-loyalty-members",
        "summary": "List all loyalty members",
        "description": "List all loyalty members",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_members": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/LoyaltyMember"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/customers/loyalty-members/change-tier": {
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "change-loyalty-tier",
        "summary": "Change loyalty tier",
        "description": "Change loyalty tier for customers",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "tier_id": {
                      "type": "string"
                    },
                    "customer_id": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "tier_id",
                    "customer_id"
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/customers/loyalty-program": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-loyalty-programs",
        "summary": "List all loyalty program",
        "description": "List all loyalty program",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_programs": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/LoyaltyProgram"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-loyalty-program",
        "summary": "Create loyalty program",
        "description": "Creates a new loyalty program with default status set to `draft`. Only one loyalty program can be in `draft` status at a time. To schedule a loyalty program for future, provide a future datetime value in `starts_at`. Use the activate endpoint to make it active or scheduled. Returns the created `LoyaltyProgram` object.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoyaltyProgram"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_program": {
                          "$ref": "#/components/schemas/LoyaltyProgram"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/customers/loyalty-program/{id}": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-loyalty-program-detail",
        "summary": "Retrieve loyalty program detail",
        "description": "Retrieve loyalty program detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_program": {
                          "$ref": "#/components/schemas/LoyaltyProgram"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-loyalty-program",
        "summary": "Update loyalty program detail",
        "description": "Update loyalty program detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoyaltyProgram"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_program": {
                          "$ref": "#/components/schemas/LoyaltyProgram"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Customers"
        ],
        "operationId": "delete-loyalty-program",
        "summary": "Delete loyalty program",
        "description": "Delete loyalty program",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "loyalty program id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/loyalty-program/{id}/activate": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "activate-loyalty-program",
        "summary": "Activate loyalty program",
        "description": "Activates or schedules the loyalty program, setting its status to `active` or `scheduled`. Only one loyalty program can be `active` at a time, and only one can be `scheduled` at a time. Can only be used when the current status is `draft` or `inactive`. Returns the updated `LoyaltyProgram` object.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "loyalty program id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_program": {
                          "$ref": "#/components/schemas/LoyaltyProgram"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/customers/loyalty-program/{id}/deactivate": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "deactivate-loyalty-program",
        "summary": "Deactivate loyalty program",
        "description": "Deactivates the loyalty program, setting its status to `inactive`. Can only be used when the current status is `active`, `scheduled`, or `paused`. Returns the updated `LoyaltyProgram` object.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "loyalty program id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_program": {
                          "$ref": "#/components/schemas/LoyaltyProgram"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/customers/loyalty-program/{id}/pause": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "pause-loyalty-program",
        "summary": "Pause loyalty program",
        "description": "Pauses the loyalty program, setting its status to `paused`. Can only be used when the current status is `active` or `paused`. Returns the updated `LoyaltyProgram` object.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "loyalty program id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "pause_starts_at": {
                    "description": "When to start the pause. If not specified, pauses immediately.",
                    "type": "string",
                    "format": "date-time"
                  },
                  "pause_ends_at": {
                    "description": "When to end the pause. If not specified, remains paused until resumed.",
                    "type": "string",
                    "format": "date-time"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_program": {
                          "$ref": "#/components/schemas/LoyaltyProgram"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/customers/loyalty-program/{id}/resume": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "resume-loyalty-program",
        "summary": "Resume loyalty program",
        "description": "Resumes a paused loyalty program, setting its status to `active`. Can only be used when the current status is `paused`. Returns the updated `LoyaltyProgram` object.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "loyalty program id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "loyalty_program": {
                          "$ref": "#/components/schemas/LoyaltyProgram"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/customers/metrics/stats": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-customer-metrics",
        "summary": "Retrieve customers stats",
        "description": "Retrieve customers stats",
        "parameters": [
          {
            "name": "customer_id",
            "in": "query",
            "description": "To retrieve stats of a particular customer.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "description": "for aggregating data",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "stats": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "metrics": {
                                "type": "object",
                                "$ref": "#/components/schemas/CustomerStats"
                              }
                            }
                          }
                        },
                        "lifetime_stats": {
                          "$ref": "#/components/schemas/CustomerStats"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/customers/segments": {
      "get": {
        "tags": [
          "Segments"
        ],
        "operationId": "list-segments",
        "summary": "List all segments",
        "description": "List all segments",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "name": "segment_type",
            "in": "query",
            "description": "to filter segments by type",
            "schema": {
              "type": "string",
              "enum": [
                "dynamic",
                "manual"
              ]
            }
          },
          {
            "name": "status",
            "in": "query",
            "description": "to filter segments by status",
            "schema": {
              "type": "string",
              "enum": [
                "draft",
                "active",
                "inactive",
                "archived"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "segments": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Segment"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Segments"
        ],
        "operationId": "create-segment",
        "summary": "Create a segment",
        "description": "Create a segment. In case of dynamic segment, conditions field should accept only the json format specified. Proper validation message should be returned in case different jsob object is provided.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SegmentDetail"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "segment": {
                          "$ref": "#/components/schemas/SegmentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/customers/segments/{id}": {
      "get": {
        "tags": [
          "Segments"
        ],
        "operationId": "get-segment-detail",
        "summary": "Retrieve segment detail",
        "description": "Retrieve segment detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "segment": {
                          "$ref": "#/components/schemas/SegmentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Segments"
        ],
        "operationId": "update-segment",
        "summary": "Update segment detail",
        "description": "Update segment detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SegmentDetail"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "segment": {
                          "$ref": "#/components/schemas/SegmentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Segments"
        ],
        "operationId": "delete-segment",
        "summary": "Delete segment",
        "description": "Delete segment if not used in anywhere. ",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "segment id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/segments/{id}/ad-audiences": {
      "post": {
        "tags": [
          "Segments"
        ],
        "operationId": "create-ad-audience",
        "summary": "Create ad-audience",
        "description": "Create Ad-audience",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SegmentAdAudience"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "ad_audience": {
                          "$ref": "#/components/schemas/SegmentAdAudience"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "segment id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/segments/{id}/ad-audiences/{ad_audience_id}": {
      "get": {
        "tags": [
          "Segments"
        ],
        "operationId": "get-ad-audience-detail",
        "summary": "Retrieve ad-audience detail",
        "description": "Retrieve ad-audience detail",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "ad_audience": {
                          "$ref": "#/components/schemas/SegmentAdAudience"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Segments"
        ],
        "operationId": "update-ad-audience",
        "summary": "Update ad-audience detail",
        "description": "Update ad-audience detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SegmentAdAudience"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "ad_audience": {
                          "$ref": "#/components/schemas/SegmentAdAudience"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Segments"
        ],
        "operationId": "delete-ad-audience",
        "summary": "Delete ad-audience",
        "description": "Delete ad-audience",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "ad_audience": {
                          "$ref": "#/components/schemas/SegmentAdAudience"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "ad_audience_id",
          "in": "path",
          "description": "ad audience id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "id",
          "in": "path",
          "description": "segment id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/segments/{id}/ad-audiences/{ad_audience_id}/sync-history": {
      "get": {
        "tags": [
          "Segments"
        ],
        "operationId": "get-ad-audience-sync-history",
        "summary": "List all ad-audience sync hisory",
        "description": "List all ad-audience sync hisory",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "sync_history": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/SegmentAdAudienceSyncHistory"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "ad_audience_id",
          "in": "path",
          "description": "ad audience id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "id",
          "in": "path",
          "description": "segment id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/segments/{id}/members": {
      "get": {
        "tags": [
          "Segments"
        ],
        "operationId": "list-segment-members",
        "summary": "List all segment members",
        "description": "List all segment members. Data will be fetched from clickhouse database, using raw sql written on clickhouse db tables by matching segment dynamic conditions or matching user id of manual segment.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "segment_members": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/SegmentMember"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Segments"
        ],
        "operationId": "update-segment-members",
        "summary": "Add segment members",
        "description": "Add segment members in manual segment type.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "email_id"
                ],
                "properties": {
                  "email_id": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Segments"
        ],
        "operationId": "delete-segment-members",
        "summary": "Delete segment members",
        "description": "Delete segment members in manual segment type.",
        "parameters": [
          {
            "name": "email_id",
            "in": "query",
            "description": "use comma to separate multple email ids. maximum limit - 50 email ids",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "segment id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/segments/{id}/members-metrics": {
      "get": {
        "tags": [
          "Segments"
        ],
        "operationId": "get-segment-members-metrics",
        "summary": "Retrieve members metrics",
        "description": "Retrieve members metrics. Data should be retrieved from clickhouse database using raw sql.",
        "parameters": [
          {
            "name": "from_date",
            "in": "query",
            "description": "from date",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "resolution",
            "in": "query",
            "description": "enum field. any of (daily, weekly). default daily",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "to_date",
            "in": "query",
            "description": "to date",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "metrics_data": {
                          "type": "object",
                          "properties": {
                            "opening": {
                              "type": "array",
                              "items": {
                                "type": "integer"
                              }
                            },
                            "total_in": {
                              "type": "array",
                              "items": {
                                "type": "integer"
                              }
                            },
                            "total_out": {
                              "type": "array",
                              "items": {
                                "type": "integer"
                              }
                            },
                            "balance": {
                              "type": "array",
                              "items": {
                                "type": "integer"
                              }
                            },
                            "from_date": {
                              "type": "string",
                              "format": "date"
                            },
                            "to_date": {
                              "type": "string",
                              "format": "date"
                            },
                            "resolution": {
                              "enum": [
                                "daily",
                                "weekly"
                              ]
                            }
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "segment id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/visitors": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-visitors",
        "summary": "List all visitors",
        "description": "List all visitors",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "visitors": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Visitor"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/customers/visitors/{id}": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-visitor-detail",
        "summary": "Retrieve visitor detail",
        "description": "Retrieve visitor detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "visitor": {
                          "$ref": "#/components/schemas/VisitorDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "visitor id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/visitors/{id}/activities": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-visitor-activity",
        "summary": "List all activities",
        "description": "List all activities",
        "parameters": [
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AnalyticsActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "visitor id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/visitors/{id}/attributes": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-visitor-attributes",
        "summary": "List all visitor attributes",
        "description": "List all visitor attributes",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attributes": {
                          "type": "array",
                          "items": {
                            "oneOf": [
                              {
                                "$ref": "#/components/schemas/StringAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/IntegerAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/NumberAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/BooleanAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/ListAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/ObjectAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/DateTimeAttribute"
                              }
                            ],
                            "type": "object"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-visitor-attribute",
        "summary": "Create an attribute",
        "description": "Create an attribute",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/StringAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/IntegerAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/NumberAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/BooleanAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/ListAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/ObjectAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/DateTimeAttribute"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "visitor id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/visitors/{id}/attributes/{attribute_id}": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-visitor-attribute",
        "summary": "Update visitor attribute",
        "description": "Update visitor attribute",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "value"
                ],
                "properties": {
                  "value": {
                    "oneOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "integer"
                      },
                      {
                        "type": "number"
                      },
                      {
                        "type": "boolean"
                      },
                      {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      {
                        "type": "object",
                        "additionalProperties": true
                      },
                      {
                        "type": "string",
                        "format": "date-time"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Customers"
        ],
        "operationId": "delete-visitor-attribute",
        "summary": "Delete visitor attribute",
        "description": "Delete visitor attribute",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "attribute_id",
          "in": "path",
          "description": "attribute id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "id",
          "in": "path",
          "description": "visitor id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/credit-balance": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-customer-credit-balance",
        "summary": "Get customer credit balance",
        "description": "Retrieves a customer's bank-transfer credit balance. Returns a `CustomerCreditBalance` with `received_amount`, `settled_amount`, and spendable `balance_amount`.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/CustomerCreditBalance"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/credit-line-balance": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-customer-credit-line-balance",
        "summary": "Get credit line balance",
        "description": "Retrieves the `CustomerCreditLineBalance` for a customer.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "is_eligible": {
                          "description": "Whether the customer is approved to use the credit line. `false` blocks new mandate creation and credit-line checkouts.",
                          "type": "boolean"
                        },
                        "credit_line_balance": {
                          "description": "The customer's latest credit-line balance. `null` when no balance has been provisioned yet.",
                          "oneOf": [
                            {
                              "$ref": "#/components/schemas/CustomerCreditLineBalance"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "is_eligible",
                        "credit_line_balance"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/mandate-debit-schedules": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customer-mandate-debit-schedules",
        "summary": "List mandate debit schedules",
        "description": "Retrieves the paginated list of `MandateDebitSchedule` entries for a customer across all mandates. Each entry represents a queued, executed, retried, or cancelled mandate-based debit attempt. Use optional `mandate_id` and `status` query parameters to narrow results.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "name": "mandate_id",
            "in": "query",
            "description": "Filter debit schedules to a specific `CustomerMandate` ID.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "in": "query",
            "description": "Filter debit schedules by execution status.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "scheduled",
                "debit-requested",
                "debit-success",
                "debit-failed",
                "cancelled",
                "awaiting-retry"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "debit_schedules": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/MandateDebitSchedule"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "required": [
                        "debit_schedules"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/mandates": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customer-mandates",
        "summary": "List all mandates",
        "description": "Retrieves the paginated list of `CustomerMandate` entries for a customer. Use the optional `status` query parameter to filter by mandate lifecycle state.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "name": "status",
            "in": "query",
            "description": "Filter mandates by lifecycle status.",
            "required": false,
            "schema": {
              "$ref": "#/components/schemas/MandateStatus"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "mandates": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CustomerMandate"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "required": [
                        "mandates"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/mandates/{mandate_id}": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-customer-mandate",
        "summary": "Get mandate",
        "description": "Retrieve a mandate for a given customer.",
        "parameters": [
          {
            "name": "sync",
            "in": "query",
            "description": "If true, sync the mandate status from the external mandate provider before returning.",
            "required": false,
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "mandate": {
                          "$ref": "#/components/schemas/CustomerMandate"
                        }
                      },
                      "required": [
                        "mandate"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "mandate_id",
          "in": "path",
          "description": "Mandate Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/mandates/{mandate_id}/activity": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customer-mandate-activity",
        "summary": "List mandate activity",
        "description": "Retrieves the paginated audit trail of lifecycle actions for a mandate — activation, pause, resume, revoke, and provider sync events. Each entry is a `MandateActivity` recording who performed the action, the outcome, and optional context in `details`.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "mandate_activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/MandateActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "required": [
                        "mandate_activities"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "mandate_id",
          "in": "path",
          "description": "Mandate Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/mandates/{mandate_id}/logs": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customer-mandate-logs",
        "summary": "List mandate logs",
        "description": "Retrieves the paginated request/response logs from the mandate provider for a given mandate. Use the optional `debit_schedule_id` query parameter to filter to a specific debit attempt.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "name": "debit_schedule_id",
            "in": "query",
            "description": "Filter logs to a specific `MandateDebitSchedule` ID.",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "mandate_logs": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/MandateLog"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "required": [
                        "mandate_logs"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "mandate_id",
          "in": "path",
          "description": "Mandate Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/mandates/{mandate_id}/pause": {
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "pause-customer-mandate",
        "summary": "Pause mandate",
        "description": "Pause a mandate for a given customer.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "mandate": {
                          "$ref": "#/components/schemas/CustomerMandate"
                        }
                      },
                      "required": [
                        "mandate"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "mandate_id",
          "in": "path",
          "description": "Mandate Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/mandates/{mandate_id}/resume": {
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "resume-customer-mandate",
        "summary": "Resume mandate",
        "description": "Resume a paused mandate for a given customer.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "mandate": {
                          "$ref": "#/components/schemas/CustomerMandate"
                        }
                      },
                      "required": [
                        "mandate"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "mandate_id",
          "in": "path",
          "description": "Mandate Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{customer_id}/mandates/{mandate_id}/revoke": {
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "revoke-customer-mandate",
        "summary": "Revoke mandate",
        "description": "Revoke a mandate for a given customer.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "mandate": {
                          "$ref": "#/components/schemas/CustomerMandate"
                        }
                      },
                      "required": [
                        "mandate"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "customer_id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "mandate_id",
          "in": "path",
          "description": "Mandate Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-customer-detail",
        "summary": "Retrieve customer detail",
        "description": "Retrieves the full `CustomerDetail` object, including `business`, `segments`, `addresses`, `banking`, `loyalty`, `notification_preferences`, and the assigned `customer_group_id`.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customer": {
                          "$ref": "#/components/schemas/CustomerDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-customer",
        "summary": "Update customer",
        "description": "Updates a customer's profile and returns the updated `CustomerDetail` object. Change `customer_group_id` to move the customer to a different Customer Group, which drives group-specific pricing and promotions.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateCustomer"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customer": {
                          "$ref": "#/components/schemas/CustomerDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/activities": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customer-activity",
        "summary": "List all activities",
        "description": "List all activities",
        "parameters": [
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AnalyticsActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/addresses": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-addresses",
        "summary": "List all addresses",
        "description": "List all addresses",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "addresses": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Address"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-address",
        "summary": "Create address",
        "description": "Create address",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "$ref": "#/components/schemas/Address"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "address": {
                          "$ref": "#/components/schemas/Address"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/addresses/{address_id}": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-address",
        "summary": "Update address detail",
        "description": "Update address detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "$ref": "#/components/schemas/Address"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "address": {
                          "$ref": "#/components/schemas/Address"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Customers"
        ],
        "operationId": "delete-address",
        "summary": "Delete address",
        "description": "Delete address",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "address_id",
          "in": "path",
          "description": "address id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/attributes": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-user-attributes",
        "summary": "List all customer attributes",
        "description": "List all customer attributes",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attributes": {
                          "type": "array",
                          "items": {
                            "oneOf": [
                              {
                                "$ref": "#/components/schemas/StringAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/IntegerAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/NumberAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/BooleanAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/ListAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/ObjectAttribute"
                              },
                              {
                                "$ref": "#/components/schemas/DateTimeAttribute"
                              }
                            ],
                            "type": "object"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-user-attribute",
        "summary": "Create an attribute",
        "description": "Create an attribute",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/StringAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/IntegerAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/NumberAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/BooleanAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/ListAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/ObjectAttribute"
                  },
                  {
                    "$ref": "#/components/schemas/DateTimeAttribute"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/attributes/{attribute_id}": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-user-attribute",
        "summary": "Update customer attribute",
        "description": "Update customer attribute",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "value": {
                    "oneOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "integer"
                      },
                      {
                        "type": "number"
                      },
                      {
                        "type": "boolean"
                      },
                      {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      {
                        "type": "object"
                      },
                      {
                        "type": "string",
                        "format": "date-time"
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Customers"
        ],
        "operationId": "delete-user-attribute",
        "summary": "Delete customer attribute",
        "description": "Delete customer attribute",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "attribute_id",
          "in": "path",
          "description": "attribute id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/authorized-sellers": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-customer-authorized-sellers",
        "summary": "Get authorized sellers for customer",
        "description": "Get authorized sellers for customer",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "authorized_sellers": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AuthorizedSellerInfo"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/authorized-sellers/{seller_id}/authorize": {
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "customer-authorize-seller",
        "summary": "Authorize a seller for a customer",
        "description": "Authorizes a seller for a customer. Use this for private sellers the customer can buy from.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "seller_id",
          "in": "path",
          "description": "Seller Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/authorized-sellers/{seller_id}/unauthorize": {
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "customer-unauthorize-seller",
        "summary": "Unauthorize a seller for a customer",
        "description": "Removes a seller from the customer's authorized seller list.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "seller_id",
          "in": "path",
          "description": "Seller Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/bank-accounts": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-bank-accounts",
        "summary": "List all bank accounts",
        "description": "List all bank accounts",
        "parameters": [
          {
            "name": "account_type",
            "in": "query",
            "description": "Filter bank accounts by direction.",
            "schema": {
              "type": "string",
              "enum": [
                "inbound",
                "outbound"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "bank_accounts": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CustomerBankAccount"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-bank-account",
        "summary": "Create a bank account",
        "description": "Add a new bank account for a customer. Returns the created `CustomerBankAccount` object.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateBankAccount"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "bank_account": {
                          "$ref": "#/components/schemas/CustomerBankAccount"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/bank-accounts/{bank_account_id}": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-bank-account-detail",
        "summary": "Retrieve bank account detail",
        "description": "Retrieve bank account detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "bank_account": {
                          "$ref": "#/components/schemas/CustomerBankAccount"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-bank-account",
        "summary": "Update a bank account",
        "description": "Update an existing bank account for a customer. Outbound accounts support full updates; inbound accounts can only update `is_default`. Returns the updated `CustomerBankAccount` object.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateBankAccount"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "bank_account": {
                          "$ref": "#/components/schemas/CustomerBankAccount"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Customers"
        ],
        "operationId": "delete-bank-account",
        "summary": "Delete bank account",
        "description": "Delete bank account",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "bank_account_id",
          "in": "path",
          "description": "bank account id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/documents": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customer-kyc-documents",
        "summary": "List all documents",
        "description": "List all documents",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "documents": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/KycDocument"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-customer-kyc-document",
        "summary": "Create document",
        "description": "Create document",
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "$ref": "#/components/schemas/KycDocument"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "document": {
                          "$ref": "#/components/schemas/KycDocument"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/documents/{document_id}": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-customer-kyc-document-detail",
        "summary": "Retrieve document detail",
        "description": "Retrieve document detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "document": {
                          "$ref": "#/components/schemas/KycDocument"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-customer-kyc-document",
        "summary": "Update document detail",
        "description": "Update document detail",
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "$ref": "#/components/schemas/UpdateKycDocument"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "document": {
                          "$ref": "#/components/schemas/KycDocument"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Customers"
        ],
        "operationId": "delete-customer-kyc-document",
        "summary": "Delete document",
        "description": "Delete document",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "document_id",
          "in": "path",
          "description": "document id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/loyalty-point-activities": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-loyalty-activity",
        "summary": "List all loyalty point activities",
        "description": "List all loyalty point activities",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/LoyaltyPointActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Customers"
        ],
        "operationId": "create-loyalty-activity",
        "summary": "Create loyalty point activity",
        "description": "Create loyalty point activity",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoyaltyPointActivity"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activity": {
                          "$ref": "#/components/schemas/LoyaltyPointActivity"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/loyalty-tier-activities": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-loyalty-tier-activity",
        "summary": "List all loyalty tier activities",
        "description": "List all loyalty tier activities",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/LoyaltyTierActivity"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/notification-preferences": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "get-user-notification-preferences",
        "summary": "Retrieve notification preferences",
        "description": "Retrieve notification preferences",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "notification_preferences": {
                          "$ref": "#/components/schemas/NotificationPreferences"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "update-user-notification-preferences",
        "summary": "Update notification preferences",
        "description": "Update notification preferences",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "$ref": "#/components/schemas/NotificationPreferences"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "notification_preferences": {
                          "$ref": "#/components/schemas/NotificationPreferences"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/users": {
      "get": {
        "tags": [
          "Customers"
        ],
        "operationId": "list-customer-users",
        "summary": "List customer users",
        "description": "Retrieves the users linked to a customer. Returns `CustomerUser` objects with pagination metadata.",
        "parameters": [
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "users": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CustomerUser"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/users/{user_id}/activate": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "activate-customer-user",
        "summary": "Activate a customer user",
        "description": "Activates a user linked to the customer. Returns the updated `CustomerUser` object.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "user": {
                          "$ref": "#/components/schemas/CustomerUser"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "user_id",
          "in": "path",
          "description": "User Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/customers/{id}/users/{user_id}/deactivate": {
      "put": {
        "tags": [
          "Customers"
        ],
        "operationId": "deactivate-customer-user",
        "summary": "Deactivate a customer user",
        "description": "Deactivates a user linked to the customer. Returns the updated `CustomerUser` object.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "user": {
                          "$ref": "#/components/schemas/CustomerUser"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "Customer Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "user_id",
          "in": "path",
          "description": "User Id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/marketplace/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-marketplace-filter-options",
        "summary": "List all marketplace filter options",
        "description": "List all filter options for marketplace listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/marketplace/{marketplace_id}/categories/attributes": {
      "get": {
        "tags": [
          "Marketplace"
        ],
        "operationId": "get-marketplace-category-attributes",
        "summary": "Get marketplace category attributes",
        "description": "Get marketplace attributes for a specific category",
        "parameters": [
          {
            "name": "category_id",
            "in": "query",
            "description": "category id. multiple category ids can be passed separated by comma.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attributes": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/MarketplaceAttribute"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Marketplace"
        ],
        "operationId": "create-update-marketplace-category-attributes",
        "summary": "Create or update marketplace category attributes",
        "description": "Create or update marketplace attributes for a specific category",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "category_id",
                  "attributes"
                ],
                "properties": {
                  "category_id": {
                    "description": "Array of category IDs",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "attributes": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/CreateUpdateMarketplaceAttribute"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "attributes": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/MarketplaceAttribute"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "marketplace_id",
          "in": "path",
          "description": "marketplace id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/marketplace/{marketplace_id}/categories/{category_id}/schema": {
      "get": {
        "tags": [
          "Marketplace"
        ],
        "operationId": "get-marketplace-categories-schema",
        "summary": "Get marketplace categories schema",
        "description": "Get marketplace categories schema",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "schema": {
                          "$ref": "#/components/schemas/MarketplaceSchema"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Marketplace"
        ],
        "operationId": "create-update-marketplace-categories-schema",
        "summary": "Create or update marketplace categories schema",
        "description": "Create or update marketplace categories schema",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MarketplaceSchema"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "schema": {
                          "$ref": "#/components/schemas/MarketplaceSchema"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "category_id",
          "in": "path",
          "description": "category id",
          "required": true,
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "marketplace_id",
          "in": "path",
          "description": "marketplace id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/marketplace/{marketplace_id}/config": {
      "get": {
        "tags": [
          "Marketplace"
        ],
        "operationId": "get-marketplace-config",
        "summary": "Retrieve marketplace config",
        "description": "Retrieve marketplace config",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "marketplace_config": {
                          "$ref": "#/components/schemas/MarketplaceConfig"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "marketplace_id",
          "in": "path",
          "description": "marketplace id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/media/files": {
      "get": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "list-media-files",
        "summary": "List all files",
        "description": "List all files",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "name": "folder_id",
            "in": "query",
            "description": "folder id",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "files": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/MediaFile"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/media/files/bulk-delete": {
      "post": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "bulk-delete-media-files",
        "summary": "Delete multiple files",
        "description": "Delete multiple files",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "file_id"
                ],
                "properties": {
                  "file_id": {
                    "description": "array of file ids",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/media/files/bulk-move": {
      "post": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "bulk-move-media-files",
        "summary": "Move multiple files",
        "description": "Move multiple files",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "file_id"
                ],
                "properties": {
                  "file_id": {
                    "description": "array of file ids",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "folder_id": {
                    "description": "folder id where selected files will be moved.",
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/media/files/upload-complete": {
      "post": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "notify-file-upload-complete",
        "summary": "Update upload complete status",
        "description": "Update upload complete status",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "id"
                ],
                "properties": {
                  "id": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/media/files/upload-request": {
      "post": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "request-file-upload",
        "summary": "Create upload request",
        "description": "Create upload request",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MediaFileUploadRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "file": {
                          "type": "object",
                          "properties": {
                            "upload_source": {
                              "enum": [
                                "local-storage",
                                "external-url"
                              ]
                            },
                            "file_type": {
                              "enum": [
                                "image",
                                "video",
                                "document"
                              ]
                            },
                            "id": {
                              "type": "string"
                            },
                            "upload_url": {
                              "description": "for uploading file directly to third party server from local-storage.",
                              "type": "string"
                            }
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/media/files/{id}": {
      "get": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "get-media-file-detail",
        "summary": "Retrieve file detail",
        "description": "Retrieve file detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "file": {
                          "$ref": "#/components/schemas/MediaFile"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "update-media-file",
        "summary": "Update file detail",
        "description": "Update file detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MediaFileInfo"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "file": {
                          "$ref": "#/components/schemas/MediaFile"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "delete-media-file",
        "summary": "Delete file",
        "description": "Delete file",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "file id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/media/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-media-filter-options",
        "summary": "List all media filter options",
        "description": "List all filter options for media listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/media/folders": {
      "get": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "list-media-folders",
        "summary": "List all folders",
        "description": "List all folders",
        "parameters": [
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "folders": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/MediaFolder"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "create-media-folder",
        "summary": "Create a folder",
        "description": "Create a folder",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MediaFolder"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "folder": {
                          "$ref": "#/components/schemas/MediaFolder"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/media/folders/{id}": {
      "get": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "get-media-folder-detail",
        "summary": "Retrieve folder detail",
        "description": "Retrieve folder detail",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "folder": {
                          "$ref": "#/components/schemas/MediaFolder"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "update-media-folder",
        "summary": "Update folder detail",
        "description": "Update folder detail",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MediaFolder"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "folder": {
                          "$ref": "#/components/schemas/MediaFolder"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Media Gallery"
        ],
        "operationId": "delete-media-folder",
        "summary": "Delete folder",
        "description": "Delete folder",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "folder id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/offer/coupons": {
      "get": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "list-coupons",
        "summary": "List all coupons",
        "description": "List all coupons",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "coupons": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Coupon"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "create-coupon",
        "summary": "Create coupon",
        "description": "Create coupon",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Coupon"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "coupon": {
                          "$ref": "#/components/schemas/CouponDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/offer/coupons/{id}": {
      "get": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "get-coupon",
        "summary": "Retrieve a coupon",
        "description": "Returns a complete `CouponDetail` object for the coupon, including eligibility, redemption limits, and type-specific `details`.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "coupon": {
                          "$ref": "#/components/schemas/CouponDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "update-coupon",
        "summary": "Update coupon",
        "description": "Update coupon",
        "requestBody": {
          "description": "",
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Coupon"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "coupon": {
                          "$ref": "#/components/schemas/CouponDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "delete-coupon",
        "summary": "Delete a coupon",
        "description": "Delete a coupon",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "coupon id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/offer/coupons/{id}/codes": {
      "get": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "list-codes",
        "summary": "List all coupon codes",
        "description": "List all coupon codes.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "name": {
                          "description": "The internal name of the coupon these codes belong to.",
                          "type": "string"
                        },
                        "coupon_code": {
                          "description": "The redeemable coupon codes issued for this coupon.",
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "create-codes",
        "summary": "Add coupon code",
        "description": "Add coupon code",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "coupon_code": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "coupon id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/offer/coupons/{id}/delete-codes": {
      "post": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "delete-codes",
        "summary": "Delete coupon codes",
        "description": "Deletes one or more codes from a coupon. Codes that have already been redeemed cannot be deleted; the request fails with the `codes-in-use` error code and returns the offending codes in `errors.coupon_code`.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "coupon_code"
                ],
                "properties": {
                  "coupon_code": {
                    "description": "The coupon codes to delete.",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Coupon codes deleted successfully."
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Coupon codes could not be deleted",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Cannot delete coupon codes that have been used."
                    },
                    "success": {
                      "type": "boolean",
                      "default": false
                    },
                    "code": {
                      "type": "string",
                      "example": "codes-in-use"
                    },
                    "errors": {
                      "type": "object",
                      "properties": {
                        "coupon_code": {
                          "description": "The codes that have already been used and therefore cannot be deleted.",
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "coupon id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/offer/coupons/{id}/usage/customers": {
      "get": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "list-coupon-usage-customers",
        "summary": "List all coupon customers",
        "description": "List all customers who used the specified coupon at least once.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customers": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CouponUsageCustomer"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "coupon id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/offer/coupons/{id}/usage/orders": {
      "get": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "list-coupon-usage-orders",
        "summary": "List all coupon orders",
        "description": "List all coupon orders",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "orders": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "customer_id": {
                                "type": "string"
                              },
                              "customer_name": {
                                "type": "string"
                              },
                              "order_number": {
                                "type": "string"
                              },
                              "order_date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "order_amount": {
                                "type": "number"
                              },
                              "coupon_code": {
                                "type": "string"
                              },
                              "redemption_date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "created_at": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "modified_at": {
                                "type": "string",
                                "format": "date-time"
                              }
                            }
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "coupon id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/offer/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-offer-filter-options",
        "summary": "List all offer filter options",
        "description": "List all filter options for offer listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/offer/promotions": {
      "get": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "list-promotions",
        "summary": "List promotions",
        "description": "Returns a paginated array of full `Promotion` objects.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "promotions": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Promotion"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "create-promotion",
        "summary": "Create promotion",
        "description": "Create promotion",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Promotion"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "promotion": {
                          "$ref": "#/components/schemas/PromotionDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/offer/promotions/{id}": {
      "get": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "get-promotion",
        "summary": "Retrieve a promotion",
        "description": "Returns a complete `PromotionDetail` object, including eligibility, redemption limits, and type-specific `details`.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "promotion": {
                          "$ref": "#/components/schemas/PromotionDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "update-promotion",
        "summary": "Update promotion",
        "description": "Update promotion",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Promotion"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "promotion": {
                          "$ref": "#/components/schemas/PromotionDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "delete-promotion",
        "summary": "Delete Promotion",
        "description": "Delete specific promotion",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "promotion id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/offer/promotions/{id}/usage/customers": {
      "get": {
        "tags": [
          "Coupons & promotions"
        ],
        "operationId": "list-promotion-usage-customers",
        "summary": "List customers who used a promotion",
        "description": "Returns customers who redeemed the promotion at least once, with pagination.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customers": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CouponUsageCustomer"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "promotion id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/offers/coupons/metrics/stats": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-coupons-metrics",
        "summary": "Retrieve coupons stats",
        "description": "Retrieve coupons stats",
        "parameters": [
          {
            "name": "coupon_id",
            "in": "query",
            "description": "To retrieve analytics stats of a particular coupon. ",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "description": "for aggregating data",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "stats": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "metrics": {
                                "type": "object",
                                "$ref": "#/components/schemas/CouponStats"
                              }
                            }
                          }
                        },
                        "lifetime_stats": {
                          "$ref": "#/components/schemas/CouponStats"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/orders": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "list-orders",
        "summary": "List all orders",
        "description": "List all orders",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "orders": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/OrderList"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/orders/abandoned-carts": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "get-abandoned-carts",
        "summary": "List all abandoned carts",
        "description": "List all abandoned carts",
        "parameters": [
          {
            "name": "customer_id",
            "in": "query",
            "description": "customer id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "abandoned_carts": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AbandonedCart",
                            "type": "object"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/orders/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-orders-filter-options",
        "summary": "List all orders filter options",
        "description": "List all filter options for orders listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/orders/invoices": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "list-invoices",
        "summary": "List all invoices",
        "description": "Retrieves a paginated list of tax invoices across all orders. Returns an array of `InvoiceList` objects, each carrying tax-exclusive and tax-inclusive totals plus a GST `tax_summary`. One invoice is raised per shipment, so a multi-shipment order appears as multiple rows. Use `/orders/{order_number}/invoice` to retrieve a single invoice with its line items or as a PDF.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "invoices": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/InvoiceList"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/orders/metrics/stats": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-orders-metrics",
        "summary": "Retrieve orders stats",
        "description": "Retrieve orders stats",
        "parameters": [
          {
            "name": "customer_id",
            "in": "query",
            "description": "customer id to filter data customer wise",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "description": "for aggregating data",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          },
          {
            "name": "product_id",
            "in": "query",
            "description": "product id to filter data product wise",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "variant_id",
            "in": "query",
            "description": "variant id to filter data variant wise",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "stats": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "metrics": {
                                "type": "object",
                                "$ref": "#/components/schemas/OrderStats"
                              }
                            }
                          }
                        },
                        "lifetime_stats": {
                          "$ref": "#/components/schemas/OrderStats"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/orders/metrics/top-selling-products": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-top-selling-products",
        "summary": "List all top selling products",
        "description": "List all top selling products",
        "parameters": [
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "user_id",
            "in": "query",
            "description": "To retrieve analytics stats of a particular user. ",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "products": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/TopSellingProduct"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/orders/payments": {
      "get": {
        "tags": [
          "Payments"
        ],
        "operationId": "list-payments",
        "summary": "List all payments",
        "description": "List all payments",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payments": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Payment"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Payments"
        ],
        "operationId": "create-payment",
        "summary": "Create Payment",
        "description": "Create Payment",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePayment"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/orders/payments/metrics/stats": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-payments-metrics",
        "summary": "Retrieve payments stats",
        "description": "Retrieve payments stats",
        "parameters": [
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "description": "for aggregating data",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          },
          {
            "name": "user_id",
            "in": "query",
            "description": "To retrieve analytics stats of a particular user. ",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "stats": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "metrics": {
                                "type": "object",
                                "$ref": "#/components/schemas/PaymentStats"
                              }
                            }
                          }
                        },
                        "lifetime_stats": {
                          "$ref": "#/components/schemas/PaymentStats"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/orders/payments/refund": {
      "post": {
        "tags": [
          "Payments"
        ],
        "operationId": "refund-payment",
        "summary": "Refund payment",
        "description": "Refund payment",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "customer_id": {
                    "type": "string"
                  },
                  "reference_number": {
                    "description": "multiple reference numbers are separated by comma.",
                    "type": "string"
                  },
                  "amount": {
                    "type": "string"
                  },
                  "payment_mode": {
                    "enum": [
                      "bank-transfer",
                      "original-payment-mode"
                    ]
                  },
                  "bank_account_id": {
                    "description": "in case payment mode is bank-transfer",
                    "type": "string"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/orders/payments/{request_number}": {
      "get": {
        "tags": [
          "Payments"
        ],
        "operationId": "get-payment-detail",
        "summary": "Retrieve payment details",
        "description": "Retrieve payment details",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payment": {
                          "$ref": "#/components/schemas/PaymentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "request_number",
          "in": "path",
          "description": "payment request number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/payments/{request_number}/cancel": {
      "post": {
        "tags": [
          "Payments"
        ],
        "operationId": "cancel-payment",
        "summary": "Cancel Payment",
        "description": "Cancel Payment",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "request_number",
          "in": "path",
          "description": "payment request number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/payouts/config": {
      "get": {
        "tags": [
          "Payouts"
        ],
        "operationId": "list-seller-payout-configs",
        "summary": "List seller payout config",
        "description": "List the seller payout configurations for the marketplace store. Each `SellerPayoutConfig` holds the commission, hold period, and payout inclusion rules applied to a single seller.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_configs": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/SellerPayoutConfig"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "upsert-seller-payout-config",
        "summary": "Create or update seller payout config",
        "description": "Create the seller payout configuration for the marketplace store, or update the existing configuration.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutConfigRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Updated",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_config": {
                          "$ref": "#/components/schemas/SellerPayoutConfig"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/config/{ulid}": {
      "get": {
        "tags": [
          "Payouts"
        ],
        "operationId": "get-seller-payout-config",
        "summary": "Retrieve seller payout config",
        "description": "Retrieve a single seller payout configuration by its `ulid`. Returns the full `SellerPayoutConfig` object, including the `seller_detail` of the seller it applies to.",
        "parameters": [
          {
            "name": "ulid",
            "in": "path",
            "description": "Payout config ULID.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_config": {
                          "$ref": "#/components/schemas/SellerPayoutConfig"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices": {
      "get": {
        "tags": [
          "Payouts"
        ],
        "operationId": "list-seller-payout-invoices",
        "summary": "List seller payout invoices",
        "description": "Retrieves a paginated list of seller invoices tracked by the payout pipeline. Each `SellerPayoutInvoice` carries the order and shipment it settles, the `SellerPayoutCharge` deductions applied to it, and its `payout_batch_id` once batched. Read `status` to tell where an invoice sits: `eligible` invoices are awaiting a batch, `on_hold` ones are excluded from batching until released. Call `/orders/filter-options` with a `listing_type` of `payout-invoice` for the fields and values accepted by `filters`.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_invoices": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/SellerPayoutInvoice"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/adjustments": {
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "create-seller-payout-adjustment",
        "summary": "Create seller payout adjustment",
        "description": "Create a credit or debit adjustment for a seller. The adjustment is created in pending status and may be picked up by the next payout batch.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutAdjustmentCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_adjustment": {
                          "$ref": "#/components/schemas/SellerPayoutAdjustment"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/batches": {
      "get": {
        "tags": [
          "Payouts"
        ],
        "operationId": "list-seller-payout-batches",
        "summary": "List seller payout batches",
        "description": "Retrieves a paginated list of payout batches. Each entry is a `SellerPayoutBatch` summary carrying the `OrderPayment` transfers made against it, but without invoices or adjustments; retrieve a batch by `id` for the expanded `SellerPayoutBatchDetail`.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_batches": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/SellerPayoutBatch"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "create-seller-payout-batch",
        "summary": "Create seller payout batch",
        "description": "Manually create a scheduled seller payout batch from selected pending payout invoices.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutBatchCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_batch": {
                          "$ref": "#/components/schemas/SellerPayoutBatch"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/batches/activities": {
      "get": {
        "tags": [
          "Payouts"
        ],
        "operationId": "list-seller-payout-batch-activities",
        "summary": "List seller payout batch activities",
        "description": "Retrieves a paginated audit trail of events recorded while payout batches are processed. Each `SellerPayoutBatchActivity` names the `batch_id` it belongs to and, for gateway-facing events, captures the request and response exchanged with the payout provider. Use it to diagnose batches stuck in `processing` or left `failed`.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/SellerPayoutBatchActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/batches/{id}": {
      "get": {
        "tags": [
          "Payouts"
        ],
        "operationId": "get-seller-payout-batch",
        "summary": "Retrieve a seller payout batch",
        "description": "Retrieves a single payout batch. Returns a `SellerPayoutBatchDetail` object: the batch totals plus the full `SellerPayoutInvoice` list it settles and any `SellerPayoutAdjustment` records applied to it.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the payout batch.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_batch": {
                          "$ref": "#/components/schemas/SellerPayoutBatchDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "put": {
        "tags": [
          "Payouts"
        ],
        "operationId": "update-seller-payout-batch",
        "summary": "Update a seller payout batch",
        "description": "Switches how a batch will be settled by updating its `payment_option`. Move a batch to `manual` to take it out of automated processing and pay the seller yourself, then record the transfer with the manual-payment endpoint; move it back to `auto` to let the connected payout provider settle it. Returns the updated `SellerPayoutBatch`.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the payout batch.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutBatchUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_batch": {
                          "$ref": "#/components/schemas/SellerPayoutBatch"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/batches/{id}/auto-pay": {
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "auto-pay-seller-payout-batch",
        "summary": "Pay a seller payout batch early",
        "description": "Triggers the transfer for a `scheduled` batch straight away instead of waiting for its `scheduled_at` run. Available while `pay-early` is listed in the batch's `allowed_actions`. The transfer is processed asynchronously, so poll `GET /orders/payouts/invoices/batches/{id}` for the outcome and read `payments` for each attempt's `payment_status`.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the payout batch.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/batches/{id}/cancel": {
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "cancel-seller-payout-batch",
        "summary": "Cancel a seller payout batch",
        "description": "Cancels a payout batch before it is transferred and releases the invoices it was holding. Only `scheduled` and `on_hold` batches can be cancelled; once a batch has been transferred it is immutable. Use `reassign_batch` to choose whether those invoices are regrouped into a new batch immediately or returned to the payout pool. Cancelling does not change the invoices' own hold state, so an invoice held with `/orders/payouts/invoices/hold` stays held.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the payout batch.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutBatchCancel"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/batches/{id}/hold": {
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "hold-seller-payout-batch",
        "summary": "Hold a seller payout batch",
        "description": "Puts a payout batch on hold so the next transfer run skips it. `status` moves to `on_hold` and the batch stays out of settlement until it is unheld. Use this to stop a scheduled payout without cancelling the batch or releasing its invoices. Returns the updated `SellerPayoutBatch`.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the payout batch.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_batch": {
                          "$ref": "#/components/schemas/SellerPayoutBatch"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/batches/{id}/manual-payment": {
      "put": {
        "tags": [
          "Payouts"
        ],
        "operationId": "record-seller-payout-batch-manual-payment",
        "summary": "Record a manual payment for a payout batch",
        "description": "Records a payout that was transferred to the seller outside the platform, for example a bank transfer made from your own banking portal. Use this when the store `payout` configuration is `manual`, or when an `auto` batch had to be settled by hand. Marks the batch as paid and returns the updated `SellerPayoutBatch`.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the payout batch.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutBatchManualPayment"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_batch": {
                          "$ref": "#/components/schemas/SellerPayoutBatch"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/batches/{id}/unhold": {
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "unhold-seller-payout-batch",
        "summary": "Unhold a seller payout batch",
        "description": "Releases a held payout batch back into the payout pipeline so the next transfer run can pick it up. Returns the updated `SellerPayoutBatch`.",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID of the payout batch.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_batch": {
                          "$ref": "#/components/schemas/SellerPayoutBatch"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/charges": {
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "create-seller-payout-charge",
        "summary": "Create seller payout charge",
        "description": "Create an admin-applied charge against a pending seller payout invoice.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutChargeCreate"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payout_charge": {
                          "$ref": "#/components/schemas/SellerPayoutCharge"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/hold": {
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "hold-seller-payout-invoices",
        "summary": "Hold seller payout invoices",
        "description": "Put one or more seller payout invoices on hold and rebalance any affected scheduled payout batch.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutInvoiceHoldRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/SellerPayoutInvoiceHoldSummary"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/invoices/unhold": {
      "post": {
        "tags": [
          "Payouts"
        ],
        "operationId": "unhold-seller-payout-invoices",
        "summary": "Unhold seller payout invoices",
        "description": "Move one or more held seller payout invoices back to pending status.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SellerPayoutInvoiceUnholdRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "$ref": "#/components/schemas/SellerPayoutInvoiceUnholdSummary"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/payouts/metrics/stats": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-seller-payout-metrics",
        "summary": "Retrieve seller payout stats",
        "description": "Retrieves seller payout amounts and invoice volumes bucketed by payout state. Returns a `SellerPayoutStats` object per interval in `stats`, plus a `lifetime_stats` roll-up across all time.",
        "parameters": [
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "description": "for aggregating data",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          },
          {
            "name": "seller_id",
            "in": "query",
            "description": "To retrieve payout stats of a particular seller.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "stats": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "date": {
                                "description": "Bucket timestamp, as an ISO 8601 datetime carrying the store's UTC offset (for example `2026-08-04T00:00:00.000000+05:30`) rather than a UTC `Z` instant.",
                                "type": "string"
                              },
                              "metrics": {
                                "type": "object",
                                "$ref": "#/components/schemas/SellerPayoutStats"
                              }
                            }
                          }
                        },
                        "lifetime_stats": {
                          "$ref": "#/components/schemas/SellerPayoutStats"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/orders/products-purchase-count": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "get-products-purchase-count",
        "summary": "List all products purchase count",
        "description": "List all products purchase count",
        "parameters": [
          {
            "name": "customer_id",
            "in": "query",
            "description": "customer id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "products": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "product_id": {
                                "type": "string"
                              },
                              "product_name": {
                                "type": "string"
                              },
                              "product_image_url": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "sku": {
                                "type": "string"
                              },
                              "product_variant_id": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "selling_price": {
                                "type": "number"
                              },
                              "purchase_count": {
                                "type": "integer"
                              }
                            }
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/orders/refund-estimates": {
      "post": {
        "tags": [
          "Orders"
        ],
        "operationId": "estimate-order-refund",
        "summary": "Estimate refund for a shipment or order",
        "description": "Calculates the refund amount and breakdown for an order or a specific shipment before a cancellation is initiated. Returns an `OrderRefundEstimate` describing the total refundable amount, its split across the original payment modes/methods, the recommended and available refund modes, and any refunds already processed against the shipment. Use this to preview the refund the customer will receive and to let the operator pick a refund mode.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "order_number",
                  "shipment_number"
                ],
                "properties": {
                  "order_number": {
                    "type": "string"
                  },
                  "shipment_number": {
                    "description": "Shipment number to estimate refund for. If not provided, refund will be estimated for the order as a whole.",
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "order": {
                          "$ref": "#/components/schemas/OrderRefundEstimate"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/orders/subscriptions": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "list-subscriptions",
        "summary": "List all subscriptions",
        "description": "List all subscriptions",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "subscriptions": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Subscription"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/orders/subscriptions/{subscription_number}": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "get-subscription-detail",
        "summary": "Retrieve a subscription details",
        "description": "Retrieve a subscription details",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "subscription": {
                          "$ref": "#/components/schemas/Subscription"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "subscription_number",
          "in": "path",
          "description": "subscription number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/subscriptions/{subscription_number}/customers": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "list-subscription-customers",
        "summary": "List all subscription customers",
        "description": "List all subscription customers",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customers": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/SubscriptionCustomer"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "subscription_number",
          "in": "path",
          "description": "subscription number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "get-order-detail",
        "summary": "Retrieve order details",
        "description": "Retrieve order details",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "order": {
                          "$ref": "#/components/schemas/OrderDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Orders"
        ],
        "operationId": "update-order",
        "summary": "Update order details",
        "description": "Update order details",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateOrder"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "order": {
                          "$ref": "#/components/schemas/OrderDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}/accept": {
      "post": {
        "tags": [
          "Orders"
        ],
        "operationId": "accept-order",
        "summary": "Accept order",
        "description": "Accept order",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "order": {
                          "$ref": "#/components/schemas/OrderDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}/activity": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "list-order-activity",
        "summary": "List all order activity",
        "description": "List all order activity",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activity": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/OrderActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Orders"
        ],
        "operationId": "create-order-activity",
        "summary": "Create order activity",
        "description": "Create order activity",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OrderActivity"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "activity": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/OrderActivity"
                      }
                    },
                    "pagination": {
                      "$ref": "#/components/schemas/Pagination"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}/cancel": {
      "post": {
        "tags": [
          "Orders"
        ],
        "operationId": "cancel-order",
        "summary": "Cancel an order",
        "description": "Cancels an order and initiates a refund for any captured payment. Returns the updated `OrderDetail` object.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "cancellation_reason",
                  "refund_mode"
                ],
                "properties": {
                  "cancellation_reason": {
                    "description": "The reason for cancelling the order. Recorded on the order for reporting and customer communication.",
                    "type": "string"
                  },
                  "refund_mode": {
                    "description": "How the refund is issued. Use `original-payment-mode` to refund back to the customer's original payment instrument, or `bank-transfer` to refund to a saved customer bank account.",
                    "type": "string",
                    "enum": [
                      "original-payment-mode",
                      "bank-transfer"
                    ]
                  },
                  "bank_account_id": {
                    "description": "The customer bank account to credit. Required when `refund_mode` is `bank-transfer`; omit or set to `null` for `original-payment-mode`.",
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "order": {
                          "$ref": "#/components/schemas/OrderDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}/check-inventory": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "check-order-inventory",
        "summary": "Check inventory",
        "description": "Verifies stock availability for an order's unscheduled or store_rejected shipment before it is scheduled.",
        "parameters": [
          {
            "name": "fulfillment_type",
            "in": "query",
            "description": "Optional. The fulfillment type to evaluate inventory against. If not provided, the inventory will be checked for the `fulfillment_type` of the shipment.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "delivery",
                "collect-in-store"
              ]
            }
          },
          {
            "name": "shipment_number",
            "in": "query",
            "description": "Optional. The shipment number to check inventory for. If not provided, the inventory will be checked for the `unscheduled` shipment of the order.",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "inventory": {
                          "$ref": "#/components/schemas/CheckInventoryResponse"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "Order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}/invoice": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "get-order-invoice",
        "summary": "Retrieve order invoice",
        "description": "Retrieve order invoice",
        "parameters": [
          {
            "name": "format",
            "in": "query",
            "description": "Response data format",
            "schema": {
              "type": "string",
              "default": "json",
              "enum": [
                "json",
                "pdf"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "invoices": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/InvoiceDetail"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              },
              "application/pdf": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}/receipt": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "get-order-receipt",
        "summary": "Retrieve order receipt",
        "description": "Retrieves a printable receipt for a specific order using the order number. This endpoint returns either structured JSON data or a formatted PDF, suitable for customer presentation. Response format (JSON or PDF) is determined by an optional query parameter (e.g. format=pdf or format=json).",
        "parameters": [
          {
            "name": "format",
            "in": "query",
            "description": "Response data format",
            "schema": {
              "type": "string",
              "default": "json",
              "enum": [
                "json",
                "pdf"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "order_receipt": {
                          "$ref": "#/components/schemas/OrderReceiptJsonFormat"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              },
              "application/pdf": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}/shipments": {
      "get": {
        "tags": [
          "Orders"
        ],
        "operationId": "list-order-shipments",
        "summary": "Retrieve order shipments",
        "description": "Retrieve order shipments",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipment": {
                          "$ref": "#/components/schemas/OrderShipmentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/orders/{order_number}/verify-payment": {
      "post": {
        "tags": [
          "Orders"
        ],
        "operationId": "verify-order-payment",
        "summary": "Verify order payment",
        "description": "Verify order payment",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OrderActivity"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "payments": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/OrderPayment"
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/pos/devices": {
      "get": {
        "tags": [
          "POS"
        ],
        "operationId": "list-devices",
        "summary": "List all POS devices",
        "description": "List all POS devices",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "devices": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/PosDevice"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "POS"
        ],
        "operationId": "create-device",
        "summary": "Create POS device",
        "description": "Create POS device",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePosDevice"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "device": {
                          "$ref": "#/components/schemas/PosDevice"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/pos/devices/{id}": {
      "get": {
        "tags": [
          "POS"
        ],
        "operationId": "get-device",
        "summary": "Retrieve POS device detail",
        "description": "Retrieve POS device detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "device": {
                          "$ref": "#/components/schemas/PosDevice"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "POS"
        ],
        "operationId": "update-device",
        "summary": "Update POS device",
        "description": "Update POS device",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PosDevice"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "device": {
                          "$ref": "#/components/schemas/PosDevice"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "POS"
        ],
        "operationId": "delete-device",
        "summary": "Delete POS device",
        "description": "Delete POS device",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "id of pos device",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/pos/devices/{id}/pairing-code": {
      "post": {
        "tags": [
          "POS"
        ],
        "operationId": "generate-device-pairing-code",
        "summary": "Generate POS device Pairing Code",
        "description": "Generates a new verification code for pairing the specified POS device. This code is used to securely link the device with the system during the pairing process.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "pairing_code": {
                          "type": "string"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "id of pos device",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/pos/devices/{id}/revoke": {
      "post": {
        "tags": [
          "POS"
        ],
        "operationId": "revoke-device",
        "summary": "Revoke POS device",
        "description": "Disables the specified POS device, revoking its access to the system. This action updates the device’s status to disabled, preventing it from performing any operations or connecting to the POS network.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "reason"
                ],
                "properties": {
                  "reason": {
                    "type": "string"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "device": {
                          "$ref": "#/components/schemas/PosDevice"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "id of pos device",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/pos/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-pos-filter-options",
        "summary": "List all pos filter options",
        "description": "List all filter options for pos listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/pos/permissions": {
      "get": {
        "tags": [
          "POS"
        ],
        "operationId": "list-pos-permissions",
        "summary": "List all POS permissions",
        "description": "List all POS permissions",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "permissions": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/PosPermission"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/pos/roles": {
      "get": {
        "tags": [
          "POS"
        ],
        "operationId": "list-pos-roles",
        "summary": "List all POS roles",
        "description": "List all POS roles",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "roles": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/PosRole"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "POS"
        ],
        "operationId": "create-pos-role",
        "summary": "Create POS role",
        "description": "Create POS role",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PosRole"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "role": {
                          "$ref": "#/components/schemas/PosRole"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/pos/roles/{id}": {
      "get": {
        "tags": [
          "POS"
        ],
        "operationId": "get-pos-role",
        "summary": "Retrieve POS role",
        "description": "Retrieve POS role",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "role": {
                          "$ref": "#/components/schemas/PosRole"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "POS"
        ],
        "operationId": "update-pos-role",
        "summary": "Update POS role",
        "description": "Update POS role",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "permissions": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "required": [
                        "module_name",
                        "resource_group",
                        "permission_type"
                      ],
                      "properties": {
                        "module_name": {
                          "type": "string"
                        },
                        "resource_group": {
                          "type": "string"
                        },
                        "permission_type": {
                          "enum": [
                            "admin",
                            "readonly",
                            "none"
                          ]
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "role": {
                          "$ref": "#/components/schemas/PosRole"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "POS"
        ],
        "operationId": "delete-pos-role",
        "summary": "Delete POS role",
        "description": "Delete POS role",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "pos role id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/pos/users": {
      "get": {
        "tags": [
          "POS"
        ],
        "operationId": "list-pos-users",
        "summary": "List all POS users",
        "description": "List all POS users",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "users": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/PosUser"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "POS"
        ],
        "operationId": "create-pos-user",
        "summary": "Create POS user",
        "description": "Create POS user",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePosUser"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "user": {
                          "$ref": "#/components/schemas/PosUser"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/pos/users/{id}": {
      "get": {
        "tags": [
          "POS"
        ],
        "operationId": "get-pos-user-detail",
        "summary": "Retrieve POS user",
        "description": "Retrieve POS user",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "user": {
                          "$ref": "#/components/schemas/PosUser"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "POS"
        ],
        "operationId": "update-pos-user",
        "summary": "Update POS user",
        "description": "Update POS user",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PosUser"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "user": {
                          "$ref": "#/components/schemas/PosUser"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "POS"
        ],
        "operationId": "delete-pos-user",
        "summary": "Delete POS user",
        "description": "Delete POS user",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "pos user id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-shipping-filter-options",
        "summary": "List all shipping filter options",
        "description": "List all filter options for shipping listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/shipping/metrics/stats": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-shipping-metrics",
        "summary": "Retrieve shipments stats",
        "description": "Retrieve shipments stats",
        "parameters": [
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "description": "for aggregating data",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          },
          {
            "name": "sku",
            "in": "query",
            "description": "To retrieve analytics stats of a particular sku.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "user_id",
            "in": "query",
            "description": "To retrieve analytics stats of a particular user. ",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "stats": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "metrics": {
                                "type": "object",
                                "$ref": "#/components/schemas/ShippingStats"
                              }
                            }
                          }
                        },
                        "lifetime_stats": {
                          "$ref": "#/components/schemas/ShippingStats"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/shipping/serviceability": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "check-shipping-serviceability",
        "summary": "Courier Serviceability",
        "description": "Check Courier Serviceability",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "delivery_pincode",
                  "total_weight"
                ],
                "properties": {
                  "delivery_pincode": {
                    "type": "string"
                  },
                  "total_weight": {
                    "type": "number"
                  },
                  "length": {
                    "type": "integer"
                  },
                  "breadth": {
                    "type": "integer"
                  },
                  "height": {
                    "type": "integer"
                  },
                  "warehouse_id": {
                    "description": "warehouse id",
                    "type": "string"
                  },
                  "shipping_option": {
                    "enum": [
                      "auto",
                      "manual"
                    ]
                  },
                  "shipping_provider_id": {
                    "description": "to check serviceability using particular shipping provider.",
                    "type": "string"
                  },
                  "mode": {
                    "enum": [
                      "SURFACE",
                      "AIR",
                      "ALL"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "is_serviceable": {
                          "type": "boolean"
                        },
                        "shipping_options": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "warehouse_id": {
                                "type": "string"
                              },
                              "warehouse_name": {
                                "type": "string"
                              },
                              "warehouse_pincode": {
                                "type": "string"
                              },
                              "shipping_methods": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "id": {
                                      "type": "string"
                                    },
                                    "name": {
                                      "type": "string"
                                    },
                                    "shipping_type": {
                                      "enum": [
                                        "auto",
                                        "manual"
                                      ]
                                    },
                                    "shipping_amount": {
                                      "description": "shipment amount of recommended courier, or range of shipment amount - (lowest to highest).",
                                      "type": "string"
                                    },
                                    "estimated_delivery_days": {
                                      "description": "estimated delivery days of recommended courier, or range of estimated delivery days - (lowest to highest).",
                                      "type": [
                                        "integer",
                                        "string",
                                        "null"
                                      ]
                                    },
                                    "courier_companies": {
                                      "type": "array",
                                      "items": {
                                        "type": "object",
                                        "properties": {
                                          "id": {
                                            "type": "string"
                                          },
                                          "name": {
                                            "type": "string"
                                          },
                                          "shipping_amount": {
                                            "type": "number"
                                          },
                                          "estimated_delivery_days": {
                                            "type": [
                                              "integer",
                                              "string",
                                              "null"
                                            ]
                                          },
                                          "is_recommended": {
                                            "type": "boolean"
                                          },
                                          "is_surface": {
                                            "type": "boolean"
                                          },
                                          "is_hyperlocal": {
                                            "type": "boolean"
                                          },
                                          "rating": {
                                            "type": "number"
                                          }
                                        }
                                      }
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/shipping/shipments": {
      "get": {
        "tags": [
          "Shipping"
        ],
        "operationId": "list-shipments",
        "summary": "List all shipments",
        "description": "List all shipments",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipments": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ShipmentList"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "create-shipment",
        "summary": "Create shipment",
        "description": "Create shipment",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "allOf": [
                  {
                    "type": "object",
                    "properties": {
                      "order_number": {
                        "type": "string"
                      }
                    }
                  },
                  {
                    "$ref": "#/components/schemas/CreateShipment"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/shipping/shipments/bulk-update": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "bulk-update-shipments",
        "summary": "Update shipments in bulk",
        "description": "Update shipments in bulk",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ShipmentBulkUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/shipping/shipments/{order_number}/merge": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "merge-shipments",
        "summary": "Merge shipments",
        "description": "Merges multiple `unscheduled` shipments of an order into one. Items from every shipment listed in `target_shipments` are moved into `source_shipment`, and the emptied target shipments are discarded. Only shipments in the `unscheduled` status can be merged. Returns the reference number of the surviving shipment.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "source_shipment",
                  "target_shipments"
                ],
                "properties": {
                  "source_shipment": {
                    "description": "Reference number of the shipment that receives the merged items and survives the merge.",
                    "type": "string"
                  },
                  "target_shipments": {
                    "description": "Reference numbers of the shipments merged into `source_shipment`. Each is dissolved once its items are moved.",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "source_shipment": {
                          "description": "Reference number of the merged shipment holding all items.",
                          "type": "string"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "Order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{order_number}/pack-items": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "pack-shipment-items",
        "summary": "Pack items",
        "description": "Generate auto packing details",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "warehouse_id",
                  "items"
                ],
                "properties": {
                  "warehouse_id": {
                    "type": "string"
                  },
                  "items": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "required": [
                        "product_id",
                        "variant_id",
                        "quantity"
                      ],
                      "properties": {
                        "product_id": {
                          "type": "string"
                        },
                        "variant_id": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "quantity": {
                          "type": "integer"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "total_boxes": {
                          "type": "integer"
                        },
                        "total_cost": {
                          "type": "number"
                        },
                        "total_weight": {
                          "type": "number"
                        },
                        "boxes": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "type": {
                                "enum": [
                                  "bin",
                                  "shipper"
                                ]
                              },
                              "name": {
                                "type": "string"
                              },
                              "length": {
                                "type": "number"
                              },
                              "width": {
                                "type": "number"
                              },
                              "height": {
                                "type": "number"
                              },
                              "weight": {
                                "type": "number"
                              },
                              "max_weight": {
                                "type": "number"
                              },
                              "packed_items_count": {
                                "type": "integer"
                              },
                              "packed_items_weight": {
                                "type": "number"
                              },
                              "chargeable_weight": {
                                "type": "number"
                              },
                              "box_count": {
                                "type": "integer"
                              },
                              "items": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "id": {
                                      "description": "combination of product id and variant id separated by - (hyphen).",
                                      "type": "string"
                                    },
                                    "product_id": {
                                      "type": "string"
                                    },
                                    "product_name": {
                                      "type": "string"
                                    },
                                    "variant_id": {
                                      "type": "string"
                                    },
                                    "variant_name": {
                                      "type": "string"
                                    },
                                    "length": {
                                      "type": "number"
                                    },
                                    "width": {
                                      "type": "number"
                                    },
                                    "height": {
                                      "type": "number"
                                    },
                                    "weight": {
                                      "type": "number"
                                    },
                                    "image_separated": {
                                      "type": "string"
                                    },
                                    "image_sbs": {
                                      "type": "string"
                                    },
                                    "coordinates": {
                                      "type": "object",
                                      "additionalProperties": {
                                        "type": "integer"
                                      }
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "Order number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{order_number}/refund-shortfall": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "refund-shortfall",
        "summary": "Refund shortfall",
        "description": "Refund shortfall",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "items",
                  "payment_method"
                ],
                "properties": {
                  "items": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "required": [
                        "product_id",
                        "variant_id",
                        "quantity"
                      ],
                      "properties": {
                        "product_id": {
                          "type": "string"
                        },
                        "variant_id": {
                          "description": "The unique identifier of the product variant. Use `null` if the product has no variants.",
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "quantity": {
                          "type": "integer"
                        },
                        "free_quantity": {
                          "type": "integer",
                          "default": 0
                        }
                      }
                    }
                  },
                  "payment_method": {
                    "enum": [
                      "original-payment-mode",
                      "bank-transfer"
                    ]
                  },
                  "bank_account_id": {
                    "description": "required if payment_method = bank-transfer",
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "Order Number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{order_number}/wait-for-inventory": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "wait-for-inventory",
        "summary": "Wait for inventory",
        "description": "Wait for inventory",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "revised_shipping_date"
                ],
                "properties": {
                  "revised_shipping_date": {
                    "type": "string"
                  },
                  "shipping_option": {
                    "enum": [
                      "auto",
                      "manual"
                    ]
                  },
                  "notify_customer": {
                    "type": "boolean"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "order_number",
          "in": "path",
          "description": "Order Number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}": {
      "get": {
        "tags": [
          "Shipping"
        ],
        "operationId": "get-shipment-detail",
        "summary": "Retrieve shipment detail",
        "description": "Retrieve shipment detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipment": {
                          "$ref": "#/components/schemas/ShipmentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/activities": {
      "get": {
        "tags": [
          "Shipping"
        ],
        "operationId": "get-shipment-activities",
        "summary": "Retrieve shipment activities",
        "description": "Retrieve shipment activities",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "activities": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ShipmentActivity"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/approve": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "approve-shipment",
        "summary": "Approve shipment",
        "description": "Approves a shipment that is pending store review. Returns an updated `ShipmentDetail`.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipment": {
                          "$ref": "#/components/schemas/ShipmentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/cancel": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "cancel-shipment",
        "summary": "Cancel shipment",
        "description": "Cancels a shipment. Use the `cancel` payload to mark the shipment as unscheduled so it can be re-shipped via another carrier or a manual method. Use the `cancel-and-refund` payload to cancel and simultaneously initiate a refund to the original payment instrument or a customer bank account.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "discriminator": {
                  "propertyName": "action",
                  "mapping": {
                    "cancel": "#/components/schemas/CancelShipment",
                    "cancel-and-refund": "#/components/schemas/CancelAndRefundShipment"
                  }
                },
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/CancelShipment"
                  },
                  {
                    "$ref": "#/components/schemas/CancelAndRefundShipment"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/download-invoice": {
      "get": {
        "tags": [
          "Shipping"
        ],
        "operationId": "download-shipment-invoice",
        "summary": "Download invoice",
        "description": "Download invoice",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/download-shipping-label": {
      "get": {
        "tags": [
          "Shipping"
        ],
        "operationId": "get-shipping-label",
        "summary": "Download shipping label",
        "description": "Download shipping label",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/invoice": {
      "get": {
        "tags": [
          "Shipping"
        ],
        "operationId": "get-shipment-invoice",
        "summary": "Retrieve shipment invoice",
        "description": "Retrieve shipment invoice",
        "parameters": [
          {
            "name": "format",
            "in": "query",
            "description": "Response data format",
            "schema": {
              "type": "string",
              "default": "json",
              "enum": [
                "json",
                "pdf"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "invoice": {
                          "$ref": "#/components/schemas/InvoiceDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              },
              "application/pdf": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/manual-update": {
      "put": {
        "tags": [
          "Shipping"
        ],
        "operationId": "update-shipment",
        "summary": "Update shipment detail",
        "description": "Update shipment detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "status": {
                    "type": "string"
                  },
                  "warehouse_id": {
                    "type": "string"
                  },
                  "awb_no": {
                    "type": "string"
                  },
                  "courier_company_name": {
                    "type": "string"
                  },
                  "shipping_label_url": {
                    "type": "string"
                  },
                  "tracking_url": {
                    "type": "string"
                  },
                  "manual_shipping_charges": {
                    "type": "number"
                  },
                  "eta_delivery": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "shipped_date": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "out_for_delivery_date": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "delivered_date": {
                    "type": "string",
                    "format": "date-time"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipment": {
                          "$ref": "#/components/schemas/ShipmentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/packing-detail": {
      "get": {
        "tags": [
          "Shipping"
        ],
        "operationId": "get-shipment-packing-detail",
        "summary": "Retrieve packing detail",
        "description": "Retrieve packing detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "packing_detail": {
                          "anyOf": [
                            {
                              "$ref": "#/components/schemas/ManualPackingDetail"
                            },
                            {
                              "$ref": "#/components/schemas/AutoPackingDetail"
                            }
                          ]
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/reject": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "reject-shipment",
        "summary": "Reject shipment",
        "description": "Rejects a shipment that is pending store review. Returns an updated `ShipmentDetail`.",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipment": {
                          "$ref": "#/components/schemas/ShipmentDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/replacement": {
      "post": {
        "tags": [
          "Shipping"
        ],
        "operationId": "create-replacement-shipment",
        "summary": "Create a replacement shipment",
        "description": "Creates a replacement shipment against an existing shipment. Use the `manual` payload to dispatch outside an integrated carrier, or the `auto` payload to fulfill through an integrated carrier with system-managed packing and rates.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/CreateReplacementShipmentWithManualMethod"
                  },
                  {
                    "$ref": "#/components/schemas/CreateReplacementShipmentWithAutoMethod"
                  },
                  {
                    "$ref": "#/components/schemas/CreateReplacementShipmentForCollectInStore"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Reference number of the original shipment being replaced.",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/shipping/shipments/{reference_number}/tracking": {
      "get": {
        "tags": [
          "Shipping"
        ],
        "operationId": "get-shipment-tracking",
        "summary": "Tracking Shipment",
        "description": "Tracking Shipment",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "description": "Tracking details when available, or an empty array when the shipment has no tracking.",
                      "oneOf": [
                        {
                          "properties": {
                            "current_status": {
                              "type": "string"
                            },
                            "expected_delivery_date": {
                              "type": "string",
                              "format": "date-time"
                            },
                            "shipment_track_activities": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "activity_time": {
                                    "type": "string",
                                    "format": "date-time"
                                  },
                                  "activity": {
                                    "type": "string"
                                  },
                                  "location": {
                                    "type": "string"
                                  }
                                }
                              }
                            }
                          },
                          "type": "object"
                        },
                        {
                          "type": "array",
                          "maxItems": 0
                        }
                      ]
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "reference_number",
          "in": "path",
          "description": "Shipment reference number",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/available-payment-options": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-available-payment-options",
        "summary": "List available payment options",
        "description": "Returns a unified list of manual payment methods and connected payment service providers (`service_type` `payment`, `service_sub_type` `credit-line`). Use for credit-line configuration, payout configuration, and checkout option selection.",
        "parameters": [
          {
            "name": "supports_credit_line",
            "in": "query",
            "description": "Filter by whether the option supports credit-line settlement.",
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          },
          {
            "name": "supports_payout",
            "in": "query",
            "description": "Filter by whether the option can settle seller payout batches. Pass `true` when building the store `payout` configuration.",
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          },
          {
            "name": "type",
            "in": "query",
            "description": "Filter by option source: `manual` (store payment methods) or `auto` (service providers).",
            "schema": {
              "type": "string",
              "enum": [
                "auto",
                "manual"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "available_payment_options": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AvailablePaymentOption"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/available-shipping-options": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-available-shipping-options",
        "summary": "List all available shipping options",
        "description": "List all available shipping options",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_options": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/AvailableShippingOption"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/config": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-store-config",
        "summary": "Retrieve store config",
        "description": "Retrieve store config",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "store_config": {
                          "$ref": "#/components/schemas/StoreConfig"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "update-store-config",
        "summary": "Update store config",
        "description": "Update store config",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/StoreConfig"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "store_config": {
                          "$ref": "#/components/schemas/StoreConfig"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/countries": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-countries",
        "summary": "List all countries",
        "description": "List all countries",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "countries": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CustomerAddressCountry"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "X-Api-Key": []
          }
        ]
      },
      "parameters": []
    },
    "/store/countries/{country_iso_code}/pincodes": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-pincodes",
        "summary": "List all pincodes",
        "description": "List all pincodes",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "pincodes": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Pincode"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "X-Api-Key": []
          }
        ]
      },
      "parameters": [
        {
          "name": "country_iso_code",
          "in": "path",
          "description": "country iso code in 2 chars. ex. IN for India",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/countries/{country_iso_code}/states": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-states",
        "summary": "List all states",
        "description": "List all states",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "states": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CustomerAddressState"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "X-Api-Key": []
          }
        ]
      },
      "parameters": [
        {
          "name": "country_iso_code",
          "in": "path",
          "description": "country iso code in 2 chars. ex. IN for India",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/customer-group": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-customer-groups",
        "summary": "List all customer groups",
        "description": "List all customer groups",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customer_groups": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/CustomerGroup"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-customer-group",
        "summary": "Create customer group",
        "description": "Create customer group",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CustomerGroup"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customer_group": {
                          "$ref": "#/components/schemas/CustomerGroup"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/customer-group/{id}": {
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-customer-group",
        "summary": "Update customer group",
        "description": "Update customer group",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "$ref": "#/components/schemas/CustomerGroup"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "customer_group": {
                          "$ref": "#/components/schemas/CustomerGroup"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-customer-group",
        "summary": "Delete customer group",
        "description": "Delete customer group",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "customer group id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/downloads": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-downloads",
        "summary": "List all download jobs",
        "description": "List all download jobs",
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "exports": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/DataDownload"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-download-request",
        "summary": "Create download request",
        "description": "Create download request",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "data_source": {
                    "description": "Records to export. `invoices` exports payout-eligible `SellerPayoutInvoice` records; `payout_batches` exports seller settlement `SellerPayoutBatch` records.",
                    "enum": [
                      "customers",
                      "orders",
                      "shipments",
                      "payments",
                      "invoices",
                      "payout_batches"
                    ]
                  },
                  "data_filters": {
                    "$ref": "#/components/schemas/DataFilterObject"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "$ref": "#/components/schemas/DataDownload"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-store-filter-options",
        "summary": "List all store filter options",
        "description": "List all filter options for store listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/kyc-document": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-kyc-documents",
        "summary": "List all kyc documents",
        "description": "List all kyc documents",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "kyc_documents": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/KycDocumentConfig"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-kyc-document",
        "summary": "Create kyc document",
        "description": "Create kyc document",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/KycDocumentConfig"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "kyc_document": {
                          "$ref": "#/components/schemas/KycDocumentConfig"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/kyc-document/{id}": {
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-kyc-document",
        "summary": "Update kyc document",
        "description": "Update kyc document",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "$ref": "#/components/schemas/UpdateKycDocumentConfig"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "kyc_document": {
                          "$ref": "#/components/schemas/KycDocumentConfig"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-kyc-document",
        "summary": "Delete kyc document",
        "description": "Delete kyc document",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "kyc document id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/manual-payment-methods": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-manual-payment-methods",
        "summary": "List all manual payment methods",
        "description": "List all manual payment methods",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payment_methods": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ManualPaymentMethod"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-manual-payment-method",
        "summary": "Create manual payment method",
        "description": "Create manual payment method",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ManualPaymentMethod"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payment_method": {
                          "$ref": "#/components/schemas/ManualPaymentMethod"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/manual-payment-methods/{id}": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-manual-payment-method",
        "summary": "Retrieve manual payment method detail",
        "description": "Retrieve manual payment method detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payment_method": {
                          "$ref": "#/components/schemas/ManualPaymentMethod"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-manual-payment-method",
        "summary": "Update manual payment method detail",
        "description": "Update manual payment method detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ManualPaymentMethod"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "payment_method": {
                          "$ref": "#/components/schemas/ManualPaymentMethod"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-manual-payment-method",
        "summary": "Delete manual payment method",
        "description": "Delete manual payment method",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "payment method id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/manual-shipping-methods": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-manual-shipping-methods",
        "summary": "List all manual shipping methods",
        "description": "List all manual shipping methods",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_methods": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ManualShippingMethod"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-manual-shipping-method",
        "summary": "Create manual shipping method",
        "description": "Create manual shipping method",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ManualShippingMethod"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_method": {
                          "$ref": "#/components/schemas/ManualShippingMethod"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/manual-shipping-methods/{id}": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-manual-shipping-method",
        "summary": "Retrieve manual shipping method detail",
        "description": "Retrieve manual shipping method detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_method": {
                          "$ref": "#/components/schemas/ManualShippingMethod"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-manual-shipping-method",
        "summary": "Update manual shipping method detail",
        "description": "Update manual shipping method detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ManualShippingMethod"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_method": {
                          "$ref": "#/components/schemas/ManualShippingMethod"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-manual-shipping-method",
        "summary": "Delete manual shipping method",
        "description": "Delete manual shipping method",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "shipping method id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/search": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "global-search",
        "summary": "Global search across Customers, Orders, and Products",
        "description": "Search across Customers, Orders, and Products using Meilisearch. Each `content.results[]` entry is a `GlobalSearchResult`. Read `indexUid` to interpret `hits`: customer index entries are `GlobalSearchCustomerHit`, order index entries are `GlobalSearchOrder`, product index entries are `GlobalSearchProduct`.",
        "parameters": [
          {
            "name": "filter",
            "in": "query",
            "description": "Meilisearch filter expression, e.g. `id=01KXQD8EACBDCEM5Y8HTJ3Q71T`. Returns `400` if it references an attribute that is not filterable.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "index",
            "in": "query",
            "description": "Search index to query",
            "required": false,
            "schema": {
              "enum": [
                "Customers",
                "Orders",
                "Products"
              ]
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum number of hits to return. Defaults to `5`.",
            "required": false,
            "schema": {
              "type": "integer"
            }
          },
          {
            "name": "search",
            "in": "query",
            "description": "Search query string",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "results": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/GlobalSearchResult"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/store/service-providers": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-service-providers",
        "summary": "List all service providers",
        "description": "List all service providers",
        "parameters": [
          {
            "name": "service_type",
            "in": "query",
            "description": "type of service",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/ServiceProviderType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "service_providers": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ServiceProvider"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-service-provider-config",
        "summary": "Configure a service provider",
        "description": "Configure a service provider.",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "allOf": [
                  {
                    "type": "object",
                    "required": [
                      "service_provider_id"
                    ],
                    "properties": {
                      "service_provider_id": {
                        "type": "string"
                      }
                    }
                  },
                  {
                    "oneOf": [
                      {
                        "$ref": "#/components/schemas/CreateShippingServiceProvider"
                      },
                      {
                        "$ref": "#/components/schemas/CreateOtherServiceProvider"
                      }
                    ]
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "service_provider": {
                          "$ref": "#/components/schemas/ServiceProvider"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/service-providers/{id}": {
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-service-provider-config",
        "summary": "Update service provider config",
        "description": "Update service provider config",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ServiceProvider"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "service_provider": {
                          "$ref": "#/components/schemas/ServiceProvider"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-service-provider-config",
        "summary": "Delete service provider config",
        "description": "Delete service provider config",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "service provider id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/service-providers/{id}/test-connection": {
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "test-service-provider-connection",
        "summary": "Test service provider config",
        "description": "Test service provider config",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "api_credentials"
                ],
                "properties": {
                  "api_credentials": {
                    "description": "key & value pair. keys must match with input_field_name in required_credentials_params.",
                    "type": "object"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "errors": {
                      "description": "optional field. returned in case of errors only.",
                      "type": "object"
                    },
                    "code": {
                      "description": "optional key. returned in case of errors only.",
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "service provider id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/shipping-boxes": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-shipping-boxes",
        "summary": "List all shipping boxes",
        "description": "List all shipping boxes",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_boxes": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/StoreShippingBoxDetail"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-shipping-box",
        "summary": "Create shipping box",
        "description": "Create shipping box",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/StoreShippingBoxDetail"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_box": {
                          "$ref": "#/components/schemas/StoreShippingBoxDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/shipping-boxes/{id}": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-shipping-box",
        "summary": "Retrieve shipping box detail",
        "description": "Retrieve shipping box detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_box": {
                          "$ref": "#/components/schemas/StoreShippingBoxDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-shipping-box",
        "summary": "Update shipping box detail",
        "description": "Update shipping box detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/StoreShippingBoxDetail"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_box": {
                          "$ref": "#/components/schemas/StoreShippingBoxDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-shipping-box",
        "summary": "Delete shipping box",
        "description": "Delete shipping box",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "shipping box id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/shipping-cost-policy": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-shipping-policy",
        "summary": "Retrieve shipping cost policy",
        "description": "Returns the shipping cost policy rules",
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "$ref": "#/components/schemas/ShippingCostPolicy"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "update-shipping-policy",
        "summary": "Create shipping cost policy",
        "description": "Create shipping cost policy",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ShippingCostPolicy"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "$ref": "#/components/schemas/ShippingCostPolicy"
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/store/shipping-options/add": {
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "add-shipping-option",
        "summary": "Add shipping options",
        "description": "Add shipping options for specified warehouse and shipping zone.",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ManageShippingOption"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/shipping-options/remove": {
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "remove-shipping-option",
        "summary": "Remove shipping options",
        "description": "Remove shipping options for specified warehouse and shipping zone.",
        "parameters": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ManageShippingOption"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/shipping-zones": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-shipping-zones",
        "summary": "List all shipping zones",
        "description": "List all shipping zones",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_zone": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ShippingZoneDetail"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-shipping-zone",
        "summary": "Create a shipping zone",
        "description": "Create a shipping zone",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateShippingZone"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_zone": {
                          "$ref": "#/components/schemas/ShippingZoneDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/shipping-zones/{id}": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-shipping-zone",
        "summary": "Retrieve shipping zone detail",
        "description": "Retrieve shipping zone detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_zones": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ShippingZoneDetail"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-shipping-zone",
        "summary": "Update shipping zone detail",
        "description": "Update shipping zone detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateShippingZone"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "shipping_zone": {
                          "$ref": "#/components/schemas/ShippingZoneDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-shipping-zone",
        "summary": "Delete shipping zone",
        "description": "Delete shipping zone",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "shipping zone id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/sse/global-state": {
      "get": {
        "tags": [
          "SSE"
        ],
        "operationId": "get-global-state",
        "summary": "Retrieve global state",
        "description": "Opens a server-sent events stream that pushes store configuration changes. Each event's `data` field carries a JSON-encoded payload with the event name and the updated `StoreConfig` object.",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Event stream opened. The connection stays open and emits events as the store state changes.",
            "content": {
              "text/event-stream": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "event_name": {
                      "type": "string"
                    },
                    "data": {
                      "$ref": "#/components/schemas/StoreConfig"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/sse/live-events": {
      "get": {
        "tags": [
          "SSE"
        ],
        "operationId": "get-live-events",
        "summary": "Retrieve live events",
        "description": "Opens a server-sent events stream of live storefront activity. Each event's `data` field carries a JSON-encoded `AnalyticsEvent` object.",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Event stream opened. The connection stays open and emits an event for each analytics event as it occurs.",
            "content": {
              "text/event-stream": {
                "schema": {
                  "$ref": "#/components/schemas/AnalyticsEvent"
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/templates": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-templates",
        "summary": "List all templates",
        "description": "List all templates",
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "description": "search string",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "templates": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/StoreTemplate"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-template",
        "summary": "Create template",
        "description": "Create template",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/StoreTemplateDetail"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "template": {
                          "$ref": "#/components/schemas/StoreTemplateDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/templates/{id}": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-template",
        "summary": "Retrieve template detail",
        "description": "Retrieve template detail",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "template": {
                          "$ref": "#/components/schemas/StoreTemplateDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-template",
        "summary": "Update template detail",
        "description": "Update template detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/StoreTemplateDetail"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "template": {
                          "$ref": "#/components/schemas/StoreTemplateDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-template",
        "summary": "Delete template",
        "description": "Delete template",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "template id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/store/warehouses": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "list-warehouses",
        "summary": "List all warehouses",
        "description": "List all warehouses",
        "parameters": [
          {
            "name": "accepts_returns",
            "in": "query",
            "description": "Accepts returned goods",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "active",
            "in": "query",
            "description": "active status",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "can_collect",
            "in": "query",
            "description": "Customer can collect parcel or not",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "can_receive_stock",
            "in": "query",
            "description": "Can receive stock",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "can_ship_parcel",
            "in": "query",
            "description": "Can ship parcel",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "is_checkout_point",
            "in": "query",
            "description": "Supports pos devices or not",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "warehouse_type",
            "in": "query",
            "description": "warehouse type",
            "schema": {
              "type": "string",
              "enum": [
                "retail-store",
                "distribution-center"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "warehouses": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/WarehouseDetail"
                          }
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Store"
        ],
        "operationId": "create-warehouse",
        "summary": "Create a warehouse",
        "description": "Create a warehouse",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWarehouse"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "warehouse": {
                          "$ref": "#/components/schemas/WarehouseDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/store/warehouses/{id}": {
      "get": {
        "tags": [
          "Store"
        ],
        "operationId": "get-warehouse",
        "summary": "Retrieve warehouse detail",
        "description": "Retrieve warehouse detail",
        "parameters": [
          {
            "name": "fulfillment_type",
            "in": "query",
            "description": "Optional. If provided, it will filter shipping methods on the returned `WarehouseDetail` (`shipping_providers`, `manual_methods`, `available_shipping_options`) to those supporting the given fulfillment type.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "delivery",
                "collect-in-store"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "warehouse": {
                          "$ref": "#/components/schemas/WarehouseDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Store"
        ],
        "operationId": "update-warehouse",
        "summary": "Update warehouse detail",
        "description": "Update warehouse detail",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWarehouse"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "warehouse": {
                          "$ref": "#/components/schemas/WarehouseDetail"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Store"
        ],
        "operationId": "delete-warehouse",
        "summary": "Delete warehouse",
        "description": "Delete warehouse",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "description": "warehouse id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/webhooks": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "list-webhooks",
        "summary": "List Webhooks",
        "description": "List of all webhooks",
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "items": {
                        "$ref": "#/components/schemas/Webhook"
                      },
                      "type": "array"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "post": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "create-webhook",
        "summary": "Create Webhook",
        "description": "Create a new webhook for the store. The response returns the newly created webhook configuration.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "name",
                  "endpoint",
                  "events"
                ],
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "endpoint": {
                    "type": "string",
                    "format": "uri"
                  },
                  "events": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "example": "orders.created"
                    }
                  },
                  "custom_headers": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Webhook created successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "$ref": "#/components/schemas/Webhook"
                    }
                  }
                },
                "examples": {
                  "default": {
                    "value": {
                      "success": true,
                      "message": "Webhook created successfully",
                      "content": {
                        "created_at": "2025-03-25T12:00:00Z",
                        "custom_headers": {
                          "Authorization": "Bearer xyz123"
                        },
                        "endpoint": "https://example.com/hooks/order",
                        "events": [
                          "orders.created",
                          "orders.shipped"
                        ],
                        "id": "e8a17f04-449f-40d2-9248-818b935f3c01",
                        "modified_at": "2025-03-25T12:00:00Z",
                        "name": "Order Webhook",
                        "status": "active",
                        "webhook_secret_key": "whsec_9e91f874..."
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      }
    },
    "/webhooks/deliveries": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "list-webhook-logs",
        "summary": "List All Deliveries Log",
        "description": "Paginated list of delivery attempts made across all webhooks. Supports optional filtering by `webhook_id` and `event_id`.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "logs": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/WebhookDeliveryLog"
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "required": [
                        "logs",
                        "pagination"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/webhooks/deliveries/{delivery_id}": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "get-webhook-log-detail",
        "summary": "Get Delivery Log Detail",
        "description": "Get Delivery Log Detail",
        "parameters": [],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success",
                    "content"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    },
                    "content": {
                      "properties": {
                        "log": {
                          "$ref": "#/components/schemas/WebhookDeliveryLogDetail"
                        }
                      },
                      "required": [
                        "log"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "delivery_id",
          "in": "path",
          "description": "delivery id",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/webhooks/event-types": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "list-webhook-event-types",
        "summary": "List all event types",
        "description": "List all event types",
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "items": {
                        "$ref": "#/components/schemas/WebhookEventType"
                      },
                      "type": "array"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          }
        }
      },
      "parameters": []
    },
    "/webhooks/events": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "list-webhook-events",
        "summary": "List All Events",
        "description": "List all events.",
        "parameters": [
          {
            "$ref": "#/components/parameters/pageNumber"
          },
          {
            "$ref": "#/components/parameters/pageLimit"
          },
          {
            "$ref": "#/components/parameters/sortByOptions"
          },
          {
            "$ref": "#/components/parameters/searchKeyword"
          },
          {
            "$ref": "#/components/parameters/columnBasedFilters"
          }
        ],
        "responses": {
          "200": {
            "description": "Events fetched successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "events": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "required": [
                              "event_id",
                              "event",
                              "timestamp",
                              "is_test"
                            ],
                            "properties": {
                              "event_id": {
                                "type": "string"
                              },
                              "event": {
                                "type": "string"
                              },
                              "timestamp": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "is_test": {
                                "type": "boolean"
                              }
                            }
                          }
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/Pagination"
                        }
                      },
                      "required": [
                        "events"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/webhooks/events/{event_id}": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "get-webhook-event-detail",
        "summary": "Get Event Details",
        "description": "Fetch the original event payload and metadata, including all related delivery attempts.",
        "responses": {
          "200": {
            "description": "Event fetched successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "$ref": "#/components/schemas/WebhookEventDetail"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "event_id",
          "in": "path",
          "description": "Unique identifier of the event to retrieve",
          "required": true,
          "schema": {
            "type": "string",
            "format": "ulid"
          }
        }
      ]
    },
    "/webhooks/filter-options": {
      "get": {
        "tags": [
          "Filter Options"
        ],
        "operationId": "list-webhooks-filter-options",
        "summary": "List all webhooks filter options",
        "description": "List all filter options for webhooks listing data.",
        "parameters": [
          {
            "name": "listing_type",
            "in": "query",
            "description": "name of listing api",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/FilterOptionListingType"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "filter_options": {
                          "$ref": "#/components/schemas/FilterOptions"
                        }
                      },
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        }
      },
      "parameters": []
    },
    "/webhooks/metrics/stats": {
      "get": {
        "tags": [
          "Metrics"
        ],
        "operationId": "get-webhook-metrics",
        "summary": "Retrieve webhook stats",
        "description": "Retrieve webhook stats",
        "parameters": [
          {
            "name": "date_from",
            "in": "query",
            "description": "start datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "end datetime",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "interval",
            "in": "query",
            "description": "for aggregating data",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "hour",
                "day",
                "week",
                "month"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Webhook stats retrieved successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "stats": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "required": [
                              "date",
                              "metrics"
                            ],
                            "properties": {
                              "date": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "metrics": {
                                "$ref": "#/components/schemas/WebhookStats"
                              }
                            }
                          }
                        },
                        "lifetime_stats": {
                          "$ref": "#/components/schemas/WebhookStats"
                        }
                      },
                      "required": [
                        "stats",
                        "lifetime_stats"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": []
    },
    "/webhooks/{webhook_id}": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "get-webhook-detail",
        "summary": "Get Webhook Details",
        "description": "Retrieve details of a single webhook by its ID.",
        "responses": {
          "200": {
            "description": "Webhook details",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "$ref": "#/components/schemas/Webhook"
                    }
                  }
                },
                "examples": {
                  "default": {
                    "value": {
                      "success": true,
                      "message": "Webhook retrieved successfully",
                      "content": {
                        "created_at": "2025-03-25T12:00:00Z",
                        "custom_headers": {
                          "Authorization": "Bearer xyz123"
                        },
                        "endpoint": "https://example.com/hooks/order",
                        "events": [
                          "orders.created",
                          "orders.shipped"
                        ],
                        "id": "e8a17f04-449f-40d2-9248-818b935f3c01",
                        "modified_at": "2025-03-25T12:00:00Z",
                        "name": "Order Webhook",
                        "status": "active",
                        "webhook_secret_key": "whsec_9e91f874..."
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "put": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "update-webhook",
        "summary": "Update Webhook",
        "description": "Update an existing webhook by replacing all fields.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Webhook"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Webhook updated successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "$ref": "#/components/schemas/Webhook"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "delete": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "delete-webhook",
        "summary": "Delete Webhook",
        "description": "Permanently delete a webhook by its ID.",
        "responses": {
          "200": {
            "description": "Webhook deleted successfully. No content returned.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "message",
                    "success"
                  ],
                  "properties": {
                    "message": {
                      "type": "string"
                    },
                    "success": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "webhook_id",
          "in": "path",
          "description": "Webhook ID",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/webhooks/{webhook_id}/deliveries/{delivery_id}/retry": {
      "post": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "retry-webhook-delivery",
        "summary": "Retry Webhook Delivery",
        "description": "Manually retry a specific delivery log by re-sending the same payload to the configured webhook endpoint.",
        "responses": {
          "200": {
            "description": "Webhook retried successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "delivery_id": {
                          "description": "New delivery attempt ID for this replay",
                          "type": "string",
                          "format": "ulid"
                        }
                      },
                      "required": [
                        "delivery_id"
                      ],
                      "type": "object"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "delivery_id",
          "in": "path",
          "description": "The ID of the delivery attempt to retry",
          "required": true,
          "schema": {
            "type": "string",
            "format": "uuid"
          }
        },
        {
          "name": "webhook_id",
          "in": "path",
          "description": "The ID of the webhook",
          "required": true,
          "schema": {
            "type": "string",
            "format": "uuid"
          }
        }
      ]
    },
    "/webhooks/{webhook_id}/replay-event/{event_id}": {
      "post": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "replay-webhook-event",
        "summary": "Replay Event to Webhook",
        "description": "Replay an existing event to a specific webhook. This triggers a new delivery with a fresh delivery_id.",
        "responses": {
          "200": {
            "description": "Webhook replay queued",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "delivery_id": {
                          "description": "New delivery attempt ID for this replay",
                          "type": "string",
                          "format": "ulid"
                        }
                      },
                      "required": [
                        "delivery_id"
                      ],
                      "type": "object"
                    }
                  }
                },
                "examples": {
                  "default": {
                    "value": {
                      "success": true,
                      "message": "Replay successfully queued",
                      "content": {
                        "delivery_id": "01HV6J6G8R3CE2PY4WJZ6ZTKCV"
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "event_id",
          "in": "path",
          "description": "The ID of the event to replay",
          "required": true,
          "schema": {
            "type": "string",
            "format": "ulid"
          }
        },
        {
          "name": "webhook_id",
          "in": "path",
          "description": "The ID of the webhook to send the replay to",
          "required": true,
          "schema": {
            "type": "string",
            "format": "uuid"
          }
        }
      ]
    },
    "/webhooks/{webhook_id}/rotate-secret": {
      "post": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "rotate-webhook-secret",
        "summary": "Rotate Webhook Secret",
        "description": "Rotate the webhook's HMAC secret. The new secret is returned once and used to sign future webhook requests.",
        "responses": {
          "200": {
            "description": "Secret rotated successfully",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message",
                    "content"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "webhook_secret_key": {
                          "description": "The new HMAC secret key (only shown once)",
                          "type": "string",
                          "example": "whsec_c8a0f9d7a12fbc1f388db1c621730fb935182ef918de3b7e36e77dcf99c44f9"
                        }
                      },
                      "required": [
                        "webhook_secret_key"
                      ],
                      "type": "object"
                    }
                  }
                },
                "examples": {
                  "default": {
                    "value": {
                      "success": true,
                      "message": "Webhook secret rotated successfully",
                      "content": {
                        "webhook_secret_key": "whsec_c8a0f9d7a12fbc1f388db1c621730fb935182ef918de3b7e36e77dcf99c44f9"
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "webhook_id",
          "in": "path",
          "description": "Webhook ID",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    },
    "/webhooks/{webhook_id}/test": {
      "post": {
        "tags": [
          "Webhooks"
        ],
        "operationId": "send-test-webhook",
        "summary": "Send Test Webhook",
        "description": "Sends a test webhook to the configured callback URL. You may optionally provide a test payload.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "event": {
                    "description": "The event type to simulate",
                    "type": "string",
                    "example": "orders.created"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Test webhook sent",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "success",
                    "message"
                  ],
                  "properties": {
                    "success": {
                      "type": "boolean"
                    },
                    "message": {
                      "type": "string"
                    },
                    "content": {
                      "properties": {
                        "delivery_id": {
                          "description": "New delivery attempt ID for this replay",
                          "type": "string",
                          "format": "ulid"
                        }
                      },
                      "required": [
                        "delivery_id"
                      ],
                      "type": "object"
                    }
                  }
                },
                "examples": {
                  "default": {
                    "value": {
                      "success": true,
                      "message": "Test webhook sent successfully"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "parameters": [
        {
          "name": "webhook_id",
          "in": "path",
          "description": "The ID of the webhook to send a test to",
          "required": true,
          "schema": {
            "type": "string",
            "format": "uuid"
          }
        }
      ]
    }
  },
  "components": {
    "schemas": {
      "AbandonedCart": {
        "title": "AbandonedCart",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "active": {
            "type": "boolean"
          },
          "cart_items_count": {
            "type": "integer"
          },
          "email": {
            "type": [
              "string",
              "null"
            ]
          },
          "phone": {
            "type": [
              "string",
              "null"
            ]
          },
          "first_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_promotion_applied": {
            "type": "boolean"
          },
          "promotion_discount_percent": {
            "type": "number"
          },
          "promotion_discount_amount": {
            "type": "number"
          },
          "is_coupon_applied": {
            "type": "boolean"
          },
          "coupon_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_discount_percent": {
            "type": "number"
          },
          "coupon_discount_amount": {
            "type": "number"
          },
          "loyalty_point_redeemed": {
            "type": "number"
          },
          "loyalty_point_earned": {
            "type": "number"
          },
          "credit_balance_used": {
            "type": "number"
          },
          "currency": {
            "$ref": "#/components/schemas/Currency"
          },
          "metadata": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "cart_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AbandonedCartItem"
            }
          },
          "expires_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "subtotal": {
            "type": "number"
          },
          "item_total_tax": {
            "type": "number"
          },
          "subtotal_including_tax": {
            "type": "number"
          },
          "shipping_amount": {
            "type": "number"
          },
          "shipping_total_tax": {
            "type": "number"
          },
          "shipping_amount_including_tax": {
            "type": "number"
          },
          "total_tax": {
            "type": "number"
          },
          "grand_total": {
            "type": "number"
          },
          "to_be_paid": {
            "type": "number"
          }
        }
      },
      "AbandonedCartItem": {
        "title": "AbandonedCartItem",
        "type": "object",
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "product_image_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "sku": {
            "type": "string"
          },
          "product_variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "quantity": {
            "type": "integer"
          },
          "free_quantity": {
            "type": "integer"
          },
          "is_free_item": {
            "type": "boolean"
          },
          "listing_price": {
            "type": "number"
          },
          "selling_price": {
            "type": "number"
          },
          "selling_price_excluding_tax": {
            "type": "number"
          },
          "tax_rate": {
            "type": "number"
          },
          "tax_type": {
            "type": "string"
          }
        }
      },
      "AcceleratedRewardByQuantity": {
        "title": "AcceleratedRewardByQuantity",
        "type": "object",
        "required": [
          "product_id",
          "variant_id",
          "minimum_quantity",
          "minimum_value"
        ],
        "properties": {
          "product_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "minimum_quantity": {
            "type": "integer",
            "minimum": 1
          },
          "minimum_value": {
            "type": [
              "number",
              "null"
            ]
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "AcceleratedRewardByValue": {
        "title": "AcceleratedRewardByValue",
        "type": "object",
        "required": [
          "product_id",
          "variant_id",
          "minimum_quantity",
          "minimum_value"
        ],
        "properties": {
          "product_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "minimum_quantity": {
            "type": [
              "integer",
              "null"
            ]
          },
          "minimum_value": {
            "type": "number",
            "minimum": 1
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "AcceleratedRewardCouponPromotion": {
        "title": "AcceleratedRewardCouponPromotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "details",
              "applies_to_product"
            ],
            "properties": {
              "details": {
                "$ref": "#/components/schemas/AcceleratedRewardRule"
              },
              "applies_to_product": {
                "enum": [
                  "product",
                  "category"
                ]
              }
            }
          }
        ]
      },
      "AcceleratedRewardRule": {
        "title": "AcceleratedRewardRule",
        "type": "object",
        "required": [
          "products",
          "category_id",
          "bonus_loyalty_point"
        ],
        "properties": {
          "products": {
            "type": "array",
            "items": {
              "description": "A product earns the bonus by minimum quantity or by minimum value, never both.",
              "oneOf": [
                {
                  "$ref": "#/components/schemas/AcceleratedRewardByQuantity"
                },
                {
                  "$ref": "#/components/schemas/AcceleratedRewardByValue"
                }
              ]
            }
          },
          "category_id": {
            "description": "Array of category ids.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "bonus_loyalty_point": {
            "type": "integer"
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "Address": {
        "title": "Address",
        "type": "object",
        "required": [
          "first_name",
          "phone",
          "email",
          "address_line1",
          "pincode",
          "city",
          "state",
          "country"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "first_name": {
            "type": "string"
          },
          "last_name": {
            "type": "string"
          },
          "country_code": {
            "description": "Two-letter code begin with a plus sign prefix that identifies different countries. By default it will be +91 if not provided.\r\n",
            "type": "string"
          },
          "phone": {
            "description": "10 digit phone number without country code.",
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "address_line1": {
            "type": "string"
          },
          "address_line2": {
            "type": [
              "string",
              "null"
            ]
          },
          "landmark": {
            "type": [
              "string",
              "null"
            ]
          },
          "pincode": {
            "type": "string"
          },
          "city": {
            "type": "string"
          },
          "state": {
            "type": "string"
          },
          "country": {
            "enum": [
              "India"
            ]
          },
          "gstin": {
            "description": "Use in shipping details only for third party.",
            "type": [
              "string",
              "null"
            ]
          },
          "business_name": {
            "description": "Use in shipping details only for third party.",
            "type": [
              "string",
              "null"
            ]
          },
          "is_phone_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_email_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "is_default_billing": {
            "type": "boolean"
          },
          "is_default_shipping": {
            "type": "boolean"
          }
        },
        "examples": [],
        "x-tags": [
          "Customers"
        ]
      },
      "AnalyticsActivity": {
        "title": "AnalyticsActivity",
        "type": "object",
        "properties": {
          "id": {
            "description": "The customer activities endpoint sends an integer; the analytics session detail endpoint sends the same ID as a numeric string.",
            "type": [
              "integer",
              "string"
            ]
          },
          "event_type": {
            "enum": [
              "track",
              "page",
              "identify"
            ]
          },
          "event_name": {
            "type": "string"
          },
          "event_schema_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "session_id": {
            "type": "string"
          },
          "session_origin_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "session_last_seen": {
            "type": "string",
            "format": "date-time"
          },
          "user_id": {
            "type": "string"
          },
          "event_data": {
            "description": "analytic event raw json object.",
            "type": "object"
          },
          "channel": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "message_id": {
            "type": "string"
          },
          "original_timestamp": {
            "type": "string",
            "format": "date-time"
          },
          "sent_at": {
            "type": "string",
            "format": "date-time"
          },
          "received_at": {
            "type": "string",
            "format": "date-time"
          },
          "anonymous_id": {
            "description": "in case user id is missing.",
            "type": [
              "string",
              "null"
            ]
          }
        },
        "x-tags": [
          "Analytics"
        ]
      },
      "AnalyticsChartRow": {
        "title": "AnalyticsChartRow",
        "type": "object",
        "properties": {
          "business_name": {
            "description": "Returned when `chart_type` is `top_customers`. Coalesced billing or customer business name.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "additionalProperties": true
      },
      "AnalyticsChartsInfo": {
        "title": "AnalyticsChartsInfo",
        "type": "object",
        "required": [
          "stats"
        ],
        "properties": {
          "user_params": {
            "type": "object",
            "additionalProperties": true
          },
          "query_params": {
            "type": "object",
            "additionalProperties": true
          },
          "queries": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "stats": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AnalyticsChartRow"
            }
          }
        }
      },
      "AnalyticsEvent": {
        "title": "AnalyticsEvent",
        "type": "object",
        "properties": {
          "id": {
            "type": "integer"
          },
          "event_type": {
            "enum": [
              "track",
              "page",
              "identify"
            ]
          },
          "event_name": {
            "type": "string"
          },
          "user_id": {
            "type": "string"
          },
          "event_data": {
            "type": "object"
          },
          "channel": {
            "type": "string"
          },
          "store_id": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "message_id": {
            "type": "string"
          },
          "original_timestamp": {
            "type": "string",
            "format": "date-time"
          },
          "sent_at": {
            "type": "string",
            "format": "date-time"
          },
          "received_at": {
            "type": "string",
            "format": "date-time"
          },
          "anonymous_id": {
            "type": "string"
          },
          "origin_source": {
            "type": "string"
          },
          "origin_url": {
            "type": "string"
          },
          "session_created_at": {
            "type": "string",
            "format": "date-time"
          },
          "session_last_seen": {
            "type": "string",
            "format": "date-time"
          },
          "session_id": {
            "type": "string"
          },
          "utm_params": {
            "type": "object"
          },
          "initial_origin_url": {
            "type": "string"
          },
          "initial_origin_source": {
            "type": "string"
          },
          "initial_utm_params": {
            "type": "object"
          }
        }
      },
      "AnalyticsEventSchemaChildProperty": {
        "title": "AnalyticsEventSchemaChildProperty",
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "data_type": {
            "enum": [
              "string",
              "number",
              "boolean",
              "datetime",
              "json"
            ]
          },
          "properties": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string"
                },
                "data_type": {
                  "enum": [
                    "string",
                    "number",
                    "boolean",
                    "datetime"
                  ]
                }
              }
            }
          }
        },
        "x-tags": [
          "Analytics"
        ]
      },
      "AnalyticsEventSchemaDetail": {
        "title": "AnalyticsEventSchemaDetail",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "schema": {
            "type": "object",
            "properties": {
              "properties": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/AnalyticsEventSchemaProperty"
                }
              }
            }
          }
        },
        "x-tags": [
          "Analytics"
        ]
      },
      "AnalyticsEventSchemaProperty": {
        "title": "AnalyticsEventSchemaProperty",
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "data_type": {
            "enum": [
              "string",
              "number",
              "boolean",
              "datetime",
              "json"
            ]
          },
          "properties": {
            "description": "this key will be available only if data_type is json.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AnalyticsEventSchemaChildProperty"
            }
          }
        },
        "x-tags": [
          "Analytics"
        ]
      },
      "AnalyticsQueryRow": {
        "title": "AnalyticsQueryRow",
        "description": "Query-dependent column names and JSON values. Consumers must narrow each value for the selected query.",
        "type": "object",
        "additionalProperties": true
      },
      "AnalyticsRawQueryInfo": {
        "title": "AnalyticsRawQueryInfo",
        "type": "object",
        "properties": {
          "data": {
            "description": "rows returned by raw query passed in request body.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AnalyticsQueryRow"
            }
          }
        }
      },
      "AnalyticsRecords": {
        "title": "AnalyticsRecords",
        "type": "object",
        "required": [
          "schema_name",
          "query_type",
          "query"
        ],
        "properties": {
          "schema_name": {
            "type": "string"
          },
          "query_type": {
            "enum": [
              "records"
            ]
          },
          "query": {
            "type": "object",
            "properties": {
              "fields": {
                "description": "multiple fields separated by comma.",
                "type": "string"
              },
              "filters": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/DynamicQueryFilter"
                }
              },
              "sort_by": {
                "description": "json object with key-value. example: {\"field1\":\"asc\",\"field2\":\"desc\"}",
                "type": "object"
              },
              "limit": {
                "type": "integer",
                "default": 25
              },
              "offset": {
                "type": "integer",
                "default": 0
              }
            },
            "required": [
              "fields"
            ]
          }
        },
        "x-tags": [
          "Analytics"
        ]
      },
      "AnalyticsSession": {
        "title": "AnalyticsSession",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "last_seen": {
            "type": "string",
            "format": "date-time"
          },
          "origin_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "origin_source": {
            "type": [
              "string",
              "null"
            ]
          },
          "utm_params": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/UtmParam"
              },
              {
                "type": "null"
              }
            ]
          },
          "initial_origin_source": {
            "type": [
              "string",
              "null"
            ]
          },
          "initial_utm_params": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/UtmParam"
              },
              {
                "type": "null"
              }
            ]
          },
          "initial_origin_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "user_id": {
            "type": "string"
          },
          "is_anonymous": {
            "type": "boolean"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "AnalyticsStats": {
        "title": "AnalyticsStats",
        "type": "object",
        "required": [
          "schema_name",
          "query_type",
          "query"
        ],
        "properties": {
          "schema_name": {
            "description": "Different schema name will be as per the types of data required. ",
            "type": "string"
          },
          "query_type": {
            "enum": [
              "stats"
            ]
          },
          "query": {
            "type": "object",
            "properties": {
              "aggregate": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "type",
                    "field_name",
                    "alias"
                  ],
                  "properties": {
                    "type": {
                      "enum": [
                        "COUNT",
                        "SUM",
                        "MIN",
                        "MAX",
                        "AVG"
                      ]
                    },
                    "field_name": {
                      "type": "string"
                    },
                    "alias": {
                      "type": "string"
                    }
                  }
                }
              },
              "group_by": {
                "description": "multiple fields separated by comma.",
                "type": "object",
                "properties": {
                  "fields": {
                    "type": "string"
                  },
                  "having_condition": {
                    "description": "additional conditions on filters. only aggregate columns can be passed in having condition.",
                    "type": "array",
                    "items": {
                      "type": "object"
                    }
                  }
                }
              },
              "filters": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/DynamicQueryFilter"
                }
              },
              "sort_by": {
                "description": "json object with key-value. example: {\"field1\":\"asc\",\"field2\":\"desc\"}",
                "type": "object"
              },
              "limit": {
                "type": "integer",
                "default": 25
              },
              "offset": {
                "type": "integer",
                "default": 0
              }
            },
            "required": [
              "aggregate"
            ]
          }
        },
        "x-tags": [
          "Analytics"
        ]
      },
      "AppliedCoupon": {
        "title": "AppliedPromotion",
        "description": "Details about an active coupon applied to a cart/order",
        "type": "object",
        "required": [
          "coupon_id",
          "coupon_type",
          "savings",
          "product_id",
          "variant_id",
          "product_name",
          "variant_name"
        ],
        "properties": {
          "coupon_id": {
            "type": "string"
          },
          "coupon_type": {
            "enum": [
              "discount",
              "free-goods",
              "fixed-price",
              "free-shipping",
              "buy-x-get-y",
              "volume-based",
              "accelerated-rewards"
            ]
          },
          "savings": {
            "type": "number"
          },
          "product_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "product_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ]
          }
        }
      },
      "AppliedPromotion": {
        "title": "AppliedPromotion",
        "description": "Details about an active promotion applied to a cart/order",
        "type": "object",
        "required": [
          "promotion_id",
          "promotion_type",
          "savings",
          "product_id",
          "variant_id",
          "product_name",
          "variant_name",
          "applied_sequence",
          "scope"
        ],
        "properties": {
          "promotion_id": {
            "type": "string"
          },
          "promotion_type": {
            "enum": [
              "discount",
              "free-goods",
              "fixed-price",
              "free-shipping",
              "buy-x-get-y",
              "volume-based"
            ]
          },
          "savings": {
            "type": "number"
          },
          "product_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "product_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "applied_sequence": {
            "type": "number"
          },
          "scope": {
            "type": "string"
          }
        }
      },
      "AssignCategoryToProductsRequest": {
        "title": "AssignCategoryToProductsRequest",
        "type": "object",
        "required": [
          "category_id",
          "product_id"
        ],
        "properties": {
          "category_id": {
            "type": "string"
          },
          "product_id": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "AssociatedOption": {
        "title": "AssociatedOption",
        "type": "object",
        "required": [
          "attribute_id",
          "attribute_value"
        ],
        "properties": {
          "attribute_id": {
            "type": "string"
          },
          "attribute_value": {
            "oneOf": [
              {
                "type": "string",
                "description": "Attributes with type of **single-select**, the value will be represented as a **string**."
              },
              {
                "$ref": "#/components/schemas/ColorObject",
                "description": "**Color** attributes will have their value represented as a color object, specifying the color details with name and hexcode."
              }
            ]
          },
          "attribute_name": {
            "type": "string",
            "readOnly": true
          },
          "attribute_type": {
            "enum": [
              "single-select",
              "color"
            ],
            "readOnly": true
          },
          "key": {
            "description": "value in snake case.",
            "type": "string",
            "readOnly": true
          }
        }
      },
      "Attribute": {
        "title": "Attribute",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "attribute_type": {
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "single-select",
              "multi-select",
              "color"
            ]
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "supports_variant_creation": {
            "type": "boolean"
          },
          "product_count": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "AttributeBasicDetail": {
        "title": "AttributeBasicDetail",
        "type": "object",
        "required": [
          "id",
          "name",
          "key",
          "type"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "key": {
            "type": "string"
          },
          "type": {
            "type": "string"
          }
        }
      },
      "AttributeConfig": {
        "title": "AttributeConfig",
        "type": "object",
        "required": [
          "id",
          "is_required",
          "default_value"
        ],
        "properties": {
          "id": {
            "description": "Attribute id",
            "type": "string"
          },
          "is_required": {
            "type": "boolean"
          },
          "default_value": {
            "type": [
              "string",
              "null"
            ]
          }
        }
      },
      "AttributeConfigDetail": {
        "title": "AttributeConfigDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/AttributeBasicDetail"
          },
          {
            "type": "object",
            "properties": {
              "is_required": {
                "type": "boolean"
              },
              "default_value": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "is_required",
              "default_value"
            ]
          }
        ]
      },
      "AttributeSet": {
        "title": "AttributeSet",
        "type": "object",
        "required": [
          "id",
          "name",
          "attributes"
        ],
        "properties": {
          "id": {
            "description": "Attribute set id",
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AttributeBasicDetail"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        }
      },
      "AttributeSetConfigDetail": {
        "title": "AttributeSetConfigDetail",
        "type": "object",
        "required": [
          "id",
          "name",
          "attributes"
        ],
        "properties": {
          "id": {
            "description": "Attribute set id",
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AttributeConfigDetail"
            }
          }
        }
      },
      "AuthorizedSellerInfo": {
        "title": "AuthorizedSellerInfo",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "trade_name": {
            "type": "string"
          },
          "legal_name": {
            "type": "string"
          },
          "business_type": {
            "$ref": "#/components/schemas/SellerBusinessType"
          },
          "tax_identification_number": {
            "type": "string"
          },
          "status": {
            "$ref": "#/components/schemas/SellerAccountStatus"
          },
          "kyc_status": {
            "$ref": "#/components/schemas/SellerKycStatus"
          },
          "visibility": {
            "description": "Visibility of the products of the seller. public: products are visible to all users, private: products are visible to only authenticated users.",
            "type": "string",
            "enum": [
              "public",
              "private"
            ]
          },
          "logo": {
            "type": [
              "string",
              "null"
            ]
          }
        }
      },
      "AutoPackingDetail": {
        "title": "AutoPackingDetail",
        "type": "object",
        "properties": {
          "packing_option": {
            "enum": [
              "auto"
            ]
          },
          "total_boxes": {
            "type": [
              "integer",
              "null"
            ]
          },
          "items_weight": {
            "type": "number"
          },
          "packing_bin_weight": {
            "type": "number"
          },
          "total_weight": {
            "type": "number"
          },
          "json_data": {
            "description": "json data of 3dbin packing.",
            "type": [
              "object",
              "null"
            ]
          }
        }
      },
      "AutoScaleBasedOnAmount": {
        "title": "AutoScaleBasedOnAmount",
        "type": "object",
        "required": [
          "spending_criteria_type",
          "products"
        ],
        "properties": {
          "spending_criteria_type": {
            "type": "string",
            "const": "minimum-purchase-amount"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "product_id",
                "variant_id",
                "auto_scale",
                "slab"
              ],
              "properties": {
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_name": {
                  "type": "string",
                  "readOnly": true
                },
                "status": {
                  "type": "string",
                  "readOnly": true
                },
                "stock_available": {
                  "type": "string",
                  "readOnly": true
                },
                "images": {
                  "type": "string",
                  "readOnly": true
                },
                "product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "auto_scale": {
                  "type": "boolean"
                },
                "slab": {
                  "type": "object",
                  "properties": {
                    "minimum_purchase_amount": {
                      "type": "number"
                    },
                    "get_quantity": {
                      "type": "integer"
                    },
                    "condition": {
                      "enum": [
                        "greater-or-equal"
                      ]
                    }
                  },
                  "required": [
                    "minimum_purchase_amount",
                    "get_quantity",
                    "condition"
                  ]
                }
              }
            }
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "AutoScaleBasedOnQuantity": {
        "title": "AutoScaleBasedOnQuantity",
        "type": "object",
        "required": [
          "spending_criteria_type",
          "products"
        ],
        "properties": {
          "spending_criteria_type": {
            "type": "string",
            "const": "minimum-quantity"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "product_id",
                "variant_id",
                "auto_scale",
                "slab"
              ],
              "properties": {
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_name": {
                  "type": "string",
                  "readOnly": true
                },
                "status": {
                  "type": "string",
                  "readOnly": true
                },
                "stock_available": {
                  "type": "string",
                  "readOnly": true
                },
                "images": {
                  "type": "string",
                  "readOnly": true
                },
                "product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "auto_scale": {
                  "type": "boolean"
                },
                "slab": {
                  "type": "object",
                  "properties": {
                    "buy_quantity": {
                      "type": "integer"
                    },
                    "get_quantity": {
                      "type": "integer"
                    },
                    "condition": {
                      "enum": [
                        "greater-or-equal"
                      ]
                    }
                  },
                  "required": [
                    "buy_quantity",
                    "get_quantity",
                    "condition"
                  ]
                }
              }
            }
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "AvailablePaymentOption": {
        "title": "AvailablePaymentOption",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "description": {
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ]
          },
          "is_connected": {
            "description": "Derived from `status`. `true` when `status` is `active`.",
            "type": "boolean",
            "readOnly": true
          },
          "type": {
            "description": "`manual` for store-defined payment methods; `auto` for connected payment service providers.",
            "enum": [
              "auto",
              "manual"
            ]
          },
          "supports_credit_line": {
            "description": "`true` when the option can be used for credit-line settlement. Always `true` for `auto` credit-line providers; for `manual` methods, reflects store credit-line configuration.",
            "type": "boolean"
          },
          "used_in_credit_line": {
            "description": "`true` when the option is linked in the store credit-line payment method configuration.",
            "type": "boolean",
            "readOnly": true
          },
          "supports_payout": {
            "description": "`true` when the option can be used to settle seller payout batches.",
            "type": "boolean"
          },
          "used_in_payout": {
            "description": "`true` when the option is linked in the store `payout` configuration.",
            "type": "boolean",
            "readOnly": true
          },
          "logo": {
            "description": "Primary logo URL. Same as `logo_light` for `auto` providers; `null` for `manual` methods.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_dark": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_light": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "AvailableShippingOption": {
        "title": "AvailableShippingOption",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_connected": {
            "type": "boolean"
          },
          "is_forward_shipping": {
            "type": "boolean"
          },
          "is_return_shipping": {
            "type": "boolean"
          },
          "logo": {
            "type": [
              "string",
              "null"
            ]
          },
          "logo_dark": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_light": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "type": {
            "enum": [
              "auto",
              "manual"
            ]
          },
          "fulfillment_type": {
            "enum": [
              "delivery",
              "collect-in-store"
            ]
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ]
          },
          "warehouses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                }
              }
            }
          },
          "shipping_zone": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                }
              }
            }
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "BankTransfer": {
        "title": "BankTransfer",
        "description": "Bank transfer payment - IMPS, NEFT, RTGS",
        "allOf": [
          {
            "$ref": "#/components/schemas/OrderPaymentInfo"
          },
          {
            "type": "object",
            "properties": {
              "bank_account_number": {
                "description": "masked account number\r\ne.g. ************1234",
                "type": [
                  "string",
                  "null"
                ]
              },
              "bank_name": {
                "type": [
                  "string",
                  "null"
                ]
              }
            }
          }
        ]
      },
      "BooleanAttribute": {
        "title": "BooleanAttribute",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "is_linked": {
            "type": "boolean",
            "readOnly": true
          },
          "value": {
            "description": "`null` when no value is set for this customer.",
            "type": [
              "boolean",
              "null"
            ]
          },
          "attribute_type": {
            "enum": [
              "Boolean"
            ]
          },
          "is_readonly": {
            "type": "boolean",
            "readOnly": true
          },
          "is_pinned": {
            "description": "Whether the attribute is pinned to the top of the customer profile.",
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "last_updated_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "Brand": {
        "title": "Brand",
        "type": "object",
        "properties": {
          "name": {
            "description": "brand name. it will be used in emails and other communications.",
            "type": "string"
          },
          "logo_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "file_id": {
            "description": "Media gallery file id for the brand logo. Omitted or `null` when no logo file is linked.",
            "type": [
              "string",
              "null"
            ]
          },
          "social_media_links": {
            "description": "json object having key - value pair.\r\n\r\nexample - {\"facebook\": \"www.facebook.com/commecengine\"}",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "string"
            }
          }
        },
        "additionalProperties": true,
        "x-tags": [
          "Store"
        ]
      },
      "BundleDataSync": {
        "title": "BundleDataSync",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "sku": {
            "type": "string"
          },
          "listing_price": {
            "type": "number"
          },
          "selling_price": {
            "type": "number"
          },
          "image_url": {
            "type": "string"
          },
          "stock_available": {
            "type": "boolean"
          },
          "status": {
            "type": "string"
          },
          "last_synced_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "BusinessInfo": {
        "title": "BusinessInfo",
        "type": "object",
        "properties": {
          "name": {
            "type": [
              "string",
              "null"
            ]
          },
          "business_type": {
            "description": "Free text on existing records; new values are one of SellerBusinessType.",
            "type": [
              "string",
              "null"
            ]
          },
          "pan_number": {
            "type": [
              "string",
              "null"
            ]
          },
          "gstin": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_registered_under_gst": {
            "type": "boolean"
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "BuyXGetYCouponPromotion": {
        "title": "BuyXGetYCouponPromotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "details",
              "applies_to_product"
            ],
            "properties": {
              "details": {
                "$ref": "#/components/schemas/BuyXGetYRule"
              },
              "applies_to_product": {
                "type": "string",
                "const": "product"
              }
            }
          }
        ]
      },
      "BuyXGetYRule": {
        "title": "BuyXGetYRule",
        "oneOf": [
          {
            "$ref": "#/components/schemas/BuyXGetYRuleBasedOnQuantity"
          },
          {
            "$ref": "#/components/schemas/BuyXGetYRuleBasedOnAmount"
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "BuyXGetYRuleBasedOnAmount": {
        "title": "BuyXGetYRuleBasedOnAmount",
        "description": "Additional fields required in addition to marked as required.\n1) buy_product_id or buy_variant_id or buy_from_category_id\n2) get_product_id or get_variant_id or get_from_category_id\n3) get_free_quantity or get_discount_percent",
        "type": "object",
        "required": [
          "spending_criteria_type",
          "products",
          "maximum_discount_amount"
        ],
        "properties": {
          "spending_criteria_type": {
            "type": "string",
            "const": "minimum-purchase-amount"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "minimum_purchase_amount",
                "buy_product_id",
                "buy_variant_id",
                "buy_from_category_id",
                "get_product_id",
                "get_variant_id",
                "get_from_category_id",
                "get_quantity",
                "get_offer_type",
                "get_discount_percent"
              ],
              "properties": {
                "minimum_purchase_amount": {
                  "type": "number",
                  "minimum": 1
                },
                "buy_product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "buy_variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "buy_from_category_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "get_product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "get_variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "get_from_category_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "get_quantity": {
                  "type": "integer",
                  "minimum": 1
                },
                "get_offer_type": {
                  "enum": [
                    "discount",
                    "free"
                  ]
                },
                "get_discount_percent": {
                  "description": "It can be null for get_offer_type = free",
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "auto_scale": {
                  "type": "boolean",
                  "readOnly": true
                }
              }
            }
          },
          "maximum_discount_amount": {
            "description": "It can be null for get_offer_type = free",
            "type": [
              "number",
              "null"
            ]
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "BuyXGetYRuleBasedOnQuantity": {
        "title": "BuyXGetYRuleBasedOnQuantity",
        "description": "Additional fields required in addition to marked as required.\n1) buy_product_id or buy_variant_id or buy_from_category_id\n2) get_product_id or get_variant_id or get_from_category_id\n3) get_free_quantity or get_discount_percent",
        "type": "object",
        "required": [
          "spending_criteria_type",
          "products",
          "maximum_discount_amount"
        ],
        "properties": {
          "spending_criteria_type": {
            "type": "string",
            "const": "minimum-quantity"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "minimum_quantity",
                "buy_product_id",
                "buy_variant_id",
                "buy_from_category_id",
                "get_product_id",
                "get_variant_id",
                "get_from_category_id",
                "get_quantity",
                "get_offer_type",
                "get_discount_percent"
              ],
              "properties": {
                "minimum_quantity": {
                  "type": "integer",
                  "minimum": 1
                },
                "buy_product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "buy_variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "buy_from_category_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "get_product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "get_variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "get_from_category_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "get_quantity": {
                  "type": "integer",
                  "minimum": 1
                },
                "get_offer_type": {
                  "enum": [
                    "discount",
                    "free"
                  ]
                },
                "get_discount_percent": {
                  "description": "It can be null for get_offer_type = free",
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "minimum_purchase_amount": {
                  "type": [
                    "number",
                    "null"
                  ],
                  "readOnly": true
                },
                "auto_scale": {
                  "type": "boolean",
                  "readOnly": true
                }
              }
            }
          },
          "maximum_discount_amount": {
            "description": "It can be null for get_offer_type = free",
            "type": [
              "number",
              "null"
            ]
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "CancelAndRefundShipment": {
        "title": "CancelAndRefundShipment",
        "description": "Cancel payload used when the shipment's payment must be refunded as part of the cancellation. The shipment is cancelled and a refund is initiated in the selected mode.",
        "type": "object",
        "required": [
          "action",
          "refund_mode"
        ],
        "properties": {
          "action": {
            "description": "Set to `cancel-and-refund` to cancel the shipment and initiate a refund.",
            "type": "string",
            "const": "cancel-and-refund"
          },
          "reason": {
            "description": "Reason recorded against the cancellation for audit and customer communication.",
            "type": "string"
          },
          "refund_amount": {
            "description": "Optional partial refund amount. Omit to refund the full shipment amount.",
            "type": "number"
          },
          "refund_mode": {
            "description": "How the refund is issued. Use `original-payment-mode` to refund back to the customer's original payment instrument, or `bank-transfer` to refund to a saved customer bank account.",
            "type": "string",
            "enum": [
              "original-payment-mode",
              "bank-transfer"
            ]
          },
          "bank_account_id": {
            "description": "The customer bank account to credit. Required when `refund_mode` is `bank-transfer`; omit or set to `null` for `original-payment`.",
            "type": [
              "string",
              "null"
            ]
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "CancelShipment": {
        "title": "CancelShipment",
        "description": "Cancel payload used when no refund is required. The shipment is marked as unscheduled and can be rescheduled with another carrier or fulfilled manually.",
        "type": "object",
        "required": [
          "action",
          "reason"
        ],
        "properties": {
          "action": {
            "description": "Set to `cancel` to cancel the shipment without issuing a refund.",
            "type": "string",
            "const": "cancel"
          },
          "reason": {
            "description": "Reason recorded against the cancellation for audit and customer communication.",
            "type": "string"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "CardPayment": {
        "title": "CardPayment",
        "description": "Payments using credit card, debit card",
        "allOf": [
          {
            "$ref": "#/components/schemas/OrderPaymentInfo"
          },
          {
            "type": "object",
            "properties": {
              "card_number": {
                "description": "masked card number\r\ne.g. ************1111",
                "type": [
                  "string",
                  "null"
                ]
              },
              "card_type": {
                "type": "string",
                "enum": [
                  "Visa",
                  "Master Card",
                  "Rupay"
                ]
              }
            }
          }
        ]
      },
      "CatalogDataSyncItem": {
        "title": "CatalogDataSyncItem",
        "type": "object",
        "oneOf": [
          {
            "$ref": "#/components/schemas/ProductDataSync"
          },
          {
            "$ref": "#/components/schemas/BundleDataSync"
          },
          {
            "$ref": "#/components/schemas/CategoryDataSync"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "CatalogDataSyncSummary": {
        "title": "CatalogDataSyncSummary",
        "type": "object",
        "properties": {
          "last_synced_at": {
            "type": "string",
            "format": "date-time"
          },
          "sync_status": {
            "enum": [
              "success",
              "failed"
            ]
          },
          "total_items": {
            "type": "integer"
          },
          "total_items_synced": {
            "type": "integer"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "CatalogJob": {
        "title": "CatalogJob",
        "type": "object",
        "required": [
          "job_id",
          "kind",
          "status",
          "input_data",
          "message",
          "marketplace_id",
          "created_at",
          "modified_at",
          "completed_at"
        ],
        "properties": {
          "job_id": {
            "type": "string"
          },
          "kind": {
            "type": "string",
            "enum": [
              "marketplace-sync"
            ]
          },
          "status": {
            "$ref": "#/components/schemas/CatalogJobStatus"
          },
          "input_data": {
            "type": "object"
          },
          "message": {
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "completed_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "CatalogJobDetail": {
        "title": "CatalogJobDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/CatalogJob"
          },
          {
            "type": "object",
            "properties": {
              "details": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CatalogJobDetailItem"
                }
              }
            }
          }
        ]
      },
      "CatalogJobDetailItem": {
        "title": "CatalogJobDetailItem",
        "type": "object",
        "properties": {
          "status": {
            "enum": [
              "success",
              "failed"
            ]
          },
          "product_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "product_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "error_message": {
            "type": [
              "string",
              "null"
            ]
          },
          "output_error_file": {
            "type": [
              "object",
              "null"
            ]
          }
        }
      },
      "CatalogJobStatus": {
        "enum": [
          "pending",
          "running",
          "success",
          "failed",
          "partial"
        ]
      },
      "Category": {
        "title": "Category",
        "allOf": [
          {
            "$ref": "#/components/schemas/CategoryCommonDetail"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "CategoryAttribute": {
        "title": "CategoryAttribute",
        "type": "object",
        "required": [
          "attribute_sets",
          "attributes"
        ],
        "properties": {
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AttributeConfigDetail"
            }
          },
          "attribute_sets": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AttributeSetConfigDetail"
            }
          }
        }
      },
      "CategoryCommonDetail": {
        "title": "CategoryCommonDetail",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "parent_category_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "slug": {
            "type": "string"
          },
          "product_count": {
            "type": "integer",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "auto_assign_products": {
            "type": "boolean",
            "readOnly": true
          },
          "assign_products_condition": {
            "description": "Filter that selects products auto-assigned to the category when `auto_assign_products` is `true`.",
            "anyOf": [
              {
                "$ref": "#/components/schemas/DataFilterObject"
              },
              {
                "type": "null"
              }
            ],
            "readOnly": true
          },
          "nested_level": {
            "description": "Depth in the category tree. `1` for a root category.",
            "type": "integer",
            "readOnly": true
          },
          "child_categories": {
            "description": "Direct children, each nesting its own `child_categories`.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ChildCategory"
            }
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "CategoryDataSync": {
        "title": "CategoryDataSync",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "status": {
            "type": "string"
          },
          "last_synced_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "CategoryDetail": {
        "title": "CategoryDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/Category"
          },
          {
            "type": "object",
            "properties": {
              "attributes": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/AttributeBasicDetail"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "CheckInventoryResponse": {
        "title": "CheckInventoryResponse",
        "type": "object",
        "properties": {
          "allowed_actions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/InventoryAction"
            }
          },
          "shipment_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentItem"
            }
          },
          "inventory_status": {
            "$ref": "#/components/schemas/InventoryStatus"
          },
          "inventory_detail": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "product_id": {
                  "type": "string"
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "product_name": {
                  "type": "string"
                },
                "variant_name": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "track_inventory": {
                  "type": "boolean"
                },
                "allow_backorder": {
                  "type": "boolean"
                },
                "requested_quantity": {
                  "type": "integer"
                },
                "stock_quantity": {
                  "type": "integer"
                },
                "inventory_status": {
                  "$ref": "#/components/schemas/InventoryStatus"
                },
                "warehouses": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "warehouse_id": {
                        "type": "string"
                      },
                      "warehouse_name": {
                        "type": "string"
                      },
                      "stock_quantity": {
                        "type": "integer"
                      },
                      "inventory_status": {
                        "$ref": "#/components/schemas/InventoryStatus"
                      }
                    }
                  }
                }
              }
            }
          },
          "recommended_warehouses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "inventory_status": {
                  "$ref": "#/components/schemas/InventoryStatus"
                }
              }
            }
          }
        }
      },
      "ChildCategory": {
        "title": "ChildCategory",
        "allOf": [
          {
            "$ref": "#/components/schemas/CategoryCommonDetail"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "CollectInStoreFulfillment": {
        "title": "CollectInStoreFulfillment",
        "type": "object",
        "required": [
          "fulfillment_type",
          "pickup_location_id"
        ],
        "properties": {
          "fulfillment_type": {
            "type": "string",
            "const": "collect-in-store"
          },
          "preference_type": {
            "type": "string",
            "enum": [
              "user",
              "auto"
            ],
            "readOnly": true
          },
          "pickup_location_id": {
            "type": "string"
          },
          "pickup_location_name": {
            "type": "string",
            "readOnly": true
          }
        }
      },
      "ColorObject": {
        "title": "ColorObject",
        "type": "object",
        "required": [
          "name",
          "hexcode"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "hexcode": {
            "type": "string"
          }
        }
      },
      "ColumnBasedFilterRule": {
        "title": "ColumnBasedFilterRule",
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "data",
              "attribute"
            ]
          },
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string"
          },
          "value": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            ]
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "Comparison": {
        "title": "Comparison",
        "oneOf": [
          {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "gt"
            ],
            "properties": {
              "gt": {
                "type": "number",
                "minimum": 0
              }
            },
            "title": "Greater than"
          },
          {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "gte"
            ],
            "properties": {
              "gte": {
                "type": "number",
                "minimum": 0
              }
            },
            "title": "Greater than or equal"
          },
          {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "lt"
            ],
            "properties": {
              "lt": {
                "type": "number",
                "minimum": 0
              }
            },
            "title": "Less than"
          },
          {
            "type": "object",
            "additionalProperties": false,
            "required": [
              "lte"
            ],
            "properties": {
              "lte": {
                "type": "number",
                "minimum": 0
              }
            },
            "title": "Less than or equal"
          }
        ]
      },
      "Country": {
        "title": "Country",
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "country_code": {
            "type": "string"
          },
          "iso_code": {
            "type": "string"
          },
          "currency_code": {
            "type": "string"
          },
          "currency_symbol": {
            "type": "string"
          },
          "currency_name": {
            "type": "string"
          },
          "flag_icon_url": {
            "type": "string"
          },
          "region": {
            "type": "string"
          },
          "alias": {
            "type": "string"
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "all_states": {
            "type": "boolean",
            "default": true
          },
          "states": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CountryState"
            }
          },
          "total_states": {
            "description": "Total number of states or provinces defined for the country in Commerce Engine.",
            "type": "integer",
            "readOnly": true
          },
          "states_count": {
            "description": "Number of states or provinces included in this shipping zone country entry.",
            "type": "integer",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CountryState": {
        "title": "CountryState",
        "type": "object",
        "properties": {
          "id": {
            "type": "integer",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "iso_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "gst_code": {
            "type": "string"
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "alias": {
            "type": "string"
          }
        }
      },
      "Coupon": {
        "title": "Coupon",
        "allOf": [
          {
            "oneOf": [
              {
                "$ref": "#/components/schemas/DiscountCouponPromotion"
              },
              {
                "$ref": "#/components/schemas/TieredDiscountCouponPromotion"
              },
              {
                "$ref": "#/components/schemas/FreeGoodCouponPromotion"
              },
              {
                "$ref": "#/components/schemas/FixedPriceCouponPromotion"
              },
              {
                "$ref": "#/components/schemas/BuyXGetYCouponPromotion"
              },
              {
                "$ref": "#/components/schemas/VolumeBasedCouponPromotion"
              },
              {
                "$ref": "#/components/schemas/FreeShippingCouponPromotion"
              },
              {
                "$ref": "#/components/schemas/AcceleratedRewardCouponPromotion"
              }
            ]
          },
          {
            "type": "object",
            "required": [
              "coupon_type",
              "coupon_code",
              "can_be_used_with_promotion"
            ],
            "properties": {
              "coupon_type": {
                "$ref": "#/components/schemas/CouponType"
              },
              "can_be_used_with_promotion": {
                "type": "boolean"
              },
              "coupon_code": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "application_rules": {
                "type": [
                  "object",
                  "null"
                ],
                "properties": {
                  "max_applicable_items": {
                    "type": "integer"
                  },
                  "application_priority": {
                    "enum": [
                      "cheapest_first",
                      "most_expensive_first",
                      "first_added"
                    ]
                  }
                },
                "required": [
                  "max_applicable_items",
                  "application_priority"
                ]
              },
              "visibility_scope": {
                "description": "visibility scope of the coupon. only public coupons are visible in storefront.",
                "type": "string",
                "default": "public",
                "enum": [
                  "public",
                  "private"
                ]
              },
              "terms_and_conditions": {
                "type": [
                  "array",
                  "null"
                ],
                "items": {
                  "type": "string"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "CouponDetail": {
        "title": "CouponDetail",
        "description": "Full coupon returned on create, retrieve, and update. Same shape as `Coupon`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/Coupon"
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "CouponPromotionCommonDetail": {
        "title": "CouponPromotionCommonDetail",
        "type": "object",
        "required": [
          "name",
          "status",
          "customer_eligibility",
          "starts_at"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "tags": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "active": {
            "type": "boolean",
            "readOnly": true
          },
          "status": {
            "description": "this key is ignored in create coupon api and draft status will be added by default. required in update coupon api only.",
            "allOf": [
              {
                "$ref": "#/components/schemas/CouponPromotionStatus"
              }
            ]
          },
          "customer_eligibility": {
            "enum": [
              "all",
              "customer",
              "segment",
              "customer-group"
            ]
          },
          "customer_id": {
            "description": "required if customer_eligibility = customer",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "segment_id": {
            "description": "required if customer_eligibility = segment",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "customer_group_id": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "redemption_limits": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "total_redemptions": {
                "type": [
                  "integer",
                  "null"
                ]
              },
              "per_customer_redemptions": {
                "type": [
                  "integer",
                  "null"
                ]
              },
              "per_coupon_code_redemptions": {
                "type": [
                  "integer",
                  "null"
                ]
              }
            },
            "required": [
              "total_redemptions",
              "per_customer_redemptions"
            ]
          },
          "redemption_count": {
            "type": "integer",
            "readOnly": true
          },
          "minimum_order_total": {
            "description": "Ignored when `coupon_type` or `promotion_type` is `tiered-discount`. Each slab in `details` defines its own `order_value` threshold.",
            "type": [
              "integer",
              "null"
            ],
            "default": 0
          },
          "for_first_time_customer_only": {
            "type": "boolean",
            "default": false
          },
          "can_earn_loyalty_points": {
            "type": "boolean",
            "default": true
          },
          "can_redeem_loyalty_points": {
            "type": "boolean",
            "default": true
          },
          "starts_at": {
            "type": "string",
            "format": "date-time"
          },
          "expires_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "CouponPromotionStatus": {
        "title": "CouponPromotionStatus",
        "type": "string",
        "enum": [
          "draft",
          "scheduled",
          "active",
          "inactive"
        ]
      },
      "CouponStats": {
        "title": "CouponStats",
        "type": "object",
        "properties": {
          "total_redemption": {
            "type": "integer"
          },
          "total_redemption_value": {
            "type": "number"
          },
          "order_amount": {
            "description": "Total value of the orders the coupon was redeemed on, as opposed to `total_redemption_value`, which is the discount the coupon gave.",
            "type": "number"
          }
        }
      },
      "CouponType": {
        "title": "CouponType",
        "type": "string",
        "enum": [
          "discount",
          "tiered-discount",
          "free-goods",
          "fixed-price",
          "free-shipping",
          "buy-x-get-y",
          "volume-based",
          "accelerated-rewards"
        ]
      },
      "CouponUsageCustomer": {
        "title": "CouponUsageCustomer",
        "type": "object",
        "properties": {
          "customer_id": {
            "type": "string"
          },
          "customer_name": {
            "type": "string"
          },
          "order_number": {
            "type": "string"
          },
          "order_count": {
            "type": "integer"
          },
          "total_order_amount": {
            "type": "number"
          },
          "redemption_date": {
            "type": "string",
            "format": "date-time"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "CreateAttribute": {
        "title": "CreateAttribute",
        "type": "object",
        "required": [
          "name",
          "attribute_type",
          "is_visible",
          "is_filterable"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "attribute_type": {
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "single-select",
              "multi-select",
              "color"
            ]
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "supports_variant_creation": {
            "description": "can be true for attribute types - single-select and color.",
            "type": "boolean"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "CreateAttributeSet": {
        "title": "CreateAttributeSet",
        "type": "object",
        "required": [
          "name",
          "attribute_id"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "attribute_id": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "CreateBankAccount": {
        "title": "CreateBankAccount",
        "discriminator": {
          "propertyName": "account_type",
          "mapping": {
            "outbound": "#/components/schemas/CreateOutboundBankAccount",
            "inbound": "#/components/schemas/CreateInboundBankAccount"
          }
        },
        "oneOf": [
          {
            "$ref": "#/components/schemas/CreateOutboundBankAccount"
          },
          {
            "$ref": "#/components/schemas/CreateInboundBankAccount"
          }
        ],
        "x-tags": [
          "Customers"
        ]
      },
      "CreateCategory": {
        "title": "CreateCategory",
        "type": "object",
        "required": [
          "name"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "parent_category_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "slug": {
            "type": "string"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "CreateCustomer": {
        "title": "CreateCustomer",
        "type": "object",
        "required": [
          "first_name",
          "last_name",
          "email"
        ],
        "properties": {
          "first_name": {
            "type": "string"
          },
          "last_name": {
            "type": "string"
          },
          "phone": {
            "description": "10 digit phone number without country code.",
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "profile_image_id": {
            "description": "file id of media gallery",
            "type": [
              "string",
              "null"
            ]
          },
          "customer_group_id": {
            "description": "Assigns the customer to a Customer Group, which drives group-specific pricing and promotions. Send `null` to fall back to the store's default group.",
            "type": [
              "string",
              "null"
            ]
          },
          "loyalty_tier_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "loyalty_tier_starting_point": {
            "type": [
              "integer",
              "null"
            ]
          },
          "business": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "name": {
                "type": "string"
              },
              "business_type": {
                "$ref": "#/components/schemas/SellerBusinessType"
              },
              "gstin": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "name",
              "business_type"
            ]
          },
          "kyc_documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KycDocument"
            }
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CreateDraftProduct": {
        "title": "CreateDraftProduct",
        "type": "object",
        "required": [
          "name",
          "product_type"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "product_type": {
            "enum": [
              "physical",
              "digital",
              "bundle"
            ]
          },
          "slug": {
            "description": "URL-friendly product identifier",
            "type": "string"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "CreateInboundBankAccount": {
        "title": "CreateInboundBankAccount",
        "type": "object",
        "required": [
          "account_type",
          "service_provider_slug"
        ],
        "properties": {
          "account_type": {
            "const": "inbound"
          },
          "service_provider_slug": {
            "type": "string"
          },
          "is_default": {
            "description": "Default bank account for the customer.",
            "type": "boolean"
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CreateOtherServiceProvider": {
        "title": "CreateOtherServiceProvider",
        "type": "object",
        "required": [
          "api_credentials"
        ],
        "properties": {
          "api_credentials": {
            "description": "json object in key & value pair. Keys must match with params specified in required_credentials_params object (input_field_name).",
            "type": "object"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CreateOutboundBankAccount": {
        "title": "CreateOutboundBankAccount",
        "type": "object",
        "required": [
          "account_type",
          "account_name",
          "account_number",
          "ifsc_code",
          "bank_name"
        ],
        "properties": {
          "account_type": {
            "const": "outbound"
          },
          "account_name": {
            "type": "string"
          },
          "account_number": {
            "type": "string"
          },
          "ifsc_code": {
            "type": "string"
          },
          "bank_name": {
            "type": "string"
          },
          "is_default": {
            "description": "Default bank account for the customer.",
            "type": "boolean"
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CreatePayment": {
        "title": "CreatePayment",
        "type": "object",
        "properties": {
          "customer_id": {
            "type": "string"
          },
          "order_number": {
            "description": "multiple order numbers are separated by comma.",
            "type": "string"
          },
          "payment_link": {
            "type": "string"
          }
        },
        "x-tags": [
          "Payments"
        ]
      },
      "CreatePosDevice": {
        "title": "CreatePosDevice",
        "type": "object",
        "required": [
          "name",
          "device_type",
          "external_device_id",
          "vendor",
          "model_number",
          "location_id"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "device_type": {
            "enum": [
              "pos-terminal"
            ]
          },
          "external_device_id": {
            "description": "A unique ID issued by the Vendor.",
            "type": "string"
          },
          "vendor": {
            "type": "string"
          },
          "model_number": {
            "type": "string"
          },
          "mac_address": {
            "type": [
              "string",
              "null"
            ]
          },
          "location_id": {
            "type": "string"
          }
        }
      },
      "CreatePosUser": {
        "title": "CreatePosUser",
        "type": "object",
        "required": [
          "first_name",
          "phone",
          "email",
          "roles"
        ],
        "properties": {
          "first_name": {
            "type": "string"
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "country_code": {
            "description": "Two-letter code begin with a plus sign prefix that identifies different countries. By default it will be +91 if not provided.",
            "type": "string",
            "default": "+91"
          },
          "phone": {
            "description": "10 digit phone number without country code.",
            "type": "string"
          },
          "email": {
            "type": "string",
            "format": "email"
          },
          "roles": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "location_id",
                "role_id"
              ],
              "properties": {
                "location_id": {
                  "type": "string"
                },
                "role_id": {
                  "type": "string"
                }
              }
            }
          }
        }
      },
      "CreateReplacementShipmentForCollectInStore": {
        "title": "CreateReplacementShipmentForCollectInStore",
        "description": "Replacement shipment payload when the customer collects the items from a store instead of having them delivered.",
        "type": "object",
        "required": [
          "warehouse_id",
          "shipment_items",
          "shipping_option",
          "shipping_provider_id",
          "packing_option",
          "reason"
        ],
        "properties": {
          "fulfillment_type": {
            "description": "Set to `collect-in-store` when the replacement is fulfilled via in-store pickup.",
            "type": "string",
            "const": "collect-in-store"
          },
          "warehouse_id": {
            "description": "The warehouse holding the replacement items for in-store pickup.",
            "type": "string"
          },
          "shipment_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentItem"
            }
          },
          "shipping_option": {
            "description": "Set to `manual` since in-store pickup is handled outside of an integrated carrier.",
            "enum": [
              "manual"
            ]
          },
          "shipping_provider_id": {
            "description": "The manual shipping provider associated with the in-store pickup flow.",
            "type": "string"
          },
          "packing_option": {
            "description": "The packing option for the replacement shipment.",
            "enum": [
              "manual",
              "auto"
            ]
          },
          "boxes": {
            "description": "The boxes for the replacement shipment.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentBox"
            }
          },
          "reason": {
            "description": "The reason for the replacement shipment.",
            "type": "string"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "CreateReplacementShipmentWithAutoMethod": {
        "title": "CreateReplacementShipmentWithAutoMethod",
        "description": "Replacement shipment payload when fulfilling through an integrated carrier.",
        "type": "object",
        "required": [
          "warehouse_id",
          "shipment_items",
          "shipping_option",
          "shipping_provider_id",
          "packing_option",
          "total_weight",
          "reason"
        ],
        "properties": {
          "fulfillment_type": {
            "description": "Set to `delivery` when the replacement is shipped to the customer.",
            "type": "string",
            "const": "delivery"
          },
          "warehouse_id": {
            "description": "The warehouse from which the replacement items will be shipped.",
            "type": "string"
          },
          "shipment_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentItem"
            }
          },
          "shipping_option": {
            "description": "Set to `auto` to dispatch the shipment through an integrated carrier.",
            "enum": [
              "auto"
            ]
          },
          "shipping_provider_id": {
            "description": "The integrated shipping provider used to fulfill the replacement.",
            "type": "string"
          },
          "packing_option": {
            "description": "Use `manual` to specify boxes explicitly, or `auto` to let the system pack on your behalf.",
            "enum": [
              "auto",
              "manual"
            ]
          },
          "boxes": {
            "description": "Box-wise packing breakdown. Required when `packing_option` is `manual`.",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "$ref": "#/components/schemas/ShipmentBox"
            }
          },
          "total_weight": {
            "description": "Total shipment weight in kilograms, used for rate calculation by the carrier.",
            "type": "number"
          },
          "courier_company_id": {
            "description": "Specific courier company to use. If omitted, the system selects the most suitable courier automatically.",
            "type": [
              "string",
              "null"
            ]
          },
          "reason": {
            "description": "The reason for the replacement shipment.",
            "type": "string"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "CreateReplacementShipmentWithManualMethod": {
        "title": "CreateReplacementShipmentWithManualMethod",
        "description": "Replacement shipment payload when fulfilling through a manual courier (no carrier integration).",
        "type": "object",
        "required": [
          "warehouse_id",
          "shipment_items",
          "shipping_option",
          "shipping_provider_id",
          "packing_option",
          "total_weight",
          "expected_delivery_date",
          "tracking_link",
          "manual_shipping_charges"
        ],
        "properties": {
          "fulfillment_type": {
            "description": "Set to `delivery` when the replacement is shipped to the customer.",
            "type": "string",
            "const": "delivery"
          },
          "warehouse_id": {
            "description": "The warehouse from which the replacement items will be shipped.",
            "type": "string"
          },
          "shipment_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentItem"
            }
          },
          "shipping_option": {
            "description": "Set to `manual` to dispatch the shipment outside of an integrated carrier.",
            "enum": [
              "manual"
            ]
          },
          "shipping_provider_id": {
            "description": "The manual shipping provider used to fulfill the replacement.",
            "type": "string"
          },
          "packing_option": {
            "description": "The packing option for the replacement shipment.",
            "enum": [
              "manual",
              "auto"
            ]
          },
          "boxes": {
            "description": "The boxes for the replacement shipment.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentBox"
            }
          },
          "total_weight": {
            "description": "Total shipment weight in kilograms, used for rate calculation by the carrier.",
            "type": "number"
          },
          "expected_delivery_date": {
            "description": "The expected delivery date communicated to the customer.",
            "type": [
              "string",
              "null"
            ],
            "format": "date"
          },
          "tracking_link": {
            "description": "Optional tracking URL shared with the customer.",
            "type": [
              "string",
              "null"
            ]
          },
          "manual_shipping_charges": {
            "description": "Shipping charges incurred for the manual dispatch.",
            "type": [
              "number",
              "null"
            ]
          },
          "reason": {
            "description": "The reason for the replacement shipment.",
            "type": "string"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "CreateShipment": {
        "title": "CreateShipment",
        "description": "Create shipment model",
        "type": "object",
        "required": [
          "order_number",
          "shipments"
        ],
        "properties": {
          "order_number": {
            "type": "string"
          },
          "shipment_number": {
            "description": "Optional. The shipment number based on which the new shipment will be created. If not provided, a new shipment will be created based on unscheduled shipment of the order.",
            "type": [
              "string",
              "null"
            ]
          },
          "shipments": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "warehouse_id",
                "shipment_items",
                "packing_option",
                "shipping_option",
                "shipping_provider_id",
                "total_weight",
                "expected_delivery_date"
              ],
              "properties": {
                "fulfillment_type": {
                  "type": "string",
                  "enum": [
                    "delivery",
                    "collect-in-store"
                  ]
                },
                "warehouse_id": {
                  "type": "string"
                },
                "shipment_items": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ShipmentItem"
                  }
                },
                "packing_option": {
                  "enum": [
                    "auto",
                    "manual"
                  ]
                },
                "shipping_option": {
                  "enum": [
                    "auto",
                    "manual"
                  ]
                },
                "shipping_provider_id": {
                  "type": "string"
                },
                "total_weight": {
                  "type": "number",
                  "default": 0
                },
                "boxes": {
                  "description": "use this field for packing_option = manual",
                  "type": [
                    "array",
                    "null"
                  ],
                  "items": {
                    "$ref": "#/components/schemas/ShipmentBox"
                  }
                },
                "tracking_link": {
                  "description": "use this field for shipping_option = manual",
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "expected_delivery_date": {
                  "description": "Required when `shipping_option` is `manual`.",
                  "type": "string",
                  "format": "date"
                },
                "manual_shipping_charges": {
                  "description": "use this field for shipping_option = manual",
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "courier_company_id": {
                  "description": "Specifies the courier company to be used for shipping when shipping_option is set to auto. If not provided, the system will choose the most suitable courier automatically.",
                  "type": [
                    "string",
                    "null"
                  ]
                }
              }
            }
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "CreateShippingServiceProvider": {
        "title": "CreateShippingServiceProvider",
        "type": "object",
        "required": [
          "api_credentials",
          "warehouse_id",
          "shipping_zone_id"
        ],
        "properties": {
          "api_credentials": {
            "description": "json object in key & value pair. Keys must match with params specified in required_credentials_params object (input_field_name).",
            "type": "object"
          },
          "warehouse_id": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "writeOnly": true
          },
          "shipping_zone_id": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "writeOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CreateShippingZone": {
        "title": "ShippingZone",
        "type": "object",
        "required": [
          "name",
          "countries"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "countries": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "country_alias",
                "all_states"
              ],
              "properties": {
                "country_alias": {
                  "type": "string"
                },
                "all_states": {
                  "type": "boolean",
                  "default": true
                },
                "state_alias": {
                  "description": "required if all_regions=false",
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "active": {
            "type": "boolean",
            "default": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CreateUpdateCategoryAttribute": {
        "title": "CreateUpdateCategoryAttribute",
        "type": "object",
        "properties": {
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AttributeConfig"
            }
          },
          "attributes_set": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "description": "Attribute set id",
                  "type": "string"
                },
                "attributes": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AttributeConfig"
                  }
                }
              },
              "required": [
                "id",
                "attributes"
              ]
            }
          }
        }
      },
      "CreateUpdateMarketplaceAttribute": {
        "title": "CreateUpdateMarketplaceAttribute",
        "type": "object",
        "required": [
          "id",
          "name",
          "key",
          "type",
          "is_required"
        ],
        "properties": {
          "id": {
            "type": [
              "string",
              "null"
            ]
          },
          "name": {
            "type": "string"
          },
          "key": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "is_required": {
            "type": "boolean"
          }
        }
      },
      "CreateUpdateMarketplaceItem": {
        "title": "CreateUpdateMarketplaceItem",
        "type": "object",
        "required": [
          "marketplace_id",
          "product_id",
          "variant_id",
          "marketplace_item_sku",
          "marketplace_category",
          "marketplace_pricing",
          "marketplace_attribute"
        ],
        "properties": {
          "marketplace_id": {
            "type": "string"
          },
          "product_id": {
            "type": "string"
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_item_sku": {
            "description": "SKU Required for physical product.",
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_product_id": {
            "description": "Provide product id if product already available in marketplace.",
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_variant_id": {
            "description": "Provide variant id if variant already available in marketplace.",
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_item_id": {
            "description": "Provide item id if item already available in marketplace.",
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_category": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "marketplace_attribute": {
            "type": "array",
            "items": {
              "properties": {
                "attribute_id": {
                  "type": "string"
                },
                "attribute_value": {
                  "type": "string"
                }
              },
              "required": [
                "attribute_id",
                "attribute_value"
              ]
            }
          },
          "marketplace_pricing": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductPricing"
            }
          },
          "marketplace_promotion": {
            "$ref": "#/components/schemas/ProductPromotion"
          },
          "marketplace_subscription": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductSubscription"
            }
          }
        }
      },
      "CreateVariant": {
        "title": "CreateVariant",
        "allOf": [
          {
            "$ref": "#/components/schemas/VariantCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "name",
              "associated_options"
            ],
            "properties": {
              "name": {
                "type": "string"
              },
              "associated_options": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/AssociatedOption"
                }
              },
              "description": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "images": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "videos": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "seo": {
                "$ref": "#/components/schemas/Seo"
              },
              "shipping": {
                "$ref": "#/components/schemas/ProductShipping"
              },
              "packaging": {
                "$ref": "#/components/schemas/ProductPackaging"
              },
              "related_products": {
                "type": "object",
                "properties": {
                  "cross_sell": {
                    "description": "Array of IDs. The ID value should be the product ID if a non-variant product is selected. For variant products, the ID should be a combination of the product ID and variant ID, separated by a hyphen ('-').",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "upsell": {
                    "description": "Array of IDs. The ID value should be the product ID if a non-variant product is selected. For variant products, the ID should be a combination of the product ID and variant ID, separated by a hyphen ('-').",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              },
              "promotions": {
                "$ref": "#/components/schemas/ProductPromotion"
              },
              "subscriptions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductSubscription"
                }
              }
            }
          }
        ],
        "examples": [],
        "x-tags": [
          "Catalog"
        ]
      },
      "CreateWarehouse": {
        "title": "CreateWarehouse",
        "description": "Validations:\n\n1) Either 'can_receive_stock' or 'accepts_returns' must be set to true.\n2) 'can_receive_stock' cannot be set to false while the warehouse has existing inventory.\n3) 'is_checkout_point' must be true when the warehouse type is 'retail-store'.\n4) If 'can_receive_stock' is false then 'can_ship_parcel' and 'can_collect' fields should be false.",
        "type": "object",
        "required": [
          "name",
          "warehouse_type",
          "city",
          "address_line1",
          "pincode",
          "state",
          "country",
          "contact_phone",
          "contact_email",
          "can_receive_stock",
          "can_ship_parcel",
          "can_collect",
          "accepts_returns",
          "is_checkout_point"
        ],
        "properties": {
          "id": {
            "description": "warehouse ulid",
            "type": "string",
            "readOnly": true
          },
          "name": {
            "description": "legal name",
            "type": "string"
          },
          "warehouse_type": {
            "enum": [
              "retail-store",
              "distribution-center"
            ]
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "gstin": {
            "type": [
              "string",
              "null"
            ]
          },
          "city": {
            "type": "string"
          },
          "address_line1": {
            "type": "string"
          },
          "address_line2": {
            "type": [
              "string",
              "null"
            ]
          },
          "landmark": {
            "type": [
              "string",
              "null"
            ]
          },
          "pincode": {
            "type": "string"
          },
          "state": {
            "type": "string"
          },
          "country": {
            "type": "string"
          },
          "country_code": {
            "type": "string",
            "default": "+91"
          },
          "contact_phone": {
            "description": "10 digit number without country code.",
            "type": "number"
          },
          "contact_email": {
            "type": "string"
          },
          "is_default": {
            "type": "boolean"
          },
          "image_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "seller_warehouse_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "opening_hours": {
            "$ref": "#/components/schemas/OpeningHours"
          },
          "can_receive_stock": {
            "type": "boolean"
          },
          "can_ship_parcel": {
            "type": "boolean"
          },
          "can_collect": {
            "type": "boolean"
          },
          "accepts_returns": {
            "type": "boolean"
          },
          "is_checkout_point": {
            "type": "boolean"
          },
          "shipping_boxes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/StoreShippingBox"
            },
            "readOnly": true
          },
          "service_provider_id": {
            "description": "for courier integration.",
            "type": "array",
            "items": {
              "type": "string"
            },
            "writeOnly": true
          },
          "channel_id": {
            "description": "array of channel ids",
            "type": "array",
            "items": {
              "type": "string"
            },
            "writeOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CreditLineConfig": {
        "title": "CreditLineConfig",
        "type": "object",
        "required": [
          "is_enabled",
          "customer_eligibility",
          "total_credit_limit",
          "payment_method_slugs"
        ],
        "properties": {
          "is_enabled": {
            "description": "Enables the credit line feature for the store. When `false`, customers cannot place orders using their credit line.",
            "type": "boolean",
            "default": false
          },
          "customer_eligibility": {
            "description": "Controls which customers can access the credit line.\n\n- `all` - every customer is eligible.\n- `specific` - only customers who have been individually approved are eligible.",
            "enum": [
              "specific",
              "all"
            ]
          },
          "total_credit_limit": {
            "description": "Default spending limit assigned to a customer when their credit line is approved.",
            "type": "number"
          },
          "mandate_per_order_limit": {
            "description": "(Optional) Default upper cap on the mandate amount issued to a customer. Must be greater than or equal to `total_credit_limit`. If not provided, `total_credit_limit` will be automatically assigned as the mandate per order limit.",
            "type": "number"
          },
          "credit_period": {
            "description": "Credit period in days. If not provided, the credit period will be automatically assigned as 21 days.",
            "type": "number",
            "default": 21
          },
          "payment_method_slugs": {
            "description": "Array of payment method slugs to be used for the credit line.",
            "type": "array",
            "items": {
              "type": "string"
            },
            "writeOnly": true
          },
          "payment_methods": {
            "description": "Payment methods to be used for the credit line.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CreditLinePaymentMethod"
            },
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CreditLinePaymentMethod": {
        "title": "CreditLinePaymentMethod",
        "description": "A payment method linked to the store credit line, as returned inside `StoreConfig.credit_line`. Read-only projection of a manual payment method or a connected payment provider - unlike `ManualPaymentMethod`, this shape carries branding (`type`, `logo_dark`, `logo_light`).",
        "type": "object",
        "required": [
          "name",
          "description"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "type": {
            "description": "`manual` for store-defined payment methods; `auto` for connected payment service providers.",
            "enum": [
              "auto",
              "manual"
            ]
          },
          "used_in_credit_line": {
            "description": "`true` when the option is linked in the store credit-line payment method configuration.",
            "type": "boolean",
            "readOnly": true
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ],
            "readOnly": true
          },
          "logo_dark": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_light": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "Currency": {
        "title": "Currency",
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "code": {
            "type": "string"
          },
          "symbol": {
            "type": "string"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "Customer": {
        "title": "Customer",
        "allOf": [
          {
            "$ref": "#/components/schemas/CustomerInfo"
          },
          {
            "type": "object",
            "properties": {
              "business": {
                "description": "`null` for customers that are not registered as a business.",
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/BusinessInfo"
                  }
                ]
              },
              "segments": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CustomerSegment"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerAddress": {
        "title": "CustomerAddress",
        "type": "object",
        "required": [
          "first_name",
          "phone",
          "email",
          "address_line1",
          "pincode",
          "city",
          "state",
          "country"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "first_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "country_code": {
            "description": "Two-letter code begin with a plus sign prefix that identifies different countries. By default it will be +91 if not provided.\r\n",
            "type": "string"
          },
          "phone": {
            "description": "10 digit phone number without country code.",
            "type": [
              "string",
              "null"
            ]
          },
          "email": {
            "type": [
              "string",
              "null"
            ]
          },
          "address_line1": {
            "type": [
              "string",
              "null"
            ]
          },
          "address_line2": {
            "type": [
              "string",
              "null"
            ]
          },
          "landmark": {
            "type": [
              "string",
              "null"
            ]
          },
          "pincode": {
            "type": [
              "string",
              "null"
            ]
          },
          "city": {
            "type": [
              "string",
              "null"
            ]
          },
          "state": {
            "type": [
              "string",
              "null"
            ]
          },
          "country": {
            "type": "string",
            "enum": [
              "India"
            ]
          },
          "gstin": {
            "description": "Use in shipping details only for third party.",
            "type": [
              "string",
              "null"
            ]
          },
          "business_name": {
            "description": "Use in shipping details only for third party.",
            "type": [
              "string",
              "null"
            ]
          },
          "is_phone_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_email_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_default_shipping": {
            "type": "boolean"
          },
          "is_default_billing": {
            "type": "boolean"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "examples": [],
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerAddressCountry": {
        "title": "CustomerAddressCountry",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "country_code": {
            "type": "string"
          },
          "iso_code": {
            "type": "string"
          },
          "currency_code": {
            "type": "string"
          },
          "currency_symbol": {
            "type": "string"
          },
          "currency_name": {
            "type": "string"
          },
          "flag_icon_url": {
            "type": "string"
          },
          "region": {
            "type": "string"
          },
          "alias": {
            "type": "string"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CustomerAddressState": {
        "title": "CustomerAddressState",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "iso_code": {
            "type": "string"
          },
          "gst_code": {
            "type": "string"
          },
          "alias": {
            "type": "string"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CustomerAttribute": {
        "title": "CustomerAttribute",
        "type": "object",
        "required": [
          "name",
          "attribute_type"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "attribute_type": {
            "$ref": "#/components/schemas/CustomerAttributeType"
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "is_visible": {
            "type": "boolean",
            "default": true
          },
          "is_filterable": {
            "type": "boolean",
            "default": true
          },
          "is_readonly": {
            "type": "boolean",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerAttributeType": {
        "title": "CustomerAttributeType",
        "type": "string",
        "enum": [
          "String",
          "Integer",
          "Number",
          "Boolean",
          "List",
          "Object",
          "DateTime"
        ]
      },
      "CustomerBankAccount": {
        "title": "CustomerBankAccount",
        "type": "object",
        "required": [
          "account_type",
          "account_name",
          "account_number",
          "ifsc_code",
          "bank_name"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "account_type": {
            "enum": [
              "inbound",
              "outbound"
            ]
          },
          "account_name": {
            "type": "string"
          },
          "account_number": {
            "type": "string"
          },
          "ifsc_code": {
            "type": "string"
          },
          "bank_name": {
            "type": "string"
          },
          "is_default": {
            "description": "default bank account for the customer.",
            "type": "boolean"
          },
          "is_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerCreditBalance": {
        "title": "CustomerCreditBalance",
        "type": "object",
        "required": [
          "received_amount",
          "settled_amount",
          "balance_amount"
        ],
        "properties": {
          "received_amount": {
            "description": "Total bank-transfer payments received from the customer.",
            "type": "number"
          },
          "settled_amount": {
            "description": "Portion of received bank-transfer payments already applied to orders.",
            "type": "number"
          },
          "balance_amount": {
            "description": "Remaining spendable bank-transfer credit available to the customer.",
            "type": "number"
          }
        }
      },
      "CustomerCreditLineBalance": {
        "title": "CustomerCreditLineBalance",
        "type": "object",
        "required": [
          "mandate_per_order_limit",
          "total_credit_limit",
          "utilized_amount",
          "balance_amount",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "mandate_per_order_limit": {
            "description": "Upper cap on the mandate amount. Sourced into `CustomerMandate.mandate_per_order_limit` when the mandate is created.",
            "type": "number"
          },
          "total_credit_limit": {
            "description": "Total spending limit approved for the customer. Cannot exceed `mandate_per_order_limit`.",
            "type": "number"
          },
          "utilized_amount": {
            "description": "Approved limit currently committed to in-flight or completed orders.",
            "type": "number"
          },
          "balance_amount": {
            "description": "Remaining spendable balance (`total_credit_limit` minus `utilized_amount`).",
            "type": "number"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "CustomerDetail": {
        "title": "CustomerDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/Customer"
          },
          {
            "type": "object",
            "properties": {
              "addresses": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CustomerAddress"
                }
              },
              "banking": {
                "description": "Bank accounts saved against the customer, used for refunds and payouts.",
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/CustomerBankAccount"
                }
              },
              "loyalty": {
                "description": "`null` when the customer is not enrolled in a loyalty program.",
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/LoyaltyMember"
                  }
                ]
              },
              "notification_preferences": {
                "$ref": "#/components/schemas/NotificationPreferences"
              }
            }
          }
        ],
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerGroup": {
        "title": "CustomerGroup",
        "type": "object",
        "required": [
          "name"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_default": {
            "description": "first record will be treated as default if not changed.",
            "type": "boolean"
          },
          "active": {
            "type": "boolean",
            "default": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "CustomerInfo": {
        "title": "CustomerInfo",
        "type": "object",
        "properties": {
          "id": {
            "description": "user id",
            "type": "string",
            "readOnly": true
          },
          "first_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "full_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "profile_image_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "country_code": {
            "type": "string"
          },
          "phone": {
            "type": [
              "string",
              "null"
            ]
          },
          "email": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_phone_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_email_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_whatsapp_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "status": {
            "description": "`null` for customers with no status recorded.",
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/CustomerStatus"
              }
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "last_seen": {
            "description": "Empty string when the customer has no recorded activity yet.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "kyc_status": {
            "$ref": "#/components/schemas/KycStatus"
          },
          "is_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "customer_group_id": {
            "description": "The Customer Group the customer belongs to. Drives group-specific pricing and promotions.",
            "type": [
              "string",
              "null"
            ]
          },
          "tags": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerListItem": {
        "title": "CustomerListItem",
        "allOf": [
          {
            "$ref": "#/components/schemas/Customer"
          },
          {
            "type": "object",
            "properties": {
              "user_id": {
                "type": "string",
                "readOnly": true
              },
              "metadata": {
                "description": "Arbitrary key-value data stored against the customer.",
                "type": [
                  "object",
                  "null"
                ],
                "additionalProperties": true
              },
              "address": {
                "description": "A single address for the customer, `null` when none is saved.",
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/CustomerAddress"
                  }
                ]
              }
            }
          }
        ],
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerLoyalty": {
        "title": "CustomerLoyalty",
        "type": "object",
        "properties": {
          "membership_number": {
            "type": "string"
          },
          "points_earned": {
            "description": "total points earned within the current loyalty program.",
            "type": "integer"
          },
          "points_redeemed": {
            "description": "total points redeemed within the current loyalty program.",
            "type": "integer"
          },
          "points_balance": {
            "description": "total points available.",
            "type": "integer"
          },
          "total_spent": {
            "description": "The total amount a customer has spent within the current loyalty program, excluding taxes, promotional discounts, and redeemed loyalty points. This value is used to determine tier eligibility and earning points calculation.",
            "type": "integer"
          },
          "total_orders": {
            "description": "The total number of completed orders counted in the current loyalty program.",
            "type": "integer"
          },
          "lifetime_spent": {
            "description": " The total amount a customer has spent across all time, regardless of loyalty program participation. This includes all completed orders and excludes taxes, promotional discounts, and redeemed points.",
            "type": "integer"
          },
          "lifetime_orders": {
            "description": "The total number of completed orders across all time, regardless of loyalty program.",
            "type": "integer"
          },
          "date_of_join": {
            "description": " The date and time when the customer first enrolled in the loyalty program.",
            "type": "string",
            "format": "date-time"
          },
          "date_of_assign": {
            "description": "The date and time when the customer's current loyalty tier or program instance was assigned. This may change when tiers are upgraded, downgraded, or reassigned.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "date_of_reset": {
            "description": " The date and time when the customer’s current loyalty program cycle will reset, at which points earned, points redeemed, balance points, total spent, total orders will be cleared.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "current_tier": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            }
          },
          "next_tier": {
            "description": "null when the member is already on the highest tier",
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "name": {
                    "type": "string"
                  },
                  "total_spent_threshold": {
                    "type": [
                      "integer",
                      "null"
                    ],
                    "minimum": 0
                  },
                  "total_orders_threshold": {
                    "type": [
                      "integer",
                      "null"
                    ],
                    "minimum": 0
                  }
                }
              },
              {
                "type": "null"
              }
            ]
          },
          "name": {
            "type": "string"
          },
          "renewal_type": {
            "type": "string",
            "enum": [
              "yearly",
              "never",
              "custom"
            ]
          },
          "tier_upgrade_criteria": {
            "type": "string",
            "enum": [
              "total-spent",
              "total-orders",
              "custom"
            ]
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerMandate": {
        "title": "CustomerMandate",
        "type": "object",
        "required": [
          "id",
          "status"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "mandate_type": {
            "type": "string"
          },
          "status": {
            "$ref": "#/components/schemas/MandateStatus"
          },
          "max_amount": {
            "type": "integer"
          },
          "frequency": {
            "type": "string"
          },
          "external_reference_id": {
            "description": "The external reference id of the mandate. This is the id of the mandate in the external system.",
            "type": [
              "string",
              "null"
            ]
          },
          "start_date": {
            "type": "string",
            "format": "date-time"
          },
          "end_date": {
            "type": "string",
            "format": "date-time"
          },
          "gateway": {
            "type": "string"
          },
          "gateway_reference_id": {
            "type": "string"
          },
          "block_fund": {
            "type": "boolean"
          },
          "revokable_by_customer": {
            "type": "boolean"
          },
          "currency": {
            "type": "string"
          },
          "payment_info": {
            "type": "object",
            "properties": {
              "payment_method_type": {
                "type": "string"
              },
              "payment_method": {
                "type": "string"
              },
              "bank_details": {
                "type": "object",
                "properties": {
                  "account_number": {
                    "type": "string"
                  },
                  "ifsc": {
                    "type": "string"
                  },
                  "bank_account_type": {
                    "type": "string"
                  },
                  "beneficiary_name": {
                    "type": "string"
                  },
                  "bank_name": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "activated_at": {
            "type": "string",
            "format": "date-time"
          },
          "last_activated_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "CustomerSegment": {
        "title": "CustomerSegment",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CustomerStats": {
        "title": "CustomerStats",
        "type": "object",
        "properties": {
          "total_customer": {
            "type": "integer"
          },
          "new_customer": {
            "type": "integer"
          },
          "total_customers": {
            "type": "integer"
          },
          "new_customers": {
            "type": "integer"
          },
          "customer_lifetime_value": {
            "type": "number"
          },
          "total_session": {
            "type": "integer"
          },
          "total_session_duration": {
            "description": "in minutes",
            "type": "integer"
          },
          "avg_session_duration": {
            "description": "in minutes\n",
            "type": "number"
          },
          "total_spending": {
            "type": "number"
          },
          "total_paid": {
            "type": "number"
          },
          "settled_amount": {
            "type": "number"
          },
          "refunded_amount": {
            "type": "number"
          },
          "account_balance": {
            "type": "number"
          }
        }
      },
      "CustomerStatus": {
        "enum": [
          "active",
          "inactive"
        ]
      },
      "CustomerUser": {
        "title": "CustomerUser",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "first_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "email": {
            "type": [
              "string",
              "null"
            ],
            "format": "email"
          },
          "phone": {
            "type": "string"
          },
          "country_code": {
            "type": "string"
          },
          "status": {
            "description": "Activation status used by customer user access controls.",
            "type": "string"
          },
          "is_primary": {
            "description": "Whether this is the customer's primary user.",
            "type": "boolean"
          },
          "is_phone_verified": {
            "type": "boolean"
          },
          "is_email_verified": {
            "type": "boolean"
          },
          "profile_image_url": {
            "type": [
              "string",
              "null"
            ],
            "format": "uri"
          },
          "login_methods": {
            "description": "Authentication methods enabled for the user.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "CustomSlabsBasedOnAmount": {
        "title": "CustomSlabsBasedOnAmount",
        "type": "object",
        "required": [
          "spending_criteria_type",
          "products"
        ],
        "properties": {
          "spending_criteria_type": {
            "type": "string",
            "const": "minimum-purchase-amount"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "product_id",
                "variant_id",
                "slabs"
              ],
              "properties": {
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_name": {
                  "type": "string",
                  "readOnly": true
                },
                "status": {
                  "type": "string",
                  "readOnly": true
                },
                "stock_available": {
                  "type": "string",
                  "readOnly": true
                },
                "images": {
                  "type": "string",
                  "readOnly": true
                },
                "product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "slabs": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "required": [
                      "minimum_purchase_amount",
                      "get_quantity",
                      "condition"
                    ],
                    "properties": {
                      "minimum_purchase_amount": {
                        "type": "number"
                      },
                      "get_quantity": {
                        "type": "integer"
                      },
                      "condition": {
                        "enum": [
                          "greater-or-equal"
                        ]
                      }
                    }
                  }
                },
                "auto_scale": {
                  "type": "boolean",
                  "readOnly": true
                }
              }
            }
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "CustomSlabsBasedOnQuantity": {
        "title": "CustomSlabsBasedOnQuantity",
        "type": "object",
        "required": [
          "spending_criteria_type",
          "products"
        ],
        "properties": {
          "spending_criteria_type": {
            "type": "string",
            "const": "minimum-quantity"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "product_id",
                "variant_id",
                "slabs"
              ],
              "properties": {
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_name": {
                  "type": "string",
                  "readOnly": true
                },
                "status": {
                  "type": "string",
                  "readOnly": true
                },
                "stock_available": {
                  "type": "string",
                  "readOnly": true
                },
                "images": {
                  "type": "string",
                  "readOnly": true
                },
                "product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "slabs": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "required": [
                      "buy_quantity",
                      "get_quantity",
                      "condition"
                    ],
                    "properties": {
                      "buy_quantity": {
                        "type": "integer"
                      },
                      "get_quantity": {
                        "type": "integer"
                      },
                      "condition": {
                        "enum": [
                          "greater-or-equal"
                        ]
                      }
                    }
                  }
                },
                "auto_scale": {
                  "type": "boolean",
                  "readOnly": true
                }
              }
            }
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "DataDownload": {
        "title": "DataDownload",
        "type": "object",
        "required": [
          "job_id",
          "status",
          "name",
          "job_type",
          "data_source",
          "data_filters",
          "download",
          "error_message",
          "created_at",
          "processed_at"
        ],
        "properties": {
          "job_id": {
            "type": "string"
          },
          "status": {
            "enum": [
              "pending",
              "ready",
              "failed"
            ]
          },
          "name": {
            "type": "string"
          },
          "job_type": {
            "description": "Derived from `data_source` as `download_<data_source>`.",
            "enum": [
              "download_orders",
              "download_customers",
              "download_shipments",
              "download_payments",
              "download_invoices",
              "download_payout_batches",
              "download_products",
              "download_media",
              "download_loyalty_members",
              "download_loyalty-members"
            ]
          },
          "data_source": {
            "description": "Records exported by the job. `invoices` exports payout-eligible `SellerPayoutInvoice` records; `payout_batches` exports seller settlement `SellerPayoutBatch` records.",
            "enum": [
              "orders",
              "customers",
              "shipments",
              "payments",
              "invoices",
              "payout_batches",
              "products",
              "media",
              "loyalty_members",
              "loyalty-members"
            ]
          },
          "data_filters": {
            "$ref": "#/components/schemas/DataFilterObject"
          },
          "download": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "url": {
                "type": "string"
              },
              "file_name": {
                "type": "string"
              },
              "file_type": {
                "type": "string"
              }
            },
            "required": [
              "url",
              "file_name",
              "file_type"
            ]
          },
          "error_message": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "processed_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          }
        }
      },
      "DataFilterNestedObject": {
        "title": "DataFilterNestedObject",
        "type": "object",
        "properties": {
          "condition": {
            "enum": [
              "AND",
              "OR"
            ]
          },
          "filters": {
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/ColumnBasedFilterRule"
                },
                {
                  "$ref": "#/components/schemas/DataFilterObject"
                }
              ]
            }
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "DataFilterObject": {
        "title": "DataFilterObject",
        "type": "object",
        "properties": {
          "condition": {
            "enum": [
              "AND",
              "OR"
            ]
          },
          "filters": {
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/ColumnBasedFilterRule"
                },
                {
                  "$ref": "#/components/schemas/DataFilterNestedObject"
                }
              ]
            }
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "DateTimeAttribute": {
        "title": "DateTimeAttribute",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "is_linked": {
            "type": "boolean",
            "readOnly": true
          },
          "value": {
            "description": "`null` when no value is set for this customer.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "attribute_type": {
            "enum": [
              "DateTime"
            ]
          },
          "is_readonly": {
            "type": "boolean",
            "readOnly": true
          },
          "is_pinned": {
            "description": "Whether the attribute is pinned to the top of the customer profile.",
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "last_updated_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "DeliveryFulfillment": {
        "title": "DeliveryFulfillment",
        "type": "object",
        "required": [
          "fulfillment_type",
          "shipping_provider_id"
        ],
        "properties": {
          "fulfillment_type": {
            "type": "string",
            "const": "delivery"
          },
          "preference_type": {
            "type": "string",
            "enum": [
              "user",
              "auto"
            ],
            "readOnly": true
          },
          "shipping_provider_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_provider_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "courier_company_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "courier_company_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          }
        }
      },
      "DiscountAction": {
        "title": "DiscountAction",
        "type": "object",
        "required": [
          "type",
          "mode",
          "value"
        ],
        "properties": {
          "type": {
            "type": "string",
            "const": "discount"
          },
          "mode": {
            "type": "string",
            "enum": [
              "percent",
              "absolute"
            ]
          },
          "value": {
            "description": "Percentage (0–100) or absolute amount off",
            "type": "number",
            "minimum": 0
          }
        },
        "additionalProperties": false
      },
      "DiscountBasedPromotion": {
        "title": "DiscountBasedPromotion",
        "description": "promotion_type = discount",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "promotion_type",
          "starts_at",
          "details"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "promotion_type": {
            "enum": [
              "discount"
            ]
          },
          "starts_at": {
            "type": "string"
          },
          "expires_at": {
            "description": "null means never expires.",
            "type": [
              "string",
              "null"
            ]
          },
          "details": {
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/PercentageBasedDiscount"
                },
                {
                  "$ref": "#/components/schemas/FixedAmountBasedDiscount"
                }
              ]
            }
          }
        }
      },
      "DiscountCouponPromotion": {
        "title": "DiscountCouponPromotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "details",
              "applies_to_product"
            ],
            "properties": {
              "details": {
                "$ref": "#/components/schemas/DiscountRule"
              },
              "applies_to_product": {
                "enum": [
                  "all",
                  "product",
                  "category"
                ]
              }
            }
          }
        ]
      },
      "DiscountRule": {
        "title": "DiscountRule",
        "type": "object",
        "required": [
          "discount_type",
          "products",
          "category_id"
        ],
        "properties": {
          "discount_type": {
            "type": "string",
            "enum": [
              "percentage",
              "fixed-amount"
            ]
          },
          "discount_percent": {
            "type": [
              "number",
              "null"
            ]
          },
          "fixed_discount_amount": {
            "type": [
              "number",
              "null"
            ]
          },
          "maximum_discount_amount": {
            "type": [
              "number",
              "null"
            ]
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_name": {
                  "type": "string",
                  "readOnly": true
                },
                "status": {
                  "type": "string",
                  "readOnly": true
                },
                "stock_available": {
                  "type": "string",
                  "readOnly": true
                },
                "images": {
                  "type": "string",
                  "readOnly": true
                },
                "product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "minimum_quantity": {
                  "type": [
                    "integer",
                    "null"
                  ]
                },
                "maximum_quantity": {
                  "type": [
                    "integer",
                    "null"
                  ]
                },
                "minimum_value": {
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "maximum_value": {
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "minimum_purchase_amount": {
                  "type": [
                    "number",
                    "null"
                  ],
                  "readOnly": true
                },
                "auto_scale": {
                  "type": "boolean",
                  "readOnly": true
                }
              }
            }
          },
          "category_id": {
            "description": "Array of category ids",
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "DynamicAction": {
        "title": "DynamicAction",
        "type": "object",
        "required": [
          "type",
          "rounding"
        ],
        "properties": {
          "type": {
            "type": "string",
            "const": "dynamic"
          },
          "rounding": {
            "$ref": "#/components/schemas/Rounding"
          }
        },
        "additionalProperties": false
      },
      "DynamicQueryFilter": {
        "title": "DynamicQueryFilter",
        "type": "object",
        "properties": {
          "field_name": {
            "type": "string"
          },
          "operator": {
            "enum": [
              "equal",
              "not-equal",
              "exact",
              "contains",
              "does-not-contain",
              "is-empty",
              "is-not-empty",
              "starts-with",
              "ends-with",
              "less",
              "less-or-equal",
              "greater",
              "greater-or-equal",
              "between"
            ]
          },
          "value": {
            "oneOf": [
              {
                "type": [
                  "string",
                  "null"
                ]
              },
              {
                "type": "integer"
              },
              {
                "type": "number"
              },
              {
                "type": "boolean"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            ]
          }
        },
        "x-tags": [
          "Analytics"
        ]
      },
      "DynamicQueryMetricsData": {
        "title": "DynamicQueryMetricsData",
        "type": "object",
        "properties": {
          "data": {
            "description": "array of object. similar structure of metrics api, but actual keys will be decided by request payload.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AnalyticsQueryRow"
            }
          },
          "pagination": {
            "$ref": "#/components/schemas/Pagination"
          }
        },
        "nullable": true,
        "x-tags": [
          "Analytics"
        ]
      },
      "DynamicQueryRecords": {
        "title": "DynamicQueryRecords",
        "type": "object",
        "properties": {
          "data": {
            "description": "array of object containing key-value data as per fields passed in query payload.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AnalyticsQueryRow"
            }
          },
          "pagination": {
            "$ref": "#/components/schemas/Pagination"
          }
        },
        "nullable": true,
        "x-tags": [
          "Analytics"
        ]
      },
      "DynamicQueryStatsData": {
        "title": "DynamicQueryStatsData",
        "type": "object",
        "properties": {
          "data": {
            "description": "array of object containing key-value data as per fields, aggregate fields or group by fields passed in query payload.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AnalyticsQueryRow"
            }
          },
          "pagination": {
            "$ref": "#/components/schemas/Pagination"
          }
        },
        "nullable": true,
        "x-tags": [
          "Analytics"
        ]
      },
      "DynamicSegment": {
        "title": "DynamicSegment",
        "allOf": [
          {
            "$ref": "#/components/schemas/SegmentInfo"
          },
          {
            "type": "object",
            "required": [
              "dynamic_conditions"
            ],
            "properties": {
              "dynamic_conditions": {
                "type": "object",
                "properties": {
                  "condition": {
                    "enum": [
                      "and",
                      "or"
                    ]
                  },
                  "filters": {
                    "type": "array",
                    "items": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/ColumnBasedFilterRule"
                        },
                        {
                          "$ref": "#/components/schemas/EventBasedFilterRule"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          {
            "type": "object",
            "properties": {
              "ad_audiences": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SegmentAdAudience"
                },
                "readOnly": true
              }
            }
          },
          {
            "type": "object",
            "properties": {
              "usage": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SegmentUsage"
                },
                "readOnly": true
              }
            }
          }
        ],
        "x-tags": [
          "Segments"
        ]
      },
      "EventAttributeBasedFilterRule": {
        "title": "EventAttributeBasedFilterRule",
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string"
          },
          "value": {
            "type": "string"
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "EventBasedFilterRule": {
        "title": "EventBasedFilterRule",
        "type": "object",
        "properties": {
          "type": {
            "enum": [
              "event"
            ]
          },
          "event": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "properties": {
                "type": "object",
                "properties": {
                  "condition": {
                    "enum": [
                      "and",
                      "or"
                    ]
                  },
                  "filters": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/EventAttributeBasedFilterRule"
                    }
                  }
                }
              }
            }
          },
          "inverse": {
            "type": "boolean"
          },
          "times": {
            "type": "integer"
          },
          "within": {
            "type": "integer"
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "FilterOptionListingType": {
        "title": "FilterOptionListingType",
        "type": "string",
        "enum": [
          "attributes-set",
          "categories",
          "coupons",
          "customer-attributes",
          "customers",
          "inventories",
          "inventory-activities",
          "loyalty-activities",
          "loyalty-members",
          "marketplace-inventory-activities",
          "marketplace-listing",
          "marketplace-products",
          "marketplace-products-channels",
          "media-files",
          "media-folders",
          "orders",
          "payments",
          "pos-devices",
          "product-attributes",
          "products",
          "promotions",
          "shipments",
          "visitors",
          "webhook-deliveries",
          "webhook-events",
          "seller-payout-config",
          "seller-payout-batches",
          "analytics-sessions",
          "invoice",
          "payout-invoice"
        ]
      },
      "FilterOptions": {
        "title": "FilterOptions",
        "type": "object",
        "required": [
          "fields"
        ],
        "properties": {
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FilterOptionsField"
            }
          },
          "events": {
            "description": "optional. by default empty array will be returned if events are not required in filters. ",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FilterOptionsEvent"
            }
          },
          "attributes": {
            "description": "optional. by default empty array will be returned if attributes are not required in filters. ",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FilterOptionsAttribute"
            }
          },
          "segments": {
            "description": "optional. by default empty array will be returned if segments are not required in filters. ",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FilterOptionsSegment"
            }
          }
        },
        "x-tags": [
          "Filter Options"
        ]
      },
      "FilterOptionsAttribute": {
        "title": "FilterOptionsAttribute",
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "data_type": {
            "description": "Attribute type, using the same vocabulary as `CustomerAttributeType`.",
            "enum": [
              "String",
              "Integer",
              "Number",
              "Boolean",
              "List",
              "Object",
              "DateTime"
            ]
          },
          "label": {
            "type": "string"
          },
          "filterable": {
            "type": "boolean"
          },
          "sortable": {
            "type": "boolean"
          },
          "value": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          }
        },
        "x-tags": [
          "Filter Options"
        ]
      },
      "FilterOptionsEvent": {
        "title": "FilterOptionsEvent",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "event_name": {
            "type": "string"
          }
        },
        "x-tags": [
          "Filter Options"
        ]
      },
      "FilterOptionsField": {
        "title": "FilterOptionsField",
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "data_type": {
            "enum": [
              "string",
              "number",
              "datetime",
              "date",
              "boolean",
              "list",
              "json"
            ]
          },
          "label": {
            "type": "string"
          },
          "filterable": {
            "type": "boolean"
          },
          "sortable": {
            "type": "boolean"
          },
          "value": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "number"
                },
                {
                  "type": "object",
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  }
                }
              ]
            }
          }
        },
        "x-tags": [
          "Filter Options"
        ]
      },
      "FilterOptionsSegment": {
        "title": "FilterOptionsEvent",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        },
        "x-tags": [
          "Filter Options"
        ]
      },
      "FixedAmountBasedDiscount": {
        "title": "FixedAmountBasedDiscount",
        "description": "promotion_type = discount",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "discount_type",
          "discount_fixed_amount",
          "customer_group_id",
          "minimum_quantity",
          "maximum_quantity"
        ],
        "properties": {
          "discount_type": {
            "type": "string",
            "const": "fixed-amount"
          },
          "discount_fixed_amount": {
            "type": "integer"
          },
          "customer_group_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "minimum_quantity": {
            "description": "It refers to the minimum quantity of a specific item a customer must purchase to qualify for the promotion.",
            "type": "integer",
            "default": 1
          },
          "maximum_quantity": {
            "description": "It refers to the maximum quantity of a specific item a customer can purchase in order to qualify for the promotion. If this field is set to null, it indicates that there is no limit.",
            "type": [
              "integer",
              "null"
            ]
          }
        }
      },
      "FixedAmountTieredDiscountSlab": {
        "title": "FixedAmountTieredDiscountSlab",
        "type": "object",
        "required": [
          "order_value",
          "condition",
          "discount_type",
          "fixed_discount_amount"
        ],
        "properties": {
          "order_value": {
            "description": "The order total the cart is evaluated against for this slab.",
            "type": "number"
          },
          "condition": {
            "description": "This key defines how the system will evaluate the order total to determine if the discount should be applied, based on the specified slab. The last slab must use `greater` so the highest tier stays open-ended.",
            "enum": [
              "less-or-equal",
              "greater"
            ]
          },
          "discount_type": {
            "type": "string",
            "const": "fixed-amount"
          },
          "fixed_discount_amount": {
            "type": "number"
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "FixedChargeAction": {
        "title": "FixedChargeAction",
        "type": "object",
        "required": [
          "type",
          "value"
        ],
        "properties": {
          "type": {
            "type": "string",
            "const": "fixed-charge"
          },
          "value": {
            "description": "Flat charge amount",
            "type": "number",
            "minimum": 0
          }
        },
        "additionalProperties": false
      },
      "FixedPriceCouponPromotion": {
        "title": "FixedPriceCouponPromotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "details",
              "applies_to_product"
            ],
            "properties": {
              "details": {
                "$ref": "#/components/schemas/FixedPriceRule"
              },
              "applies_to_product": {
                "type": "string",
                "const": "product"
              }
            }
          }
        ]
      },
      "FixedPricePromotion": {
        "title": "FixedPricePromotion",
        "description": "promotion_type = fixed-price",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "promotion_type",
          "starts_at",
          "details"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "promotion_type": {
            "enum": [
              "fixed-price"
            ]
          },
          "starts_at": {
            "type": "string"
          },
          "expires_at": {
            "description": "null means never expires.",
            "type": [
              "string",
              "null"
            ]
          },
          "details": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "offer_price",
                "customer_group_id",
                "minimum_quantity",
                "maximum_quantity"
              ],
              "properties": {
                "offer_price": {
                  "type": "number"
                },
                "customer_group_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "minimum_quantity": {
                  "description": "It refers to the minimum quantity of a specific item a customer must purchase to qualify for the promotion.",
                  "type": "integer",
                  "default": 1
                },
                "maximum_quantity": {
                  "description": "It refers to the maximum quantity of a specific item a customer can purchase in order to qualify for the promotion. If this field is set to null, it indicates that there is no limit.",
                  "type": [
                    "integer",
                    "null"
                  ]
                }
              }
            }
          }
        }
      },
      "FixedPriceRule": {
        "title": "FixedPriceRule",
        "oneOf": [
          {
            "$ref": "#/components/schemas/FixedPriceRuleBasedQuantity"
          },
          {
            "$ref": "#/components/schemas/FixedPriceRuleBasedAmount"
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "FixedPriceRuleBasedAmount": {
        "title": "FixedPriceRuleBasedAmount",
        "type": "object",
        "required": [
          "spending_criteria_type",
          "products"
        ],
        "properties": {
          "spending_criteria_type": {
            "type": "string",
            "const": "minimum-purchase-amount"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "product_id",
                "variant_id",
                "minimum_purchase_amount",
                "maximum_purchase_amount",
                "offer_price"
              ],
              "properties": {
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_name": {
                  "type": "string",
                  "readOnly": true
                },
                "status": {
                  "type": "string",
                  "readOnly": true
                },
                "stock_available": {
                  "type": "string",
                  "readOnly": true
                },
                "images": {
                  "type": "string",
                  "readOnly": true
                },
                "product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "minimum_purchase_amount": {
                  "type": "number"
                },
                "maximum_purchase_amount": {
                  "description": "null means there is no limit.",
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "offer_price": {
                  "type": "number"
                }
              }
            }
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "FixedPriceRuleBasedQuantity": {
        "title": "FixedPriceRuleBasedQuantity",
        "type": "object",
        "required": [
          "spending_criteria_type",
          "products"
        ],
        "properties": {
          "spending_criteria_type": {
            "type": "string",
            "const": "minimum-quantity"
          },
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "product_id",
                "variant_id",
                "minimum_quantity",
                "maximum_quantity",
                "offer_price"
              ],
              "properties": {
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_name": {
                  "type": "string",
                  "readOnly": true
                },
                "status": {
                  "type": "string",
                  "readOnly": true
                },
                "stock_available": {
                  "type": "string",
                  "readOnly": true
                },
                "images": {
                  "type": "string",
                  "readOnly": true
                },
                "product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "minimum_quantity": {
                  "type": "integer",
                  "minimum": 1
                },
                "maximum_quantity": {
                  "description": "null means there is no limit.",
                  "type": [
                    "integer",
                    "null"
                  ]
                },
                "offer_price": {
                  "type": "number"
                }
              }
            }
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "FreeAction": {
        "title": "FreeAction",
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "const": "free"
          }
        },
        "additionalProperties": false
      },
      "FreeGoodCouponPromotion": {
        "title": "FreeGoodCouponPromotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "details",
              "applies_to_product"
            ],
            "properties": {
              "details": {
                "$ref": "#/components/schemas/FreeGoodsRule"
              },
              "applies_to_product": {
                "type": "string",
                "const": "product"
              }
            }
          }
        ]
      },
      "FreeGoodsPromotion": {
        "title": "FreeGoodsPromotion",
        "description": "promotion_type = free-goods",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "promotion_type",
          "starts_at",
          "details"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "promotion_type": {
            "enum": [
              "free-goods"
            ]
          },
          "starts_at": {
            "type": "string",
            "format": "date-time"
          },
          "expires_at": {
            "description": "null means never expires.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "details": {
            "type": "array",
            "items": {
              "allOf": [
                {
                  "required": [
                    "customer_group_id"
                  ],
                  "properties": {
                    "customer_group_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  }
                },
                {
                  "oneOf": [
                    {
                      "title": "ScaleAutomatically",
                      "required": [
                        "auto_scale",
                        "slab"
                      ],
                      "properties": {
                        "auto_scale": {
                          "description": "The **auto_scale** key determines whether the promotion should be automatically adjusted based on the ratio between the quantities bought and the quantities received.\\n\\nIf **true**: The promotion will be applied dynamically according to the ratio of the buy quantity to the get quantity. For example, if the promotion is \\\"Buy 2, Get 1\\\" and the customer buys 4 items, they would receive 2 free items (scaling based on the original ratio).\\n\\nIf **false**: The promotion will be applied strictly according to the predefined conditions. For example, even if the customer buys more items, they will receive the fixed free quantity as defined in the original promotion (e.g., buying 4 would still only get them 1 free item).",
                          "type": "boolean"
                        },
                        "slab": {
                          "type": "object",
                          "properties": {
                            "buy_quantity": {
                              "type": "integer"
                            },
                            "get_quantity": {
                              "type": "integer"
                            },
                            "quantity_condition": {
                              "description": "Defines how the system will evaluate the buy_quantity to determine if the promotion should be applied.",
                              "enum": [
                                "less",
                                "less-or-equal",
                                "greater",
                                "greater-or-equal"
                              ]
                            }
                          },
                          "required": [
                            "buy_quantity",
                            "get_quantity",
                            "quantity_condition"
                          ]
                        }
                      }
                    },
                    {
                      "title": "CustomSlabs",
                      "required": [
                        "slabs"
                      ],
                      "properties": {
                        "slabs": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "required": [
                              "buy_quantity",
                              "get_quantity",
                              "quantity_condition"
                            ],
                            "properties": {
                              "buy_quantity": {
                                "type": "integer"
                              },
                              "get_quantity": {
                                "type": "integer"
                              },
                              "quantity_condition": {
                                "description": "Defines how the system will evaluate the buy_quantity to determine if the promotion should be applied.",
                                "enum": [
                                  "less",
                                  "less-or-equal",
                                  "greater",
                                  "greater-or-equal"
                                ]
                              }
                            }
                          }
                        }
                      }
                    }
                  ]
                }
              ],
              "type": "object"
            }
          }
        }
      },
      "FreeGoodsRule": {
        "title": "FreeGoodsRule",
        "oneOf": [
          {
            "$ref": "#/components/schemas/AutoScaleBasedOnQuantity"
          },
          {
            "$ref": "#/components/schemas/AutoScaleBasedOnAmount"
          },
          {
            "$ref": "#/components/schemas/CustomSlabsBasedOnQuantity"
          },
          {
            "$ref": "#/components/schemas/CustomSlabsBasedOnAmount"
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "FreeShippingCouponPromotion": {
        "title": "FreeShippingCouponPromotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "details",
              "applies_to_product"
            ],
            "properties": {
              "details": {
                "$ref": "#/components/schemas/FreeShippingDetails"
              },
              "applies_to_product": {
                "type": "string",
                "const": "all"
              }
            }
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "FreeShippingDetails": {
        "title": "FreeShippingDetails",
        "description": "Free shipping has no rule. Returns `null` on read; send an empty array on write.",
        "type": [
          "array",
          "null"
        ],
        "default": [],
        "maxItems": 0,
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "FulfillmentItem": {
        "title": "FulfillmentItem",
        "type": "object",
        "required": [
          "product_id",
          "product_name",
          "variant_id",
          "variant_name",
          "quantity"
        ],
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string",
            "readOnly": true
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "quantity": {
            "type": "integer"
          }
        }
      },
      "FulfillmentPreference": {
        "title": "FulfillmentPreference",
        "discriminator": {
          "propertyName": "fulfillment_type",
          "mapping": {
            "collect-in-store": "#/components/schemas/CollectInStoreFulfillment",
            "delivery": "#/components/schemas/DeliveryFulfillment",
            "partial-collect-and-delivery": "#/components/schemas/PartialCollectAndDelivery"
          }
        },
        "oneOf": [
          {
            "$ref": "#/components/schemas/CollectInStoreFulfillment"
          },
          {
            "$ref": "#/components/schemas/DeliveryFulfillment"
          },
          {
            "$ref": "#/components/schemas/PartialCollectAndDelivery"
          }
        ],
        "x-tags": [
          "Orders"
        ]
      },
      "GlobalSearchCustomerHit": {
        "title": "GlobalSearchCustomerHit",
        "description": "Customer document from the Meilisearch Customers index.",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "first_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "full_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "profile_image_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "country_code": {
            "type": "string"
          },
          "phone": {
            "type": [
              "string",
              "null"
            ]
          },
          "email": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_phone_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_email_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_whatsapp_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "status": {
            "description": "Customer status as indexed. Often `active` or `inactive`; the index may contain other values.",
            "type": [
              "string",
              "null"
            ]
          },
          "kyc_status": {
            "$ref": "#/components/schemas/KycStatus"
          },
          "customer_group_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "tags": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "last_seen": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "business": {
            "description": "`null` when the customer is not registered as a business.",
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/BusinessInfo"
              }
            ]
          },
          "address": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/CustomerAddress"
              }
            ]
          },
          "segments": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CustomerSegment"
            }
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "GlobalSearchOrder": {
        "title": "GlobalSearchOrder",
        "type": "object",
        "properties": {
          "billing_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "cart_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "credit_balance_used": {
            "type": "number",
            "format": "double"
          },
          "currency": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "code": {
                "type": "string"
              },
              "symbol": {
                "type": "string"
              }
            }
          },
          "customer_id": {
            "type": "string"
          },
          "customer_note": {
            "type": [
              "string",
              "null"
            ]
          },
          "fulfillment_type": {
            "enum": [
              "collect-in-store",
              "delivery"
            ]
          },
          "grand_total": {
            "type": "number",
            "format": "double"
          },
          "id": {
            "type": "string"
          },
          "loyalty_point_earned": {
            "type": "number",
            "format": "double"
          },
          "loyalty_point_redeemed": {
            "type": "number",
            "format": "double"
          },
          "metadata": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "on_subscription": {
            "type": "boolean"
          },
          "order_date": {
            "type": "string",
            "format": "date-time"
          },
          "order_items_count": {
            "type": "integer"
          },
          "order_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderItem"
            }
          },
          "order_number": {
            "type": "string"
          },
          "payment_status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "payment_success_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "sales_channel": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name",
              "type"
            ]
          },
          "shipping_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "status": {
            "$ref": "#/components/schemas/OrderStatus"
          },
          "to_be_paid": {
            "type": "number",
            "format": "double"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "GlobalSearchProduct": {
        "title": "GlobalSearchProduct",
        "type": "object",
        "properties": {
          "active": {
            "type": "boolean"
          },
          "associated_options": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AssociatedOption"
            }
          },
          "attribute": {
            "type": [
              "object",
              "null"
            ]
          },
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductAttribute"
            }
          },
          "categories": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string",
                  "readOnly": true
                },
                "description": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "slug": {
                  "type": "string",
                  "readOnly": true
                },
                "parent_category_id": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_count": {
                  "type": "integer",
                  "readOnly": true
                },
                "active": {
                  "type": "boolean",
                  "readOnly": true
                }
              }
            }
          },
          "category_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "customer_group_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "has_variant": {
            "type": "boolean"
          },
          "hsn_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "id": {
            "description": "product id",
            "type": "string",
            "readOnly": true
          },
          "images": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductImage"
            }
          },
          "is_featured": {
            "type": "boolean"
          },
          "name": {
            "type": "string",
            "maxLength": 128
          },
          "on_offer": {
            "type": "boolean"
          },
          "on_promotion": {
            "type": "boolean"
          },
          "on_subscription": {
            "type": "boolean"
          },
          "packing": {
            "$ref": "#/components/schemas/ProductPackaging"
          },
          "price": {
            "type": [
              "number",
              "null"
            ],
            "format": "double"
          },
          "pricing": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductPricing"
            }
          },
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "product_slug": {
            "type": "string",
            "maxLength": 128
          },
          "variant_slug": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          },
          "_rankingScore": {
            "description": "Meilisearch relevance score for the hit.",
            "type": "number",
            "format": "double"
          },
          "product_type": {
            "enum": [
              "physical",
              "digital",
              "bundle"
            ]
          },
          "promotion": {
            "$ref": "#/components/schemas/ProductPromotion"
          },
          "rating": {
            "type": [
              "number",
              "null"
            ],
            "format": "float"
          },
          "raw_attributes": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "reviews_count": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "reviews_rating_sum": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "sales_channels": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SalesChannel"
            }
          },
          "seo": {
            "$ref": "#/components/schemas/Seo"
          },
          "shipping": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/ProductShipping"
              },
              {
                "type": "null"
              }
            ]
          },
          "short_description": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 256
          },
          "sku": {
            "type": "string",
            "maxLength": 64
          },
          "slug": {
            "type": "string",
            "maxLength": 128
          },
          "status": {
            "$ref": "#/components/schemas/ProductStatus"
          },
          "stock_available": {
            "type": "boolean"
          },
          "subscription": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductSubscription"
            }
          },
          "tags": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "GlobalSearchResult": {
        "title": "GlobalSearchResult",
        "description": "One Meilisearch index result. `hits` entries match `GlobalSearchProduct` when `indexUid` is the products index, `GlobalSearchOrder` for orders, and `GlobalSearchCustomerHit` for customers.",
        "type": "object",
        "properties": {
          "indexUid": {
            "type": "string"
          },
          "hits": {
            "description": "Index documents. Shape depends on `indexUid`: `GlobalSearchCustomerHit`, `GlobalSearchOrder`, or `GlobalSearchProduct`.",
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/GlobalSearchCustomerHit"
                },
                {
                  "$ref": "#/components/schemas/GlobalSearchOrder"
                },
                {
                  "$ref": "#/components/schemas/GlobalSearchProduct"
                }
              ]
            }
          },
          "facetDistribution": {
            "description": "Meilisearch facet counts keyed by attribute, then facet value.",
            "type": "object",
            "additionalProperties": {
              "type": "object",
              "additionalProperties": {
                "type": "integer"
              }
            }
          },
          "facetStats": {
            "description": "Meilisearch numeric facet min/max per attribute.",
            "type": "object",
            "additionalProperties": {
              "type": "object",
              "properties": {
                "min": {
                  "type": "number"
                },
                "max": {
                  "type": "number"
                }
              }
            }
          },
          "query": {
            "type": "string"
          },
          "processingTimeMs": {
            "type": "integer",
            "format": "int32"
          },
          "limit": {
            "type": "integer",
            "format": "int32"
          },
          "offset": {
            "type": "integer",
            "format": "int32"
          },
          "estimatedTotalHits": {
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "ImportBulkProducts": {
        "title": "ImportBulkProducts",
        "description": "Schema for bulk importing products.",
        "type": "object",
        "required": [
          "kind",
          "input_data"
        ],
        "properties": {
          "kind": {
            "description": "Type of bulk operation",
            "type": "string",
            "enum": [
              "create-products"
            ]
          },
          "input_data": {
            "description": "Array of products to import",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ImportProduct"
            }
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ImportNonVariantProduct": {
        "title": "ImportNonVariantProduct",
        "description": "Schema for importing a non-variant product.",
        "type": "object",
        "required": [
          "name",
          "product_type",
          "hsn_code",
          "categories",
          "short_description",
          "pricing"
        ],
        "properties": {
          "name": {
            "description": "Product name",
            "type": "string"
          },
          "slug": {
            "description": "URL-friendly product identifier",
            "type": "string"
          },
          "sku": {
            "description": "Stock Keeping Unit",
            "type": "string"
          },
          "product_type": {
            "$ref": "#/components/schemas/ProductType"
          },
          "hsn_code": {
            "description": "Harmonized System Nomenclature code for tax classification",
            "type": [
              "string",
              "null"
            ]
          },
          "short_description": {
            "description": "Brief description of the product",
            "type": [
              "string",
              "null"
            ]
          },
          "tags": {
            "description": "Product tags for categorization and search",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "seo": {
            "$ref": "#/components/schemas/Seo"
          },
          "attributes": {
            "description": "Product attributes",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductAttribute"
            }
          },
          "categories": {
            "description": "List of category IDs the product belongs to",
            "type": "array",
            "items": {
              "type": "string",
              "description": "Category ID"
            }
          },
          "images": {
            "description": "Array of image file ids.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "videos": {
            "description": "Array of video file ids.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "pricing": {
            "description": "Product pricing information",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductPricing"
            }
          },
          "subscriptions": {
            "description": "Subscription plans for the product",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductSubscription"
            }
          },
          "packaging": {
            "$ref": "#/components/schemas/ProductPackaging"
          },
          "shipping": {
            "$ref": "#/components/schemas/ProductShipping"
          },
          "promotions": {
            "description": "Product promotions",
            "oneOf": [
              {
                "$ref": "#/components/schemas/ProductPromotion"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ImportProduct": {
        "title": "ImportProduct",
        "description": "Schema for importing a product. Can be either a non-variant product or a variant-based product.",
        "oneOf": [
          {
            "$ref": "#/components/schemas/ImportNonVariantProduct"
          },
          {
            "$ref": "#/components/schemas/ImportVariantBasedProduct"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "ImportVariantBasedProduct": {
        "title": "ImportVariantBasedProduct",
        "description": "Schema for importing a variant-based product.",
        "type": "object",
        "required": [
          "name",
          "slug",
          "product_type",
          "hsn_code",
          "short_description",
          "categories",
          "variants"
        ],
        "properties": {
          "name": {
            "description": "Product name",
            "type": "string"
          },
          "slug": {
            "description": "URL-friendly product identifier",
            "type": "string"
          },
          "product_type": {
            "$ref": "#/components/schemas/ProductType"
          },
          "hsn_code": {
            "description": "Harmonized System Nomenclature code for tax classification",
            "type": [
              "string",
              "null"
            ]
          },
          "short_description": {
            "description": "Brief description of the product",
            "type": [
              "string",
              "null"
            ]
          },
          "description": {
            "description": "Full description of the product",
            "type": [
              "string",
              "null"
            ]
          },
          "tags": {
            "description": "Product tags for categorization and search",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "metadata": {
            "description": "Additional metadata for the product",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "seo": {
            "$ref": "#/components/schemas/Seo"
          },
          "attributes": {
            "description": "Product attributes",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductAttribute"
            }
          },
          "categories": {
            "description": "List of category IDs the product belongs to",
            "type": "array",
            "items": {
              "type": "string",
              "description": "Category ID"
            }
          },
          "variants": {
            "description": "Product variants",
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "description": "Variant name",
                  "type": "string"
                },
                "short_description": {
                  "description": "Brief description of the variant",
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "sku": {
                  "description": "Stock Keeping Unit",
                  "type": "string"
                },
                "slug": {
                  "description": "URL-friendly variant identifier",
                  "type": "string"
                },
                "metadata": {
                  "description": "Additional metadata for the variant",
                  "type": [
                    "object",
                    "null"
                  ],
                  "additionalProperties": {
                    "type": "string"
                  }
                },
                "associated_options": {
                  "description": "Options that define this variant",
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AssociatedOption"
                  }
                },
                "is_default": {
                  "description": "Whether this is the default variant",
                  "type": "boolean"
                },
                "images": {
                  "description": "Array of image file ids.",
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "videos": {
                  "description": "Array of video file ids.",
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "pricing": {
                  "description": "Variant pricing information",
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ProductPricing"
                  }
                },
                "variant_attributes": {
                  "description": "Attributes specific to this variant",
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ProductAttribute"
                  }
                },
                "packaging": {
                  "$ref": "#/components/schemas/ProductPackaging"
                },
                "shipping": {
                  "$ref": "#/components/schemas/ProductShipping"
                }
              },
              "required": [
                "name",
                "sku",
                "slug",
                "associated_options",
                "is_default",
                "pricing"
              ]
            }
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "IntegerAttribute": {
        "title": "IntegerAttribute",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "is_linked": {
            "type": "boolean",
            "readOnly": true
          },
          "value": {
            "description": "`null` when no value is set for this customer.",
            "type": [
              "integer",
              "null"
            ]
          },
          "attribute_type": {
            "enum": [
              "Integer"
            ]
          },
          "is_readonly": {
            "type": "boolean",
            "readOnly": true
          },
          "is_pinned": {
            "description": "Whether the attribute is pinned to the top of the customer profile.",
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "last_updated_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "IntegrationSyncInfo": {
        "title": "IntegrationSyncInfo",
        "type": "object",
        "properties": {
          "sync_summary": {
            "$ref": "#/components/schemas/CatalogDataSyncSummary"
          },
          "sync_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CatalogDataSyncItem",
              "type": "object"
            }
          },
          "pagination": {
            "$ref": "#/components/schemas/Pagination"
          }
        }
      },
      "IntegrationSyncRequest": {
        "title": "IntegrationSyncRequest",
        "type": "object",
        "required": [
          "destination"
        ],
        "properties": {
          "destination": {
            "type": "string",
            "enum": [
              "datocms"
            ]
          },
          "model": {
            "type": "string",
            "enum": [
              "product",
              "category",
              "bundle"
            ]
          }
        }
      },
      "IntegrationSyncResult": {
        "title": "IntegrationSyncResult",
        "type": "object",
        "properties": {
          "request_id": {
            "type": "string"
          }
        }
      },
      "InventoryAction": {
        "title": "InventoryAction",
        "enum": [
          "create-shipment",
          "refund-shortfall",
          "wait-for-inventory",
          "cancel-shipment",
          "cancel-and-refund-shipment",
          "reject-order"
        ]
      },
      "InventoryActivity": {
        "title": "InventoryActivity",
        "type": "object",
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "variant_id": {
            "type": "string"
          },
          "variant_name": {
            "type": "string"
          },
          "sku": {
            "type": "string"
          },
          "warehouse_id": {
            "type": "string"
          },
          "warehouse": {
            "$ref": "#/components/schemas/WarehouseBasicDetail"
          },
          "activity_type": {
            "enum": [
              "add",
              "reserve",
              "reduce",
              "adjust",
              "update"
            ]
          },
          "quantity": {
            "type": "integer"
          },
          "reason": {
            "type": "string",
            "maxLength": 512
          },
          "lot_batch": {
            "type": "string"
          },
          "mfg_date": {
            "type": "string",
            "format": "date"
          },
          "exp_date": {
            "type": "string",
            "format": "date"
          },
          "manufacturer": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "InventoryActivityWarehouse": {
        "title": "InventoryActivityWarehouse",
        "allOf": [
          {
            "$ref": "#/components/schemas/WarehouseBasicDetail"
          },
          {
            "type": "object",
            "properties": {
              "gstin": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "address_line2": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "landmark": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "contact_phone": {
                "type": "string"
              },
              "contact_email": {
                "type": "string"
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "InventoryCheckResponse": {
        "title": "InventoryCheckResponse",
        "type": "object",
        "properties": {
          "inventory_status": {
            "enum": [
              "fulfilled",
              "partially-fulfilled",
              "not-fulfilled"
            ]
          },
          "total_fulfilled_products": {
            "type": "integer"
          },
          "total_fulfilled_warehouses": {
            "type": "integer"
          },
          "inventory": {
            "type": "object",
            "properties": {
              "products": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": "string"
                    },
                    "allow_backorder": {
                      "type": "boolean"
                    },
                    "track_inventory": {
                      "type": "boolean"
                    },
                    "requested_quantity": {
                      "type": "integer"
                    },
                    "stock_quantity": {
                      "type": "integer"
                    },
                    "allowed_quantity": {
                      "type": "integer"
                    },
                    "inventory_status": {
                      "enum": [
                        "fulfilled",
                        "partially-fulfilled",
                        "not-fulfilled"
                      ]
                    },
                    "warehouses": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "warehouse_id": {
                            "type": "string"
                          },
                          "warehouse_name": {
                            "type": "string"
                          },
                          "stock_quantity": {
                            "type": "integer"
                          },
                          "inventory_status": {
                            "enum": [
                              "fulfilled",
                              "partially-fulfilled",
                              "not-fulfilled"
                            ]
                          }
                        }
                      }
                    }
                  }
                }
              },
              "warehouses": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "warehouse_id": {
                      "type": "string"
                    },
                    "warehouse_name": {
                      "type": "string"
                    },
                    "inventory_status": {
                      "enum": [
                        "fulfilled",
                        "partially-fulfilled",
                        "not-fulfilled"
                      ]
                    },
                    "products": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "product_id": {
                            "type": "string"
                          },
                          "variant_id": {
                            "type": "string"
                          },
                          "stock_quantity": {
                            "type": "integer"
                          },
                          "allowed_quantity": {
                            "type": "integer"
                          },
                          "inventory_status": {
                            "enum": [
                              "fulfilled",
                              "partially-fulfilled",
                              "not-fulfilled"
                            ]
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "InventoryDetail": {
        "title": "InventoryDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/ItemWiseInventory"
          },
          {
            "type": "object",
            "properties": {
              "details": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/WarehouseWiseInventory"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "InventoryStatus": {
        "enum": [
          "fulfilled",
          "partially-fulfilled",
          "not-fulfilled"
        ]
      },
      "Invoice": {
        "title": "Invoice",
        "description": "Invoice model",
        "type": "object",
        "properties": {
          "invoice_number": {
            "type": "string"
          },
          "status": {
            "description": "Current state of the invoice, e.g. `\"printed\"`.",
            "type": "string"
          },
          "invoice_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date"
          },
          "irn_number": {
            "description": "Invoice Reference Number",
            "type": [
              "string",
              "null"
            ]
          },
          "ack_number": {
            "description": "Acknowledgement Number",
            "type": [
              "string",
              "null"
            ]
          },
          "ack_date": {
            "description": "Acknowledgement Date",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "signed_qr_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "gatepass_barcode": {
            "type": [
              "string",
              "null"
            ]
          },
          "seller_details": {
            "description": "Party the invoice is raised by: the seller record for marketplace seller invoices, the warehouse for single-seller stores, or `null`.",
            "anyOf": [
              {
                "$ref": "#/components/schemas/SellerInfo"
              },
              {
                "$ref": "#/components/schemas/Warehouse"
              },
              {
                "type": "null"
              }
            ]
          },
          "billing_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "shipping_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "subtotal": {
            "type": "number"
          },
          "sub_total": {
            "type": "number"
          },
          "sub_total_including_tax": {
            "type": "number"
          },
          "shipping_amount": {
            "type": "number"
          },
          "shipping_amount_including_tax": {
            "type": "number"
          },
          "coupon_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_discount_percent": {
            "type": [
              "number",
              "null"
            ]
          },
          "coupon_discount_amount": {
            "type": [
              "number",
              "null"
            ]
          },
          "promotion_discount_amount": {
            "type": "number"
          },
          "loyalty_point_redeemed": {
            "type": "number"
          },
          "total_tax": {
            "type": "number"
          },
          "grand_total": {
            "type": "number"
          },
          "tax_summary": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "tax_rate": {
                  "type": "number"
                },
                "taxable_value": {
                  "type": "number"
                },
                "igst": {
                  "type": "number"
                },
                "cgst": {
                  "type": "number"
                },
                "sgst": {
                  "type": "number"
                }
              }
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "InvoiceDetail": {
        "title": "InvoiceDetail",
        "description": "InvoiceDetail model",
        "allOf": [
          {
            "$ref": "#/components/schemas/Invoice"
          },
          {
            "type": "object",
            "properties": {
              "items": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/InvoiceItem"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Shipping"
        ]
      },
      "InvoiceItem": {
        "title": "InvoiceItem",
        "description": "InvoiceItem model",
        "type": "object",
        "properties": {
          "sku": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "product_image_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "listing_price": {
            "type": "number"
          },
          "selling_price": {
            "type": "number"
          },
          "qty": {
            "description": "Quantity invoiced. Sent as a numeric string, not a number.",
            "type": "string"
          },
          "free_qty": {
            "description": "Quantity supplied free of charge. Sent as a numeric string, not a number.",
            "type": "string"
          },
          "tax_type": {
            "type": "string"
          },
          "tax_rate": {
            "type": "number"
          },
          "hsncode": {
            "type": "string"
          },
          "batch_no": {
            "type": [
              "string",
              "null"
            ]
          },
          "expiry": {
            "type": [
              "string",
              "null"
            ]
          },
          "amount": {
            "type": "number"
          },
          "coupon_discount_amount": {
            "type": "number"
          },
          "promotion_discount_amount": {
            "type": "number"
          },
          "selling_price_excluding_tax": {
            "type": "number"
          },
          "item_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "order_item_id": {
            "type": "string"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "InvoiceList": {
        "title": "InvoiceList",
        "description": "A single invoice row in the invoice listing. Each invoice is raised against one shipment of an order, so an order with multiple shipments produces multiple invoices.",
        "type": "object",
        "required": [
          "invoice_number",
          "invoice_date",
          "invoice_source",
          "order_number",
          "shipment_id",
          "customer_id",
          "customer_name",
          "items_count",
          "subtotal",
          "subtotal_including_tax",
          "shipping_amount_excluding_tax",
          "shipping_amount_including_tax",
          "shipping_tax_rate",
          "shipping_tax_amount",
          "total_tax",
          "invoice_amount_excluding_tax",
          "invoice_amount_including_tax",
          "tax_summary",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "invoice_number": {
            "description": "Seller-scoped invoice number printed on the tax invoice.",
            "type": "string"
          },
          "invoice_date": {
            "description": "Date of supply printed on the invoice. May differ from `created_at`, which records when the invoice was generated.",
            "type": "string",
            "format": "date"
          },
          "invoice_source": {
            "description": "Party that raised the invoice. `default` for invoices raised by the store itself; `seller` for invoices raised by a marketplace seller.",
            "type": "string",
            "enum": [
              "default",
              "seller"
            ]
          },
          "order_number": {
            "type": "string"
          },
          "shipment_id": {
            "description": "Identifier of the shipment this invoice was raised for.",
            "type": "string"
          },
          "seller_id": {
            "description": "Seller who raised the invoice. `null` when `invoice_source` is `default`.",
            "type": [
              "string",
              "null"
            ]
          },
          "seller_details": {
            "description": "Registered details of the seller identified by `seller_id`. `null` when `invoice_source` is `default`.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/SellerInfo"
              },
              {
                "type": "null"
              }
            ]
          },
          "customer_id": {
            "type": "string"
          },
          "customer_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "items_count": {
            "description": "Number of line items on the invoice.",
            "type": "integer"
          },
          "irn_number": {
            "description": "Invoice Reference Number returned by the GST e-invoicing portal. `null` if the invoice has not been registered.",
            "type": [
              "string",
              "null"
            ]
          },
          "ack_number": {
            "description": "Acknowledgement number issued by the GST e-invoicing portal. `null` until the invoice is registered.",
            "type": [
              "string",
              "null"
            ]
          },
          "ack_date": {
            "description": "When the GST e-invoicing portal acknowledged the invoice. `null` until the invoice is registered.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "gatepass_barcode": {
            "description": "Barcode scanned at warehouse dispatch. `null` if no gatepass was issued.",
            "type": [
              "string",
              "null"
            ]
          },
          "subtotal": {
            "description": "Line-item total before tax and shipping.",
            "type": "number",
            "format": "double"
          },
          "subtotal_including_tax": {
            "description": "Line-item total including tax, before shipping.",
            "type": "number",
            "format": "double"
          },
          "shipping_amount_excluding_tax": {
            "description": "Shipping charged on this invoice, before tax.",
            "type": "number",
            "format": "double"
          },
          "shipping_amount_including_tax": {
            "description": "Shipping charged on this invoice, including tax.",
            "type": "number",
            "format": "double"
          },
          "shipping_tax_rate": {
            "description": "GST rate applied to shipping, as a percentage.",
            "type": "number",
            "format": "double"
          },
          "shipping_tax_amount": {
            "description": "Tax levied on the shipping amount.",
            "type": "number",
            "format": "double"
          },
          "coupon_code": {
            "description": "Coupon applied to the invoiced items. `null` if none was applied.",
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_discount_amount": {
            "description": "Discount attributed to `coupon_code` on this invoice.",
            "type": "number",
            "format": "double"
          },
          "total_tax": {
            "description": "Total tax on the invoice, across items and shipping.",
            "type": "number",
            "format": "double"
          },
          "invoice_amount_excluding_tax": {
            "description": "Invoice total before tax, after discounts and shipping.",
            "type": "number",
            "format": "double"
          },
          "invoice_amount_including_tax": {
            "description": "Amount payable on the invoice. This is the figure printed as the invoice total.",
            "type": "number",
            "format": "double"
          },
          "tax_summary": {
            "description": "GST breakdown grouped by tax rate. Intra-state supplies populate `cgst` and `sgst`; inter-state supplies populate `igst`.",
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "tax_rate",
                "taxable_value",
                "igst",
                "cgst",
                "sgst"
              ],
              "properties": {
                "tax_rate": {
                  "description": "GST rate for this group, as a percentage.",
                  "type": "number",
                  "format": "double"
                },
                "taxable_value": {
                  "description": "Value taxed at `tax_rate`.",
                  "type": "number",
                  "format": "double"
                },
                "igst": {
                  "description": "Integrated GST on `taxable_value`.",
                  "type": "number",
                  "format": "double"
                },
                "cgst": {
                  "description": "Central GST on `taxable_value`.",
                  "type": "number",
                  "format": "double"
                },
                "sgst": {
                  "description": "State GST on `taxable_value`.",
                  "type": "number",
                  "format": "double"
                }
              }
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "ItemWiseInventory": {
        "title": "ItemWiseInventory",
        "type": "object",
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "sku": {
            "type": [
              "string",
              "null"
            ]
          },
          "track_quantity": {
            "type": "boolean"
          },
          "allow_backorder": {
            "type": "boolean"
          },
          "track_lot_batch": {
            "type": "boolean"
          },
          "low_stock_threshold": {
            "type": "number",
            "format": "decimal"
          },
          "received_quantity": {
            "type": "number",
            "format": "decimal"
          },
          "reserved_quantity": {
            "type": "number",
            "format": "decimal"
          },
          "sold_quantity": {
            "type": "number",
            "format": "decimal"
          },
          "adjusted_quantity": {
            "type": "number",
            "format": "decimal"
          },
          "stock_quantity": {
            "type": "number",
            "format": "decimal"
          },
          "stock_available": {
            "description": "Whether sellable stock is available after reservations and backorder rules.",
            "type": "boolean",
            "readOnly": true
          },
          "images": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductImage"
            }
          }
        }
      },
      "KycDocument": {
        "title": "KycDocument",
        "type": "object",
        "required": [
          "document_number",
          "document_type_id"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "document_number": {
            "type": "string"
          },
          "note": {
            "type": [
              "string",
              "null"
            ]
          },
          "file": {
            "description": "file attachment will be required or optional as per store setting.",
            "type": "string",
            "format": "binary",
            "writeOnly": true
          },
          "document_type_id": {
            "type": "string"
          },
          "document_type_slug": {
            "description": "Document type slug from store KYC configuration. Populated for marketplace stores; `null` or omitted otherwise.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "status": {
            "enum": [
              "submitted",
              "approved",
              "rejected"
            ],
            "readOnly": true
          },
          "title": {
            "type": "string",
            "readOnly": true
          },
          "file_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "verification_type": {
            "enum": [
              "auto",
              "manual"
            ],
            "readOnly": true
          },
          "is_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "verified_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "readOnly": true
          },
          "created_by": {
            "description": "Actor that created the record. Typical values are `customer`, `admin`, or `import`; an empty string means unset on older records.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "created_by_user_id": {
            "type": "string",
            "readOnly": true
          },
          "created_at": {
            "description": "`YYYY-MM-DD HH:MM:SS` (UTC), not RFC 3339.",
            "type": "string",
            "readOnly": true
          },
          "modified_by": {
            "description": "Actor that last modified the record. Typical values are `customer`, `admin`, or `import`; an empty string means unset on older records.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "modified_by_user_id": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "modified_at": {
            "description": "`YYYY-MM-DD HH:MM:SS` (UTC), not RFC 3339.",
            "type": "string",
            "readOnly": true
          },
          "modified_reason": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          }
        },
        "additionalProperties": true,
        "x-tags": [
          "Customers"
        ]
      },
      "KycDocumentConfig": {
        "title": "KycDocumentConfig",
        "type": "object",
        "required": [
          "document_type",
          "title",
          "is_mandatory",
          "is_attachment_required",
          "verification_type"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "document_type": {
            "description": "Kind of KYC document the store collects. Known values are `gst`, `pan`, `drug_license` and `other`; the set is store-configurable and not exhaustive.",
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "is_mandatory": {
            "type": "boolean"
          },
          "is_attachment_required": {
            "type": "boolean"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "verification_type": {
            "enum": [
              "auto",
              "manual"
            ]
          },
          "is_value_unique": {
            "description": "When `true`, the document number must be unique across customers in the store.",
            "type": "boolean",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "KycStatus": {
        "description": "KYC progress for a customer. `document_pending` means required documents have not been uploaded; `submitted` and `submitted_for_approval` mean they are awaiting review.",
        "enum": [
          "pending",
          "document_pending",
          "submitted",
          "submitted_for_approval",
          "approved",
          "rejected"
        ]
      },
      "ListAttribute": {
        "title": "ListAttribute",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "is_linked": {
            "type": "boolean",
            "readOnly": true
          },
          "value": {
            "description": "`null` when no value is set for this customer.",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "attribute_type": {
            "enum": [
              "List"
            ]
          },
          "is_readonly": {
            "type": "boolean",
            "readOnly": true
          },
          "is_pinned": {
            "description": "Whether the attribute is pinned to the top of the customer profile.",
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "last_updated_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "LotBatchWiseInventory": {
        "title": "LotBatchWiseInventory",
        "allOf": [
          {
            "$ref": "#/components/schemas/ItemWiseInventory"
          },
          {
            "type": "object",
            "properties": {
              "lot_batch": {
                "type": "string"
              },
              "mfg_date": {
                "type": "string",
                "format": "date"
              },
              "exp_date": {
                "type": "string",
                "format": "date"
              },
              "manufacturer": {
                "type": "string"
              }
            }
          }
        ]
      },
      "LoyaltyMember": {
        "title": "LoyaltyMember",
        "allOf": [
          {
            "type": "object",
            "properties": {
              "customer_id": {
                "type": "string"
              },
              "customer_name": {
                "type": "string"
              }
            }
          },
          {
            "$ref": "#/components/schemas/CustomerLoyalty"
          }
        ],
        "x-tags": [
          "Customers"
        ]
      },
      "LoyaltyPointActivity": {
        "title": "LoyaltyPointActivity",
        "type": "object",
        "required": [
          "activity",
          "action",
          "title",
          "loyalty_points"
        ],
        "properties": {
          "activity": {
            "enum": [
              "order",
              "credit-note",
              "tier-upgrade",
              "tier-downgrade",
              "no-purchase-activity",
              "points-carryforward",
              "signup",
              "bonus",
              "other"
            ]
          },
          "action": {
            "enum": [
              "add",
              "remove"
            ]
          },
          "title": {
            "type": "string"
          },
          "loyalty_points": {
            "type": "integer"
          },
          "reference_number": {
            "type": "string"
          },
          "internal_note": {
            "type": [
              "string",
              "null"
            ]
          },
          "remarks": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "LoyaltyPointPayment": {
        "title": "LoyaltyPointPayment",
        "description": "Loyalty point redemption.",
        "allOf": [
          {
            "$ref": "#/components/schemas/OrderPaymentInfo"
          }
        ],
        "x-tags": [
          "Orders"
        ]
      },
      "LoyaltyProgram": {
        "title": "LoyaltyProgram",
        "type": "object",
        "required": [
          "name",
          "renewal_type",
          "starts_at",
          "date_of_reset",
          "tier_upgrade_criteria",
          "points_earning_type",
          "point_value",
          "redemption_expiry_type",
          "redemption_inactivity_days",
          "tiers"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "description": "name of loyalty program",
            "type": "string"
          },
          "seller_id": {
            "description": "Restricts the program to these sellers. Use `null` or omit to apply it across all sellers.",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "customer_group_id": {
            "description": "Restricts the program to these customer groups. Use `null` or omit to apply it to all customers.",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "renewal_type": {
            "description": "frequency at which loyalty program will be renewed.",
            "enum": [
              "yearly",
              "never",
              "custom"
            ]
          },
          "starts_at": {
            "description": "If renewal_type is \"custom\", a corresponding valid date must be specified; for other types, the value should be null.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "date_of_reset": {
            "description": "If renewal_type is \"custom\", a corresponding valid date must be specified; for other types, the value should be null.",
            "type": [
              "string",
              "null"
            ],
            "format": "date"
          },
          "tier_upgrade_criteria": {
            "description": "to decide tier upgradation based on no of orders or total purchase value",
            "enum": [
              "total-spent",
              "total-orders",
              "custom"
            ]
          },
          "points_earning_type": {
            "description": "Defines how points are earned. \"dynamic\" means points are calculated based on a rate (points_earning_rate), \"fixed\" means a fixed number of points are given.",
            "enum": [
              "dynamic",
              "fixed"
            ]
          },
          "point_value": {
            "description": "The monetary value of one loyalty point.",
            "type": "number",
            "default": 1
          },
          "redemption_expiry_type": {
            "description": "Defines when loyalty points are expired. \"never\" means the points never expire, \"inactivity\" means the points expire after a certain number of days of inactivity, \"reset_date\" means the points expire when the loyalty program is reset.",
            "enum": [
              "never",
              "inactivity",
              "reset_date"
            ]
          },
          "redemption_inactivity_days": {
            "description": "The number of days after the last order was placed, after which the points expire if redemption_expiry_type is \"inactivity\". required if redemption_expiry_type is \"inactivity\", otherwise should be null.",
            "type": [
              "integer",
              "null"
            ]
          },
          "status": {
            "$ref": "#/components/schemas/LoyaltyProgramStatus",
            "readOnly": true
          },
          "pause_starts_at": {
            "description": "If status is \"paused\", the date and time from which the loyalty program will be paused. If not specified, the loyalty program will be paused immediately.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "pause_ends_at": {
            "description": "If status is \"paused\", the date and time until which the loyalty program will be paused. If not specified, the loyalty program will remain paused until it is resumed.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "tiers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LoyaltyTier"
            }
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "LoyaltyProgramStatus": {
        "title": "LoyaltyProgramStatus",
        "description": "The operational status of the loyalty program.",
        "type": "string",
        "enum": [
          "draft",
          "scheduled",
          "active",
          "inactive",
          "paused",
          "expired"
        ]
      },
      "LoyaltyTier": {
        "title": "LoyaltyTier",
        "type": "object",
        "required": [
          "name",
          "total_spent_threshold",
          "total_orders_threshold",
          "points_earning_rate",
          "fixed_points",
          "point_value",
          "earn_points_with_promotion",
          "redeem_points_with_promotion"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "description": "name of loyalty tier",
            "type": "string"
          },
          "total_spent_threshold": {
            "description": "It should be null if tier upgrade criteria is total orders only.",
            "type": [
              "integer",
              "null"
            ],
            "minimum": 0
          },
          "total_orders_threshold": {
            "description": "It should be null if tier upgrade criteria is total spent only.",
            "type": [
              "integer",
              "null"
            ],
            "minimum": 0
          },
          "points_earning_rate": {
            "description": "The rate at which points are earned. For point earning type = dynamic",
            "type": [
              "number",
              "null"
            ]
          },
          "fixed_points": {
            "description": "Fixed loyalty points for all orders. For point earning type = fixed",
            "type": [
              "integer",
              "null"
            ]
          },
          "is_initial": {
            "description": "only one tier will have value as True",
            "type": "boolean",
            "readOnly": true
          },
          "next_tier_id": {
            "description": "id of next loyalty tier",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "LoyaltyTierActivity": {
        "title": "LoyaltyTierActivity",
        "type": "object",
        "properties": {
          "activity": {
            "enum": [
              "tier-upgrade",
              "tier-downgrade",
              "other"
            ]
          },
          "tier_id": {
            "type": "string"
          },
          "tier_name": {
            "type": "string"
          },
          "total_spent": {
            "type": "integer"
          },
          "total_orders": {
            "type": "integer"
          },
          "remarks": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "ManageShippingOption": {
        "title": "ManageShippingOption",
        "oneOf": [
          {
            "$ref": "#/components/schemas/ShippingZoneBasedShippingOption"
          },
          {
            "$ref": "#/components/schemas/WarehouseBasedShippingOption"
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "MandateActivity": {
        "title": "MandateActivity",
        "type": "object",
        "required": [
          "status",
          "comment",
          "activity_type",
          "details",
          "user_type",
          "user_name",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "status": {
            "type": "string",
            "enum": [
              "success",
              "failed"
            ]
          },
          "comment": {
            "type": "string"
          },
          "activity_type": {
            "type": [
              "string"
            ]
          },
          "details": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "user_type": {
            "enum": [
              "customer",
              "admin",
              "system"
            ]
          },
          "user_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "MandateDebitSchedule": {
        "title": "MandateDebitSchedule",
        "type": "object",
        "required": [
          "id",
          "mandate_id",
          "order_id",
          "amount",
          "status",
          "scheduled_at",
          "retry_attempt",
          "max_retries",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "mandate_id": {
            "description": "ID of the parent `CustomerMandate`.",
            "type": "string"
          },
          "customer_id": {
            "description": "Internal numeric customer ID, not the customer ULID.",
            "type": "integer"
          },
          "order_id": {
            "description": "ID of the order that triggered this debit.",
            "type": "string"
          },
          "order_number": {
            "description": "Order number of the order that triggered this debit.",
            "type": [
              "string",
              "null"
            ]
          },
          "amount": {
            "description": "Amount to be debited from the customer for this scheduled execution.",
            "type": "number"
          },
          "status": {
            "type": "string",
            "enum": [
              "scheduled",
              "debit-requested",
              "debit-success",
              "debit-failed",
              "cancelled",
              "awaiting-retry"
            ]
          },
          "scheduled_at": {
            "description": "Time at which the debit is queued to be executed against the mandate provider.",
            "type": "string",
            "format": "date-time"
          },
          "picked_at": {
            "description": "Time at which the worker picked the schedule for execution.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "executed_at": {
            "description": "Time at which the debit was executed against the mandate provider.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "external_reference_id": {
            "description": "Mandate provider reference returned for this debit.",
            "type": [
              "string",
              "null"
            ]
          },
          "gateway_order_id": {
            "description": "Order ID submitted to the mandate provider for this debit.",
            "type": [
              "string",
              "null"
            ]
          },
          "retry_attempt": {
            "type": "integer"
          },
          "max_retries": {
            "type": "integer"
          },
          "next_retry_at": {
            "description": "Time at which the next retry will be attempted.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "MandateLog": {
        "title": "MandateLog",
        "type": "object",
        "required": [
          "mandate_id",
          "status",
          "timestamp",
          "retry_attempt",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "id": {
            "type": "integer"
          },
          "mandate_id": {
            "description": "ID of the parent `CustomerMandate`.",
            "type": "string"
          },
          "debit_schedule_id": {
            "description": "ID of the related `MandateDebitSchedule`. `null` for logs not tied to a specific debit attempt.",
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "success",
              "failed"
            ]
          },
          "timestamp": {
            "type": "string",
            "format": "date-time"
          },
          "endpoint": {
            "description": "Mandate provider endpoint that was invoked.",
            "type": [
              "string",
              "null"
            ]
          },
          "request_headers": {
            "description": "Headers sent to the mandate provider. Sensitive values are masked.",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "request_body": {
            "description": "Payload sent to the mandate provider.",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "response_code": {
            "description": "HTTP status code returned by the mandate provider.",
            "type": [
              "integer",
              "null"
            ]
          },
          "response_body": {
            "description": "Raw response body returned by the mandate provider.",
            "type": [
              "string",
              "null"
            ]
          },
          "response_headers": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "duration_ms": {
            "description": "Round-trip duration of the call in milliseconds.",
            "type": [
              "integer",
              "null"
            ]
          },
          "retry_attempt": {
            "type": "integer"
          },
          "next_retry_at": {
            "description": "Time at which the next retry will be attempted.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "error_code": {
            "description": "Error code returned by the mandate provider.",
            "type": [
              "string",
              "null"
            ]
          },
          "error_message": {
            "description": "Error message returned by the mandate provider.",
            "type": [
              "string",
              "null"
            ]
          },
          "store_id": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "MandateStatus": {
        "type": "string",
        "enum": [
          "created",
          "active",
          "paused",
          "revoked",
          "error"
        ]
      },
      "ManualPackingDetail": {
        "title": "ManualPackingDetail",
        "type": "object",
        "properties": {
          "packing_option": {
            "enum": [
              "manual"
            ]
          },
          "total_boxes": {
            "type": [
              "integer",
              "null"
            ]
          },
          "items_weight": {
            "type": "number"
          },
          "packing_bin_weight": {
            "type": "number"
          },
          "total_weight": {
            "type": "number"
          },
          "boxes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentBox"
            }
          }
        }
      },
      "ManualPaymentMethod": {
        "title": "ManualPaymentMethod",
        "type": "object",
        "required": [
          "name",
          "description",
          "payment_instructions"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "used_in_credit_line": {
            "description": "`true` when the option is linked in the store credit-line payment method configuration.",
            "type": "boolean",
            "readOnly": true
          },
          "is_connected": {
            "description": "Derived from `status`. `true` when `status` is `active`.",
            "type": "boolean",
            "readOnly": true
          },
          "payment_instructions": {
            "type": "string"
          },
          "mark_as_paid": {
            "description": "When `true`, orders using this method can be marked paid without an online capture flow.",
            "type": "boolean",
            "readOnly": true
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ],
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "ManualSegment": {
        "title": "ManualSegment",
        "allOf": [
          {
            "$ref": "#/components/schemas/SegmentInfo"
          },
          {
            "type": "object",
            "properties": {
              "segment_members": {
                "description": "accepts array of email ids. (valid emails only). \n send null value if members list is empty or to remove all existing members.",
                "type": [
                  "array",
                  "null"
                ],
                "items": {
                  "type": "string"
                },
                "writeOnly": true
              }
            }
          },
          {
            "type": "object",
            "properties": {
              "ad_audiences": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SegmentAdAudience"
                },
                "readOnly": true
              }
            }
          },
          {
            "type": "object",
            "properties": {
              "usage": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SegmentUsage"
                },
                "readOnly": true
              }
            }
          }
        ],
        "x-tags": [
          "Segments"
        ]
      },
      "ManualShippingMethod": {
        "title": "ManualShippingMethod",
        "type": "object",
        "required": [
          "name",
          "shipping_method_type",
          "type",
          "description",
          "is_connected",
          "is_forward_shipping",
          "is_return_shipping",
          "enable_shipping_rate",
          "delivery_leadtime_minimum",
          "delivery_leadtime_maximum",
          "shipping_zone_id",
          "warehouse_id"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "shipping_method_type": {
            "enum": [
              "manual",
              "local-pickup"
            ]
          },
          "type": {
            "enum": [
              "manual",
              "local-pickup"
            ],
            "readOnly": true
          },
          "fulfillment_type": {
            "enum": [
              "delivery",
              "collect-in-store"
            ],
            "readOnly": true
          },
          "description": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_dark": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_light": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo": {
            "description": "Primary logo URL. `null` for manual methods without a logo.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "is_connected": {
            "type": "boolean",
            "default": true,
            "readOnly": true
          },
          "is_default": {
            "type": "boolean",
            "default": false
          },
          "is_forward_shipping": {
            "type": "boolean",
            "default": true
          },
          "is_return_shipping": {
            "type": "boolean",
            "default": true
          },
          "maximum_weight": {
            "description": "can be null if there is no limit on weight.",
            "type": [
              "number",
              "null"
            ]
          },
          "enable_shipping_rate": {
            "type": "boolean"
          },
          "shipping_rate_name": {
            "description": "required if enable_shipping_rate = true; `null` when no shipping rate is set.",
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_rate_fixed_price": {
            "description": "can be null if shipping_rate_condition is provided.",
            "type": [
              "number",
              "null"
            ]
          },
          "shipping_rate_condition": {
            "description": "can be null if shipping_rate_fixed_price is provided.",
            "$ref": "#/components/schemas/ManualShippingRateCondition"
          },
          "delivery_leadtime_minimum": {
            "description": "in days.",
            "type": "integer"
          },
          "delivery_leadtime_maximum": {
            "description": "in days.",
            "type": "integer"
          },
          "shipping_zone_id": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "writeOnly": true
          },
          "warehouse_id": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "writeOnly": true
          },
          "shipping_zone": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                }
              }
            },
            "readOnly": true
          },
          "warehouses": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                }
              }
            },
            "readOnly": true
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ]
          },
          "created_at": {
            "type": "string",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "readOnly": true
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ManualShippingRateCondition": {
        "title": "ManualShippingRateCondition",
        "anyOf": [
          {
            "$ref": "#/components/schemas/ShippingRateBasedOnItemWeight"
          },
          {
            "$ref": "#/components/schemas/ShippingRateBasedOnOrderValue"
          }
        ],
        "x-tags": [
          "Shipping"
        ]
      },
      "MarketplaceAttribute": {
        "title": "MarketplaceAttribute",
        "allOf": [
          {
            "$ref": "#/components/schemas/AttributeBasicDetail"
          },
          {
            "type": "object",
            "properties": {
              "is_required": {
                "type": "boolean"
              }
            },
            "required": [
              "is_required"
            ]
          }
        ]
      },
      "MarketplaceCategory": {
        "title": "MarketplaceCategory",
        "allOf": [
          {
            "$ref": "#/components/schemas/CategoryCommonDetail"
          }
        ]
      },
      "MarketplaceConfig": {
        "title": "MarketplaceConfig",
        "type": "object",
        "required": [
          "marketplace_id",
          "marketplace_name",
          "marketplace_slug",
          "marketplace_type",
          "marketplace_store_id",
          "sync_products",
          "sync_inventory",
          "sync_orders",
          "categories",
          "customer_groups"
        ],
        "properties": {
          "marketplace_id": {
            "type": "string"
          },
          "marketplace_name": {
            "type": "string"
          },
          "marketplace_slug": {
            "type": "string"
          },
          "marketplace_type": {
            "$ref": "#/components/schemas/MarketplaceType"
          },
          "marketplace_store_id": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "marketplace_store_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "required_credentials_params": {
            "type": [
              "object",
              "null"
            ],
            "readOnly": true
          },
          "sync_products": {
            "type": "boolean"
          },
          "sync_inventory": {
            "type": "boolean"
          },
          "sync_orders": {
            "type": "boolean"
          },
          "categories": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MarketplaceCategory"
            }
          },
          "customer_groups": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MarketplaceCustomerGroup"
            }
          }
        }
      },
      "MarketplaceCustomerGroup": {
        "title": "MarketplaceCustomerGroup",
        "allOf": [
          {
            "$ref": "#/components/schemas/CustomerGroup"
          }
        ]
      },
      "MarketplaceItem": {
        "title": "MarketplaceItem",
        "type": "object",
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "sku": {
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_id": {
            "type": "string"
          },
          "marketplace_name": {
            "type": "string"
          },
          "marketplace_slug": {
            "type": "string"
          },
          "status": {
            "$ref": "#/components/schemas/MarketplaceListingStatus"
          },
          "marketplace_product_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_item_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_item_sku": {
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_category": {
            "description": "Marketplace category of the item. Array of category ids.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "marketplace_pricing": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductPricing"
            }
          },
          "marketplace_attribute": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "attribute_id": {
                  "type": "string"
                },
                "attribute_value": {
                  "type": "string"
                }
              },
              "required": [
                "attribute_id",
                "attribute_value"
              ]
            }
          },
          "marketplace_promotion": {
            "$ref": "#/components/schemas/ProductPromotion"
          },
          "marketplace_subscription": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductSubscription"
            }
          },
          "sync_status": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/MarketplaceListingSyncStatus"
              },
              {
                "type": "null"
              }
            ]
          },
          "last_synced_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "sync_error_message": {
            "description": "Error message from the last sync. This is only set if the sync status is failed or error.",
            "type": [
              "string",
              "null"
            ]
          },
          "publication_status": {
            "$ref": "#/components/schemas/MarketplacePublicationStatus"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "MarketplaceListingStatus": {
        "title": "MarketplaceListingStatus",
        "type": "string",
        "enum": [
          "listed",
          "unlisted"
        ]
      },
      "MarketplaceListingSyncStatus": {
        "title": "MarketplaceListingSyncStatus",
        "type": "string",
        "enum": [
          "success",
          "failed",
          "error"
        ]
      },
      "MarketplacePublicationStatus": {
        "description": "Marketplace publication status",
        "type": "string",
        "enum": [
          "published",
          "unpublished"
        ]
      },
      "MarketplaceSchema": {
        "title": "MarketplaceSchema",
        "type": "object",
        "required": [
          "event",
          "schema"
        ],
        "properties": {
          "event": {
            "type": "string"
          },
          "schema": {
            "type": "object"
          }
        }
      },
      "MarketplaceSyncAllProduct": {
        "title": "MarketplaceSyncAllProduct",
        "type": "object",
        "required": [
          "marketplace_id",
          "input_data"
        ],
        "properties": {
          "marketplace_id": {
            "type": "string"
          },
          "input_data": {
            "type": "object",
            "properties": {
              "sync_type": {
                "type": "string",
                "enum": [
                  "all-products"
                ]
              }
            },
            "required": [
              "sync_type"
            ]
          }
        }
      },
      "MarketplaceSyncSpecificProduct": {
        "title": "MarketplaceSyncSpecificProduct",
        "type": "object",
        "required": [
          "marketplace_id",
          "input_data"
        ],
        "properties": {
          "marketplace_id": {
            "type": "string"
          },
          "input_data": {
            "type": "object",
            "properties": {
              "sync_type": {
                "type": "string",
                "enum": [
                  "specific-products"
                ]
              },
              "items": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "product_id",
                    "variant_id"
                  ]
                }
              }
            },
            "required": [
              "sync_type",
              "items"
            ]
          }
        }
      },
      "MarketplaceType": {
        "title": "MarketplaceType",
        "type": "string",
        "enum": [
          "amazon",
          "flipkart",
          "marketplace",
          "internal"
        ]
      },
      "MediaDocumentFile": {
        "title": "MediaDocumentFile",
        "allOf": [
          {
            "$ref": "#/components/schemas/MediaFileInfo"
          },
          {
            "type": "object",
            "properties": {
              "url": {
                "type": [
                  "object",
                  "null"
                ],
                "properties": {
                  "document": {
                    "type": "string",
                    "readOnly": true
                  }
                }
              }
            }
          }
        ],
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MediaFile": {
        "title": "MediaFile",
        "oneOf": [
          {
            "$ref": "#/components/schemas/MediaImageFile"
          },
          {
            "$ref": "#/components/schemas/MediaVideoFile"
          },
          {
            "$ref": "#/components/schemas/MediaDocumentFile"
          }
        ],
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MediaFileInfo": {
        "title": "MediaFileInfo",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "user_id": {
            "type": "string"
          },
          "created_by": {
            "type": "string"
          },
          "file_name": {
            "type": "string"
          },
          "file_extension": {
            "type": "string",
            "readOnly": true
          },
          "file_size": {
            "description": "in bytes",
            "type": "integer",
            "readOnly": true
          },
          "video_duration": {
            "type": [
              "number",
              "null"
            ],
            "readOnly": true
          },
          "external_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "file_type": {
            "enum": [
              "image",
              "video",
              "document"
            ],
            "readOnly": true
          },
          "mime_type": {
            "type": "string",
            "readOnly": true
          },
          "title": {
            "type": "string"
          },
          "alternate_text": {
            "type": [
              "string",
              "null"
            ]
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "meta_data": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                }
              }
            }
          },
          "tags": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "notes": {
            "type": [
              "string",
              "null"
            ]
          },
          "folder_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "upload_source": {
            "enum": [
              "local-storage",
              "external-url"
            ],
            "readOnly": true
          },
          "status": {
            "enum": [
              "ready",
              "uploaded",
              "pending"
            ],
            "readOnly": true
          },
          "usage": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MediaFileUsage"
            },
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MediaFileUploadRequest": {
        "title": "MediaFileUploadRequest",
        "oneOf": [
          {
            "$ref": "#/components/schemas/MediaFileUploadRequestForLocalStorage"
          },
          {
            "$ref": "#/components/schemas/MediaFileUploadRequestForExternalUrl"
          }
        ]
      },
      "MediaFileUploadRequestForExternalUrl": {
        "title": "MediaFileUploadRequestForExternalUrl",
        "type": "object",
        "required": [
          "upload_source",
          "external_url"
        ],
        "properties": {
          "upload_source": {
            "enum": [
              "external-url"
            ]
          },
          "external_url": {
            "type": "string"
          },
          "folder_id": {
            "description": "Optional. If provided, file will be uploaded into the specified folder.",
            "type": "string"
          }
        },
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MediaFileUploadRequestForLocalStorage": {
        "title": "MediaFileUploadRequestForLocalStorage",
        "type": "object",
        "required": [
          "upload_source",
          "file_type",
          "file_name",
          "file_size"
        ],
        "properties": {
          "upload_source": {
            "enum": [
              "local-storage"
            ]
          },
          "file_type": {
            "enum": [
              "image",
              "video",
              "document"
            ]
          },
          "file_name": {
            "type": "string"
          },
          "file_size": {
            "description": "in bytes",
            "type": "integer"
          },
          "folder_id": {
            "description": "Optional. If provided, file will be uploaded into the specified folder.",
            "type": "string"
          }
        },
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MediaFileUsage": {
        "title": "MediaFileUsage",
        "type": "object",
        "properties": {
          "used_in": {
            "description": "section where file is used. e.g. product, campaign",
            "enum": [
              "product",
              "product_variant",
              "variant",
              "campaign",
              "warehouse"
            ]
          },
          "used_in_reference_id": {
            "description": "id of the reference object. e.g. product id, campaign id",
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MediaFolder": {
        "title": "MediaFolder",
        "type": "object",
        "required": [
          "name"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "parent_folder_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MediaImageFile": {
        "title": "MediaImageFile",
        "allOf": [
          {
            "$ref": "#/components/schemas/MediaFileInfo"
          },
          {
            "type": "object",
            "properties": {
              "url": {
                "type": [
                  "object",
                  "null"
                ],
                "properties": {
                  "image_original": {
                    "type": "string",
                    "readOnly": true
                  },
                  "image_standard": {
                    "type": "string",
                    "readOnly": true
                  },
                  "image_thumbnail": {
                    "type": "string",
                    "readOnly": true
                  },
                  "image_blur": {
                    "type": "string",
                    "readOnly": true
                  }
                }
              }
            }
          }
        ],
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MediaVideoFile": {
        "title": "MediaVideoFile",
        "allOf": [
          {
            "$ref": "#/components/schemas/MediaFileInfo"
          },
          {
            "type": "object",
            "properties": {
              "url": {
                "type": [
                  "object",
                  "null"
                ],
                "properties": {
                  "video_preview_url": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "readOnly": true
                  },
                  "video_stream_hls_url": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "video_stream_dash_url": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "readOnly": true
                  },
                  "image_thumbnail": {
                    "type": "string",
                    "readOnly": true
                  }
                }
              }
            }
          }
        ],
        "x-tags": [
          "Media Gallery"
        ]
      },
      "MsOrderPayment": {
        "title": "MsOrderPayment",
        "description": "Payment received in Marketplace for a marketplace-synced order.",
        "allOf": [
          {
            "$ref": "#/components/schemas/OrderPaymentInfo"
          },
          {
            "type": "object",
            "required": [
              "settlement_type"
            ],
            "properties": {
              "payment_date": {
                "type": [
                  "string",
                  "null"
                ],
                "format": "date-time"
              },
              "settlement_type": {
                "enum": [
                  "prepaid"
                ]
              }
            }
          }
        ],
        "x-tags": [
          "Orders"
        ]
      },
      "NetbankingPayment": {
        "title": "NetbankingPayment",
        "description": "Payments using payment gateway netbanking option.",
        "allOf": [
          {
            "$ref": "#/components/schemas/OrderPaymentInfo"
          },
          {
            "type": "object",
            "properties": {
              "bank_name": {
                "type": "string"
              }
            }
          }
        ]
      },
      "NotificationChannelPreferences": {
        "title": "NotificationChannelPreferences",
        "description": "Set specific channel preferences",
        "type": "object",
        "properties": {
          "email": {
            "description": "Indicates whether the user has opted to receive notifications via email.",
            "type": "boolean",
            "default": true
          },
          "sms": {
            "description": "Indicates whether the user has opted to receive notifications via SMS.",
            "type": "boolean",
            "default": true
          },
          "whatsapp": {
            "description": "Indicates whether the user has opted to receive notifications via WhatsApp.",
            "type": "boolean",
            "default": true
          }
        }
      },
      "NotificationPreferences": {
        "title": "NotificationPreferences",
        "description": "Set channel preferences for each type of ",
        "type": "object",
        "properties": {
          "transactional": {
            "description": "These notifications are typically critical for user engagement, providing updates, confirmations, or alerts related to their account activities.",
            "$ref": "#/components/schemas/NotificationChannelPreferences"
          },
          "promotional": {
            "description": "These notifications aim to engage users with promotional content and enhance their overall experience with the platform.",
            "$ref": "#/components/schemas/NotificationChannelPreferences"
          },
          "newsletter": {
            "description": "These notifications are often sent periodically as part of a subscription service.\n",
            "$ref": "#/components/schemas/NotificationChannelPreferences"
          }
        }
      },
      "NumberAttribute": {
        "title": "NumberAttribute",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "is_linked": {
            "type": "boolean",
            "readOnly": true
          },
          "value": {
            "description": "`null` when no value is set for this customer.",
            "type": [
              "number",
              "null"
            ]
          },
          "attribute_type": {
            "enum": [
              "Number"
            ]
          },
          "is_readonly": {
            "type": "boolean",
            "readOnly": true
          },
          "is_pinned": {
            "description": "Whether the attribute is pinned to the top of the customer profile.",
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "last_updated_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "ObjectAttribute": {
        "title": "ObjectAttribute",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "is_linked": {
            "type": "boolean",
            "readOnly": true
          },
          "value": {
            "description": "`null` when no value is set for this customer.",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "attribute_type": {
            "enum": [
              "Object"
            ]
          },
          "is_readonly": {
            "type": "boolean",
            "readOnly": true
          },
          "is_pinned": {
            "description": "Whether the attribute is pinned to the top of the customer profile.",
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "last_updated_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "OpeningHours": {
        "type": "object",
        "required": [
          "monday",
          "tuesday",
          "wednesday",
          "thursday",
          "friday",
          "saturday",
          "sunday"
        ],
        "properties": {
          "monday": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "opening_time": {
                "type": "string",
                "format": "time"
              },
              "closing_time": {
                "type": "string",
                "format": "time"
              }
            },
            "required": [
              "opening_time",
              "closing_time"
            ]
          },
          "tuesday": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "opening_time": {
                "type": "string",
                "format": "time"
              },
              "closing_time": {
                "type": "string",
                "format": "time"
              }
            },
            "required": [
              "opening_time",
              "closing_time"
            ]
          },
          "wednesday": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "opening_time": {
                "type": "string",
                "format": "time"
              },
              "closing_time": {
                "type": "string",
                "format": "time"
              }
            },
            "required": [
              "opening_time",
              "closing_time"
            ]
          },
          "thursday": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "opening_time": {
                "type": "string",
                "format": "time"
              },
              "closing_time": {
                "type": "string",
                "format": "time"
              }
            },
            "required": [
              "opening_time",
              "closing_time"
            ]
          },
          "friday": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "opening_time": {
                "type": "string",
                "format": "time"
              },
              "closing_time": {
                "type": "string",
                "format": "time"
              }
            },
            "required": [
              "opening_time",
              "closing_time"
            ]
          },
          "saturday": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "opening_time": {
                "type": "string",
                "format": "time"
              },
              "closing_time": {
                "type": "string",
                "format": "time"
              }
            },
            "required": [
              "opening_time",
              "closing_time"
            ]
          },
          "sunday": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "opening_time": {
                "type": "string",
                "format": "time"
              },
              "closing_time": {
                "type": "string",
                "format": "time"
              }
            },
            "required": [
              "opening_time",
              "closing_time"
            ]
          }
        }
      },
      "Order": {
        "title": "Order",
        "type": "object",
        "properties": {
          "id": {
            "description": "Same value as `order_number`.",
            "type": "string",
            "readOnly": true
          },
          "order_number": {
            "type": "string"
          },
          "cart_id": {
            "description": "Identifier of the cart the order was created from.",
            "type": "string",
            "readOnly": true
          },
          "order_date": {
            "type": "string",
            "format": "date-time"
          },
          "status": {
            "$ref": "#/components/schemas/OrderStatus"
          },
          "payment_status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "marketplace_synced": {
            "description": "Indicates whether the order was synced from Marketplace.",
            "type": "boolean"
          },
          "payment_success_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "customer_id": {
            "type": "string"
          },
          "customer_email": {
            "type": [
              "string",
              "null"
            ]
          },
          "customer_phone": {
            "type": [
              "string",
              "null"
            ]
          },
          "customer_note": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_promotion_applied": {
            "type": "boolean"
          },
          "promotion_discount_amount": {
            "type": [
              "integer",
              "null"
            ]
          },
          "promotion_discount_percent": {
            "type": [
              "number",
              "null"
            ],
            "format": "double",
            "readOnly": true
          },
          "is_coupon_applied": {
            "type": "boolean"
          },
          "coupon_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_id": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "coupon_discount_amount": {
            "type": [
              "number",
              "null"
            ],
            "format": "double"
          },
          "coupon_discount_percent": {
            "type": [
              "number",
              "null"
            ],
            "format": "double",
            "readOnly": true
          },
          "on_subscription": {
            "type": "boolean"
          },
          "fulfillment_preference": {
            "$ref": "#/components/schemas/FulfillmentPreference"
          },
          "sales_channel": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name",
              "type"
            ]
          },
          "metadata": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "subtotal": {
            "type": "number",
            "format": "double"
          },
          "subtotal_tax": {
            "type": "number",
            "format": "double"
          },
          "subtotal_including_tax": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount": {
            "type": "number",
            "format": "double"
          },
          "shipping_tax_rate": {
            "type": "number",
            "format": "double"
          },
          "shipping_total_tax": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount_including_tax": {
            "type": "number",
            "format": "double"
          },
          "total_tax": {
            "type": "number",
            "format": "double"
          },
          "grand_total": {
            "type": "number",
            "format": "double"
          },
          "loyalty_point_redeemed": {
            "type": "integer"
          },
          "credit_balance_used": {
            "type": "integer"
          },
          "to_be_paid": {
            "type": "number",
            "format": "double"
          },
          "loyalty_point_earned": {
            "type": "integer"
          },
          "order_items_count": {
            "type": "integer"
          },
          "currency": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "code": {
                "type": "string"
              },
              "symbol": {
                "type": "string"
              }
            }
          },
          "feedback": {
            "type": [
              "string",
              "null"
            ]
          },
          "allowed_actions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderAction"
            }
          },
          "applied_coupons": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AppliedCoupon"
            }
          },
          "applied_promotions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AppliedPromotion"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderAction": {
        "enum": [
          "create-shipment",
          "update-order",
          "download-invoice",
          "inventory-check",
          "refresh-payment-status",
          "return-replace",
          "update-payment-status",
          "cancel-order",
          "approve-order"
        ]
      },
      "OrderActivity": {
        "title": "OrderActivity",
        "type": "object",
        "required": [
          "comment"
        ],
        "properties": {
          "activity_type": {
            "description": "`null` when the activity was written without one — the create-activity endpoint requires only `comment`.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "status": {
            "description": "Outcome of the activity, e.g. `success`.",
            "type": "string",
            "readOnly": true
          },
          "comment": {
            "type": "string"
          },
          "details": {
            "description": "Extra context for the activity as key/value pairs, e.g. the payment request number. `null` when the activity carries none.",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                }
              }
            },
            "readOnly": true
          },
          "user_type": {
            "enum": [
              "customer",
              "admin",
              "system"
            ],
            "readOnly": true
          },
          "user_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderAddress": {
        "title": "OrderAddress",
        "description": "Address snapshot captured at checkout for an order or invoice.",
        "type": "object",
        "required": [
          "first_name",
          "phone",
          "email",
          "address_line1",
          "pincode",
          "city",
          "state",
          "country"
        ],
        "properties": {
          "first_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "country_code": {
            "description": "Phone country calling code, e.g. +91.",
            "type": "string"
          },
          "phone": {
            "description": "10 digit phone number without country code.",
            "type": [
              "string",
              "null"
            ]
          },
          "email": {
            "type": [
              "string",
              "null"
            ]
          },
          "address_line1": {
            "type": [
              "string",
              "null"
            ]
          },
          "address_line2": {
            "type": [
              "string",
              "null"
            ]
          },
          "landmark": {
            "type": [
              "string",
              "null"
            ]
          },
          "pincode": {
            "type": [
              "string",
              "null"
            ]
          },
          "city": {
            "type": [
              "string",
              "null"
            ]
          },
          "state": {
            "type": [
              "string",
              "null"
            ]
          },
          "country": {
            "type": [
              "string",
              "null"
            ]
          },
          "gstin": {
            "description": "Use in shipping details only for third party.",
            "type": [
              "string",
              "null"
            ]
          },
          "business_name": {
            "description": "Use in shipping details only for third party.",
            "type": [
              "string",
              "null"
            ]
          },
          "is_phone_verified": {
            "type": "boolean",
            "readOnly": true
          },
          "is_email_verified": {
            "type": "boolean",
            "readOnly": true
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderDetail": {
        "title": "OrderDetail",
        "type": "object",
        "required": [
          "order_number",
          "order_date",
          "status",
          "payment_status",
          "marketplace_synced",
          "payment_success_date",
          "customer_id",
          "customer_email",
          "customer_phone",
          "customer_note",
          "is_promotion_applied",
          "promotion_discount_amount",
          "is_coupon_applied",
          "coupon_code",
          "coupon_discount_amount",
          "on_subscription",
          "fulfillment_preference",
          "sales_channel",
          "metadata",
          "subtotal",
          "subtotal_tax",
          "subtotal_including_tax",
          "shipping_amount",
          "shipping_tax_rate",
          "shipping_total_tax",
          "shipping_amount_including_tax",
          "total_tax",
          "grand_total",
          "loyalty_point_redeemed",
          "credit_balance_used",
          "to_be_paid",
          "loyalty_point_earned",
          "order_items_count",
          "order_items",
          "billing_address",
          "shipping_address",
          "currency",
          "feedback",
          "allowed_actions",
          "applied_coupons",
          "applied_promotions",
          "payments",
          "shipments",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "id": {
            "description": "Same value as `order_number`.",
            "type": "string",
            "readOnly": true
          },
          "order_number": {
            "type": "string"
          },
          "cart_id": {
            "description": "Identifier of the cart the order was created from.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "order_date": {
            "type": "string",
            "format": "date-time"
          },
          "status": {
            "$ref": "#/components/schemas/OrderStatus"
          },
          "payment_status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "marketplace_synced": {
            "description": "Indicates whether the order was synced from Marketplace.",
            "type": "boolean"
          },
          "payment_success_date": {
            "type": [
              "string",
              "null"
            ]
          },
          "customer_id": {
            "type": "string"
          },
          "customer_email": {
            "type": [
              "string",
              "null"
            ]
          },
          "customer_phone": {
            "type": [
              "string",
              "null"
            ]
          },
          "customer_note": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_promotion_applied": {
            "type": "boolean"
          },
          "promotion_discount_amount": {
            "type": [
              "number",
              "null"
            ],
            "format": "double"
          },
          "promotion_discount_percent": {
            "type": [
              "number",
              "null"
            ],
            "format": "double",
            "readOnly": true
          },
          "is_coupon_applied": {
            "type": "boolean"
          },
          "coupon_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_id": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "coupon_discount_amount": {
            "type": [
              "number",
              "null"
            ],
            "format": "double"
          },
          "coupon_discount_percent": {
            "type": [
              "number",
              "null"
            ],
            "format": "double",
            "readOnly": true
          },
          "on_subscription": {
            "type": "boolean"
          },
          "fulfillment_preference": {
            "$ref": "#/components/schemas/FulfillmentPreference"
          },
          "sales_channel": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name",
              "type"
            ]
          },
          "metadata": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "subtotal": {
            "type": "number",
            "format": "double"
          },
          "subtotal_tax": {
            "type": "number",
            "format": "double"
          },
          "subtotal_including_tax": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount": {
            "type": "number",
            "format": "double"
          },
          "shipping_tax_rate": {
            "type": "number",
            "format": "double"
          },
          "shipping_total_tax": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount_including_tax": {
            "type": "number",
            "format": "double"
          },
          "total_tax": {
            "type": "number",
            "format": "double"
          },
          "grand_total": {
            "type": "number",
            "format": "double"
          },
          "loyalty_point_redeemed": {
            "type": "number",
            "format": "double"
          },
          "credit_balance_used": {
            "type": "number",
            "format": "double"
          },
          "to_be_paid": {
            "type": "number",
            "format": "double"
          },
          "loyalty_point_earned": {
            "type": "number",
            "format": "double"
          },
          "order_items_count": {
            "type": "integer"
          },
          "order_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderItem"
            }
          },
          "billing_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "shipping_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "currency": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "code": {
                "type": "string"
              },
              "symbol": {
                "type": "string"
              }
            }
          },
          "feedback": {
            "type": [
              "string",
              "null"
            ]
          },
          "allowed_actions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderAction"
            }
          },
          "applied_coupons": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AppliedCoupon"
            }
          },
          "applied_promotions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AppliedPromotion"
            }
          },
          "payments": {
            "description": "Uses `OrderPayment` when `marketplace_synced` is `false`. Uses `MsOrderPayment` when `marketplace_synced` is `true`.",
            "oneOf": [
              {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/OrderPayment"
                }
              },
              {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/MsOrderPayment"
                }
              }
            ]
          },
          "shipments": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderShipment"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderItem": {
        "title": "OrderItem",
        "type": "object",
        "required": [
          "sku",
          "quantity"
        ],
        "properties": {
          "product_id": {
            "type": "string",
            "readOnly": true
          },
          "product_name": {
            "type": "string",
            "readOnly": true
          },
          "slug": {
            "description": "Slug of the thing actually ordered — the variant's slug when the item has a variant, otherwise the product's.",
            "type": "string",
            "readOnly": true
          },
          "product_slug": {
            "type": "string",
            "readOnly": true
          },
          "variant_slug": {
            "description": "Null or an empty string when the item has no variant.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "product_type": {
            "$ref": "#/components/schemas/ProductType"
          },
          "product_image_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "sku": {
            "type": "string"
          },
          "on_offer": {
            "type": "boolean",
            "readOnly": true
          },
          "on_promotion": {
            "type": "boolean",
            "readOnly": true
          },
          "on_subscription": {
            "type": "boolean"
          },
          "subscription_plan": {
            "type": [
              "string",
              "null"
            ]
          },
          "subscription_interval": {
            "type": [
              "integer",
              "null"
            ],
            "readOnly": true
          },
          "subscription_frequency": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "quantity": {
            "type": "integer"
          },
          "incremental_quantity": {
            "description": "Step the quantity can be changed by.",
            "type": "integer",
            "readOnly": true
          },
          "free_quantity": {
            "type": "integer",
            "readOnly": true
          },
          "is_free_item": {
            "type": "boolean",
            "readOnly": true
          },
          "selling_price": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "selling_price_excluding_tax": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "listing_price": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "price_including_tax": {
            "description": "Whether `selling_price` and `listing_price` already include tax. A flag, not an amount.",
            "type": "boolean",
            "readOnly": true
          },
          "promotion_discount_amount": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "promotion_discount_percent": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "coupon_discount_amount": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "coupon_discount_percent": {
            "type": [
              "number",
              "null"
            ],
            "format": "double",
            "readOnly": true
          },
          "tax_type": {
            "enum": [
              "gst",
              "GST"
            ],
            "readOnly": true
          },
          "tax_rate": {
            "type": "number",
            "format": "float",
            "readOnly": true
          },
          "tax_amount": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "hsncode": {
            "description": "HSN code used for the item's tax treatment.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "handling_charge_excluding_tax": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "handling_charge_including_tax": {
            "type": "number",
            "format": "double"
          },
          "handling_charge_tax_rate": {
            "type": "number",
            "format": "double"
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "product_variant_id": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "seller_id": {
            "description": "Seller ID. This field is relevant for marketplace type stores only. Will return null for b2b and b2c type stores.",
            "type": [
              "string",
              "null"
            ]
          },
          "seller_detail": {
            "description": "Seller detail information. This field is relevant for marketplace type stores only. Will return null for b2b and b2c type stores.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/SellerBasicDetail"
              },
              {
                "type": "null"
              }
            ]
          },
          "seller_product_id": {
            "description": "Seller's own product identifier. Relevant to marketplace stores only; `null` for b2b and b2c stores.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "seller_variant_id": {
            "description": "Seller's own variant identifier. Relevant to marketplace stores only; `null` for b2b and b2c stores.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "attributes": {
            "description": "Product attributes captured on the item at the time of the order.",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "key": {
                  "description": "Attribute name in snake case.",
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "type": {
                  "description": "Attribute type, e.g. `single-select`, `boolean`, `text`, `multi-select`, `date`, `color`.",
                  "type": "string"
                },
                "value": {
                  "description": "Shape follows `type`: a string for `text`, `single-select` and `date`, a boolean for `boolean`. Items carrying `multi-select` or `color` attributes were not present in the sample, so their shape is deliberately left open."
                }
              }
            },
            "readOnly": true
          },
          "associated_options": {
            "description": "Variant options, keyed by the option's snake-case key. `null` for items with no variant.",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string"
                },
                "type": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                }
              }
            },
            "readOnly": true
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderList": {
        "title": "OrderList",
        "description": "order list model",
        "type": "object",
        "required": [
          "id",
          "order_number",
          "order_date",
          "status",
          "payment_status",
          "marketplace_synced",
          "payment_success_date",
          "fulfillment_type",
          "on_subscription",
          "grand_total",
          "loyalty_point_redeemed",
          "credit_balance_used",
          "to_be_paid",
          "order_items_count",
          "order_items",
          "customer_id",
          "customer_note",
          "billing_address",
          "shipping_address",
          "loyalty_point_earned",
          "coupon_code",
          "currency",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "id": {
            "description": "Order id. Same as order number.",
            "type": "string"
          },
          "order_number": {
            "description": "Unique number associated with the order.",
            "type": "string"
          },
          "cart_id": {
            "description": "Identifier of the cart the order was created from.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "order_date": {
            "description": "Date and time when the order was placed.",
            "type": "string",
            "format": "date-time"
          },
          "status": {
            "$ref": "#/components/schemas/OrderStatus"
          },
          "payment_status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "marketplace_synced": {
            "description": "Indicates whether the order was synced from Marketplace.",
            "type": "boolean"
          },
          "payment_success_date": {
            "description": "Date and time when the payment for the order was successfully processed.",
            "type": [
              "string",
              "null"
            ]
          },
          "fulfillment_type": {
            "enum": [
              "collect-in-store",
              "delivery"
            ]
          },
          "on_subscription": {
            "description": "Indicates whether the order includes subscription items.",
            "type": "boolean"
          },
          "grand_total": {
            "description": "Total amount for the order, including all items, taxes, and discounts.",
            "type": "number",
            "format": "double"
          },
          "loyalty_point_redeemed": {
            "description": "Number of loyalty points redeemed in the order.",
            "type": "number",
            "format": "double"
          },
          "credit_balance_used": {
            "description": "Amount of credit balance used in the order.",
            "type": "number",
            "format": "double"
          },
          "to_be_paid": {
            "description": "Amount remaining to be paid for the order.",
            "type": "number",
            "format": "double"
          },
          "order_items_count": {
            "description": "Total count of items included in the order.",
            "type": "integer"
          },
          "order_items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderItem"
            }
          },
          "customer_id": {
            "type": "string"
          },
          "customer_note": {
            "type": [
              "string",
              "null"
            ]
          },
          "billing_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "shipping_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "loyalty_point_earned": {
            "type": "number",
            "format": "double"
          },
          "coupon_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_id": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "currency": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "code": {
                "type": "string"
              },
              "symbol": {
                "type": "string"
              }
            },
            "required": [
              "name",
              "code",
              "symbol"
            ]
          },
          "sales_channel": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name",
              "type"
            ]
          },
          "metadata": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderPayment": {
        "title": "OrderPayment",
        "description": "Order payment. Each array entry matches one method-specific shape; only fields for that method are present (for example `card_number` on card payments, `bank_name` on bank transfer).",
        "oneOf": [
          {
            "$ref": "#/components/schemas/CardPayment"
          },
          {
            "$ref": "#/components/schemas/BankTransfer"
          },
          {
            "$ref": "#/components/schemas/NetbankingPayment"
          },
          {
            "$ref": "#/components/schemas/UpiPayment"
          },
          {
            "$ref": "#/components/schemas/WalletPayment"
          },
          {
            "$ref": "#/components/schemas/LoyaltyPointPayment"
          },
          {
            "$ref": "#/components/schemas/OrderPaymentCommonOnly"
          }
        ],
        "x-tags": [
          "Orders"
        ]
      },
      "OrderPaymentCommonOnly": {
        "title": "OrderPaymentCommonOnly",
        "description": "Order payment with only common fields, for methods such as Cash, NACH, or POS entries with no method-specific metadata.",
        "allOf": [
          {
            "$ref": "#/components/schemas/OrderPaymentInfo"
          }
        ],
        "x-tags": [
          "Orders"
        ]
      },
      "OrderPaymentInfo": {
        "title": "OrderPaymentInfo",
        "description": "Common fields in all types of payments.",
        "type": "object",
        "properties": {
          "transaction_type": {
            "enum": [
              "payment",
              "refund"
            ]
          },
          "request_number": {
            "type": "string"
          },
          "amount": {
            "type": "number",
            "format": "double"
          },
          "payment_status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "payment_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "payment_reference_number": {
            "type": [
              "string",
              "null"
            ]
          },
          "payment_method": {
            "description": "Empty string when recorded without a method, as on point-of-sale orders; null for refunds.",
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "Card",
              "Credit Card",
              "Debit Card",
              "Netbanking",
              "UPI",
              "Wallet",
              "Loyalty Point",
              "IMPS",
              "NEFT",
              "RTGS",
              "Cash",
              "NACH",
              "",
              null
            ]
          },
          "payment_mode": {
            "type": "string"
          },
          "icon_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderReceiptJsonFormat": {
        "title": "OrderReceiptJsonFormat",
        "allOf": [
          {
            "$ref": "#/components/schemas/Order"
          },
          {
            "type": "object",
            "properties": {
              "billing_address": {
                "$ref": "#/components/schemas/OrderAddress"
              },
              "shipping_address": {
                "$ref": "#/components/schemas/OrderAddress"
              },
              "order_items": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/OrderItem"
                }
              },
              "payments": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/OrderPayment"
                }
              }
            }
          }
        ]
      },
      "OrderRefundAmountBreakup": {
        "title": "OrderRefundAmountBreakup",
        "description": "One line item in a refund amount breakdown, describing how a portion of the refund maps back to an original payment.",
        "type": "object",
        "properties": {
          "original_payment_mode": {
            "description": "Payment mode used in the original transaction this portion of the refund is being attributed to (e.g., `payment-gateway`, `bank-transfer`).",
            "type": "string",
            "enum": [
              "payment-gateway",
              "bank-transfer"
            ]
          },
          "original_payment_method": {
            "description": "Payment method used in the original transaction (e.g., `NACH`, `UPI`, `CARD`, `NETBANKING`, `WALLET`, `IMPS`, `NEFT`, `RTGS`).",
            "type": "string"
          },
          "amount": {
            "description": "Refund amount to be credited to the customer. Amount will be adjusted for any scheduled payment if provided order was paid using NACH mandate.",
            "type": "number"
          },
          "label": {
            "description": "Explanation of how this portion of the refund will be processed. Safe to display directly to the operator.",
            "type": "string"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderRefundEstimate": {
        "title": "OrderRefundEstimate",
        "description": "A preview of the refund a customer will receive when an order or a shipment is cancelled and refunded. Returned by the refund estimate endpoint and used to drive the operator's refund-mode selection before any refund is actually initiated.",
        "type": "object",
        "properties": {
          "order_number": {
            "type": "string"
          },
          "shipment_number": {
            "description": "Reference number of the shipment the refund is being estimated for. `null` when the estimate covers the whole order.",
            "type": [
              "string",
              "null"
            ]
          },
          "currency": {
            "$ref": "#/components/schemas/Currency"
          },
          "refund_amount": {
            "description": "Total refundable amount for the order or shipment, before choosing a refund mode.",
            "type": "number"
          },
          "refund_amount_breakup": {
            "description": "Breakdown of `refund_amount` across the original payment modes and methods. Drives the explanation shown to the operator and customer about how the refund will be processed.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderRefundAmountBreakup"
            }
          },
          "recommended_refund_mode": {
            "description": "Refund mode the system recommends based on the original payment mix and store configuration. Should be pre-selected in the operator UI.",
            "type": "string"
          },
          "available_refund_modes": {
            "description": "Refund modes the operator can choose from for this shipment. Common values include `bank-transfer` and `original-payment-mode`.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "previous_refund_amount": {
            "description": "Total amount already refunded against this order in earlier refund operations. `0` if no refunds have been processed yet.",
            "type": "number"
          },
          "previous_refund_amount_breakup": {
            "description": "Breakdown of `previous_refund_amount` by the payment mode/method each portion was refunded to.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderRefundAmountBreakup"
            }
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderShipment": {
        "title": "OrderShipment",
        "description": "Order shipment model",
        "type": "object",
        "properties": {
          "reference_number": {
            "type": "string"
          },
          "status": {
            "$ref": "#/components/schemas/ShipmentStatus"
          },
          "total_weight": {
            "type": "number"
          },
          "total_boxes": {
            "type": [
              "integer",
              "null"
            ]
          },
          "shipment_items_count": {
            "type": "integer"
          },
          "shipment_items": {
            "description": "`ShipmentItemStandard` on B2B/B2C stores; `ShipmentItem` when `seller_detail` is returned for marketplace stores.",
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "$ref": "#/components/schemas/ShipmentItemStandard"
                },
                {
                  "$ref": "#/components/schemas/ShipmentItem"
                }
              ]
            }
          },
          "shipping_estimated_cost": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "shipping_discount_amount": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "shipping_amount": {
            "type": "number",
            "format": "double"
          },
          "shipping_tax_rate": {
            "type": "number",
            "format": "double",
            "readOnly": true
          },
          "shipping_tax_amount": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount_including_tax": {
            "type": "number",
            "format": "double"
          },
          "shipping_provider_id": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "shipping_provider_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "courier_company_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "courier_company_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_label_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "awb_no": {
            "type": [
              "string",
              "null"
            ]
          },
          "eta_delivery": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "promised_delivery_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "readOnly": true
          },
          "estimated_delivery_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time",
            "readOnly": true
          },
          "shipped_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "delivered_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "cancellation_reason": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_address_line1": {
            "type": "string",
            "readOnly": true
          },
          "shipping_address_line2": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "shipping_landmark": {
            "description": "Empty string when the address has no landmark.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "shipping_city": {
            "type": "string",
            "readOnly": true
          },
          "shipping_state": {
            "type": "string",
            "readOnly": true
          },
          "shipping_pincode": {
            "type": "string",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "OrderShipmentDetail": {
        "title": "OrderShipmentDetail",
        "type": "object",
        "required": [
          "order_number",
          "order_date",
          "order_status",
          "sales_channel",
          "payment_status",
          "customer_name",
          "shipments",
          "allowed_actions"
        ],
        "properties": {
          "order_number": {
            "type": "string"
          },
          "order_date": {
            "type": "string",
            "format": "date-time"
          },
          "order_status": {
            "$ref": "#/components/schemas/OrderStatus"
          },
          "sales_channel": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name",
              "type"
            ]
          },
          "payment_status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "customer_name": {
            "type": "string"
          },
          "customer_id": {
            "type": "string"
          },
          "sales_channel_type": {
            "description": "Type of the sales channel, repeated flat alongside `sales_channel`.",
            "type": "string"
          },
          "sub_total": {
            "type": "number",
            "format": "double"
          },
          "total_tax": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount": {
            "type": "number",
            "format": "double"
          },
          "grand_total": {
            "type": "number",
            "format": "double"
          },
          "coupon_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "coupon_discount_amount": {
            "type": "number",
            "format": "double"
          },
          "coupon_discount_percent": {
            "type": [
              "number",
              "null"
            ],
            "format": "double"
          },
          "shipments": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Shipment"
            }
          },
          "allowed_actions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/InventoryAction"
            }
          }
        }
      },
      "OrderStats": {
        "title": "OrderStats",
        "type": "object",
        "properties": {
          "total_order": {
            "type": "integer"
          },
          "total_revenue": {
            "type": "number"
          },
          "live_order": {
            "type": "integer"
          },
          "live_order_revenue": {
            "type": "number"
          },
          "completed_order": {
            "type": "integer"
          },
          "completed_order_revenue": {
            "type": "number"
          },
          "cancelled_order": {
            "type": "integer"
          },
          "cancelled_order_revenue": {
            "type": "number"
          },
          "conversion_rate": {
            "type": "number"
          },
          "gross_revenue": {
            "type": "number"
          },
          "net_revenue": {
            "type": "number"
          },
          "total_spending": {
            "type": "number"
          }
        }
      },
      "OrderStatus": {
        "enum": [
          "draft",
          "awaiting_approval",
          "confirmed",
          "schedule_requested",
          "partially_scheduled",
          "awaiting_shipment",
          "shipped",
          "partially_shipped",
          "undelivered",
          "partially_undelivered",
          "return_to_origin",
          "partially_return_to_origin",
          "complete",
          "partially_delivered",
          "cancelled",
          "pending",
          "lost",
          "sent_to_store",
          "store_rejected"
        ]
      },
      "OtherServiceProvider": {
        "title": "OtherServiceProvider",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "readOnly": true
          },
          "alias": {
            "type": "string",
            "readOnly": true
          },
          "logo": {
            "description": "Primary logo URL. Same as `logo_light` for most providers.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "service_sub_type": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "service_type": {
            "$ref": "#/components/schemas/ServiceProviderType",
            "readOnly": true
          },
          "description": {
            "type": "string",
            "readOnly": true
          },
          "short_description": {
            "type": "string",
            "readOnly": true
          },
          "logo_dark": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_light": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "website_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "api_doc_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "required_credentials_params": {
            "description": "json object in key & value pair.",
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "input_field_name": {
                  "type": "string"
                },
                "input_field_label": {
                  "type": "string"
                },
                "input_field_type": {
                  "enum": [
                    "text",
                    "number",
                    "boolean",
                    "email",
                    "password"
                  ]
                }
              }
            },
            "readOnly": true
          },
          "is_connected": {
            "type": "boolean",
            "default": false,
            "readOnly": true
          },
          "is_connection_expired": {
            "type": "boolean",
            "default": true,
            "readOnly": true
          },
          "supports_test_connection": {
            "type": "boolean",
            "default": true,
            "readOnly": true
          },
          "api_credentials": {
            "description": "Connected credential values. Keys match `required_credentials_params[].input_field_name`. Returned as `null`, or as an empty array `[]`, when the provider has no stored credentials.",
            "type": [
              "object",
              "array",
              "null"
            ],
            "additionalProperties": true,
            "readOnly": true
          },
          "status": {
            "default": "active",
            "enum": [
              "active",
              "inactive",
              "error"
            ]
          },
          "features": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                },
                "is_supported": {
                  "type": "boolean"
                },
                "features": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "is_supported": {
                        "type": "boolean"
                      }
                    }
                  }
                }
              }
            },
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "Pagination": {
        "title": "Pagination",
        "description": "pagination metadata structure",
        "type": "object",
        "properties": {
          "total_records": {
            "type": "integer"
          },
          "total_pages": {
            "type": "integer"
          },
          "previous_page": {
            "description": "Previous page number",
            "type": [
              "integer",
              "null"
            ]
          },
          "limit": {
            "type": "integer",
            "default": 25
          },
          "next_page": {
            "description": "Next page number",
            "type": [
              "integer",
              "null"
            ]
          }
        }
      },
      "PartialCollectAndDelivery": {
        "title": "PartialCollectAndDelivery",
        "type": "object",
        "required": [
          "fulfillment_type",
          "collect-in-store",
          "delivery"
        ],
        "properties": {
          "fulfillment_type": {
            "type": "string",
            "const": "partial-collect-and-delivery"
          },
          "preference_type": {
            "type": "string",
            "enum": [
              "user",
              "auto"
            ],
            "readOnly": true
          },
          "collect-in-store": {
            "type": "object",
            "properties": {
              "pickup_location_id": {
                "type": "string"
              },
              "pickup_location_name": {
                "type": "string",
                "readOnly": true
              },
              "items": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/FulfillmentItem"
                }
              }
            },
            "required": [
              "items",
              "pickup_location_id"
            ]
          },
          "delivery": {
            "type": "object",
            "properties": {
              "shipping_provider_id": {
                "type": "string"
              },
              "shipping_provider_name": {
                "type": [
                  "string",
                  "null"
                ],
                "readOnly": true
              },
              "courier_company_id": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "courier_company_name": {
                "type": [
                  "string",
                  "null"
                ],
                "readOnly": true
              },
              "items": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/FulfillmentItem"
                }
              }
            },
            "required": [
              "shipping_provider_id",
              "items"
            ]
          }
        }
      },
      "Payment": {
        "title": "Payment",
        "description": "Common fields in inbound and refund payments.",
        "allOf": [
          {
            "$ref": "#/components/schemas/PaymentCommonFields"
          },
          {
            "$ref": "#/components/schemas/PaymentMethodDetail"
          }
        ],
        "x-tags": [
          "Payments"
        ]
      },
      "PaymentAction": {
        "enum": [
          "refund",
          "send-reminder",
          "cancel"
        ]
      },
      "PaymentCommonFields": {
        "title": "PaymentCommonFields",
        "description": "Common fields in inbound and refund payments.",
        "type": "object",
        "properties": {
          "transaction_type": {
            "enum": [
              "payment",
              "refund"
            ]
          },
          "request_number": {
            "type": "string"
          },
          "transaction_date": {
            "type": "string",
            "format": "date-time"
          },
          "transaction_amount": {
            "type": "number",
            "format": "double"
          },
          "settled_amount": {
            "type": "number",
            "format": "double",
            "default": 0
          },
          "unsettled_amount": {
            "type": "number",
            "format": "double",
            "default": 0
          },
          "payment_method": {
            "enum": [
              "Credit Card",
              "Debit Card",
              "Netbanking",
              "UPI",
              "Wallet",
              "IMPS",
              "NEFT",
              "RTGS",
              "NACH"
            ]
          },
          "payment_reference_number": {
            "type": "string"
          },
          "payment_mode": {
            "enum": [
              "bank-transfer",
              "payment-gateway",
              "nach-mandate"
            ]
          },
          "payment_gateway": {
            "description": "Payment provider slug when `payment_mode` is `payment-gateway`. `null` otherwise.",
            "oneOf": [
              {
                "type": "null"
              },
              {
                "type": "string",
                "enum": [
                  "juspay",
                  "icici-ecollection",
                  "icici-cib",
                  "PAYU",
                  "DUMMY"
                ]
              }
            ]
          },
          "status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "user_id": {
            "type": "string"
          },
          "customer_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "customer_name": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "x-tags": [
          "Payments"
        ]
      },
      "PaymentDetail": {
        "title": "PaymentDetail",
        "description": "Payment info with settlement details.",
        "allOf": [
          {
            "$ref": "#/components/schemas/Payment"
          },
          {
            "type": "object",
            "properties": {
              "settlement": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/PaymentSettlement"
                }
              },
              "allowed_actions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/PaymentAction"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Payments"
        ]
      },
      "PaymentMethodDetail": {
        "title": "PaymentMethodDetail",
        "description": "Method-specific details carried on a payment. Only fields for the payment's `payment_method` are populated; others are omitted or `null`.",
        "type": "object",
        "properties": {
          "icon_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "card_number": {
            "description": "Masked card number when `payment_method` is a card type.",
            "type": [
              "string",
              "null"
            ]
          },
          "card_type": {
            "type": [
              "string",
              "null"
            ]
          },
          "bank_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "wallet_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "bank_account_number": {
            "type": [
              "string",
              "null"
            ]
          },
          "upi_id": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "additionalProperties": true,
        "x-tags": [
          "Payments"
        ]
      },
      "PaymentSettlement": {
        "title": "PaymentSettlement",
        "description": "Payment settlement details.",
        "allOf": [
          {
            "type": "object",
            "properties": {
              "settlement_option": {
                "enum": [
                  "order",
                  "refund",
                  "payment"
                ]
              },
              "settlement_date": {
                "type": "string",
                "format": "date-time"
              },
              "settled_amount": {
                "type": "number",
                "format": "double"
              },
              "payment_method": {
                "type": "string"
              },
              "card_number": {
                "type": "string"
              },
              "card_type": {
                "type": "string"
              },
              "upi_id": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "bank_account_number": {
                "type": "string"
              },
              "bank_name": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "icon_url": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "order_number": {
                "description": "Present when `settlement_option` is `order`.",
                "type": "string",
                "readOnly": true
              },
              "order_date": {
                "description": "Present when `settlement_option` is `order`.",
                "type": "string",
                "format": "date-time",
                "readOnly": true
              },
              "order_amount": {
                "description": "Present when `settlement_option` is `order`.",
                "type": "number",
                "format": "double",
                "readOnly": true
              },
              "order_status": {
                "description": "Present when `settlement_option` is `order`.",
                "$ref": "#/components/schemas/OrderStatus",
                "readOnly": true
              }
            }
          },
          {
            "oneOf": [
              {
                "$ref": "#/components/schemas/PaymentSettlementWithOrder"
              },
              {
                "$ref": "#/components/schemas/PaymentSettlementWithRefund"
              },
              {
                "$ref": "#/components/schemas/RefundForPaymentSettlement"
              }
            ]
          }
        ],
        "x-tags": [
          "Payments"
        ]
      },
      "PaymentSettlementWithOrder": {
        "title": "PaymentSettlementWithOrder",
        "description": "Payment settlement with orders",
        "type": "object",
        "properties": {
          "order_number": {
            "type": "string"
          },
          "order_date": {
            "type": "string",
            "format": "date-time"
          },
          "order_amount": {
            "type": "number",
            "format": "double"
          },
          "order_status": {
            "$ref": "#/components/schemas/OrderStatus"
          }
        },
        "x-tags": [
          "Payments"
        ]
      },
      "PaymentSettlementWithRefund": {
        "title": "PaymentSettlementWithRefund",
        "description": "Payment settlement with orders",
        "allOf": [
          {
            "$ref": "#/components/schemas/PaymentSettlementWithRefundCommon"
          },
          {
            "$ref": "#/components/schemas/PaymentMethodDetail"
          }
        ],
        "x-tags": [
          "Payments"
        ]
      },
      "PaymentSettlementWithRefundCommon": {
        "title": "PaymentSettlementWithRefundCommon",
        "description": "Payment settlement with orders",
        "type": "object",
        "properties": {
          "payment_method": {
            "type": "string"
          },
          "payment_reference_number": {
            "type": "string"
          },
          "request_number": {
            "type": "string"
          },
          "transaction_date": {
            "type": "string",
            "format": "date-time"
          },
          "transaction_amount": {
            "type": "number",
            "format": "double"
          },
          "status": {
            "enum": [
              "success"
            ]
          }
        },
        "x-tags": [
          "Payments"
        ]
      },
      "PaymentStats": {
        "title": "PaymentStats",
        "type": "object",
        "properties": {
          "total_payments": {
            "type": "integer"
          },
          "total_payments_value": {
            "type": [
              "number",
              "null"
            ]
          },
          "total_refunds": {
            "type": "integer"
          },
          "total_refunds_value": {
            "type": [
              "number",
              "null"
            ]
          }
        }
      },
      "PaymentStatus": {
        "title": "PaymentStatus",
        "enum": [
          "pending",
          "success",
          "failed",
          "partially_paid",
          "refund_initiated",
          "refunded",
          "unsettled",
          "settled",
          "partially_settled",
          "debit_scheduled",
          "collection_due"
        ]
      },
      "PayoutConfig": {
        "title": "PayoutConfig",
        "type": "object",
        "required": [
          "payment_option",
          "payment_methods"
        ],
        "properties": {
          "payment_option": {
            "description": "Controls how seller payouts are disbursed.\n\n- `auto` - payout batches are settled through the connected payment providers listed in `payment_methods`.\n\n- `manual` - payouts are settled outside the platform, so no provider is linked and `payment_methods` is empty.",
            "enum": [
              "auto",
              "manual"
            ]
          },
          "payment_methods": {
            "description": "Payment providers used to settle payout batches. When writing, send only `slug` and `is_default` for each entry; the response returns each fully expanded `PayoutPaymentMethod`. Send an empty array when `payment_option` is `manual`.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PayoutPaymentMethod"
            }
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "PayoutPaymentMethod": {
        "title": "PayoutPaymentMethod",
        "type": "object",
        "required": [
          "slug"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "readOnly": true
          },
          "slug": {
            "description": "Slug of the payment provider to pay out through, for example `juspay` or `icici-cib`. The only identifier required when writing the payout configuration.",
            "type": "string"
          },
          "description": {
            "type": "string",
            "readOnly": true
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ],
            "readOnly": true
          },
          "type": {
            "description": "`auto` for connected payment service providers; `manual` for store-defined payment methods.",
            "enum": [
              "auto",
              "manual"
            ],
            "readOnly": true
          },
          "used_in_payout": {
            "description": "`true` when the provider is linked in the store payout configuration.",
            "type": "boolean",
            "readOnly": true
          },
          "is_default": {
            "description": "Marks the provider used to settle payout batches by default. Exactly one entry should be `true` when `payment_option` is `auto`.",
            "type": "boolean",
            "default": false
          },
          "logo_dark": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_light": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "PercentageBasedDiscount": {
        "title": "PercentageBasedDiscount",
        "description": "promotion_type = discount",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "discount_type",
          "discount_percent",
          "customer_group_id",
          "minimum_quantity",
          "maximum_quantity",
          "maximum_discount_amount"
        ],
        "properties": {
          "discount_type": {
            "type": "string",
            "const": "percentage"
          },
          "discount_percent": {
            "type": "number"
          },
          "customer_group_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "minimum_quantity": {
            "description": "It refers to the minimum quantity of a specific item a customer must purchase to qualify for the promotion.",
            "type": "integer",
            "default": 1
          },
          "maximum_quantity": {
            "description": "It refers to the maximum quantity of a specific item a customer can purchase in order to qualify for the promotion. If this field is set to null, it indicates that there is no limit.",
            "type": [
              "integer",
              "null"
            ]
          },
          "maximum_discount_amount": {
            "description": "When a value is specified, the discount amount will not exceed the defined maximum, ensuring that the promotion stays within a controlled discount range. If this field is set to null, it indicates that there is no limit to the discount amount.",
            "type": [
              "number",
              "null"
            ]
          }
        }
      },
      "PercentageTieredDiscountSlab": {
        "title": "PercentageTieredDiscountSlab",
        "type": "object",
        "required": [
          "order_value",
          "condition",
          "discount_type",
          "discount_percent"
        ],
        "properties": {
          "order_value": {
            "description": "The order total the cart is evaluated against for this slab.",
            "type": "number"
          },
          "condition": {
            "description": "This key defines how the system will evaluate the order total to determine if the discount should be applied, based on the specified slab. The last slab must use `greater` so the highest tier stays open-ended.",
            "enum": [
              "less-or-equal",
              "greater"
            ]
          },
          "discount_type": {
            "type": "string",
            "const": "percentage"
          },
          "discount_percent": {
            "type": "number"
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "Pincode": {
        "title": "Pincode",
        "description": "Pincode model",
        "type": "object",
        "properties": {
          "pincode": {
            "type": "string"
          },
          "city": {
            "type": "string"
          },
          "state_name": {
            "type": "string"
          },
          "country_name": {
            "type": "string"
          },
          "country_iso_code": {
            "type": "string"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "PosDevice": {
        "title": "PosDevice",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "device_type": {
            "enum": [
              "pos-terminal"
            ]
          },
          "external_device_id": {
            "description": "A unique ID issued by the Vendor.",
            "type": "string"
          },
          "vendor": {
            "type": "string"
          },
          "model_number": {
            "type": "string"
          },
          "mac_address": {
            "type": [
              "string",
              "null"
            ]
          },
          "location_id": {
            "type": "string"
          },
          "location_name": {
            "type": "string",
            "readOnly": true
          },
          "claimed_by": {
            "description": "Returns a user object if the device is claimed, otherwise returns null.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/PosDeviceClaimedUser"
              },
              {
                "type": "null"
              }
            ]
          },
          "status": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PosDeviceStatus"
              }
            ],
            "readOnly": true
          },
          "is_busy": {
            "description": "This field specifies the device is occupied for a transaction.",
            "type": "boolean"
          }
        }
      },
      "PosDeviceClaimedUser": {
        "title": "PosDeviceClaimedUser",
        "type": "object",
        "required": [
          "id",
          "first_name",
          "last_name",
          "phone",
          "email"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "first_name": {
            "type": "string"
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "phone": {
            "type": "string"
          },
          "email": {
            "type": "string",
            "format": "email"
          }
        }
      },
      "PosDeviceStatus": {
        "title": "PosDeviceStatus",
        "type": "string",
        "enum": [
          "unpaired",
          "available",
          "claimed",
          "offline",
          "revoked"
        ]
      },
      "PosPermission": {
        "title": "PosPermission",
        "type": "object",
        "required": [
          "module_name",
          "resource_group",
          "description"
        ],
        "properties": {
          "module_name": {
            "type": "string"
          },
          "resource_group": {
            "type": "string"
          },
          "description": {
            "type": "string"
          }
        }
      },
      "PosRole": {
        "title": "PosRole",
        "type": "object",
        "required": [
          "name",
          "type",
          "permissions"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "type": {
            "enum": [
              "global",
              "custom"
            ],
            "readOnly": true
          },
          "permissions": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "module_name",
                "resource_group",
                "permission_type"
              ],
              "properties": {
                "module_name": {
                  "type": "string"
                },
                "resource_group": {
                  "type": "string"
                },
                "permission_type": {
                  "enum": [
                    "admin",
                    "readonly",
                    "none"
                  ]
                }
              }
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        }
      },
      "PosUser": {
        "title": "PosUser",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "store_id": {
            "type": "string",
            "readOnly": true
          },
          "first_name": {
            "type": "string"
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "phone": {
            "description": "10 digit phone number without country code.",
            "type": "string"
          },
          "email": {
            "type": "string",
            "format": "email"
          },
          "pin": {
            "type": "integer",
            "readOnly": true
          },
          "roles": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "location_id": {
                  "type": "string"
                },
                "location_name": {
                  "type": "string",
                  "readOnly": true
                },
                "role_id": {
                  "type": "string"
                },
                "role_name": {
                  "type": "string",
                  "readOnly": true
                }
              }
            }
          },
          "status": {
            "$ref": "#/components/schemas/PosUserStatus"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        }
      },
      "PosUserStatus": {
        "title": "PosUserStatus",
        "type": "string",
        "enum": [
          "active",
          "inactive",
          "blocked"
        ]
      },
      "Product": {
        "title": "Product",
        "type": "object",
        "required": [
          "reviews_rating_sum",
          "reviews_count",
          "is_featured",
          "on_offer",
          "on_promotion",
          "on_subscription",
          "has_variant",
          "sku"
        ],
        "properties": {
          "id": {
            "description": "product id",
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "maxLength": 128
          },
          "status": {
            "description": "This field is relevant for b2b and b2c type stores only and it will be returned only for b2b and b2c type stores. It is computed based on the status of the variants if product has variants otherwise it is computed based on the active channels associated with the product.",
            "$ref": "#/components/schemas/ProductStatus",
            "readOnly": true
          },
          "active": {
            "description": "This field is relevant for b2b and b2c type stores only and it will be returned only for b2b and b2c type stores.",
            "type": "boolean",
            "readOnly": true
          },
          "publication_status": {
            "description": "This field is relevant for marketplace type stores only and it will be returned only for marketplace type stores.",
            "$ref": "#/components/schemas/MarketplacePublicationStatus",
            "readOnly": true
          },
          "stock_available": {
            "type": "boolean"
          },
          "short_description": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 1024
          },
          "metadata": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "product_type": {
            "enum": [
              "physical",
              "digital",
              "bundle"
            ]
          },
          "hsn_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "categories": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string",
                  "readOnly": true
                },
                "active": {
                  "type": "boolean",
                  "readOnly": true
                }
              }
            }
          },
          "sales_channels": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SalesChannel"
            }
          },
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductAttribute"
            }
          },
          "variant_options": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/VariantOption"
            }
          },
          "reviews_rating_sum": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "reviews_count": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "is_featured": {
            "type": "boolean"
          },
          "on_offer": {
            "type": "boolean"
          },
          "on_promotion": {
            "type": "boolean"
          },
          "on_subscription": {
            "type": "boolean"
          },
          "has_variant": {
            "type": "boolean"
          },
          "variant_count": {
            "type": "integer",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "sku": {
            "description": "`null` on a draft product until a SKU is set.",
            "type": [
              "string",
              "null"
            ],
            "maxLength": 64
          },
          "slug": {
            "type": "string",
            "maxLength": 128
          },
          "images": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductImage"
            }
          },
          "videos": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductVideo"
            }
          },
          "seller_id": {
            "description": "Seller ID. This field is relevant for marketplace type stores only. Will return null for b2b and b2c type stores.",
            "type": [
              "string",
              "null"
            ]
          },
          "seller_detail": {
            "description": "Seller detail information. This field is relevant for marketplace type stores only. Will return null for b2b and b2c type stores.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/SellerInfo"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductAnalyticsStats": {
        "title": "ProductAnalyticsStats",
        "type": "object",
        "properties": {
          "viewed": {
            "type": "integer"
          },
          "added_to_cart": {
            "type": "integer"
          },
          "removed_from_cart": {
            "type": "integer"
          },
          "checkout_started": {
            "type": "integer"
          },
          "purchased": {
            "type": "integer"
          }
        }
      },
      "ProductAttribute": {
        "title": "ProductAttribute",
        "type": "object",
        "properties": {
          "id": {
            "description": "Attribute id as returned on SKU and search payloads; same as `attribute_id` on write.",
            "type": "string"
          },
          "name": {
            "description": "Display name; same as `attribute_name` on write payloads.",
            "type": "string",
            "readOnly": true
          },
          "type": {
            "description": "Same as `attribute_type` on write payloads.",
            "type": "string",
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "single-select",
              "multi-select",
              "color"
            ],
            "readOnly": true
          },
          "value": {
            "description": "Resolved value; same as `attribute_value` on write payloads.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              },
              {
                "type": "boolean"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              {
                "$ref": "#/components/schemas/ColorObject"
              }
            ]
          },
          "is_visible": {
            "type": "boolean",
            "readOnly": true
          },
          "is_filterable": {
            "type": "boolean",
            "readOnly": true
          },
          "attribute_id": {
            "type": "string"
          },
          "attribute_name": {
            "type": "string",
            "readOnly": true
          },
          "attribute_type": {
            "type": "string",
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "single-select",
              "multi-select",
              "color"
            ],
            "readOnly": true
          },
          "attribute_value": {
            "oneOf": [
              {
                "type": "string",
                "description": "string value for attribute type **text**, **single select** and **date**."
              },
              {
                "type": "number",
                "description": "numeric value for attribute type number."
              },
              {
                "type": "boolean",
                "description": "true/false for attribute type boolean."
              },
              {
                "type": "array",
                "description": "for attribute type = multi-select",
                "items": {
                  "type": "string"
                }
              },
              {
                "$ref": "#/components/schemas/ColorObject",
                "description": "for attribute type = color"
              }
            ]
          },
          "key": {
            "description": "Value in snake case.",
            "type": "string",
            "readOnly": true
          }
        },
        "examples": [],
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductBasicDetail": {
        "title": "ProductBasicDetail",
        "type": "object",
        "properties": {
          "id": {
            "description": "product id or combination of product id and variant id separated by hyphen.",
            "type": "string",
            "readOnly": true
          },
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "product_type": {
            "enum": [
              "physical",
              "digital",
              "bundle"
            ]
          },
          "status": {
            "enum": [
              "draft",
              "active",
              "inactive"
            ],
            "readOnly": true
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "reviews_rating_sum": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "reviews_count": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "hsn_code": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          },
          "slug": {
            "type": "string",
            "maxLength": 128
          },
          "sku": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          },
          "associated_options": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AssociatedOption"
            }
          },
          "active": {
            "type": "boolean"
          },
          "stock_available": {
            "type": "boolean"
          },
          "images": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductImage"
            }
          },
          "pricing": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductPricing"
            }
          },
          "metadata": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductAttribute"
            }
          },
          "category_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "is_featured": {
            "type": "boolean"
          },
          "on_offer": {
            "type": "boolean",
            "readOnly": true
          },
          "on_promotion": {
            "type": "boolean",
            "readOnly": true
          },
          "on_subscription": {
            "type": "boolean",
            "readOnly": true
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "short_description": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 1024
          },
          "promotion": {
            "$ref": "#/components/schemas/ProductPromotion"
          },
          "subscription": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductSubscription"
            }
          },
          "shipping": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/ProductShipping"
              },
              {
                "type": "null"
              }
            ]
          },
          "packaging": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProductPackaging"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductBundleItem": {
        "title": "ProductBundelItem",
        "allOf": [
          {
            "$ref": "#/components/schemas/ProductBasicDetail"
          },
          {
            "type": "object",
            "properties": {
              "quantity": {
                "type": "integer"
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductChannel": {
        "title": "ProductChannel",
        "allOf": [
          {
            "$ref": "#/components/schemas/ProductBasicDetail"
          },
          {
            "type": "object",
            "properties": {
              "attributes": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductAttribute"
                }
              },
              "sales_channels": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SalesChannel"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductCommonDetail": {
        "title": "ProductCommonDetail",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string",
            "maxLength": 128
          },
          "slug": {
            "type": "string",
            "maxLength": 128
          },
          "status": {
            "enum": [
              "draft",
              "active",
              "inactive"
            ],
            "readOnly": true
          },
          "active": {
            "type": "boolean",
            "readOnly": true
          },
          "stock_available": {
            "type": "boolean",
            "readOnly": true
          },
          "short_description": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 1024
          },
          "metadata": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "tags": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "product_type": {
            "enum": [
              "physical",
              "digital",
              "bundle"
            ],
            "readOnly": true
          },
          "hsn_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductAttribute"
            }
          },
          "seo": {
            "$ref": "#/components/schemas/Seo"
          },
          "variant_options": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/VariantOption"
            },
            "readOnly": true
          },
          "reviews_rating_sum": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "reviews_count": {
            "type": "integer",
            "format": "int32",
            "readOnly": true
          },
          "is_featured": {
            "type": "boolean"
          },
          "on_offer": {
            "type": "boolean",
            "default": false,
            "readOnly": true
          },
          "on_promotion": {
            "type": "boolean",
            "readOnly": true
          },
          "on_subscription": {
            "type": "boolean",
            "readOnly": true
          },
          "has_variant": {
            "type": "boolean",
            "readOnly": true
          },
          "variant_count": {
            "type": "integer",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductDataSync": {
        "title": "ProductDataSync",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "sku": {
            "type": "string"
          },
          "listing_price": {
            "type": "number"
          },
          "selling_price": {
            "type": "number"
          },
          "image_url": {
            "type": "string"
          },
          "stock_available": {
            "type": "boolean"
          },
          "status": {
            "type": "string"
          },
          "last_synced_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductDetail": {
        "title": "ProductDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/Product"
          },
          {
            "type": "object",
            "properties": {
              "description": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "videos": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductVideo"
                }
              },
              "pricing": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductPricing"
                }
              },
              "shipping": {
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/ProductShipping"
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "packaging": {
                "$ref": "#/components/schemas/ProductPackaging"
              },
              "promotions": {
                "$ref": "#/components/schemas/ProductPromotion"
              },
              "subscriptions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductSubscription"
                }
              },
              "related_products": {
                "type": "object",
                "properties": {
                  "upsell": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/ProductBasicDetail"
                    }
                  },
                  "cross_sell": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/ProductBasicDetail"
                    }
                  }
                }
              },
              "variants": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductDetailVariant"
                }
              },
              "bundle_items": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductBundleItem"
                }
              },
              "seo": {
                "$ref": "#/components/schemas/Seo"
              },
              "integrations": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductIntegrationSync"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductDetailVariant": {
        "title": "ProductDetailVariant",
        "description": "A variant as embedded in `ProductDetail.variants`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/Variant"
          },
          {
            "type": "object",
            "properties": {
              "status": {
                "$ref": "#/components/schemas/ProductStatus",
                "readOnly": true
              },
              "sales_channels": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SalesChannel"
                }
              },
              "shipping": {
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/ProductShipping"
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "packaging": {
                "$ref": "#/components/schemas/VariantPackaging"
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductImage": {
        "title": "ProductImage",
        "type": "object",
        "properties": {
          "title": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          },
          "alternate_text": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128
          },
          "sort_order": {
            "type": "integer",
            "format": "int32"
          },
          "url_tiny": {
            "type": "string",
            "maxLength": 512
          },
          "url_thumbnail": {
            "type": "string",
            "maxLength": 512
          },
          "url_standard": {
            "type": "string",
            "maxLength": 512
          },
          "url_zoom": {
            "type": "string",
            "maxLength": 512
          },
          "file_id": {
            "type": "string"
          },
          "file_type": {
            "description": "MIME type of the file, e.g. `image/png`.",
            "type": "string"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductIntegrationSync": {
        "title": "ProductIntegrationSync",
        "type": "object",
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "integration_name": {
            "type": "string"
          },
          "sync_status": {
            "enum": [
              "pending",
              "success",
              "failed"
            ]
          },
          "item_id": {
            "type": "string"
          },
          "item_type": {
            "description": "Item type in the integration that wrote the row, e.g. `product`, `productbundle`, `category`, `ce_item`.",
            "type": "string"
          },
          "item_type_id": {
            "type": "string"
          },
          "item_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "schema": {
            "type": "string"
          },
          "logo": {
            "type": [
              "string",
              "null"
            ]
          },
          "last_updated": {
            "type": "string",
            "format": "date-time"
          },
          "last_synced": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "ProductInventory": {
        "title": "ProductInventory",
        "type": "object",
        "properties": {
          "variant_id": {
            "description": "required only if product has_variant = true. otherwise it can be excluded or pass null.\n",
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "description": "`null` for products without variants.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "product_id": {
            "type": "string",
            "readOnly": true
          },
          "product_name": {
            "type": "string",
            "readOnly": true
          },
          "update_other_variants": {
            "description": "Can be used for the product having variants. if true, same inventry details will be updated to other variants which are not mentioned in request body.",
            "type": "boolean",
            "writeOnly": true
          },
          "track_quantity": {
            "type": "boolean"
          },
          "track_lot_batch": {
            "type": "boolean"
          },
          "allow_backorder": {
            "type": "boolean"
          },
          "low_stock_threshold": {
            "type": "integer",
            "readOnly": true
          },
          "stock_available": {
            "type": "boolean",
            "readOnly": true
          },
          "stock": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "warehouse_id",
                "stock_quantity"
              ],
              "properties": {
                "sku": {
                  "type": "string",
                  "readOnly": true
                },
                "warehouse": {
                  "oneOf": [
                    {
                      "$ref": "#/components/schemas/WarehouseBasicDetail"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "opening_stock_date": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time"
                },
                "warehouse_id": {
                  "type": "string"
                },
                "warehouse_name": {
                  "type": "string",
                  "readOnly": true
                },
                "received_quantity": {
                  "type": "number",
                  "readOnly": true
                },
                "reserved_quantity": {
                  "type": "number",
                  "readOnly": true
                },
                "sold_quantity": {
                  "type": "number",
                  "readOnly": true
                },
                "adjusted_quantity": {
                  "type": "number",
                  "readOnly": true
                },
                "stock_quantity": {
                  "description": "Send `null` to clear the stock of a deactivated warehouse.",
                  "type": [
                    "number",
                    "null"
                  ]
                },
                "lot_batch": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "mfg_date": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date"
                },
                "exp_date": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date"
                },
                "manufacturer": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time",
                  "readOnly": true
                },
                "modified_at": {
                  "type": "string",
                  "format": "date-time",
                  "readOnly": true
                }
              }
            }
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductInventoryActivity": {
        "title": "ProductInventoryActivity",
        "type": "object",
        "required": [
          "warehouse_id",
          "activity_type",
          "quantity",
          "reason"
        ],
        "properties": {
          "product_id": {
            "type": "string",
            "readOnly": true
          },
          "product_name": {
            "type": "string",
            "readOnly": true
          },
          "variant_id": {
            "description": "`null` for products without variants.",
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "warehouse_id": {
            "type": "string",
            "maxLength": 128
          },
          "warehouse": {
            "$ref": "#/components/schemas/InventoryActivityWarehouse",
            "readOnly": true
          },
          "sku": {
            "type": "string",
            "readOnly": true
          },
          "activity_type": {
            "description": "`reset` rows are written when a stock quantity is set outright rather than adjusted.",
            "enum": [
              "add",
              "reserve",
              "reduce",
              "reset",
              "release"
            ]
          },
          "quantity": {
            "type": "integer"
          },
          "reason": {
            "type": "string",
            "maxLength": 512
          },
          "lot_batch": {
            "type": [
              "string",
              "null"
            ]
          },
          "mfg_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date"
          },
          "exp_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date"
          },
          "manufacturer": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductPackaging": {
        "title": "ProductPackaging",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "pack_width",
          "pack_height",
          "pack_length",
          "pack_dry_weight",
          "units_per_pack",
          "vertical_rotation"
        ],
        "properties": {
          "product_id": {
            "type": "string",
            "readOnly": true
          },
          "product_variant_id": {
            "description": "`null` when packaging applies to a product without variants.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "product_name": {
            "type": "string",
            "readOnly": true
          },
          "variant_name": {
            "description": "`null` when packaging applies to a product without variants.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "pack_width": {
            "type": "number",
            "format": "float"
          },
          "pack_height": {
            "type": "number",
            "format": "float"
          },
          "pack_length": {
            "type": "number",
            "format": "float"
          },
          "pack_dry_weight": {
            "type": "number",
            "format": "float"
          },
          "units_per_pack": {
            "type": "integer",
            "format": "int32"
          },
          "vertical_rotation": {
            "description": "Indicates whether items can be rotated during packing or if they must be kept in a strictly vertical orientation.",
            "type": "boolean"
          },
          "shipper_width": {
            "type": [
              "number",
              "null"
            ],
            "format": "float"
          },
          "shipper_height": {
            "type": [
              "number",
              "null"
            ],
            "format": "float"
          },
          "shipper_length": {
            "type": [
              "number",
              "null"
            ],
            "format": "float"
          },
          "shipper_dry_weight": {
            "type": [
              "number",
              "null"
            ],
            "format": "float"
          },
          "units_per_shipper": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int32"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductPricing": {
        "title": "ProductPricing",
        "type": "object",
        "required": [
          "customer_group_id",
          "cost_price",
          "listing_price",
          "selling_price",
          "tax_rate"
        ],
        "properties": {
          "customer_group_id": {
            "description": "customer group id. for different pricing model in case of multiple customer groups.",
            "type": [
              "string",
              "null"
            ]
          },
          "cost_price": {
            "type": [
              "number",
              "null"
            ],
            "format": "double"
          },
          "listing_price": {
            "type": "number",
            "format": "double"
          },
          "selling_price": {
            "type": "number",
            "format": "double"
          },
          "min_order_quantity": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int32",
            "default": 1
          },
          "max_order_quantity": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int32"
          },
          "incremental_quantity": {
            "type": [
              "integer",
              "null"
            ],
            "format": "int32",
            "default": 1
          },
          "tax_type": {
            "enum": [
              "GST"
            ],
            "readOnly": true
          },
          "tax_rate": {
            "type": "number",
            "format": "double"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductPromotion": {
        "title": "ProductPromotion",
        "oneOf": [
          {
            "$ref": "#/components/schemas/DiscountBasedPromotion"
          },
          {
            "$ref": "#/components/schemas/FixedPricePromotion"
          },
          {
            "$ref": "#/components/schemas/VolumeBasedPromotion"
          },
          {
            "$ref": "#/components/schemas/FreeGoodsPromotion"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductReview": {
        "title": "ProductReview",
        "type": "object",
        "required": [
          "product_id",
          "rating",
          "review_text",
          "name",
          "email",
          "status",
          "is_featured",
          "review_date"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "product_id": {
            "type": "string",
            "readOnly": true
          },
          "rating": {
            "type": "number",
            "format": "float",
            "readOnly": true
          },
          "review_text": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128,
            "readOnly": true
          },
          "email": {
            "type": [
              "string",
              "null"
            ],
            "maxLength": 128,
            "readOnly": true
          },
          "status": {
            "enum": [
              "pending",
              "approved",
              "rejected",
              "archived"
            ]
          },
          "is_featured": {
            "type": "boolean"
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "images": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "$ref": "#/components/schemas/ProductImage"
            }
          },
          "videos": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "$ref": "#/components/schemas/ProductVideo",
              "type": "object"
            }
          },
          "review_date": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "review_reply": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductShipping": {
        "title": "ProductShipping",
        "type": "object",
        "required": [
          "handling_charge"
        ],
        "properties": {
          "handling_charge": {
            "description": "A handling charge is an additional fee applied to cover the costs associated with preparing, packaging, and processing an order for shipment or delivery.",
            "type": "number",
            "minimum": 0
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductStatus": {
        "enum": [
          "draft",
          "active",
          "inactive"
        ]
      },
      "ProductSubscription": {
        "title": "ProductSubscription",
        "type": "object",
        "required": [
          "subscription_plan",
          "billing_interval",
          "billing_frequency",
          "billing_limit",
          "billing_trial_days",
          "fulfill_separately",
          "subscription_price"
        ],
        "properties": {
          "subscription_plan_id": {
            "type": "string",
            "readOnly": true
          },
          "subscription_plan": {
            "type": "string"
          },
          "billing_interval": {
            "type": "integer",
            "format": "int32"
          },
          "billing_frequency": {
            "enum": [
              "monthly"
            ]
          },
          "billing_limit": {
            "type": [
              "integer",
              "null"
            ]
          },
          "billing_trial_days": {
            "type": "integer",
            "format": "int32",
            "default": 0
          },
          "order_interval": {
            "type": [
              "integer",
              "null"
            ]
          },
          "order_frequency": {
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "monthly"
            ]
          },
          "order_limit": {
            "type": [
              "integer",
              "null"
            ]
          },
          "fulfill_separately": {
            "type": "boolean"
          },
          "subscription_price": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "suscription_price",
                "minimum_quantity",
                "customer_group_id"
              ],
              "properties": {
                "suscription_price": {
                  "type": "number",
                  "format": "double"
                },
                "minimum_quantity": {
                  "type": "integer",
                  "default": 1
                },
                "customer_group_id": {
                  "description": "customer group id.",
                  "type": [
                    "string",
                    "null"
                  ]
                }
              }
            }
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductType": {
        "title": "ProductType",
        "description": "Type of product",
        "type": "string",
        "enum": [
          "physical",
          "digital",
          "bundle"
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "ProductVideo": {
        "title": "ProductVideo",
        "type": "object",
        "properties": {
          "title": {
            "type": [
              "string",
              "null"
            ]
          },
          "alternate_text": {
            "type": [
              "string",
              "null"
            ]
          },
          "sort_order": {
            "type": "integer"
          },
          "video_preview_url": {
            "type": "string"
          },
          "video_stream_hls_url": {
            "type": "string"
          },
          "video_stream_dash_url": {
            "type": "string"
          },
          "image_thumbnail_url": {
            "type": "string"
          },
          "video_duration": {
            "type": [
              "number",
              "null"
            ]
          },
          "file_id": {
            "type": "string"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "Promotion": {
        "title": "Promotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "promotion_type",
              "can_be_used_with_other_promotion"
            ],
            "properties": {
              "store_id": {
                "type": "string",
                "readOnly": true
              },
              "promotion_type": {
                "$ref": "#/components/schemas/PromotionType"
              },
              "can_be_used_with_other_promotion": {
                "type": "boolean"
              },
              "priority": {
                "type": [
                  "integer",
                  "null"
                ],
                "maximum": 5,
                "minimum": 1
              },
              "applies_to_product": {
                "enum": [
                  "all",
                  "product",
                  "category"
                ]
              },
              "details": {
                "description": "Promotion rules; shape depends on `promotion_type`.",
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/AutoScaleBasedOnQuantity"
                  },
                  {
                    "$ref": "#/components/schemas/AutoScaleBasedOnAmount"
                  },
                  {
                    "$ref": "#/components/schemas/CustomSlabsBasedOnQuantity"
                  },
                  {
                    "$ref": "#/components/schemas/CustomSlabsBasedOnAmount"
                  },
                  {
                    "$ref": "#/components/schemas/BuyXGetYRuleBasedOnQuantity"
                  },
                  {
                    "$ref": "#/components/schemas/BuyXGetYRuleBasedOnAmount"
                  },
                  {
                    "$ref": "#/components/schemas/VolumeBasedRule"
                  },
                  {
                    "$ref": "#/components/schemas/FreeShippingDetails"
                  },
                  {
                    "$ref": "#/components/schemas/DiscountRule"
                  }
                ]
              },
              "terms_and_conditions": {
                "type": [
                  "array",
                  "null"
                ],
                "items": {
                  "type": "string"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "PromotionDetail": {
        "title": "PromotionDetail",
        "description": "Full promotion returned on retrieve and update. Same shape as `Promotion`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/Promotion"
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "PromotionType": {
        "title": "PromotionType",
        "type": "string",
        "enum": [
          "discount",
          "free-goods",
          "free-shipping",
          "buy-x-get-y",
          "volume-based"
        ]
      },
      "RefundForPaymentSettlement": {
        "title": "RefundForPaymentSettlement",
        "allOf": [
          {
            "$ref": "#/components/schemas/RefundForPaymentSettlementCommon"
          },
          {
            "$ref": "#/components/schemas/PaymentMethodDetail"
          }
        ],
        "x-tags": [
          "Payments"
        ]
      },
      "RefundForPaymentSettlementCommon": {
        "title": "RefundForPaymentSettlementCommon",
        "type": "object",
        "properties": {
          "payment_method": {
            "type": "string"
          },
          "payment_reference_number": {
            "type": "string"
          },
          "request_number": {
            "type": "string"
          },
          "transaction_date": {
            "type": "string",
            "format": "date-time"
          },
          "transaction_amount": {
            "type": "number",
            "format": "double"
          },
          "status": {
            "enum": [
              "settled"
            ]
          }
        },
        "x-tags": [
          "Payments"
        ]
      },
      "RemoveMarketplaceListing": {
        "title": "RemoveMarketplaceListing",
        "type": "object",
        "required": [
          "product_id",
          "variant_id"
        ],
        "properties": {
          "product_id": {
            "type": "string"
          },
          "variant_id": {
            "type": [
              "string",
              "null"
            ]
          }
        }
      },
      "Rounding": {
        "title": "Rounding",
        "description": "Define how to round the shipping cost",
        "type": "object",
        "required": [
          "unit",
          "method"
        ],
        "properties": {
          "unit": {
            "type": "number",
            "exclusiveMinimum": 0
          },
          "method": {
            "type": "string",
            "enum": [
              "nearest",
              "ceil",
              "floor"
            ]
          }
        },
        "additionalProperties": false
      },
      "SalesChannel": {
        "title": "SalesChannel",
        "type": "object",
        "required": [
          "id",
          "name",
          "active"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string",
            "readOnly": true
          },
          "kind": {
            "type": "string",
            "enum": [
              "storefront",
              "marketplace"
            ]
          },
          "active": {
            "type": "boolean",
            "readOnly": true
          },
          "sales_channel_type": {
            "description": "Observed values: `commercengine`, `web`, `pos`.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "sales_channel_slug": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          }
        }
      },
      "Segment": {
        "title": "Segment",
        "allOf": [
          {
            "$ref": "#/components/schemas/SegmentInfo"
          }
        ],
        "x-tags": [
          "Segments"
        ]
      },
      "SegmentAdAudience": {
        "title": "SegmentAdAudience",
        "type": "object",
        "required": [
          "name",
          "service_provider_id"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "audience_match_field": {
            "type": [
              "string",
              "null"
            ]
          },
          "service_provider_id": {
            "type": "string"
          },
          "service_provider_name": {
            "type": "string",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "last_synced_status": {
            "description": "default status = pending",
            "enum": [
              "success",
              "failed",
              "pending"
            ],
            "readOnly": true
          },
          "last_synced_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "total_people_synced": {
            "type": "integer",
            "readOnly": true
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "SegmentAdAudienceSyncHistory": {
        "title": "SegmentAdAudienceSyncHistory",
        "type": "object",
        "properties": {
          "synced_status": {
            "description": "default status = pending",
            "enum": [
              "success",
              "failed",
              "pending"
            ]
          },
          "synced_at": {
            "type": "string",
            "format": "date-time"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "request_payload": {
            "type": "string"
          },
          "response_data": {
            "type": "string"
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "SegmentDetail": {
        "title": "SegmentDetail",
        "oneOf": [
          {
            "$ref": "#/components/schemas/ManualSegment"
          },
          {
            "$ref": "#/components/schemas/DynamicSegment"
          }
        ],
        "x-tags": [
          "Segments"
        ]
      },
      "SegmentInfo": {
        "title": "SegmentInfo",
        "type": "object",
        "required": [
          "name",
          "segment_type"
        ],
        "properties": {
          "id": {
            "description": "segment id",
            "type": "string",
            "readOnly": true
          },
          "name": {
            "description": "segment name",
            "type": "string"
          },
          "segment_type": {
            "enum": [
              "dynamic",
              "manual"
            ]
          },
          "status": {
            "description": "default status is draft",
            "enum": [
              "draft",
              "active",
              "inactive",
              "archived"
            ]
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "meta": {
            "description": "meta data in key-value pair. example - [{\"key\":\"value\"}]",
            "type": "array",
            "items": {
              "type": "object"
            }
          },
          "description": {
            "type": "string"
          },
          "people_count": {
            "type": "integer",
            "default": 0,
            "readOnly": true
          },
          "usage_count": {
            "type": "integer",
            "default": 0,
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "archived_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "SegmentMember": {
        "title": "SegmentMember",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "email": {
            "type": "string",
            "readOnly": true
          },
          "phone": {
            "type": "string",
            "readOnly": true
          },
          "first_name": {
            "type": "string",
            "readOnly": true
          },
          "last_name": {
            "type": "string",
            "readOnly": true
          },
          "first_seen": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "last_seen": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "SegmentUsage": {
        "title": "SegmentUsage",
        "type": "object",
        "properties": {
          "campaigns": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "created_at": {
                  "type": "string",
                  "format": "date-time"
                },
                "modified_at": {
                  "type": "string",
                  "format": "date-time"
                }
              }
            }
          }
        },
        "x-tags": [
          "Segments"
        ]
      },
      "SellerAccountStatus": {
        "title": "SellerAccountStatus",
        "type": "string",
        "enum": [
          "pending_approval",
          "approved",
          "rejected"
        ]
      },
      "SellerBasicDetail": {
        "title": "SellerBasicDetail",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "trade_name": {
            "type": "string"
          },
          "legal_name": {
            "type": "string"
          },
          "business_type": {
            "$ref": "#/components/schemas/SellerBusinessType"
          },
          "tax_identification_number": {
            "type": "string"
          }
        }
      },
      "SellerBusinessType": {
        "title": "SellerBusinessType",
        "type": "string",
        "enum": [
          "sole_proprietorship",
          "private_limited",
          "public_listed",
          "public_limited",
          "state_owned",
          "charity",
          "individual"
        ]
      },
      "SellerInfo": {
        "title": "SellerInfo",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "description": "Display name of the seller. Sent in place of `trade_name` and `legal_name` on the abbreviated form of this object.",
            "type": "string"
          },
          "trade_name": {
            "type": "string"
          },
          "legal_name": {
            "type": "string"
          },
          "business_type": {
            "$ref": "#/components/schemas/SellerBusinessType"
          },
          "tax_identification_number": {
            "type": "string"
          },
          "status": {
            "$ref": "#/components/schemas/SellerAccountStatus"
          },
          "kyc_status": {
            "$ref": "#/components/schemas/SellerKycStatus"
          },
          "visibility": {
            "description": "Visibility of the products of the seller. public: products are visible to all users, private: products are visible to only authenticated users.",
            "type": "string",
            "enum": [
              "public",
              "private"
            ]
          },
          "logo": {
            "type": [
              "string",
              "null"
            ]
          }
        }
      },
      "SellerKycStatus": {
        "title": "SellerKycStatus",
        "type": "string",
        "enum": [
          "document_pending",
          "document_submitted",
          "approved",
          "rejected"
        ]
      },
      "SellerPayoutAdjustment": {
        "title": "SellerPayoutAdjustment",
        "type": "object",
        "properties": {
          "adjustment_type": {
            "type": "string",
            "enum": [
              "credit",
              "debit"
            ]
          },
          "amount": {
            "description": "Adjustment amount, as a decimal string.",
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "payout_batch_id": {
            "description": "Linked payout batch ULID when the adjustment has been applied to a batch.",
            "type": [
              "string",
              "null"
            ]
          },
          "reference_field": {
            "type": "string"
          },
          "reference_id": {
            "type": "string"
          },
          "reference_type": {
            "type": "string"
          },
          "seller_id": {
            "type": "string"
          },
          "seller_name": {
            "type": "string",
            "readOnly": true
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "applied",
              "cancelled"
            ]
          },
          "tax_amount": {
            "description": "Tax on the adjustment, as a decimal string.",
            "type": "string"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutAdjustmentCreate": {
        "title": "SellerPayoutAdjustmentCreate",
        "type": "object",
        "required": [
          "adjustment_type",
          "amount",
          "seller_id",
          "tax_amount"
        ],
        "properties": {
          "adjustment_type": {
            "type": "string",
            "enum": [
              "credit",
              "debit"
            ]
          },
          "amount": {
            "description": "Must be greater than 0.",
            "type": "number"
          },
          "reference_field": {
            "type": "string"
          },
          "reference_id": {
            "type": "string"
          },
          "reference_type": {
            "type": "string"
          },
          "seller_id": {
            "description": "Seller ID must exist in the marketplace seller cache.",
            "type": "string"
          },
          "tax_amount": {
            "type": "number"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutBatch": {
        "title": "SellerPayoutBatch",
        "description": "A settlement batch that groups a seller's payout-eligible invoices into a single transfer.",
        "type": "object",
        "properties": {
          "batch_number": {
            "description": "Human-readable batch reference, e.g. `PB-TNSFR9Q0HA7J`.",
            "type": "string"
          },
          "credit_adjustments": {
            "description": "Total credits applied to the batch from its `adjustments`, as a decimal string.",
            "type": "string"
          },
          "debit_adjustments": {
            "description": "Total debits applied to the batch from its `adjustments`, as a decimal string.",
            "type": "string"
          },
          "id": {
            "description": "Payout batch ULID.",
            "type": "string"
          },
          "include_shipping_in_payout": {
            "description": "Snapshot of the seller's payout config at batch creation. When `true`, shipping charges are part of the payable amount.",
            "type": "boolean"
          },
          "include_tax_in_payout": {
            "description": "Snapshot of the seller's payout config at batch creation. When `true`, tax collected on the invoices is part of the payable amount.",
            "type": "boolean"
          },
          "initiated_by": {
            "description": "`system` for scheduled batch runs, `admin` for manually created batches.",
            "type": "string",
            "enum": [
              "system",
              "admin"
            ]
          },
          "initiated_by_user_id": {
            "description": "The admin user who created the batch. `null` when `initiated_by` is `system`.",
            "type": [
              "string",
              "null"
            ]
          },
          "invoice_count": {
            "description": "Number of payout invoices settled by this batch.",
            "type": "integer"
          },
          "marketplace_detail": {
            "description": "Marketplace context for this payout batch. Returned as `null` when not applicable.",
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "id": {
                "description": "Marketplace ULID.",
                "type": "string",
                "example": "01KVZ1TK3V1ZB8TK2V3E3G64FS"
              },
              "marketplace_type": {
                "example": "internal",
                "$ref": "#/components/schemas/MarketplaceType"
              },
              "name": {
                "type": "string",
                "example": "Davai Marketplace"
              },
              "slug": {
                "type": "string",
                "example": "davai-marketplace"
              },
              "store_id": {
                "type": "string",
                "example": "f7ul64jr3n"
              }
            }
          },
          "payment_gateway": {
            "description": "Slug of the payment provider that transferred the batch, for example `juspay` or `icici-cib`. `null` until the batch is transferred, and for batches settled manually.",
            "type": [
              "string",
              "null"
            ]
          },
          "payment_gateway_reference_no": {
            "description": "Reference number issued by the bank or gateway for the transfer, such as the NEFT UTR. `null` until the batch is transferred.",
            "type": [
              "string",
              "null"
            ]
          },
          "payment_method": {
            "description": "Instrument used for the transfer, one of `CC`, `DC`, `NEFT`, `RTGS`, `IMPS`, `UPI`, or `WALLET`. `null` until the batch is transferred.",
            "type": [
              "string",
              "null"
            ]
          },
          "payment_mode": {
            "description": "How the batch was paid to the seller, either `bank-transfer` or `payment-gateway`. `null` until the batch is transferred.",
            "type": [
              "string",
              "null"
            ]
          },
          "payment_option": {
            "description": "Snapshot of the store `payout` configuration at batch creation. `auto` batches are settled through a connected provider; `manual` batches are paid outside the platform and recorded with the manual-payment endpoint.",
            "type": "string",
            "enum": [
              "auto",
              "manual"
            ]
          },
          "payments": {
            "description": "Transfers made to the seller against this batch, as `SellerPayoutBatchPayment` objects. Covers both provider transfers and payments recorded through the manual-payment endpoint. Empty until a transfer is attempted; each entry carries its own `payment_status`, so a retried batch lists one entry per attempt.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SellerPayoutBatchPayment"
            }
          },
          "period_end": {
            "description": "End of the invoice eligibility window covered by this batch.",
            "type": "string",
            "format": "date-time"
          },
          "period_start": {
            "description": "Start of the invoice eligibility window covered by this batch.",
            "type": "string",
            "format": "date-time"
          },
          "remarks": {
            "type": [
              "string",
              "null"
            ]
          },
          "scheduled_at": {
            "description": "When the batch is scheduled to be transferred to the seller.",
            "type": "string",
            "format": "date-time"
          },
          "seller_id": {
            "type": "string"
          },
          "seller_name": {
            "type": "string",
            "readOnly": true
          },
          "status": {
            "description": "Batch lifecycle state. Batches move `created` → `scheduled` → `processing` → `processed` → `completed`; `on_hold`, `failed`, and `cancelled` are terminal until an admin acts.",
            "type": "string",
            "enum": [
              "created",
              "scheduled",
              "processing",
              "processed",
              "completed",
              "failed",
              "cancelled",
              "on_hold"
            ]
          },
          "to_be_paid": {
            "description": "Net amount payable to the seller: `total_invoice_amount` - `total_charges` + `credit_adjustments` - `debit_adjustments`. Decimal string.",
            "type": "string"
          },
          "total_charges": {
            "description": "Sum of marketplace charges deducted across all invoices in the batch, as a decimal string.",
            "type": "string"
          },
          "total_invoice_amount": {
            "description": "Sum of the batched invoice amounts, before charges and adjustments, as a decimal string.",
            "type": "string"
          },
          "total_loyalty_point_redeemed": {
            "description": "Sum of `loyalty_point_redeemed` across invoices in the batch, as a decimal string.",
            "type": "string"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutBatchAction": {
        "enum": [
          "cancel-batch",
          "hold-batch",
          "unhold-batch",
          "update-manual-payment",
          "manual-payment",
          "pay-early",
          "change-payment-option"
        ]
      },
      "SellerPayoutBatchActivity": {
        "title": "SellerPayoutBatchActivity",
        "description": "An audit entry recorded while a seller payout batch is processed, including the raw exchange with the payout provider.",
        "type": "object",
        "properties": {
          "batch_id": {
            "description": "ULID of the `SellerPayoutBatch` the event was recorded against.",
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "duration_ms": {
            "description": "Round-trip time of the provider call. `null` for events that make no outbound request.",
            "type": [
              "integer",
              "null"
            ]
          },
          "event": {
            "description": "Dot-namespaced event key, for example `payout_batch.gateway_unavailable`.",
            "type": "string"
          },
          "id": {
            "description": "Activity ULID.",
            "type": "string"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "reference_field": {
            "description": "Field on `reference_type` that `reference_id` matches, for example `id`.",
            "type": [
              "string",
              "null"
            ]
          },
          "reference_id": {
            "description": "Value identifying the record the event was raised against.",
            "type": [
              "string",
              "null"
            ]
          },
          "reference_type": {
            "description": "Record the event relates to, such as `seller_payout_batch`.",
            "type": [
              "string",
              "null"
            ]
          },
          "remarks": {
            "description": "Human-readable detail about the event, such as why a batch could not be processed.",
            "type": [
              "string",
              "null"
            ]
          },
          "request_endpoint": {
            "description": "Provider endpoint called. `null` for events that make no outbound request.",
            "type": [
              "string",
              "null"
            ]
          },
          "request_payload": {
            "description": "Body sent to the provider. `null` for events that make no outbound request.",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "response_body": {
            "description": "Body returned by the provider. `null` for events that make no outbound request.",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "response_code": {
            "description": "HTTP status returned by the provider. `null` for events that make no outbound request.",
            "type": [
              "integer",
              "null"
            ]
          },
          "response_headers": {
            "description": "Headers returned by the provider. `null` for events that make no outbound request.",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "timestamp": {
            "description": "When the event occurred. `created_at` is when the activity record was written.",
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutBatchCancel": {
        "title": "SellerPayoutBatchCancel",
        "type": "object",
        "required": [
          "reassign_batch"
        ],
        "properties": {
          "reassign_batch": {
            "description": "What happens to the invoices the cancelled batch was holding. When `true`, they are regrouped into a new payout batch straight away. When `false`, they return to the payout pool as `eligible` and wait for the next batch run.",
            "type": "boolean"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutBatchCreate": {
        "title": "SellerPayoutBatchCreate",
        "type": "object",
        "required": [
          "invoice_numbers"
        ],
        "properties": {
          "include_pending_adjustments": {
            "description": "When true, pending unlinked adjustments for the seller are included in the batch.",
            "type": "boolean",
            "default": true
          },
          "invoice_numbers": {
            "description": "Pending payout invoice numbers. All invoices must belong to the same seller.",
            "type": "array",
            "items": {
              "type": "string"
            },
            "minItems": 1
          },
          "remarks": {
            "type": "string"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutBatchDetail": {
        "title": "SellerPayoutBatchDetail",
        "description": "A `SellerPayoutBatch` expanded with the invoices it settles, the adjustments applied to it, and the actions currently available on it.",
        "type": "object",
        "properties": {
          "adjustments": {
            "description": "`SellerPayoutAdjustment` records applied to this batch. Their totals are reflected in `credit_adjustments` and `debit_adjustments`.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SellerPayoutAdjustment"
            }
          },
          "allowed_actions": {
            "description": "Actions currently available on this batch, derived from its `status` and `payment_option`. `cancel-batch` appears while the batch is `scheduled` or `on_hold`, `hold-batch` while it is `scheduled`, `unhold-batch` while it is `on_hold`, `update-manual-payment` (also returned as `manual-payment`) when `payment_option` is `manual` or a transfer has failed, `pay-early` to transfer a `scheduled` batch ahead of its `scheduled_at`, and `change-payment-option` to switch the batch between `auto` and `manual` settlement. Drive your batch UI from this list rather than deriving it from `status` yourself.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SellerPayoutBatchAction"
            }
          },
          "invoices": {
            "description": "`SellerPayoutInvoice` objects settled by this batch. Their amounts roll up into `total_invoice_amount` and `total_charges`.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SellerPayoutInvoice"
            }
          }
        },
        "allOf": [
          {
            "$ref": "#/components/schemas/SellerPayoutBatch"
          }
        ],
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutBatchManualPayment": {
        "title": "SellerPayoutBatchManualPayment",
        "description": "Details of an off-platform transfer made to a seller, recorded against a payout batch.",
        "type": "object",
        "required": [
          "payment_mode",
          "payment_method",
          "payment_gateway_reference_no"
        ],
        "properties": {
          "payment_mode": {
            "description": "How the transfer was made.\n\n- `bank-transfer` - paid directly from your bank account.\n\n- `payment-gateway` - paid through a payment gateway outside the platform.",
            "type": "string",
            "enum": [
              "bank-transfer",
              "payment-gateway"
            ]
          },
          "payment_method": {
            "description": "Instrument used for the transfer: `CC` (credit card), `DC` (debit card), `NEFT`, `RTGS`, `IMPS`, `UPI`, or `WALLET`.",
            "type": "string",
            "enum": [
              "CC",
              "DC",
              "NEFT",
              "RTGS",
              "IMPS",
              "UPI",
              "WALLET"
            ]
          },
          "payment_gateway_reference_no": {
            "description": "Reference number issued by the bank or gateway for the transfer, such as the NEFT UTR. Use it to reconcile the payout against the bank statement.",
            "type": "string"
          },
          "remarks": {
            "description": "Free-text note stored on the batch, for example the reason the payout was settled outside the platform.",
            "type": "string"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutBatchPayment": {
        "title": "SellerPayoutBatchPayment",
        "description": "Transfer recorded on a `SellerPayoutBatch`. Mirrors `OrderPayment`, with payout settlement field types.",
        "type": "object",
        "properties": {
          "transaction_type": {
            "enum": [
              "payment",
              "refund"
            ]
          },
          "request_number": {
            "type": "string"
          },
          "amount": {
            "description": "Transfer amount as a decimal string.",
            "type": "string"
          },
          "payment_status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "payment_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "payment_success_date": {
            "description": "When the transfer succeeded.",
            "type": [
              "string",
              "null"
            ]
          },
          "payment_reference_number": {
            "type": [
              "string",
              "null"
            ]
          },
          "payment_method": {
            "description": "Empty string when recorded without a method; null for refunds.",
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "Card",
              "Credit Card",
              "Debit Card",
              "Netbanking",
              "UPI",
              "Wallet",
              "Loyalty Point",
              "IMPS",
              "NEFT",
              "RTGS",
              "Cash",
              "NACH",
              "",
              null
            ]
          },
          "payment_mode": {
            "type": "string"
          },
          "icon_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "card_number": {
            "description": "Masked card number, e.g. ************1111. Card payments only.",
            "type": [
              "string",
              "null"
            ]
          },
          "card_type": {
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "Visa",
              "Master Card",
              "Rupay",
              null
            ]
          },
          "bank_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "bank_account_number": {
            "description": "Masked account number, e.g. ************1234.",
            "type": [
              "string",
              "null"
            ]
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutBatchUpdate": {
        "title": "SellerPayoutBatchUpdate",
        "type": "object",
        "required": [
          "payment_option"
        ],
        "properties": {
          "payment_option": {
            "description": "How the batch should be settled. `auto` hands it to the connected payout provider; `manual` takes it out of automated processing so you can pay the seller outside the platform and record it with the manual-payment endpoint.",
            "type": "string",
            "enum": [
              "auto",
              "manual"
            ]
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutCharge": {
        "title": "SellerPayoutCharge",
        "type": "object",
        "properties": {
          "base_amount": {
            "description": "Amount the charge was calculated on, as a decimal string.",
            "type": "string"
          },
          "charge_amount": {
            "description": "Deduction amount, as a decimal string.",
            "type": "string"
          },
          "charge_basis": {
            "type": "string",
            "enum": [
              "percent",
              "fixed",
              "percent_plus_fixed"
            ]
          },
          "charge_fixed_amount": {
            "description": "Fixed component of the charge, as a decimal string.",
            "type": "string"
          },
          "charge_percent": {
            "description": "Percent component of the charge, as a decimal string.",
            "type": "string"
          },
          "charge_type": {
            "description": "Nature of the deduction. `commission` is the marketplace fee, `tcs` and `tds` are statutory withholdings derived from the seller payout config, and `other` covers manually created charges.",
            "type": "string",
            "enum": [
              "commission",
              "tcs",
              "tds",
              "other"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "remarks": {
            "type": [
              "string",
              "null"
            ]
          },
          "tax_amount": {
            "description": "Tax on the charge, as a decimal string.",
            "type": "string"
          },
          "tax_rate": {
            "description": "Tax rate applied to the charge, as a decimal string.",
            "type": "string"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutChargeCreate": {
        "title": "SellerPayoutChargeCreate",
        "type": "object",
        "required": [
          "charge_basis",
          "charge_type",
          "invoice_number",
          "seller_id"
        ],
        "properties": {
          "charge_basis": {
            "type": "string",
            "enum": [
              "percent",
              "fixed",
              "percent_plus_fixed"
            ]
          },
          "charge_fixed_amount": {
            "description": "Required to be greater than 0 when charge_basis is fixed or percent_plus_fixed.",
            "type": "number",
            "default": 0
          },
          "charge_percent": {
            "description": "Required to be greater than 0 when charge_basis is percent or percent_plus_fixed.",
            "type": "number",
            "default": 0
          },
          "charge_type": {
            "type": "string",
            "enum": [
              "commission",
              "other"
            ]
          },
          "invoice_number": {
            "description": "Pending payout invoice number in the current store.",
            "type": "string"
          },
          "remarks": {
            "type": "string",
            "default": ""
          },
          "seller_id": {
            "description": "Seller ID must exist in the marketplace seller cache and match the payout invoice.",
            "type": "string"
          },
          "tax_rate": {
            "type": "number"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutConfig": {
        "title": "SellerPayoutConfig",
        "type": "object",
        "properties": {
          "seller_id": {
            "type": "string"
          },
          "seller_details": {
            "$ref": "#/components/schemas/SellerInfo"
          },
          "commission_fixed_amount": {
            "type": "number"
          },
          "commission_percent": {
            "type": "number",
            "maximum": 100,
            "minimum": 0
          },
          "commission_type": {
            "type": "string",
            "enum": [
              "percent",
              "fixed",
              "percent_plus_fixed"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "hold_period_days": {
            "type": "integer"
          },
          "include_shipping_in_payout": {
            "type": "boolean"
          },
          "include_tax_in_payout": {
            "type": "boolean"
          },
          "tcs_percent": {
            "type": "number"
          },
          "tds_percent": {
            "type": "number"
          },
          "minimum_payout_amount": {
            "type": "number"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "store_id": {
            "type": "string"
          },
          "ulid": {
            "type": "string"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutConfigRequest": {
        "title": "SellerPayoutConfigRequest",
        "type": "object",
        "required": [
          "seller_id",
          "commission_fixed_amount",
          "commission_percent",
          "commission_type",
          "hold_period_days",
          "include_shipping_in_payout",
          "include_tax_in_payout",
          "minimum_payout_amount"
        ],
        "properties": {
          "seller_id": {
            "description": "Seller ID for which the payout config is being created.",
            "type": "string"
          },
          "commission_fixed_amount": {
            "description": "Required to be greater than 0 when commission_type is fixed or percent_plus_fixed.",
            "type": "number"
          },
          "commission_percent": {
            "description": "Required to be greater than 0 when commission_type is percent or percent_plus_fixed.",
            "type": "number"
          },
          "commission_type": {
            "type": "string",
            "enum": [
              "percent",
              "fixed",
              "percent_plus_fixed"
            ]
          },
          "hold_period_days": {
            "type": "integer"
          },
          "include_shipping_in_payout": {
            "type": "boolean"
          },
          "include_tax_in_payout": {
            "type": "boolean"
          },
          "minimum_payout_amount": {
            "type": "number"
          },
          "tds_percent": {
            "type": "number"
          },
          "tcs_percent": {
            "type": "number"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutInvoice": {
        "title": "SellerPayoutInvoice",
        "description": "A seller invoice tracked through the payout pipeline, from eligibility to settlement in a payout batch.",
        "type": "object",
        "properties": {
          "batch_assigned_at": {
            "description": "When the invoice was pulled into a payout batch. `null` until then.",
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "charges": {
            "description": "`SellerPayoutCharge` records deducted from this invoice, such as `commission`, `tcs`, and `tds`. Their total is `marketplace_charges`.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SellerPayoutCharge"
            }
          },
          "coupon_discount_amount": {
            "description": "Coupon discount deducted from the invoice total.",
            "type": "number"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "grand_total": {
            "description": "Invoice total payable by the customer, after discounts, tax, and shipping. Basis for the payable amount.",
            "type": "number"
          },
          "id": {
            "description": "Payout invoice ULID.",
            "type": "string"
          },
          "invoice_date": {
            "type": "string",
            "format": "date-time"
          },
          "invoice_id": {
            "description": "Underlying invoice database identifier.",
            "type": "integer"
          },
          "invoice_number": {
            "type": "string"
          },
          "loyalty_point_redeemed": {
            "description": "Value of loyalty points redeemed against the invoice.",
            "type": "number"
          },
          "marketplace_detail": {
            "description": "Marketplace context for this payout invoice. Returned as `null` when not applicable.",
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "marketplace_charges": {
            "description": "Commission and other marketplace charges deducted from this invoice, as a decimal string.",
            "type": "string"
          },
          "marketplace_charges_tax_amount": {
            "description": "Tax levied on `marketplace_charges`, as a decimal string.",
            "type": "string"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          },
          "order_id": {
            "type": "integer"
          },
          "order_number": {
            "type": "string"
          },
          "payout_batch_id": {
            "description": "Linked payout batch ULID. `null` while the invoice is unbatched.",
            "type": [
              "string",
              "null"
            ]
          },
          "payout_eligible_at": {
            "description": "Date the invoice becomes payable, derived from the seller's configured `hold_period_days`.",
            "type": "string",
            "format": "date"
          },
          "promotion_discount_amount": {
            "description": "Promotion discount deducted from the invoice total.",
            "type": "number"
          },
          "seller_id": {
            "type": "string"
          },
          "seller_name": {
            "type": "string",
            "readOnly": true
          },
          "shipment_id": {
            "type": [
              "integer",
              "null"
            ]
          },
          "shipment_reference_no": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_amount": {
            "description": "Shipping charged on the invoice, excluding tax.",
            "type": "number"
          },
          "shipping_amount_including_tax": {
            "description": "Shipping charged on the invoice, including tax. Counted towards the payout only when the seller's `include_shipping_in_payout` is `true`.",
            "type": "number"
          },
          "status": {
            "$ref": "#/components/schemas/SellerPayoutInvoiceStatus"
          },
          "sub_total": {
            "description": "Item total before tax, discounts, and shipping.",
            "type": "number"
          },
          "sub_total_including_tax": {
            "description": "Item total including tax. Counted towards the payout without tax when the seller's `include_tax_in_payout` is `false`.",
            "type": "number"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutInvoiceHoldRequest": {
        "title": "SellerPayoutInvoiceHoldRequest",
        "type": "object",
        "required": [
          "invoice_numbers",
          "seller_id"
        ],
        "properties": {
          "invoice_numbers": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "minItems": 1
          },
          "seller_id": {
            "description": "Seller ID must exist in the marketplace seller cache. Every invoice in invoice_numbers must belong to this seller.",
            "type": "string"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutInvoiceHoldSummary": {
        "title": "SellerPayoutInvoiceHoldSummary",
        "type": "object",
        "properties": {
          "already_on_hold_invoice_numbers": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "batches_deleted": {
            "description": "Batch numbers deleted after rebalancing.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "batches_updated": {
            "description": "Batch numbers updated after rebalancing.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "held_invoice_numbers": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutInvoiceStatus": {
        "title": "SellerPayoutInvoiceStatus",
        "description": "Payout state of an invoice. Invoices move `pending` → `eligible` → `batched` → `paid`. `on_hold` invoices are skipped by batching until released.",
        "type": "string",
        "enum": [
          "pending",
          "eligible",
          "batched",
          "paid",
          "on_hold",
          "cancelled"
        ]
      },
      "SellerPayoutInvoiceUnholdRequest": {
        "title": "SellerPayoutInvoiceUnholdRequest",
        "type": "object",
        "required": [
          "invoice_numbers",
          "seller_id"
        ],
        "properties": {
          "invoice_numbers": {
            "description": "Held payout invoice numbers to move back to pending.",
            "type": "array",
            "items": {
              "type": "string"
            },
            "minItems": 1
          },
          "seller_id": {
            "description": "Seller ID must exist in the marketplace seller cache. Every invoice in invoice_numbers must belong to this seller.",
            "type": "string"
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutInvoiceUnholdSummary": {
        "title": "SellerPayoutInvoiceUnholdSummary",
        "type": "object",
        "properties": {
          "unheld_invoice_numbers": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "x-tags": [
          "Payouts"
        ]
      },
      "SellerPayoutStats": {
        "title": "SellerPayoutStats",
        "description": "Seller payout amounts and invoice volumes aggregated by payout state.",
        "type": "object",
        "properties": {
          "deductions": {
            "description": "Marketplace charges, their tax, and debit adjustments withheld from the payable amount.",
            "type": "number"
          },
          "on_hold_amount": {
            "description": "Payable amount on invoices held back from batching.",
            "type": "number"
          },
          "outstanding_amount": {
            "description": "Payout-eligible amount not yet assigned to a batch.",
            "type": "number"
          },
          "scheduled_amount": {
            "description": "Amount in batches scheduled for transfer but not yet paid out.",
            "type": "number"
          },
          "total_count": {
            "description": "Number of payout invoices counted in the period.",
            "type": "integer"
          },
          "total_orders": {
            "description": "Number of distinct orders behind those payout invoices.",
            "type": "integer"
          },
          "total_payout": {
            "description": "Total payout amount recorded for the period.",
            "type": "number"
          },
          "transferred_amount": {
            "description": "Amount already transferred to sellers.",
            "type": "number"
          }
        },
        "x-tags": [
          "Metrics"
        ]
      },
      "Seo": {
        "title": "Seo",
        "type": "object",
        "required": [
          "title",
          "description",
          "keywords"
        ],
        "properties": {
          "title": {
            "type": [
              "string",
              "null"
            ]
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "keywords": {
            "type": [
              "array",
              "null"
            ]
          }
        }
      },
      "ServiceProvider": {
        "title": "ServiceProvider",
        "description": "Third-party service integration returned from store service-provider APIs. Combines catalog metadata, connection state, and type-specific fields (for example shipping `warehouses` and `shipping_zone`).",
        "allOf": [
          {
            "$ref": "#/components/schemas/StoreConfigServiceProvider"
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "ServiceProviderType": {
        "title": "ServiceProviderType",
        "description": "The type of third-party service integration.",
        "type": "string",
        "enum": [
          "shipping",
          "payment",
          "chat",
          "cms",
          "analytics"
        ]
      },
      "Shipment": {
        "title": "Shipment",
        "description": "Shipment on an order. Shape depends on store type: `ShipmentStandard` for B2B/B2C, `ShipmentMarketplace` when marketplace fields are present.",
        "oneOf": [
          {
            "$ref": "#/components/schemas/ShipmentStandard"
          },
          {
            "$ref": "#/components/schemas/ShipmentMarketplace"
          }
        ],
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentAction": {
        "enum": [
          "create-shipment",
          "download-invoice",
          "download-shipping-label",
          "inventory-check",
          "return-replace",
          "update-manual",
          "update-shipment",
          "cancel-shipment",
          "cancel-and-refund-shipment",
          "replace-shipment",
          "approve-shipment",
          "reject-shipment"
        ]
      },
      "ShipmentActivity": {
        "title": "ShipmentActivity",
        "type": "object",
        "required": [
          "activity_type",
          "comment",
          "status",
          "user_type",
          "user_name",
          "details",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "activity_type": {
            "type": "string"
          },
          "comment": {
            "type": "string"
          },
          "status": {
            "enum": [
              "success",
              "failed"
            ]
          },
          "user_type": {
            "type": "string"
          },
          "user_name": {
            "type": "string"
          },
          "details": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "ShipmentBox": {
        "title": "ShipmentBox",
        "type": "object",
        "properties": {
          "box_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "max_weight": {
            "type": [
              "number",
              "null"
            ]
          },
          "used_space": {
            "type": [
              "number",
              "null"
            ]
          },
          "box_name": {
            "type": "string"
          },
          "box_length": {
            "type": "number"
          },
          "box_width": {
            "type": "number"
          },
          "box_height": {
            "type": "number"
          },
          "box_weight": {
            "type": "number"
          },
          "items_count": {
            "type": [
              "integer",
              "null"
            ]
          },
          "box_count": {
            "type": [
              "integer",
              "null"
            ]
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentBulkUpdate": {
        "title": "ShipmentBulkUpdate",
        "type": "array",
        "items": {
          "type": "object",
          "required": [
            "shipment_number",
            "status"
          ],
          "properties": {
            "shipment_number": {
              "type": "string"
            },
            "status": {
              "enum": [
                "shipped",
                "in_transit",
                "out_for_delivery",
                "delivered",
                "return_to_origin",
                "lost"
              ]
            },
            "shipped_date": {
              "description": "required if shipped_date is not updated yet for this shipment.",
              "type": "string",
              "format": "date-time"
            },
            "out_for_delivery_date": {
              "description": "required if status is out_for_delivery.",
              "type": "string",
              "format": "date-time"
            },
            "delivered_date": {
              "description": "required if status is delivered.",
              "type": "string",
              "format": "date-time"
            },
            "returned_date": {
              "description": "required if status is return_to_origin.",
              "type": "string",
              "format": "date-time"
            },
            "awb_no": {
              "type": "string"
            },
            "courier_company_name": {
              "type": "string"
            },
            "shipping_label_url": {
              "type": "string"
            }
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentDetail": {
        "title": "ShipmentDetail",
        "type": "object",
        "required": [
          "order_number",
          "order_date",
          "order_status",
          "sales_channel",
          "payment_status",
          "shipment_detail",
          "allowed_actions"
        ],
        "properties": {
          "order_number": {
            "type": "string"
          },
          "order_date": {
            "type": "string",
            "format": "date-time"
          },
          "order_status": {
            "$ref": "#/components/schemas/OrderStatus"
          },
          "sales_channel": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name",
              "type"
            ]
          },
          "payment_status": {
            "$ref": "#/components/schemas/PaymentStatus"
          },
          "customer_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "billing_business_name": {
            "description": "Business name on the billing address. `null` for B2C orders placed without business details.",
            "type": [
              "string",
              "null"
            ]
          },
          "shipment_detail": {
            "$ref": "#/components/schemas/Shipment"
          },
          "allowed_actions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentAction"
            }
          },
          "customer_id": {
            "type": "string"
          },
          "sales_channel_type": {
            "description": "Type of the sales channel, repeated flat alongside `sales_channel`.",
            "type": "string"
          }
        }
      },
      "ShipmentInfo": {
        "title": "ShipmentInfo",
        "type": "object",
        "required": [
          "order_number",
          "order_status",
          "shipment_number",
          "warehouse_id",
          "warehouse_name",
          "status",
          "total_weight",
          "total_boxes",
          "shipment_items_count",
          "shipping_estimated_cost",
          "shipping_discount_amount",
          "shipping_amount",
          "shipping_tax_rate",
          "shipping_tax_amount",
          "shipping_amount_including_tax",
          "shipping_provider_id",
          "shipping_provider_name",
          "courier_company_id",
          "courier_company_name",
          "courier_company_image_url",
          "awb_no",
          "shipping_label_url",
          "eta_delivery",
          "estimated_delivery_date",
          "promised_delivery_date",
          "shipped_date",
          "delivered_date",
          "returned_date",
          "fulfillment_type",
          "slo",
          "cancellation_reason",
          "customer_id",
          "customer_name",
          "shipping_address_line1",
          "shipping_address_line2",
          "shipping_landmark",
          "shipping_pincode",
          "shipping_city",
          "shipping_state",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "order_number": {
            "type": "string"
          },
          "order_status": {
            "$ref": "#/components/schemas/OrderStatus"
          },
          "shipment_number": {
            "type": "string"
          },
          "warehouse_id": {
            "type": "string"
          },
          "warehouse_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "$ref": "#/components/schemas/ShipmentStatus"
          },
          "total_weight": {
            "type": "number"
          },
          "total_boxes": {
            "type": [
              "integer",
              "null"
            ]
          },
          "shipment_items_count": {
            "type": "integer"
          },
          "shipping_estimated_cost": {
            "type": "number",
            "format": "double"
          },
          "shipping_discount_amount": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount": {
            "type": "number",
            "format": "double"
          },
          "shipping_tax_rate": {
            "type": "number",
            "format": "double"
          },
          "shipping_tax_amount": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount_including_tax": {
            "type": "number",
            "format": "double"
          },
          "shipping_provider_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_provider_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "courier_company_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "courier_company_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "courier_company_image_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "awb_no": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_label_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "eta_delivery": {
            "type": [
              "string",
              "null"
            ]
          },
          "estimated_delivery_date": {
            "type": [
              "string",
              "null"
            ]
          },
          "promised_delivery_date": {
            "type": [
              "string",
              "null"
            ]
          },
          "out_for_delivery_date": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipped_date": {
            "type": [
              "string",
              "null"
            ]
          },
          "delivered_date": {
            "type": [
              "string",
              "null"
            ]
          },
          "returned_date": {
            "type": [
              "string",
              "null"
            ]
          },
          "fulfillment_type": {
            "enum": [
              "delivery",
              "collect-in-store"
            ]
          },
          "slo": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "expected_date": {
                "type": "string",
                "format": "datetime"
              },
              "actual_date": {
                "type": "string",
                "format": "datetime"
              },
              "difference": {
                "type": "number"
              },
              "slo_status": {
                "enum": [
                  "on-time",
                  "delay",
                  "early"
                ]
              }
            }
          },
          "cancellation_reason": {
            "type": [
              "string",
              "null"
            ]
          },
          "customer_id": {
            "type": "string"
          },
          "customer_name": {
            "type": "string"
          },
          "billing_business_name": {
            "description": "Business name on the billing address. `null` for B2C orders placed without business details.",
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_address_line1": {
            "type": "string"
          },
          "shipping_address_line2": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_landmark": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_pincode": {
            "type": "string"
          },
          "shipping_city": {
            "type": "string"
          },
          "shipping_state": {
            "type": "string"
          },
          "created_at": {
            "type": "string"
          },
          "modified_at": {
            "type": "string"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentItem": {
        "title": "ShipmentItem",
        "description": "Shipment item model",
        "type": "object",
        "required": [
          "product_id",
          "variant_id",
          "quantity"
        ],
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string",
            "readOnly": true
          },
          "variant_id": {
            "description": "`null` for products without variants.",
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "product_image_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "sku": {
            "type": "string",
            "readOnly": true
          },
          "quantity": {
            "type": "integer"
          },
          "is_free_item": {
            "type": "boolean"
          },
          "free_quantity": {
            "type": "integer"
          },
          "selling_price": {
            "type": "number",
            "format": "double"
          },
          "seller_detail": {
            "description": "Seller detail information. This field is relevant for marketplace type stores only. Will return null for b2b and b2c type stores.",
            "oneOf": [
              {
                "$ref": "#/components/schemas/SellerBasicDetail"
              },
              {
                "type": "null"
              }
            ]
          }
        }
      },
      "ShipmentItemStandard": {
        "title": "ShipmentItemStandard",
        "description": "Line item on a shipment for B2B/B2C stores (no marketplace seller metadata).",
        "type": "object",
        "required": [
          "product_id",
          "variant_id",
          "quantity"
        ],
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string",
            "readOnly": true
          },
          "variant_id": {
            "description": "`null` for products without variants.",
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "product_image_url": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "sku": {
            "type": "string",
            "readOnly": true
          },
          "quantity": {
            "type": "integer"
          },
          "is_free_item": {
            "type": "boolean"
          },
          "free_quantity": {
            "type": "integer"
          },
          "seller_detail": {
            "type": [
              "object",
              "null"
            ]
          },
          "selling_price": {
            "type": "number",
            "format": "double"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentList": {
        "title": "ShipmentList",
        "allOf": [
          {
            "type": "object",
            "properties": {
              "order_number": {
                "type": "string"
              },
              "sales_channel": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "name": {
                    "type": "string"
                  },
                  "type": {
                    "type": "string"
                  }
                }
              },
              "reference_number": {
                "type": "string"
              },
              "sub_total": {
                "type": "number",
                "format": "double"
              },
              "sub_total_including_tax": {
                "type": "number",
                "format": "double"
              },
              "grand_total": {
                "type": "number",
                "format": "double"
              },
              "coupon_discount_amount": {
                "type": "number",
                "format": "double"
              },
              "promotion_discount_amount": {
                "type": "number",
                "format": "double"
              },
              "loyalty_point_redeemed": {
                "type": "number",
                "format": "double"
              },
              "seller_id": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "marketplace_listing": {
                "type": "array"
              },
              "packing": {
                "description": "Per-box packing summary. Empty until packing is assigned.",
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ShipmentBox"
                }
              }
            }
          },
          {
            "$ref": "#/components/schemas/ShipmentInfo"
          }
        ],
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentMarketplace": {
        "title": "ShipmentMarketplace",
        "description": "Shipment payload for marketplace stores, including seller and order amount breakdown fields.",
        "allOf": [
          {
            "$ref": "#/components/schemas/ShipmentInfo"
          },
          {
            "type": "object",
            "properties": {
              "shipment_items": {
                "type": "array",
                "items": {
                  "oneOf": [
                    {
                      "$ref": "#/components/schemas/ShipmentItem"
                    },
                    {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/ShipmentItem"
                        },
                        {
                          "type": "object",
                          "properties": {
                            "is_free_item": {
                              "type": "boolean",
                              "readOnly": true
                            },
                            "selling_price_excluding_tax": {
                              "type": "number",
                              "format": "double",
                              "readOnly": true
                            }
                          },
                          "required": [
                            "is_free_item"
                          ]
                        }
                      ]
                    }
                  ]
                }
              }
            }
          },
          {
            "$ref": "#/components/schemas/ShipmentMarketplaceFields"
          },
          {
            "$ref": "#/components/schemas/ShipmentPackingAndProgression"
          }
        ],
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentMarketplaceFields": {
        "title": "ShipmentMarketplaceFields",
        "description": "Shipment fields returned for marketplace stores only.",
        "type": "object",
        "properties": {
          "reference_number": {
            "type": "string"
          },
          "sub_total": {
            "type": "number",
            "format": "double"
          },
          "sub_total_including_tax": {
            "type": "number",
            "format": "double"
          },
          "grand_total": {
            "type": "number",
            "format": "double"
          },
          "coupon_discount_amount": {
            "type": "number",
            "format": "double"
          },
          "promotion_discount_amount": {
            "type": "number",
            "format": "double"
          },
          "loyalty_point_redeemed": {
            "type": "number",
            "format": "double"
          },
          "seller_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "seller_detail": {
            "type": [
              "object",
              "null"
            ]
          },
          "marketplace_listing": {
            "type": "array"
          },
          "sales_channel": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name",
              "type"
            ]
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentPackingAndProgression": {
        "title": "ShipmentPackingAndProgression",
        "type": "object",
        "properties": {
          "packing": {
            "description": "Per-box packing summary. Empty until packing is assigned.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentBox"
            }
          },
          "progression": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShipmentProgression"
            }
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentProgression": {
        "title": "ShipmentProgression",
        "type": "object",
        "properties": {
          "status": {
            "$ref": "#/components/schemas/ShipmentProgressionStatus"
          },
          "is_current": {
            "type": "boolean",
            "readOnly": true
          },
          "is_completed": {
            "type": "boolean",
            "readOnly": true
          },
          "completion_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentProgressionStatus": {
        "title": "ShipmentProgressionStatus",
        "description": "Milestone on a shipment's fixed four-step progression ladder. Display labels, not `ShipmentStatus` values: every shipment carries all four in this order, and `is_completed` / `is_current` say where it has reached.",
        "type": "string",
        "enum": [
          "Created",
          "Packed",
          "Shipped",
          "Delivered"
        ],
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentStandard": {
        "title": "ShipmentStandard",
        "description": "Shipment payload for B2B/B2C stores without marketplace-only fields.",
        "allOf": [
          {
            "$ref": "#/components/schemas/ShipmentInfo"
          },
          {
            "type": "object",
            "properties": {
              "shipment_items": {
                "type": "array",
                "items": {
                  "oneOf": [
                    {
                      "$ref": "#/components/schemas/ShipmentItemStandard"
                    },
                    {
                      "allOf": [
                        {
                          "$ref": "#/components/schemas/ShipmentItemStandard"
                        },
                        {
                          "type": "object",
                          "properties": {
                            "is_free_item": {
                              "type": "boolean",
                              "readOnly": true
                            },
                            "selling_price_excluding_tax": {
                              "type": "number",
                              "format": "double",
                              "readOnly": true
                            }
                          },
                          "required": [
                            "is_free_item"
                          ]
                        }
                      ]
                    }
                  ]
                }
              }
            }
          },
          {
            "$ref": "#/components/schemas/ShipmentPackingAndProgression"
          }
        ],
        "x-tags": [
          "Shipping"
        ]
      },
      "ShipmentStatus": {
        "enum": [
          "unscheduled",
          "schedule_requested",
          "scheduled",
          "packed",
          "created",
          "shipped",
          "in_transit",
          "out_for_delivery",
          "delivery_attempted",
          "undelivered",
          "return_to_origin",
          "delivered",
          "cancelled",
          "lost",
          "sent_to_store",
          "processing",
          "ready_to_collect",
          "store_rejected"
        ]
      },
      "ShipperBox": {
        "title": "ShipperBox",
        "type": "object",
        "required": [
          "id",
          "name",
          "length",
          "width",
          "height",
          "dry_weight",
          "units_per_shipper"
        ],
        "properties": {
          "id": {
            "description": "product/variant id",
            "type": "string"
          },
          "name": {
            "description": "product - variant name",
            "type": "string"
          },
          "length": {
            "description": "in cm",
            "type": "integer"
          },
          "width": {
            "description": "in cm",
            "type": "integer"
          },
          "height": {
            "description": "in cm",
            "type": "integer"
          },
          "dry_weight": {
            "description": "in kilo gram",
            "type": "number"
          },
          "units_per_shipper": {
            "type": "integer"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "ShippingConfig": {
        "title": "ShippingConfig",
        "type": "object",
        "properties": {
          "packaging_optimisation_logic": {
            "description": "- cost - the lowest cost of shipment\n- bins_utilization - max. utilization inside packing spaces\n- bins_number - the smallest possible number of packing spaces",
            "enum": [
              "cost",
              "bins_utilization",
              "bins_number"
            ]
          },
          "location_priority": {
            "enum": [
              "manual",
              "distance",
              "inventory"
            ]
          },
          "warehouse_id": {
            "description": "optional. required only if location_priority = manual. Value should be array of warehouses ids.",
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            }
          },
          "approval_option": {
            "default": "auto",
            "enum": [
              "auto",
              "manual"
            ]
          },
          "shipping_option": {
            "description": "Omitted when shipping is not configured for the store.",
            "enum": [
              "auto",
              "manual"
            ]
          },
          "default_weight": {
            "description": "Specifies the default weight (in kilograms) used to calculate shipping costs when product packing details are missing. This value ensures that shipping estimates can still be generated in the absence of product packing information.",
            "type": "number"
          }
        },
        "additionalProperties": true,
        "x-tags": [
          "Store"
        ]
      },
      "ShippingCostAction": {
        "title": "ShippingCostAction",
        "oneOf": [
          {
            "$ref": "#/components/schemas/FreeAction"
          },
          {
            "$ref": "#/components/schemas/FixedChargeAction"
          },
          {
            "$ref": "#/components/schemas/DiscountAction"
          },
          {
            "$ref": "#/components/schemas/DynamicAction"
          }
        ]
      },
      "ShippingCostCondition": {
        "title": "ShippingCostCondition",
        "type": "object",
        "oneOf": [
          {
            "additionalProperties": false,
            "title": "Order Total",
            "required": [
              "order_total"
            ],
            "properties": {
              "order_total": {
                "$ref": "#/components/schemas/Comparison"
              }
            }
          },
          {
            "additionalProperties": false,
            "title": "Shipping Mode",
            "required": [
              "shipping_mode"
            ],
            "properties": {
              "shipping_mode": {
                "description": "e.g. [\"air\",\"surface\"]",
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            }
          },
          {
            "additionalProperties": false,
            "title": "Shipping Providers",
            "required": [
              "providers"
            ],
            "properties": {
              "providers": {
                "description": "e.g. [\"dhl\",\"fedex\"]",
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            }
          }
        ]
      },
      "ShippingCostPolicy": {
        "title": "ShippingCostPolicy",
        "type": "object",
        "required": [
          "rules",
          "default_action"
        ],
        "properties": {
          "rules": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShippingRule"
            }
          },
          "default_action": {
            "$ref": "#/components/schemas/ShippingCostAction"
          }
        },
        "additionalProperties": false
      },
      "ShippingOption": {
        "title": "ShippingOption",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_connected": {
            "type": "boolean"
          },
          "is_forward_shipping": {
            "type": "boolean"
          },
          "is_return_shipping": {
            "type": "boolean"
          },
          "logo_dark": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_light": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo": {
            "description": "Primary logo URL for display. Same as `logo_light` for most providers.",
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "fulfillment_type": {
            "enum": [
              "delivery",
              "collect-in-store"
            ],
            "readOnly": true
          },
          "sort_order": {
            "type": "integer",
            "readOnly": true
          },
          "type": {
            "enum": [
              "auto",
              "manual"
            ]
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ]
          }
        }
      },
      "ShippingRateBasedOnItemWeight": {
        "title": "ShippingRateBasedOnItemWeight",
        "description": "",
        "anyOf": [
          {
            "$ref": "#/components/schemas/ShippingRateBasedOnWeightSlabs"
          },
          {
            "$ref": "#/components/schemas/ShippingRatePerKgFixedPrice"
          }
        ],
        "x-tags": [
          "Shipping"
        ]
      },
      "ShippingRateBasedOnOrderValue": {
        "title": "ShippingRateBasedOnOrderValue",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "rate_based_on",
          "slabs"
        ],
        "properties": {
          "rate_based_on": {
            "enum": [
              "order-value"
            ]
          },
          "slabs": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "order_value",
                "shipping_rate",
                "condition"
              ],
              "properties": {
                "order_value": {
                  "type": "number"
                },
                "shipping_rate": {
                  "type": "number"
                },
                "condition": {
                  "enum": [
                    "less-or-equal",
                    "greater"
                  ]
                }
              }
            }
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShippingRateBasedOnWeightSlabs": {
        "title": "ShippingRateBasedOnWeightSlabs",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "rate_based_on",
          "rate_type",
          "slabs"
        ],
        "properties": {
          "rate_based_on": {
            "enum": [
              "item-weight"
            ]
          },
          "rate_type": {
            "enum": [
              "weight-slabs"
            ]
          },
          "slabs": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "weight",
                "shipping_rate",
                "condition"
              ],
              "properties": {
                "weight": {
                  "type": "number"
                },
                "shipping_rate": {
                  "type": "number"
                },
                "condition": {
                  "enum": [
                    "less-or-equal",
                    "greater"
                  ]
                }
              }
            }
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShippingRatePerKgFixedPrice": {
        "title": "ShippingRatePerKgFixedPrice",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "rate_based_on",
          "rate_type",
          "shipping_rate_per_kg"
        ],
        "properties": {
          "rate_based_on": {
            "enum": [
              "item-weight"
            ]
          },
          "rate_type": {
            "enum": [
              "fixed-price-per-kg"
            ]
          },
          "shipping_rate_per_kg": {
            "type": "number"
          }
        },
        "x-tags": [
          "Shipping"
        ]
      },
      "ShippingRule": {
        "title": "ShippingRule",
        "type": "object",
        "required": [
          "condition",
          "action"
        ],
        "properties": {
          "condition": {
            "$ref": "#/components/schemas/ShippingCostCondition"
          },
          "action": {
            "$ref": "#/components/schemas/ShippingCostAction"
          }
        },
        "additionalProperties": false
      },
      "ShippingStats": {
        "title": "ShippingStats",
        "type": "object",
        "properties": {
          "to_be_shipped": {
            "type": "integer"
          },
          "in_transit": {
            "type": "integer"
          },
          "on_hold": {
            "type": "integer"
          },
          "delivered": {
            "type": "integer"
          },
          "late_delivered": {
            "type": "integer"
          },
          "returned_to_origin": {
            "type": "integer"
          }
        }
      },
      "ShippingZoneBasedShippingOption": {
        "title": "ShippingZoneBasedShippingOption",
        "type": "object",
        "required": [
          "based_on",
          "shipping_zone_id",
          "service_provider_id"
        ],
        "properties": {
          "based_on": {
            "type": "string",
            "const": "shipping-zone"
          },
          "shipping_zone_id": {
            "type": "string"
          },
          "service_provider_id": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "ShippingZoneDetail": {
        "title": "ShippingZoneDetail",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "countries": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Country"
            }
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "is_default": {
            "type": "boolean"
          },
          "available_shipping_options": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShippingOption"
            },
            "readOnly": true
          },
          "shipping_providers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShippingOption"
            },
            "readOnly": true
          },
          "manual_methods": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ShippingOption"
            },
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfig": {
        "title": "StoreConfig",
        "type": "object",
        "properties": {
          "is_kyc_enabled": {
            "type": "boolean",
            "default": false
          },
          "is_customer_group_enabled": {
            "type": "boolean",
            "default": false
          },
          "is_loyalty_program_enabled": {
            "type": "boolean",
            "default": false
          },
          "tax": {
            "$ref": "#/components/schemas/TaxConfig"
          },
          "shipping": {
            "$ref": "#/components/schemas/ShippingConfig"
          },
          "customer_groups": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CustomerGroup"
            },
            "readOnly": true
          },
          "kyc_documents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KycDocumentConfig"
            },
            "readOnly": true
          },
          "brand": {
            "$ref": "#/components/schemas/Brand"
          },
          "subscription": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/SubscriptionSetting"
              },
              {
                "type": "null"
              }
            ]
          },
          "general": {
            "$ref": "#/components/schemas/StoreGeneralConfig"
          },
          "currency": {
            "$ref": "#/components/schemas/Currency",
            "readOnly": true
          },
          "credit_line": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/CreditLineConfig"
              },
              {
                "type": "null"
              }
            ]
          },
          "payout": {
            "$ref": "#/components/schemas/PayoutConfig"
          },
          "warehouses": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/StoreConfigWarehouse"
            },
            "readOnly": true
          },
          "templates": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/StoreConfigTemplate"
            },
            "readOnly": true
          },
          "service_providers": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/StoreConfigServiceProvider"
            },
            "readOnly": true
          },
          "shipping_zones": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/StoreConfigShippingZone"
            },
            "readOnly": true
          },
          "manual_payment_methods": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ManualPaymentMethod"
            },
            "readOnly": true
          },
          "shipping_cost_policy": {
            "$ref": "#/components/schemas/ShippingCostPolicy"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfigSalesChannel": {
        "title": "StoreConfigSalesChannel",
        "description": "Sales channel summary embedded in `StoreConfig` warehouse listings.",
        "type": "object",
        "required": [
          "id",
          "name",
          "active"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string",
            "readOnly": true
          },
          "kind": {
            "type": "string",
            "enum": [
              "storefront",
              "marketplace"
            ]
          },
          "active": {
            "type": "boolean",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfigServiceProvider": {
        "title": "StoreConfigServiceProvider",
        "allOf": [
          {
            "$ref": "#/components/schemas/OtherServiceProvider"
          },
          {
            "type": "object",
            "properties": {
              "api_credentials": {
                "description": "Connected credential values. Keys match `required_credentials_params[].input_field_name`. Returned as `null`, or as an empty array `[]`, when the provider has no stored credentials.",
                "type": [
                  "object",
                  "array",
                  "null"
                ],
                "additionalProperties": true,
                "readOnly": true
              },
              "alias": {
                "type": "string"
              },
              "logo": {
                "description": "Primary logo URL. Same as `logo_light` for `auto` providers; `null` for `manual` methods.",
                "type": [
                  "string",
                  "null"
                ],
                "readOnly": true
              },
              "service_sub_type": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "used_in_credit_line": {
                "description": "`true` when the option is linked in the store credit-line payment method configuration.",
                "type": "boolean",
                "readOnly": true
              },
              "used_in_payout": {
                "description": "`true` when the option is linked in the store `payout` configuration.",
                "type": "boolean",
                "readOnly": true
              },
              "warehouses": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    }
                  }
                },
                "readOnly": true
              },
              "shipping_zone": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    }
                  }
                },
                "readOnly": true
              },
              "fulfillment_type": {
                "description": "Present on shipping providers.",
                "type": "string",
                "enum": [
                  "delivery"
                ],
                "readOnly": true
              },
              "type": {
                "description": "Present on shipping providers (`auto` fulfillment integrations).",
                "type": "string",
                "enum": [
                  "auto"
                ],
                "readOnly": true
              },
              "is_forward_shipping": {
                "type": "boolean",
                "default": false,
                "readOnly": true
              },
              "is_return_shipping": {
                "type": "boolean",
                "default": false,
                "readOnly": true
              }
            }
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfigShippingZone": {
        "title": "StoreConfigShippingZone",
        "allOf": [
          {
            "$ref": "#/components/schemas/ShippingZoneDetail"
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfigTemplate": {
        "title": "StoreConfigTemplate",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "template_type": {
            "enum": [
              "terms-of-service",
              "refund-policy",
              "email",
              "invoice",
              "web-layer",
              "whatsapp",
              "chat",
              "push-notification",
              "webhook"
            ]
          },
          "name": {
            "type": "string"
          },
          "activity": {
            "description": "example - signup, order-confirmation, order-cancelled, order-refunded, cart-abandoned, etc.",
            "type": [
              "string",
              "null"
            ]
          },
          "content_type": {
            "enum": [
              "html",
              "markdown",
              "plaintext"
            ]
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "content_title": {
            "description": "to be used in email subject or notification heading if provided.",
            "type": [
              "string",
              "null"
            ]
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfigWarehouse": {
        "title": "StoreConfigWarehouse",
        "allOf": [
          {
            "$ref": "#/components/schemas/WarehouseDetail"
          },
          {
            "type": "object",
            "properties": {
              "seller_id": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "marketplace_listing": {
                "type": "array"
              },
              "manual_methods": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/StoreConfigWarehouseManualMethod"
                },
                "readOnly": true
              },
              "channels": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/StoreConfigWarehouseSalesChannel"
                },
                "readOnly": true
              }
            }
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfigWarehouseManualMethod": {
        "title": "StoreConfigWarehouseManualMethod",
        "description": "Manual shipping method on a warehouse as returned in `StoreConfig`.",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_connected": {
            "type": "boolean"
          },
          "is_forward_shipping": {
            "type": "boolean"
          },
          "is_return_shipping": {
            "type": "boolean"
          },
          "logo_dark": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo_light": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "logo": {
            "type": [
              "string",
              "null"
            ],
            "readOnly": true
          },
          "fulfillment_type": {
            "enum": [
              "delivery",
              "collect-in-store"
            ],
            "readOnly": true
          },
          "sort_order": {
            "type": "integer",
            "readOnly": true
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ]
          },
          "shipping_method_type": {
            "enum": [
              "manual",
              "local-pickup"
            ]
          },
          "shipping_rate_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "shipping_rate_fixed_price": {
            "description": "`null` when `shipping_rate_condition` is set.",
            "type": [
              "number",
              "null"
            ]
          },
          "shipping_rate_condition": {
            "description": "`null` when `shipping_rate_fixed_price` is set.",
            "anyOf": [
              {
                "$ref": "#/components/schemas/ManualShippingRateCondition"
              },
              {
                "type": "null"
              }
            ]
          },
          "maximum_weight": {
            "description": "`null` when there is no weight limit.",
            "type": [
              "number",
              "null"
            ]
          },
          "delivery_leadtime_minimum": {
            "description": "In days.",
            "type": "integer"
          },
          "delivery_leadtime_maximum": {
            "description": "In days.",
            "type": "integer"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfigWarehouseSalesChannel": {
        "title": "StoreConfigWarehouseSalesChannel",
        "description": "Sales channel on a warehouse as returned in `StoreConfig`.",
        "allOf": [
          {
            "$ref": "#/components/schemas/StoreConfigSalesChannel"
          },
          {
            "type": "object",
            "properties": {
              "channel_type": {
                "description": "Observed values: `web`, `pos`, `internal`.",
                "type": "string"
              },
              "is_default": {
                "type": "boolean"
              },
              "domain": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "app_platform": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "external_id": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "pos_vendor": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "store_id": {
                "type": "string"
              },
              "store_name": {
                "type": "string"
              },
              "marketplace_id": {
                "description": "Set only when `kind` is `marketplace`.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "marketplace": {
                "description": "`null` unless `kind` is `marketplace`.",
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      },
                      "slug": {
                        "type": "string"
                      },
                      "marketplace_type": {
                        "type": "string"
                      },
                      "store_id": {
                        "description": "The marketplace operator's store.",
                        "type": "string"
                      },
                      "sync_products": {
                        "type": "boolean"
                      },
                      "sync_inventory": {
                        "type": "boolean"
                      },
                      "sync_orders": {
                        "type": "boolean"
                      },
                      "required_credentials_params": {
                        "type": [
                          "object",
                          "null"
                        ]
                      },
                      "created_at": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "modified_at": {
                        "type": "string",
                        "format": "date-time"
                      }
                    }
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "seller_account": {
                "description": "This store's seller account on the marketplace. `null` unless `kind` is `marketplace`.",
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/StoreConfigWarehouseSellerAccount"
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            }
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "StoreConfigWarehouseSellerAccount": {
        "title": "StoreConfigWarehouseSellerAccount",
        "description": "Seller account linked to a marketplace channel on a warehouse in `StoreConfig`.",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "trade_name": {
            "type": "string"
          },
          "legal_name": {
            "type": "string"
          },
          "business_type": {
            "$ref": "#/components/schemas/SellerBusinessType"
          },
          "tax_identification_number": {
            "type": "string"
          },
          "status": {
            "$ref": "#/components/schemas/SellerAccountStatus"
          },
          "kyc_status": {
            "$ref": "#/components/schemas/SellerKycStatus"
          },
          "logo": {
            "type": [
              "string",
              "null"
            ]
          },
          "marketplace_id": {
            "type": "string"
          },
          "marketplace_name": {
            "type": "string"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreGeneralConfig": {
        "title": "StoreGeneralConfig",
        "type": "object",
        "properties": {
          "order_number_prefix": {
            "description": "Prefix prepended to generated order numbers for identification or branding.",
            "type": "string",
            "maxLength": 4,
            "minLength": 2
          },
          "currency_code": {
            "description": "ISO 4217 currency code used for store prices and payments (e.g. INR, USD).",
            "type": "string",
            "maxLength": 3,
            "minLength": 3
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreShippingBox": {
        "title": "ShippingBox",
        "description": "",
        "type": "object",
        "required": [
          "name",
          "length",
          "width",
          "height",
          "empty_box_weight",
          "max_weight_box_can_carry",
          "empty_box_price"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "length": {
            "type": "number"
          },
          "width": {
            "type": "number"
          },
          "height": {
            "type": "number"
          },
          "empty_box_weight": {
            "type": "number"
          },
          "max_weight_box_can_carry": {
            "type": "number"
          },
          "empty_box_price": {
            "type": "number"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        }
      },
      "StoreShippingBoxDetail": {
        "title": "StoreShippingBoxDetail",
        "type": "object",
        "required": [
          "name",
          "length",
          "width",
          "height",
          "empty_box_weight",
          "max_weight_box_can_carry",
          "empty_box_price",
          "warehouse_id"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "length": {
            "type": "number"
          },
          "width": {
            "type": "number"
          },
          "height": {
            "type": "number"
          },
          "empty_box_weight": {
            "type": "number"
          },
          "max_weight_box_can_carry": {
            "type": "number"
          },
          "empty_box_price": {
            "type": "number"
          },
          "warehouse_id": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "writeOnly": true
          },
          "warehouses": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/WarehouseDetail"
            },
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreTemplate": {
        "title": "StoreTemplate",
        "type": "object",
        "required": [
          "name",
          "template_type",
          "content_type",
          "content"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "template_type": {
            "enum": [
              "terms-of-service",
              "refund-policy",
              "email",
              "invoice",
              "web-layer",
              "whatsapp",
              "chat",
              "push-notification",
              "webhook"
            ]
          },
          "activity": {
            "description": "example - signup, order-confirmation, order-cancelled, order-refunded, cart-abandoned, etc.",
            "type": [
              "string",
              "null"
            ]
          },
          "content_title": {
            "description": "to be used in email subject or notification heading if provided.",
            "type": [
              "string",
              "null"
            ]
          },
          "content_type": {
            "enum": [
              "html",
              "markdown",
              "plaintext"
            ]
          },
          "content": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StoreTemplateDetail": {
        "title": "StoreTemplateDetail",
        "type": "object",
        "required": [
          "name",
          "template_type",
          "content_type",
          "content"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "template_type": {
            "enum": [
              "terms-of-service",
              "refund-policy",
              "email",
              "invoice",
              "web-layer",
              "whatsapp",
              "chat",
              "push-notification",
              "webhook"
            ]
          },
          "activity": {
            "description": "example - signup, order-confirmation, order-cancelled, order-refunded, cart-abandoned, etc.",
            "type": [
              "string",
              "null"
            ]
          },
          "content_title": {
            "description": "to be used in email subject, notification heading if provided.",
            "type": [
              "string",
              "null"
            ]
          },
          "content_type": {
            "enum": [
              "html",
              "markdown",
              "plaintext"
            ]
          },
          "content": {
            "type": "string"
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "StringAttribute": {
        "title": "StringAttribute",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string",
            "readOnly": true
          },
          "is_linked": {
            "type": "boolean",
            "readOnly": true
          },
          "value": {
            "description": "`null` when no value is set for this customer.",
            "type": [
              "string",
              "null"
            ]
          },
          "attribute_type": {
            "enum": [
              "String"
            ]
          },
          "is_readonly": {
            "type": "boolean",
            "readOnly": true
          },
          "is_pinned": {
            "description": "Whether the attribute is pinned to the top of the customer profile.",
            "type": "boolean"
          },
          "active": {
            "type": "boolean"
          },
          "is_visible": {
            "type": "boolean"
          },
          "is_filterable": {
            "type": "boolean"
          },
          "last_updated_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "Subscription": {
        "title": "Subscription",
        "description": "Subscription model",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "subscription_number": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "sub_total": {
            "type": "number",
            "format": "double"
          },
          "shipping_amount": {
            "type": "number",
            "format": "double"
          },
          "total_tax": {
            "type": "number",
            "format": "double"
          },
          "net_amount": {
            "type": "number",
            "format": "double"
          },
          "billing_frequency": {
            "enum": [
              "Monthly",
              "Quarterly",
              "Half-yearly",
              "Yearly"
            ]
          },
          "billing_interval": {
            "type": "integer",
            "default": 1
          },
          "billing_limit": {
            "type": "integer",
            "default": 0
          },
          "fulfill_separately": {
            "type": "boolean"
          },
          "fulfillment_frequency": {
            "enum": [
              "Monthly",
              "Quarterly",
              "Half-yearly",
              "Yearly"
            ]
          },
          "fulfillment_interval": {
            "type": "integer",
            "default": 1
          },
          "fulfillment_limit": {
            "type": "integer",
            "default": 0
          },
          "billing_trial_days": {
            "type": "integer",
            "default": 0
          },
          "status": {
            "enum": [
              "draft",
              "active",
              "inactive"
            ]
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "SubscriptionCustomer": {
        "title": "SubscriptionCustomer",
        "description": "Subscription Customer model",
        "type": "object",
        "properties": {
          "customer_id": {
            "type": "string"
          },
          "customer_name": {
            "type": "string"
          },
          "customer_profile_image_url": {
            "type": "string"
          },
          "subscription_start_date": {
            "type": "string",
            "format": "date-time"
          },
          "subscription_end_date": {
            "type": "string",
            "format": "date-time"
          },
          "subscription_status": {
            "enum": [
              "active",
              "paused",
              "stopped",
              "cancelled"
            ]
          },
          "subscription_next_billing_date": {
            "type": "string",
            "format": "date-time"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "SubscriptionSetting": {
        "title": "SubscriptionSetting",
        "type": "object",
        "required": [
          "charge_automatically",
          "retry_and_dunning",
          "pause_during_trial",
          "pause_when_past_due",
          "pause_indefinitely",
          "skip_next_interval"
        ],
        "properties": {
          "charge_automatically": {
            "type": "boolean"
          },
          "retry_and_dunning": {
            "type": "boolean"
          },
          "retry_and_dunning_rules": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "object",
              "required": [
                "days",
                "retry_payment",
                "send_notification"
              ],
              "properties": {
                "days": {
                  "description": "days after first payment failure",
                  "type": "integer"
                },
                "retry_payment": {
                  "type": "boolean"
                },
                "send_notification": {
                  "type": "boolean"
                }
              }
            }
          },
          "retry_final_step_action": {
            "description": "send null value for no action.",
            "enum": [
              "mark-as-unpaid",
              "cancel-subscription"
            ]
          },
          "pause_during_trial": {
            "type": "boolean"
          },
          "pause_when_past_due": {
            "type": "boolean"
          },
          "pause_indefinitely": {
            "type": "boolean"
          },
          "skip_next_interval": {
            "type": "boolean"
          },
          "skip_next_interval_threshold": {
            "description": "days before next shipment. required if skip_next_interval = true",
            "type": "integer",
            "default": 0
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "SyncProductToMarketplace": {
        "title": "SyncProductToMarketplace",
        "description": "Schema for syncing products to marketplace. Can sync all products or specific products.",
        "oneOf": [
          {
            "$ref": "#/components/schemas/MarketplaceSyncAllProduct"
          },
          {
            "$ref": "#/components/schemas/MarketplaceSyncSpecificProduct"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "TaxConfig": {
        "title": "TaxConfig",
        "type": "object",
        "properties": {
          "tax_type": {
            "enum": [
              "GST"
            ]
          },
          "taxable_location": {
            "enum": [
              "shipping-address",
              "billing-address"
            ]
          },
          "is_product_price_include_tax": {
            "description": "This field indicates whether the product prices, handling charges already include applicable taxes.\n\n- If set to true, the product prices are inclusive of tax, meaning no additional tax will be added during checkout.\n\n- If set to false, taxes are excluded from the listed prices and will be calculated and added separately at checkout.",
            "type": "boolean"
          },
          "is_shipping_price_include_tax": {
            "description": "This field indicates whether the shipping prices already include applicable taxes.\n\n- If set to true, the shipping prices are inclusive of tax, meaning no additional tax will be added during checkout.\n\n- If set to false, taxes are excluded from the listed prices and will be calculated and added separately at checkout.",
            "type": "boolean"
          },
          "is_tax_apply_after_discount": {
            "type": "boolean"
          },
          "is_discount_apply_after_tax": {
            "type": "boolean"
          },
          "shipping_tax_rate": {
            "type": "number"
          },
          "handling_charge_tax_rate": {
            "description": "This represents the tax rate percentage applied specifically to handling charge in shipping. A handling charge is an additional fee applied to cover the costs associated with preparing, packaging, and processing an order for shipment or delivery.",
            "type": "number"
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "TieredDiscountCouponPromotion": {
        "title": "TieredDiscountCouponPromotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "details",
              "applies_to_product"
            ],
            "properties": {
              "details": {
                "$ref": "#/components/schemas/TieredDiscountRule"
              },
              "applies_to_product": {
                "enum": [
                  "all",
                  "product",
                  "category"
                ]
              }
            }
          }
        ]
      },
      "TieredDiscountRule": {
        "title": "TieredDiscountRule",
        "type": "object",
        "required": [
          "slabs",
          "maximum_discount_amount"
        ],
        "properties": {
          "slabs": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TieredDiscountSlab"
            }
          },
          "maximum_discount_amount": {
            "description": "Caps the discount across all slabs. Use `null` for no cap.",
            "type": [
              "number",
              "null"
            ]
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "TieredDiscountSlab": {
        "title": "TieredDiscountSlab",
        "oneOf": [
          {
            "$ref": "#/components/schemas/PercentageTieredDiscountSlab"
          },
          {
            "$ref": "#/components/schemas/FixedAmountTieredDiscountSlab"
          }
        ],
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "TopSellingProduct": {
        "title": "TopSellingProduct",
        "type": "object",
        "properties": {
          "product_id": {
            "type": "string"
          },
          "product_name": {
            "type": "string"
          },
          "product_image_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "sku": {
            "type": "string"
          },
          "product_variant_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "variant_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "quantity": {
            "type": "integer"
          },
          "free_quantity": {
            "type": "integer"
          },
          "order_count": {
            "type": "integer"
          },
          "seller_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "store_id": {
            "type": "string"
          },
          "customer_count": {
            "type": "integer"
          },
          "average_selling_price": {
            "type": "number"
          }
        }
      },
      "UpdateAttributeSet": {
        "title": "UpdateAttributeSet",
        "type": "object",
        "required": [
          "name",
          "attribute_id"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "attribute_id": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "UpdateBankAccount": {
        "title": "UpdateBankAccount",
        "discriminator": {
          "propertyName": "account_type",
          "mapping": {
            "outbound": "#/components/schemas/UpdateOutboundBankAccount",
            "inbound": "#/components/schemas/UpdateInboundBankAccount"
          }
        },
        "oneOf": [
          {
            "$ref": "#/components/schemas/UpdateOutboundBankAccount"
          },
          {
            "$ref": "#/components/schemas/UpdateInboundBankAccount"
          }
        ],
        "x-tags": [
          "Customers"
        ]
      },
      "UpdateBundleProduct": {
        "title": "UpdateBundleProduct",
        "allOf": [
          {
            "$ref": "#/components/schemas/ProductCommonDetail"
          },
          {
            "type": "object",
            "properties": {
              "description": {
                "description": "Array of category ids.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "categories": {
                "description": "Array of category ids.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "images": {
                "description": "Array of image file ids.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "videos": {
                "description": "Array of video file ids.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "pricing": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductPricing"
                }
              },
              "promotions": {
                "$ref": "#/components/schemas/ProductPromotion"
              },
              "subscriptions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductSubscription"
                }
              },
              "bundle_items": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "product_id",
                    "variant_id",
                    "quantity"
                  ],
                  "properties": {
                    "product_id": {
                      "type": "string"
                    },
                    "variant_id": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "quantity": {
                      "type": "integer"
                    }
                  }
                }
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "UpdateCustomer": {
        "title": "UpdateCustomer",
        "type": "object",
        "properties": {
          "first_name": {
            "type": "string"
          },
          "last_name": {
            "type": [
              "string",
              "null"
            ]
          },
          "phone": {
            "description": "10 digit phone number without country code.",
            "type": "string"
          },
          "email": {
            "type": "string"
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "profile_image_id": {
            "description": "file id of media gallery",
            "type": [
              "string",
              "null"
            ]
          },
          "customer_group_id": {
            "description": "Moves the customer to a different Customer Group, which drives group-specific pricing and promotions. Send `null` to fall back to the store's default group.",
            "type": [
              "string",
              "null"
            ]
          },
          "business": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "name": {
                "type": "string"
              },
              "business_type": {
                "$ref": "#/components/schemas/SellerBusinessType"
              },
              "gstin": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "name",
              "business_type"
            ]
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "UpdateCustomerAttribute": {
        "title": "UpdateCustomerAttribute",
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "is_visible": {
            "type": "boolean",
            "default": true
          },
          "is_filterable": {
            "type": "boolean",
            "default": true
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "UpdateDigitalProduct": {
        "title": "UpdateDigitalProduct",
        "oneOf": [
          {
            "$ref": "#/components/schemas/UpdateProductWithoutVariant"
          },
          {
            "$ref": "#/components/schemas/UpdateProductWithVariant"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "UpdateInboundBankAccount": {
        "title": "UpdateInboundBankAccount",
        "type": "object",
        "properties": {
          "account_type": {
            "const": "inbound"
          },
          "is_default": {
            "description": "Default bank account for the customer.",
            "type": "boolean"
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "UpdateKycDocument": {
        "title": "UpdateKycDocument",
        "type": "object",
        "required": [
          "modified_reason"
        ],
        "properties": {
          "document_number": {
            "type": "string"
          },
          "document_type_id": {
            "description": "Sending this field on update is rejected, even when the document type is unchanged.",
            "type": "string"
          },
          "note": {
            "type": "string"
          },
          "file": {
            "description": "file attachment will be required or optional as per store setting.",
            "type": "string",
            "format": "binary"
          },
          "status": {
            "enum": [
              "submitted",
              "approved",
              "rejected"
            ]
          },
          "modified_reason": {
            "type": "string"
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "UpdateKycDocumentConfig": {
        "title": "UpdateKycDocumentConfig",
        "type": "object",
        "required": [
          "title",
          "is_mandatory",
          "is_attachment_required",
          "verification_type"
        ],
        "properties": {
          "title": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "is_mandatory": {
            "type": "boolean"
          },
          "is_attachment_required": {
            "type": "boolean"
          },
          "verification_type": {
            "enum": [
              "auto",
              "manual"
            ]
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "UpdateOrder": {
        "title": "UpdateOrder",
        "type": "object",
        "required": [
          "shipping_address"
        ],
        "properties": {
          "shipping_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "is_billing_same_as_shipping": {
            "type": "boolean"
          },
          "billing_address": {
            "$ref": "#/components/schemas/OrderAddress"
          },
          "sync_address": {
            "description": "When `true`, syncs the provided addresses to the customer's saved address profile.",
            "type": "boolean"
          }
        },
        "x-tags": [
          "Orders"
        ]
      },
      "UpdateOutboundBankAccount": {
        "title": "UpdateOutboundBankAccount",
        "type": "object",
        "properties": {
          "account_type": {
            "const": "outbound"
          },
          "account_name": {
            "type": "string"
          },
          "account_number": {
            "type": "string"
          },
          "ifsc_code": {
            "type": "string"
          },
          "bank_name": {
            "type": "string"
          },
          "is_verified": {
            "type": "boolean"
          },
          "is_default": {
            "description": "Default bank account for the customer.",
            "type": "boolean"
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "UpdatePhysicalProductWithoutVariant": {
        "title": "UpdatePhysicalProductWithoutVariant",
        "allOf": [
          {
            "$ref": "#/components/schemas/UpdateProductWithoutVariant"
          },
          {
            "type": "object",
            "properties": {
              "sku": {
                "type": "string"
              },
              "shipping": {
                "$ref": "#/components/schemas/ProductShipping"
              },
              "packaging": {
                "$ref": "#/components/schemas/ProductPackaging"
              },
              "related_products": {
                "type": "object",
                "properties": {
                  "cross_sell": {
                    "description": "Array of IDs. The ID value should be the product ID if a non-variant product is selected. For variant products, the ID should be a combination of the product ID and variant ID, separated by a hyphen ('-').",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "upsell": {
                    "description": "Array of IDs. The ID value should be the product ID if a non-variant product is selected. For variant products, the ID should be a combination of the product ID and variant ID, separated by a hyphen ('-').",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "UpdatePhysicalProductWithVariant": {
        "title": "UpdatePhysicalProductWithVariant",
        "allOf": [
          {
            "$ref": "#/components/schemas/UpdateProductWithVariant"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "UpdateProduct": {
        "title": "UpdateProduct",
        "oneOf": [
          {
            "$ref": "#/components/schemas/UpdatePhysicalProductWithoutVariant"
          },
          {
            "$ref": "#/components/schemas/UpdatePhysicalProductWithVariant"
          },
          {
            "$ref": "#/components/schemas/UpdateDigitalProduct"
          },
          {
            "$ref": "#/components/schemas/UpdateBundleProduct"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "UpdateProductWithoutVariant": {
        "title": "UpdateProductWithoutVariant",
        "allOf": [
          {
            "$ref": "#/components/schemas/ProductCommonDetail"
          },
          {
            "type": "object",
            "properties": {
              "description": {
                "description": "Array of category ids.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "categories": {
                "description": "Array of category ids.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "images": {
                "description": "Array of image file ids.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "videos": {
                "description": "Array of video file ids.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "pricing": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductPricing"
                }
              },
              "promotions": {
                "$ref": "#/components/schemas/ProductPromotion"
              },
              "subscriptions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductSubscription"
                }
              },
              "variants": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "name",
                    "associated_options",
                    "is_default"
                  ],
                  "properties": {
                    "name": {
                      "type": "string"
                    },
                    "associated_options": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/AssociatedOption"
                      }
                    },
                    "is_default": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "UpdateProductWithVariant": {
        "title": "UpdateProductWithVariant",
        "allOf": [
          {
            "$ref": "#/components/schemas/ProductCommonDetail"
          },
          {
            "type": "object",
            "properties": {
              "description": {
                "description": "Array of category ids.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "categories": {
                "description": "Array of category ids.",
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            }
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "UpdateShippingZone": {
        "title": "UpdateShippingZone",
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "countries": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "country_alias": {
                  "type": "string"
                },
                "all_states": {
                  "type": "boolean",
                  "default": true
                },
                "state_alias": {
                  "description": "required if all_regions=false",
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "active": {
            "type": "boolean",
            "default": true
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "UpdateVariant": {
        "title": "UpdateVariant",
        "allOf": [
          {
            "$ref": "#/components/schemas/VariantCommonDetail"
          },
          {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "associated_options": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/AssociatedOption"
                }
              },
              "description": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "images": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "videos": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "seo": {
                "$ref": "#/components/schemas/Seo"
              },
              "shipping": {
                "$ref": "#/components/schemas/ProductShipping"
              },
              "packaging": {
                "$ref": "#/components/schemas/ProductPackaging"
              },
              "related_products": {
                "type": "object",
                "properties": {
                  "cross_sell": {
                    "description": "Array of IDs. The ID value should be the product ID if a non-variant product is selected. For variant products, the ID should be a combination of the product ID and variant ID, separated by a hyphen ('-').",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "upsell": {
                    "description": "Array of IDs. The ID value should be the product ID if a non-variant product is selected. For variant products, the ID should be a combination of the product ID and variant ID, separated by a hyphen ('-').",
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                }
              },
              "promotions": {
                "$ref": "#/components/schemas/ProductPromotion"
              },
              "subscriptions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductSubscription"
                }
              }
            }
          }
        ],
        "examples": [],
        "x-tags": [
          "Catalog"
        ]
      },
      "UpiPayment": {
        "title": "UpiPayment",
        "description": "UPI Payment",
        "allOf": [
          {
            "$ref": "#/components/schemas/OrderPaymentInfo"
          },
          {
            "type": "object",
            "properties": {
              "upi_id": {
                "type": [
                  "string",
                  "null"
                ]
              }
            }
          }
        ]
      },
      "UtmParam": {
        "title": "UtmParam",
        "type": "object",
        "required": [
          "utm_source",
          "utm_campaign",
          "utm_medium"
        ],
        "properties": {
          "utm_source": {
            "type": [
              "string",
              "null"
            ]
          },
          "utm_campaign": {
            "type": [
              "string",
              "null"
            ]
          },
          "utm_medium": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "additionalProperties": true
      },
      "Variant": {
        "title": "Variant",
        "allOf": [
          {
            "$ref": "#/components/schemas/VariantCommonDetail"
          },
          {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "associated_options": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/AssociatedOption"
                }
              },
              "images": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductImage"
                }
              }
            }
          }
        ],
        "examples": [],
        "x-tags": [
          "Catalog"
        ]
      },
      "VariantBulkUpdate": {
        "title": "VariantBulkUpdate",
        "type": "object",
        "properties": {
          "id": {
            "description": "variant id",
            "type": "string"
          },
          "shipping": {
            "$ref": "#/components/schemas/ProductShipping"
          },
          "packaging": {
            "$ref": "#/components/schemas/ProductPackaging"
          }
        },
        "examples": [],
        "x-tags": [
          "Catalog"
        ]
      },
      "VariantCommonDetail": {
        "title": "VariantCommonDetail",
        "type": "object",
        "properties": {
          "id": {
            "description": "variant id",
            "type": "string",
            "readOnly": true
          },
          "active": {
            "type": "boolean",
            "readOnly": true
          },
          "stock_available": {
            "type": "boolean",
            "readOnly": true
          },
          "is_default": {
            "type": "boolean"
          },
          "short_description": {
            "type": [
              "string",
              "null"
            ]
          },
          "metadata": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": {
              "type": "string"
            }
          },
          "sku": {
            "description": "variant sku. can be null for digital product.",
            "type": [
              "string",
              "null"
            ]
          },
          "slug": {
            "description": "variant sku. can be null for digital product.",
            "type": "string"
          },
          "hsn_code": {
            "type": "string",
            "readOnly": true
          },
          "on_offer": {
            "type": "boolean",
            "readOnly": true
          },
          "on_promotion": {
            "type": "boolean",
            "readOnly": true
          },
          "on_subscription": {
            "type": "boolean",
            "readOnly": true
          },
          "product_type": {
            "enum": [
              "physical",
              "digital"
            ],
            "readOnly": true
          },
          "product_id": {
            "type": "string",
            "readOnly": true
          },
          "product_name": {
            "type": "string",
            "readOnly": true
          },
          "pricing": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductPricing"
            }
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "variant_attributes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductAttribute"
            }
          }
        },
        "examples": [],
        "x-tags": [
          "Catalog"
        ]
      },
      "VariantDetail": {
        "title": "VariantDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/Variant"
          },
          {
            "type": "object",
            "properties": {
              "description": {
                "type": "string"
              },
              "videos": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductVideo"
                }
              },
              "seo": {
                "$ref": "#/components/schemas/Seo"
              },
              "shipping": {
                "$ref": "#/components/schemas/ProductShipping"
              },
              "packaging": {
                "$ref": "#/components/schemas/ProductPackaging"
              },
              "sales_channels": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SalesChannel"
                }
              },
              "related_products": {
                "type": "object",
                "properties": {
                  "upsell": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/ProductBasicDetail"
                    }
                  },
                  "cross_sell": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/ProductBasicDetail"
                    }
                  }
                }
              },
              "promotions": {
                "$ref": "#/components/schemas/ProductPromotion"
              },
              "subscriptions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ProductSubscription"
                }
              }
            }
          }
        ],
        "examples": [],
        "x-tags": [
          "Catalog"
        ]
      },
      "VariantOption": {
        "title": "VariantOption",
        "type": "object",
        "properties": {
          "attribute_id": {
            "type": "string"
          },
          "attribute_value": {
            "description": "The attribute value can be a plain string or an array of strings or color objects containing name and hexcode.",
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "oneOf": [
                    {
                      "type": "string"
                    },
                    {
                      "$ref": "#/components/schemas/ColorObject"
                    }
                  ]
                }
              }
            ]
          },
          "attribute_name": {
            "type": "string"
          },
          "attribute_type": {
            "enum": [
              "single-select",
              "color"
            ]
          },
          "key": {
            "description": "value in snake case.",
            "type": "string"
          }
        }
      },
      "VariantPackaging": {
        "title": "VariantPackaging",
        "allOf": [
          {
            "$ref": "#/components/schemas/ProductPackaging"
          }
        ],
        "x-tags": [
          "Catalog"
        ]
      },
      "Visitor": {
        "title": "Visitor",
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "os": {
            "type": "string"
          },
          "device": {
            "type": "string"
          },
          "browser": {
            "type": "string"
          },
          "last_seen": {
            "type": "string",
            "format": "date-time"
          },
          "total_event": {
            "type": "integer",
            "format": "int32"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "modified_at": {
            "type": "string",
            "format": "date-time"
          }
        },
        "x-tags": [
          "Customers"
        ]
      },
      "VisitorDetail": {
        "title": "VisitorDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/Visitor"
          }
        ],
        "x-tags": [
          "Customers"
        ]
      },
      "VolumeBasedCouponPromotion": {
        "title": "VolumeBasedCouponPromotion",
        "allOf": [
          {
            "$ref": "#/components/schemas/CouponPromotionCommonDetail"
          },
          {
            "type": "object",
            "required": [
              "details",
              "applies_to_product"
            ],
            "properties": {
              "details": {
                "$ref": "#/components/schemas/VolumeBasedRule"
              },
              "applies_to_product": {
                "type": "string",
                "const": "product"
              }
            }
          }
        ]
      },
      "VolumeBasedPromotion": {
        "title": "VolumeBasedPromotion",
        "description": "promotion_type = volume-based",
        "type": [
          "object",
          "null"
        ],
        "required": [
          "promotion_type",
          "starts_at",
          "details"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "promotion_type": {
            "enum": [
              "volume-based"
            ]
          },
          "starts_at": {
            "type": "string"
          },
          "expires_at": {
            "description": "null means never expires.",
            "type": [
              "string",
              "null"
            ]
          },
          "details": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "customer_group_id",
                "slabs"
              ],
              "properties": {
                "customer_group_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "slabs": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "required": [
                      "quantity",
                      "quantity_condition",
                      "discount_percent"
                    ],
                    "properties": {
                      "quantity": {
                        "type": "integer"
                      },
                      "quantity_condition": {
                        "description": "This key defines how the system will evaluate the quantity to determine if the promotion should be applied, based on the specified slab.",
                        "enum": [
                          "less",
                          "less-or-equal",
                          "greater",
                          "greater-or-equal"
                        ]
                      },
                      "discount_percent": {
                        "type": "number"
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "VolumeBasedRule": {
        "title": "VolumeBasedRule",
        "type": "object",
        "required": [
          "products",
          "maximum_discount_amount"
        ],
        "properties": {
          "products": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "product_id",
                "variant_id",
                "slabs"
              ],
              "properties": {
                "sku": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "readOnly": true
                },
                "product_name": {
                  "type": "string",
                  "readOnly": true
                },
                "status": {
                  "type": "string",
                  "readOnly": true
                },
                "stock_available": {
                  "type": "string",
                  "readOnly": true
                },
                "images": {
                  "type": "string",
                  "readOnly": true
                },
                "product_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "variant_id": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "slabs": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "required": [
                      "quantity",
                      "condition",
                      "discount_percent"
                    ],
                    "properties": {
                      "quantity": {
                        "type": "integer"
                      },
                      "condition": {
                        "enum": [
                          "less-or-equal",
                          "greater"
                        ]
                      },
                      "discount_percent": {
                        "type": "number"
                      }
                    }
                  }
                }
              }
            }
          },
          "maximum_discount_amount": {
            "type": [
              "number",
              "null"
            ]
          }
        },
        "x-tags": [
          "Coupons & promotions"
        ]
      },
      "WalletPayment": {
        "title": "WalletPayment",
        "allOf": [
          {
            "$ref": "#/components/schemas/OrderPaymentInfo"
          },
          {
            "type": "object",
            "properties": {
              "wallet_name": {
                "type": [
                  "string",
                  "null"
                ]
              }
            }
          }
        ]
      },
      "Warehouse": {
        "title": "Warehouse",
        "description": "Validations:\n\n1) Either 'can_receive_stock' or 'accepts_returns' must be set to true.\n2) 'can_receive_stock' cannot be set to false while the warehouse has existing inventory.\n3) 'is_checkout_point' must be true when the warehouse type is 'retail-store'.\n4) If 'can_receive_stock' is false then 'can_ship_parcel' and 'can_collect' fields should be false.",
        "type": "object",
        "required": [
          "name",
          "warehouse_type",
          "city",
          "address_line1",
          "pincode",
          "state",
          "country",
          "contact_phone",
          "contact_email",
          "can_receive_stock",
          "can_ship_parcel",
          "can_collect",
          "is_checkout_point",
          "accepts_returns"
        ],
        "properties": {
          "id": {
            "description": "warehouse id",
            "type": "string",
            "readOnly": true
          },
          "name": {
            "description": "legal name",
            "type": "string"
          },
          "warehouse_type": {
            "enum": [
              "retail-store",
              "distribution-center"
            ]
          },
          "active": {
            "type": "boolean",
            "default": true
          },
          "gstin": {
            "type": [
              "string",
              "null"
            ]
          },
          "city": {
            "type": [
              "string",
              "null"
            ]
          },
          "address_line1": {
            "type": "string"
          },
          "address_line2": {
            "type": [
              "string",
              "null"
            ]
          },
          "landmark": {
            "type": [
              "string",
              "null"
            ]
          },
          "pincode": {
            "type": [
              "string",
              "null"
            ]
          },
          "state": {
            "type": [
              "string",
              "null"
            ]
          },
          "country": {
            "type": "string"
          },
          "country_code": {
            "type": [
              "string",
              "null"
            ]
          },
          "contact_phone": {
            "description": "10 digit number without country code.",
            "type": [
              "string",
              "null"
            ]
          },
          "contact_email": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_default": {
            "type": "boolean"
          },
          "image_url": {
            "type": [
              "string",
              "null"
            ]
          },
          "seller_warehouse_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "can_receive_stock": {
            "type": "boolean"
          },
          "can_ship_parcel": {
            "type": "boolean"
          },
          "can_collect": {
            "type": "boolean"
          },
          "is_checkout_point": {
            "description": "this field will be always true for warehouse_type = retail-store.",
            "type": "boolean"
          },
          "accepts_returns": {
            "type": "boolean"
          },
          "opening_hours": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/OpeningHours"
              },
              {
                "type": "null"
              }
            ]
          },
          "channels": {
            "description": "channels associated with the warehouse",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/WarehouseSalesChannel"
            },
            "readOnly": true
          }
        }
      },
      "WarehouseBasedShippingOption": {
        "title": "WarehouseBasedShippingOption",
        "type": "object",
        "required": [
          "based_on",
          "warehouse_id",
          "service_provider_id"
        ],
        "properties": {
          "based_on": {
            "type": "string",
            "const": "warehouse"
          },
          "warehouse_id": {
            "type": "string"
          },
          "service_provider_id": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "x-tags": [
          "Store"
        ]
      },
      "WarehouseBasicDetail": {
        "title": "WarehouseBasicDetail",
        "type": "object",
        "properties": {
          "id": {
            "type": [
              "string",
              "null"
            ]
          },
          "name": {
            "type": [
              "string",
              "null"
            ]
          },
          "address_line1": {
            "type": [
              "string",
              "null"
            ]
          },
          "pincode": {
            "type": [
              "string",
              "null"
            ]
          },
          "city": {
            "type": [
              "string",
              "null"
            ]
          },
          "state": {
            "type": [
              "string",
              "null"
            ]
          },
          "gstin": {
            "type": [
              "string",
              "null"
            ]
          },
          "address_line2": {
            "type": [
              "string",
              "null"
            ]
          },
          "landmark": {
            "type": [
              "string",
              "null"
            ]
          },
          "contact_phone": {
            "type": [
              "string",
              "null"
            ]
          },
          "contact_email": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_default": {
            "type": "boolean"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "WarehouseDetail": {
        "title": "WarehouseDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/Warehouse"
          },
          {
            "type": "object",
            "properties": {
              "seller_id": {
                "description": "Relevant for marketplace type stores only. `null` for b2b and b2c type stores.",
                "type": [
                  "string",
                  "null"
                ],
                "readOnly": true
              },
              "marketplace_listing": {
                "description": "Marketplaces this warehouse is listed on.",
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "marketplace_id": {
                      "type": "string"
                    }
                  }
                },
                "readOnly": true
              },
              "shipping_boxes": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/StoreShippingBox"
                },
                "readOnly": true
              },
              "shipping_providers": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ShippingOption"
                },
                "readOnly": true
              },
              "manual_methods": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/WarehouseManualMethod"
                },
                "readOnly": true
              },
              "available_shipping_options": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/WarehouseShippingOption"
                },
                "readOnly": true
              }
            }
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "WarehouseManualMethod": {
        "title": "WarehouseManualMethod",
        "allOf": [
          {
            "$ref": "#/components/schemas/WarehouseShippingOption"
          },
          {
            "type": "object",
            "properties": {
              "shipping_method_type": {
                "enum": [
                  "manual",
                  "local-pickup"
                ]
              },
              "shipping_rate_name": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "shipping_rate_fixed_price": {
                "description": "`null` when `shipping_rate_condition` is set.",
                "type": [
                  "number",
                  "null"
                ]
              },
              "shipping_rate_condition": {
                "description": "`null` when `shipping_rate_fixed_price` is set.",
                "anyOf": [
                  {
                    "$ref": "#/components/schemas/ManualShippingRateCondition"
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "maximum_weight": {
                "description": "`null` when there is no weight limit.",
                "type": [
                  "number",
                  "null"
                ]
              },
              "delivery_leadtime_minimum": {
                "description": "In days.",
                "type": "integer"
              },
              "delivery_leadtime_maximum": {
                "description": "In days.",
                "type": "integer"
              }
            }
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "WarehouseSalesChannel": {
        "title": "WarehouseSalesChannel",
        "allOf": [
          {
            "$ref": "#/components/schemas/SalesChannel"
          },
          {
            "type": "object",
            "properties": {
              "channel_type": {
                "description": "Observed values: `web`, `pos`, `internal`.",
                "type": "string"
              },
              "is_default": {
                "type": "boolean"
              },
              "domain": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "app_platform": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "external_id": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "pos_vendor": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "store_id": {
                "type": "string"
              },
              "store_name": {
                "type": "string"
              },
              "marketplace_id": {
                "description": "Set only when `kind` is `marketplace`.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "marketplace": {
                "description": "`null` unless `kind` is `marketplace`.",
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      },
                      "slug": {
                        "type": "string"
                      },
                      "marketplace_type": {
                        "type": "string"
                      },
                      "store_id": {
                        "description": "The marketplace operator's store.",
                        "type": "string"
                      },
                      "sync_products": {
                        "type": "boolean"
                      },
                      "sync_inventory": {
                        "type": "boolean"
                      },
                      "sync_orders": {
                        "type": "boolean"
                      },
                      "required_credentials_params": {
                        "type": [
                          "object",
                          "null"
                        ]
                      },
                      "created_at": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "modified_at": {
                        "type": "string",
                        "format": "date-time"
                      }
                    }
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "seller_account": {
                "description": "This store's seller account on the marketplace. `null` unless `kind` is `marketplace`.",
                "oneOf": [
                  {
                    "allOf": [
                      {
                        "$ref": "#/components/schemas/SellerInfo"
                      },
                      {
                        "type": "object",
                        "properties": {
                          "marketplace_id": {
                            "type": "string"
                          },
                          "marketplace_name": {
                            "type": "string"
                          }
                        }
                      }
                    ]
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            }
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "WarehouseShippingOption": {
        "title": "WarehouseShippingOption",
        "allOf": [
          {
            "$ref": "#/components/schemas/ShippingOption"
          },
          {
            "type": "object",
            "properties": {
              "logo": {
                "type": [
                  "string",
                  "null"
                ],
                "readOnly": true
              },
              "fulfillment_type": {
                "enum": [
                  "delivery",
                  "collect-in-store"
                ]
              },
              "sort_order": {
                "type": "integer"
              }
            }
          }
        ],
        "x-tags": [
          "Store"
        ]
      },
      "WarehouseWiseInventory": {
        "title": "WarehouseWiseInventory",
        "type": "object",
        "properties": {
          "lot_batch": {
            "type": [
              "string",
              "null"
            ]
          },
          "mfg_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date"
          },
          "exp_date": {
            "type": [
              "string",
              "null"
            ],
            "format": "date"
          },
          "manufacturer": {
            "type": [
              "string",
              "null"
            ]
          },
          "warehouse_id": {
            "type": "string"
          },
          "warehouse": {
            "$ref": "#/components/schemas/WarehouseBasicDetail"
          },
          "received_quantity": {
            "type": "integer"
          },
          "reserved_quantity": {
            "type": "integer"
          },
          "sold_quantity": {
            "type": "integer"
          },
          "adjusted_quantity": {
            "type": "integer"
          },
          "stock_quantity": {
            "type": "integer"
          }
        },
        "x-tags": [
          "Catalog"
        ]
      },
      "Webhook": {
        "title": "Webhook",
        "type": "object",
        "required": [
          "id",
          "name",
          "endpoint",
          "events",
          "custom_headers",
          "status",
          "webhook_secret_key",
          "created_at",
          "modified_at"
        ],
        "properties": {
          "id": {
            "type": "string",
            "readOnly": true
          },
          "name": {
            "type": "string"
          },
          "endpoint": {
            "type": "string",
            "format": "uri"
          },
          "events": {
            "type": "array",
            "items": {
              "type": "string",
              "example": "order.created"
            }
          },
          "custom_headers": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "status": {
            "$ref": "#/components/schemas/WebhookStatus"
          },
          "webhook_secret_key": {
            "description": "This will be shown only once during create. For all GET requests, this will be redacted.",
            "type": "string",
            "readOnly": true
          },
          "created_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          },
          "modified_at": {
            "type": "string",
            "format": "date-time",
            "readOnly": true
          }
        },
        "x-tags": [
          "Webhooks"
        ]
      },
      "WebhookDeliveryLog": {
        "title": "WebhookDeliveryLog",
        "type": "object",
        "required": [
          "delivery_id",
          "event_id",
          "webhook_id",
          "webhook_name",
          "endpoint",
          "event",
          "timestamp",
          "retry_attempt",
          "next_retry_at",
          "status",
          "response_code",
          "duration_ms",
          "error_message",
          "is_test"
        ],
        "properties": {
          "delivery_id": {
            "description": "The unique delivery_id for the Webhook delivery attempt",
            "type": "string",
            "readOnly": true
          },
          "event_id": {
            "description": "The unique id for that event. Shared across all delivery attempts of the same event.",
            "type": "string",
            "readOnly": true
          },
          "webhook_id": {
            "type": "string"
          },
          "webhook_name": {
            "type": "string"
          },
          "endpoint": {
            "type": "string"
          },
          "event": {
            "type": "string"
          },
          "timestamp": {
            "type": "string",
            "format": "date-time"
          },
          "retry_attempt": {
            "type": "integer"
          },
          "next_retry_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "status": {
            "type": "string",
            "enum": [
              "success",
              "failed"
            ]
          },
          "response_code": {
            "type": "integer"
          },
          "duration_ms": {
            "type": "integer"
          },
          "error_message": {
            "type": [
              "string",
              "null"
            ]
          },
          "is_test": {
            "type": "boolean"
          }
        },
        "x-tags": [
          "Webhooks"
        ]
      },
      "WebhookDeliveryLogDetail": {
        "title": "WebhookDeliveryLogDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/WebhookDeliveryLog"
          },
          {
            "type": "object",
            "required": [
              "request_headers",
              "request_body",
              "response_headers",
              "response_body"
            ],
            "properties": {
              "request_headers": {
                "type": "object",
                "additionalProperties": {
                  "type": "string"
                }
              },
              "request_body": {
                "type": "object"
              },
              "response_headers": {
                "type": "object",
                "additionalProperties": {
                  "type": "string"
                }
              },
              "response_body": {
                "type": "string"
              }
            }
          }
        ],
        "x-tags": [
          "Webhooks"
        ]
      },
      "WebhookEvent": {
        "title": "WebhookEvent",
        "type": "object",
        "required": [
          "event_id",
          "event",
          "timestamp",
          "is_test"
        ],
        "properties": {
          "event_id": {
            "description": "The unique id for that event. Shared across all delivery attempts of the same event.",
            "type": "string",
            "readOnly": true
          },
          "event": {
            "type": "string"
          },
          "timestamp": {
            "type": "string",
            "format": "date-time"
          },
          "is_test": {
            "type": "boolean"
          }
        },
        "x-tags": [
          "Webhooks"
        ]
      },
      "WebhookEventDetail": {
        "title": "WebhookEventDetail",
        "allOf": [
          {
            "$ref": "#/components/schemas/WebhookEvent"
          },
          {
            "type": "object",
            "required": [
              "payload",
              "deliveries",
              "webhook_relations"
            ],
            "properties": {
              "payload": {
                "type": "object"
              },
              "deliveries": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/WebhookDeliveryLog"
                }
              },
              "webhook_relations": {
                "type": "array",
                "items": {
                  "type": "object",
                  "required": [
                    "webhook_id",
                    "webhook_name"
                  ],
                  "properties": {
                    "webhook_id": {
                      "type": "string"
                    },
                    "webhook_name": {
                      "type": "string"
                    }
                  }
                }
              }
            }
          }
        ],
        "x-tags": [
          "Webhooks"
        ]
      },
      "WebhookEventType": {
        "title": "WebhookEventType",
        "type": "object",
        "required": [
          "event",
          "description"
        ],
        "properties": {
          "event": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "x-tags": [
          "Webhooks"
        ]
      },
      "WebhookStats": {
        "title": "WebhookStats",
        "type": "object",
        "required": [
          "delivered",
          "delivered_in_first_attempt",
          "delivered_in_second_attempt",
          "delivered_in_third_attempt",
          "delivered_in_fourth_attempt",
          "failed",
          "total_deliveries",
          "total_events",
          "average_latency",
          "p50_latency",
          "p75_latency",
          "p95_latency"
        ],
        "properties": {
          "delivered": {
            "type": "integer"
          },
          "delivered_in_first_attempt": {
            "type": "integer"
          },
          "delivered_in_second_attempt": {
            "type": "integer"
          },
          "delivered_in_third_attempt": {
            "type": "integer"
          },
          "delivered_in_fourth_attempt": {
            "type": "integer"
          },
          "failed": {
            "type": "integer"
          },
          "total_deliveries": {
            "type": "integer"
          },
          "total_events": {
            "type": "integer"
          },
          "average_latency": {
            "type": "number"
          },
          "p50_latency": {
            "type": "number"
          },
          "p75_latency": {
            "type": "number"
          },
          "p95_latency": {
            "type": "number"
          }
        },
        "x-tags": [
          "Webhooks"
        ]
      },
      "WebhookStatus": {
        "title": "WebhookStatus",
        "type": "string",
        "enum": [
          "enabled",
          "disabled",
          "error"
        ]
      }
    },
    "parameters": {
      "columnBasedFilters": {
        "name": "filters",
        "in": "query",
        "required": false,
        "schema": {
          "type": "string",
          "example": "{\"condition\":\"AND\",\"filters\":[{\"type\":\"data\",\"field\":\"status\",\"operator\":\"equals\",\"value\":\"success\"}]}"
        },
        "description": "JSON object"
      },
      "dataView": {
        "name": "view",
        "in": "query",
        "required": false,
        "schema": {
          "type": "string",
          "enum": [
            "warehouse"
          ]
        },
        "description": "view to be used to display the data"
      },
      "pageLimit": {
        "name": "limit",
        "in": "query",
        "required": false,
        "schema": {
          "type": "integer",
          "default": 25,
          "minimum": 1
        },
        "description": "no of rows per page"
      },
      "pageNumber": {
        "name": "page",
        "in": "query",
        "required": false,
        "schema": {
          "type": "integer",
          "default": 1,
          "minimum": 1
        },
        "description": "page number of pagination list"
      },
      "searchKeyword": {
        "name": "search",
        "in": "query",
        "required": false,
        "schema": {
          "type": "string"
        },
        "description": "search keyword"
      },
      "sortByOptions": {
        "name": "sort_by",
        "in": "query",
        "required": false,
        "schema": {
          "description": "json string in format {'field_name':'asc', 'other_field_name':'desc', ...}",
          "type": "string"
        },
        "description": "JSON string format: {\"field1\":\"asc\", \"field2\":\"desc\"}"
      }
    },
    "responses": {
      "BadRequest": {
        "description": "Bad request",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "properties": {
                "message": {
                  "type": "string"
                },
                "success": {
                  "type": "boolean"
                },
                "code": {
                  "type": "string"
                },
                "error": {
                  "type": "object",
                  "properties": {
                    "fieldname": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "NotFound": {
        "description": "Requested resource not found",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "properties": {
                "message": {
                  "type": "string"
                },
                "success": {
                  "type": "boolean"
                },
                "code": {
                  "type": "string"
                }
              }
            }
          }
        }
      },
      "Unauthorized": {
        "description": "Not authorized for given operation on the Resource",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "properties": {
                "message": {
                  "type": "string",
                  "example": "Not authorized for given operation on the Resource."
                },
                "success": {
                  "type": "boolean",
                  "default": false
                },
                "code": {
                  "type": "string",
                  "example": "unauthorized"
                }
              }
            }
          }
        }
      }
    },
    "securitySchemes": {
      "Authorization": {
        "type": "http",
        "scheme": "bearer"
      },
      "X-Api-Key": {
        "name": "X-Api-Key",
        "type": "apiKey",
        "in": "header"
      }
    }
  },
  "security": [
    {
      "Authorization": []
    }
  ]
}