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

# Get Components List

Use this endpoint to search the component catalog. Components represent additional product elements such as buttons, zippers, and trims that contribute to a product's environmental impact.

### Request body params

| Name         | Type            | Description                                                        |
| :----------- | :-------------- | :----------------------------------------------------------------- |
| `textSearch` | `string`        | Search components by name.                                         |
| `ids`        | `Array<string>` | Filter by specific component IDs.                                  |
| `from`       | `number`        | **\[DEFAULT: 0]** Pagination start index.                          |
| `size`       | `number`        | **\[DEFAULT: 50]** Number of results to return (max 50).           |
| `sort`       | `object`        | Sorting configuration `{ field: string, order: "asc" \| "desc" }`. |

### Implementation Details

* **Pagination**: Maximum page size is capped at 50 results.
* **Usage**: Use the returned `_id` values (as `componentId`) in the `components` array when [creating](/api-reference/pic/products/create) or [updating](/api-reference/pic/products/update) products.


## OpenAPI

````yaml api-reference/openapi/french-eco.json POST /components/search
openapi: 3.0.0
info:
  title: pic-api
  version: 1.0.0
servers:
  - url: https://api-v2.production.higg.org/pic-api/v1
    description: Production
  - url: https://api-v2.demo.higg.org/pic-api/v1
    description: Demo
security:
  - sec0: []
    sec1: []
paths:
  /components/search:
    post:
      summary: Get Components List
      operationId: GetComponentsList
      requestBody:
        $ref: '#/components/requestBodies/CorpRepApiSearchRequest'
      responses:
        '200':
          description: Ok
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/CorpReportApiPaginatedResponseCorpRepByProducts
components:
  requestBodies:
    CorpRepApiSearchRequest:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/CorpRepApiSearchRequest'
      required: true
  schemas:
    CorpReportApiPaginatedResponseCorpRepByProducts:
      description: API Search responses
      properties:
        from:
          type: number
          format: double
        size:
          type: number
          format: double
        total:
          type: number
          format: double
        results:
          items:
            $ref: '#/components/schemas/CorpRepByProducts'
          type: array
      required:
        - from
        - results
        - size
        - total
      type: object
      additionalProperties: false
    CorpRepApiSearchRequest:
      properties:
        from:
          type: number
          format: double
          nullable: true
        size:
          type: number
          format: double
          nullable: true
        ids:
          items:
            type: string
          type: array
          nullable: true
        sort:
          $ref: '#/components/schemas/SortType'
        textSearch:
          type: string
          nullable: true
      type: object
      additionalProperties: false
    CorpRepByProducts:
      properties:
        _id:
          type: string
        name:
          type: string
      required:
        - _id
        - name
      type: object
      additionalProperties: false
    SortType:
      description: API Search requests
      properties:
        field:
          type: string
        order:
          type: string
          enum:
            - asc
            - desc
      required:
        - field
        - order
      type: object
      additionalProperties: false
  securitySchemes:
    sec0:
      type: apiKey
      in: header
      name: x-api-key
    sec1:
      type: apiKey
      in: header
      name: x-developer-request-token

````