The Arkena provider exposes its API through a single entry point:
const result = await window.arkena.request({ method, params });This page lists every supported method. Methods are grouped by purpose.
The provider also implements CIP-103 discovery (EIP-6963 pattern), and
window.canton and window.arkena point to the same frozen object — pick
either, the request flow is identical.
Connection
canton_connect
Request connection to the dApp. Shows the user an approval popup.
paramsobjectOptional. No fields are accepted at this time; the wallet always grants the default permission set on approval.
Returns:
{
accounts: string[], // The user's party IDs (currently always length 1)
network: "devnet" | "testnet" | "mainnet",
}Throws: 4001 if the user rejects.
const { accounts, network } = await provider.request({ method: "canton_connect" });canton_disconnect
Revoke the current origin's access. The next canton_connect will show the
popup again.
Returns: void.
await provider.request({ method: "canton_disconnect" });Read
canton_getAccounts
Return the user's connected accounts. Currently always a single-element array.
Returns: string[].
canton_getNetwork
Return the network the wallet is currently configured for.
Returns: "devnet" | "testnet" | "mainnet".
canton_getBalance
Return native balances. For richer balance data (USDCx, NFT count), fetch from the backend with a SIWC token instead.
params{ partyId?: string }Optional. Defaults to the primary account.
Returns:
{
cc: string, // e.g. "12.345"
usdcx: string, // e.g. "100.00"
}Sign
canton_signMessage
Sign a structured message — used for SIWC. The wallet shows the message in a sign-in card.
params{ message: string }requiredThe message to sign. Format follows the EIP-4361 / SIWC convention.
Returns:
{ signature: string, publicKey: string }The publicKey is the hex-encoded Ed25519 verification key for the
signing party. Pair it with the connected account from canton_getAccounts
when you need to bind a signature to a party ID server-side.
Throws: 4001 (rejected), 4100 (wallet locked or unauthorized).
canton_signTransaction
Sign a Canton transaction prepared by the backend. The wallet shows the
summary from the prepare response as a card.
params.hashstringrequiredThe transaction hash to sign. Comes from the backend's prepare response.
params.commandIdstringrequiredThe deduplication ID for this submission. Pass through unchanged from the prepare response.
params.hashingSchemeVersionstringrequiredCanton's hashing scheme version. Pass through unchanged from the prepare response.
params.summaryTxSummaryrequiredThe structured transaction summary the wallet renders to the user. The backend builds this; pass through unchanged.
Returns:
{ signature: string, signedBy: string, partyId: string }Throws: 4001 (rejected), 4100 (locked), -32003 (transaction
rejected by the wallet's policy checks).
canton_getAuthToken
Convenience wrapper around the SIWC flow. Combines challenge fetch, message sign, and JWT issuance in a single round-trip when the wallet holds a fresh challenge for the current origin.
params{ partyId?: string }Optional. Defaults to the primary account.
Returns:
{ token: string, expiresAt: number }For finer control, use the manual SIWC flow described in Sign-In with Canton.
Status
canton_isConnected
Check whether the current origin is currently connected to a Canton party. Cheap, synchronous-feeling read; safe to call on every render.
Returns: boolean.
canton_status
Return the wallet's current state. Useful for rendering the right UI before any user action.
Returns:
{
connected: boolean,
locked: boolean,
network: "devnet" | "testnet" | "mainnet",
primaryAccount: string | null,
}canton_getPrimaryAccount
Return the user's primary account (the first / default party). Equivalent
to canton_getAccounts()[0] today; kept as a stable name for forward
compatibility once multi-account is enabled.
Returns: string — the primary party ID.
Reserved
canton_ledgerApi
Reserved for direct Canton Ledger API proxying. Not implemented yet — calling it raises an error. Listed here so dApp authors know the surface is taken and can plan around it.
Throws: an UNSUPPORTED error on every call.
CIP-103 aliases
The provider accepts a small set of CIP-103 / OpenAccount-style aliases
for the canonical canton_* names. They map to the same handlers and are
useful when integrating with a wallet-agnostic library:
| Alias | Maps to |
|---|---|
connect | canton_connect |
disconnect | canton_disconnect |
isConnected | canton_isConnected |
status | canton_status |
getActiveNetwork | canton_getNetwork |
listAccounts | canton_getAccounts |
getPrimaryAccount | canton_getPrimaryAccount |
signMessage | canton_signMessage |
prepareExecute | canton_signTransaction |
ledgerApi | canton_ledgerApi (stub) |
What's next
- Provider events — the subscribe-to-state side of the API.
- Error codes — every error code this page references, with example payloads.