MCPcopy Create free account

hub / github.com/AbdelStark/bitcoin-mcp / functions

Functions47 in github.com/AbdelStark/bitcoin-mcp

↓ 4 callersMethodshutdown
(code?: number)
src/types.ts:114
↓ 2 callersFunctionmain
()
src/index.ts:15
↓ 1 callersMethoddecodeInvoice
* ⚡ Decode Lightning Invoice * ======================= * Decodes a BOLT11 invoice and presents human-readable information * * @param bolt1
src/services/bitcoin.ts:278
↓ 1 callersMethoddecodeTx
* 📜 Decode Raw Transaction * ======================= * Parses a raw transaction hex and returns human-readable information * * Returns:
src/services/bitcoin.ts:137
↓ 1 callersMethodgenerateKey
* 🔑 Generate a New Bitcoin Key Pair * ================================ * Creates a fresh Bitcoin key pair with: * - Private key (WIF format)
src/services/bitcoin.ts:79
↓ 1 callersMethodgetLatestBlock
* ⛓️ Get Latest Block Information * ============================ * Fetches information about the most recent block * from the Bitcoin network
src/services/bitcoin.ts:173
↓ 1 callersMethodgetTransaction
* 🔍 Get Transaction Details * ======================= * Fetches detailed information about a specific transaction * * @param txid - Transa
src/services/bitcoin.ts:212
↓ 1 callersFunctionhandleDecodeInvoice
( bitcoinService: BitcoinService, args: unknown )
src/server/tools.ts:199
↓ 1 callersFunctionhandleDecodeTx
( bitcoinService: BitcoinService, args: unknown )
src/server/tools.ts:107
↓ 1 callersFunctionhandleGenerateKey
(bitcoinService: BitcoinService)
src/server/tools.ts:52
↓ 1 callersFunctionhandleGetLatestBlock
(bitcoinService: BitcoinService)
src/server/tools.ts:142
↓ 1 callersFunctionhandleGetTransaction
( bitcoinService: BitcoinService, args: unknown )
src/server/tools.ts:163
↓ 1 callersFunctionhandlePayInvoice
( bitcoinService: BitcoinService, args: unknown )
src/server/tools.ts:242
↓ 1 callersFunctionhandleValidateAddress
( bitcoinService: BitcoinService, args: unknown )
src/server/tools.ts:73
↓ 1 callersMethodhumanFriendlyInvoice
(decoded: DecodedInvoice)
src/clients/lnbits_clients.ts:58
↓ 1 callersMethodpayInvoice
* ⚡ Pay Lightning Invoice * ==================== * Pays a BOLT11 invoice using LNBits * * @param bolt11 - BOLT11 format Lightning invoice
src/services/bitcoin.ts:306
↓ 1 callersMethodsendPayment
(bolt11: string)
src/clients/lnbits_clients.ts:36
↓ 1 callersMethodsetupExpressRoutes
* 🛣️ Configure Express Routes * ======================== * Sets up the SSE endpoint and message handling route
src/server/sse.ts:64
↓ 1 callersMethodsetupStdioRedirect
* 🔄 Configure STDIO Redirection * ========================== * Sets up stdout redirection to ensure clean separation of * JSON-RPC messages a
src/server/stdio.ts:53
↓ 1 callersMethodstart
()
src/types.ts:113
↓ 1 callersMethodtoHumanFriendlyInvoice
(bolt11Invoice: string)
src/clients/lnbits_clients.ts:75
↓ 1 callersMethodtryGetAddress
* Helper function to extract Bitcoin address from output script
src/services/bitcoin.ts:262
↓ 1 callersMethodvalidateAddress
* 🔍 Validate Bitcoin Address * ========================= * Checks if a given string is a valid Bitcoin address * for the current network (mai
src/services/bitcoin.ts:114
FunctionFeature
({ title, image, description }: FeatureItem)
docs/src/components/HomepageFeatures/index.tsx:45
FunctionHome
()
docs/src/pages/index.tsx:32
FunctionHomepageFeatures
()
docs/src/components/HomepageFeatures/index.tsx:69
FunctionHomepageHeader
()
docs/src/pages/index.tsx:10
Functionconstructor
* Creates a new MCP server instance * * @param config - Server configuration including network and API settings * @throws Error if configurat
src/server/base.ts:64
Methodconstructor
( message: string, public readonly code: BitcoinErrorCode, public readonly status = 500 )
src/types.ts:92
Methodconstructor
( message: string, public readonly code: LightningErrorCode | string, public readonly status?: num
src/types.ts:151
Methodconstructor
* Creates a new Bitcoin service instance * * @param config - Configuration including network (mainnet/testnet) and API base URL
src/services/bitcoin.ts:49
Methodconstructor
* Creates a new STDIO-based Bitcoin MCP server * * @param config - Bitcoin network configuration
src/server/stdio.ts:41
Methodconstructor
* Creates a new SSE-based Bitcoin MCP server * * @param config - Bitcoin network configuration * @param serverConfig - SSE server settings in
src/server/sse.ts:52
Methodconstructor
(baseUrl: string, adminKey: string, readKey: string)
src/clients/lnbits_clients.ts:15
MethodcustomWrite
( str: string | Uint8Array, encodingOrCb?: BufferEncoding | ((err?: Error) => void), cb?: (e
src/server/stdio.ts:55
MethoddisplayInvoiceDetails
(bolt11Invoice: string)
src/clients/lnbits_clients.ts:80
FunctionformatResponse
* 📝 Format Response for MCP * ======================= * Converts any response data into the MCP text content format
src/server/base.ts:236
MethodgetWalletInfo
()
src/clients/lnbits_clients.ts:21
FunctionhandleError
* ⚠️ Handle Errors * ============== * Formats errors into user-friendly MCP responses
src/server/base.ts:252
Functionrng
(size: number)
src/services/bitcoin.ts:37
FunctionsetupHandlers
* 🎮 Setup Server Event Handlers * =========================== * Configures error handling and graceful shutdown * for the server instance
src/server/base.ts:83
FunctionsetupToolHandlers
* 🛠️ Register Available Tools * ======================== * Sets up handlers for all supported Bitcoin operations: * - Key Generation * - A
src/server/base.ts:113
Functionshutdown
* 🔄 Graceful Shutdown * ================= * Cleanly shuts down the server and exits
src/server/base.ts:262
Methodshutdown
* 🔄 Graceful Shutdown * ================= * Restores original stdout and cleanly shuts down
src/server/stdio.ts:99
Methodshutdown
* 🔄 Graceful Shutdown * ================= * Cleanly closes SSE connections and shuts down
src/server/sse.ts:97
Methodstart
* 🚀 Start STDIO Server * ================= * Initializes the STDIO transport and begins * listening for JSON-RPC messages
src/server/stdio.ts:88
Methodstart
* 🚀 Start SSE Server * ================ * Begins listening for SSE connections and messages
src/server/sse.ts:86