List affiliates
curl --request GET \
--url https://api.lomadee.com.br/brand/whitelabel/affiliates \
--header 'x-api-key: <api-key>'import requests
url = "https://api.lomadee.com.br/brand/whitelabel/affiliates"
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://api.lomadee.com.br/brand/whitelabel/affiliates', 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://api.lomadee.com.br/brand/whitelabel/affiliates",
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://api.lomadee.com.br/brand/whitelabel/affiliates"
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://api.lomadee.com.br/brand/whitelabel/affiliates")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.lomadee.com.br/brand/whitelabel/affiliates")
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{
"data": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"email": "[email protected]",
"document": "12345678909",
"documentType": "CPF",
"phone": "5511999998888",
"birthDate": "2023-12-25",
"legalName": "<string>",
"tradeName": "<string>",
"status": "pending",
"utm": "66981f67-7026-403b-95cd-165a9352dfb5_0b9d6a3e-5a0f-4a52-9c3e-2f1f7c8d4e10",
"address": {
"postalCode": "<string>",
"street": "<string>",
"number": "<string>",
"complement": "<string>",
"neighborhood": "<string>",
"city": "<string>",
"state": "<string>",
"country": "<string>"
},
"clusters": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
}
],
"additionalFields": [
{
"key": "store_code",
"name": "Store code",
"type": "text",
"value": "<string>"
}
],
"joinedAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
],
"meta": {
"total": 123,
"page": 123,
"limit": 123,
"totalPages": 123
}
}{
"success": false,
"message": "limit must not be greater than 100",
"code": "BAD_REQUEST"
}{
"success": false,
"message": "Invalid API key",
"code": "UNAUTHORIZED"
}{
"success": false,
"message": "Insufficient scope",
"code": "FORBIDDEN"
}{
"success": false,
"message": "Too many requests",
"code": "TOO_MANY_REQUESTS"
}White label reference
List affiliates
Returns the affiliates of your white-label program, with their registration data, groups and additional fields. Requires a brand key with scope whitelabel:affiliates:read.
GET
/
brand
/
whitelabel
/
affiliates
List affiliates
curl --request GET \
--url https://api.lomadee.com.br/brand/whitelabel/affiliates \
--header 'x-api-key: <api-key>'import requests
url = "https://api.lomadee.com.br/brand/whitelabel/affiliates"
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://api.lomadee.com.br/brand/whitelabel/affiliates', 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://api.lomadee.com.br/brand/whitelabel/affiliates",
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://api.lomadee.com.br/brand/whitelabel/affiliates"
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://api.lomadee.com.br/brand/whitelabel/affiliates")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.lomadee.com.br/brand/whitelabel/affiliates")
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{
"data": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"email": "[email protected]",
"document": "12345678909",
"documentType": "CPF",
"phone": "5511999998888",
"birthDate": "2023-12-25",
"legalName": "<string>",
"tradeName": "<string>",
"status": "pending",
"utm": "66981f67-7026-403b-95cd-165a9352dfb5_0b9d6a3e-5a0f-4a52-9c3e-2f1f7c8d4e10",
"address": {
"postalCode": "<string>",
"street": "<string>",
"number": "<string>",
"complement": "<string>",
"neighborhood": "<string>",
"city": "<string>",
"state": "<string>",
"country": "<string>"
},
"clusters": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>"
}
],
"additionalFields": [
{
"key": "store_code",
"name": "Store code",
"type": "text",
"value": "<string>"
}
],
"joinedAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
],
"meta": {
"total": 123,
"page": 123,
"limit": 123,
"totalPages": 123
}
}{
"success": false,
"message": "limit must not be greater than 100",
"code": "BAD_REQUEST"
}{
"success": false,
"message": "Invalid API key",
"code": "UNAUTHORIZED"
}{
"success": false,
"message": "Insufficient scope",
"code": "FORBIDDEN"
}{
"success": false,
"message": "Too many requests",
"code": "TOO_MANY_REQUESTS"
}Returns the affiliates of your white-label program, with their registration data, groups and additional fields. Requires scope
whitelabel:affiliates:read.Authorizations
Brand key created in the dashboard.
Query Parameters
Page number.
Required range:
x >= 1Items per page. Values above 100 return 400.
Required range:
1 <= x <= 100Filter by status in your program.
Available options:
pending, active, inactive Search by name, e-mail or document.
Maximum string length:
100Only affiliates of this group.
Only affiliates changed at or after this date (ISO 8601).