bookr-cli
Version:
A terminal-based CLI tool to book time in Jira using the Tempo plugin by parsing your current Git branch name
36 lines • 1.13 kB
TypeScript
/**
* Tempo API client for worklog-related tasks
* Docs: https://apidocs.tempo.io/
*/
import type { TempoWorklogCreateResponse, TempoUserWorkload } from '../types/tempo.js';
export declare class TempoClient {
private baseUrl;
private apiToken;
constructor(baseUrl: string, apiToken: string);
/**
* Fetch worklogs for a user for a given date range (Tempo API v4)
*/
getWorklogsForUser(accountId: string, from: string, to: string): Promise<unknown>;
/**
* Add a worklog for a user
*/
addWorklog(worklogData: {
issueId: string;
issueKey: string;
timeSpentSeconds: number;
comment?: string;
startDate: string;
authorAccountId: string;
startTime?: string;
}): Promise<TempoWorklogCreateResponse>;
/**
* Delete a worklog by ID
*/
deleteWorklog(worklogId: string): Promise<boolean>;
/**
* Get workload scheme for a user
*/
getUserWorkload(accountId: string): Promise<TempoUserWorkload>;
}
export declare function createTempoClient(): TempoClient;
//# sourceMappingURL=tempo-client.d.ts.map