Skip to main content
Read a policy template to inspect the authority and actions saved for wallet creation. This metadata describes a template, not an existing wallet’s on-chain permissions. Use the same Developer SDK client that prepares your wallet operations. Reading a template requires an API key with access to it; it does not require a wallet signature.

Before you begin

Fetch a template

The following examples use your initialized swig client and policy ID.
TypeScript
Both clients call GET /wallet/policies/{policyId} on the hosted API. TypeScript returns the policy metadata directly; Python exposes a Policy object and normalizes its top-level field names to snake case. This SDK lookup returns initial-user policy metadata and recovery fields; it does not return the additional users saved in the portal template. Keep the authorities and actions needed for your add-role requests in your application’s configuration. See Policy Templates for the wallet-creation and additional-user setup boundaries.

Understand the result

The response describes stored configuration. For example, a template created in the portal gives its initial user full root access. The TypeScript client preserves the API’s wallet-authority shape:
A template can omit the authority so that your application supplies the initial user at wallet creation. The actions list contains saved action data. See Permissions for the meaning of each grant, its units, and the Developer SDK inputs used when adding a role. Policy response actions use stored action names and fields. When adding a role, map them to the typed SDK inputs shown in the reference rather than forwarding stored action data unchanged. To inspect the authorities and permissions currently attached to a wallet, use Read Wallet State.

Handle read errors

The TypeScript client throws SwigDeveloperSdkError for failed API requests:
Check the API key and its resource access for 401 or 403 responses. For a 404, check that the policy ID exists and is visible to the caller. See Developer API Errors for other response statuses.

Continue with the template

Pass the policy ID when you Create Wallets. The SDK reads the template as part of wallet preparation. Your application then signs and submits the returned transactions.