import { encodeUriSegment } from '@histoire/cli/workbench-url';
import { z } from 'zod/v4';
/** Valid resource address, resolved by catalog/operations rather than filesystem paths. */
declare const addressSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
    projectId: z.ZodString;
    kind: z.ZodLiteral<"project">;
}, z.core.$strict>, z.ZodObject<{
    projectId: z.ZodString;
    kind: z.ZodLiteral<"story">;
    storyId: z.ZodString;
    revision: z.ZodOptional<z.ZodString>;
}, z.core.$strict>, z.ZodObject<{
    projectId: z.ZodString;
    kind: z.ZodLiteral<"docs">;
    storyId: z.ZodString;
    revision: z.ZodOptional<z.ZodString>;
    offset: z.ZodOptional<z.ZodNumber>;
    limit: z.ZodOptional<z.ZodNumber>;
}, z.core.$strict>, z.ZodObject<{
    projectId: z.ZodString;
    kind: z.ZodLiteral<"source">;
    storyId: z.ZodString;
    revision: z.ZodOptional<z.ZodString>;
    startLine: z.ZodOptional<z.ZodNumber>;
    lineCount: z.ZodOptional<z.ZodNumber>;
}, z.core.$strict>, z.ZodObject<{
    projectId: z.ZodString;
    kind: z.ZodLiteral<"operation">;
    operationId: z.ZodUUID;
    offset: z.ZodOptional<z.ZodNumber>;
    limit: z.ZodOptional<z.ZodNumber>;
}, z.core.$strict>, z.ZodObject<{
    projectId: z.ZodString;
    kind: z.ZodLiteral<"artifact">;
    artifactId: z.ZodUUID;
}, z.core.$strict>], "kind">;
/** Canonical public resource address. */
export type McpResourceAddress = z.infer<typeof addressSchema>;
/** Encode exact ID as one RFC 3986 segment; dot-only segments never undergo URL normalization. */
export declare const encodeMcpUriSegment: typeof encodeUriSegment;
/** Construct resource URI without URL parser's dot-segment or host normalization. */
export declare function encodeMcpResourceUri(input: McpResourceAddress): string;
/** Parse exact resource shape and reject foreign projects, aliases, duplicate keys, and unknown fields. */
export declare function decodeMcpResourceUri(uri: string, expectedProjectId: string): McpResourceAddress;
export {};
//# sourceMappingURL=uris.d.ts.map