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

# Subir documento individual

> Este endpoint permite subir documentos de identidad y verificación para una solicitud individual

### Parámetros

<ParamField path="userId" type="string" required>
  El ID de usuario de la solicitud
</ParamField>

### Cuerpo

<ParamField body="document" type="file" required>
  El archivo del documento a subir (multipart/form-data)
</ParamField>

<ParamField body="documentName" type="string" required>
  El nombre del documento
</ParamField>

<ParamField body="documentType" type="string" required>
  Tipo de documento que se sube (por ejemplo, "drivers\_license", "passport", "national\_id", "proof\_of\_address")
</ParamField>

<ParamField body="side" type="string">
  Para documentos de identidad, indicar "front" o "back"
</ParamField>

### Respuesta

<ResponseField name="message" type="string">
  Mensaje de confirmación
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl --location --request POST 'https://stablecoin-api.sandbox.getmeru.com/api/v1/cards-program/applications/individual/3ddd0e5b-6276-4b48-b756-c1fcc9a2efd1/documents' \
  --header 'api-key: <api-key>' \
  --form 'document=@"/path/to/document.jpg"' \
  --form 'documentName="Drivers License"' \
  --form 'documentType="drivers_license"' \
  --form 'side="front"'
  ```

  ```js Javascript theme={null}
  const formData = new FormData();
  formData.append('document', fileInput.files[0]);
  formData.append('documentName', 'Drivers License');
  formData.append('documentType', 'drivers_license');
  formData.append('side', 'front');

  const response = await fetch('https://stablecoin-api.sandbox.getmeru.com/api/v1/cards-program/applications/individual/3ddd0e5b-6276-4b48-b756-c1fcc9a2efd1/documents', {
    method: 'POST',
    headers: {
      'api-key': '<api-key>'
    },
    body: formData
  });

  const data = await response.json();
  ```
</RequestExample>

<ResponseExample>
  ```json 204 theme={null}
  {
    "message": "Document uploaded successfully"
  }
  ```
</ResponseExample>

### Respuestas de error

<ResponseExample>
  ```json 401 theme={null}
  {
    "success": false,
    "error": "Unauthorized. Please check your authentication credentials."
  }
  ```

  ```json 400 theme={null}
  {
    "success": false,
    "error": "Document file is required"
  }
  ```

  ```json 404 theme={null}
  {
    "success": false,
    "error": "Application not found."
  }
  ```
</ResponseExample>
