Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: DOCS-797 Sonic API Reference and Quickstart #1761

Merged
merged 1 commit into from
Dec 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pages/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ From [public RPC endpoints](https://www.ankr.com/rpc/) that developers have come
<img src="/docs/build/rpc.png" class="responsive-pic" width="600" />

* Access RPC/REST Endpoints via HTTPS or WebSockets.
* Interact with 50+ [supported blockchains](/rpc-service/chains/chains-list/).
* Interact with 60+ [supported blockchains](/rpc-service/chains/chains-list/).
* Test out and get important stats.
* Suitable for Web3 developers and enthusiasts of all skill levels.
<div className="nx-p-4 border border-gray-200 dark:border-gray-900 rounded nx-mt-6">
Expand Down
1 change: 1 addition & 0 deletions pages/rpc-service/chains/chains-api/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
"secret-network": "Secret Network",
"sei": "Sei",
"solana": "Solana",
"sonic": "Sonic",
"stellar": "Stellar",
"story": "Story",
"sui": "Sui",
Expand Down
45 changes: 0 additions & 45 deletions pages/rpc-service/chains/chains-api/gnosis.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ The API interaction follows the [JSON-RPC](https://www.jsonrpc.org/specification
* [`eth_protocolVersion`](/rpc-service/chains/chains-api/gnosis/#eth_protocolversion) — returns the current protocol version.
* [`eth_syncing`](/rpc-service/chains/chains-api/gnosis/#eth_syncing) — returns data on the sync status or false.
* [`eth_gasPrice`](/rpc-service/chains/chains-api/gnosis/#eth_gasprice) — returns the current price per gas in wei.
* [`eth_accounts`](/rpc-service/chains/chains-api/gnosis/#eth_accounts) — returns a list of addresses owned by client.
* [`eth_blockNumber`](/rpc-service/chains/chains-api/gnosis/#eth_blocknumber) — returns the number of most recent block.
* [`eth_getBalance`](/rpc-service/chains/chains-api/gnosis/#eth_getbalance) — returns the balance of the account specified by address.
* [`eth_getStorageAt`](/rpc-service/chains/chains-api/gnosis/#eth_getstorageat) — returns the value from a storage position at an address specified.
Expand Down Expand Up @@ -367,50 +366,6 @@ curl -X POST https://rpc.ankr.com/gnosis \

---

## `eth_accounts`

> Returns a list of addresses owned by client.

### Parameters
<br/>

* `id` (integer; required): a request ID (example: 1).
* `jsonrpc` (string; required): a JSON RPC spec used (example: 2.0).
* `method` (string; required): a method used for the request.
* `params` (array; required): none.

### Returns
<br/>

* `<array>` (string; data, 20 bytes): addresses owned by the client.

### Request example

```shell
curl -X POST https://rpc.ankr.com/gnosis \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"method": "eth_accounts",
"params": [],
"id": 1
}'
```

### Response example

```json
{
"id": 1,
"jsonrpc": "2.0",
"result": [
"0x407d73d8a49eeb85d32cf465507dd71d507100c1"
]
}
```

---

## `eth_blockNumber`

> Returns the number of most recent block.
Expand Down
Loading
Loading