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

# Search Overrides

> Returns a list of capacity overrides by applying one or more filter criteria such as status, schedule, or location number.



## OpenAPI

````yaml locations.openapi post /location-capacity/search
openapi: 3.0.1
info:
  contact:
    email: support@fabric.inc
    name: fabric Orders team
  description: >-
    fabric **Locations** API provides location endpoints that support
    multi-tenant services. This location data is used for both inventory
    management and order management. When an order is created, it's allocated to
    the nearest location according to the Order Fulfillment Logic.
  license:
    name: fabric API License
    url: https://fabric.inc/api-license
  termsOfService: https://fabric.inc/terms-of-use
  title: Inventory - Locations API
  version: 3.0.0
  x-audience: external-public
servers:
  - description: Production
    url: https://api.fabric.inc/v3
security:
  - authorization: []
tags:
  - description: These Endpoints help in performing Outage operations
    name: Location Outage Endpoints
  - description: These endpoints let you create and manage locations.
    name: Locations
  - description: These Endpoints help in performing capacity operations
    name: Location Capacity Endpoints
  - name: Location Geography Endpoints
    description: These Endpoints help in performing Geography operations
  - name: Location Zone Endpoints
    description: These Endpoints help in performing Zone operations
paths:
  /location-capacity/search:
    post:
      tags:
        - Location Capacity Endpoints
      summary: Search Overrides
      description: >-
        Returns a list of capacity overrides by applying one or more filter
        criteria such as status, schedule, or location number.
      operationId: searchLocationCapacityOverride
      parameters:
        - name: offset
          in: query
          description: >-
            Number of records to skip before returning all records. Default is
            `0` when no value is specified.
          schema:
            type: number
            default: 0
            example: 1
          example: 0
        - name: limit
          in: query
          description: Maximum number of records per page
          schema:
            type: number
            default: 10
            example: 10
          example: 10
        - $ref: '#/components/parameters/xFabricTenantId'
        - $ref: '#/components/parameters/xFabricRequestId'
        - $ref: '#/components/parameters/xFabricChannelIdOptional'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/capacityOverrideSearchRequest'
        required: true
      responses:
        '200':
          description: OK
          headers:
            x-fabric-request-id:
              $ref: '#/components/headers/xFabricRequestIdResponseHeader'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CapacityOverrideSearchResponse'
        '400':
          description: Bad request
          headers:
            x-fabric-request-id:
              $ref: '#/components/headers/xFabricRequestIdResponseHeader'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
              example:
                type: CLIENT_ERROR
                errorCode: SERVICE-4003
                message: 'Mandatory param(s): `requiredField1` is/are missing'
                errors:
                  - type: CLIENT_ERROR
                    errorCode: SERVICE-4002
                    message: Invalid value(s) specified for 'requiredField.field3'
                    errors: []
                context:
                  service: orders
                  endpoint: POST /v3/orders
        '401':
          description: Unauthorized
          headers:
            x-fabric-request-id:
              $ref: '#/components/headers/xFabricRequestIdResponseHeader'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
              example:
                type: CLIENT_ERROR
                errorCode: SERVICE-4001
                message: Unauthorized request
                errors: []
                context:
                  service: orders
                  endpoint: POST /v3/orders/OrderId_12345
        '500':
          description: Internal server error
          headers:
            x-fabric-request-id:
              $ref: '#/components/headers/xFabricRequestIdResponseHeader'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/errorResponse'
              example:
                type: SERVER_ERROR
                errorCode: SERVICE-5000
                message: Internal server error
                errors: []
                context:
                  service: inventories
                  endpoint: POST /v3/inventories/actions/find-by-geography
