Organizations API
The Organizations API allows you to retrieve your organization’s hierarchical structure. For holding companies with subsidiaries, this provides a complete tree view of all child organizations and their relationships.New API: This endpoint is part of the new API architecture with improved design and maintainability.
Key Features
- Organization Tree: View the complete hierarchical structure from the top-level holding down to all subsidiaries and child organizations
- Automatic Root Detection: Always returns the full tree from the root organization, regardless of which organization the API key belongs to
- Clean & Simple: Minimal response with just the essential fields (id, name, children)
Authentication
All endpoints require authentication using either:- API Key: Include in
x-api-keyheader - JWT Token: Include in
Authorizationheader asBearer {JWT_TOKEN}
Headers
All requests must include:Your API key for authenticationExample:
sk_live_1234567890abcdefYour organization UUIDExample:
a8315ef3-dd50-43f8-b7ce-d839e68d51faAvailable Endpoints
Data Model
Organization Tree Node
Each node in the tree represents an organization:Node Attributes
| Field | Type | Description |
|---|---|---|
id | UUID | Unique identifier for the organization |
name | string | Organization name |
children | array | List of child organization nodes (same structure, recursive) |
Use Cases
View Holding Structure
Retrieve the full organization tree for a holding company:Find Specific Subsidiaries
Navigate the tree to find specific child organizations:Error Handling
Common HTTP Status Codes
| Status | Meaning | Solution |
|---|---|---|
| 200 | Success | - |
| 401 | Unauthorized | Verify API key |
| 404 | Not Found | Check organization UUID |
| 500 | Server Error | Contact support if persists |
Error Response Format
Related Documentation
Authentication Guide
Learn how to authenticate API requests
Vehicles API
Manage vehicles within organizations
Employees API
Manage employee commuting data
Invoices API
Manage invoices for organizations
Rate Limiting
API requests are subject to rate limiting. Include rate limit information from response headers:X-RateLimit-Limit: Maximum requests per minuteX-RateLimit-Remaining: Requests remainingX-RateLimit-Reset: Unix timestamp when limit resets

