# Get a client (https://docs.loybox.com.ar/en/api-reference/clientes/obtener)



<Endpoint method="GET" path="/v1/clients/{client_code}" auth="api-key" />

Looks a client up by their code. The `client_code` is the number every person
registered in Loybox has: the one the member gives at the register and the one used
to [record a consumption](https://docs.loybox.com.ar/api-reference/consumos/crear-por-codigo).

## Parameters
<Fields>
  <Field name="client_code" type="string" location="path" required="true">
    The client's code.
  </Field>
</Fields>

## Response
A [Client](https://docs.loybox.com.ar/api-reference/objetos#cliente) object.

```bash
curl https://loybox-public-api-752998171300.southamerica-west1.run.app/v1/clients/12345 \
  -H "Authorization: Bearer $LOYBOX_API_KEY"
```

```json
// 200 OK
{
  "code": 12345,
  "username": "Ana Pérez",
  "email": "ana@example.com",
  "points": 340
}
```

The `points` field is the available balance: live earned points minus redeemed
points. Expired points do not count. See
[Balance](https://docs.loybox.com.ar/referencia-tecnica#saldo).

## Errors
| Code  | When                            |
| ----- | ------------------------------- |
| `404` | The client does not exist.      |
| `422` | The code is not a valid format. |
