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

# Get the query rewrite status

> Check the status of any instances of a specific query rewrite type, such as rules or spell correction.



## OpenAPI

````yaml /api-reference/5.9/fusion-api-query.json get /query-rewrite/{type}
openapi: 3.0.1
info:
  title: Fusion Query API
  description: >-
    A Lucidworks Fusion microservice for machine-learning-enhanced ranking and
    retrieval.
  contact:
    name: Lucidworks
    url: www.lucidworks.com
    email: support@lucidworks.com
  license:
    name: License of API
    url: https://lucidworks.com/legal/developer-license-agreement/
  version: '5.9'
servers:
  - url: https://{FUSION HOST}/api
    description: Fusion
    variables:
      FUSION HOST:
        default: FUSION_HOST
        description: Your environment host.
  - url: https://{FUSION HOST}/api/apps/{APP_NAME}
    description: Fusion app
    variables:
      FUSION HOST:
        default: FUSION_HOST
        description: Your environment host.
      APP_NAME:
        default: APP_NAME
        description: The name of your Fusion app.
security:
  - Basic auth: []
  - API key: []
tags:
  - name: Custom Rule Type API
    description: Endpoints to define and manage custom rule type definitions.
  - name: Experiments API
    description: >-
      Use the Experiments API to compare different configuration variants and
      determine which ones are most successful.
  - name: Query Pipelines API
    description: >-
      Use these endpoints to view and manage your query pipelines.  You can also
      send queries using this API, though the Query Profiles API is recommended
      instead.
  - name: Query Profiles API
    description: >-
      The Query Profiles API provides static endpoints that you can consistently
      point to when querying your collections.  Query profiles allow you to
      change the query pipelines or collections behind them without changing the
      endpoint you use for your search queries.  See the Query Profiles CRUD API
      for endpoints that create and modify query profiles.
  - name: Query Profiles CRUD API
    description: >-
      Use these endpoints to create and modify query profiles.  Query profiles
      allow you to change the query pipelines or collections behind them without
      changing the endpoint you use for your search queries.  See the Query
      Profiles API for the query endpoints.
  - name: Query Rewrite API
    description: >-
      The Query Rewrite API manages documents used for query rewriting to
      improve relevancy using AI-generated data. Primarily for internal use.
  - name: Query Stage API
    description: >-
      Use these endpoints to view the available query pipeline stages and their
      configuration parameters.
  - name: Query Stage Plugins API
    description: >-
      Use these endpoints to view, install, and manage custom query stages
      developed with the Query Stage SDK.
  - name: Signal Indexing API
    description: Endpoints to index signals.
  - name: Experience Manager API
    description: API only for internal use by the Experience Manager Springboard system
  - name: Query Pipeline Template API
    description: Used internally to generate query pipelines from a template.
externalDocs:
  description: Lucidworks Documentation.
  url: https://doc.lucidworks.com/
paths:
  /query-rewrite/{type}:
    get:
      tags:
        - Query Rewrite API
      summary: Get the query rewrite status
      description: >-
        Check the status of any instances of a specific query rewrite type, such
        as rules or spell correction.
      operationId: getQueryRewriteTypeStatus
      parameters:
        - name: type
          description: >-
            The query rewrite type.  Use `/query-rewrite/instances` to get the
            types for your existing query rewrites, or `/query-rewrite/schema`
            to get all possible types.





            >In the Fusion UI, some of these types correspond to the rewrite
            types in the Rewrites Manager and others correspond to action types
            in the Rules Manager.
          in: path
          required: true
          schema:
            type: string
        - name: context
          description: >-
            The app to which this object belongs, as `app:SomeApp`. If the app
            doesn't exist, the request fails. Other comma-separated contexts in
            the `context` parameter are allowed but ignored.
          in: query
          required: true
          schema:
            type: string
          example: app:SomeApp
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/QueryRewriteTypeStatus'
components:
  schemas:
    QueryRewriteTypeStatus:
      type: object
      properties:
        app:
          description: The Fusion app to which this query rewrite belongs.
          type: string
        type:
          description: The query rewrite type.
          type: string
        enabled:
          description: '`true` if this query rewrite is enabled.'
          type: boolean
        numDeployed:
          description: The number of deployed (published) query rewrites of this type.
          type: integer
          format: int64
        collection:
          description: The data collection to which this query rewrite belongs.
          type: string
        job:
          description: 'The job type: `spark`, `datasource`, or `task`.'
          type: string
        lastDeployedOn:
          description: The date and time at which this query rewrite was last deployed.
          type: string
          format: date-time
        lastJobStatus:
          $ref: '#/components/schemas/JobRunView'
    JobRunView:
      type: object
      properties:
        resource:
          description: >-
            The resource ID, prefixed with the job type: `spark`, `datasource`,
            or `task`.
          type: string
          example: '`spark:api-test-app_synonym_detection`'
        runId:
          description: The job run ID.
          type: string
        startTime:
          description: The job run start time.
          type: string
          format: date-time
        endTime:
          description: The job run end time.
          type: string
          format: date-time
        status:
          description: The job run status.
          type: string
        error:
          description: A job run error, if any.
          type: object
          additionalProperties:
            type: object
        extra:
          description: Additional statistics about the job run.
          type: object
          additionalProperties:
            type: object
        startedBy:
          description: The username of the user who started the job.
          type: string
  securitySchemes:
    Basic auth:
      type: http
      scheme: basic
    API key:
      name: x-api-key
      type: apiKey
      in: header

````