Skip to main content
You can limit the number of times the session can be used. To enable the policy:
const session: Session = {
  owners: {
    type: 'ecdsa',
    accounts: [sessionOwnerAccount],
  },
  actions: [
    {
      policies: [
        {
          type: 'usage-limit',
          limit: 10n,
        },
      ],
    },
  ],
}
This will create a session that can only be used 10 times.