API Documentation
Integrate your applications with EarnFlow using our simple and powerful REST API.
https://earnflow.com.ng/api
All endpoints require HTTPS
Introduction
The EarnFlow API allows you to integrate your applications with our platform programmatically. You can check balances, manage orders, create new tasks, and more.
API Details
- Base URL:
https://earnflow.com.ng/api - Allowed Methods: GET, POST
- Response Format: JSON
- Authentication: Token-based
Quick Overview
| Endpoint | Method | Description |
|---|---|---|
/balance |
GET | Current balance and total withdrawal |
/service/list |
GET | List of services and IDs |
/order/list |
GET | All orders you have placed |
/get/order |
GET | Order details for the given ID/Link |
/update/order |
GET | Update order status (pause, resume, cancel, stopandrefund) |
/create/post |
POST | Create a new order/post |
/increase/audience |
POST | Increase audience for an existing order |
/search/order |
POST | Search orders with filters |
/download/audience_list |
GET | Download PDF list of earners who completed tasks |
Authentication
The EarnFlow API uses token-based authentication. You must include your API key in the Authorization header of every request.
Authorization Header Format
Authorization: Token (Your Key)
Example Request
curl -X GET https://earnflow.com.ng/api/balance \
-H 'Authorization: Token (Your Key)'
Getting Your API Key
To get your API key:
- Log in to your EarnFlow account
- Go to Dashboard → Settings → API Settings
- Generate a new API key
- Copy and store your key securely
Important: Never share your API key or commit it to version control. Keep it secret like a password.
Endpoints Reference
Detailed documentation for all available API endpoints.
Retrieve your current wallet balance and total withdrawal amount.
Parameters
This endpoint does not accept any parameters.
Example Request
curl -X GET https://earnflow.com.ng/api/balance \
-H 'Authorization: Token (Your Key)'
Example Response
{
"status": "success",
"balance": 25000,
"total_withdrawal": 150000,
"currency": "NGN"
}
Get a list of all available services and their IDs.
Parameters
This endpoint does not accept any parameters.
Example Request
curl -X GET https://earnflow.com.ng/api/service/list \
-H 'Authorization: Token (Your Key)'
Example Response
{
"status": "success",
"services": [
{
"id": 1,
"name": "Instagram Followers",
"category": "instagram",
"rate": 100,
"min": 100,
"max": 5000
},
{
"id": 2,
"name": "Instagram Likes",
"category": "instagram",
"rate": 50,
"min": 50,
"max": 10000
},
{
"id": 3,
"name": "Facebook Followers",
"category": "facebook",
"rate": 80,
"min": 100,
"max": 5000
}
]
}
Retrieve all orders you have placed, with optional filters.
Parameters
Example Request
curl -X GET "https://earnflow.com.ng/api/order/list?status=completed" \
-H 'Authorization: Token (Your Key)'
Example Response
{
"status": "success",
"orders": [
{
"id": 12345,
"service_id": 1,
"service_name": "Instagram Followers",
"link": "https://instagram.com/username",
"quantity": 1000,
"rate": 100,
"total": 100000,
"status": "completed",
"created_at": "2024-02-15 10:30:00"
}
],
"total": 1
}
Get details for a specific order by ID or link.
Parameters
Example Request
curl -X GET "https://earnflow.com.ng/api/get/order?id=12345" \
-H 'Authorization: Token (Your Key)'
Example Response
{
"status": "success",
"order": {
"id": 12345,
"service_id": 1,
"service_name": "Instagram Followers",
"link": "https://instagram.com/username",
"quantity": 1000,
"completed": 850,
"rate": 100,
"total": 100000,
"status": "in_progress",
"created_at": "2024-02-15 10:30:00",
"updated_at": "2024-02-15 11:45:00"
}
}
Create a new order/post for social media engagement.
Parameters
Example Request
curl -X POST https://earnflow.com.ng/api/create/post \
-H 'Authorization: Token (Your Key)' \
-H 'Content-Type: application/json' \
-d '{
"Social_Media": "instagram",
"link": "https://instagram.com/p/abc123",
"rate_needed": 1000,
"custom_text": "Check out this amazing post!"
}'
Example Response
{
"status": "success",
"message": "Order created successfully",
"order_id": 12346,
"estimated_cost": 100000
}
Update the status of an existing order (pause, resume, cancel, stopandrefund).
Parameters
Example Request
curl -X GET "https://earnflow.com.ng/api/update/order?id=12345&type=pause" \
-H 'Authorization: Token (Your Key)'
Example Response
{
"status": "success",
"message": "Order has been paused successfully",
"order_id": 12345,
"new_status": "paused"
}
Increase the audience quantity for an existing order.
Parameters
Example Request
curl -X POST https://earnflow.com.ng/api/increase/audience \
-H 'Authorization: Token (Your Key)' \
-H 'Content-Type: application/json' \
-d '{
"id": 12345,
"rate_needed": 500
}'
Example Response
{
"status": "success",
"message": "Audience increased successfully",
"order_id": 12345,
"new_quantity": 1500,
"additional_cost": 50000
}
Search for orders with filters. Returns filtered list of orders from all general orders placed on EarnFlow.
Parameters
Example Request
curl -X POST https://earnflow.com.ng/api/search/order \
-H 'Authorization: Token (Your Key)' \
-H 'Content-Type: application/json' \
-d '{
"filt_data": "instagram",
"social_media": "instagram"
}'
Example Response
{
"status": "success",
"orders": [
{
"id": 12345,
"service_id": 1,
"service_name": "Instagram Followers",
"link": "https://instagram.com/username",
"quantity": 1000,
"status": "in_progress",
"created_at": "2024-02-15 10:30:00"
}
],
"total": 15
}
Download a PDF list of earners who submitted approved tasks for an order.
Parameters
Example Request
curl -X GET "https://earnflow.com.ng/api/download/audience_list?id=12345" \
-H 'Authorization: Token (Your Key)' \
--output audience_list.pdf
Response
This endpoint returns a PDF file download. The response headers will include:
Content-Type: application/pdf
Content-Disposition: attachment; filename="audience_list_12345.pdf"
Response Codes
The API uses conventional HTTP response codes to indicate success or failure of requests.
| Code | Description |
|---|---|
| 200 OK | Request was successful |
| 400 Bad Request | Invalid input – The request was malformed or missing required parameters |
| 401 Unauthorized | Invalid or missing API token |
| 404 Not Found | Resource does not exist – The requested endpoint or resource was not found |
| 500 Internal Server Error | Something went wrong on our server. Try again later |
Error Response Format
When an error occurs, the API returns a JSON object with error details:
{
"status": "error",
"code": 400,
"message": "Invalid parameters",
"details": {
"field": "rate_needed",
"error": "must be a positive integer"
}
}
Ready to Start Building?
Get your API keys and start integrating EarnFlow into your applications today.
Get API Keys