> ## Documentation Index
> Fetch the complete documentation index at: https://docs.querying.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Lista de países

> Os códigos de país que um mecanismo aceita, tirados das mesmas regras que validam o envio. Filtre com ?model=.

Sem `model`, o endpoint devolve todos os códigos ISO 3166-1 alpha-2 atribuídos. Com `model`, devolve apenas os países que aquele mecanismo aceita, então um seletor montado com esta lista não oferece uma combinação que o envio recusa com `422 REGION_UNSUPPORTED`.

`COMMERCE_SERP` e `COMMERCE_PRODUCT` devolvem os países de todas as suas lojas. Cada loja atende um só país, então envie o `site` ou a URL de produto que corresponde ao país escolhido; outra combinação devolve `422 REGION_UNSUPPORTED`.

Aceita os nomes de provedor da Cloro além dos nossos taskTypes. `aioverview` e `GOOGLE` nomeiam o mecanismo de AI Overviews; `google` e `GOOGLE_SERP`, o de busca. Um mecanismo que não vendemos devolve `400 VALIDATION_ERROR`.

A lista muda raramente, então busque no start-up e guarde por 24 horas ou mais. A resposta é o array puro, como na Cloro, com `Cache-Control: public, max-age=3600`.


## OpenAPI

````yaml GET /v1/countries
openapi: 3.1.0
info:
  title: querying.ai
  description: >-
    One API for every AI answer engine. Every task is asynchronous: submit, then
    collect the result via webhook or polling.
  version: 1.0.0
servers:
  - url: https://api.querying.ai
    description: Production
security:
  - bearerAuth: []
paths:
  /v1/countries:
    get:
      tags:
        - Operations
      summary: List of countries
      description: >-
        The ISO 3166-1 alpha-2 codes one engine accepts, and every assigned code
        when no model is named. Read it at start-up and cache it: the list
        changes rarely. Filtering follows the same rules that validate a
        submission, so a country from this list passes submit. COMMERCE_SERP and
        COMMERCE_PRODUCT list the countries of all their storefronts, and each
        storefront serves one country, so the `site` or product URL must belong
        to the country sent. A model we do not sell returns 400. The response is
        a bare array, as in Cloro, so a client that moves over parses it
        unchanged.
      operationId: getCountries
      parameters:
        - name: model
          in: query
          required: false
          description: >-
            One engine. Cloro's provider names are accepted alongside our
            taskTypes: `aioverview` and `GOOGLE` are the AI Overviews engine,
            `google` and `GOOGLE_SERP` the search one. Aliases such as
            `bing_copilot_search` work too.
          schema:
            type: string
            examples:
              - aioverview
              - aimode
              - bing_aimode
              - chatgpt
              - gemini
              - google
              - perplexity
          example: bing_aimode
      responses:
        '200':
          description: Country codes, ascending.
          headers:
            Cache-Control:
              schema:
                type: string
                example: public, max-age=3600
          content:
            application/json:
              schema:
                type: array
                items:
                  type: string
                  example: US
              example:
                - AE
                - AU
                - BR
                - CA
                - DE
                - EE
                - ES
                - FR
                - GB
                - HK
                - HU
                - IE
                - IN
                - IT
                - JP
                - MX
                - NL
                - PL
                - PT
                - RO
                - RS
                - SE
                - SG
                - SK
                - TR
                - US
                - ZA
        '400':
          description: '`model` is not an engine we sell.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                success: false
                error:
                  code: VALIDATION_ERROR
                  message: Request validation failed
                  details:
                    - field: model
                      message: '''grok'' is not a model we serve; use one of ...'
                  timestamp: '2026-11-10T02:00:00.000Z'
      security: []
components:
  schemas:
    ErrorResponse:
      type: object
      required:
        - success
        - error
      properties:
        success:
          type: boolean
          const: false
        error:
          $ref: '#/components/schemas/ErrorDetail'
    ErrorDetail:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
          description: Stable, safe to branch on. See the Errors guide for the full list.
        message:
          type: string
          description: For humans. May change.
        details:
          description: >-
            Context for the error. An array of `{field, message}` on most
            `VALIDATION_ERROR`s; an object elsewhere (for example `{id}` on
            `RESOURCE_NOT_FOUND`, `retryAfterSec` on 429 and 503 codes). Omitted
            when there is nothing to add.
          oneOf:
            - type: array
              items:
                type: object
                properties:
                  field:
                    type: string
                  message:
                    type: string
            - type: object
              additionalProperties: true
        timestamp:
          type: string
          format: date-time
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Your API key, sent as `Authorization: Bearer <key>`.'

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.