UNPKG

humanlayer

Version:

typescript client for humanlayer.dev

74 lines (73 loc) 2 kB
type FunctionCallStatus = { requested_at: Date; responded_at?: Date; approved?: boolean; comment?: string; reject_option_name?: string; }; type SlackContactChannel = { channel_or_user_id: string; context_about_channel_or_user?: string; bot_token?: string; experimental_slack_blocks?: boolean; }; type SMSContactChannel = { phone_number: string; context_about_user?: string; }; type WhatsAppContactChannel = { phone_number: string; context_about_user?: string; }; type EmailContactChannel = { address: string; context_about_user?: string; experimental_subject_line?: string; experimental_in_reply_to_message_id?: string; experimental_references_message_id?: string; }; type ContactChannel = { slack?: SlackContactChannel; sms?: SMSContactChannel; whatsapp?: WhatsAppContactChannel; email?: EmailContactChannel; }; type ResponseOption = { name: string; title?: string; description?: string; prompt_fill?: string; interactive?: boolean; }; type FunctionCallSpec = { fn: string; kwargs: Record<string, any>; channel?: ContactChannel; reject_options?: ResponseOption[]; state?: Record<string, any>; }; type FunctionCall = { run_id: string; call_id: string; spec: FunctionCallSpec; status?: FunctionCallStatus; }; type HumanContactSpec = { msg: string; channel?: ContactChannel; response_options?: ResponseOption[]; state?: Record<string, any>; }; type HumanContactStatus = { requested_at?: Date; responded_at?: Date; response?: string; response_option_name?: string; }; type HumanContact = { run_id: string; call_id: string; spec: HumanContactSpec; status?: HumanContactStatus; }; export { SlackContactChannel, SMSContactChannel, WhatsAppContactChannel, EmailContactChannel, ContactChannel, ResponseOption, FunctionCallSpec, FunctionCallStatus, FunctionCall, HumanContactSpec, HumanContactStatus, HumanContact, };