https://github.com/weavevm/wvm-blobscan
https://github.com/weavevm/wvm-blobscan
Last synced: over 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/weavevm/wvm-blobscan
- Owner: weaveVM
- License: mit
- Created: 2024-11-20T22:09:14.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-24T23:00:53.000Z (over 1 year ago)
- Last Synced: 2025-02-05T13:51:27.814Z (over 1 year ago)
- Language: Rust
- Size: 79.1 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## About
`wvm-blobscan` is a data bridge built to archive Ethereum's blob data on [WeaveVM](https://wvm.dev). It grabs blocks containing eip-4844 transactions from [Blobscan](https://blobscan.com) and archive them permanently on WeaveVM..
### Prerequisites & Dependencies
While the core functionality of this ETL codebase can run without web2 component dependencies, this node implementation uses [planetscale](https://planetscale.com) for cloud indexing and [shuttle.dev](https://shuttle.dev) for backend hosting. Check [.env.example](./env.example) to set up your environment variables.
```js
blobscan_pk="" // WeaveVM Blobscan archiver PK
DATABASE_HOST="" // planetscale
DATABASE_USERNAME="" // planetscale
DATABASE_PASSWORD="" // planetscale
```
## Build & Run
```bash
git clone https://github.com/weaveVM/wvm-blobscan.git
cd wvm-blobscan
shuttle run
```
## Workflow
```mermaid
graph TD
A[Ethereum Block]
B[Fetch Block Object from Blobscan API]
C[Archive on WeaveVM]
D[Index on PlanetScale]
A --> B
B --> C
C --> D
C -- Archive TxId --> D
```
## Server Methods
### Retrieve blob data and the associated archive txid by VersionedHash
```bash
curl -X GET https://blobscan.wvm.network/v1/blob/$BLOB_VERSIONED_HASH
```
Returns the res in the format as in below:
```rs
pub struct PsGetBlockByVersionedHash {
pub ethereum_block_number: u64,
pub wvm_archive_txid: String,
pub versioned_hash: String,
pub blob_data: String,
}
```
### Retrieve Archiver stats
```bash
curl -X GET https://blobscan.wvm.network/v1/stats
```
## License
This project is licensed under the [MIT License](./LICENSE)