Thefux on Nostr: the api could be easily tested via curl curl -i -X POST \ -H "X-PAYMENT-SATS: <ecash ...
the api could be easily tested via curl
curl -i -X POST
https://ecash.otrta.io/v1/chat/completions \
-H "X-PAYMENT-SATS: <ecash token>" \
-H "Content-Type: application/json" \
-d '{ "model": "meta-llama/llama-4-maverick-17b-128e-instruct-fp8", "messages": [{"role": "user", "content": "Tell me the difference between ecash and regular money."}] }'
The response includes a new header field (X-CHANGE-SATS) that provides an eCash token with change.
x-change-sats: <cashback token>
Published at
2025-05-17 11:29:44Event JSON
{
"id": "6c085b54c897d9ca8b35ffc6bd4522ac73ee317aaf8390358294f1da3346f67f",
"pubkey": "2224da17d76bb87ff4611eef23962da04f154a9bbe641355fcb6448e359d220a",
"created_at": 1747481384,
"kind": 1,
"tags": [
[
"r",
"https://ecash.otrta.io/v1/chat/completions"
]
],
"content": "the api could be easily tested via curl\n\ncurl -i -X POST https://ecash.otrta.io/v1/chat/completions \\\n-H \"X-PAYMENT-SATS: \u003cecash token\u003e\" \\\n-H \"Content-Type: application/json\" \\\n-d '{ \"model\": \"meta-llama/llama-4-maverick-17b-128e-instruct-fp8\", \"messages\": [{\"role\": \"user\", \"content\": \"Tell me the difference between ecash and regular money.\"}] }'\n\nThe response includes a new header field (X-CHANGE-SATS) that provides an eCash token with change.\n\nx-change-sats: \u003ccashback token\u003e\n\n",
"sig": "c8dc7875ea49ed621c6ca7371370e009fa3713d4f07dd209c31f0ee5ba6569cbaf0a240af9cfc4d8d99428e5937ac94d918553ed14d9695f204299a48bc64763"
}