import { type IssueEnvelope, type NormalizedIssueEnvelope } from './types.js';
export interface ShortcutAdapterConfig {
    apiToken?: string;
    workspaceSlug?: string;
    apiUrl?: string;
}
interface ShortcutWorkflowState {
    id?: number;
    name?: string;
    type?: string;
}
/**
 * Normalize a raw Shortcut API story into a canonical IssueEnvelope.
 */
export declare function normalizeShortcutStory(rawStory: unknown, workflowStates?: Map<number, ShortcutWorkflowState>): IssueEnvelope;
/**
 * Normalize a raw Shortcut story into a PMO-ready NormalizedIssueEnvelope.
 */
export declare function normalizeShortcutStoryToEnvelope(rawStory: unknown, workflowStates?: Map<number, ShortcutWorkflowState>): NormalizedIssueEnvelope;
/**
 * Build a PMO ticket description from a NormalizedIssueEnvelope.
 */
export declare function buildShortcutTicketDescription(envelope: NormalizedIssueEnvelope): string;
/**
 * Build ticket metadata from a NormalizedIssueEnvelope for traceability.
 */
export declare function buildShortcutMetadata(envelope: NormalizedIssueEnvelope): Record<string, string>;
/**
 * Build a spawn context message from a NormalizedIssueEnvelope.
 */
export declare function buildShortcutSpawnContextMessage(envelope: NormalizedIssueEnvelope, additionalMessage?: string): string;
/**
 * Build a CLI command string for selecting a specific Shortcut story.
 */
export declare function buildShortcutStoryChoiceCommand(storyKey: string, projectId?: string): string;
/**
 * Fetch a single Shortcut story by its numeric ID or sc-<id> key and normalize it.
 */
export declare function getShortcutStoryByKey(configInput: ShortcutAdapterConfig, storyKey: string, options?: {
    fetchImpl?: typeof fetch;
}): Promise<NormalizedIssueEnvelope | null>;
/**
 * Check if Shortcut is configured via environment variables.
 */
export declare function isShortcutConfiguredFromEnv(config?: ShortcutAdapterConfig): boolean;
/**
 * Fetch and normalize Shortcut stories into NormalizedIssueEnvelopes.
 */
export declare function listShortcutStories(configInput: ShortcutAdapterConfig, options?: {
    limit?: number;
    query?: string;
    fetchImpl?: typeof fetch;
}): Promise<NormalizedIssueEnvelope[]>;
/**
 * Import a Shortcut story into PMO as a linked ticket.
 */
export declare function importShortcutStoryToPmo(storage: {
    listTickets(projectId: string): Promise<Array<{
        id: string;
        metadata?: Record<string, string>;
    }>>;
    createTicket(projectId: string, input: {
        title: string;
        description: string;
        priority?: string;
        category?: string;
        labels: string[];
        metadata: Record<string, string>;
    }): Promise<{
        id: string;
    }>;
    updateTicket(ticketId: string, input: {
        title: string;
        description: string;
        priority?: string;
        category?: string;
        labels: string[];
        metadata: Record<string, string>;
    }): Promise<{
        id: string;
    }>;
}, projectId: string, envelope: NormalizedIssueEnvelope): Promise<{
    ticketId: string;
    created: boolean;
}>;
export {};
