import { ExternalExecutionMappingStore } from './mapping-store.js';
import { type ExternalIssueAdapter, type ExternalExecutionMapping, type IssueEnvelope } from './types.js';
type FetchIssueByKey = (key: string) => Promise<unknown>;
type FetchIssuesByQuery = (query: Record<string, unknown>) => Promise<unknown[]>;
interface AdapterFetchers {
    fetchByKey?: FetchIssueByKey;
    fetchByQuery?: FetchIssuesByQuery;
}
export declare class LinearIssueAdapter implements ExternalIssueAdapter {
    readonly source: "linear";
    private readonly fetchByKeyImpl?;
    private readonly fetchByQueryImpl?;
    constructor(fetchers?: AdapterFetchers);
    normalize(raw: unknown): IssueEnvelope;
    fetchByKey(key: string): Promise<IssueEnvelope>;
    fetchByQuery(query: Record<string, unknown>): Promise<IssueEnvelope[]>;
    persistMapping(store: ExternalExecutionMappingStore, envelope: IssueEnvelope, params?: {
        executionId?: string;
        prUrl?: string;
        lastSyncedAt?: Date;
        lastSpawnedAt?: Date;
    }): ExternalExecutionMapping;
    readMappingByExternalId(store: ExternalExecutionMappingStore, externalId: string): ExternalExecutionMapping | null;
    readMappingsByExecutionId(store: ExternalExecutionMappingStore, executionId: string): ExternalExecutionMapping[];
}
export declare class JiraIssueAdapter implements ExternalIssueAdapter {
    readonly source: "jira";
    private readonly fetchByKeyImpl?;
    private readonly fetchByQueryImpl?;
    constructor(fetchers?: AdapterFetchers);
    normalize(raw: unknown): IssueEnvelope;
    fetchByKey(key: string): Promise<IssueEnvelope>;
    fetchByQuery(query: Record<string, unknown>): Promise<IssueEnvelope[]>;
    persistMapping(store: ExternalExecutionMappingStore, envelope: IssueEnvelope, params?: {
        executionId?: string;
        prUrl?: string;
        lastSyncedAt?: Date;
        lastSpawnedAt?: Date;
    }): ExternalExecutionMapping;
    readMappingByExternalId(store: ExternalExecutionMappingStore, externalId: string): ExternalExecutionMapping | null;
    readMappingsByExecutionId(store: ExternalExecutionMappingStore, executionId: string): ExternalExecutionMapping[];
}
export {};
