Skip to main content

💳 Wallets Endpoint

Overview

The /wallets endpoint allows you to create a list of wallets. You need to specify the number of wallets you want to create in the request body. The endpoint returns an array of objects, each containing the public and private key for each wallet.

Endpoint

POST /wallets

Request Body

The request body should be a JSON object with the following property:

PropertyTypeRequiredDescriptionExample
numbernumberYesThe number of wallets to create.5

Response

A successful response will be a JSON object containing the response status and an array of wallet objects. Each wallet object will have the following properties:

PropertyTypeDescription
publicKeystringThe public key of the wallet.
privateKeystringThe private key of the wallet.

Examples

const fetch = require('node-fetch');

const url = "https://pumpapi.dev/wallets";
const payload = {
number: 5
};

await fetch(url, {
method: "POST",
headers: {
"Content-Type": "application/json"
},
body: JSON.stringify(payload)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error('Error:', error));

Response Example

{
"status": 200,
"wallets": [
{
"publicKey": "ABCDEFG1234567890HIJKLMNOPQRSTUV",
"privateKey": "1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ"
},
{
"publicKey": "WXYZ1234567890ABCDEFGHIJKLMNOPQRST",
"privateKey": "ZYXWVUTSRQPONMLKJIHGFEDCBA098765"
},
{
"publicKey": "QRST1234567890ABCDEFGHIJKLMNOPUVWX",
"privateKey": "567890ABCDEFGHIJKLMNOPQRST1234567890"
},
{
"publicKey": "UVWXYZ1234567890ABCDEFGHIJKLMNOPQRST",
"privateKey": "ABCDEFGHIJKLMNOPQRSTUVWXYZ0987654321"
},
{
"publicKey": "IJKLMNOPQRST1234567890ABCDEFGHIJKLMNOP",
"privateKey": "87654321ABCDEFGHIJKLMNOPQRSTUVWXYZ098765"
}
]
}