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

# Create account verification code

> Create a new account record and sends an otp code to the customer

When you POST to this endpoint, we will save the customer's information and send a otp code to the number provided on the `phoneNumber` field

<RequestExample>
  ```bash Request theme={null}
  curl --location --request POST 'https://staging-api.propaga.io/v1/account/{userId}/verification' 
  --header 'Authorization: <your_awesome_token>'
  --header 'Content-Type: application/json'
  --data '{
      "firstName": "John",
      "lastNames": "Doe",
      "phoneNumber": "551238976",
      "latitude": "19.3883998",
      "longitude": "-99.0209696",
      "contacts": [
          {
              "fullName": "Contact name 1",
              "phoneNumber": "550987654"
          },
          {
              "fullName": "Contact name 2",
              "phoneNumber": "551234567"
          }
      ],
      "metadata": {}
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
      "verificationId": "222297d8-187b-4ea7-a193-d8fd82ee162a"
  }
  ```
</ResponseExample>

## Path parameters

<ParamField path="userId" type="string" required>
  Propaga's user id
</ParamField>

## Body

<ParamField path="firstName" type="string" required />

<ParamField path="lastNames" type="string" required />

<ParamField path="phoneNumber" type="string" required />

<ParamField path="latitude" type="string" />

<ParamField path="longitude" type="string" />

<ParamField path="contacts" type="array" required>
  <Expandable title="properties">
    <ParamField path="fullName" type="string" required />

    <ParamField path="phoneNumber" type="string" required />
  </Expandable>
</ParamField>

<ParamField body="metadata" type="json" optional>
  Any metadata you want to save for the user
</ParamField>

## Response

<ResponseField name="verificationId" type="string" />

## Error codes

<ResponseField>
  ```json User not found (404) theme={null}
  {
      "errorCode": "USER_NOT_FOUND",
      "errorMessage": "This user not found"
  }
  ```

  ```json User already verified (422) theme={null}
  {
      "errorCode": "USER_IS_VERIFIED",
      "errorMessage": "This user is verified"
  }
  ```

  ```json User in internal verification (422) theme={null}
  {
      "errorCode": "USER_IN_MANUAL_VALIDATION",
      "errorMessage": "This user information is currently in manual validation"
  }
  ```
</ResponseField>
