Prerequisites

Before you begin, make sure you have:

  • A Solana wallet (like Phantom)
  • A way to make HTTP requests (curl, Postman, or your preferred HTTP client).

Direct API Integration

1. Initialize Claim

First, request a sign-in message for your wallet:

curl "https://api.pow.cards/api/v1/claim/init?publicKey=YOUR_SOLANA_PUBLIC_KEY"

2. Sign Message

Use your Solana wallet to sign the message. Here’s an example using the Phantom wallet:

const messageBytes = new TextEncoder().encode(message);
const signature = await window.phantom.solana.signMessage(messageBytes);

3. Create Wallet Pass

Submit the signed message to create your wallet pass:

curl -X POST "https://api.pow.cards/api/v1/claim/wallet-pass" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "pow.cards wants you to create a POW card...",
    "signature": "base58_signature",
    "publicKey": "YOUR_SOLANA_PUBLIC_KEY",
    "walletType": "Phantom"
  }'

Next Steps