@crosspost/types
Version:
Shared type definitions for Crosspost API
1,727 lines (1,722 loc) • 103 kB
TypeScript
import { z } from 'zod';
import { StatusCode } from 'hono/utils/http-status';
export { StatusCode } from 'hono/utils/http-status';
import * as buffer from 'buffer';
/**
* Platform enum
*/
declare enum Platform {
UNKNOWN = "unknown",
TWITTER = "twitter"
}
/**
* PlatformName type - Derived from the Platform enum
*/
type PlatformName = Platform;
declare const PlatformSchema: z.ZodNativeEnum<typeof Platform>;
/**
* Array of currently supported platforms
*/
declare const SUPPORTED_PLATFORMS: readonly [Platform.TWITTER];
type SupportedPlatformName = typeof SUPPORTED_PLATFORMS[number];
declare const SupportedPlatformSchema: z.ZodEnum<[Platform.TWITTER]> | z.ZodNever;
/**
* Check if a platform is currently supported
*/
declare function isPlatformSupported(platform: Platform): platform is SupportedPlatformName;
declare enum ApiErrorCode {
UNKNOWN_ERROR = "UNKNOWN_ERROR",
INTERNAL_ERROR = "INTERNAL_ERROR",
UNAUTHORIZED = "UNAUTHORIZED",
FORBIDDEN = "FORBIDDEN",
VALIDATION_ERROR = "VALIDATION_ERROR",
INVALID_REQUEST = "INVALID_REQUEST",
RATE_LIMITED = "RATE_LIMITED",
NOT_FOUND = "NOT_FOUND",
PLATFORM_ERROR = "PLATFORM_ERROR",
PLATFORM_UNAVAILABLE = "PLATFORM_UNAVAILABLE",
CONTENT_POLICY_VIOLATION = "CONTENT_POLICY_VIOLATION",
DUPLICATE_CONTENT = "DUPLICATE_CONTENT",
MEDIA_UPLOAD_FAILED = "MEDIA_UPLOAD_FAILED",
MULTI_STATUS = "MULTI_STATUS",
POST_CREATION_FAILED = "POST_CREATION_FAILED",
THREAD_CREATION_FAILED = "THREAD_CREATION_FAILED",
POST_DELETION_FAILED = "POST_DELETION_FAILED",
POST_INTERACTION_FAILED = "POST_INTERACTION_FAILED",
NETWORK_ERROR = "NETWORK_ERROR",
INVALID_RESPONSE = "INVALID_RESPONSE",
TOKEN_REFRESH_FAILED = "TOKEN_REFRESH_FAILED",
PROFILE_REFRESH_FAILED = "PROFILE_REFRESH_FAILED"
}
declare const ApiErrorCodeSchema: z.ZodEnum<[string, ...string[]]>;
/**
* Map of API error codes to HTTP status codes
* This ensures consistent HTTP status codes across the application
*/
declare const errorCodeToStatusCode: Record<ApiErrorCode, StatusCode>;
/**
* Common error details that can be included in any error
*/
interface ErrorDetails {
platform?: PlatformName;
userId?: string;
[key: string]: unknown;
}
declare const ErrorDetailSchema: z.ZodObject<{
message: z.ZodString;
code: z.ZodEnum<[string, ...string[]]>;
recoverable: z.ZodBoolean;
details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
}, "strip", z.ZodTypeAny, {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}, {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}>;
type ErrorDetail = z.infer<typeof ErrorDetailSchema>;
interface ApiErrorResponse {
success: false;
errors: ErrorDetail[];
meta: ResponseMeta;
}
declare const ResponseMetaSchema: z.ZodObject<{
requestId: z.ZodString;
timestamp: z.ZodString;
rateLimit: z.ZodOptional<z.ZodObject<{
remaining: z.ZodNumber;
limit: z.ZodNumber;
reset: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
remaining: number;
limit: number;
reset: number;
}, {
remaining: number;
limit: number;
reset: number;
}>>;
pagination: z.ZodOptional<z.ZodObject<{
limit: z.ZodOptional<z.ZodNumber>;
offset: z.ZodOptional<z.ZodNumber>;
total: z.ZodOptional<z.ZodNumber>;
}, "strip", z.ZodTypeAny, {
limit?: number | undefined;
offset?: number | undefined;
total?: number | undefined;
}, {
limit?: number | undefined;
offset?: number | undefined;
total?: number | undefined;
}>>;
}, "strip", z.ZodTypeAny, {
requestId: string;
timestamp: string;
rateLimit?: {
remaining: number;
limit: number;
reset: number;
} | undefined;
pagination?: {
limit?: number | undefined;
offset?: number | undefined;
total?: number | undefined;
} | undefined;
}, {
requestId: string;
timestamp: string;
rateLimit?: {
remaining: number;
limit: number;
reset: number;
} | undefined;
pagination?: {
limit?: number | undefined;
offset?: number | undefined;
total?: number | undefined;
} | undefined;
}>;
declare const createSuccessDetailSchema: <T extends z.ZodTypeAny = z.ZodAny>(detailsSchema?: T) => z.ZodObject<{
platform: z.ZodString;
userId: z.ZodString;
details: T;
status: z.ZodLiteral<"success">;
}, "strip", z.ZodAny, z.objectOutputType<{
platform: z.ZodString;
userId: z.ZodString;
details: T;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">, z.objectInputType<{
platform: z.ZodString;
userId: z.ZodString;
details: T;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">>;
declare const SuccessDetailSchema: z.ZodObject<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, "strip", z.ZodAny, z.objectOutputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">, z.objectInputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">>;
declare const HealthStatusSchema: z.ZodObject<{
status: z.ZodString;
version: z.ZodOptional<z.ZodString>;
timestamp: z.ZodString;
}, "strip", z.ZodTypeAny, {
status: string;
timestamp: string;
version?: string | undefined;
}, {
status: string;
timestamp: string;
version?: string | undefined;
}>;
declare const MultiStatusSummarySchema: z.ZodObject<{
total: z.ZodNumber;
succeeded: z.ZodNumber;
failed: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
total: number;
succeeded: number;
failed: number;
}, {
total: number;
succeeded: number;
failed: number;
}>;
declare const createMultiStatusDataSchema: <TDetailSchema extends z.ZodTypeAny = z.ZodAny>(detailsSchema?: TDetailSchema) => z.ZodObject<{
summary: z.ZodObject<{
total: z.ZodNumber;
succeeded: z.ZodNumber;
failed: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
total: number;
succeeded: number;
failed: number;
}, {
total: number;
succeeded: number;
failed: number;
}>;
results: z.ZodArray<z.ZodObject<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, "strip", z.ZodAny, z.objectOutputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">, z.objectInputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">> | z.ZodObject<{
platform: z.ZodString;
userId: z.ZodString;
details: TDetailSchema;
status: z.ZodLiteral<"success">;
}, "strip", z.ZodAny, z.objectOutputType<{
platform: z.ZodString;
userId: z.ZodString;
details: TDetailSchema;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">, z.objectInputType<{
platform: z.ZodString;
userId: z.ZodString;
details: TDetailSchema;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">>, "many">;
errors: z.ZodArray<z.ZodObject<{
message: z.ZodString;
code: z.ZodEnum<[string, ...string[]]>;
recoverable: z.ZodBoolean;
details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
}, "strip", z.ZodTypeAny, {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}, {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}>, "many">;
}, "strip", z.ZodTypeAny, {
summary: {
total: number;
succeeded: number;
failed: number;
};
results: (z.objectOutputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip"> | z.objectOutputType<{
platform: z.ZodString;
userId: z.ZodString;
details: TDetailSchema;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">)[];
errors: {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}[];
}, {
summary: {
total: number;
succeeded: number;
failed: number;
};
results: (z.objectInputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip"> | z.objectInputType<{
platform: z.ZodString;
userId: z.ZodString;
details: TDetailSchema;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">)[];
errors: {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}[];
}>;
declare const MultiStatusDataSchema: z.ZodObject<{
summary: z.ZodObject<{
total: z.ZodNumber;
succeeded: z.ZodNumber;
failed: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
total: number;
succeeded: number;
failed: number;
}, {
total: number;
succeeded: number;
failed: number;
}>;
results: z.ZodArray<z.ZodObject<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, "strip", z.ZodAny, z.objectOutputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">, z.objectInputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">>, "many">;
errors: z.ZodArray<z.ZodObject<{
message: z.ZodString;
code: z.ZodEnum<[string, ...string[]]>;
recoverable: z.ZodBoolean;
details: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
}, "strip", z.ZodTypeAny, {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}, {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}>, "many">;
}, "strip", z.ZodTypeAny, {
summary: {
total: number;
succeeded: number;
failed: number;
};
results: z.objectOutputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">[];
errors: {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}[];
}, {
summary: {
total: number;
succeeded: number;
failed: number;
};
results: z.objectInputType<{
platform: z.ZodString;
userId: z.ZodString;
details: z.ZodAny;
status: z.ZodLiteral<"success">;
}, z.ZodAny, "strip">[];
errors: {
code: string;
message: string;
recoverable: boolean;
details?: Record<string, unknown> | undefined;
}[];
}>;
interface ApiResponse<T> {
success: boolean;
data?: T | null;
errors?: ErrorDetail[] | null;
meta: ResponseMeta;
}
type ResponseMeta = z.infer<typeof ResponseMetaSchema>;
type SuccessDetail<T = any> = Omit<z.infer<typeof SuccessDetailSchema>, 'details'> & {
details?: T;
};
type MultiStatusSummary = z.infer<typeof MultiStatusSummarySchema>;
type MultiStatusData<TDetail = any> = {
summary: MultiStatusSummary;
results: SuccessDetail<TDetail>[];
errors: ErrorDetail[];
};
type HealthStatus = z.infer<typeof HealthStatusSchema>;
declare const PlatformParamSchema: z.ZodObject<{
platform: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: string;
}, {
platform: string;
}>;
declare const AuthStatusSchema: z.ZodObject<{
message: z.ZodString;
code: z.ZodString;
details: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
code: string;
message: string;
details?: string | undefined;
}, {
code: string;
message: string;
details?: string | undefined;
}>;
declare const AuthInitRequestSchema: z.ZodObject<{
successUrl: z.ZodOptional<z.ZodString>;
errorUrl: z.ZodOptional<z.ZodString>;
redirect: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
}, "strip", z.ZodTypeAny, {
redirect: boolean;
successUrl?: string | undefined;
errorUrl?: string | undefined;
}, {
successUrl?: string | undefined;
errorUrl?: string | undefined;
redirect?: boolean | undefined;
}>;
declare const AuthUrlResponseSchema: z.ZodObject<{
url: z.ZodString;
}, "strip", z.ZodTypeAny, {
url: string;
}, {
url: string;
}>;
declare const AuthCallbackQuerySchema: z.ZodObject<{
code: z.ZodString;
state: z.ZodString;
}, "strip", z.ZodTypeAny, {
code: string;
state: string;
}, {
code: string;
state: string;
}>;
declare const AuthCallbackResponseSchema: z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
redirectUrl: z.ZodOptional<z.ZodString>;
status: z.ZodObject<{
message: z.ZodString;
code: z.ZodString;
details: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
code: string;
message: string;
details?: string | undefined;
}, {
code: string;
message: string;
details?: string | undefined;
}>;
}, "strip", z.ZodTypeAny, {
status: {
code: string;
message: string;
details?: string | undefined;
};
platform: Platform;
userId: string;
redirectUrl?: string | undefined;
}, {
status: {
code: string;
message: string;
details?: string | undefined;
};
platform: Platform;
userId: string;
redirectUrl?: string | undefined;
}>;
declare const AuthStatusParamsSchema: z.ZodObject<{
platform: z.ZodString;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: string;
userId: string;
}, {
platform: string;
userId: string;
}>;
declare const NearUnauthorizationResponseSchema: z.ZodObject<{
success: z.ZodBoolean;
nearAccount: z.ZodString;
}, "strip", z.ZodTypeAny, {
success: boolean;
nearAccount: string;
}, {
success: boolean;
nearAccount: string;
}>;
declare const AuthStatusResponseSchema: z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
authenticated: z.ZodBoolean;
tokenStatus: z.ZodObject<{
valid: z.ZodBoolean;
expired: z.ZodBoolean;
expiresAt: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
valid: boolean;
expired: boolean;
expiresAt?: string | undefined;
}, {
valid: boolean;
expired: boolean;
expiresAt?: string | undefined;
}>;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
authenticated: boolean;
tokenStatus: {
valid: boolean;
expired: boolean;
expiresAt?: string | undefined;
};
}, {
platform: Platform;
userId: string;
authenticated: boolean;
tokenStatus: {
valid: boolean;
expired: boolean;
expiresAt?: string | undefined;
};
}>;
declare const AuthTokenRequestSchema: z.ZodObject<{
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
userId: string;
}, {
userId: string;
}>;
declare const AuthRevokeResponseSchema: z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>;
declare const ConnectedAccountSchema: z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
connectedAt: z.ZodString;
profile: z.ZodNullable<z.ZodObject<{
userId: z.ZodString;
username: z.ZodString;
url: z.ZodOptional<z.ZodString>;
profileImageUrl: z.ZodString;
isPremium: z.ZodOptional<z.ZodBoolean>;
platform: z.ZodNativeEnum<typeof Platform>;
lastUpdated: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
}, {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
}>>;
error: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
profile: {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
} | null;
connectedAt: string;
error?: string | undefined;
}, {
platform: Platform;
userId: string;
profile: {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
} | null;
connectedAt: string;
error?: string | undefined;
}>;
declare const ConnectedAccountsResponseSchema: z.ZodObject<{
accounts: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
connectedAt: z.ZodString;
profile: z.ZodNullable<z.ZodObject<{
userId: z.ZodString;
username: z.ZodString;
url: z.ZodOptional<z.ZodString>;
profileImageUrl: z.ZodString;
isPremium: z.ZodOptional<z.ZodBoolean>;
platform: z.ZodNativeEnum<typeof Platform>;
lastUpdated: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
}, {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
}>>;
error: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
profile: {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
} | null;
connectedAt: string;
error?: string | undefined;
}, {
platform: Platform;
userId: string;
profile: {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
} | null;
connectedAt: string;
error?: string | undefined;
}>, "many">;
}, "strip", z.ZodTypeAny, {
accounts: {
platform: Platform;
userId: string;
profile: {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
} | null;
connectedAt: string;
error?: string | undefined;
}[];
}, {
accounts: {
platform: Platform;
userId: string;
profile: {
platform: Platform;
userId: string;
username: string;
profileImageUrl: string;
lastUpdated: number;
url?: string | undefined;
isPremium?: boolean | undefined;
} | null;
connectedAt: string;
error?: string | undefined;
}[];
}>;
declare const NearAuthorizationRequestSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
declare const NearAuthorizationResponseSchema: z.ZodObject<{
signerId: z.ZodString;
isAuthorized: z.ZodBoolean;
}, "strip", z.ZodTypeAny, {
signerId: string;
isAuthorized: boolean;
}, {
signerId: string;
isAuthorized: boolean;
}>;
declare const NearAuthorizationStatusResponseSchema: z.ZodObject<{
signerId: z.ZodString;
isAuthorized: z.ZodBoolean;
authorizedAt: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
signerId: string;
isAuthorized: boolean;
authorizedAt?: string | undefined;
}, {
signerId: string;
isAuthorized: boolean;
authorizedAt?: string | undefined;
}>;
type PlatformParam = z.infer<typeof PlatformParamSchema>;
type AuthInitRequest = z.infer<typeof AuthInitRequestSchema>;
type AuthUrlResponse = z.infer<typeof AuthUrlResponseSchema>;
type AuthCallbackQuery = z.infer<typeof AuthCallbackQuerySchema>;
type AuthCallbackResponse = z.infer<typeof AuthCallbackResponseSchema>;
type AuthStatusResponse = z.infer<typeof AuthStatusResponseSchema>;
type AuthRevokeResponse = z.infer<typeof AuthRevokeResponseSchema>;
type ConnectedAccount = z.infer<typeof ConnectedAccountSchema>;
type ConnectedAccountsResponse = z.infer<typeof ConnectedAccountsResponseSchema>;
type NearAuthorizationRequest = z.infer<typeof NearAuthorizationRequestSchema>;
type NearAuthorizationResponse = z.infer<typeof NearAuthorizationResponseSchema>;
type NearAuthorizationStatusResponse = z.infer<typeof NearAuthorizationStatusResponseSchema>;
type AuthTokenRequest = z.infer<typeof AuthTokenRequestSchema>;
type AuthStatusParams = z.infer<typeof AuthStatusParamsSchema>;
type NearUnauthorizationResponse = z.infer<typeof NearUnauthorizationResponseSchema>;
type AuthStatus = z.infer<typeof AuthStatusSchema>;
declare const MediaContentSchema: z.ZodObject<{
data: z.ZodUnion<[z.ZodString, z.ZodType<buffer.Blob, z.ZodTypeDef, buffer.Blob>]>;
mimeType: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}>;
declare const MediaSchema: z.ZodObject<{
id: z.ZodString;
type: z.ZodEnum<["image", "video", "gif"]>;
url: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}>;
declare const PostMetricsSchema: z.ZodObject<{
retweets: z.ZodNumber;
quotes: z.ZodNumber;
likes: z.ZodNumber;
replies: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}>;
declare const PostSchema: z.ZodObject<{
id: z.ZodString;
text: z.ZodString;
createdAt: z.ZodString;
authorId: z.ZodString;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
id: z.ZodString;
type: z.ZodEnum<["image", "video", "gif"]>;
url: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}>, "many">>;
metrics: z.ZodOptional<z.ZodObject<{
retweets: z.ZodNumber;
quotes: z.ZodNumber;
likes: z.ZodNumber;
replies: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}>>;
inReplyToId: z.ZodOptional<z.ZodString>;
quotedPostId: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}>;
declare const PostContentSchema: z.ZodObject<{
text: z.ZodOptional<z.ZodString>;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
data: z.ZodUnion<[z.ZodString, z.ZodType<buffer.Blob, z.ZodTypeDef, buffer.Blob>]>;
mimeType: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}>, "many">>;
}, "strip", z.ZodTypeAny, {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}, {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}>;
declare const PostResultSchema: z.ZodObject<{
id: z.ZodString;
text: z.ZodOptional<z.ZodString>;
createdAt: z.ZodString;
mediaIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
threadIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
quotedPostId: z.ZodOptional<z.ZodString>;
inReplyToId: z.ZodOptional<z.ZodString>;
success: z.ZodOptional<z.ZodBoolean>;
}, "strip", z.ZodAny, z.objectOutputType<{
id: z.ZodString;
text: z.ZodOptional<z.ZodString>;
createdAt: z.ZodString;
mediaIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
threadIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
quotedPostId: z.ZodOptional<z.ZodString>;
inReplyToId: z.ZodOptional<z.ZodString>;
success: z.ZodOptional<z.ZodBoolean>;
}, z.ZodAny, "strip">, z.objectInputType<{
id: z.ZodString;
text: z.ZodOptional<z.ZodString>;
createdAt: z.ZodString;
mediaIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
threadIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
quotedPostId: z.ZodOptional<z.ZodString>;
inReplyToId: z.ZodOptional<z.ZodString>;
success: z.ZodOptional<z.ZodBoolean>;
}, z.ZodAny, "strip">>;
declare const DeleteResultSchema: z.ZodObject<{
success: z.ZodBoolean;
id: z.ZodString;
}, "strip", z.ZodTypeAny, {
success: boolean;
id: string;
}, {
success: boolean;
id: string;
}>;
declare const LikeResultSchema: z.ZodObject<{
success: z.ZodBoolean;
id: z.ZodString;
}, "strip", z.ZodTypeAny, {
success: boolean;
id: string;
}, {
success: boolean;
id: string;
}>;
declare const TargetSchema: z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>;
declare const CreatePostRequestSchema: z.ZodObject<{
targets: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>, "many">;
content: z.ZodArray<z.ZodObject<{
text: z.ZodOptional<z.ZodString>;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
data: z.ZodUnion<[z.ZodString, z.ZodType<buffer.Blob, z.ZodTypeDef, buffer.Blob>]>;
mimeType: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}>, "many">>;
}, "strip", z.ZodTypeAny, {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}, {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}>, "many">;
}, "strip", z.ZodTypeAny, {
targets: {
platform: Platform;
userId: string;
}[];
content: {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}[];
}, {
targets: {
platform: Platform;
userId: string;
}[];
content: {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}[];
}>;
declare const RepostRequestSchema: z.ZodObject<{
targets: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>, "many">;
platform: z.ZodNativeEnum<typeof Platform>;
postId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
postId: string;
}, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
postId: string;
}>;
declare const QuotePostRequestSchema: z.ZodObject<{
targets: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>, "many">;
platform: z.ZodNativeEnum<typeof Platform>;
postId: z.ZodString;
content: z.ZodArray<z.ZodObject<{
text: z.ZodOptional<z.ZodString>;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
data: z.ZodUnion<[z.ZodString, z.ZodType<buffer.Blob, z.ZodTypeDef, buffer.Blob>]>;
mimeType: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}>, "many">>;
}, "strip", z.ZodTypeAny, {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}, {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}>, "many">;
}, "strip", z.ZodTypeAny, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
content: {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}[];
postId: string;
}, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
content: {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}[];
postId: string;
}>;
declare const ReplyToPostRequestSchema: z.ZodObject<{
targets: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>, "many">;
platform: z.ZodNativeEnum<typeof Platform>;
postId: z.ZodString;
content: z.ZodArray<z.ZodObject<{
text: z.ZodOptional<z.ZodString>;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
data: z.ZodUnion<[z.ZodString, z.ZodType<buffer.Blob, z.ZodTypeDef, buffer.Blob>]>;
mimeType: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}, {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}>, "many">>;
}, "strip", z.ZodTypeAny, {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}, {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}>, "many">;
}, "strip", z.ZodTypeAny, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
content: {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}[];
postId: string;
}, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
content: {
text?: string | undefined;
media?: {
data: string | buffer.Blob;
mimeType?: string | undefined;
altText?: string | undefined;
}[] | undefined;
}[];
postId: string;
}>;
declare const PostToDeleteSchema: z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
postId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
postId: string;
}, {
platform: Platform;
userId: string;
postId: string;
}>;
declare const DeletePostRequestSchema: z.ZodObject<{
targets: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>, "many">;
posts: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
postId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
postId: string;
}, {
platform: Platform;
userId: string;
postId: string;
}>, "many">;
}, "strip", z.ZodTypeAny, {
targets: {
platform: Platform;
userId: string;
}[];
posts: {
platform: Platform;
userId: string;
postId: string;
}[];
}, {
targets: {
platform: Platform;
userId: string;
}[];
posts: {
platform: Platform;
userId: string;
postId: string;
}[];
}>;
declare const LikePostRequestSchema: z.ZodObject<{
targets: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>, "many">;
platform: z.ZodNativeEnum<typeof Platform>;
postId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
postId: string;
}, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
postId: string;
}>;
declare const UnlikePostRequestSchema: z.ZodObject<{
targets: z.ZodArray<z.ZodObject<{
platform: z.ZodNativeEnum<typeof Platform>;
userId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
userId: string;
}, {
platform: Platform;
userId: string;
}>, "many">;
platform: z.ZodNativeEnum<typeof Platform>;
postId: z.ZodString;
}, "strip", z.ZodTypeAny, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
postId: string;
}, {
platform: Platform;
targets: {
platform: Platform;
userId: string;
}[];
postId: string;
}>;
declare const PostResponseSchema: z.ZodUnion<[z.ZodObject<{
id: z.ZodString;
text: z.ZodString;
createdAt: z.ZodString;
authorId: z.ZodString;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
id: z.ZodString;
type: z.ZodEnum<["image", "video", "gif"]>;
url: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}>, "many">>;
metrics: z.ZodOptional<z.ZodObject<{
retweets: z.ZodNumber;
quotes: z.ZodNumber;
likes: z.ZodNumber;
replies: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}>>;
inReplyToId: z.ZodOptional<z.ZodString>;
quotedPostId: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}>, z.ZodArray<z.ZodObject<{
id: z.ZodString;
text: z.ZodString;
createdAt: z.ZodString;
authorId: z.ZodString;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
id: z.ZodString;
type: z.ZodEnum<["image", "video", "gif"]>;
url: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}>, "many">>;
metrics: z.ZodOptional<z.ZodObject<{
retweets: z.ZodNumber;
quotes: z.ZodNumber;
likes: z.ZodNumber;
replies: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}>>;
inReplyToId: z.ZodOptional<z.ZodString>;
quotedPostId: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}>, "many">]>;
declare const CreatePostResponseSchema: z.ZodUnion<[z.ZodObject<{
id: z.ZodString;
text: z.ZodString;
createdAt: z.ZodString;
authorId: z.ZodString;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
id: z.ZodString;
type: z.ZodEnum<["image", "video", "gif"]>;
url: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}>, "many">>;
metrics: z.ZodOptional<z.ZodObject<{
retweets: z.ZodNumber;
quotes: z.ZodNumber;
likes: z.ZodNumber;
replies: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}>>;
inReplyToId: z.ZodOptional<z.ZodString>;
quotedPostId: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}>, z.ZodArray<z.ZodObject<{
id: z.ZodString;
text: z.ZodString;
createdAt: z.ZodString;
authorId: z.ZodString;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
id: z.ZodString;
type: z.ZodEnum<["image", "video", "gif"]>;
url: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}>, "many">>;
metrics: z.ZodOptional<z.ZodObject<{
retweets: z.ZodNumber;
quotes: z.ZodNumber;
likes: z.ZodNumber;
replies: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}>>;
inReplyToId: z.ZodOptional<z.ZodString>;
quotedPostId: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}>, "many">]>;
declare const RepostResponseSchema: z.ZodUnion<[z.ZodObject<{
id: z.ZodString;
text: z.ZodString;
createdAt: z.ZodString;
authorId: z.ZodString;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
id: z.ZodString;
type: z.ZodEnum<["image", "video", "gif"]>;
url: z.ZodOptional<z.ZodString>;
altText: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}, {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}>, "many">>;
metrics: z.ZodOptional<z.ZodObject<{
retweets: z.ZodNumber;
quotes: z.ZodNumber;
likes: z.ZodNumber;
replies: z.ZodNumber;
}, "strip", z.ZodTypeAny, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}, {
retweets: number;
quotes: number;
likes: number;
replies: number;
}>>;
inReplyToId: z.ZodOptional<z.ZodString>;
quotedPostId: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}, {
id: string;
text: string;
createdAt: string;
authorId: string;
media?: {
type: "image" | "video" | "gif";
id: string;
url?: string | undefined;
altText?: string | undefined;
}[] | undefined;
metrics?: {
retweets: number;
quotes: number;
likes: number;
replies: number;
} | undefined;
inReplyToId?: string | undefined;
quotedPostId?: string | undefined;
}>, z.ZodArray<z.ZodObject<{
id: z.ZodString;
text: z.ZodString;
createdAt: z.ZodString;
authorId: z.ZodString;
media: z.ZodOptional<z.ZodArray<z.ZodObject<{
id: z