{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/datafiniti/json-schema/datafiniti-search-products-request-schema.json",
  "title": "SearchProductsRequest",
  "x-generated": "2026-11-20",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/datafiniti-products-api-openapi.yml#/components/schemas/SearchProductsRequest",
  "type": "object",
  "properties": {
    "query": {
      "type": "string",
      "description": "The search query using Datafiniti query syntax (e.g., `keys:*`, `country:US AND province:FL`)"
    },
    "num_records": {
      "type": "integer",
      "description": "The number of records your request will return, and the number of credits that will be deducted from your account. For non-downloads, the maximum is 10 records."
    },
    "format": {
      "type": "string",
      "description": "Must be either `json` or `csv`. Defaults to `json`.",
      "enum": [
        "json",
        "csv"
      ]
    },
    "download": {
      "type": "boolean",
      "description": "Whether or not to start a download for this search."
    },
    "view": {
      "type": "string",
      "description": "Specify a view you have created, or use a pre-made view. The view filters what data is displayed in your search results. This allows you to dynamically specify a view to filter the data you get back from your search."
    }
  },
  "required": [
    "query"
  ]
}