Sessions
Reference for client.sessions in the Future AGI Python and TypeScript SDKs: sessions.get, sessions.list.
client.sessions on fi.Client (Python) and client.sessions on Client from @future-agi/sdk (TypeScript). The models these methods return are on Observability response models; how arguments, pagination, errors and strict mode work is in the overview.
Methods
| Method | Description |
|---|---|
sessions.get | Return a trace session by its identifier. |
sessions.list | List trace sessions using the supplied filters. |
client.sessions
sessions.get
Return a trace session by its identifier.
/tracer/trace-session/{id}/query/ MCP tool: get_session
result = client.sessions.get("your-id")const result = await client.sessions.get("your-id"); Signature
client.sessions.get(
id: str,
*,
navigation_context: str | None | NotGiven = NOT_GIVEN,
user_id: str | None | NotGiven = NOT_GIVEN,
filters: str | None | NotGiven = NOT_GIVEN,
sort_params: str | None | NotGiven = NOT_GIVEN,
page_number: int | None | NotGiven = NOT_GIVEN,
page_size: int | None | NotGiven = NOT_GIVEN,
extra_query: dict[str, Any] | None = None,
options: RequestOptions | None = None,
) -> models.TraceSessionDetailResultclient.sessions.get(id: string, params: SessionsGetParams = {}, options?: RequestOptions): Promise<models.TraceSessionDetailResult>
export interface SessionsGetParams {
navigation_context?: string | null;
user_id?: string | null;
filters?: string | null;
sort_params?: string | null;
page_number?: number | null;
page_size?: number | null;
} Parameters
Positional argument id.
Returns
sessions.list
List trace sessions using the supplied filters.
/tracer/trace-session/list_sessions/ MCP tool: list_sessions
result = client.sessions.list()const result = await client.sessions.list(); Signature
client.sessions.list(
*,
project_id: str | None | NotGiven = NOT_GIVEN,
user_id: str | None | NotGiven = NOT_GIVEN,
bookmarked: bool | None | NotGiven = NOT_GIVEN,
filters: str | None | NotGiven = NOT_GIVEN,
sort_params: str | None | NotGiven = NOT_GIVEN,
page_number: int | None | NotGiven = NOT_GIVEN,
page_size: int | None | NotGiven = NOT_GIVEN,
cursor: str | None | NotGiven = NOT_GIVEN,
cursor_mode: bool | None | NotGiven = NOT_GIVEN,
interval: str | None | NotGiven = NOT_GIVEN,
allow_sampled: bool | None | NotGiven = NOT_GIVEN,
extra_query: dict[str, Any] | None = None,
options: RequestOptions | None = None,
) -> models.TraceSessionListResultclient.sessions.list(params: SessionsListParams = {}, options?: RequestOptions): Promise<models.TraceSessionListResult>
export interface SessionsListParams {
project_id?: string | null;
user_id?: string | null;
bookmarked?: boolean | null;
filters?: string | null;
sort_params?: string | null;
/** Zero-based numbered page. Pages whose required ordered work exceeds the finite read contract return HTTP 422 with code page_depth_exceeded; request an earlier page or narrow the time range. */
page_number?: number | null;
page_size?: number | null;
/** Opaque continuation token returned by the previous page. When supplied, do not also send the numbered-page parameter. */
cursor?: string | null;
cursor_mode?: boolean | null;
interval?: string | null;
/** Omit for backward-compatible complete bounded pages, which may label total_rows as a lower bound. Send false to require an exact total, or true to opt in explicitly to lower-bound totals. */
allow_sampled?: boolean | null;
} Parameters
Zero-based numbered page. Pages whose required ordered work exceeds the finite read contract return HTTP 422 with code page_depth_exceeded; request an earlier page or narrow the time range.
Opaque continuation token returned by the previous page. When supplied, do not also send the numbered-page parameter.
Omit for backward-compatible complete bounded pages, which may label total_rows as a lower bound. Send false to require an exact total, or true to opt in explicitly to lower-bound totals.
Returns
Questions & Discussion