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

# API and organization structure sync

> How to connect an HR system or 1C to the company through the API: which operations are available, external IDs and sync rules

If you keep HR records in 1C, your own HR system or another service, you can sync the organization structure
with Exode through the API. Your system creates departments and positions, hires, transfers and
dismisses employees, and sends absences. Exode applies the same rules to these changes as to
changes made in the interface, including automatic course assignment.

This page describes what the API can do for business and HR. The technical description of the requests is in the
[developer documentation](https://docs.exode.biz/). General information about API keys is in
[API](https://faq.exode.biz/en/general/developers/api.md).

## Company API key

Keys are created in **Company → For developers → API keys**.

* A company can have up to 5 API keys. More are available on request to support: “API keys limit is 5. Contact
  support”.
* The key is shown only once, right after it is issued. Save it.
* **Reissue the API key** issues a new key, and the old one stops working right away.
* In a company, a new key gets organization structure permissions (“Staff management” and “Staff browsing”)
  and does not get sales and refund permissions. You can change the key's permissions.

## What you can do through the API

| Section | Operations |
| - | - |
| **Departments** | Get the tree and the list, create, change, delete, set the parent department and the main manager |
| **Positions** | Get the list, create, change, delete, set the position's grades and departments |
| **Grades** | Get the list, create, change, delete |
| **Employee assignments** | Get the list, hire, transfer to another department, change position or grade, dismiss |
| **Department managers** | Assign, remove |
| **Absences** | Get the list, create, change, delete |
| **Users** | Create, update, create or update in one operation, find, get the list, delete |

Organization structure operations work only in a corporate company. They are not available in an online school.

## External IDs

To avoid storing Exode IDs on your side, send your own: a personnel number, a department code from 1C and
so on. Almost every operation can be performed either by the Exode ID or by your external
ID.

| Object | Uniqueness rule |
| - | - |
| Department, position, grade, absence | The external ID is unique in the company |
| Employee assignment | Unique among active assignments. Stays with the employee after a transfer or position change |
| Department manager | Unique in the company |

If the ID is already taken, the operation returns an error, for example “External employment ID is not
unique” or “External grade ID is not unique”.

## How to sync employees

**1. Send the structure**

Create departments from the top down: parent ones first, then nested ones. Then create positions and, if
needed, grades.

**2. Create accounts**

Create a user and pass their department, position and grade right away. In a company, a user without
a department is not created: “Required employment data is missing”.

**3. Send HR events**

Send transfers, position changes and dismissals as separate operations by the external ID of the
assignment.

**4. Send absences**

Create vacations, sick leave and business trips per employee and update them by your own ID.

> [!TIP]
>
> For regular reconciliation, use the “create or update” user operation. Sending the same
> employee again with the same department and position does not create a duplicate: Exode returns the existing assignment and, if
> it does not have an external ID yet, links yours.

## Rules that also apply in the API

| Rule | Error |
| - | - |
| You can hire only a user who already exists in the company | An error: user not found |
| A person cannot have two identical assignments in one department | “This employee assignment already exists” |
| A position is assigned only in allowed departments | “The position is not available in this department” |
| The grade must be one of the position's grades | “This grade does not apply to the position” |
| A grade can be given only if grades are turned on | “Grades are turned off in the org structure settings” |
| The date of a transfer, position change or dismissal cannot fall outside the assignment period | “Invalid assignment change date” |
| A department cannot be moved inside its own branch | “A department cannot be moved inside its own branch” |
| You can delete only an empty department and a position or grade without employees | A deletion error |
| You cannot dismiss the company owner | “Cannot remove the school owner's last assignment” |
| Records from Verifix are changed only in Verifix | “This record is managed in an external system (Verifix) — change it there” |

## What happens after changes through the API

* **Hiring, transfer, position or grade change**: the automatic assignment rules are checked within a minute or two. See
  [Automatic course assignment](https://faq.exode.biz/en/corporate/auto-assignment.md).
* **Dismissal from the last department**: the account gets the “Dismissed” status, and sign-in is closed.
  Data and progress are kept.
* **Rehiring a dismissed employee**: the account becomes active again.
* **Deleting a user**: all their assignments are closed.

## Webhooks

Webhooks in a company work the same way as in an online school: see [Webhooks](https://faq.exode.biz/en/general/developers/webhooks.md).
Events about payments, refunds and enrollment via payment are not available in a company. Webhooks are in
**Company → For developers → Webhooks**.

## Frequently asked questions

> **Can I hire an employee who does not have an account yet?**
>
> No. First create the user and pass the department when you create them: then the account and the assignment
> appear in one operation.

> **How do I send a transfer to another department together with a new position?**
>
> With one transfer operation: in it you can specify the new department, the new position and the grade. The position
> is checked for the new department.

> **What happens if I send a backdated dismissal?**
>
> The dismissal date cannot be earlier than the start of the assignment. If the date is earlier, you get the “Invalid
> assignment change date” error.

> **Is the external ID kept after a transfer?**
>
> Yes. The external ID of the assignment moves to the new assignment, so you can send the next operations
> by the same ID.

> **Can I use the API and Verifix at the same time?**
>
> Yes, but you cannot change records from Verifix through the API: they are changed only in Verifix. Use the API to manage
> the records that do not come from Verifix.

> **Why do organization structure operations return an access error?**
>
> The key does not have the “Staff management” or “Staff browsing” permission. Check the key's permissions in the
> **API keys** section.

> **Are there webhooks about hiring and dismissing employees?**
>
> No. You send HR events to Exode yourself, so they are already in your system. Webhooks report
> learning and user events, for example a course completion or a certificate being issued.

***

*Updated: 2026-10-15 18:32 UTC*


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.