import DodoPayments from 'dodopayments';const client = new DodoPayments({ bearerToken: process.env['DODO_PAYMENTS_API_KEY'], // This is the default and can be omitted});const brands = await client.brands.list();console.log(brands.items);
import os
from dodopayments import DodoPayments
client = DodoPayments(
bearer_token=os.environ.get("DODO_PAYMENTS_API_KEY"), # This is the default and can be omitted
)
brands = client.brands.list()
print(brands.items)
using System;
using DodoPayments.Client;
using DodoPayments.Client.Models.Brands;
DodoPaymentsClient client = new();
BrandListParams parameters = new();
var brands = await client.Brands.List(parameters);
Console.WriteLine(brands);
use dodopayments::Client;
#[tokio::main]
async fn main() -> dodopayments::Result<()> {
let client = Client::from_env()?;
let result = client
.brands()
.list()
.query(serde_json::json!({}))
.await?;
println!("{result:?}");
Ok(())
}
Send your API key as a bearer token: Authorization: Bearer <api_key>. A test mode key starts with dodo_test_, for example dodo_test_AbCd1234EfGh5678.<secret>. A live mode key starts with dodo_live_. Use a test mode key on test.dodopayments.com and a live mode key on live.dodopayments.com. Keys from before these tags have no tag and operate as before.
import DodoPayments from 'dodopayments';const client = new DodoPayments({ bearerToken: process.env['DODO_PAYMENTS_API_KEY'], // This is the default and can be omitted});const brands = await client.brands.list();console.log(brands.items);
import os
from dodopayments import DodoPayments
client = DodoPayments(
bearer_token=os.environ.get("DODO_PAYMENTS_API_KEY"), # This is the default and can be omitted
)
brands = client.brands.list()
print(brands.items)
using System;
using DodoPayments.Client;
using DodoPayments.Client.Models.Brands;
DodoPaymentsClient client = new();
BrandListParams parameters = new();
var brands = await client.Brands.List(parameters);
Console.WriteLine(brands);
use dodopayments::Client;
#[tokio::main]
async fn main() -> dodopayments::Result<()> {
let client = Client::from_env()?;
let result = client
.brands()
.list()
.query(serde_json::json!({}))
.await?;
println!("{result:?}");
Ok(())
}