function postEvent
postEvent(
origin: string,
event: string
): Promise<boolean>

Sends the signed event event to the events endpoint of the instance at origin, and returns whether it took it. A 4xx other than 429 means it never will, which the caller treats as delivered.

Parameters

origin: string
event: string

Return Type

Promise<boolean>

Throws

Error

When it can't be reached, or answers 429 or a 5xx.

Usage

import { postEvent } from "api/remote/gerbeur-instance.ts";