Fetch the complete documentation index at: https://docs.tcgplayer.com/llms.txt. Use this file to discover all available pages before exploring further.

# Search Category Products

This endpoint returns an array of product Ids that match the provided search critera.
Use the search manifest from the GET /catalog/categories/{categoryId}/search/manifest
endpoint to build requests to this endpoint.  If an invalid filter name is specified
in the request, it will be ignored.  Use the GET /catalog/products/{productIds}
endpoint to get the details about the returned product Ids.

[block:callout]
{
  "type": "info",
  "title": "Application Performance Note",
  "body": "While this endpoint can be super useful for searching for specific products, the highest performance for end users involves caching a local database and writing searches that work on a local database."
}
[/block]

[block:code]
{
  "codes": [
    {
      "code": "{\n  \"sort\": \"string\",\n  \"limit\": 0,\n  \"offset\": 0,\n  \"filters\": [\n    {\n      \"name\": \"string\",\n      \"values\": [\n        \"string\"\n      ]\n    }\n  ]\n}",
      "language": "json",
      "name": "Body Template"
    },
    {
      "code": "{\n  \"totalItems\": 0,\n  \"success\": true,\n  \"errors\": [\n    \"string\"\n  ],\n  \"results\": [\n    0\n  ]\n}",
      "language": "json",
      "name": "Response Template"
    },
    {
      "code": "/catalog/categories/24/search\n\nHeaders:\nAuthorization | {{bearerToken}}\nContent-Type | application/json\n\nBody:\n{\n\t\"sort\": \"MinPrice DESC\",\n\t\"limit\": 10,\n\t\"offset\": 0,\n\t\"filters\": [\n\t\t{\n\t\t\t\"name\": \"ProductName\",\n\t\t\t\"values\": [ \"Aerith\"]\n\t\t},\n\t\t{\n\t\t\t\"name\": \"Rarity\",\n\t\t\t\"values\": [ \"Rare\", \"Legend\", \"Hero\", \"Promo\" ]\n\t\t},\n\t\t{\n\t\t\t\"name\": \"Category\",\n\t\t\t\"values\": [ \"VII\"]\n\t\t}\n\t]\n}\n\nResponse:\n{\n    \"totalItems\": 2,\n    \"success\": true,\n    \"errors\": [],\n    \"results\": [\n        137942,\n        132438\n    ]\n}",
      "language": "json",
      "name": "Example Response #1"
    }
  ]
}
[/block]

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "version": "v1.39.0",
    "title": "TcgApi"
  },
  "paths": {
    "/catalog/categories/{categoryId}/search": {
      "post": {
        "tags": [
          "Catalog"
        ],
        "summary": "Search Category Products",
        "description": "This endpoint returns an array of product Ids that match the provided search critera.\r\nUse the search manifest from the GET /catalog/categories/{categoryId}/search/manifest\r\nendpoint to build requests to this endpoint.  If an invalid filter name is specified\r\nin the request, it will be ignored.  Use the GET /catalog/products/{productIds}\r\nendpoint to get the details about the returned product Ids.",
        "operationId": "Catalog_SearchCategory",
        "parameters": [
          {
            "name": "categoryId",
            "in": "path",
            "description": "The Id of the category to search.",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "requestBody": {
          "$ref": "#/components/requestBodies/TcgApiModel.Catalog.CategorySearchCriteria"
        },
        "responses": {
          "200": {
            "description": "Search completed and results returned.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TcgApiModel.Common.AggregatedPagedApiResult_System.Int64_"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TcgApiModel.Common.AggregatedPagedApiResult_System.Int64_"
                }
              }
            }
          },
          "400": {
            "description": "CategoryId is less than or equal to 0, offset is less than 0, limit is less than or\r\nequal to 0, or duplicate filters provided."
          },
          "404": {
            "description": "CategoryId could not be found."
          }
        }
      }
    }
  },
  "servers": [
    {
      "url": "https://api.tcgplayer.com"
    }
  ],
  "components": {
    "requestBodies": {
      "TcgApiModel.Catalog.CategorySearchCriteria": {
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/TcgApiModel.Catalog.CategorySearchCriteria"
            }
          },
          "text/json": {
            "schema": {
              "$ref": "#/components/schemas/TcgApiModel.Catalog.CategorySearchCriteria"
            }
          },
          "application/x-www-form-urlencoded": {
            "schema": {
              "$ref": "#/components/schemas/TcgApiModel.Catalog.CategorySearchCriteria"
            }
          }
        },
        "description": "A collection of search parameters (i.e. filters and sorting).",
        "required": true
      }
    },
    "schemas": {
      "TcgApiModel.Catalog.CategorySearchCriteria": {
        "type": "object",
        "properties": {
          "offset": {
            "format": "int32",
            "type": "integer"
          },
          "limit": {
            "format": "int32",
            "type": "integer"
          },
          "sort": {
            "type": "string"
          },
          "includeAggregates": {
            "type": "boolean"
          },
          "filters": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TcgApiModel.Catalog.CategorySearchCriteria.Filter"
            }
          }
        }
      },
      "TcgApiModel.Catalog.CategorySearchCriteria.Filter": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "values": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "TcgApiModel.Common.Aggregate": {
        "type": "object",
        "properties": {
          "filterName": {
            "type": "string"
          },
          "values": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TcgApiModel.Common.AggregateItem"
            }
          }
        }
      },
      "TcgApiModel.Common.AggregateItem": {
        "type": "object",
        "properties": {
          "value": {
            "type": "string"
          },
          "count": {
            "format": "int64",
            "type": "integer"
          }
        }
      },
      "TcgApiModel.Common.AggregatedPagedApiResult_System.Int64_": {
        "type": "object",
        "properties": {
          "aggregates": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TcgApiModel.Common.Aggregate"
            }
          },
          "totalItems": {
            "format": "int32",
            "type": "integer"
          },
          "success": {
            "type": "boolean"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "results": {
            "type": "array",
            "items": {
              "format": "int64",
              "type": "integer"
            }
          }
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "_id": {
    "buffer": {
      "0": 94,
      "1": 217,
      "2": 152,
      "3": 86,
      "4": 78,
      "5": 118,
      "6": 200,
      "7": 0,
      "8": 17,
      "9": 105,
      "10": 157,
      "11": 192
    }
  }
}
```