OpenPayments.WalletAddress (open_payments_elixir v1.0.0)

Copy Markdown View Source

Public wallet-address discovery using full wallet URLs or payment pointers.

Discovery uses an unsigned GET and validates the returned wallet information. Production identifiers use HTTPS without user-info, explicit port, query, or fragment. With HTTP explicitly enabled on the client, HTTP URLs and local ports are accepted for development. Paths and returned server URLs are not inferred from a provider's layout. Redirects are returned as HTTP errors.

Summary

Functions

Fetches and validates public wallet information without signing the request.

Fetches the public JWKS bound to a wallet URL or payment pointer.

Functions

get(client, address)

Fetches and validates public wallet information without signing the request.

get_keys(client, address)

@spec get_keys(OpenPayments.Client.t(), String.t()) ::
  {:ok, OpenPayments.Types.JWKS.t()} | {:error, OpenPayments.Error.t()}

Fetches the public JWKS bound to a wallet URL or payment pointer.

Appends jwks.json to the resolved wallet URL, reusing an existing trailing slash. Root payment pointers first resolve to /.well-known/pay. This operation is unsigned, does not follow redirects or cache keys, and validates each public key using the shared schema. Key selection and signature verification are separate from discovery.