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

# ✍️ Crear participación

> Agrega un participante a una tarea de Contractia con nombre, correo, teléfono, rol (firmante, validador o copia) y validación OTP o biométrica opcional.

## <Badge color="yellow" size="lg">POST</Badge>  ➜ /v2/tareas/tarea\_id/participaciones

`https://api.contractia.app/v2/tareas/tarea_id/participaciones`

<Info>
  Reemplazar `{tarea_id}` por el ID numérico de la tarea deseada.
</Info>

¿Cómo obtener el ID de la tarea? [➜](/platform/buscar)

### 🧾 Parámetros del cuerpo (JSON)

| Parámetro                | Tipo     | Descripción                                                                                                                                                        |
| ------------------------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`                     | int      | Identificador único del contacto                                                                                                                                   |
| `nombre`                 | string   | Nombre del participante                                                                                                                                            |
| `apellido`               | string   | Apellido del participante                                                                                                                                          |
| `mail`                   | string   | Correo electrónico del participante                                                                                                                                |
| `tipo_otp`               | string   | Tipo de validación OTP: `OTP_EMAIL`, `OTP_SMS` o vacío                                                                                                             |
| `validacion_biometrica`  | bool     | `true` si solicita validación biométrica<br />`false` si no solicita.                                                                                              |
| `telefono{`              | object   |                                                                                                                                                                    |
| `telefono.codigo_pais`   | string   | Código telefónico del país                                                                                                                                         |
| `telefono.numero`        | string   | Número de teléfono                                                                                                                                                 |
| `telefono.referencia`    | string   | Etiqueta opcional para identificar el número                                                                                                                       |
| }                        |          |                                                                                                                                                                    |
| `save`                   | bool     | `true` si quiere guardar/actualizar datos de contacto en la agenda<br />`false` si no quiere guardar.                                                              |
| `role`                   | int      | `1` Firmante<br />`2` Validador<br />`3` En copia                                                                                                                  |
| `reminder{`              | nullable | reminder = null indica que no se enviarán recordatorios para esta participación. <br />Si no se indica frecuencia, hereda la frecuencia establecida para la tarea. |
| `frequency`              | int      | Frecuencia de envío de recordatorios                                                                                                                               |
| `unit`                   | string   | Unidad de frecuencia: hours o days                                                                                                                                 |
| `notification_channel`   | int      | `1` Whatsapp<br />`3` Email                                                                                                                                        |
| `supress_notifications`  | bool     | `true` Desactiva el envío de notificaciones<br />`false` Activa el envío de notificaciones                                                                         |
| `redirect_url`           | string   | URL opcional de redirección al finalizar la firma                                                                                                                  |
| `access_password`        | string   | Opcional. Activa password para el participante. Se completa con la clave deseada.                                                                                  |
| `remove_access_password` | bool     | `true `Desactiva password para el participante. ([Solo en Editar Participación](/platform/editar))                                                                 |

### 💻 Ejemplo de implementación

<Tabs>
  <Tab title="cURL">
    ```bash theme={null}
    curl --location --request POST 'https://api.contractia.app/v2/tareas/{{tarea_id}}/participaciones' \
    --header 'Authorization: Bearer {{api_key}}' \
    --header 'user_id: {{user_id}}' \
    --header 'Content-Type: application/json' \
    --data '[
        {
            "id": 1500,
            "nombre": "",
            "apellido": "",
            "mail": "",
            "tipo_otp": null,
            "validacion_biometrica": false,
            "telefono": null,
            "save": false,
            "role": 2,
            "reminder": {
                "frequency": 2,
                "unit": "days"
            }
        },
        {
            "id": 0,
            "nombre": "Roberto",
            "apellido": "Sanchez",
            "mail": "roberto.sanchez@yopmail.com",
            "tipo_otp": "OTP_SMS",
            "validacion_biometrica": false,
            "telefono": {
                "id": 0,
                "codigo_pais": "54",
                "numero": "1122556699",
                "referencia": "string"
            },
            "save": false,
            "role": 1,
            "reminder": {
                "frequency": 1,
                "unit": "days"
            },
            "notification_channel": 1,
            "supress_notifications": false,
            "redirect_url": "https://domain.com/",
            "access_password": "Clave-Roberto_7"
        }
    ]'
    ```
  </Tab>

  <Tab title="Request JSON">
    ```json theme={null}
    [
        {
            "id": 1500,
            "nombre": "",
            "apellido": "",
            "mail": "",
            "tipo_otp": null,
            "validacion_biometrica": false,
            "telefono": null,
            "save": false,
            "role": 2,
            "reminder": {
                "frequency": 2,
                "unit": "days"
            },
            "notification_channel": 3,
            "supress_notifications": true,
            "redirect_url": null,
            "access_password": "miClave123"
        },
        {
            "id": 0,
            "nombre": "Roberto",
            "apellido": "Sanchez",
            "mail": "roberto.sanchez@yopmail.com",
            "tipo_otp": "OTP_SMS",
            "validacion_biometrica": false,
            "telefono": {
                "id": 0,
                "codigo_pais": "54",
                "numero": "1122556699",
                "referencia": "string"
            },
            "save": false,
            "role": 1,
            "reminder": {
                "frequency": 1,
                "unit": "days"
            },
            "notification_channel": 1,
            "supress_notifications": false,
            "redirect_url": "https://domain.com/",
            "access_password": "Clave-Roberto_7"
        },
        {
            "id": 0,
            "nombre": "Luis",
            "apellido": "Rodriguez",
            "mail": "rodriguezl@yopmail.com",
            "tipo_otp": null,
            "validacion_biometrica": false,
            "telefono": null,
            "save": false,
            "role": 1,
            "reminder": {}
        }
    ]
    ```
  </Tab>

  <Tab title="Response JSON">
    ```json theme={null}
    [
      6477,
      6478
    ]
    ```
  </Tab>
</Tabs>

***

## Datos a tener en cuenta:

* Los parámetros `nombre`, `apellido` y `mail` son obligatorios para la creación de un participante.
* Si se declara `OTP_SMS`, el object `telefono` debe ir completo.
* Si se declara `notification_channel` con valor `3` (Whatsapp), el object `telefono` debe ir completo.
* El parámetro `remove_access_password` solo debe utilizarse en la [Edición de un participante](/platform/editar).

#### Siguiente paso:

* Agregar documentos a una tarea [➜](/cargar-nuevo)
