# List member fields

> Source: https://elaichi.ai/docs/api-reference/members/member-attribute/listmemberattributes/

`GET /member-attribute`

Resource: **Member Attribute** · API: **Members**

## Query parameters

- **`q`** _(string)_
  Prefix match on the field key or label. LIKE wildcards are matched literally. Max 200 characters.

## Response body

- **`result`** _(array<object>)_
  - **`id`** _(string)_
    Member field id (`mad_…`).
  - **`key`** _(string)_
    What placeholders name: `{{caller.attributes.<key>}}`. Immutable.
  - **`label`** _(string)_
  - **`description`** _(string,null)_
  - **`type`** _(string)_
    Immutable.
    Allowed: `text`, `number`, `boolean`, `text_list`
  - **`source`** _(string)_
    `manual`: an admin types the values. `scim`: your identity provider fills them; nobody can type one.
    Allowed: `manual`, `scim`
  - **`scim_path`** _(string,null)_
    For `source: scim`: the SCIM User attribute it mirrors (enterprise extension, or core `title`).
    Allowed: `employeeNumber`, `department`, `costCenter`, `division`, `organization`, `manager.value`, `title`, `null`
  - **`created_at`** _(string)_
  - **`updated_at`** _(string)_
  - **`can_manage`** _(boolean)_
    You hold `member:manage`: you may edit or delete this field.
  - **`can_set_values`** _(boolean)_
    `can_manage` and the field is `manual`. False for a SCIM field even for an admin.
  - **`value_count`** _(integer,null)_
    How many current members hold a value for this field. Null unless you hold `member:manage`. The members without one: `GET /member?attribute_missing=<key>`.
  - **`member_count`** _(integer,null)_
    How many current members the organization has (the set `GET /member` lists). Null unless you hold `member:manage`.
- **`next_cursor`** _(string,null)_
- **`prev_cursor`** _(string,null)_

## Code examples

### curl

```bash
curl -X GET 'https://api.elaichi.ai/member-attribute' \
  -H 'Authorization: Bearer $ELAICHI_API_TOKEN' \
  -H 'Content-Type: application/json'
```

### JavaScript

```javascript
const response = await fetch('https://api.elaichi.ai/member-attribute', {
  method: 'GET',
  headers: {
    'Authorization': 'Bearer ' + process.env.ELAICHI_API_TOKEN,
    'Content-Type': 'application/json',
  },
});

const data = await response.json();
console.log(data);
```

### Python

```python
import os
import requests

url = "https://api.elaichi.ai/member-attribute"
headers = {
    "Authorization": f"Bearer {os.environ['ELAICHI_API_TOKEN']}",
    "Content-Type": "application/json",
}

response = requests.get(url, headers=headers)
print(response.json())
```
