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

# sicarv4.products.search

> Search articulo by text (art_id/clave/claveAlterna/descripcion/caracteristicas), ids, status, servicio, existencia, cat_id

# `sicarv4.products.search`

Search articulo by text (art\_id/clave/claveAlterna/descripcion/caracteristicas), ids, status, servicio, existencia, cat\_id

|                |            |
| -------------- | ---------- |
| **Adapter**    | `sicarv4`  |
| **Operation**  | `db.query` |
| **SQL policy** | `read`     |

## Parameters

| Name            | Kind      | Required | Notes                                                                                                                      |       |        |       |       |
| --------------- | --------- | -------- | -------------------------------------------------------------------------------------------------------------------------- | ----- | ------ | ----- | ----- |
| `q`             | `string`  | No       | Optional. Whitespace-separated terms AND'd; each matches art\_id\|clave\|claveAlterna\|descripcion\|caracteristicas (LIKE) |       |        |       |       |
| `ids`           | `id_list` | No       | Optional. Comma-separated art\_id exact filter                                                                             |       |        |       |       |
| `status`        | `string`  | No       | 1=activo, 0=inactivo, -1=eliminado, all=sin filtro. options: \`all \\                                                      | 1 \\  | 0 \\   | -1\`  |       |
| `servicio`      | `string`  | No       | 0=producto, 1=servicio, all=sin filtro. options: \`all \\                                                                  | 0 \\  | 1\`    |       |       |
| `existencia_op` | `string`  | No       | Comparador de stock; requiere existencia si no es all. options: \`all \\                                                   | gt \\ | gte \\ | lt \\ | lte\` |
| `existencia`    | `string`  | No       | Cantidad (requerida si existencia\_op ≠ all)                                                                               |       |        |       |       |
| `cat_id`        | `id_list` | No       | Optional. Comma-separated category ids                                                                                     |       |        |       |       |
| `limit`         | `limit`   | No       | Optional. Default 1000000, max 1000000. default 1000000. max 1000000                                                       |       |        |       |       |

## Example

```bash theme={"system"}
curl -s -X POST "$API/v1/devices/$DEVICE_ID/functions/sicarv4.products.search" \
  -H "Authorization: Bearer $ORQUESTR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"input":{"q":"coca 600","ids":"1,2,3","status":"1","servicio":"0","existencia_op":"gte","existencia":"1","limit":"50"}}'
```
