API Documentation

This page shows how to use Biteq.

First things first, let’s add sats to your API wallet. Use this endpoint to create an invoice which you can pay to fund your API wallet for paying others!

post
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
amountstringOptional
Responses
post
/create-invoice
POST /create-invoice HTTP/1.1
Host: biteq.teqquu.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/x-www-form-urlencoded
Accept: */*
Content-Length: 17

"amount='text'"
200

POST /create-invoice

{
  "checkingId": "text",
  "invoice": "text"
}

Now you can copy your invoice, and pay it with your personal wallet! Once you have paid your invoice, you can check with Biteq to see if it reflected. Copy the checkingId you got earlier and make this request!

get
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Query parameters
hashstringOptional
Responses
get
/check-invoice
GET /check-invoice HTTP/1.1
Host: biteq.teqquu.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
200

GET /check-invoice

{
  "paid": "text"
}

Another thing you can do is make an invoice on your personal wallet and pay it with the sats you have in the Biteq API. Let's try that method out!

post
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
invoicestringOptional
Responses
post
/pay-invoice
POST /pay-invoice HTTP/1.1
Host: biteq.teqquu.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/x-www-form-urlencoded
Accept: */*
Content-Length: 18

"invoice='text'"
200

POST /pay-invoice

{
  "payment_hash": "text"
}

Now, let’s verify to see if a lightning address exists! This endpoint will not just return if it’s valid, but basic metadata and more info of the Lightning address, like ZEBEDEE. (thanks to fiatjaf for the endpoint)

get
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Query parameters
addressstringOptional
Responses
get
/check-address
GET /check-address HTTP/1.1
Host: biteq.teqquu.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
200

GET /check-address

{
  "success": "text",
  "data": {
    "status": "text",
    "callback": "text",
    "tag": "text",
    "maxSendable": "text",
    "minSendable": "text",
    "metadata": "text",
    "commentAllowed": "text",
    "domain": "text",
    "username": "text"
  }
}

Next, let's pay to a lightning address! (useful for play-to earn games and/or GPT sites) Let's try this endpoint out!

POST https://biteq.teqquu.com/pay-address

Request Body

Name
Type
Description

amount*

Integer

address*

String

comment

String

Defaults to "Payment from Biteq"

{
    "success_action": {
        "tag": "string",
        "message": "string"
    },
    "payment_hash": "string",
    "checking_id": "string"
}

I should have covered this a while ago, but you can also check your balance before you try paying or stuff to make sure you don’t get any errors. Let’s try that out!

GET https://biteq.teqquu.com/balance

{
  "amount": "integer"
}

There will be more endpoints soon, but remember, Biteq is in beta-testing and we will continue adding endpoints for you.

Last updated