GLAMIDL Reference

initialize_state

Initializes a GLAM state account for a vault or related account type.

Required conditions

  • Creation-style flows require the target account or PDA to be uninitialized or intentionally updatable, the fee payer to be writable, and the System Program to be present when rent or allocation is needed.

Accounts

AccountRoleDescription
glam_statewritableGLAM state account that stores vault configuration, integration ACLs, delegate permissions, policies, assets, mint linkage, and pricing records.
glam_signersigner, writableCalling authority or fee payer.
system_programread-onlySolana System Program.
base_asset_mintread-onlyToken mint account used or validated by this instruction.

Arguments

ArgumentTypeNotes
stateStateModel

Policy & permissions

  • Only the GLAM owner can call this; delegates are rejected.

TypeScript SDK usage

import { GlamClient, StateAccountType, nameToChars } from "@glamsystems/glam-sdk";

const glamClient = new GlamClient();
await glamClient.state.create({
  accountType: StateAccountType.VAULT,
  name: nameToChars("Managed Vault"),
});