{
  "openapi": "3.0.3",
  "info": {
    "title": "Gaming Wishlist – curated gift wishlist API",
    "version": "1.0.0",
    "description": "Create a gift wishlist for gamers (gaming gifts) in seconds from curated amazon.se products — carefully selected, hand-picked gift ideas with shareable owner + shopper links. Curated by us (no customer reviews or ratings). Keywords: gift ideas, wishlist, gift list, shopping list, presenttips, önskelista, gaming. Quickstart: POST /api/v1/agent/create-and-fill → shopUrl. Gaming wishlists, shopping lists, and gift recommendation lists with owner/shopper URLs and curated Amazon buy links. Pass marketplace + locale on every call. amazon.se product links include ?tag=sw-gaming-21; other storefronts stay untagged. Responses dual-write buyUrl (and legacy affiliateUrl for compatibility) and trackingTag (and legacy affiliateTag for compatibility). MCP: /api/mcp. Catalog: /api/v1/catalog."
  },
  "servers": [
    {
      "url": "https://gaming-wishlist.vercel.app"
    }
  ],
  "paths": {
    "/api/v1/health": {
      "get": {
        "summary": "Health",
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/search": {
      "get": {
        "summary": "Open Amazon gift search",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "platform",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "budgetBand",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "genre",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "default": 10
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Search results"
          }
        }
      }
    },
    "/api/v1/catalog": {
      "get": {
        "summary": "Curated starter catalog",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "platform",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "budgetBand",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "genre",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "genres",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Catalog items"
          }
        }
      }
    },
    "/api/v1/wishlists": {
      "post": {
        "summary": "Create wishlist",
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "gamerName": {
                    "type": "string"
                  },
                  "platform": {
                    "type": "string"
                  },
                  "budgetBand": {
                    "type": "string"
                  },
                  "genres": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "platforms": {
                    "type": "string"
                  },
                  "items": {
                    "type": "array",
                    "items": {
                      "type": "object"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Created (ownerUrl + shopUrl)"
          }
        }
      }
    },
    "/api/v1/wishlists/{id}": {
      "get": {
        "summary": "Get wishlist",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Wishlist"
          }
        }
      },
      "patch": {
        "summary": "Patch wishlist",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "X-Edit-Token",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Updated"
          }
        }
      }
    },
    "/api/v1/wishlists/{id}/items": {
      "post": {
        "summary": "Add item",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "X-Edit-Token",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Item added"
          }
        }
      }
    },
    "/api/v1/wishlists/{id}/items/{itemId}": {
      "delete": {
        "summary": "Delete item",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "itemId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "X-Edit-Token",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Deleted"
          }
        }
      }
    },
    "/api/v1/agent/create-and-fill": {
      "post": {
        "summary": "One-shot create + fill",
        "responses": {
          "201": {
            "description": "Created"
          }
        }
      }
    },
    "/api/v1/products/resolve": {
      "post": {
        "summary": "Resolve ASIN/URL/keywords to buy URL",
        "responses": {
          "200": {
            "description": "Resolved"
          }
        }
      }
    },
    "/api/cron/refresh-catalog": {
      "get": {
        "summary": "Weekly catalog refresh stub (Bearer CRON_SECRET)",
        "responses": {
          "200": {
            "description": "Stub status"
          }
        }
      }
    },
    "/api/mcp": {
      "post": {
        "summary": "MCP Streamable HTTP",
        "description": "Model Context Protocol endpoint. JSON-RPC initialize and tools/list/call.",
        "responses": {
          "200": {
            "description": "OK"
          },
          "406": {
            "description": "Protocol negotiation"
          }
        }
      }
    }
  }
}