Skip to main content

Quickstart Guide

This guide will help you create your first wallet and send a transaction using AxonVault WaaS.
Choose your integration path based on your use case:
  • Embedded Wallets: For consumer apps with social login
  • Server Wallets: For backend automation and treasury management

Prerequisites

Before you begin, you’ll need:
  1. An AxonVault account (Sign up here)
  2. A project created in the dashboard
  3. API credentials (Client Key and Secret Key)

Step 1: Get Your API Credentials

1

Create a Project

Log in to the AxonVault Dashboard and create a new project.
2

Generate API Keys

Navigate to Settings > API Keys and create a new API key pair.
Store your Secret Key securely. It will only be shown once and cannot be retrieved later.
3

Configure Chains

Select which blockchain networks your project will support (e.g., Ethereum, Base, Solana).

Step 2: Authenticate

All API requests require authentication. Generate an access token using your credentials:
curl -X POST https://api.axonvault.io/v1/iam/verify/credential \
  -H "Content-Type: application/json" \
  -d '{
    "accessKey": "your_client_key",
    "signature": "hmac_signature",
    "payload": "request_body",
    "method": "POST",
    "path": "/v1/server/wallets",
    "timestamp": "2024-01-15T10:30:00Z"
  }'

Step 3: Create a Wallet

For consumer applications, use the Embedded Wallet SDK:
import { AxonVaultEmbedded } from '@axonvault/embedded-wallet-sdk';

// Initialize SDK
const axonVault = new AxonVaultEmbedded({
  projectId: 'proj_abc123',
  environment: 'production'
});

// 1. User authenticates via social login
const user = await axonVault.authenticate({
  provider: 'google',
  idToken: googleIdToken
});

console.log('User authenticated:', user.userId);

// 2. Get or create wallet (SDK handles creation automatically)
const wallet = await axonVault.getOrCreateWallet({
  walletName: 'My First Wallet'
});

console.log('Wallet ready:', wallet.walletId);

// 3. Get addresses for a chain
const addresses = await wallet.getAddresses('eip155:8453');
console.log('Address:', addresses[0].address);

// 4. Send a transaction
const txHash = await wallet.sendTransaction({
  to: '0x1234567890123456789012345678901234567890',
  amount: '1000000000000000000', // 1 ETH
  chainId: 'eip155:8453'
});

console.log('Transaction sent:', txHash);

Full Integration Guide

See the complete embedded wallet integration guide

Step 4: Create an Account & Derive Address

Wallets contain accounts, and accounts have addresses on different chains:
# Create an account in the wallet
curl -X POST https://api.axonvault.io/v1/server/wallets/wlt_srv_abc123/accounts \
  -H "X-Access-Key: your_client_key" \
  -H "X-Signature: hmac_signature" \
  -H "X-Timestamp: 2024-01-15T10:30:00Z" \
  -H "Content-Type: application/json" \
  -d '{
    "accountIndex": 0,
    "accountName": "Main Account"
  }'
Response:
{
  "account": {
    "accountId": "acc_abc123",
    "walletId": "wlt_srv_abc123",
    "accountIndex": 0,
    "accountName": "Main Account",
    "accountStatus": 1,
    "createAt": "2024-01-15T10:30:00Z"
  }
}
# Derive an Ethereum address
curl -X POST https://api.axonvault.io/v1/wallets/wlt_srv_abc123/accounts/acc_abc123/addresses/derive \
  -H "X-Access-Key: your_client_key" \
  -H "X-Signature: hmac_signature" \
  -H "X-Timestamp: 2024-01-15T10:30:00Z" \
  -H "Content-Type: application/json" \
  -d '{
    "chainId": "eip155:1",
    "addressIndex": 0
  }'
Response:
{
  "address": {
    "addressId": "addr_abc123",
    "address": "0x742d35Cc6634C0532925a3b844Bc9e7595f8fE8d",
    "chainId": "eip155:1",
    "derivationPath": "m/44'/60'/0'/0/0",
    "publicKey": "0x04abc123...",
    "keyAlgorithm": "secp256k1"
  }
}

Step 5: Build and Send a Transaction

1

Build Transaction

curl -X POST https://api.axonvault.io/v1/transactions/build \
  -H "X-Access-Key: your_client_key" \
  -H "X-Signature: hmac_signature" \
  -H "X-Timestamp: 2024-01-15T10:30:00Z" \
  -H "Content-Type: application/json" \
  -d '{
    "fromAddress": "0x742d35Cc6634C0532925a3b844Bc9e7595f8fE8d",
    "toAddress": "0x1234567890123456789012345678901234567890",
    "amount": "1000000000000000000",
    "chainReference": "eip155:1",
    "chainId": "1"
  }'
Response:
{
  "txId": "tx_abc123",
  "unsignedTxHex": "0xf86c...",
  "signHashes": ["0xabc123..."],
  "metadata": {
    "nonce": "42",
    "gasLimit": "21000",
    "gasPrice": "20000000000",
    "chainId": "1"
  }
}
2

Sign Transaction

curl -X POST https://api.axonvault.io/v1/signature/sign \
  -H "X-Access-Key: your_client_key" \
  -H "X-Signature: hmac_signature" \
  -H "X-Timestamp: 2024-01-15T10:30:00Z" \
  -H "Content-Type: application/json" \
  -d '{
    "chainReference": "eip155:1",
    "unsignedTxHex": "0xf86c...",
    "keyId": "key_xyz789",
    "coinType": 60,
    "accountIndex": 0
  }'
Response:
{
  "signature": "0x...",
  "digest": "0xabc123...",
  "algorithm": "secp256k1"
}
3

Submit Transaction

curl -X POST https://api.axonvault.io/v1/transactions/submit \
  -H "X-Access-Key: your_client_key" \
  -H "X-Signature: hmac_signature" \
  -H "X-Timestamp: 2024-01-15T10:30:00Z" \
  -H "Content-Type: application/json" \
  -d '{
    "txId": "tx_abc123",
    "signedTxHex": "0xf86c..."
  }'
Response:
{
  "txId": "tx_abc123",
  "txHash": "0x1234567890abcdef...",
  "status": 1
}

Step 6: Check Transaction Status

curl -X GET https://api.axonvault.io/v1/transactions/tx_abc123 \
  -H "X-Access-Key: your_client_key" \
  -H "X-Signature: hmac_signature" \
  -H "X-Timestamp: 2024-01-15T10:30:00Z"
Response:
{
  "transaction": {
    "txId": "tx_abc123",
    "txHash": "0x1234567890abcdef...",
    "status": 2,
    "fromAddress": "0x742d35Cc6634C0532925a3b844Bc9e7595f8fE8d",
    "toAddress": "0x1234567890123456789012345678901234567890",
    "amount": "1000000000000000000",
    "chainReference": "eip155:1"
  }
}
Transaction statuses:
  • 0: Pending
  • 1: Submitted
  • 2: Confirmed
  • 3: Failed

Next Steps