cURL
curl --request GET \
--url https://firstpromoter.com/api/v1/promoters/list \
--header 'X-API-KEY: <api-key>'import requests
url = "https://firstpromoter.com/api/v1/promoters/list"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch('https://firstpromoter.com/api/v1/promoters/list', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://firstpromoter.com/api/v1/promoters/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://firstpromoter.com/api/v1/promoters/list"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://firstpromoter.com/api/v1/promoters/list")
.header("X-API-KEY", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://firstpromoter.com/api/v1/promoters/list")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-KEY"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": 8815216,
"status": "active",
"cust_id": null,
"email": "mintly@mailinator.com",
"created_at": "2024-09-11T14:20:50.403Z",
"temp_password": "1y-JxB",
"default_promotion_id": 10116083,
"pref": "y3fvz4o",
"default_ref_id": "heubv",
"note": null,
"w8_form_url": null,
"w9_form_url": null,
"parent_promoter_id": null,
"earnings_balance": null,
"current_balance": null,
"paid_balance": null,
"auth_token": "X9edc-csF56dt8qB6KwcDyPhVdMUtWXY",
"profile": {
"id": 8862106,
"first_name": null,
"last_name": null,
"website": null,
"company_name": null,
"phone_number": null,
"address": null,
"vat_id": null,
"country": null,
"paypal_email": null,
"avatar_url": null,
"description": null,
"social_accounts": {}
},
"promotions": [
{
"id": 10116083,
"status": "offer_running",
"ref_id": "heubv",
"promo_code": null,
"customer_promo_code": null,
"target_reached_at": null,
"promoter_id": 8815216,
"campaign_id": 26127,
"referral_link": "https://lastechworld.com?fpr=heubv",
"current_offer": {
"id": 140358,
"name": "1 free subscription months",
"amount": 1,
"unit": "free_months",
"default_promo_code": ""
},
"current_referral_reward": {
"id": 140359,
"amount": 1,
"type": "per_referral",
"unit": "free_months",
"name": "1 free subscription months",
"per_of_sale": 0,
"default_promo_code": ""
},
"current_promotion_reward": null,
"current_target_reward": null,
"campaign_name": "Make Campaign",
"hidden": false,
"visitors_count": 0,
"leads_count": 0,
"customers_count": 0,
"refunds_count": 0,
"cancellations_count": 0,
"sales_count": 0,
"sales_total": 0,
"refunds_total": 0,
"active_customers_count": 0
}
]
},
{
"id": 8809547,
"status": "active",
"cust_id": null,
"email": "prince+grace@mailinator.com",
"created_at": "2024-09-09T22:01:16.909Z",
"temp_password": "yx4_LJ",
"default_promotion_id": 10108807,
"pref": "udicfs6",
"default_ref_id": "ljysw",
"note": null,
"w8_form_url": null,
"w9_form_url": null,
"parent_promoter_id": null,
"earnings_balance": null,
"current_balance": null,
"paid_balance": null,
"auth_token": "kitwmn6ER9RzfZ5Mn9Ksv8PFxnpAzwBT",
"profile": {
"id": 8856384,
"first_name": null,
"last_name": null,
"website": null,
"company_name": null,
"phone_number": null,
"address": null,
"vat_id": null,
"country": null,
"paypal_email": null,
"avatar_url": null,
"description": null,
"social_accounts": {}
},
"promotions": [
{
"id": 10108807,
"status": "offer_running",
"ref_id": "ljysw",
"promo_code": null,
"customer_promo_code": null,
"target_reached_at": null,
"promoter_id": 8809547,
"campaign_id": 26127,
"referral_link": "https://lastechworld.com?fpr=ljysw",
"current_offer": {
"id": 140358,
"name": "1 free subscription months",
"amount": 1,
"unit": "free_months",
"default_promo_code": ""
},
"current_referral_reward": {
"id": 140359,
"amount": 1,
"type": "per_referral",
"unit": "free_months",
"name": "1 free subscription months",
"per_of_sale": 0,
"default_promo_code": ""
},
"current_promotion_reward": null,
"current_target_reward": null,
"campaign_name": "Make Campaign",
"hidden": false,
"visitors_count": 0,
"leads_count": 0,
"customers_count": 0,
"refunds_count": 0,
"cancellations_count": 0,
"sales_count": 0,
"sales_total": 0,
"refunds_total": 0,
"active_customers_count": 0
}
]
}
]"Bad credentials"{
"error": "Campaign not found."
}Promoters
List promoters
List promoters, optionally for one campaign, with pagination in the response headers (legacy v1 API).
GET
/
list
cURL
curl --request GET \
--url https://firstpromoter.com/api/v1/promoters/list \
--header 'X-API-KEY: <api-key>'import requests
url = "https://firstpromoter.com/api/v1/promoters/list"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch('https://firstpromoter.com/api/v1/promoters/list', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://firstpromoter.com/api/v1/promoters/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://firstpromoter.com/api/v1/promoters/list"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-KEY", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://firstpromoter.com/api/v1/promoters/list")
.header("X-API-KEY", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://firstpromoter.com/api/v1/promoters/list")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-KEY"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": 8815216,
"status": "active",
"cust_id": null,
"email": "mintly@mailinator.com",
"created_at": "2024-09-11T14:20:50.403Z",
"temp_password": "1y-JxB",
"default_promotion_id": 10116083,
"pref": "y3fvz4o",
"default_ref_id": "heubv",
"note": null,
"w8_form_url": null,
"w9_form_url": null,
"parent_promoter_id": null,
"earnings_balance": null,
"current_balance": null,
"paid_balance": null,
"auth_token": "X9edc-csF56dt8qB6KwcDyPhVdMUtWXY",
"profile": {
"id": 8862106,
"first_name": null,
"last_name": null,
"website": null,
"company_name": null,
"phone_number": null,
"address": null,
"vat_id": null,
"country": null,
"paypal_email": null,
"avatar_url": null,
"description": null,
"social_accounts": {}
},
"promotions": [
{
"id": 10116083,
"status": "offer_running",
"ref_id": "heubv",
"promo_code": null,
"customer_promo_code": null,
"target_reached_at": null,
"promoter_id": 8815216,
"campaign_id": 26127,
"referral_link": "https://lastechworld.com?fpr=heubv",
"current_offer": {
"id": 140358,
"name": "1 free subscription months",
"amount": 1,
"unit": "free_months",
"default_promo_code": ""
},
"current_referral_reward": {
"id": 140359,
"amount": 1,
"type": "per_referral",
"unit": "free_months",
"name": "1 free subscription months",
"per_of_sale": 0,
"default_promo_code": ""
},
"current_promotion_reward": null,
"current_target_reward": null,
"campaign_name": "Make Campaign",
"hidden": false,
"visitors_count": 0,
"leads_count": 0,
"customers_count": 0,
"refunds_count": 0,
"cancellations_count": 0,
"sales_count": 0,
"sales_total": 0,
"refunds_total": 0,
"active_customers_count": 0
}
]
},
{
"id": 8809547,
"status": "active",
"cust_id": null,
"email": "prince+grace@mailinator.com",
"created_at": "2024-09-09T22:01:16.909Z",
"temp_password": "yx4_LJ",
"default_promotion_id": 10108807,
"pref": "udicfs6",
"default_ref_id": "ljysw",
"note": null,
"w8_form_url": null,
"w9_form_url": null,
"parent_promoter_id": null,
"earnings_balance": null,
"current_balance": null,
"paid_balance": null,
"auth_token": "kitwmn6ER9RzfZ5Mn9Ksv8PFxnpAzwBT",
"profile": {
"id": 8856384,
"first_name": null,
"last_name": null,
"website": null,
"company_name": null,
"phone_number": null,
"address": null,
"vat_id": null,
"country": null,
"paypal_email": null,
"avatar_url": null,
"description": null,
"social_accounts": {}
},
"promotions": [
{
"id": 10108807,
"status": "offer_running",
"ref_id": "ljysw",
"promo_code": null,
"customer_promo_code": null,
"target_reached_at": null,
"promoter_id": 8809547,
"campaign_id": 26127,
"referral_link": "https://lastechworld.com?fpr=ljysw",
"current_offer": {
"id": 140358,
"name": "1 free subscription months",
"amount": 1,
"unit": "free_months",
"default_promo_code": ""
},
"current_referral_reward": {
"id": 140359,
"amount": 1,
"type": "per_referral",
"unit": "free_months",
"name": "1 free subscription months",
"per_of_sale": 0,
"default_promo_code": ""
},
"current_promotion_reward": null,
"current_target_reward": null,
"campaign_name": "Make Campaign",
"hidden": false,
"visitors_count": 0,
"leads_count": 0,
"customers_count": 0,
"refunds_count": 0,
"cancellations_count": 0,
"sales_count": 0,
"sales_total": 0,
"refunds_total": 0,
"active_customers_count": 0
}
]
}
]"Bad credentials"{
"error": "Campaign not found."
}Use this endpoint to list your promoters using the API. The response will return the promoters as JSON array.
Pagination details are held on response headers. Add —include option on curl request to see the pagination details format and links to next pages.
Response
List Promoters response
Example:
[
{
"id": 8815216,
"status": "active",
"cust_id": null,
"email": "mintly@mailinator.com",
"created_at": "2024-09-11T14:20:50.403Z",
"temp_password": "1y-JxB",
"default_promotion_id": 10116083,
"pref": "y3fvz4o",
"default_ref_id": "heubv",
"note": null,
"w8_form_url": null,
"w9_form_url": null,
"parent_promoter_id": null,
"earnings_balance": null,
"current_balance": null,
"paid_balance": null,
"auth_token": "X9edc-csF56dt8qB6KwcDyPhVdMUtWXY",
"profile": {
"id": 8862106,
"first_name": null,
"last_name": null,
"website": null,
"company_name": null,
"phone_number": null,
"address": null,
"vat_id": null,
"country": null,
"paypal_email": null,
"avatar_url": null,
"description": null,
"social_accounts": {}
},
"promotions": [
{
"id": 10116083,
"status": "offer_running",
"ref_id": "heubv",
"promo_code": null,
"customer_promo_code": null,
"target_reached_at": null,
"promoter_id": 8815216,
"campaign_id": 26127,
"referral_link": "https://lastechworld.com?fpr=heubv",
"current_offer": {
"id": 140358,
"name": "1 free subscription months",
"amount": 1,
"unit": "free_months",
"default_promo_code": ""
},
"current_referral_reward": {
"id": 140359,
"amount": 1,
"type": "per_referral",
"unit": "free_months",
"name": "1 free subscription months",
"per_of_sale": 0,
"default_promo_code": ""
},
"current_promotion_reward": null,
"current_target_reward": null,
"campaign_name": "Make Campaign",
"hidden": false,
"visitors_count": 0,
"leads_count": 0,
"customers_count": 0,
"refunds_count": 0,
"cancellations_count": 0,
"sales_count": 0,
"sales_total": 0,
"refunds_total": 0,
"active_customers_count": 0
}
]
},
{
"id": 8809547,
"status": "active",
"cust_id": null,
"email": "prince+grace@mailinator.com",
"created_at": "2024-09-09T22:01:16.909Z",
"temp_password": "yx4_LJ",
"default_promotion_id": 10108807,
"pref": "udicfs6",
"default_ref_id": "ljysw",
"note": null,
"w8_form_url": null,
"w9_form_url": null,
"parent_promoter_id": null,
"earnings_balance": null,
"current_balance": null,
"paid_balance": null,
"auth_token": "kitwmn6ER9RzfZ5Mn9Ksv8PFxnpAzwBT",
"profile": {
"id": 8856384,
"first_name": null,
"last_name": null,
"website": null,
"company_name": null,
"phone_number": null,
"address": null,
"vat_id": null,
"country": null,
"paypal_email": null,
"avatar_url": null,
"description": null,
"social_accounts": {}
},
"promotions": [
{
"id": 10108807,
"status": "offer_running",
"ref_id": "ljysw",
"promo_code": null,
"customer_promo_code": null,
"target_reached_at": null,
"promoter_id": 8809547,
"campaign_id": 26127,
"referral_link": "https://lastechworld.com?fpr=ljysw",
"current_offer": {
"id": 140358,
"name": "1 free subscription months",
"amount": 1,
"unit": "free_months",
"default_promo_code": ""
},
"current_referral_reward": {
"id": 140359,
"amount": 1,
"type": "per_referral",
"unit": "free_months",
"name": "1 free subscription months",
"per_of_sale": 0,
"default_promo_code": ""
},
"current_promotion_reward": null,
"current_target_reward": null,
"campaign_name": "Make Campaign",
"hidden": false,
"visitors_count": 0,
"leads_count": 0,
"customers_count": 0,
"refunds_count": 0,
"cancellations_count": 0,
"sales_count": 0,
"sales_total": 0,
"refunds_total": 0,
"active_customers_count": 0
}
]
}
]