> For the complete documentation index, see [llms.txt](https://placapi.gitbook.io/placapi-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://placapi.gitbook.io/placapi-docs/empresas-y-estado/registro-mercantil.md).

# Registro mercantil

`POST https://placapi.com/api/rues`

Empresas y comerciantes inscritos en las Cámaras de Comercio (el registro que el público consulta como "RUES"). Se busca por `documento` (NIT o cédula, vía exacta y recomendada) o por `nombre`. Devuelve razón social, matrícula, cámara, **estado de la matrícula**, tipo de sociedad, organización jurídica, códigos CIIU principal y secundario, fechas de matrícula, renovación, vigencia y cancelación, el último año renovado, si está inscrita como proponente y el **representante legal con su documento**. La búsqueda por `nombre` es de **texto completo**: "EL OSO" encuentra también "INVERSIONES ALTAMIRA EL OSO", y los resultados llegan por relevancia. `resumen.totalCoincidencias` es el conteo real en las dos vías. Cuesta 1 crédito, y cero coincidencias es un resultado válido que cobra. Costo: 1 crédito por consulta con datos.

## Parámetros

| Campo       | Tipo    | Obligatorio | Detalle                                                                                                                                                                                                                                                       |
| ----------- | ------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `documento` | string  | No          | NIT o cédula del inscrito. Se acepta con puntos y con el dígito de verificación (`900123456-7`): se normaliza y el dígito se descarta, porque el registro lo guarda en una columna aparte y buscarlo pegado no encuentra nada. Alias aceptados: `doc`, `nit`. |
| `nombre`    | string  | No          | Razón social o cualquier parte de ella: es búsqueda de texto completo, no por prefijo. Mínimo 3 caracteres. Alias aceptado: `razonSocial`.                                                                                                                    |
| `termino`   | string  | No          | Campo único que acepta NIT **o** razón social; se enruta según su contenido (solo dígitos = documento). Existe para migrar desde proveedores que usan un solo campo de búsqueda.                                                                              |
| `offset`    | number  | No          | Paginación en filas (0, 50, 100…). Cada página trae hasta 50 registros.                                                                                                                                                                                       |
| `refresh`   | boolean | No          | Ignora la caché y vuelve a consultar la fuente oficial. Ojo: una consulta refrescada con datos siempre cobra (el hit de caché no).                                                                                                                            |

## Ejemplo

```bash
curl -X POST 'https://placapi.com/api/rues' \
  -H 'x-api-key: pk_live_TU_CLAVE' \
  -H 'content-type: application/json' \
  -d '{"placa": "ABC123"}'
```

El esquema completo de la respuesta está en el [OpenAPI 3.1](https://placapi.com/openapi.json) y en la [referencia interactiva](https://placapi.github.io/reference.html).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://placapi.gitbook.io/placapi-docs/empresas-y-estado/registro-mercantil.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
