Listing ALL Brands
To retrieve a list of all brands in your Drop Cowboy account, use either the SDK or the REST API.
This endpoint returns all brands, including those that are approved (api_allowed: true) and those that have not yet been granted API access (api_allowed: false).
Using the SDK
// Download the helper library from https://www.npmjs.com/package/dropcowboy
const { DropCowboy } = require("dropcowboy"); // Or, for ESM: import { DropCowboy } from "dropcowboy";
// Find your Team ID and Secret at dropcowboy.com/appv1/#/api
// and set the environment variables.
const teamId = process.env.DROPCOWBOY_TEAM_ID;
const secret = process.env.DROPCOWBOY_SECRET;
const client = new DropCowboy({ teamId: teamId, secret: secret });
async function getTrustedBrands() {
const brands = await client.listBrands();
console.log(brands);
};
getTrustedBrands();API Endpoint
GET
https://api.dropcowboy.com/v1/brandExample Request
Required Headers
x-team-id- Your Team ID from API settingsx-secret- Your Secret Key from API settings
Invoke our brand api from your application by sending an HTTP GET containing with the attributes listed.
Authorizations
x-team-id / x-secretstringRequired
Requires two headers: x-team-id and x-secret. Both must be sent with each request.
Responses
200
Array of brands
application/json
get
/brand200
Array of brands
Example Response
The response will be an array of brand objects
Last updated
Was this helpful?