{
  "openapi": "3.1.0",
  "info": {
    "title": "Rose Belleza Femenina — Public Storefront API",
    "version": "1.0.0",
    "summary": "Public, unauthenticated read and cart APIs for the Rose Belleza Femenina online store.",
    "description": "Rose Belleza Femenina is a Colombian manufacturer and retailer of modest / Christian women's clothing (skirts, dresses, overalls, blouses and matching sets), operating four physical stores and one online store on Shopify.\n\nThis specification documents the endpoints that are publicly reachable on `https://rosebellezafemenina.com` with **no authentication and no API key**, plus the authenticated surfaces and the named OAuth scopes required to reach them.\n\n## What agents can do without any credentials\n\n- Search and read the full product catalog (`/api/{version}/graphql.json`, `/search/suggest.json`, `/products/{handle}.json`, `/collections/{handle}/products.json`).\n- Build a cart on the shopper's behalf (`/cart/add.js`, `/cart/change.js`, `/cart/update.js`, `/cart.js`).\n- Discover and drive an agentic checkout through the Universal Commerce Protocol MCP endpoint (`/api/ucp/mcp`).\n\n## What agents must not do\n\nCheckout completion always requires contemporaneous human approval. See `/agents.md` and the UCP specification for the buyer-approval invariant.\n\n## Errors\n\nEvery endpoint in this document returns structured JSON on failure. See the `CartError`, `GraphQLErrorResponse` and `JsonRpcErrorResponse` schemas.",
    "termsOfService": "https://rosebellezafemenina.com/policies/terms-of-service",
    "contact": {
      "name": "Rose Belleza Femenina — soporte",
      "email": "george@rosebellezafemenina.com",
      "url": "https://rosebellezafemenina.com/pages/developers"
    },
    "license": {
      "name": "Proprietary — read access granted for agent and integration use",
      "url": "https://rosebellezafemenina.com/policies/terms-of-service"
    },
    "x-logo": {
      "url": "https://cdn.shopify.com/s/files/1/0915/1745/2580/files/ROSE1_upscayl_2x_realesrgan-x4plus-anime.png",
      "altText": "Rose Belleza Femenina"
    }
  },
  "externalDocs": {
    "description": "Developer portal, quickstart and agent instructions",
    "url": "https://rosebellezafemenina.com/pages/developers"
  },
  "servers": [
    {
      "url": "https://rosebellezafemenina.com",
      "description": "Production storefront (primary domain). No sandbox is required: every endpoint in this document is read-only or cart-scoped, and carts are per-session and are never charged without human approval."
    },
    {
      "url": "https://ey9jpt-yd.myshopify.com",
      "description": "Canonical Shopify origin for the same store. Identical behaviour; prefer the primary domain."
    }
  ],
  "tags": [
    {
      "name": "catalog",
      "description": "Read product and collection data. No credentials required."
    },
    {
      "name": "search",
      "description": "Full-text and typeahead product search. No credentials required."
    },
    {
      "name": "cart",
      "description": "Session-scoped cart manipulation. No credentials required; state is bound to the `cart` cookie."
    },
    {
      "name": "agents",
      "description": "Agent discovery: UCP profile, MCP endpoint and machine-readable instructions."
    },
    {
      "name": "discovery",
      "description": "Machine-readable descriptions of this store."
    }
  ],
  "security": [],
  "paths": {
    "/api/{version}/graphql.json": {
      "post": {
        "operationId": "queryStorefrontGraphql",
        "tags": [
          "catalog",
          "search"
        ],
        "summary": "Query the public Storefront GraphQL API",
        "description": "The primary programmatic surface of this store, and the one agents should prefer. The schema is fully typed and introspectable (`{ __schema { ... } }` works), so a function-calling agent can discover every available field at runtime.\n\nThis store serves the Storefront API publicly: no `X-Shopify-Storefront-Access-Token` header is required for the unauthenticated read scopes. Supplying a token is still supported and is required for the scopes listed under the `storefrontAccessToken` security scheme (customer accounts, checkout mutations).\n\nEvery response carries an `extensions.cost` object describing the calculated query cost — use it to pace requests instead of guessing.",
        "security": [
          {},
          {
            "storefrontAccessToken": []
          }
        ],
        "parameters": [
          {
            "name": "version",
            "in": "path",
            "required": true,
            "description": "Shopify API version, in `YYYY-MM` form. Versions are supported for at least 12 months. `unstable` tracks the newest schema and may change without notice.",
            "schema": {
              "type": "string",
              "pattern": "^(\\d{4}-\\d{2}|unstable)$",
              "default": "2026-07",
              "examples": [
                "2026-10",
                "2026-07",
                "2026-04",
                "2025-10"
              ]
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GraphQLRequest"
              },
              "examples": {
                "listProducts": {
                  "summary": "First page of products with price and availability",
                  "value": {
                    "query": "query Products($n: Int!) { products(first: $n) { edges { node { id title handle onlineStoreUrl availableForSale priceRange { minVariantPrice { amount currencyCode } } } } pageInfo { hasNextPage endCursor } } }",
                    "variables": {
                      "n": 10
                    }
                  }
                },
                "searchSkirts": {
                  "summary": "Search the catalog by free text",
                  "value": {
                    "query": "query Search($q: String!) { search(query: $q, first: 5, types: PRODUCT) { edges { node { ... on Product { title handle onlineStoreUrl } } } } }",
                    "variables": {
                      "q": "falda larga jean"
                    }
                  }
                },
                "introspect": {
                  "summary": "Discover the schema at runtime",
                  "value": {
                    "query": "{ __schema { queryType { name } types { name kind } } }"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "GraphQL result. A `200` may still carry an `errors` array — always inspect both `data` and `errors`.",
            "headers": {
              "Content-Type": {
                "$ref": "#/components/headers/JsonContentType"
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GraphQLResponse"
                },
                "examples": {
                  "ok": {
                    "summary": "Successful query",
                    "value": {
                      "data": {
                        "shop": {
                          "name": "Rose Belleza Femenina"
                        }
                      },
                      "extensions": {
                        "cost": {
                          "requestedQueryCost": 5
                        }
                      }
                    }
                  },
                  "fieldError": {
                    "summary": "Unknown field",
                    "value": {
                      "errors": [
                        {
                          "message": "Field 'nopeField' doesn't exist on type 'QueryRoot'",
                          "locations": [
                            {
                              "line": 1,
                              "column": 3
                            }
                          ],
                          "path": [
                            "query",
                            "nopeField"
                          ],
                          "extensions": {
                            "code": "undefinedField",
                            "typeName": "QueryRoot",
                            "fieldName": "nopeField"
                          }
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "402": {
            "$ref": "#/components/responses/StoreUnavailable"
          },
          "429": {
            "$ref": "#/components/responses/GraphQLThrottled"
          }
        }
      }
    },
    "/products/{handle}.json": {
      "get": {
        "operationId": "getProductByHandle",
        "tags": [
          "catalog"
        ],
        "summary": "Get one product by its URL handle",
        "description": "Returns the full public record for a single product: title, HTML description, vendor, product type, tags, every variant with its price and availability, and every image. The `handle` is the last path segment of the product's storefront URL (`/products/{handle}`).",
        "security": [],
        "parameters": [
          {
            "$ref": "#/components/parameters/ProductHandle"
          }
        ],
        "responses": {
          "200": {
            "description": "The product.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "product"
                  ],
                  "properties": {
                    "product": {
                      "$ref": "#/components/schemas/Product"
                    }
                  }
                }
              }
            }
          },
          "404": {
            "$ref": "#/components/responses/NotFoundJson"
          }
        }
      }
    },
    "/collections/{handle}/products.json": {
      "get": {
        "operationId": "listCollectionProducts",
        "tags": [
          "catalog"
        ],
        "summary": "List the products in a collection",
        "description": "Paginated list of the products in one collection. Use the reserved handle `all` to page through the entire catalog. Collection handles are listed in `/sitemap_collections_1.xml` and in the storefront navigation.",
        "security": [],
        "parameters": [
          {
            "$ref": "#/components/parameters/CollectionHandle"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/Page"
          }
        ],
        "responses": {
          "200": {
            "description": "One page of products. An empty `products` array means you have paged past the end.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "products"
                  ],
                  "properties": {
                    "products": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Product"
                      }
                    }
                  }
                }
              }
            }
          },
          "404": {
            "$ref": "#/components/responses/NotFoundJson"
          }
        }
      }
    },
    "/search/suggest.json": {
      "get": {
        "operationId": "searchSuggestions",
        "tags": [
          "search"
        ],
        "summary": "Typeahead search across products, collections and pages",
        "description": "Low-latency predictive search. Prefer this over scraping `/search`. For richer filtering and cursor pagination, use `queryStorefrontGraphql` instead.",
        "security": [],
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "required": true,
            "description": "Free-text query, in Spanish. Example: `falda larga jean`.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "examples": [
                "falda larga",
                "vestido modesto"
              ]
            }
          },
          {
            "name": "resources[type]",
            "in": "query",
            "required": false,
            "description": "Comma-separated resource types to search.",
            "schema": {
              "type": "string",
              "default": "product",
              "examples": [
                "product",
                "product,collection,page"
              ]
            }
          },
          {
            "name": "resources[limit]",
            "in": "query",
            "required": false,
            "description": "Maximum results per resource type.",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 10,
              "default": 10
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Suggestions grouped by resource type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SuggestResponse"
                }
              }
            }
          }
        }
      }
    },
    "/cart.js": {
      "get": {
        "operationId": "getCart",
        "tags": [
          "cart"
        ],
        "summary": "Read the current session cart",
        "description": "Returns the cart bound to the `cart` cookie on this connection. A fresh client gets an empty cart with a new token; persist the cookie jar across calls or every request starts a new cart.",
        "security": [],
        "responses": {
          "200": {
            "description": "The current cart.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Cart"
                }
              }
            }
          }
        }
      }
    },
    "/cart/add.js": {
      "post": {
        "operationId": "addCartItems",
        "tags": [
          "cart"
        ],
        "summary": "Add one or more variants to the session cart",
        "description": "`id` is a **variant** id, not a product id. Read variant ids from `getProductByHandle` (`product.variants[].id`) or from the Storefront GraphQL API. Adding more units than are in stock fails with a `422` and a machine-readable `CartError`.",
        "security": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CartAddRequest"
              },
              "examples": {
                "single": {
                  "summary": "Add one unit of a variant",
                  "value": {
                    "items": [
                      {
                        "id": 51234567890123,
                        "quantity": 1
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The added line items.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CartAddResponse"
                }
              }
            }
          },
          "422": {
            "$ref": "#/components/responses/CartUnprocessable"
          }
        }
      }
    },
    "/cart/change.js": {
      "post": {
        "operationId": "changeCartLine",
        "tags": [
          "cart"
        ],
        "summary": "Change the quantity or properties of one cart line",
        "description": "Identify the line by 1-based `line` index or by `id` (the line item key). Setting `quantity` to `0` removes the line. Returns the whole cart after the change.",
        "security": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CartChangeRequest"
              },
              "examples": {
                "setQuantity": {
                  "summary": "Set line 1 to two units",
                  "value": {
                    "line": 1,
                    "quantity": 2
                  }
                },
                "remove": {
                  "summary": "Remove line 1",
                  "value": {
                    "line": 1,
                    "quantity": 0
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The cart after the change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Cart"
                }
              }
            }
          },
          "422": {
            "$ref": "#/components/responses/CartUnprocessable"
          }
        }
      }
    },
    "/cart/update.js": {
      "post": {
        "operationId": "updateCart",
        "tags": [
          "cart"
        ],
        "summary": "Update cart-level attributes, note or line quantities",
        "description": "Bulk update: set the order `note`, arbitrary `attributes`, or a map of variant id to quantity via `updates`. Returns the whole cart.",
        "security": [],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CartUpdateRequest"
              },
              "examples": {
                "note": {
                  "summary": "Attach a delivery note",
                  "value": {
                    "note": "Entregar despues de las 2pm"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The cart after the update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Cart"
                }
              }
            }
          },
          "422": {
            "$ref": "#/components/responses/CartUnprocessable"
          }
        }
      }
    },
    "/api/ucp/mcp": {
      "post": {
        "operationId": "callUcpMcpServer",
        "tags": [
          "agents"
        ],
        "summary": "Call the store's MCP server (Universal Commerce Protocol)",
        "description": "A JSON-RPC 2.0 endpoint speaking the Model Context Protocol over Streamable HTTP. This is the native way for an AI agent to search the catalog, build a cart and drive an approved checkout.\n\nCall `initialize` first, then `tools/list` to discover the available tools and their JSON Schemas. The server advertises the `tools`, `prompts`, `resources` and `logging` capabilities.\n\nCheckout completion requires contemporaneous human approval — see `/agents.md`.",
        "security": [],
        "parameters": [
          {
            "name": "Accept",
            "in": "header",
            "required": false,
            "description": "Send `application/json, text/event-stream` to allow streamed responses.",
            "schema": {
              "type": "string",
              "default": "application/json, text/event-stream"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/JsonRpcRequest"
              },
              "examples": {
                "initialize": {
                  "summary": "MCP handshake",
                  "value": {
                    "jsonrpc": "2.0",
                    "id": 1,
                    "method": "initialize",
                    "params": {
                      "protocolVersion": "2025-06-18",
                      "capabilities": {},
                      "clientInfo": {
                        "name": "my-agent",
                        "version": "1.0.0"
                      }
                    }
                  }
                },
                "toolsList": {
                  "summary": "Discover tools",
                  "value": {
                    "jsonrpc": "2.0",
                    "id": 2,
                    "method": "tools/list"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "JSON-RPC result.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/JsonRpcResponse"
                }
              }
            }
          },
          "422": {
            "description": "JSON-RPC error. The envelope is still valid JSON-RPC 2.0; read `error.code`, `error.message` and `error.data`.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/JsonRpcErrorResponse"
                },
                "examples": {
                  "unknownMethod": {
                    "summary": "Method rejected",
                    "value": {
                      "jsonrpc": "2.0",
                      "id": 9,
                      "error": {
                        "code": -32001,
                        "message": "UCP discovery failed",
                        "data": {
                          "code": "invalid_profile_url"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "429": {
            "$ref": "#/components/responses/RateLimited"
          }
        }
      }
    },
    "/.well-known/ucp": {
      "get": {
        "operationId": "getUcpProfile",
        "tags": [
          "agents",
          "discovery"
        ],
        "summary": "Universal Commerce Protocol merchant profile",
        "description": "Machine-readable declaration of the UCP versions, services, capabilities and payment handlers this store supports. Start here before calling `callUcpMcpServer`.",
        "security": [],
        "responses": {
          "200": {
            "description": "The merchant profile.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UcpProfile"
                }
              }
            }
          }
        }
      }
    },
    "/agents.md": {
      "get": {
        "operationId": "getAgentInstructions",
        "tags": [
          "agents",
          "discovery"
        ],
        "summary": "Agent instructions in Markdown",
        "description": "Canonical agent-facing description of the store: which protocols it speaks, the typical agent flow and the rules agents must respect. Mirrored at `/llms.txt` and `/llms-full.txt`. Store-specific 'when to use this store' guidance lives at `/agent-instructions.md`.",
        "security": [],
        "responses": {
          "200": {
            "description": "Markdown document.",
            "content": {
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/agent-instructions.md": {
      "get": {
        "operationId": "getWhenToUseGuidance",
        "tags": [
          "agents",
          "discovery"
        ],
        "summary": "When to use this store, and how to call it",
        "description": "Store-specific guidance for agents: the shopping jobs this store is the right answer to, the jobs it is the wrong answer to, and the shortest call sequence for each. Served with `Content-Type: text/markdown` after a single redirect — follow redirects.",
        "security": [],
        "responses": {
          "200": {
            "description": "Markdown document.",
            "content": {
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/openapi.json": {
      "get": {
        "operationId": "getOpenApiDocument",
        "tags": [
          "discovery"
        ],
        "summary": "This document",
        "description": "Returns this OpenAPI 3.1 specification. Served with `Content-Type: application/json` after a single redirect to the versioned asset URL — follow redirects.",
        "security": [],
        "responses": {
          "200": {
            "description": "The OpenAPI document.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/sitemap.xml": {
      "get": {
        "operationId": "getSitemapIndex",
        "tags": [
          "discovery"
        ],
        "summary": "Sitemap index",
        "description": "Index of the product, collection, page and blog sitemaps, plus `sitemap_agentic_discovery.xml`, which points at the agent instruction documents.",
        "security": [],
        "responses": {
          "200": {
            "description": "Sitemap index XML.",
            "content": {
              "application/xml": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "storefrontAccessToken": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Shopify-Storefront-Access-Token",
        "description": "Storefront API access token. **Not required** for the public read operations in this document — this store serves them unauthenticated. A token is only needed for customer-account and checkout mutations. Tokens are minted with the named scopes listed in `x-scopes`; request the narrowest set that covers your use case.",
        "x-scopes": {
          "unauthenticated_read_product_listings": "Read products, variants, prices and availability.",
          "unauthenticated_read_product_inventory": "Read per-variant inventory levels.",
          "unauthenticated_read_product_tags": "Read product tags.",
          "unauthenticated_read_collection_listings": "Read collections and their membership.",
          "unauthenticated_read_content": "Read pages, blogs and articles.",
          "unauthenticated_read_selling_plans": "Read subscription and selling-plan data.",
          "unauthenticated_write_checkouts": "Create and modify checkouts. Completion still requires buyer approval.",
          "unauthenticated_read_checkouts": "Read checkouts the caller created.",
          "unauthenticated_write_customers": "Create customer accounts and start password recovery.",
          "unauthenticated_read_customers": "Read the signed-in customer's own record."
        }
      },
      "shopifyOAuth": {
        "type": "oauth2",
        "description": "OAuth 2.0 authorization-code flow for the Shopify Admin API. Applies only to the Admin surface on `https://ey9jpt-yd.myshopify.com/admin/api/{version}/graphql.json`, which is **not** part of the public API documented above. Request the least-privilege subset of the scopes below; the merchant approves them explicitly at install time.",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://ey9jpt-yd.myshopify.com/admin/oauth/authorize",
            "tokenUrl": "https://ey9jpt-yd.myshopify.com/admin/oauth/access_token",
            "refreshUrl": "https://ey9jpt-yd.myshopify.com/admin/oauth/access_token",
            "scopes": {
              "read_products": "Read products, variants and collections.",
              "write_products": "Create and update products, variants and collections.",
              "read_product_listings": "Read the published product catalog.",
              "read_inventory": "Read inventory levels per location.",
              "write_inventory": "Adjust inventory levels per location.",
              "read_orders": "Read orders and their fulfillment state.",
              "write_orders": "Create and update orders.",
              "read_customers": "Read customer records.",
              "read_locations": "Read the store's physical locations.",
              "read_content": "Read pages, blogs and articles.",
              "write_content": "Create and update pages, blogs and articles.",
              "read_themes": "Read theme files.",
              "write_themes": "Write theme files.",
              "read_discounts": "Read discounts and price rules.",
              "read_shipping": "Read shipping zones and rates."
            }
          }
        }
      }
    },
    "headers": {
      "JsonContentType": {
        "description": "Always `application/json; charset=utf-8`.",
        "schema": {
          "type": "string"
        }
      },
      "RetryAfter": {
        "description": "Seconds to wait before retrying.",
        "schema": {
          "type": "integer",
          "minimum": 1
        }
      }
    },
    "parameters": {
      "ProductHandle": {
        "name": "handle",
        "in": "path",
        "required": true,
        "description": "URL handle of the product, e.g. `falda-1`. Handles are listed in `/sitemap_products_1.xml`.",
        "schema": {
          "type": "string",
          "pattern": "^[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$",
          "examples": [
            "falda-1"
          ]
        }
      },
      "CollectionHandle": {
        "name": "handle",
        "in": "path",
        "required": true,
        "description": "URL handle of the collection, e.g. `faldas`, `vestidos`, or the reserved handle `all`.",
        "schema": {
          "type": "string",
          "pattern": "^[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$",
          "examples": [
            "all",
            "faldas",
            "vestidos"
          ]
        }
      },
      "Limit": {
        "name": "limit",
        "in": "query",
        "required": false,
        "description": "Products per page.",
        "schema": {
          "type": "integer",
          "minimum": 1,
          "maximum": 250,
          "default": 30
        }
      },
      "Page": {
        "name": "page",
        "in": "query",
        "required": false,
        "description": "1-based page number.",
        "schema": {
          "type": "integer",
          "minimum": 1,
          "default": 1
        }
      }
    },
    "responses": {
      "NotFoundJson": {
        "description": "No such resource. The status line is a real `404` and the `Content-Type` is `application/json`; the body may be empty.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/CartError"
            }
          }
        }
      },
      "CartUnprocessable": {
        "description": "The cart operation was rejected — unknown variant, sold out, or quantity above available stock.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/CartError"
            },
            "examples": {
              "unknownVariant": {
                "summary": "Variant id does not exist",
                "value": {
                  "status": 422,
                  "message": "Cart Error",
                  "description": "Cannot find variant"
                }
              }
            }
          }
        }
      },
      "RateLimited": {
        "description": "Too many requests. Back off exponentially and honour `Retry-After`.",
        "headers": {
          "Retry-After": {
            "$ref": "#/components/headers/RetryAfter"
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/CartError"
            }
          }
        }
      },
      "StoreUnavailable": {
        "description": "The store is password-protected or temporarily unavailable.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/CartError"
            }
          }
        }
      },
      "GraphQLThrottled": {
        "description": "Query cost exceeded the leaky bucket. Read extensions.cost.throttleStatus, wait for the bucket to refill, and retry.",
        "headers": {
          "Retry-After": {
            "$ref": "#/components/headers/RetryAfter"
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/GraphQLErrorResponse"
            },
            "examples": {
              "throttled": {
                "summary": "Throttled",
                "value": {
                  "errors": [
                    {
                      "message": "Throttled",
                      "extensions": {
                        "code": "THROTTLED"
                      }
                    }
                  ]
                }
              }
            }
          }
        }
      }
    },
    "schemas": {
      "CartError": {
        "type": "object",
        "title": "CartError",
        "description": "Structured error envelope returned by the cart and JSON endpoints.",
        "properties": {
          "status": {
            "type": "integer",
            "description": "HTTP status, repeated in the body.",
            "examples": [
              422
            ]
          },
          "message": {
            "type": "string",
            "description": "Short, stable error class.",
            "examples": [
              "Cart Error"
            ]
          },
          "description": {
            "type": "string",
            "description": "Human-readable explanation and the resolution hint.",
            "examples": [
              "Cannot find variant"
            ]
          }
        },
        "additionalProperties": true
      },
      "GraphQLRequest": {
        "type": "object",
        "title": "GraphQLRequest",
        "required": [
          "query"
        ],
        "properties": {
          "query": {
            "type": "string",
            "description": "GraphQL document."
          },
          "variables": {
            "type": [
              "object",
              "null"
            ],
            "description": "Variable values.",
            "additionalProperties": true
          },
          "operationName": {
            "type": [
              "string",
              "null"
            ],
            "description": "Operation to run when the document holds several."
          }
        },
        "additionalProperties": false
      },
      "GraphQLError": {
        "type": "object",
        "title": "GraphQLError",
        "required": [
          "message"
        ],
        "properties": {
          "message": {
            "type": "string"
          },
          "locations": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "line": {
                  "type": "integer"
                },
                "column": {
                  "type": "integer"
                }
              }
            }
          },
          "path": {
            "type": "array",
            "items": {
              "type": [
                "string",
                "integer"
              ]
            }
          },
          "extensions": {
            "type": "object",
            "description": "Machine-readable error detail. `code` is the field to branch on.",
            "properties": {
              "code": {
                "type": "string",
                "examples": [
                  "undefinedField",
                  "THROTTLED"
                ]
              },
              "typeName": {
                "type": "string"
              },
              "fieldName": {
                "type": "string"
              }
            },
            "additionalProperties": true
          }
        }
      },
      "GraphQLErrorResponse": {
        "type": "object",
        "title": "GraphQLErrorResponse",
        "required": [
          "errors"
        ],
        "properties": {
          "errors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/GraphQLError"
            }
          }
        }
      },
      "GraphQLResponse": {
        "type": "object",
        "title": "GraphQLResponse",
        "properties": {
          "data": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          },
          "errors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/GraphQLError"
            }
          },
          "extensions": {
            "type": "object",
            "description": "Cost accounting for rate limiting.",
            "properties": {
              "cost": {
                "type": "object",
                "properties": {
                  "requestedQueryCost": {
                    "type": "number"
                  },
                  "actualQueryCost": {
                    "type": "number"
                  },
                  "throttleStatus": {
                    "type": "object",
                    "properties": {
                      "maximumAvailable": {
                        "type": "number"
                      },
                      "currentlyAvailable": {
                        "type": "number"
                      },
                      "restoreRate": {
                        "type": "number"
                      }
                    }
                  }
                }
              }
            },
            "additionalProperties": true
          }
        }
      },
      "ProductImage": {
        "type": "object",
        "title": "ProductImage",
        "properties": {
          "id": {
            "type": "integer",
            "format": "int64"
          },
          "src": {
            "type": "string",
            "format": "uri"
          },
          "alt": {
            "type": [
              "string",
              "null"
            ]
          },
          "width": {
            "type": "integer"
          },
          "height": {
            "type": "integer"
          },
          "position": {
            "type": "integer"
          },
          "variant_ids": {
            "type": "array",
            "items": {
              "type": "integer",
              "format": "int64"
            }
          }
        }
      },
      "ProductVariant": {
        "type": "object",
        "title": "ProductVariant",
        "description": "A single purchasable variant. `id` is the value to send to `addCartItems`.",
        "properties": {
          "id": {
            "type": "integer",
            "format": "int64",
            "description": "Variant id — the value `addCartItems` expects."
          },
          "title": {
            "type": "string",
            "description": "Combined option values, e.g. `Azul / 12`."
          },
          "sku": {
            "type": [
              "string",
              "null"
            ]
          },
          "price": {
            "type": "string",
            "description": "Decimal string in the store currency (COP)."
          },
          "compare_at_price": {
            "type": [
              "string",
              "null"
            ]
          },
          "available": {
            "type": "boolean"
          },
          "option1": {
            "type": [
              "string",
              "null"
            ]
          },
          "option2": {
            "type": [
              "string",
              "null"
            ]
          },
          "option3": {
            "type": [
              "string",
              "null"
            ]
          },
          "requires_shipping": {
            "type": "boolean"
          },
          "taxable": {
            "type": "boolean"
          },
          "featured_image": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ProductImage"
              },
              {
                "type": "null"
              }
            ]
          }
        }
      },
      "Product": {
        "type": "object",
        "title": "Product",
        "properties": {
          "id": {
            "type": "integer",
            "format": "int64"
          },
          "title": {
            "type": "string"
          },
          "handle": {
            "type": "string",
            "description": "URL segment under `/products/`."
          },
          "body_html": {
            "type": "string",
            "description": "Product description as HTML."
          },
          "vendor": {
            "type": "string"
          },
          "product_type": {
            "type": "string"
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "published_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "created_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          },
          "variants": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductVariant"
            }
          },
          "images": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductImage"
            }
          },
          "options": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string"
                },
                "position": {
                  "type": "integer"
                },
                "values": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              }
            }
          }
        }
      },
      "SuggestResponse": {
        "type": "object",
        "title": "SuggestResponse",
        "properties": {
          "resources": {
            "type": "object",
            "properties": {
              "results": {
                "type": "object",
                "properties": {
                  "products": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/SuggestProduct"
                    }
                  },
                  "collections": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "additionalProperties": true
                    }
                  },
                  "pages": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "additionalProperties": true
                    }
                  }
                }
              }
            }
          }
        }
      },
      "SuggestProduct": {
        "type": "object",
        "title": "SuggestProduct",
        "properties": {
          "title": {
            "type": "string"
          },
          "handle": {
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "price": {
            "type": "string"
          },
          "available": {
            "type": "boolean"
          },
          "image": {
            "type": [
              "string",
              "null"
            ]
          },
          "body": {
            "type": "string"
          }
        }
      },
      "CartLineItem": {
        "type": "object",
        "title": "CartLineItem",
        "properties": {
          "id": {
            "type": "integer",
            "format": "int64",
            "description": "Variant id of this line."
          },
          "key": {
            "type": "string",
            "description": "Stable line key; usable as `id` in `changeCartLine`."
          },
          "title": {
            "type": "string"
          },
          "quantity": {
            "type": "integer",
            "minimum": 0
          },
          "price": {
            "type": "integer",
            "description": "Unit price in cents of the store currency (COP)."
          },
          "line_price": {
            "type": "integer"
          },
          "final_line_price": {
            "type": "integer"
          },
          "variant_title": {
            "type": [
              "string",
              "null"
            ]
          },
          "product_title": {
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "image": {
            "type": [
              "string",
              "null"
            ]
          },
          "properties": {
            "type": [
              "object",
              "null"
            ],
            "additionalProperties": true
          }
        }
      },
      "Cart": {
        "type": "object",
        "title": "Cart",
        "properties": {
          "token": {
            "type": "string",
            "description": "Cart token, bound to the `cart` cookie."
          },
          "note": {
            "type": [
              "string",
              "null"
            ]
          },
          "attributes": {
            "type": "object",
            "additionalProperties": true
          },
          "item_count": {
            "type": "integer"
          },
          "total_price": {
            "type": "integer",
            "description": "Total in cents of the store currency (COP)."
          },
          "total_discount": {
            "type": "integer"
          },
          "original_total_price": {
            "type": "integer"
          },
          "currency": {
            "type": "string",
            "examples": [
              "COP"
            ]
          },
          "requires_shipping": {
            "type": "boolean"
          },
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CartLineItem"
            }
          }
        }
      },
      "CartAddRequest": {
        "type": "object",
        "title": "CartAddRequest",
        "required": [
          "items"
        ],
        "properties": {
          "items": {
            "type": "array",
            "minItems": 1,
            "items": {
              "type": "object",
              "required": [
                "id",
                "quantity"
              ],
              "properties": {
                "id": {
                  "type": "integer",
                  "format": "int64",
                  "description": "Variant id."
                },
                "quantity": {
                  "type": "integer",
                  "minimum": 1
                },
                "properties": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "string"
                  }
                }
              }
            }
          }
        },
        "additionalProperties": false
      },
      "CartAddResponse": {
        "type": "object",
        "title": "CartAddResponse",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CartLineItem"
            }
          }
        },
        "additionalProperties": true
      },
      "CartChangeRequest": {
        "type": "object",
        "title": "CartChangeRequest",
        "description": "Provide exactly one of `line` or `id`.",
        "properties": {
          "line": {
            "type": "integer",
            "minimum": 1,
            "description": "1-based line index."
          },
          "id": {
            "type": "string",
            "description": "Line key from `CartLineItem.key`."
          },
          "quantity": {
            "type": "integer",
            "minimum": 0,
            "description": "New quantity; `0` removes the line."
          },
          "properties": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          }
        },
        "anyOf": [
          {
            "required": [
              "line"
            ]
          },
          {
            "required": [
              "id"
            ]
          }
        ],
        "additionalProperties": false
      },
      "CartUpdateRequest": {
        "type": "object",
        "title": "CartUpdateRequest",
        "properties": {
          "note": {
            "type": "string"
          },
          "attributes": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "updates": {
            "type": "object",
            "description": "Map of variant id (as a string) to the desired quantity.",
            "additionalProperties": {
              "type": "integer",
              "minimum": 0
            }
          }
        },
        "additionalProperties": false
      },
      "JsonRpcRequest": {
        "type": "object",
        "title": "JsonRpcRequest",
        "required": [
          "jsonrpc",
          "method"
        ],
        "properties": {
          "jsonrpc": {
            "const": "2.0"
          },
          "id": {
            "type": [
              "string",
              "integer"
            ]
          },
          "method": {
            "type": "string",
            "examples": [
              "initialize",
              "tools/list",
              "tools/call",
              "resources/list"
            ]
          },
          "params": {
            "type": "object",
            "additionalProperties": true
          }
        },
        "additionalProperties": false
      },
      "JsonRpcResponse": {
        "type": "object",
        "title": "JsonRpcResponse",
        "required": [
          "jsonrpc"
        ],
        "properties": {
          "jsonrpc": {
            "const": "2.0"
          },
          "id": {
            "type": [
              "string",
              "integer",
              "null"
            ]
          },
          "result": {
            "type": "object",
            "additionalProperties": true
          }
        }
      },
      "JsonRpcErrorResponse": {
        "type": "object",
        "title": "JsonRpcErrorResponse",
        "required": [
          "jsonrpc",
          "error"
        ],
        "properties": {
          "jsonrpc": {
            "const": "2.0"
          },
          "id": {
            "type": [
              "string",
              "integer",
              "null"
            ]
          },
          "error": {
            "type": "object",
            "required": [
              "code",
              "message"
            ],
            "properties": {
              "code": {
                "type": "integer",
                "description": "JSON-RPC error code."
              },
              "message": {
                "type": "string"
              },
              "data": {
                "type": "object",
                "additionalProperties": true
              }
            }
          }
        }
      },
      "UcpProfile": {
        "type": "object",
        "title": "UcpProfile",
        "properties": {
          "ucp": {
            "type": "object",
            "properties": {
              "version": {
                "type": "string"
              },
              "supported_versions": {
                "type": "object",
                "additionalProperties": {
                  "type": "string",
                  "format": "uri"
                }
              },
              "services": {
                "type": "object",
                "additionalProperties": true
              },
              "capabilities": {
                "type": "object",
                "additionalProperties": true
              },
              "payment_handlers": {
                "type": "object",
                "additionalProperties": true
              }
            }
          }
        }
      }
    }
  }
}
