Skip to content

Commit 7869bd2

Browse files
Add Blast API documentation structure and initial endpoints (#68)
* Add Blast API documentation structure and initial endpoints - Set up the documentation structure for Blast API\n- Add documentation for Aptos REST endpoints\n- Added Superseed endpoints * Add Blast API documentation for Bitcoin chain * Add Quickstart and FAQ docs for Blast chains * Update Bitcoin examples with valid request/response * Update Blast introduction, overview and FAQ * Add Blast API documentation for Sui chain * Add Blast product pages * Remove extra content from product pages * Remove example and change Blast position
1 parent fb28282 commit 7869bd2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+31234
-0
lines changed

build/api-specs/alchemy/rest/aptos.json

Lines changed: 2754 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/api-specs/chains/bitcoin.json

Lines changed: 2816 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/api-specs/chains/sui.json

Lines changed: 6119 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/api-specs/chains/superseed.json

Lines changed: 8141 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
---
2+
title: "Aptos API FAQ"
3+
description: "Frequently asked questions about the Aptos API"
4+
url: "https://docs.alchemy.com/reference/aptos-api-faq"
5+
slug: "reference/aptos-api-faq"
6+
---
7+
8+
> 💡 Available only with [Blast](../reference/introduction-to-blast#how-to-get-blast) access
9+
10+
## What is Aptos?
11+
12+
Aptos is a Layer 1 blockchain built for scalability, safety, and upgradeability. It uses the Move programming language and the AptosBFT consensus protocol to enable high-throughput and low-latency transactions while maintaining strong security guarantees.
13+
14+
## What is the Aptos API?
15+
16+
The Aptos API allows developers to interact with the Aptos blockchain via a set of RESTful endpoints. It enables actions such as querying accounts and transactions, submitting new transactions, interacting with smart contracts, and accessing on-chain resources.
17+
18+
## How can I get access to the Aptos API?
19+
20+
This chain is available only with [Blast](/node/blast-api/blast-quickstart) access.
21+
22+
## How can I get started using the Aptos API?
23+
24+
Take a look at our [Aptos API Quickstart](/reference/aptos-api-quickstart) guide.
25+
26+
## Does Aptos support smart contracts?
27+
28+
Yes. Aptos supports smart contracts written in Move, a secure and expressive programming language developed specifically for the blockchain. You can deploy, call, and interact with smart contracts via the API.
29+
30+
## What API standard does Aptos use?
31+
32+
The Aptos API follows REST principles and communicates via standard HTTP requests and JSON responses. Endpoints are organized by functionality — accounts, blocks, transactions, events, etc.
33+
34+
## What is an Aptos API key?
35+
36+
If you're using a blockchain infrastructure provider like Alchemy, an API key allows you to send authenticated requests to the Aptos network. This lets you read data from the chain and submit transactions securely.
37+
38+
## Which libraries can I use with the Aptos API?
39+
40+
You can use any HTTP client that supports standard REST calls. Popular choices include:
41+
42+
* JavaScript: `axios`, `fetch`
43+
* Python: `requests`
44+
* Curl (for CLI or scripting)
45+
* Community SDKs like `aptos-sdk`, `aptos-client` for Python and TypeScript
46+
47+
## What programming languages are compatible with the API?
48+
49+
The API works with any language that supports HTTP — such as JavaScript/TypeScript, Python, Go, Rust, and Java. You can integrate it into backend services, CLI tools, and dApps.
50+
51+
## What is used for fees in Aptos?
52+
53+
Aptos uses its native token, APT, to pay transaction fees. The API provides endpoints to estimate gas usage and fee costs before submitting a transaction.
54+
55+
## What methods does Alchemy support for the Aptos API?
56+
57+
You can find the complete list of supported endpoints on the [Aptos API Endpoints](/node/aptos/aptos-api-endpoints) page.
58+
59+
## My question isn't listed here — where can I get help?
60+
61+
Join the [Alchemy Discord](https://alchemy.com/discord) to ask questions, get support, and chat with the developer community and the Alchemy team.
Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
---
2+
title: "Aptos API Quickstart"
3+
description: "Get started building on Aptos and using REST"
4+
url: "https://docs.alchemy.com/reference/aptos-api-quickstart"
5+
slug: "reference/aptos-api-quickstart"
6+
---
7+
8+
> 💡 Available only with [Blast](../reference/introduction-to-blast#how-to-get-blast) access
9+
10+
# Introduction
11+
12+
Aptos is a next-generation Layer 1 blockchain designed for scalability, safety, and upgradeability. It leverages the Move programming language and a novel consensus mechanism to achieve high throughput and low latency.
13+
14+
With its modular architecture, Aptos supports frequent and instant upgrades, making it a dynamic platform for developers and users alike.
15+
16+
***
17+
18+
## What is the Aptos Chain API?
19+
20+
The Aptos API provides developers with a set of tools to interact with the Aptos blockchain.
21+
22+
It offers both RESTful and JSON-RPC endpoints, allowing for seamless integration, transaction management, wallet interactions, and more.
23+
24+
Key features include:
25+
26+
* Account and Wallet Management: Create and manage Aptos accounts, check balances, and send/receive tokens.
27+
* Transaction Handling: Initiate, sign, and broadcast transactions.
28+
* Blockchain Data: Query blockchain data, such as account balances, block information, and transaction details.
29+
* Smart Contract Execution: Interact with Aptos smart contracts to perform decentralized actions.
30+
* Gas Estimates: Get current gas fees and estimate transaction costs.
31+
* Event Streams: Subscribe to real-time blockchain events through WebSockets.
32+
* Resource Access: Access blockchain resources like token metadata, account states, and more.
33+
34+
***
35+
36+
## Getting Started Instructions
37+
38+
### 1. Choose a Package Manager (npm or yarn)
39+
40+
Your first step involves selecting a package manager, which will be crucial for managing your project's dependencies. The choice between `npm` and `yarn` depends on your personal preference or project requirements.
41+
42+
| npm | yarn |
43+
| ------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
44+
| Begin with `npm` by following the [npm documentation](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm). | For `yarn`, refer to [yarn's installation guide](https://classic.yarnpkg.com/lang/en/docs/install). |
45+
46+
### 2. Set Up Your Project
47+
48+
To kickstart your project, open your terminal and execute the following commands:
49+
50+
<CodeGroup>
51+
```text npm
52+
mkdir aptos-api-quickstart
53+
cd aptos-api-quickstart
54+
npm init --yes
55+
```
56+
57+
```text yarn
58+
mkdir aptos-api-quickstart
59+
cd aptos-api-quickstart
60+
yarn init --yes
61+
```
62+
</CodeGroup>
63+
64+
This creates a new directory named `aptos-api-quickstart` and initializes a Node.js project within it.
65+
66+
### 3. Make Your First Request
67+
68+
Install Axios, a popular HTTP client, to make API requests:
69+
70+
<CodeGroup>
71+
```bash bash
72+
npm install axios
73+
# Or with yarn
74+
# yarn add axios
75+
```
76+
</CodeGroup>
77+
78+
Create an `index.js` file in your project directory and paste the following code:
79+
80+
<CodeGroup>
81+
```javascript javascript
82+
const axios = require('axios');
83+
84+
const url = `https://aptos-mainnet.alchemy-blast.com/v2/${yourAPIKey}/v1/accounts`;
85+
86+
axios.get(url)
87+
.then(response => {
88+
console.log('Accounts:', response.data);
89+
})
90+
.catch(error => {
91+
console.error('Error fetching accounts:', error.message);
92+
});
93+
94+
```
95+
</CodeGroup>
96+
97+
Remember to replace `yourAPIKey` with your actual Alchemy API key that you can get from your [Alchemy dashboard](https://dashboard.alchemy.com/).
98+
99+
### 4. Run Your Script
100+
101+
To execute your script and make a request to the Aptos App, run:
102+
103+
<CodeGroup>
104+
```bash bash
105+
node index.js
106+
```
107+
</CodeGroup>
108+
109+
You should see a list of Aptos accounts (if any exist on your node or fullnode) outputted to your console. For example:
110+
111+
```
112+
[
113+
{
114+
"authentication_key": "0x...",
115+
"sequence_number": "0",
116+
"modules": [...],
117+
"resources": [...]
118+
}
119+
]
120+
```
121+
122+
## Next Steps
123+
124+
Well done! You've just made your first request to the Aptos App API. With this foundation, you can dive deeper into the array of [JSON-RPC methods available on Aptos App](/node/aptos/aptos-api-endpoints) and start building your dApps on it!
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
---
2+
title: "Bitcoin API FAQ"
3+
description: "Frequently asked questions about the Monad API"
4+
url: "https://docs.alchemy.com/reference/bitcoin-api-faq"
5+
slug: "reference/bitcoin-api-faq"
6+
---
7+
8+
> 💡 Available only with [Blast](../reference/introduction-to-blast#how-to-get-blast) access
9+
10+
## What is Bitcoin?
11+
12+
Bitcoin is the first decentralized, peer-to-peer digital currency. It allows users to send and receive payments without the need for intermediaries like banks. Bitcoin uses a UTXO (Unspent Transaction Output) model and is secured by proof-of-work mining.
13+
14+
## What is the Bitcoin API?
15+
16+
The Bitcoin API allows developers to interact with the Bitcoin network using JSON-RPC methods. Through the API, developers can retrieve data about blocks, transactions, and the mempool, as well as broadcast new transactions to the network.
17+
18+
## How can I get access to the Aptos API?
19+
20+
This chain is available only with [Blast](/node/blast-api/blast-quickstart) access.
21+
22+
## How can I get started using the Bitcoin API?
23+
24+
Check out our [Bitcoin API Quickstart](/reference/bitcoin-api-quickstart) guide for setup instructions, sample code, and your first API call.
25+
26+
## Does Bitcoin support smart contracts?
27+
28+
Not in the same way as EVM-based chains. Bitcoin supports basic scripting for transactions, but does not have a full smart contract virtual machine like Ethereum. More advanced contract-like functionality is being explored via protocols like Taproot and Ordinals.
29+
30+
## What API standard does Bitcoin use?
31+
32+
Bitcoin Core implements a standard JSON-RPC interface for querying blockchain data and submitting transactions.
33+
34+
## What is a Bitcoin API key?
35+
36+
When accessing the Bitcoin Chain network via a node provider like Alchemy, developers use an API key to send transactions and retrieve data from the network.
37+
38+
## Which libraries can I use with the Bitcoin API?
39+
40+
You can use any HTTP client that supports JSON payloads — e.g., `axios`, `fetch`, `requests`, or `curl`. There are also Bitcoin-specific libraries like `bitcoin-core` (Node.js), `python-bitcoinrpc`, and `btcd` (Go) for deeper integration.
41+
42+
## What programming languages are compatible with the API?
43+
44+
The API works with any programming language that can send JSON over HTTP. Common choices include JavaScript/TypeScript, Python, Go, and Java.
45+
46+
## What is used for fees in Bitcoin?
47+
48+
Bitcoin transaction fees are paid in BTC. They are calculated per virtual byte (vByte) of transaction data and are used to incentivize miners to include transactions in blocks.
49+
50+
## What methods does Alchemy support for the Bitcoin API?
51+
52+
You can find a full list of supported JSON-RPC methods on the [Bitcoin API Endpoints](/node/bitcoin/bitcoin-api-endpoints) page.
53+
54+
## My question isn't listed here — where can I get help?
55+
56+
Check out the [Alchemy Discord](https://alchemy.com/discord) to ask questions, get support from the community, and connect with the Alchemy team.
Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
---
2+
title: "Bitcoin API Quickstart"
3+
description: "Get started building on Bitcoin and using the JSON-RPC API"
4+
url: "https://docs.alchemy.com/reference/bitcoin-api-quickstart"
5+
slug: "reference/bitcoin-api-quickstart"
6+
---
7+
8+
> 💡 Available only with [Blast](../reference/introduction-to-blast#how-to-get-blast) access
9+
10+
# Introduction
11+
12+
The Bitcoin API gives developers access to interact with the Bitcoin blockchain through a standard set of JSON-RPC methods. With this API, you can retrieve block and transaction data, inspect the mempool, broadcast transactions, and more.
13+
14+
Unlike EVM chains, Bitcoin uses a UTXO-based model and exposes its functionality via the JSON-RPC protocol. This quickstart will help you make your first request.
15+
16+
***
17+
18+
## What is the Bitcoin Chain API?
19+
20+
The Bitcoin Chain API allows applications to communicate with a Bitcoin node using the JSON-RPC protocol. Unlike Ethereum’s account-based model, Bitcoin relies on a UTXO (Unspent Transaction Output) model, which means that balances are tracked by outputs that are explicitly spent or unspent.
21+
22+
Alchemy’s Bitcoin API gives developers a consistent interface to query blockchain data, submit transactions, and monitor network activity. This includes:
23+
24+
* Retrieving raw or decoded transaction data
25+
* Querying block headers and full blocks
26+
* Monitoring mempool entries and states
27+
* Submitting and testing raw transactions
28+
29+
If you’ve worked with Ethereum or other JSON-RPC-compatible chains, the structure will feel familiar, though the data returned may differ in structure and semantics.
30+
31+
***
32+
33+
## Getting Started Instructions
34+
35+
### 1. Choose a Package Manager (npm or yarn)
36+
37+
Your first step involves selecting a package manager, which will be crucial for managing your project's dependencies. The choice between `npm` and `yarn` depends on your personal preference or project requirements.
38+
39+
| npm | yarn |
40+
| ------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |
41+
| Begin with `npm` by following the [npm documentation](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm). | For `yarn`, refer to [yarn's installation guide](https://classic.yarnpkg.com/lang/en/docs/install). |
42+
43+
### 2. Set Up Your Project
44+
45+
To kickstart your project, open your terminal and execute the following commands:
46+
47+
<CodeGroup>
48+
```text npm
49+
mkdir bitcoin-api-quickstart
50+
cd bitcoin-api-quickstart
51+
npm init --yes
52+
```
53+
54+
```text yarn
55+
mkdir bitcoin-api-quickstart
56+
cd bitcoin-api-quickstart
57+
yarn init --yes
58+
```
59+
</CodeGroup>
60+
61+
This creates a new directory named `bitcoin-api-quickstart` and initializes a Node.js project within it.
62+
63+
### 3. Make Your First Request
64+
65+
Install Axios, a popular HTTP client, to make API requests:
66+
67+
<CodeGroup>
68+
```bash bash
69+
npm install axios
70+
# Or with yarn
71+
# yarn add axios
72+
```
73+
</CodeGroup>
74+
75+
Create an `index.js` file in your project directory and paste the following code:
76+
77+
<CodeGroup>
78+
```javascript javascript
79+
const axios = require('axios');
80+
81+
const url = `https://bitcoin-mainnet.alchemy-blast.com/v2/${yourAPIKey}`;
82+
83+
const payload = {
84+
jsonrpc: '2.0',
85+
id: 1,
86+
method: 'getblockcount',
87+
params: []
88+
};
89+
90+
axios.post(url, payload)
91+
.then(response => {
92+
console.log('Current block height:', response.data.result);
93+
})
94+
.catch(error => {
95+
console.error('Error fetching block count:', error);
96+
});
97+
98+
```
99+
</CodeGroup>
100+
101+
Remember to replace `yourAPIKey` with your actual Alchemy API key that you can get from your [Alchemy dashboard](https://dashboard.alchemy.com/).
102+
103+
### 4. Run Your Script
104+
105+
To execute your script and make a request to the Bitcoin App, run:
106+
107+
<CodeGroup>
108+
```bash bash
109+
node index.js
110+
```
111+
</CodeGroup>
112+
113+
You should see the current block number on Bitcoin App (in hexadecimal format) outputted to your console:
114+
115+
```
116+
Current block height: 0x6d68e
117+
```
118+
119+
## Next Steps
120+
121+
Well done! You've just made your first request to the Bitcoin App API. With this foundation, you can dive deeper into the array of [JSON-RPC methods available on Bitcoin App](/node/bitcoin/bitcoin-api-endpoints) and start building your dApps on it!

0 commit comments

Comments
 (0)