@arizeai/phoenix-client
Version:
A client for the Phoenix API
43 lines • 1.22 kB
TypeScript
import type { ClientFn } from "../types/core.js";
/**
* Parameters to delete a session
*/
export interface DeleteSessionParams extends ClientFn {
/**
* The session ID. Can be either:
* - A user-provided session ID string
* - A Phoenix Global ID (base64-encoded)
*/
sessionId: string;
}
/**
* Delete a single session by ID.
*
* This will permanently remove the session and all associated traces, spans,
* and annotations via cascade delete.
*
* @experimental this function is experimental and may change in the future
*
* @param params - The parameters to delete a session
* @returns Promise that resolves when the session is successfully deleted
* @throws Error if the session is not found or deletion fails
*
* @requires Phoenix server >= 13.13.0
*
* @example
* ```ts
* // Delete by user-provided session ID
* await deleteSession({
* client,
* sessionId: "my-session-id"
* });
*
* // Delete by Phoenix Global ID
* await deleteSession({
* client,
* sessionId: "UHJvamVjdFNlc3Npb246MTIz"
* });
* ```
*/
export declare function deleteSession({ client: _client, sessionId, }: DeleteSessionParams): Promise<void>;
//# sourceMappingURL=deleteSession.d.ts.map