An async Python client for the decidalo V3 Import API
Project description
decidalo_client.py
This repository contains two async Python clients for decidalo:
| Client | API | Purpose |
|---|---|---|
DecidaloClient (Import Client) |
V3 Import API | Bulk-importing data (users, teams, projects, bookings, ...) into decidalo |
DecidaloAppClient (App Client) |
App API (api.decidalo.app) |
Reading data from decidalo: searching people, viewing profiles, skills, certificates, projects |
Use the Import Client when you need to push data into decidalo (e.g. syncing users from an HR system). Use the App Client when you need to read data from decidalo (e.g. finding people with specific skills).
[!IMPORTANT] This is a community project and is NOT an official decidalo client. It is not affiliated with or endorsed by Data Assessment Solutions GmbH.
Installation
pip install decidalo-client
Import Client (DecidaloClient)
The Import Client wraps the decidalo V3 Import API (Swagger UI). It is used for bulk-importing data into decidalo using an API key.
import asyncio
from decidalo_client import DecidaloClient, DecidaloAPIError, DecidaloAuthenticationError
async def main() -> None:
async with DecidaloClient(api_key="your-api-key") as client:
# Get all users
users = await client.get_users()
for user in users:
print(f"{user.displayName} ({user.email})")
# Get all projects
projects = await client.get_all_projects()
for project in projects:
print(f"{project.properties.name.value}")
if __name__ == "__main__":
asyncio.run(main())
Error Handling
import asyncio
from decidalo_client import DecidaloClient, DecidaloAPIError, DecidaloAuthenticationError
async def main() -> None:
async with DecidaloClient(api_key="your-api-key") as client:
try:
users = await client.get_users()
except DecidaloAuthenticationError as e:
print(f"Authentication failed: {e.message}")
except DecidaloAPIError as e:
print(f"API error {e.status_code}: {e.message}")
if __name__ == "__main__":
asyncio.run(main())
Import Client Features
- Async HTTP client built on
aiohttp - Type-safe request/response models using
pydantic - All major API endpoints:
- Users - Get users, import users (sync/async), check import status
- Teams - Get teams, import teams (sync/async), check import status
- Companies - Get companies, import companies
- Projects - Get projects, get all projects, import projects, check existence
- Bookings - Get bookings, get bookings by project, import bookings
- Absences - Get absences, import absences
- Resource Requests - Get resource requests, import resource requests
- Roles - Import roles
- Working Time Patterns - Get working time patterns, import working time patterns
App Client (DecidaloAppClient)
The App Client wraps the decidalo App API (api.decidalo.app).
It is used for reading data from decidalo — searching for people, viewing profiles, exploring skills, certificates, and projects.
[!NOTE] The App API does not have a public Swagger UI. The client was reverse-engineered from the decidalo web application.
Authentication
The App Client authenticates via OAuth2 (Microsoft SSO) through login.decidalo.app.
There are two authentication flows:
- Device Code Flow (interactive, for first-time setup) — prints a URL and code to the console for you to open in a browser.
- Refresh Token Flow (headless, for automation) — reuses a previously obtained refresh token.
import asyncio
from decidalo_app_client import DecidaloAppClient
from decidalo_app_client.auth import DecidaloAuth
async def first_time_login() -> None:
"""Interactive login — run this once to obtain a refresh token."""
token = await DecidaloAuth.device_code_login()
# The device code flow prints a URL and code to the console.
# Open the URL in your browser and enter the code to authenticate.
print(f"Save this refresh token for future use: {token.refresh_token}")
asyncio.run(first_time_login())
Store the refresh token securely (e.g. in an environment variable or a secrets manager). For subsequent runs, use the refresh token:
token = await DecidaloAuth.refresh("your-saved-refresh-token")
Minimal Working Example
import asyncio
from decidalo_app_client import DecidaloAppClient
from decidalo_app_client.auth import DecidaloAuth
async def main() -> None:
# Use a refresh token obtained from a previous device_code_login()
token = await DecidaloAuth.refresh("your-saved-refresh-token")
async with DecidaloAppClient(token=token) as client:
# Search for people with specific skills
results = await client.search.find_people(keywords=["SAP", "Python"])
for user in results.usersWithMatchedQualities:
print(f"User {user.userId} (Score: {user.score})")
# Get a user's profile header
header = await client.profile.get_header(user_id=42)
print(f"Profile quality: {header.profileQuality}, last edited by: {header.lastEditor}")
# Browse available skill categories
categories = await client.skills.get_categories()
for cat in categories:
print(f"Category: {cat.categoryName}")
asyncio.run(main())
You can also pass a static Bearer token string directly if you manage tokens yourself:
async with DecidaloAppClient(token="your-bearer-token") as client:
...
App Client Features
- Async HTTP client built on
aiohttpwith automatic token refresh - OAuth2 Device Code Flow and Refresh Token Flow (direct OIDC HTTP, no extra dependency)
- Type-safe Pydantic models for most responses
- Domain-based API structure:
- Search — Find people by skills/keywords, autocomplete user names, get filter fields
- Profile — Read profile headers, skills, certificates, languages, industries, roles, competencies, projects
- Projects — Get project headers, overviews, details, team members, references
- Skills — Autocomplete skills, get levels, categories, skill grids, assessments
- Certificates — Autocomplete certificates, get holders, certificate grids
- Roles — Get roles, check user skills/certificates against role requirements
- Teams — Get team details, find teams by manager, get members under current user
Development
Clone the repository and install the development environment:
git clone https://github.com/Hochfrequenz/decidalo_client.py.git
cd decidalo_client.py
tox -e dev
To regenerate the Pydantic models from the OpenAPI spec:
tox -e codegen
For detailed information on the development setup (tox configuration, IDE setup, etc.), see the Hochfrequenz Python Template Repository.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file decidalo_client-0.1.0.tar.gz.
File metadata
- Download URL: decidalo_client-0.1.0.tar.gz
- Upload date:
- Size: 86.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5b232a476af6465d22d4bef04fa70ab2933f37a9a2b2f4210a1fbbc9e14bb511
|
|
| MD5 |
087d8caa8463f946780e8a0e5df952f8
|
|
| BLAKE2b-256 |
825f8c05fdac17298b82addb0e0818773b6fd4344c5ad889239b2e951b96c069
|
Provenance
The following attestation bundles were made for decidalo_client-0.1.0.tar.gz:
Publisher:
python-publish.yml on Hochfrequenz/decidalo_client.py
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
decidalo_client-0.1.0.tar.gz -
Subject digest:
5b232a476af6465d22d4bef04fa70ab2933f37a9a2b2f4210a1fbbc9e14bb511 - Sigstore transparency entry: 1134004872
- Sigstore integration time:
-
Permalink:
Hochfrequenz/decidalo_client.py@40546515d7892c27a2bd8b63424fbf33bc002508 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Hochfrequenz
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@40546515d7892c27a2bd8b63424fbf33bc002508 -
Trigger Event:
release
-
Statement type:
File details
Details for the file decidalo_client-0.1.0-py3-none-any.whl.
File metadata
- Download URL: decidalo_client-0.1.0-py3-none-any.whl
- Upload date:
- Size: 42.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e9b15fbc6536572360ccd5c73074d08c9c1ce70632e02cd54a4aa8fe5dfbc191
|
|
| MD5 |
788a3fcbd50b66b69ae89db2e2216068
|
|
| BLAKE2b-256 |
582ae744fa9be133556d1b510e95876eec4d7072de889f383eede0c3f7e25228
|
Provenance
The following attestation bundles were made for decidalo_client-0.1.0-py3-none-any.whl:
Publisher:
python-publish.yml on Hochfrequenz/decidalo_client.py
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
decidalo_client-0.1.0-py3-none-any.whl -
Subject digest:
e9b15fbc6536572360ccd5c73074d08c9c1ce70632e02cd54a4aa8fe5dfbc191 - Sigstore transparency entry: 1134004909
- Sigstore integration time:
-
Permalink:
Hochfrequenz/decidalo_client.py@40546515d7892c27a2bd8b63424fbf33bc002508 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/Hochfrequenz
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@40546515d7892c27a2bd8b63424fbf33bc002508 -
Trigger Event:
release
-
Statement type: