@struktoai/mirage-core
Version:
A Unified Virtual Filesystem For AI Agents
24 lines • 1.52 kB
TypeScript
import type { JsonValue } from '../../types.ts';
import type { TokenManager } from '../google/client.ts';
import { TimeRange } from '../time_range.ts';
/**
* Every Calendar request the gcal backend makes, as one object. A core op
* reaches Calendar only through `accessor.calendar`. Mirrors Python's
* `CalendarApi`.
*/
export interface CalendarApi {
listCalendars(minAccessRole?: string): Promise<Record<string, JsonValue>[]>;
listEvents(calendarId: string, timeMin: string | null, timeMax: string, timeZone?: string, scope?: TimeRange, query?: string): Promise<Record<string, JsonValue>[]>;
syncEvents(calendarId: string, syncToken: string | null, timeZone?: string): Promise<[Record<string, JsonValue>[], string | null]>;
deleteEvent(calendarId: string, eventId: string): Promise<void>;
}
/** The live `CalendarApi`: one token manager, one wire call per method. */
export declare class CalendarClient implements CalendarApi {
readonly tokenManager: TokenManager;
constructor(tokenManager: TokenManager);
listCalendars(minAccessRole?: string): Promise<Record<string, JsonValue>[]>;
listEvents(calendarId: string, timeMin: string | null, timeMax: string, timeZone?: string, scope?: TimeRange, query?: string): Promise<Record<string, JsonValue>[]>;
syncEvents(calendarId: string, syncToken: string | null, timeZone?: string): Promise<[Record<string, JsonValue>[], string | null]>;
deleteEvent(calendarId: string, eventId: string): Promise<void>;
}
//# sourceMappingURL=api.d.ts.map