Wolfram Language

Create a Blockchain API

APIs are driving the interaction between different software and programming languages. The Wolfram Language provides extremely powerful tools to create and deploy APIs. Combined with blockchain and external services functionalities, writing and deploying an API becomes an easy task.

This example demonstrates how to extract information from an Ethereum block using BlockchainBlockData and create an APIFunction to interact with Wolfram Language blockchain functionalities via HTTP requests.

Extract the size of an Ethereum block by retrieving the "ByteCount" property of BlockchainBlockData.

Generalize this computation with an APIFunction that receives as input the block height and returns a textual answer.

Deploy this API to the cloud.

Call this API from any language that supports HTTP requests.

Related Examples

de es fr ja ko pt-br zh