Expand description
Rust SDK for the babelforce manager APIs — auth, user & agent management, call reporting, metrics, and task automations.
One client, configured once, exposes resource namespaces over the API. The low-level clients
under [gen] are generated from the OpenAPI specs and are an internal detail; the public surface
is the hand-written facade.
use babelforce_manager_sdk::{ManagerClient, Auth};
let mgr = ManagerClient::connect(Auth::ClientCredentials {
client_id: "…".into(),
client_secret: "…".into(),
})
.await?;
for user in mgr.users.list_all().await? {
println!("{:?}", user.email);
}Structs§
- Agent
Groups Resource - Agent groups —
/api/v2/agents/groups. - Agents
Resource - Agent management —
/api/v2/agents, with a nestedgroupssub-resource. - Applications
Resource - Applications —
/api/v2/applications, with a nestedlocal_automationssub-resource. - Auth
Resource - OAuth 2.0 endpoints —
/oauth/authorize,/oauth/token,/oauth/revoke. - Automations
Resource - Global automations (event triggers) —
/api/v2/events/triggers. - Babeldesk
Resource - Babeldesk dashboards —
/api/v2/babeldesk, with a nestedwidgetssub-resource. - Babeldesk
Widgets Resource - Babeldesk widgets —
/api/v2/babeldesk/widgets. - Business
Hours Resource - Business hours —
/api/v2/business-hours. - Calendars
Resource - Calendars —
/api/v2/calendars. - Call
Report Filter - Filters for the detailed call report (
/api/v2/calls/reporting). String-typed on purpose — values are validated against the API’s enums on use, so a bad value is anManagerError::InvalidArgumentnaming the field, never a silent mismatch. - Calls
Resource - Call reporting and call control —
/api/v2/calls, with a nestedreportingsub-resource. - Campaigns
Resource - Outbound campaigns —
/api/v2/outbound/campaigns. - Conferences
Resource - Conferences —
/api/v2/conferences. - Conversations
Resource - Conversations —
/api/v2/conversations, including their events and session variables. - Dashboards
Resource - Reporting dashboards —
/api/v2/dashboards, with per-dashboard user management. - Dialer
Behaviours Resource - Dialer behaviours —
/api/v2/outbound/dialer-behaviours. - Dialer
Resource - Dialer runtime & reporting —
/api/v2/dialer, with a nestedbehaviourssub-resource. - Events
Resource - Event definitions & custom events —
/api/v2/events. - Expressions
Resource - Expressions —
/api/v2/expressions. The catalog of available expressions plus an evaluator. - Files
Resource - Stored files —
/api/v2/files(recordings, prompts and backups). - Integrations
Resource - Integrations —
/api/v2/integrations. - Local
Automations Resource - Per-application local automations —
/api/v2/applications/{applicationId}/actions. - Logs
Resource - Logs — the request audit log (
/api/v2/audit/request) and the live log (/api/v2/logs). - Manager
Client - The babelforce manager SDK client. Build one with
ManagerClient::connect(orManagerClient::builder) and use its resource namespaces. - Manager
Client Builder - Builder for
ManagerClient. - MeResource
- The authenticated principal — the current user, the accounts they can access, and self-service
password reset. Backed by
/api/v2/user(the user spec). - Metrics
Resource - Metrics —
/api/v2/metrics. - Numbers
Resource - Service (phone) numbers —
/api/v2/numbers. - Outbound
Resource - Outbound lists & leads —
/api/v2/outbound/lists. - Page
- One fetched page of a v2 list endpoint.
- Phonebook
Resource - Phonebook entries —
/api/v2/phonebook. - Pkce
Challenge - A PKCE code verifier + S256 challenge (RFC 7636).
- Prompts
Resource - Audio prompts —
/api/v2/prompts. - Queue
Selections Resource - Queue selections (routing rules) and their agent/group/tag membership.
- Queues
Resource - Queues —
/api/v2/queues, with a nestedselectionssub-resource. - Recordings
Resource - Call recordings —
/api/v2/recordings, including bulk actions and per-recording flagging. - Reporting
Resource - Call reporting —
/api/v2/calls/reporting. - Retry
Policy - Automatic-retry tuning. Transient failures — network errors and 429/502/503/504 — are retried with exponential backoff. Non-idempotent requests are only retried on 429.
- Routing
Resource - Routing rules —
/api/v2/routings. - Sessions
Resource - Call/automation sessions —
/api/v2/sessions. - Settings
Resource - Global settings —
/api/v2/settings, grouped by scope (app,telephony,audit,ui,retention). Each section has a read accessor and aset_*writer that return the section’s typed response. - SmsResource
- SMS records —
/api/v2/sms. - Task
Metrics Resource - Task & agent metrics —
/api/v3/metrics. - Task
Schedules Resource - Task schedules (cron-style task submission) —
/api/v3/schedules. - Task
Scripts Resource - Custom scripts by type —
/api/v3/scripts. - Task
Secrets Resource - Account secrets, grouped by prefix —
/api/v3/secrets. - Task
Selection Config Resource - Account task-selection configuration —
/api/v3/account/selection. - Tasks
Resource - Task automation (v3) —
/api/v3/tasks, with nestedscripts,secrets,selection_config, andmetricssub-resources. - Token
Request - Optional parameters for the OAuth token endpoint. Set the fields relevant to your grant type
(e.g.
code+redirect_uri+code_verifierforauthorization_code,refresh_tokenforrefresh_token,username+passwordforpassword,client_id+client_secretforclient_credentials); leave the rest at their defaultNone. - Triggers
Resource - Workflow triggers —
/api/v2/triggers. - Users
Resource - User management —
/api/v2/users.
Enums§
- Auth
- How the SDK authenticates. Configure once when building the client.
- Manager
Error - The error type returned by every facade call.
Constants§
- DEFAULT_
BASE_ URL - Default babelforce API host. Override with
ManagerClientBuilder::base_url.
Functions§
- build_
authorize_ url - Build the
GET {base_url}/oauth/authorizeURL that starts the Authorization Code + PKCE flow. Redirect the user to it; babelforce redirects back toredirect_uriwith a short-lived code.code_challenge_methoddefaults toS256whenNone. Pass a fullbase_urlincluding the scheme (e.g.https://services.babelforce.com). - pkce_
challenge - Generate a fresh PKCE verifier + S256 challenge (RFC 7636). Pass
code_challengetobuild_authorize_urland keepcode_verifierto exchange the returned code.