# Offboarding preflight for member removal

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

`GET /member/{userId}/offboarding`

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

## Path parameters

- **`userId`** _(string, required)_
  User id (`usr_…`) of an org member.

## Response body

- **`user_id`** _(string)_
- **`connections`** _(array<object>)_
  Every connection the member owns: `connection`, `referenced_by`, `private`, `needs_resolution` (informational), `references`, `replacement_candidates`, `replacement_candidate_count`.
- **`no_eligible_successor`** _(boolean)_
  True when the member owns connectors and nobody can receive them: no active member other than the leaver and the caller exists, and the caller lacks `connector:manage` so cannot take them either. `DELETE /member/{userId}` cannot succeed until another member is invited. Always false when `connectors` is empty. A bounded existence check, never a member count.
- **`sole_successor`** _(boolean)_
  True when the member owns connectors, no active member other than the leaver and the caller exists, and the caller holds `connector:manage`: the caller may then name themselves as the connector recipient (audited as `self_assigned_sole_successor`). Connectors only. Mutually exclusive with `no_eligible_successor`; always false when `connectors` is empty.
- **`connectors`** _(array<object>)_
  Every custom connector the member owns: `slug`, `name`, `logo`, `owner_user_id`, `private`, the bounded `shared_with` rollup, `connection_count`, `needs_resolution` (always true: every connector needs a new owner) and timestamps. Resolved by `connector_actions` on `DELETE /member/{userId}`.
- **`delegated_entries`** _(array<object>)_
  Non-blocking (§6): entries elsewhere in the org whose delegation chain depends on this member, independent of which connections they own.
  - **`toolbox_id`** _(string)_
  - **`toolbox_name`** _(string)_
  - **`entry_id`** _(string)_
  - **`connector_slug`** _(string,null)_
  - **`tool_name`** _(string,null)_
  - **`connection_id`** _(string,null)_

## Code examples

### curl

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

### JavaScript

```javascript
const response = await fetch('https://api.elaichi.ai/member/<userId>/offboarding', {
  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/<userId>/offboarding"
headers = {
    "Authorization": f"Bearer {os.environ['ELAICHI_API_TOKEN']}",
    "Content-Type": "application/json",
}

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