(
path: string,
opts: {
method?: string;
body?: unknown;
query?: Record<string, unknown>;
schema: z.ZodType<T>;
}
)
| 417 | return this.on('conversation.renamed', handler); |
| 418 | } |
| 419 | |
| 420 | onConversationLeft(handler: (ctx: string, e: ConversationLeftEvent) => void): () => void { |
| 421 | return this.on('conversation.left', handler); |
| 422 | } |
| 423 | |
| 424 | onConversationRead(handler: (ctx: string, e: ConversationReadEvent) => void): () => void { |
| 425 | return this.on('conversation.read', handler); |
| 426 | } |
| 427 | |
| 428 | onConversationActivity(handler: (ctx: string, e: ConversationActivityEvent) => void): () => void { |
| 429 | return this.on('conversation.activity', handler); |
| 430 | } |
| 431 | |
| 432 | onBotStatus(handler: (ctx: string, e: BotStatusEvent) => void): () => void { |
| 433 | return this.on('bot.status', handler); |
| 434 | } |
| 435 | |
| 436 | onConversationStatus(handler: (ctx: string, e: ConversationStatusEvent) => void): () => void { |
| 437 | return this.on('conversation.status', handler); |
| 438 | } |
| 439 | |
| 440 | // ── Private HTTP helper ─────────────────────────────────────────────────── |
| 441 | |
| 442 | private async httpRequest<T>( |
| 443 | path: string, |
| 444 | opts: { |
no test coverage detected