Challenge binding shared by every usdc profile.
The EVM authorization nonce and the public request hash follow
draft-usdc-charge-00. requestHash inside the nonce preimage is the
0x-prefixed lowercase hex encoding of keccak256 over the UTF-8 JCS
request. The draft names that digest but does not pick a JSON string
encoding; hex with a 0x prefix matches the nonce field's own encoding.
Summary
Functions
EIP-3009 nonce bound to this USDC challenge.
Require a positive base-unit amount with no leading zeros.
Profile names the v00 draft allows in methodDetails.type.
Rebuild the public challenge request, without server config keys.
USDC receipt for a settled profile. network is the CAIP-2 settlement id.
Require a recipient for either direct USDC profile.
Select the single profile object whose key equals methodDetails.type.
Functions
EIP-3009 nonce bound to this USDC challenge.
request is the public JCS request map, not the server config merge.
@spec positive_amount(MPP.Intents.Charge.t()) :: :ok | {:error, MPP.Errors.t()}
Require a positive base-unit amount with no leading zeros.
@spec profile_types() :: [String.t()]
Profile names the v00 draft allows in methodDetails.type.
@spec public_request(MPP.Intents.Charge.t()) :: {:ok, map()} | {:error, MPP.Errors.t()}
Rebuild the public challenge request, without server config keys.
@spec receipt(MPP.Intents.Charge.t(), String.t(), String.t(), String.t()) :: MPP.Receipt.t()
USDC receipt for a settled profile. network is the CAIP-2 settlement id.
@spec require_recipient(MPP.Intents.Charge.t()) :: :ok | {:error, MPP.Errors.t()}
Require a recipient for either direct USDC profile.
@spec select_profile(map()) :: {:ok, String.t(), map()} | {:error, MPP.Errors.t()}
Select the single profile object whose key equals methodDetails.type.