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

# Get User Profile — GET /v1/users/:userId — CA Colombia

> Fetch a CA Colombia user by their Snowflake ID. Returns profile data, character list, and optionally linked Discord and Roblox provider accounts.

Use this endpoint to retrieve a CA Colombia user's profile by their unique Snowflake ID. The response includes account metadata, character limits, and the user's full character list. You can optionally request linked provider data (Discord and Roblox) and character signature data by passing query parameters.

<Note>
  You can only retrieve your own user profile unless your token carries `SERVICE_ADMINISTRATOR` or `DEVELOPER` permissions. Attempting to fetch another user's profile without those permissions will return a `403 Forbidden` error.
</Note>

## Endpoint

```text theme={null}
GET https://api.cacolombia.com/v1/users/:userId
```

## Path Parameters

<ParamField path="userId" type="string" required>
  The Snowflake ID of the user to retrieve.
</ParamField>

## Query Parameters

<ParamField query="providers" type="string">
  Pass `true` to include the user's linked provider accounts (Discord and Roblox) in the response. Omit or pass any other value to exclude provider data.
</ParamField>

<ParamField query="signature" type="string">
  Pass `true` to include the `signatureData` field on character objects (active character and the characters array). Omit or pass any other value to exclude it.
</ParamField>

## Response

<ResponseField name="userId" type="string">
  The user's unique Snowflake ID.
</ResponseField>

<ResponseField name="permissions" type="string">
  A numeric string representing the user's permission bitfield.
</ResponseField>

<ResponseField name="maxCharacters" type="number">
  The maximum number of characters this user is allowed to create.
</ResponseField>

<ResponseField name="activeCharacter" type="object | null">
  The user's currently active character, or `null` if none is set. See the character object shape below.

  <Expandable title="activeCharacter fields">
    <ResponseField name="characterId" type="string">
      Unique Snowflake ID of the character.
    </ResponseField>

    <ResponseField name="userId" type="string">
      The Snowflake ID of the user who owns the character.
    </ResponseField>

    <ResponseField name="firstNames" type="string">
      The character's first name(s).
    </ResponseField>

    <ResponseField name="lastNames" type="string">
      The character's last name(s).
    </ResponseField>

    <ResponseField name="age" type="number">
      The character's age in years.
    </ResponseField>

    <ResponseField name="height" type="number">
      The character's height in centimetres.
    </ResponseField>

    <ResponseField name="gender" type="string">
      The character's gender. Either `Masculino` or `Femenino`.
    </ResponseField>

    <ResponseField name="bloodType" type="string">
      The character's blood type (e.g. `O+`, `A-`, `AB+`).
    </ResponseField>

    <ResponseField name="nationality" type="object">
      An object describing the character's nationality with `nombre`, `abrev`, and `lugar` fields.
    </ResponseField>

    <ResponseField name="dob" type="string">
      The character's date of birth in `DD/MM/YYYY` format.
    </ResponseField>

    <ResponseField name="avatarHash" type="string | null">
      Hash of the character's avatar image, or `null` if not set.
    </ResponseField>

    <ResponseField name="idCardHash" type="string | null">
      Hash of the character's ID card image, or `null` if not set.
    </ResponseField>

    <ResponseField name="fullBodyHash" type="string | null">
      Hash of the character's full-body image, or `null` if not set.
    </ResponseField>

    <ResponseField name="avatar3dHash" type="string | null">
      Hash of the character's 3D avatar, or `null` if not set.
    </ResponseField>

    <ResponseField name="avatar3dCamera" type="object | null">
      Saved camera configuration for the 3D avatar, or `null` if not set.
    </ResponseField>

    <ResponseField name="avatar3dAABB" type="object | null">
      Saved axis-aligned bounding box for the 3D avatar, or `null` if not set.
    </ResponseField>

    <ResponseField name="idStatus" type="string">
      The character's ID card approval status. One of `draft`, `pending_approval`, or `approved`.
    </ResponseField>

    <ResponseField name="wallet" type="object | null">
      The character's wallet, or `null` if no wallet exists.
    </ResponseField>

    <ResponseField name="signatureData" type="string | null">
      Only present when `signature=true` is passed. The character's signature data string, or `null` if not set.
    </ResponseField>

    <ResponseField name="createdAt" type="string">
      ISO 8601 timestamp of when the character was created.
    </ResponseField>

    <ResponseField name="updatedAt" type="string">
      ISO 8601 timestamp of when the character was last updated.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="characters" type="array">
  An array of all character objects belonging to the user. Each item has the same shape as `activeCharacter` above.
