Files
openclaw/src/utils/delivery-context.types.ts
2026-05-06 01:46:42 +01:00

33 lines
751 B
TypeScript

import type { ChannelRouteTargetInput } from "../plugin-sdk/channel-route.js";
export type DeliveryIntentRef = {
id: string;
kind: "outbound_queue";
queuePolicy?: "required" | "best_effort";
};
export type DeliveryContext = Pick<
ChannelRouteTargetInput,
"accountId" | "channel" | "threadId" | "to"
> & {
channel?: string;
to?: string;
accountId?: string;
threadId?: string | number;
deliveryIntent?: DeliveryIntentRef;
};
export type DeliveryContextSessionSource = {
channel?: string;
lastChannel?: string;
lastTo?: string;
lastAccountId?: string;
lastThreadId?: string | number;
origin?: {
provider?: string;
accountId?: string;
threadId?: string | number;
};
deliveryContext?: DeliveryContext;
};