Management API Reference

Server

Using backend wallets

Create wallet#

Backend wallets can be created through our dashboard or API. You can either create a new wallet or add an existing one.

Using the Dashboard#

Navigate to the Openfort dashboard and create a new developer account.

Using the API#

You can create or add developer accounts through our API:


_10
const Openfort = require('@openfort/openfort-node').default;
_10
const openfort = new Openfort(YOUR_SECRET_KEY);
_10
_10
const settings = await openfort.settings.createDeveloperAccount()

Transactions#

To execute a transaction from your backend wallet:


_14
const Openfort = require('@openfort/openfort-node').default;
_14
const openfort = new Openfort(YOUR_SECRET_KEY);
_14
_14
const transactionintents = await openfort.transactionIntents.create({
_14
account: 'dac_...', // Your backend wallet ID
_14
chainId: 80002,
_14
policy: 'pol_...', // Optional: Policy ID for gas sponsorship
_14
optimistic: true,
_14
interactions: {
_14
contract: 'con_....',
_14
functionName: 'transfer',
_14
functionArgs: ['recipient_address', 'amount']
_14
}
_14
})

For gas sponsorship, make sure to set up appropriate policies with account_functions rules. Learn more about creating policy sponsors.

Checking transaction status#

You can monitor the status of transactions through our webhook system or by querying the API:


_10
const transactionIntent = await openfort.transactionIntents.retrieve('tin_...');
_10
console.log(transactionIntent.status);

Webhooks

To keep your application in sync with blockchain events, Openfort provides webhooks for various events including transaction status changes and asset transfers.

Signature#

Coming soon