</ResponseField>

<ResponseField name="createdAt" type="string">
  ISO 8601 timestamp of when the user account was created.
</ResponseField>

<ResponseField name="updatedAt" type="string">
  ISO 8601 timestamp of when the user account was last updated.
</ResponseField>

<ResponseField name="providers" type="array">
  Only present when `providers=true` is passed. An array of `[providerName, providerObject]` tuples for each linked account.

  <Expandable title="provider tuple fields">
    <ResponseField name="[0]" type="string">
      The provider name. Either `"discord"` or `"roblox"`.
    </ResponseField>

    <ResponseField name="[1].userId" type="string">
      The CA Colombia Snowflake ID of the user who owns this provider link.
    </ResponseField>

    <ResponseField name="[1].providerId" type="string">
      The Snowflake ID of this provider record.
    </ResponseField>

    <ResponseField name="[1].providerName" type="string">
      The provider name. Either `"discord"` or `"roblox"`.
    </ResponseField>

    <ResponseField name="[1].externalId" type="string">
      The user's ID on the external platform (e.g. Discord user ID or Roblox user ID).
    </ResponseField>

    <ResponseField name="[1].externalMetadata" type="object">
      Provider-specific metadata returned by the external platform at the time of linking.
    </ResponseField>
  </Expandable>
</ResponseField>

## Example Request

```bash theme={null}
curl -X GET "https://api.cacolombia.com/v1/users/112233445566778899?providers=true" \
  --cookie "access_token=<your_access_token>"
```

## Example Response

```json theme={null}
{
  "userId": "112233445566778899",
  "permissions": "1024",
  "maxCharacters": 2,
  "activeCharacter": {
    "characterId": "998877665544332211",
    "userId": "112233445566778899",
    "firstNames": "Carlos Alberto",
    "lastNames": "Reyes Gómez",
    "age": 28,
    "height": 175,
    "gender": "Masculino",
    "bloodType": "O+",
    "nationality": {
      "nombre": "Colombiano",
      "abrev": "COL",
      "lugar": "Colombia"
    },
    "dob": "15/04/1996",
    "avatarHash": "abc123def456",
    "idCardHash": "xyz789uvw012",
    "fullBodyHash": null,
    "avatar3dHash": null,
    "avatar3dCamera": null,
    "avatar3dAABB": null,
    "idStatus": "approved",
    "wallet": null,
    "createdAt": "2024-01-10T14:30:00.000Z",
    "updatedAt": "2024-06-01T09:15:00.000Z"
  },
  "characters": [
    {
      "characterId": "998877665544332211",
      "userId": "112233445566778899",
      "firstNames": "Carlos Alberto",
      "lastNames": "Reyes Gómez",
      "age": 28,
      "height": 175,
      "gender": "Masculino",
      "bloodType": "O+",
      "nationality": {
        "nombre": "Colombiano",
        "abrev": "COL",
        "lugar": "Colombia"
      },
      "dob": "15/04/1996",
      "avatarHash": "abc123def456",
      "idCardHash": "xyz789uvw012",
      "fullBodyHash": null,
      "avatar3dHash": null,
      "avatar3dCamera": null,
      "avatar3dAABB": null,
      "idStatus": "approved",
      "wallet": null,
      "createdAt": "2024-01-10T14:30:00.000Z",
      "updatedAt": "2024-06-01T09:15:00.000Z"
    }
  ],
  "createdAt": "2024-01-10T14:00:00.000Z",
  "updatedAt": "2024-06-01T09:15:00.000Z",
  "providers": [
    ["discord", { "userId": "112233445566778899", "providerId": "111122223333444455", "providerName": "discord", "externalId": "123456789012345678", "externalMetadata": {} }],
    ["roblox", { "userId": "112233445566778899", "providerId": "555566667777888899", "providerName": "roblox", "externalId": "987654321", "externalMetadata": {} }]
  ]
}
```

## Error Responses

| Status | Error          | Description                                                                   |
| ------ | -------------- | ----------------------------------------------------------------------------- |
| `401`  | `Unauthorized` | No valid authentication token was provided.                                   |
| `403`  | `Forbidden`    | You attempted to fetch another user's profile without sufficient permissions. |
| `404`  | `Unknown User` | No user was found with the given `userId`.                                    |
