import { APIResource } from "../resource.js"; import * as Core from "../core.js"; export declare class TokenResource extends APIResource { /** * Create a personal access token. */ create(options?: Core.RequestOptions): Core.APIPromise; /** * List the current user's personal access tokens. */ list(options?: Core.RequestOptions): Core.APIPromise; /** * Delete the personal access token with the given ID. */ delete(id: string, options?: Core.RequestOptions): Core.APIPromise; /** * Get the personal access token with the given ID. */ get(id: string, options?: Core.RequestOptions): Core.APIPromise; } /** * A personal access token used to access the Terminal API. If you leak this, * expect large sums of coffee to be ordered on your credit card. */ export interface Token { /** * Unique object identifier. The format and length of IDs may change over time. */ id: string; /** * Personal access token (obfuscated). */ token: string; /** * The created time for the token. */ created: string; } export interface TokenCreateResponse { data: TokenCreateResponse.Data; } export declare namespace TokenCreateResponse { interface Data { /** * Personal token ID. */ id: string; /** * Personal access token. Include this in the Authorization header * (`Bearer `) when accessing the Terminal API. */ token: string; } } export interface TokenListResponse { /** * List of personal access tokens. */ data: Array; } export interface TokenDeleteResponse { data: 'ok'; } export interface TokenGetResponse { /** * A personal access token used to access the Terminal API. If you leak this, * expect large sums of coffee to be ordered on your credit card. */ data: Token; } export declare namespace TokenResource { export { type Token as Token, type TokenCreateResponse as TokenCreateResponse, type TokenListResponse as TokenListResponse, type TokenDeleteResponse as TokenDeleteResponse, type TokenGetResponse as TokenGetResponse, }; } //# sourceMappingURL=token.d.ts.map