components:
  parameters:
    xFabricTenantId:
      description: >-
        A header used by fabric to identify the tenant making the request. You
        must include tenant id in the authentication header for an API request
        to access any of fabric’s endpoints. You can retrieve the tenant id ,
        which is also called account id, from
        [Copilot](/v3/platform/settings/account-details/getting-the-account-id).
        This header is required.
      example: 5f328bf0b5f328bf0b5f328b
      in: header
      name: x-fabric-tenant-id
      required: true
      schema:
        type: string
    xFabricRequestId:
      description: Unique request ID
      example: 263e731c-45c8-11ed-b878-0242ac120002
      in: header
      name: x-fabric-request-id
      required: false
      schema:
        type: string
    xFabricChannelIdOptional:
      description: >-
        x-fabric-channel-id identifies the sales channel through which the API
        request is being made; primarily for multichannel use cases. It is an
        optional field. The default US channel is 12 while the default Canada
        channel is 13.
      example: '12'
      in: header
      name: x-fabric-channel-id
      required: false
      schema:
        type: string
  schemas:
    capacityOverrideSearchRequest:
      type: object
      description: Capacity Override search request
      example:
        sort: '-capacityOverride.createdAt'
        filters:
          - field: capacityOverride.status
            value: CREATED
            condition: EQ
      properties:
        sort:
          type: string
          default: '-capacityOverride.createdAt'
          description: Resource property on which data needed to be sorted on.
          example: +capacityOverride.createdAt
          pattern: >-
            (^[+-]capacityOverride\.[a-zA-Z.\-_]*)(,([+-]alert\.[a-zA-Z.\-_]*)){0,}
        filters:
          type: array
          items:
            $ref: '#/components/schemas/CapacityOverrideSearchFilter'
            description: List to filters for search
            maxItems: 50
            minItems: 0
          maxItems: 50
          minItems: 0
      required:
        - filters
    CapacityOverrideSearchResponse:
      type: object
      description: >-
        Response object returned after searching for Capacity Overrides.
        Includes paginated data and optional summary statistics.
      properties:
        pagination:
          $ref: '#/components/schemas/pagination'
        data:
          type: array
          description: A list of Capacity Override records that match the search criteria.
          items:
            $ref: '#/components/schemas/capacityOverrideResponse'
        stats:
          type: array
          description: >-
            An array of summary statistics or aggregated data related to the
            search.
          items:
            type: string
    errorResponse:
      type: object
      description: Error response
      properties:
        type:
          type: string
          description: Error type
          example: CLIENT_ERROR
        errorCode:
          type: string
          description: Error code
          example: OMS-10001
        message:
          type: string
          description: Error message
          example: Bad request
        errors:
          type: array
          items:
            $ref: '#/components/schemas/errorResponse'
        context:
          type: string
          description: Error message
          example: Bad request
    CapacityOverrideSearchFilter:
      type: object
      description: >-
        Filter criteria used to search for Capacity Overrides. Use
        `valueSearchFilter` for single-value comparisons and
        `valuesSearchFilter` for multi-value matching.
      discriminator:
        propertyName: condition
        mapping:
          EQ:
            $ref: '#/components/schemas/valueSearchFilter'
          NEQ:
            $ref: '#/components/schemas/valueSearchFilter'
          LT:
            $ref: '#/components/schemas/valueSearchFilter'
          GT:
            $ref: '#/components/schemas/valueSearchFilter'
          LTE:
            $ref: '#/components/schemas/valueSearchFilter'
          GTE:
            $ref: '#/components/schemas/valueSearchFilter'
          IN:
            $ref: '#/components/schemas/valuesSearchFilter'
          NIN:
            $ref: '#/components/schemas/valuesSearchFilter'
      properties:
        field:
          type: string
          description: >-
            The field name to apply the filter on. Must follow the format
            `capacityOverride.<fieldName>`.
          pattern: ^capacityOverride\.[a-zA-Z.\-_]*
          example: capacityOverride.status
        condition:
          type: string
          default: EQ
          description: |
            Type of condition to apply
            - `EQ`: Equal to
            - `NEQ`: Not equal to
            - `IN`: Included in list
            - `NIN`: Not included in list
            - `LT`: Less than
            - `GT`: Greater than
            - `LTE`: Less than or equal to
            - `GTE`: Greater than or equal to
          enum:
            - EQ
            - NEQ
            - IN
            - NIN
            - LT
            - GT
            - LTE
            - GTE
          example: EQ
        group:
          type: string
          default: Default
          description: >-
            Optional group name to logically separate filter criteria for
            compound queries.
          example: GroupA
      required:
        - field
    pagination:
      type: object
      description: Pagination response
      properties:
        limit:
          type: integer
          format: int32
          default: '10'
          description: Maximum number of records per page
          example: 10
          maximum: 100
          minimum: 1
        offset:
          type: integer
          format: int32
          default: '0'
          description: >-
            Number of records to skip before returning all records. For example,
            `offset=20, limit=10` returns records 21-30.
          example: 1
          minimum: 0
        count:
          type: integer
          format: int32
          description: Total number of search results
          example: 1000
    capacityOverrideResponse:
      type: object
      description: >-
        Response object representing a capacity override at a specific location,
        including status, allocation limit, time window, and audit information.
      properties:
        capacityOverrideId:
          type: string
          description: A system-generated unique identifier for the capacity override.
          example: 9320183a01e214
        capacityOverrideNumber:
          type: string
          description: >-
            A merchant-defined unique reference number for the capacity
            override.
          example: capacityOverride1
        locationNumber:
          type: string
          description: >-
            A unique identifier for the location where the capacity override
            applies, as defined by the merchant.
          example: '23'
        status:
          type: string
          description: The current status of the capacity override.
          enum:
            - CREATED
            - STARTED
            - ENDED
            - CANCELLED
          example: CREATED
        capacity:
          type: integer
          format: int32
          description: >-
            The maximum number of allocations the location can accept at any
            point during the override period. When `currentAllocations` equals
            this value, the location is considered "AtCapacity" and cannot
            receive further orders.
          example: 30
        schedule:
          $ref: '#/components/schemas/CapacityOverrideScheduleResource'
          description: >-
            The date and time window during which the capacity override is in
            effect.
        reasonCode:
          type: string
          description: >-
            A merchant-defined reason for the override, used for traceability or
            reporting (for example, holiday, peak demand).
          example: holiday
        notes:
          $ref: '#/components/schemas/orderNote'
          description: >-
            Optional notes or comments providing additional context for the
            override.
          example: Any additional info
        createdBy:
          type: string
          description: Identifier or name of the user or system that created the override.
          example: Carl Doe
        createdAt:
          type: string
          format: date-time
          description: >-
            The timestamp when the capacity override was created, in ISO 8601
            UTC format.
          example: '2022-05-12T09:30:31Z'
        updatedBy:
          type: string
          description: >-
            Identifier or name of the user or system that last updated the
            override.
          example: Carl Doe
        updatedAt:
          type: string
          format: date-time
          description: >-
            The timestamp of the most recent update to the override record, in
            ISO 8601 UTC format.
          example: '2022-05-12T09:30:31Z'
        auditLogs:
          type: array
          description: A list of audit log entries tracking changes made to the override.
          items:
            $ref: '#/components/schemas/auditLog'
      required:
        - capacity
        - reasonCode
        - schedule
    valueSearchFilter:
      allOf:
        - $ref: '#/components/schemas/locationSearchFilter'
        - type: object
          properties:
            value:
              type: object
              description: A single value for `field` using which data is searched
              example: ORDER_CREATE
              oneOf:
                - type: string
                  description: Target record's non-numeric identifier
                  example: ORDER_CREATE
                - type: number
                  format: int64
                  description: Target record's numeric identifier
                  example: 112233
                - type: number
                  format: double
                  description: Target record's numeric identifier
                  example: 1122.33
      description: >-
        Criteria to find location using a single value. Condition between
        `field` and `value` is anything except IN and NIN when
        `valueSearchFilter` is used.
      required:
        - condition
        - field
    valuesSearchFilter:
      allOf:
        - $ref: '#/components/schemas/locationSearchFilter'
        - type: object
          properties:
            values:
              type: array
              items:
                description: Multiple values for `field` using which locations are searched
                example: ORDER_CREATE
                oneOf:
                  - type: string
                    description: Target record's non-numeric identifier
                    example: ORDER_CREATE
                  - type: number
                    format: int64
                    description: Target record's numeric identifier
                    example: 112233
                  - type: number
                    format: double
                    description: Target record's numeric identifier
                    example: 1122.33
              maxItems: 25
              minItems: 0
      description: >-
        Criteria to find locations using multiple values. Condition between
        `field` and `values` is either IN or NIN when `valuesSearchFilter` is
        used.
      required:
        - condition
        - field
    CapacityOverrideScheduleResource:
      type: object
      description: >-
        Defines the schedule during which the Capacity Override is active,
        including the start and end timestamps.
      properties:
        startDate:
          type: string
          format: date-time
          description: >-
            ISO 8601 formatted timestamp representing when the override becomes
            active.
          example: '2022-05-12T09:30:31Z'
        endDate:
          type: string
          format: date-time
          description: ISO 8601 formatted timestamp representing when the override ends.
          example: '2022-05-12T09:30:31Z'
      required:
        - startDate
        - endDate
    orderNote:
      type: object
      description: Note for attention
      properties:
        createdAt:
          type: string
          description: Time note was created (UTC)
          example: '2022-05-12T09:30:31.198Z'
        user:
          type: string
          description: >-
            Customer Service Representative or Employee (ID or name) who created
            the note
          example: 62272e917b12209e68751d94
        notes:
          type: string
          description: Additional info about the order, if any
          example: Fragile - handle with care
    auditLog:
      type: object
      description: Audit log to capture change history
      properties:
        lineItemId:
          type: string
          description: >-
            Merchant-defined unique identifier for each item in an order. When
            omitted, fabric will generate it during order creation, in UUID
            format.
          example: b03b72dc-78d8-4ea4-90fc-2fe6a1fe6569
        auditId:
          type: string
          description: System-generated audit ID (UUID format)
          example: a05b72dc-78d8-4ea4-90fc-2fe6a1fe1111
        auditType:
          type: string
          description: Audit type such as cancel, return, etc.
          example: CANCEL
        employeeId:
          type: string
          description: Employee (ID or name) who made the last update
          example: 6227
        auditedAt:
          type: string
          format: date-time
          description: Audit time (UTC)
          example: '2023-03-12T09:24:54.804Z'
        source:
          type: string
          description: >-
            Merchant-defined source from where the update was initiated. There
            are no predefined values; possible values could be Customer Service
            Representative (CSR), Point-of-Sale (POS), etc.
          example: POS
        reasonCode:
          type: string
          description: Merchant-defined reason code, varies from merchant to merchant
          example: Scratched item
        subReasonCode:
          type: string
          description: >-
            Merchant-defined sub reason code; provides more clarity to audit
            reason
          example: Scratched item
        policyCode:
          type: string
          description: >-
            Configurable in Copilot as per requirement. If omitted, default
            policy is used.
          example: POS
        note:
          type: string
          description: Additional info, if any
          example: Note
        lineItemNumber:
          type: integer
          format: int32
          description: Item identifier
          example: 1
        sku:
          type: string
          description: Stock keeping unit (SKU), unique item identifier
          example: SKU0023
        quantity:
          type: integer
          format: int32
          description: Ordered quantity of given item
          example: 1
        amount:
          type: number
          format: double
          description: Amount for which audit is done
          example: 2.4
        paymentToken:
          $ref: '#/components/schemas/orderPaymentToken'
          description: >-
            Payment token provided by payment provider. Must be provided during
            order creation if the payment life cycle orchestration is through
            fabric Orders (OMS).
        updatedFields:
          type: array
          items:
            $ref: '#/components/schemas/orderAuditLogUpdatedField'
        attributes:
          type: object
          description: Custom attributes
          example:
            key: value
        isSuccess:
          type: boolean
          default: 'false'
          description: >-
            true: Update operation (any update to the service) is successful
            <br> false: Update operation has failed
          example: true
    locationSearchFilter:
      type: object
      description: >-
        Criteria to search locations. To search using a single value,
        `valueSearchFilter` is used. To search using multiple values,
        `valuesSearchFilter` is used.
      discriminator:
        propertyName: condition
        mapping:
          EQ:
            $ref: '#/components/schemas/valueSearchFilter'
          NEQ:
            $ref: '#/components/schemas/valueSearchFilter'
          LT:
            $ref: '#/components/schemas/valueSearchFilter'
          GT:
            $ref: '#/components/schemas/valueSearchFilter'
          LTE:
            $ref: '#/components/schemas/valueSearchFilter'
          GTE:
            $ref: '#/components/schemas/valueSearchFilter'
          IN:
            $ref: '#/components/schemas/valuesSearchFilter'
          NIN:
            $ref: '#/components/schemas/valuesSearchFilter'
      properties:
        group:
          type: string
          default: Default
          description: Group name
          example: GroupA
        field:
          type: string
          description: Field name
          example: location.locationNum
          pattern: ^location\.[a-zA-Z.\-_]*
        condition:
          type: string
          default: EQ
          description: >-
            Filter conditions. <br> EQ (Equal to): Searches for exact match.
            <br> NEQ (Not equal to): Searches by excluding the specified value.
            <br> IN: Search for multiple values. <br> NIN (Not IN): Excludes the
            specified values in the search. LT (Less than): Searches for values
            that are less than the specified value. GT (Greater than):  Search
            for values that are greater than the specified value. LTE (Less than
            or equal to): Searches for values that are less than or equal to the
            specified value. GTE (Greater than or equal to): Searches for values
            that are greater than or equal to the specified value.
          enum:
            - EQ
            - NEQ
            - IN
            - NIN
            - LT
            - GT
            - LTE
            - GTE
          example: EQ
      required:
        - condition
        - field
    orderPaymentToken:
      type: object
      description: Order payment token details
      properties:
        token:
          type: string
          description: Payment token provided by payment provider
          example: pi_34tr6787rt
        paymentType:
          type: string
          description: >-
            Payment type, for example, credit card payment providers can be
            Visa, Mastercard, American express, etc.
          example: VISA
    orderAuditLogUpdatedField:
      type: object
      description: Audit log for change history
      properties:
        fieldName:
          type: string
          description: Field or property name that was updated
          example: UOM
        fieldOriginalValue:
          type: string
          description: Original value of `fieldName` before it was updated
          example: PK
  headers:
    xFabricRequestIdResponseHeader:
      description: Unique request ID
      example: 263e731c-45c8-11ed-b878-0242ac120002
      required: false
      schema:
        type: string
  securitySchemes:
    authorization:
      bearerFormat: JWT
      scheme: bearer
      type: http

````