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

# Onboarding Tasks

> Returns the list of onboarding tasks for the authenticated customer.

# Onboarding Tasks

Returns the current onboarding checklist for the authenticated customer. Tasks include items like completing their profile, adding directors, setting mail preferences, identity checks, or setting up e-invoicing. Used to display onboarding progress on the dashboard.

## Authentication

Requires a valid customer bearer token.

## Response

Returns an array of `OnBoardingTask` objects with completion status.

### Task Fields

| Field        | Type      | Description                                                                                  |
| ------------ | --------- | -------------------------------------------------------------------------------------------- |
| `CoworkerId` | `number`  | Numeric identifier for the customer the task belongs to                                      |
| `GroupId`    | `string`  | UUID that groups related tasks together (e.g. all virtual office tasks share the same group) |
| `Type`       | `string`  | The onboarding category. See [Task Types](#task-types) below                                 |
| `Action`     | `string`  | The specific action required. See [Task Actions](#task-actions) below                        |
| `Completed`  | `boolean` | Whether the customer has completed this task                                                 |

### Task Types

| Value                   | Description                                              |
| ----------------------- | -------------------------------------------------------- |
| `VirtualOffice`         | Virtual office setup tasks (directors, mail, recipients) |
| `IdentityCheck`         | Identity verification tasks                              |
| `DeferredRequiredField` | Required profile fields that must be completed later     |
| `CompleteProfile`       | Personal profile completion                              |
| `CompleteTeamProfile`   | Team profile completion                                  |
| `UnpaidInvoices`        | Outstanding invoices that need payment                   |
| `PendingDelivery`       | Pending mail or package deliveries                       |
| `EInvoicing`            | Electronic invoicing setup                               |

### Task Actions

| Value                    | Applicable Type(s)               | Description                                      |
| ------------------------ | -------------------------------- | ------------------------------------------------ |
| `AddDirectors`           | `VirtualOffice`                  | Add company directors to the virtual office      |
| `AddRecipients`          | `VirtualOffice`                  | Add mail recipients for the virtual office       |
| `SetMailPreferences`     | `VirtualOffice`                  | Configure mail handling preferences              |
| `StartIdentityChecks`    | `IdentityCheck`                  | Initiate identity verification                   |
| `CompleteIdentityChecks` | `IdentityCheck`, `VirtualOffice` | Finish all identity verification steps           |
| `CompleteProfile`        | `CompleteProfile`                | Fill in all required profile fields              |
| `PublishProfile`         | `CompleteProfile`                | Make the member profile visible in the directory |
| `CompleteTeamProfile`    | `CompleteTeamProfile`            | Fill in all required team profile fields         |
| `AddEInvoicingDetails`   | `EInvoicing`                     | Add electronic invoicing details                 |

## Examples

### Fetch onboarding tasks

```http theme={null}
GET /api/public/onboarding
Authorization: Bearer {token}
```

### Response — Virtual office tasks (mixed completion)

```json theme={null}
[
  {
    "CoworkerId": 4706,
    "GroupId": "ad1d8608-9b95-454a-9a1c-944980f7eca5",
    "Type": "VirtualOffice",
    "Action": "AddDirectors",
    "Completed": true
  },
  {
    "CoworkerId": 4706,
    "GroupId": "ad1d8608-9b95-454a-9a1c-944980f7eca5",
    "Type": "VirtualOffice",
    "Action": "CompleteIdentityChecks",
    "Completed": true
  },
  {
    "CoworkerId": 4706,
    "GroupId": "ad1d8608-9b95-454a-9a1c-944980f7eca5",
    "Type": "VirtualOffice",
    "Action": "SetMailPreferences",
    "Completed": false
  }
]
```

### Response — Identity check tasks

```json theme={null}
[
  {
    "CoworkerId": 4706,
    "GroupId": "b2e4f910-3c78-4d1a-a5ef-82710dc3b6f1",
    "Type": "IdentityCheck",
    "Action": "StartIdentityChecks",
    "Completed": false
  },
  {
    "CoworkerId": 4706,
    "GroupId": "b2e4f910-3c78-4d1a-a5ef-82710dc3b6f1",
    "Type": "IdentityCheck",
    "Action": "CompleteIdentityChecks",
    "Completed": false
  }
]
```

### Response — Multiple task types

```json theme={null}
[
  {
    "CoworkerId": 4706,
    "GroupId": "ad1d8608-9b95-454a-9a1c-944980f7eca5",
    "Type": "VirtualOffice",
    "Action": "AddDirectors",
    "Completed": false
  },
  {
    "CoworkerId": 4706,
    "GroupId": "ad1d8608-9b95-454a-9a1c-944980f7eca5",
    "Type": "VirtualOffice",
    "Action": "SetMailPreferences",
    "Completed": true
  },
  {
    "CoworkerId": 4706,
    "GroupId": "ad1d8608-9b95-454a-9a1c-944980f7eca5",
    "Type": "VirtualOffice",
    "Action": "AddRecipients",
    "Completed": true
  },
  {
    "CoworkerId": 4706,
    "GroupId": "b2e4f910-3c78-4d1a-a5ef-82710dc3b6f1",
    "Type": "IdentityCheck",
    "Action": "StartIdentityChecks",
    "Completed": false
  },
  {
    "CoworkerId": 4706,
    "GroupId": "b2e4f910-3c78-4d1a-a5ef-82710dc3b6f1",
    "Type": "IdentityCheck",
    "Action": "CompleteIdentityChecks",
    "Completed": false
  },
  {
    "CoworkerId": 4706,
    "GroupId": "f1a2b3c4-5678-9def-abcd-ef0123456789",
    "Type": "CompleteProfile",
    "Action": "CompleteProfile",
    "Completed": false
  },
  {
    "CoworkerId": 4706,
    "GroupId": "f1a2b3c4-5678-9def-abcd-ef0123456789",
    "Type": "EInvoicing",
    "Action": "AddEInvoicingDetails",
    "Completed": false
  }
]
```

### Response — No pending tasks

```json theme={null}
[]
```

## TypeScript Integration

```typescript theme={null}
import endpoints from '@/api/endpoints'

const response = await httpClient.get(endpoints.onboarding.tasks)
```

### Types

```typescript theme={null}
import type { OnBoardingTask, OnBoardingTasks } from '@/types/endpoints/OnBoardingTasks'
import { eOnBoardingType, eOnBoardingAction } from '@/types/endpoints/OnBoardingTasks'
```
