Skip to content
Functioncorev0.12.0

OwnerOnly

Passes only for a user id listed in config.ownerIds, else refuses.

Agnostic, so it attaches to interaction and event handlers alike. With no ownerIds configured it refuses every caller. Pass a Notice class as notice to replace the refusal.

See also:the @Gated decorator from your transport package

OwnerOnly(
    options?: GateNoticeOptions
): Gate<GateContextBase, "OwnerOnly">

options?

Replace the refusal with a Notice class as notice.