List creators that you have an active partnership with. Filter results by any of your Brand IDs.

Method: GET (paginated)

Parameters:

Response:

{
  "creators": [
    {
      "id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
      "name": "string",
      "email": "string",
      "bio": "string",
      "partneredBrandIds": [
        "3fa85f64-5717-4562-b3fc-2c963f66afa6"
      ]
    }
  ],
  "cursor": "string"
}

Errors:

Example:

const API_KEY = "LEVANTA_SELLER_API_KEY"
const ENDPOINT = "<https://app.levanta.io/api/seller/v1/creators/active>"

let cursor;
const creators = [];

const parameters = new URLSearchParams();
parameters.set("limit", 50); // Get 50 creators per response
// Limit creators to those partnered with the given two brands
parameters.set("brand_ids", "2ffb8c24-4496-4c68-a4e7-4ab7a39c6b90,76685df2-4ea5-4af3-943c-22e7a90a949d");

while (cursor !== null) {
	const response = await fetch(`${ENDPOINT}?${parameters.toString()}`, {
		method: "GET",
		headers: {
			Authorization: `Bearer ${API_KEY}`
		}
	});
	const json = await response.json();
	creators.push(...json.creators);
	cursor = json.cursor;
	if (cursor) parameters.set("cursor", cursor);
}
console.log(creators);