Get Orders by Presale Round
Retrieve all orders placed in a specific presale round for admin management
ADMIN ONLY
Get Orders by Round
Retrieve all presale orders from a specific round for comprehensive management and analysis.
Admin Access Required
This query is only accessible to users with ADMIN privileges for presale round management.
Overview
The getPresaleOrders
query allows administrators to retrieve all orders placed in a specific presale round, providing insights into participation levels and token distribution.
GraphQL Schema
query {
getPresaleOrders(
presaleId: Int!
): [PreSaleOrder]
}
Parameters
presaleId
RequiredInt
The unique ID of the presale round to retrieve orders from.
Return Value
✓ Success Response
Returns an array of [PreSaleOrder] objects for the specified round.
Example Usage
Request
query GetRoundOrders {
getPresaleOrders(presaleId: 12) {
id
presaleId
userId
ndbAmount
destination
extAddr
status
createdAt
updatedAt
}
}
Response
{
"data": {
"getPresaleOrders": [
{
"id": 456,
"presaleId": 12,
"userId": 789,
"ndbAmount": 1000.0,
"destination": 1,
"extAddr": null,
"status": 2,
"createdAt": 1704067200,
"updatedAt": 1704153600
},
{
"id": 457,
"presaleId": 12,
"userId": 790,
"ndbAmount": 2500.0,
"destination": 2,
"extAddr": "0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb",
"status": 0,
"createdAt": 1704240000,
"updatedAt": 1704240000
}
]
}
}
Orders Retrieved
Successfully retrieved all orders for presale round 12.
Use Cases
Round Performance
Analyze total participation, token distribution, and revenue for specific presale rounds.
Participant Management
View all participants in a presale round for support, compliance, and communication purposes.
Token Allocation
Track token allocation and ensure fair distribution according to presale conditions.
Sales Analytics
Generate reports on order patterns, average order sizes, and participation trends.
Best Practices
📊 Data Aggregation
Calculate totals, averages, and statistics to understand presale round performance comprehensively.
🔍 Status Filtering
Filter orders client-side by status to identify pending payments or completed purchases.
📥 Export Functionality
Implement export features for compliance, tax reporting, and stakeholder communications.
⚡ Pagination
Consider implementing pagination for presale rounds with large numbers of orders.