Add Signal and Whatsapp Docker CI

This commit is contained in:
Darren Clarke 2024-05-15 10:27:14 +02:00
parent b8ff61265b
commit 6305a8b0bc
12 changed files with 99 additions and 8 deletions

View file

@ -82,6 +82,20 @@ export class Service {
return NextResponse.json({ response: "ok" });
}
async receiveMessage(
req: NextRequest,
{ params: { service, token } }: ServiceParams,
): Promise<NextResponse> {
const message = await req.json();
const worker = await getWorkerUtils();
await worker.addJob(`${service}/receive-${service}-message`, {
token,
message,
});
return NextResponse.json({ response: "ok" });
}
async handleWebhook(_req: NextRequest): Promise<NextResponse> {
return NextResponse.error() as any;
}