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

# Get a query

> A query of another project answers 404.



## OpenAPI

````yaml https://api.mentionlab.io/api/docs/v2-json get /api/v2/projects/{projectId}/queries/{queryId}
openapi: 3.0.0
info:
  title: MentionLab Public API v2
  description: ''
  version: 0.6.48
  contact: {}
servers:
  - url: https://api.mentionlab.io
security: []
tags: []
paths:
  /api/v2/projects/{projectId}/queries/{queryId}:
    get:
      tags:
        - Queries
      summary: Get a query
      description: A query of another project answers 404.
      operationId: QueriesV2Controller_get_v2
      parameters:
        - name: queryId
          required: true
          in: path
          description: Id of the query
          schema:
            type: string
            format: uuid
        - name: x-project-id
          in: header
          description: Project ID to specify the project context
          required: true
          schema:
            type: string
        - name: projectId
          required: true
          in: path
          schema:
            format: uuid
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/QueryV2Response'
        '400':
          description: >-
            The request failed validation: the body, query or path parameters
            are malformed or out of range.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorResponse'
        '401':
          description: The request is missing valid authentication credentials.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorResponse'
        '403':
          description: >-
            The authenticated principal lacks the required permission, or access
            to the requested organisation/project.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorResponse'
        '404':
          description: No such query in the project
components:
  schemas:
    QueryV2Response:
      type: object
      properties:
        id:
          type: string
          format: uuid
          description: Id of the query, as used on every per-query route
        query:
          type: string
          example: best running shoes
          description: The query text sent to the engines, exactly as it is run
        language:
          type: string
          description: >-
            Language the query is written in, as a language code of the
            reference locales
          example: en
        country:
          type: string
          example: US
          description: >-
            Market the query is run for, as a country code of the reference
            locales
        type:
          nullable: true
          description: How the query is classified; null when it is not
          allOf:
            - $ref: '#/components/schemas/QueryType'
        tags:
          description: Tags linked to the query; empty when it carries none
          type: array
          items:
            $ref: '#/components/schemas/QueryTagV2'
        recurrenceSetting:
          nullable: true
          description: The schedule that runs it, if any
          type: object
          allOf:
            - $ref: '#/components/schemas/QueryRecurrenceSettingV2'
        updatedAt:
          type: string
          format: date-time
          description: >-
            When the query or its tags last changed, as an ISO 8601 instant in
            UTC
      required:
        - id
        - query
        - language
        - country
        - type
        - tags
        - recurrenceSetting
        - updatedAt
    ApiErrorResponse:
      type: object
      properties:
        statusCode:
          type: number
          description: HTTP status code of the error.
          example: 400
        message:
          type: string
          description: >-
            Human-readable description of the error. Validation failures return
            an array of per-field validation errors instead of a single string.
          example: Validation failed
        error:
          type: string
          description: Short name of the HTTP error.
          example: Bad Request
      required:
        - statusCode
    QueryType:
      type: string
      enum:
        - comparative
        - informative
        - perception
      description: >-
        The type of question the query asks: "comparative" (compares options),
        "informative" (seeks facts or how-to information) or "perception"
        (probes opinions about a brand).
    QueryTagV2:
      type: object
      properties:
        id:
          type: number
          description: Id of the tag, used to link or unlink it on a query
          example: 12
        name:
          type: string
          description: Label of the tag, unique within the project
          example: Branded
        color:
          type: string
          description: 'Colour of the tag, as a #rrggbb hex string'
          example: '#3b82f6'
      required:
        - id
        - name
        - color
    QueryRecurrenceSettingV2:
      type: object
      properties:
        id:
          type: string
          format: uuid
          description: Id of the schedule, as used on the recurrence-settings routes
          example: 018f3a2b-7c4d-7e91-b3f5-2a6c8d0e1f42
        name:
          type: string
          description: Label the schedule is listed under, usually its cadence
          example: Weekly
      required:
        - id
        - name

````

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