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

# Search tasks

> Search tasks by name, description, or a substring.



## OpenAPI

````yaml /openapi-public.yml get /api/v1/search/tasks
openapi: 3.0.3
info:
  title: Blend API
  version: 1.0.0
  description: API for Blend
servers:
  - url: https://api.byblend.com
    description: Blend production server
security:
  - bearerAuth: []
tags:
  - name: Orders
    description: Order management endpoints
  - name: Patients
    description: Patient management endpoints
  - name: Reports
    description: Reporting endpoints
  - name: Products and Materials
    description: Product catalog and inventory endpoints
  - name: Electronic Prescriptions
    description: Electronic prescription management endpoints
  - name: Prescriptions
    description: Prescription management endpoints
  - name: Authentication
    description: Authentication endpoints
  - name: Notifications
    description: User management endpoints
  - name: Prescribers
paths:
  /api/v1/search/tasks:
    get:
      tags:
        - Search
      summary: Search tasks
      description: Search tasks by name, description, or a substring.
      parameters:
        - name: q
          in: query
          required: true
          description: Search query
          schema:
            type: string
            example: '"confirm shelf-stability"'
        - name: limit
          in: query
          required: false
          description: >-
            Optional limit on the number of results to return. Max is 100,
            default is 50.
          schema:
            type: integer
            example: 10
      responses:
        '200':
          description: Successful response with array of tasks
          content:
            application/json:
              schema:
                type: object
                properties:
                  results:
                    type: array
                    items:
                      allOf:
                        - $ref: '#/components/schemas/SearchRank'
                        - $ref: '#/components/schemas/TaskFull'
components:
  schemas:
    SearchRank:
      type: object
      properties:
        rank:
          type: number
          example: 0.7
          description: >-
            Ranking score of the search result, from 0 to 1, indicating
            relevance to the search query
    TaskFull:
      type: object
      properties:
        id:
          type: string
          example: 0227d1e5-ba9a-42b5-8fe2-38882aa65708
        assignee:
          $ref: '#/components/schemas/User'
        completed_at:
          type: string
          format: date-time
          example: '2025-02-01T20:10:43Z'
        created_at:
          type: string
          format: date-time
          example: '2025-01-01T00:00:00Z'
        created_by_id:
          type: string
          example: 0227d1e5-ba9a-42b5-8fe2-38882aa65708
        assignee_id:
          type: string
          example: 0227d1e5-ba9a-42b5-8fe2-38882aa65708
        name:
          type: string
          example: Confirm shelf-stability of recent batch
        description:
          type: string
          example: >-
            Please find the most recent batch (April 2, 2025) of the topical
            rapamycin and confirm shelf-stability given the new expiration date
            of May 14, 2025.
        category_code:
          type: string
          example: T01
        category_name:
          type: string
          example: Order
        status_code:
          type: string
          example: NEW
        status_name:
          type: string
          example: New
        order_id:
          type: string
          example: 0227d1e5-ba9a-42b5-8fe2-38882aa65708
        patient_id:
          type: string
          example: 0227d1e5-ba9a-42b5-8fe2-38882aa65708
        prescription_id:
          type: string
          example: 0227d1e5-ba9a-42b5-8fe2-38882aa65708
        watchers:
          type: array
          items:
            $ref: '#/components/schemas/User2'
    User:
      type: object
      properties:
        id:
          type: string
          example: 0227d1e5-ba9a-42b5-8fe2-38882aa65708
        first_name:
          type: string
          example: Rodrigo
        last_name:
          type: string
          example: Davis
        role:
          type: string
          example: admin
    User2:
      type: object
      properties:
        id:
          type: string
          example: 1326d1e5-ba9a-42b5-8fe2-38882aa65708
        first_name:
          type: string
          example: Daphne
        last_name:
          type: string
          example: Dafoe
        role:
          type: string
          example: admin
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````