UNPKG

@didtools/siwx

Version:

Typescript library for Sign-In With X

21 lines (20 loc) 780 B
import type { Opaque } from 'ts-essentials'; import { type Combinator } from 'codeco/linear'; export declare const port: Combinator<string, string>; /** * ABNF: * ``` * reg-name = *( unreserved / pct-encoded / sub-delims ) * unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" * pct-encoded = "%" HEXDIG HEXDIG * sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" * ``` */ export declare const regName: Combinator<string, string>; export declare const host: Combinator<string, string>; export declare const dnsauthority: Combinator<string, string>; /** * Custom SIWE domain. `dnsauthority` that can not be empty. */ export type DomainString = Opaque<string, 'domain'>; export declare const domain: Combinator<DomainString, string>;