qbraid_core.services.agents.AgentsClient
- class qbraid_core.services.agents.AgentsClient(api_key=None, session=None)
Client for interacting with the qBraid Agents service.
Provides cloud sync for agent sessions and stubs for future messaging and team orchestration APIs.
- Parameters:
api_key (
Optional[str]) – Optional API key for authentication.session (
Optional[QbraidSessionV1]) – Optional pre-configured session.
Example
>>> from qbraid_core.services.agents import AgentsClient >>> client = AgentsClient() >>> sessions = client.list_sessions()
- __init__(api_key=None, session=None)
Initialize the AgentsClient.
Methods
__init__([api_key, session])Initialize the AgentsClient.
delete_session(session_id)Delete a session from the cloud.
get_credits_balance()Get the current user's credit balance for their organization.
get_session(session_id)Get a specific session from the cloud.
list_sessions([tool, machine_id])List agent sessions from the cloud.
running_in_lab()Check if running in the qBraid Lab environment.
sync_sessions(sessions)Push local sessions to the cloud.
user_credits_value()Get the current user's qBraid credits value.
Attributes
sessionThe QbraidSessionV1 used to make requests.