🍀 LuckyBits API Documentation 🍀

Introduction

The LuckyBits API allows developers to fetch real-time block reward, multiplier information, and circulating coin supply for blocks mined on the LuckyBits blockchain. Using this API, you can integrate block data into your applications, build custom tools, or analyze network activity. The API is designed to be lightweight and easy to use.

API Endpoints

GET /reward

Fetch reward and multiplier information for a specific block.

Endpoint: https://api.luckybits.org/reward/?block=BlockNumber

Parameters:

  • block (required) – The block number for which you want to retrieve data.

Example: https://api.luckybits.org/reward/?block=15090

GET /supply

Fetch the current circulating coin supply on the LuckyBits blockchain.

Endpoint: https://api.luckybits.org/supply/

Response: The API will return either a plain number representing the current supply or the string "error" if something goes wrong.

Example: https://api.luckybits.org/supply/

Response Format

The /reward/ endpoint returns data in JSON format. For example:

{
    "status": "ok",
    "block": 15090,
    "base": 10,
    "multiplier": 0.5,
    "final": 5
}
        

The /supply/ endpoint returns a plain number representing the current coin supply or the string "error" if something goes wrong. For example:

5390.000000
        

Error Handling

For the /reward/ endpoint, if an error occurs during a request, the API will return a response in the following format:

{
    "status": "error",
    "message": "Unable to fetch block data."
}
        

For the /supply/ endpoint, if an error occurs, the response will simply be the string "error".