Reading Room
Query read-only functions from smart contracts
Contract Details
Query Results
No queries executed yet. Enter contract details and click "Query Contract" to begin reading.
Writing Desk
Execute state-changing functions on smart contracts
Contract Details
Transaction Status
Connect your wallet and execute a contract call to see transaction status.
Art Gallery
Transform images for blockchain storage and visualization
Image Encoder/Decoder
Convert images to base64 strings for blockchain storage, or decode base64 back to images.
Encode Image to Base64
Drag and drop an image here, or click to select
Supports: JPG, PNG, GIF, WebP (Max: 5MB)
Decode Base64 to Image
About Library of Bitcoin
The Library of Bitcoin is a decentralized Book Publishing and Book Reading Platform built with and on the Stacks (STX) blockchain, powered by Bitcoin.
This application lets users write, edit and publish content like books, articles, news and more, directly onto the Stacks network, and further read content as well.
Publish Your Book on Library of Bitcoin:
SP22KATK6MJF40987KB2KSZQ6E027HQ0CPP73C9Y.LibraryOfBitcoin
Function | Inputs | Returns | Description |
---|---|---|---|
publish-book |
title: (string-utf8 64) description: (string-utf8 256) |
(ok uint) |
Create a book under the caller's principal. |
edit-book-meta |
book-id: uint new-title: (string-utf8 64) new-description: (string-utf8 256) |
(ok true) |
Edit book metadata (only by author). |
add-or-edit-page |
book-id: uint page-number: uint content: (string-utf8 2048) |
(ok true) |
Add or update a page's content (author only). |
set-chapter |
book-id: uint chapter-number: uint start-page: uint |
(ok true) |
Set chapter's starting page (author only). |
get-book-by-id |
book-id: uint | (optional {...}) |
Returns a book's metadata. |
get-page |
book-id: uint page: uint |
(optional string) |
Returns a page's content. |
get-chapter-start-page |
book-id: uint chapter: uint |
(optional uint) |
Returns chapter's start page. |
get-last-book-id |
— | uint |
Returns the last used book ID. |
MiniML Markup Reference
Syntax | Purpose | HTML Output |
---|---|---|
# Text |
Heading | <h2 class="chapter-heading"> |
*text* |
Bold | <strong> |
_text_ |
Italic | <em> |
> text |
Blockquote | <blockquote class="indented"> |
\p |
Paragraph break | </p><p> or <br><br> |
\n |
Line break | <br> |