API – Organization¶
Paths are under https://api.innovanet.com. Header Authorization: Bearer inv_mcp_…. The innovanet() function is in the API chapter. Writing org units requires permission for the organization.
GET /api/org/persons¶
| Parameter | Type | Required | Description |
|---|---|---|---|
page |
integer | no | default 1 |
per_page |
integer | no | default 20, at most 100 |
search |
string | no | |
user_type |
string | no | Intern or Extern |
active_only |
boolean | no | yes by default |
org_unit_id |
integer | no | |
account_unit_id |
integer | no | branch |
$res = innovanet('GET', '/api/org/persons?page=1&per_page=20&search=Novák');
Response 200
{
"success": true,
"data": {
"data": [
{
"id": 4,
"user_id": 15,
"primary_ou_name": "Obchod",
"primary_position_name": "Manažér",
"manager_name": "Peter Horváth"
}
],
"total": 1,
"page": 1,
"per_page": 20
}
}
The list of people is in data.data. Your manager: GET /api/org/my-boss. Tree: GET /api/org/tree. Org units: GET /api/org/org-units. Positions: GET /api/org/positions.
POST /api/org/org-units¶
The name is an object by language. Fill in at least one language.
| Field | Type | Required | Description |
|---|---|---|---|
name |
object | yes | name.sk, name.cs, name.en |
parentId |
integer | no | parent org unit |
accountUnitId |
integer | no | branch |
costCenter |
string | no | |
approving |
integer | no | whether the manager approves |
Request
{
"name": { "sk": "Obchod", "cs": "Obchod", "en": "Sales" },
"parentId": null,
"approving": 1
}
PHP
$res = innovanet('POST', '/api/org/org-units', [
'name' => ['sk' => 'Obchod', 'cs' => 'Obchod', 'en' => 'Sales'],
'approving' => 1,
]);
Response 201
{
"success": true,
"data": {
"id": 9,
"name": { "sk": "Obchod", "cs": "Obchod", "en": "Sales" },
"parentId": null,
"approving": 1
}
}
Assigning a person to an org unit: POST /api/org/assignments.
Other paths¶
Each path below belongs to this module. Field names are the ones the API reads. A downloaded file is not JSON.
GET /api/org/permission¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/persons/by-user/{userId}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/persons/by-tenant-user/{tenantUserId}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/persons/{id}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
PUT /api/org/persons/{id}¶
Body
| Field | Type | Required |
|---|---|---|
user_id |
integer | no |
external_name |
string | no |
external_last_name |
string | no |
external_email |
string | no |
external_phone |
string | no |
external_note |
string | no |
active |
boolean | no |
{
"user_id": 1,
"external_name": "text",
"external_last_name": "text",
"external_email": "text",
"external_phone": "text",
"external_note": "text",
"active": true
}
$res = innovanet('PUT', '/api/org/persons/1', [
'user_id' => 1,
'external_name' => 'text',
'external_last_name' => 'text',
'external_email' => 'text',
'external_phone' => 'text',
'external_note' => 'text',
'active' => true,
]);
Response 200 – Envelope { "success": true, "data": ... }.
DELETE /api/org/persons/{id}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/my-head-boss¶
Parameters
| Field | Type | Required |
|---|---|---|
date |
string | no |
The API reads these fields. A field is required when the table says yes.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/boss/{ouId}/{date}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/subordinates¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/org-units/{id}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/org-units/{id}/assignments¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
PUT /api/org/org-units/{id}¶
Body
| Field | Type | Required |
|---|---|---|
name |
array | no |
name.sk |
string | no |
name.cs |
string | no |
name.en |
string | no |
printName |
array | no |
printName.sk |
string | no |
printName.cs |
string | no |
printName.en |
string | no |
costCenter |
string | no |
parentId |
integer | no |
accountUnitId |
integer | no |
approving |
integer | no |
{
"name": [],
"name.sk": "text",
"name.cs": "text",
"name.en": "text",
"printName": [],
"printName.sk": "text",
"printName.cs": "text",
"printName.en": "text",
"costCenter": "text",
"parentId": 1,
"accountUnitId": 1,
"approving": 1
}
$res = innovanet('PUT', '/api/org/org-units/1', [
'name' => [],
'name.sk' => 'text',
'name.cs' => 'text',
'name.en' => 'text',
'printName' => [],
'printName.sk' => 'text',
'printName.cs' => 'text',
'printName.en' => 'text',
'costCenter' => 'text',
'parentId' => 1,
'accountUnitId' => 1,
'approving' => 1,
]);
Response 200 – Envelope { "success": true, "data": ... }.
DELETE /api/org/org-units/{id}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/positions/export-csv¶
No body.
Response – The response is a file, not JSON.
GET /api/org/positions/import-template¶
No body.
Response – The response is a file, not JSON.
POST /api/org/positions/import¶
Import job positions from CSV with Organisation permission. The required file uses name_sk, name_cs and name_en headers, with at least one name per row. Success: 200 with data.imported, data.failed and data.log; no valid file returns 400.
| Field | Type | Required |
|---|---|---|
file |
file | yes |
Send the file as multipart/form-data. Bash example:
curl -sS -X POST "https://api.innovanet.com/api/org/positions/import" -H "Authorization: Bearer inv_mcp_…" -H "Accept: application/json" -F "file=@positions.csv"
GET /api/org/positions/{id}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
PUT /api/org/positions/{id}¶
Body
| Field | Type | Required |
|---|---|---|
name |
array | no |
name.sk |
string | no |
name.cs |
string | no |
name.en |
string | no |
{
"name": [],
"name.sk": "text",
"name.cs": "text",
"name.en": "text"
}
$res = innovanet('PUT', '/api/org/positions/1', [
'name' => [],
'name.sk' => 'text',
'name.cs' => 'text',
'name.en' => 'text',
]);
Response 200 – Envelope { "success": true, "data": ... }.
DELETE /api/org/positions/{id}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
GET /api/org/org-units/{ouId}/boss-periods¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
PUT /api/org/org-units/{ouId}/boss¶
Body
| Field | Type | Required |
|---|---|---|
boss_person_id |
string | no |
valid_from |
string | no |
valid_to |
string | no |
{
"boss_person_id": "text",
"valid_from": "text",
"valid_to": "text"
}
$res = innovanet('PUT', '/api/org/org-units/1/boss', [
'boss_person_id' => 'text',
'valid_from' => 'text',
'valid_to' => 'text',
]);
The API reads these fields. A field is required when the table says yes.
Response 200 – Envelope { "success": true, "data": ... }.
PUT /api/org/assignments/{id}¶
Body
| Field | Type | Required |
|---|---|---|
organization_person_id |
integer | no |
organizational_unit_id |
integer | no |
position_id |
integer | no |
valid_from |
date | no |
valid_to |
date | no |
sort_order |
integer | no |
{
"organization_person_id": 1,
"organizational_unit_id": 1,
"position_id": 1,
"valid_from": "2026-11-05",
"valid_to": "2026-11-05",
"sort_order": 1
}
$res = innovanet('PUT', '/api/org/assignments/1', [
'organization_person_id' => 1,
'organizational_unit_id' => 1,
'position_id' => 1,
'valid_from' => 'text',
'valid_to' => 'text',
'sort_order' => 1,
]);
Response 200 – Envelope { "success": true, "data": ... }.
DELETE /api/org/assignments/{id}¶
No body.
Response 200 – Envelope { "success": true, "data": ... }.
Want to try this feature? Start your innovanet trial →