# Filtering clients

Below is a list of attributes available for [filtering](https://docs.complycube.com/documentation/api-reference/filtering) clients.

<table><thead><tr><th width="411.1984515650572" valign="top">Attribute</th><th>Type</th></tr></thead><tbody><tr><td valign="top"><code>type</code></td><td>string<br><br>Valid values are <code>person</code> and <code>company</code>.</td></tr><tr><td valign="top"><code>email</code></td><td>string</td></tr><tr><td valign="top"><code>joinedDate</code></td><td>string</td></tr><tr><td valign="top"><code>mobile</code></td><td>string</td></tr><tr><td valign="top"><code>telephone</code></td><td>string</td></tr><tr><td valign="top"><code>externalId</code></td><td>string</td></tr><tr><td valign="top"><code>personDetails.firstName</code></td><td>string</td></tr><tr><td valign="top"><code>personDetails.middleName</code></td><td>string</td></tr><tr><td valign="top"><code>personDetails.lastName</code></td><td>string</td></tr><tr><td valign="top"><code>personDetails.dob</code></td><td>string</td></tr><tr><td valign="top"><code>personDetails.gender</code></td><td>string</td></tr><tr><td valign="top"><code>personDetails.nationality</code></td><td>string</td></tr><tr><td valign="top"><code>personDetails.birthCountry</code></td><td>string</td></tr><tr><td valign="top"><code>companyDetails.name</code></td><td>string</td></tr><tr><td valign="top"><code>companyDetails.website</code></td><td>string</td></tr><tr><td valign="top"><code>companyDetails.registrationNumber</code></td><td>string</td></tr><tr><td valign="top"><code>companyDetails.incorporationType</code></td><td>string</td></tr><tr><td valign="top"><code>companyDetails.incorporationCountry</code></td><td>string</td></tr><tr><td valign="top"><code>metadata.{yourCustomKey}</code></td><td>string</td></tr></tbody></table>

#### Example - Get all clients for one type

In the example below, we will request to get all clients that are of type `company`.

{% tabs %}
{% tab title="cURL" %}

```bash
curl -X GET https://api.complycube.com/v1/clients?type=company \
     -H 'Authorization: <YOUR_API_KEY>'
```

{% endtab %}

{% tab title="Python" %}

```python
from complycube import ComplyCubeClient
cc_api = ComplyCubeClient(api_key='<YOUR API KEY>')

filter = { 'type':'company' }

companies = cc_api.clients.list(filter)
```

{% endtab %}

{% tab title="PHP" %}

```php
use ComplyCube\ComplyCubeClient;

$ccapi = new ComplyCubeClient('<YOUR API KEY>');

$companies = $ccapi->clients()->list(['type' => 'company']);
```

{% endtab %}

{% tab title=".NET" %}

```csharp
using ComplyCube.Net;
using ComplyCube.Net.Resources.Clients;

var clientApi = new ClientApi(new ComplyCubeClient("<YOUR_API_KEY>"));

var filter = new ClientRequest { type = "company" };

var companies = await clientApi.ListAsync(filter);
```

{% endtab %}
{% endtabs %}
