List creator attribution links
curl --request GET \
--url https://app.openlight.tech/api/creator/v1/links \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.openlight.tech/api/creator/v1/links"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.openlight.tech/api/creator/v1/links', 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://app.openlight.tech/api/creator/v1/links",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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://app.openlight.tech/api/creator/v1/links"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.openlight.tech/api/creator/v1/links")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.openlight.tech/api/creator/v1/links")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"links": [
{
"id": "<string>",
"brand_id": "<string>",
"product_id": "<string>",
"url": "<string>",
"destination_url": "<string>",
"marketplace": "<string>",
"tracking_id": "<string>",
"status": "active",
"created_at": "2023-11-07T05:31:56Z"
}
],
"next_cursor": "<string>"
}Links
List attribution links
List creator attribution links
GET
/
api
/
creator
/
v1
/
links
List creator attribution links
curl --request GET \
--url https://app.openlight.tech/api/creator/v1/links \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.openlight.tech/api/creator/v1/links"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.openlight.tech/api/creator/v1/links', 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://app.openlight.tech/api/creator/v1/links",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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://app.openlight.tech/api/creator/v1/links"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.openlight.tech/api/creator/v1/links")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.openlight.tech/api/creator/v1/links")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"links": [
{
"id": "<string>",
"brand_id": "<string>",
"product_id": "<string>",
"url": "<string>",
"destination_url": "<string>",
"marketplace": "<string>",
"tracking_id": "<string>",
"status": "active",
"created_at": "2023-11-07T05:31:56Z"
}
],
"next_cursor": "<string>"
}Use this endpoint to list attribution links created by the current creator. List endpoints use cursor pagination:
limit defaults to 25 and cannot exceed 100; pass the previous response’s next_cursor as cursor to read the next page. When there are no more results, next_cursor is null.
Link fields:
id: Attribution link ID.brand_id: Brand ID.product_id: Product ID.url: Shareable attribution link URL.destination_url: Amazon landing page URL, usually the product detail page or the requested destination.marketplace: Amazon marketplace domain for the attribution link, such asamazon.com,amazon.co.uk, oramazon.de. It identifies the link’s Amazon site; it is not a partnership status or tracking tag.tracking_id: Client-side tracking tag supplied when the link was created; empty string when omitted. Future reports will use this field for downstream attribution.status: Link status. Because the underlying AttributionLink does not currently have a status field, this is alwaysactive.created_at: Link creation time.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
每页返回数量,默认 25,最大 100。Number of items per page; defaults to 25 and maxes out at 100.
Required range:
x <= 100上一页响应返回的下一页游标。Cursor returned as next_cursor by the previous page.