Your developer gets Bayou’s API integrated in minutes for many utilities. Your customers get their utility account connected in one click.
Get started Contact Bayou# Manage your API keys at https://bayou.energy/dashboard/keys
# API reference: https://docs.bayou.energy/v2.0/reference/authentication
bayou_api_key = "live_1_13a720.....3cc858f1c673c48d"
# Create a new customer.
# API reference: https://docs.bayou.energy/v2.0/reference/post_customers
customer = requests.post(f"https://bayou.energy/api/v2/customers", json={
# Speculoos is Bayou's fake utility for testing
"utility": "speculoos_power",
# https://docs.bayou.energy/v2.0/reference/utility-support
}, auth=(bayou_api_key, '')).json()
# Manage your API keys at https://bayou.energy/dashboard/keys
# API reference: https://docs.bayou.energy/v2.0/reference/authentication
bayou_api_key = "live_1_13a720.....3cc858f1c673c48d"
# Create a new customer.
# API reference: https://docs.bayou.energy/v2.0/reference/post_customers
uri = URI("https://bayou.energy/api/v2/customers")
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri.path, 'Content-Type' => 'application/json')
request.basic_auth(bayou_api_key, '')
# Speculoos is Bayou's fake utility for testing
request.body = { "utility" => "speculoos_power" }.to_json
# https://docs.bayou.energy/v2.0/reference/utility-support
customer = JSON.parse(http.request(request).body)
// Manage your API keys at https://bayou.energy/dashboard/keys
// API reference: https://docs.bayou.energy/v2.0/reference/authentication
const bayouApiKey = "live_1_13a720.....3cc858f1c673c48d";
// Create a new customer. API reference: https://docs.bayou.energy/v2.0/reference/post_customers
const response = await fetch("https://bayou.energy/api/v2/customers", {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': `Basic ${btoa(`${bayou_api_key}:`)}`,
},
body: JSON.stringify({
// Speculoos is Bayou's fake utility for testing
utility: "speculoos_power"
// https://docs.bayou.energy/v2.0/reference/utility-support
})
});
const customer = await response.json();
// Manage your API keys at https://bayou.energy/dashboard/keys
// API reference: https://docs.bayou.energy/v2.0/reference/authentication
string bayouApiKey = "live_1_13a720.....3cc858f1c673c48d";
// Create a new customer. API reference: https://docs.bayou.energy/v2.0/reference/post_customers
using (HttpClient client = new HttpClient())
{
client.DefaultRequestHeaders.Add("Content-Type", "application/json");
client.DefaultRequestHeaders.Add("Authorization", "Basic " + Convert.ToBase64String(Encoding.UTF8.GetBytes(bayouApiKey + ":")));
// Speculoos is Bayou's fake utility for testing
string jsonInputString = "{"utility":"speculoos_power"}";
// https://docs.bayou.energy/v2.0/reference/utility-support
HttpResponseMessage response = await client.PostAsync("https://bayou.energy/api/v2/customers", new StringContent(jsonInputString, Encoding.UTF8, "application/json"));
string responseContent = await response.Content.ReadAsStringAsync();
dynamic customer = Newtonsoft.Json.JsonConvert.DeserializeObject(responseContent);
}
# onboarding_link is an attribute of Bayou's Customer model that provides a URL for customers to connect their utility account
print(f"Fill the customer credentials using the following link: {customer['onboarding_link']}")
# You can use the following credentials to load test data:
# Email: iamvalid@bayou.energy
# Password: validpassword
# onboarding_link is an attribute of Bayou's Customer model that provides a URL for customers to connect their utility account
puts "Fill the customer credentials using the following link: #{customer['onboarding_link']}"
# You can use the following credentials to load test data:
# Email: iamvalid@bayou.energy
# Password: validpassword
// onboarding_link is an attribute of Bayou's Customer model that provides a URL for customers to connect their utility account
console.log(`Fill the customer credentials using the following link: ${customer.onboarding_link}`);
// You can use the following credentials to load test data:
// Email: iamvalid@bayou.energy
// Password: validpassword
// onboarding_link is an attribute of Bayou's Customer model that provides a URL for customers to connect their utility account
Console.WriteLine($"Fill the customer credentials using the following link: {customer.onboarding_link}");
// You can use the following credentials to load test data:
// Email: iamvalid@bayou.energy
// Password: validpassword
# Get all bills for this specific customer.
# API reference: https://docs.bayou.energy/v2.0/reference/get_customers-customer-id-bills
bills = requests.get(f"https://bayou.energy/api/v2/customers/{customer['id']}/bills", auth=(bayou_api_key, '')).json()
# Get all intervals for this specific customer.
# API reference: https://docs.bayou.energy/v2.0/reference/get_customers-customer-id-intervals
intervals = requests.get(f"https://bayou.energy/api/v2/customers/{customer['id']}/intervals", auth=(bayou_api_key, '')).json()
# Get all bills for this specific customer.
bills_uri = URI("https://bayou.energy/api/v2/customers/#{customer_id}/bills")
bills_request = Net::HTTP::Get.new(bills_uri)
bills_request.basic_auth(bayou_api_key, '')
bills_response = Net::HTTP.start(bills_uri.hostname, bills_uri.port, use_ssl: true) do |http|
http.request(bills_request)
end
bills = JSON.parse(bills_response.body)
# Get all intervals for this specific customer.
intervals_uri = URI("https://bayou.energy/api/v2/customers/#{customer_id}/intervals")
intervals_request = Net::HTTP::Get.new(intervals_uri)
intervals_request.basic_auth(bayou_api_key, '')
intervals_response = Net::HTTP.start(intervals_uri.hostname, intervals_uri.port, use_ssl: true) do |http|
http.request(intervals_request)
end
intervals = JSON.parse(intervals_response.body)
// Get all bills for this specific customer.
// API reference: https://docs.bayou.energy/v2.0/reference/get_customers-customer-id-bills
const billsResponse = await fetch(`https://bayou.energy/api/v2/customers/${customer.id}/bills`, {
method: 'GET',
headers: {
'Authorization': `Basic ${btoa(`${bayou_api_key}:`)}`,
'Content-Type': 'application/json'
}
})
const bills = billsResponse.json();
// Get all intervals for this specific customer.
// API reference: https://docs.bayou.energy/v2.0/reference/get_customers-customer-id-intervals
const intervalsResponse = await fetch(`https://bayou.energy/api/v2/customers/${customer.id}/intervals`, {
method: 'GET',
headers: {
'Authorization': `Basic ${btoa(`${bayou_api_key}:`)}`,
'Content-Type': 'application/json'
}
})
const intervals = intervalsResponse.json();
using (HttpClient client = new HttpClient())
{
client.DefaultRequestHeaders.Add("Authorization", "Basic " + Convert.ToBase64String(Encoding.UTF8.GetBytes(bayouApiKey + ":")));
var bills = await client.GetStringAsync($"https://bayou.energy/api/v2/customers/{customer.id}/bills");
var intervals = await client.GetStringAsync($"https://bayou.energy/api/v2/customers/{customer.id}/intervals");
}
You get data instantly from 0 utilities today and from 0% of US utility customers by December 2024.
Bayou can add new utilities within one week.
Nathan Eidelson
CTO at Wattbot
“Our product uncovers insights hidden in the complex web of a consumer’s energy usage and billing data. This would not be possible without Bayou.”
Ross Gruber
CTO at Glow Energy
“We enable multi-family building owners to profitably provide solar energy to their tenants. Glow uses Bayou to access rich data streams of resident utility data, providing a great end-user experience while allowing us maximum flexibility in our billing operations.”
Maddi Eckert
Operations at Elephant Energy
“Our platform makes it easy to upgrade and manage a climate-friendly home. When we needed a partner to fetch customers’ utility bills, Bayou was the obvious choice - it’s been incredibly easy to set up and it delivers the one-click utility account connection experience our customers expect.”
Instant access with pay-as-you-go pricing—no setup, sales calls, or hidden fees
Includes customer bill, interval and account data with unlimited API calls
Get 12 months of historical data or 12 months of ongoing data access for $24
Read the docs, or create an account and get utility data instantly. You can also contact us to discuss your deployment.
Get started Contact Bayou