Menu
Credits and credit charges
The balance, buying credits, the credit history and statement, the credit charges, the low-balance warning, withdrawals and refunds.
| Operation | Method and path |
|---|---|
| The caller's balances and spend summary | GET /credits/balance |
| The credit charges in force, and the next ones when announced | GET /credits/charges |
| The caller's credit history | GET /credits/ledger |
| The caller's promotional credit | GET /credits/promotional |
| The caller's statement: charges grouped per day and contract | GET /credits/statement |
| The top-up limits, presets and enabled providers | GET /credits/topup |
| Start a credit top-up | POST /credits/topup |
| A top-up order of the caller | GET /credits/topup/{id} |
| The caller's orders, newest first | GET /credits/topups |
| The low-balance warning of the account | GET /credits/warning |
| Change the low-balance warning of the account | PUT /credits/warning |
| The withdrawal function: top-ups you may still withdraw from | GET /credits/withdrawals |
| Withdraw from a top-up | POST /credits/withdrawals |
The caller's balances and spend summary#
GET /credits/balance · operation getBalance
The account's credits: balances per credit type, their total, and spend over the last window_days (the total, the average per day and runway_days, how long the credits last at that pace; null when nothing was spent). Top up with POST /credits/topup. Needs a complete profile (403 profile-incomplete: see GET /auth/profile). Changes nothing. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | credits:read |
| Charged | no |
Answer 200 (Balance): the result
balances, array of objects, requiredcredit_type, string, requiredbalance, string, required — a decimal amount as text
total, string, required — a decimal amount as textspend, object, requiredwindow_days, integer, requiredtotal, string, required — a decimal amount as textavg_per_day, string, required — a decimal amount as textrunway_days, number or null, required
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | ledger-unavailable | ledger-unavailable (the credit account did not answer: try again later) |
Example
curl -X GET 'https://api.weird.ro/credits/balance' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits, weird status):
$ weird credits$ weird status
MCP: weird_status, weird_credits_balance.
The credit charges in force, and the next ones when announced#
GET /credits/charges · operation getCharges
The credit charges in force (version, created_at, effective_at, charges: contract -> rate -> decimal credits); pending, the next version with its credit charges, when one is scheduled; and upcoming, what that scheduled change does: version, effective_at, baseline_version, changed_contracts, increases and decreases (each rate contract, key, sub_key, old, new) and announced (whether the customers it affects were told). Both are absent when nothing is scheduled. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | credits:read |
| Charged | no |
Answer 200 (CreditCharges): the result
version, integer, requiredcreated_at, string, requiredeffective_at, string, requiredcharges, object, required — contract (such asdns.manage,domains.register,recurring.vps-hourly,ipfs.reads) -> rate -> credits as a decimal string; an operation'sx-weird-chargednames the contract and the rate it is charged at- each value: object — rate name (such as
per_request,per_year,per_hour,per_mb_hour) -> credits
- each value: object — rate name (such as
pending, objectversion, integer, requiredeffective_at, string, requiredcharges, object, required — contract (such asdns.manage,domains.register,recurring.vps-hourly,ipfs.reads) -> rate -> credits as a decimal string; an operation'sx-weird-chargednames the contract and the rate it is charged at- each value: object — rate name (such as
per_request,per_year,per_hour,per_mb_hour) -> credits
- each value: object — rate name (such as
upcoming, object — the scheduled change against the credit charges in force; absent when nothing is scheduledversion, integer, requiredeffective_at, string, requiredbaseline_version, integer or nullchanged_contracts, array of strings, requiredincreases, array of objects, requiredcontract, string, requiredkey, string, requiredsub_key, string or nullold, string, required — a decimal amount as textnew, string, required — a decimal amount as text
decreases, array of objects, requiredcontract, string, requiredkey, string, requiredsub_key, string or nullold, string, required — a decimal amount as textnew, string, required — a decimal amount as text
announced, boolean, required — whether the change's announcement was sent to the customers it affects
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | charges-not-published, ledger-unavailable | ledger-unavailable (the credit account did not answer: try again later) or charges-not-published (the credit charges cannot be read now: try again later) |
Example
curl -X GET 'https://api.weird.ro/credits/charges' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits charges, weird domains check, weird status):
$ weird credits charges$ weird domains check <domain>$ weird status
MCP: weird_credits_charges.
The caller's credit history#
GET /credits/ledger · operation listLedger
Every credit entry of the account (purchases, charges, refunds, grants), newest first, cursor paginated. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | credits:read |
| Charged | no |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
cursor | query | string | no | an integer, the next_cursor of a previous page |
limit | query | integer | no | an integer page size |
kind | query | string | no | only entries of that kind |
type | query | string | no | only entries of that credit type |
contract | query | string | no | only charges of that contract |
Answer 200 (CreditEntryPage): the result
entries, array of objects, requiredseq, integer, requiredcredit_type, string, requiredpromotion_kind, string or null — a promotional grant: what kind of promotion, when knownid, string, requiredexpires_at, string or null — a promotional grant: when what is left of it lapses; null when neverpromotion, string — a promotional grant: the id of the promotion it came from (such asdomain-allowance, the included allowance of a domain)invoice_id, string or null — purchaseskind, string, requiredamount, string, required — a decimal amount as textreason, string or null, requiredcreated_at, string, requiredbalance_after, string, required — a decimal amount as texttotal_after, string, required — a decimal amount as text
next_cursor, integer or null, required
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 400 | invalid-params | invalid-params (a non-integer cursor or limit) |
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | ledger-unavailable | ledger-unavailable (the credit account did not answer: try again later) |
Example
curl -X GET 'https://api.weird.ro/credits/ledger' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits history):
$ weird credits historyMCP: weird_credits_history.
The caller's promotional credit#
GET /credits/promotional · operation getPromotionalBalance
The account's promotional credit: the balance, what is available, what is lapsing and every promotional grant that still holds credit (referral rewards among them). This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | credits:read |
| Charged | no |
Answer 200 (PromoBalance): the result
user_id, stringcredit_type, string, required —promobalance, string, required — the promotional balanceavailable, string, required — what can be spent: the balance less what is lapsinglapsing, string, required — past its expiry and about to leave the balancedeficit, string, required — a decimal amount as textgrants, array of objects, required — every grant that still holds credit, in the order it is spent (soonest expiry first)seq, integer, requiredpromotion, string or nullreference, string or nullamount, string, required — a decimal amount as textremaining, string, required — a decimal amount as textexpires_at, string or nullcreated_at, stringlapsing, boolean, required — past its expiry: about to leave the balance
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | ledger-unavailable | ledger-unavailable (the credit account did not answer: try again later) |
Example
curl -X GET 'https://api.weird.ro/credits/promotional' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits promotional):
$ weird credits promotionalMCP: weird_credits_promotional.
The caller's statement: charges grouped per day and contract#
GET /credits/statement · operation statement
The account's credit history as a statement, newest first: the charges grouped per day, contract and resource (charge-group), every other entry (top-ups, refunds, grants) as it is (entry). days narrows the window; pass next_cursor as cursor for the next page. Needs a complete profile (403 profile-incomplete). Changes nothing. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | credits:read |
| Charged | no |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
days | query | integer | no | |
cursor | query | string | no | a YYYY-MM-DD day, the next_cursor of a previous page |
Answer 200 (StatementPage): the result
items, array of objects, requiredseq, integerresource, objecttype, stringid, stringlabel, string or null
credit_type, stringid, stringcount, integerinvoice_id, string or nullkind, stringtype, string, required (one ofcharge-group,entry)contract, stringamount, string — a decimal amount as textreason, string or nullcreated_at, stringbalance_after, string — a decimal amount as textday, stringtotal_after, string — a decimal amount as textlast_at, string
next_cursor, string or null, required
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 400 | invalid-params | invalid-params (a field is wrong: field names it) |
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the scope x-weird-scope names: use a key that holds it) or profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
| 502 | upstream-unavailable | upstream-unavailable (try again later) |
| 503 | ledger-unavailable | ledger-unavailable (the credit account did not answer: try again later) |
Example
curl -X GET 'https://api.weird.ro/credits/statement' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits statement):
$ weird credits statementMCP: weird_credits_statement.
The top-up limits, presets and enabled providers#
GET /credits/topup · operation topupConfig
What a top-up may be: the min and max credits, the presets, the VAT rate, the currency, credit_price (the price of one credit: net, vat, total; null while no price of a credit is set: credits are not on sale and POST /credits/topup is refused with credits-not-on-sale), the payment providers the customer may choose, and the acknowledgement a top-up needs (its version, text and the request fields that must be true; the same as GET /legal/acknowledgements for kind topup, which needs no complete profile); start one with POST /credits/topup. Needs a complete profile (403 profile-incomplete). Changes nothing. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | billing:read |
| Charged | no |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
lang | query | string | no | the language of the texts answered: ro or en (any other value is refused 400 invalid-params, field lang); without it, the Accept-Language header, else the signed-in account's language, else Romanian (one of ro, en) |
Accept-Language | header | string | no | honoured when the request names no lang (body field or query parameter): its first language the platform speaks (ro, en) by the header's own weights; else the signed-in account's language, else Romanian |
Answer 200 (TopupConfig): the result
min, integer, requiredmax, integer, requiredvat_percent, string, required — a decimal amount as textpresets, array of integers, requiredcurrency, string, required (must be"RON")credit_price, one of, required — null while no price of a credit is set: credits are not on sale (POST /credits/topup is refused 503 credits-not-on-sale)- variant 1: object — the price of one credit, what a customer pays per credit bought, set by weird with the VAT rate in force: the only price; everything else is a credit charge, in credits. A purchase is priced on its whole quantity (the credits at
net, rounded to the ban, then the VAT on that, rounded to the ban), so its total may differ by a ban from credits xtotal; a purchase keeps the price it was bought atnet, string, required — before VAT: the price in force, two to four decimalsvat, string, required — the VAT on it, two to four decimalstotal, string, required — VAT included, two to four decimals: what a visitor is shown firstcurrency, string, required (must be"RON")
- variant 2: null
- variant 1: object — the price of one credit, what a customer pays per credit bought, set by weird with the VAT rate in force: the only price; everything else is a credit charge, in credits. A purchase is priced on its whole quantity (the credits at
providers, array of objects, requiredid, string, required (one ofstripe,revolut)label, string, required
acknowledgement, object, requiredkind, string (one oftopup,domain-order,stats-detail)version, string, requiredtext, string, requiredlang, string — the language oftext: the request'slang, else Accept-Language, else the account's language, else Romanian; one version covers both languages (one ofro,en)fields, array of strings, required — the request fields that must be truestanding, boolean — true: an acceptance kept for the account, sent again only whenversionchanges (detailed statistics); false: sent with every orderrequired, string — when the fields must be sent, and what already accepted meansrelies_on, array of objects — the legal documents this acknowledgement relies on:kind(read it withread, GET /legal/documents/{kind}) and, in a live answer, its currentversion(null: not published yet, and the operation that asks for this acknowledgement is refused until it is)kind, stringread, stringversion, string or null
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the route's scope: required, granted); profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
Example
curl -X GET 'https://api.weird.ro/credits/topup' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits topup options, weird credits topup):
$ weird credits topup options$ weird credits topup [credits]
MCP: weird_topup_options.
Start a credit top-up#
POST /credits/topup · operation startTopup
A positive whole number of credits (or its string) within the limits and an enabled provider (default the first), and the two fields of the acknowledgement, both required and both true: immediate_start_requested (you ask us to start providing the services as soon as the payment arrives, within the 14-day withdrawal period) and withdrawal_terms_acknowledged (you confirm the text GET /legal/acknowledgements returns for kind topup, also under acknowledgement.text of GET /credits/topup and in this operation's x-weird-acknowledgement: withdrawing refunds only the unused part of the top-up, and the right is lost for a service fully performed). acknowledgement_version may name the version you showed; a stale one is refused 409 acknowledgement-outdated with the current version and text. The text, its version and the time are recorded with the order and mailed in the order confirmation. Answers the quote and the checkout URL: the credits at the price of one credit in force (credit_price of GET /credits/topup), rounded to the ban, and the VAT on that net; the order records that price and VAT rate, and its invoice and any refund of it use them, whatever the price is later. Refused 503 credits-not-on-sale while no price of a credit is set (nothing is ordered). Nothing is charged until the checkout is paid; an unpaid order lapses. Withdraw from a paid top-up within 14 days with POST /credits/withdrawals.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | billing:write |
| Strong authentication | a session needs an authenticator enrolled and a recent proof of it (a step-up in the last 15 minutes, or totp_code / backup_code in the body); an API key is not asked — see authentication |
| Charged | no |
Acknowledgement (kind topup, version 2026-11-21): the order carries immediate_start_requested and withdrawal_terms_acknowledged, all true, only after the person has read and accepted these words:
I ask weird to start providing the services immediately, as soon as my payment is received, within the 14-day withdrawal period. I understand that if I withdraw from this top-up I pay for what I used until I told weird I withdraw: only the credits of this top-up I have not used are refunded, at the price I paid including VAT, and that I lose the right of withdrawal for a service once it has been fully performed.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Accept-Language | header | string | no | honoured when the request names no lang (body field or query parameter): its first language the platform speaks (ro, en) by the header's own weights; else the signed-in account's language, else Romanian |
Request body (StartTopup):
credits, one of, required — a positive whole number, or its string- variant 1: integer
- variant 2: string
provider, string (one ofstripe,revolut)immediate_start_requested, boolean, required — required, true: you ask us to start providing the services as soon as the payment arrives, within the 14-day withdrawal period (must betrue)withdrawal_terms_acknowledged, boolean, required — required, true: you confirm the acknowledgement text of GET /credits/topup (acknowledgement.text) (must betrue)acknowledgement_version, string — optional: the version of the text you showed; a stale one is refusedlang, string — optional: the language of the text you showed (recorded with it); else thelangquery parameter, else the Accept-Language header, else the account's language, else Romanian; any other value is refused 400 invalid-params (field lang) (one ofro,en)totp_code, string (password) — a current authenticator code (the second factor) (a secret: shown once, never logged)backup_code, string (password) — an unused backup code, instead of the authenticator code (a secret: shown once, never logged)
Answer 200 (TopupStarted): the result
order_ref, string, requiredtotal, string, required — a decimal amount as textcredit_price, string, required — the net price of one credit this order is bought at (recorded on it)vat, string, required — a decimal amount as textcurrency, string, required (must be"RON")net, string, required — the credits at that price, before VAT, rounded to the bancheckout_url, string, requiredvat_percent, string, required — a decimal amount as textcredits, integer, required
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 400 | invalid-params | invalid-params (amount, provider; field immediate_start_requested or withdrawal_terms_acknowledged) |
| 401 | unauthorized | unauthorized |
| 403 | account-suspended, enrolment-required, insufficient-scope, not-available, profile-incomplete, step-up-required, terms-acceptance-required | insufficient-scope (an API key without the route's scope: required, granted); profile-incomplete (complete the profile first: GET /auth/profile says what is missing) or not-available (we cannot accept this request for these details: write to the abuse contact named in the answer); enrolment-required (a session caller whose account has no authenticator: enrol one first) or step-up-required (a session without a recent step-up: POST /auth/step-up, then retry); account-suspended (the account is restricted while a report about it is reviewed: reading, support tickets and the copy of its data keep working; contact is the address to write to, GET /auth/account/restrictions says more); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 409 | acknowledgement-outdated, conflict | acknowledgement-outdated (the acknowledgement text changed: the current version and text are in the answer), or conflict (another top-up of the account is being started) |
| 422 | invalid-totp | invalid-totp (a wrong or replayed authenticator code) |
| 429 | rate-limited, too-many-open-orders | rate-limited or too-many-open-orders |
| 502 | provider-unavailable | provider-unavailable (the payment provider did not answer: try again) |
| 503 | company-identity-incomplete, credits-not-on-sale, payments-disabled | payments-disabled (payments are switched off now: try again later), credits-not-on-sale (credits are not on sale now: nothing was ordered) or company-identity-incomplete (the company details are not complete: nothing was ordered) |
Example
curl -X POST 'https://api.weird.ro/credits/topup' \
-H "Authorization: Bearer $WEIRD_API_KEY" \
-H "Content-Type: application/json" \
-d '{"credits":1,"immediate_start_requested":true,"withdrawal_terms_acknowledged":true}'With the CLI (weird credits topup):
$ weird credits topup [credits]MCP: weird_topup_start.
A top-up order of the caller#
GET /credits/topup/{id} · operation topupStatus
An open order is checked with its payment provider first, so a payment just made shows at once. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | billing:read |
| Charged | no |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | yes |
Answer 200 (TopupOrder): the result
order_ref, string, requiredtotal, string — a decimal amount as textcredit_price, string or null — the net price of one credit the order was bought at, two to four decimals (recorded on the order; for an older or historical order, its net over its credits): its invoice and any refund use it, never the price in forcecurrency, string, requiredprovider, string, requiredinvoice_id, string or nullstate, string, required (one ofcreated,pending,completed,failed,cancelled)checkout_url, string or null — open orders onlycreated_at, string, requiredvat_percent, string — a decimal amount as textcompleted_at, string or nullcredits, integer, requiredimported, boolean — lists only: a historical order of the previous platform (a read-only record)purpose, string (one oftopup,credit-gift)
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the route's scope: required, granted); profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 404 | not-found | not-found |
| 429 | rate-limited | rate-limited |
Example
curl -X GET 'https://api.weird.ro/credits/topup/{id}' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits topup status, weird credits topup):
$ weird credits topup status <order>$ weird credits topup [credits]
MCP: weird_topups.
The caller's orders, newest first#
GET /credits/topups · operation listTopups
One page of the caller's orders paid through a checkout: top-ups and gifts (purpose topup or credit-gift), in every state, each as GET /credits/topup/{id} shows it plus imported (true for an order of the previous platform: a read-only record). next_cursor names the next page (null on the last). This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | billing:read |
| Charged | no |
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
cursor | query | string | no | the next_cursor of the previous page |
limit | query | integer | no | 1 to 100, default 25 (default 25; 1 to 100) |
purpose | query | string | no | topup or credit-gift; default both |
Answer 200 (TopupOrderList): the result
orders, array of objects, requiredorder_ref, string, requiredtotal, string — a decimal amount as textcredit_price, string or null — the net price of one credit the order was bought at, two to four decimals (recorded on the order; for an older or historical order, its net over its credits): its invoice and any refund use it, never the price in forcecurrency, string, requiredprovider, string, requiredinvoice_id, string or nullstate, string, required (one ofcreated,pending,completed,failed,cancelled)checkout_url, string or null — open orders onlycreated_at, string, requiredvat_percent, string — a decimal amount as textcompleted_at, string or nullcredits, integer, requiredimported, boolean — lists only: a historical order of the previous platform (a read-only record)purpose, string (one oftopup,credit-gift)
next_cursor, string or null, required
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 400 | invalid-params | invalid-params (field cursor, limit or purpose) |
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, profile-incomplete, terms-acceptance-required | insufficient-scope (an API key without the route's scope: required, granted); profile-incomplete (complete the profile first: GET /auth/profile says what is missing); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
Example
curl -X GET 'https://api.weird.ro/credits/topups' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits topups):
$ weird credits topupsMCP: weird_topups.
The low-balance warning of the account#
GET /credits/warning · operation getCreditWarning
When the account is warned that its credits will run out: enabled, runway_hours (warned once when the credits left last fewer hours than this at the projected hourly spend; default 72), min_balance (also warned once when the balance falls under this amount; null: no amount), critical_hours (a second, stronger warning when fewer than this many hours are left: 24). status is what the last check saw: level (none, low: the first warning was sent, critical: the second was sent), balance, burn_per_hour (what the account is projected to be charged per hour), estimate (complete, or partial when a product did not answer and its charges of the last 3 hours stood in for it), breakdown (one entry per product: product, per_hour, basis and, when projected, resources: servers by tier, volumes and snapshots by GB, stored content by MB times copies, active DNS zones by their records, tunnels and p2p apps, each at the credit charges in effect, whatever is on hold, suspended or not billed left out; usage, what is billed by use such as traffic and per-request calls, is the average of its charges over the last 3 hours), hours_left (null when nothing is billed), checked_at and notified_at. An account is checked about every hour. A warning is not repeated until the balance has recovered above the threshold. Change it with PUT /credits/warning. Changes nothing. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | notifications:read |
| Charged | no |
Answer 200 (CreditWarningResult): the result
warning, object, requiredenabled, boolean, required — whether the account is warnedrunway_hours, integer, required — warned once when the credits left last fewer hours than this at the present hourly rate (24 to 720)min_balance, string or null, required — also warned once when the balance falls under this amount (a decimal string); null: no amountcritical_hours, integer, required — the second, stronger warning is sent under this many hours leftstatus, object, required — what the last check saw: before the first checklevelisnoneand every other field nulllevel, string, required — none: no warning in progress; low: the first warning was sent; critical: the second was sent (one ofnone,low,critical)balance, string or null, required — the balance seen, two decimals; null when it was not neededburn_per_hour, string or null, required — the projected credits per hour: the sum ofbreakdownestimate, string or null, required — partial: a product did not answer and its recent charges stood in for it (one ofcomplete,partial,null)breakdown, array of objects, required — how burn_per_hour is made up, one entry per productproduct, string, required — vps: servers, volumes and snapshots; storage: stored content; dns: active zones; tunnels; p2p: apps; usage: what is billed by use (traffic, per-request calls) (one ofvps,storage,dns,tunnels,p2p,usage)per_hour, string, required — credits per hourbasis, string, required — projected: from what the account holds now at the credit charges in effect; recent-average: the charges of the last 3 hours, averaged (always for usage; for a product whose service did not answer) (one ofprojected,recent-average)resources, integer — the billed resources counted, on a projected entry
hours_left, number or null, required — the estimated hours the credits last; null when nothing is billed by the hourchecked_at, string or null, requirednotified_at, string or null, required — when the last warning was sent
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, terms-acceptance-required | insufficient-scope (an API key without the route's scope: required, granted); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
Example
curl -X GET 'https://api.weird.ro/credits/warning' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits warning, weird credits warning show):
$ weird credits warning$ weird credits warning show
MCP: weird_credit_warning.
Change the low-balance warning of the account#
PUT /credits/warning · operation setCreditWarning
Any of enabled (true or false), runway_hours (a whole number of hours from 24 to 720) and min_balance (a positive amount of at most 1000000 as a decimal string with at most two decimals, or null to remove it); what is left out is kept. The new settings apply at the next check, within minutes: a lower threshold the account is already above ends a warning in progress, a higher one may send one. The warnings are emailed and shown among the notifications; they cannot be turned off in the email choices, only here. Answers the warning as GET /credits/warning does. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | notifications:write |
| Charged | no |
Request body (SetCreditWarning):
enabled, booleanrunway_hours, integer (24 to 720)min_balance, string or null — a positive amount of at most 1000000, at most two decimals; null removes it
Answer 200 (CreditWarningResult): the result
warning, object, requiredenabled, boolean, required — whether the account is warnedrunway_hours, integer, required — warned once when the credits left last fewer hours than this at the present hourly rate (24 to 720)min_balance, string or null, required — also warned once when the balance falls under this amount (a decimal string); null: no amountcritical_hours, integer, required — the second, stronger warning is sent under this many hours leftstatus, object, required — what the last check saw: before the first checklevelisnoneand every other field nulllevel, string, required — none: no warning in progress; low: the first warning was sent; critical: the second was sent (one ofnone,low,critical)balance, string or null, required — the balance seen, two decimals; null when it was not neededburn_per_hour, string or null, required — the projected credits per hour: the sum ofbreakdownestimate, string or null, required — partial: a product did not answer and its recent charges stood in for it (one ofcomplete,partial,null)breakdown, array of objects, required — how burn_per_hour is made up, one entry per productproduct, string, required — vps: servers, volumes and snapshots; storage: stored content; dns: active zones; tunnels; p2p: apps; usage: what is billed by use (traffic, per-request calls) (one ofvps,storage,dns,tunnels,p2p,usage)per_hour, string, required — credits per hourbasis, string, required — projected: from what the account holds now at the credit charges in effect; recent-average: the charges of the last 3 hours, averaged (always for usage; for a product whose service did not answer) (one ofprojected,recent-average)resources, integer — the billed resources counted, on a projected entry
hours_left, number or null, required — the estimated hours the credits last; null when nothing is billed by the hourchecked_at, string or null, requirednotified_at, string or null, required — when the last warning was sent
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 400 | invalid-params | invalid-params (field enabled, runway_hours or min_balance) |
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, terms-acceptance-required | insufficient-scope (an API key without the route's scope: required, granted); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
Example
curl -X PUT 'https://api.weird.ro/credits/warning' \
-H "Authorization: Bearer $WEIRD_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'With the CLI (weird credits warning set):
$ weird credits warning setMCP: weird_credit_warning_set.
The withdrawal function: top-ups you may still withdraw from#
GET /credits/withdrawals · operation listWithdrawals
Every top-up still inside its withdrawal period (withdrawal_until: 14 days after it was paid, or 12 months more when no acknowledgement was recorded with it, extended_period true), newest first, with what withdrawing from it now would refund: refund_credits and refund_amount (RON, VAT included), to the payment it was made with. The unused part of a top-up is refunded: credit that cannot be refunded (promotional, carried over, received as a gift) is used first, then purchased credit, oldest top-up first (rule). withdrawal_open false: already withdrawn from, disputed, or nothing to refund. refunds lists every refund of the account (withdrawals, the closing refund, goodwill refunds) and where it stands. Withdraw with POST /credits/withdrawals. Changes nothing. This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | withdrawals:read |
| Charged | no |
Answer 200 (WithdrawalList): the result
withdrawable, array of objects, requiredorder_ref, string, requiredtotal, string, required — a decimal amount as textwithdrawal_until, string or null, requiredextended_period, boolean — no acknowledgement was recorded with the order: the period is 12 months longercurrency, string, requiredrefund_pay_by, string or null — the latest instant a withdrawal made now would be refunded by (14 days from now); null whilewithdrawal_openis falsenot_refundable_reason, string or nullpaid_at, string or null, requiredrefund_amount, string, required — RON, VAT includedwithdrawal_id, string or nullprovider, string or nullwithdrawal_open, boolean, required — you may withdraw from it nowkind, string, required (one oftopup,gift-returned)unused_credits, string, required — a decimal amount as textrefundable, boolean, required — false: the payment is disputedcredits, string, required — a decimal amount as textrefund_credits, string, required — a decimal amount as text
refunds, array of objects, requiredorder_ref, string, requiredneeds_bank_details, booleancurrency, string, requiredpay_by, string or null — the latest instant the refund is paid (for a withdrawal, 14 days from the request); null once it is finalid, string, requiredrejection, string or null — why the refund was not made, in plain words, whenstateisrejectedrequested_at, stringkind, string, required (one ofwithdrawal,closing,goodwill)amount, string, required — RON, VAT includedstate, string, required —awaiting-approval: the credit is set aside and the refund is being reviewed by our team;rejected: not refunded (seerejection), the credit is back in your balance (one ofawaiting-approval,removing-credit,pending-provider,needs-bank-details,done,void,rejected)ticket_id, string or null — the support ticket asking for your bank detailsunder_review, boolean — true while the refund is being reviewed by our teampaid_via, string or null — provider or bank, once paidcompleted_at, string or nullcredits, string, required — a decimal amount as text
rule, string, required
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 401 | unauthorized | unauthorized |
| 403 | insufficient-scope, terms-acceptance-required | insufficient-scope (an API key without the route's scope: required, granted); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 429 | rate-limited | rate-limited |
| 503 | unavailable | unavailable (your credits cannot be read right now) |
Example
curl -X GET 'https://api.weird.ro/credits/withdrawals' \
-H "Authorization: Bearer $WEIRD_API_KEY"With the CLI (weird credits withdrawals, weird credits withdraw):
$ weird credits withdrawals$ weird credits withdraw <order>
MCP: weird_withdrawals.
Withdraw from a top-up#
POST /credits/withdrawals · operation withdraw
Withdraws from the contract of the top-up order_ref (as GET /credits/withdrawals lists it) within its withdrawal period, without giving a reason. The unused credit of that top-up is set aside from your balance at once (you can no longer spend it) and the refund is reviewed by our team; its price, VAT included, is refunded to the payment the top-up was made with by pay_by at the latest (14 days from your request); what you used before is not refunded. A payment that can no longer be refunded that way is refunded by bank transfer: we ask for your IBAN in a support ticket. You are emailed a confirmation of receipt naming that date. Answers 202 with the withdrawal (state awaiting-approval and under_review true while it is reviewed, then removing-credit, pending-provider once the credit is removed and the refund owed, needs-bank-details, done; void when the credit was used before it could be set aside; rejected, with rejection saying why in plain words, when it is not refunded: the credit is then back in your balance and you are emailed the reason). A repeat for the same top-up answers the withdrawal already made (200): it is never made twice; after a rejected one you may withdraw again within the period. Needs a current authenticator code (totp_code) or an unused backup code (backup_code) IN THIS REQUEST, from a session and an API key alike: a recent step-up is not enough (403 step-up-required without one; 403 enrolment-required while the account has no authenticator; 422 invalid-totp for a wrong or used code, and too many wrong codes are 429 rate-limited for a while). This call is not charged.
| Credential | an API key holding the permission below, or a session (x-weird-auth: key) |
| Permission | withdrawals:write |
| Strong authentication | the body itself must carry totp_code or backup_code, from a session and an API key alike — see authentication |
| Charged | no |
| Retry safety | a repeat is refused or changes nothing: a top-up is withdrawn from once: a repeat answers the withdrawal already made (200) and refunds nothing twice |
Request body (Withdraw):
order_ref, string, required — the top-up to withdraw fromtotp_code, string (password) — a current authenticator code (the second factor) (a secret: shown once, never logged)backup_code, string (password) — an unused backup code, instead of the authenticator code (a secret: shown once, never logged)
Answer 200 (WithdrawalResult): a withdrawal from this top-up was made already: the same answer, the refund as it stands now (nothing is refunded twice)
withdrawal, object, requiredorder_ref, string, requiredneeds_bank_details, booleancurrency, string, requiredpay_by, string or null — the latest instant the refund is paid (for a withdrawal, 14 days from the request); null once it is finalid, string, requiredrejection, string or null — why the refund was not made, in plain words, whenstateisrejectedrequested_at, stringkind, string, required (one ofwithdrawal,closing,goodwill)amount, string, required — RON, VAT includedstate, string, required —awaiting-approval: the credit is set aside and the refund is being reviewed by our team;rejected: not refunded (seerejection), the credit is back in your balance (one ofawaiting-approval,removing-credit,pending-provider,needs-bank-details,done,void,rejected)ticket_id, string or null — the support ticket asking for your bank detailsunder_review, boolean — true while the refund is being reviewed by our teampaid_via, string or null — provider or bank, once paidcompleted_at, string or nullcredits, string, required — a decimal amount as text
Answer 202 (WithdrawalResult): the result
withdrawal, object, requiredorder_ref, string, requiredneeds_bank_details, booleancurrency, string, requiredpay_by, string or null — the latest instant the refund is paid (for a withdrawal, 14 days from the request); null once it is finalid, string, requiredrejection, string or null — why the refund was not made, in plain words, whenstateisrejectedrequested_at, stringkind, string, required (one ofwithdrawal,closing,goodwill)amount, string, required — RON, VAT includedstate, string, required —awaiting-approval: the credit is set aside and the refund is being reviewed by our team;rejected: not refunded (seerejection), the credit is back in your balance (one ofawaiting-approval,removing-credit,pending-provider,needs-bank-details,done,void,rejected)ticket_id, string or null — the support ticket asking for your bank detailsunder_review, boolean — true while the refund is being reviewed by our teampaid_via, string or null — provider or bank, once paidcompleted_at, string or nullcredits, string, required — a decimal amount as text
Refusals ({"error": {"code", "message"}}; see errors):
| Status | Codes | When |
|---|---|---|
| 400 | invalid-params | invalid-params (field order_ref) |
| 401 | unauthorized | unauthorized |
| 403 | enrolment-required, insufficient-scope, step-up-required, terms-acceptance-required | insufficient-scope (an API key without the route's scope: required, granted); step-up-required (no code in this request) or enrolment-required (no authenticator enrolled); enrolment-required (a session caller whose account has no authenticator: enrol one first) or step-up-required (a session without a recent step-up: POST /auth/step-up, then retry); terms-acceptance-required (the current terms of service or privacy notice are not accepted yet: required lists them; read them with GET /legal/documents and accept with POST /auth/legal/accept) |
| 404 | not-found | not-found (no such paid top-up of yours) |
| 409 | conflict, nothing-to-refund, payment-disputed, withdrawal-period-over | withdrawal-period-over, payment-disputed (the payment is disputed at the payment provider), nothing-to-refund (every credit of it was used) or conflict (another refund of the account is being prepared: retry) |
| 422 | invalid-totp | invalid-totp (a wrong or replayed authenticator code) |
| 429 | rate-limited | rate-limited |
| 503 | unavailable | unavailable (your credits cannot be read right now: nothing was done) |
Example
curl -X POST 'https://api.weird.ro/credits/withdrawals' \
-H "Authorization: Bearer $WEIRD_API_KEY" \
-H "Content-Type: application/json" \
-d '{"order_ref":"<order_ref>"}'With the CLI (weird credits withdraw):
$ weird credits withdraw <order>MCP: weird_withdraw.
This page is generated from the API's public document; it changes when the document does.