Skip to content

Token Management

POST https://api.echovalue.dev/token

Generates a new API token. No authentication required.

Request body (application/x-www-form-urlencoded):

ParameterValueDescription
tokennewMust be the literal string new

Response: 200 — The new token as plain text.

a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6
Terminal window
curl 'https://api.echovalue.dev/token' \
-d 'token=new'

GET https://api.echovalue.dev/token

Returns remaining credits and token metadata.

Request headers:

HeaderDescription
x-tokenYour API token

Response: 200 — JSON object.

{
"wallet": 12345,
"created": "2023-08-09T15:40:09.77Z",
"hash": "a1b2c3d4e5f6..."
}
FieldTypeDescription
walletintegerRemaining credit balance
createdstring (ISO 8601)Date when the token was created
hashstringSHA256 hash of your token — use this in webhook payloads instead of the raw token
Terminal window
curl 'https://api.echovalue.dev/token' \
-H 'x-token: mytoken'

GET https://api.echovalue.dev/recharge

Returns a Stripe payment link to add credits to your wallet.

Request headers:

HeaderDescription
x-tokenYour API token

Query parameters:

ParameterTypeDescriptionDefault
amountstringNumber of million operations to add. Accepted values: 1 or 3.1

Response: 200 — Stripe payment URL as plain text.

https://buy.stripe.com/<productID>?client_reference_id=mytoken
Terminal window
curl 'https://api.echovalue.dev/recharge?amount=1' \
-H 'x-token: mytoken'

Follow the returned URL to complete the payment.