Plans and fields
Every plan answers the same shape. Each plan has every endpoint of the plans before it, and adds its own. A field your plan does not include is still in the answer, as null, and meta.note names the plan that has it. So code written against the free key keeps working, unchanged, on every plan: upgrade and the nulls fill in.
| Plan | Price | Calls a minute | Calls a day | Endpoints |
|---|---|---|---|---|
| Free key | Free | 10 | 50 | 9 |
| Archive | $19 a month | 60 | 5,000 | 38 |
| Odds | $49 a month | 120 | 20,000 | 43 |
| Live | $149 a month | 300 | 100,000 | 45 |
What a held-back field looks like
{
"data": [{
"id": "ev_q63vfven",
"games": [[21, 17], [21, 19]],
"odds": null
}],
"meta": {
"note": "\"odds\" comes with the Odds plan: https://badmintonapi.com/pricing"
}
}The same call on an Odds key returns the same object with odds filled in. Nothing else changes: not the address, not the parameters, not the other fields. Write your code to treat null as "not available" and it will handle both.
Endpoints above your plan
An endpoint that belongs to a higher plan as a whole (the archive's draws, the odds endpoints, live scores) answers 403 upgrade_required rather than an empty list, so you always know the difference between "nothing there" and "not on your plan". error.plan names the plan.
body = get("/results/yesterday")
if body["meta"].get("note"):
print("More with an upgrade:", body["meta"]["note"])
for m in body["data"]:
price = m["odds"] or "no price on this plan"
print(m["id"], price)const r = await fetch(`${BASE}/tournaments/${id}/draw`, { headers });
if (r.status === 403) {
const { error } = await r.json();
showUpgrade(error.plan); // e.g. "Archive"
} else {
renderDraw((await r.json()).data);
}Changing plan
Your plan belongs to your account, not your key. Upgrade from Pricing and the key you already use sees the new plan at once. Limits change with the plan, and /v1/usage always shows the ones in force. Prices are in US dollars, and card charges appear as DEVELOPERDATA.NET.
Building on the free key first
Because every plan answers the same shape, you can write and test your whole integration on the free key, then upgrade only when you need the archive, prices or live scores. The free key reads yesterday, today and the fixtures ahead, with 50 calls a day, which is enough to build and check your parsing, your error handling and your paging. Everything you write for it carries over unchanged.