Skip to content

Commit 1087bac

Browse files
committed
feat(schema): add eth_getAddressesInBlock
1 parent 9c873c2 commit 1087bac

File tree

2 files changed

+34
-0
lines changed

2 files changed

+34
-0
lines changed

src/eth/block.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
- name: eth_getAddressesInBlock
2+
summary: Returns the addresses that appear in the block and the index of each transaction they appear in.
3+
params:
4+
- name: Block
5+
required: true
6+
schema:
7+
$ref: '#/components/schemas/BlockNumberOrTag'
8+
result:
9+
name: Addresses in block
10+
schema:
11+
oneOf:
12+
- $ref: '#/components/schemas/notFound'
13+
- $ref: '#/components/schemas/BlockAddresses'
114
- name: eth_getBlockByHash
215
summary: Returns information about a block by hash.
316
params:

src/schemas/address.yaml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
BlockAddresses:
2+
type: object
3+
title: Address appearance
4+
description: An address that appears in one or more transactions in a block
5+
required:
6+
- address
7+
- indices
8+
additionalProperties: false
9+
properties:
10+
address:
11+
title: Address
12+
$ref: '#/components/schemas/address'
13+
indices:
14+
title: Transaction indices
15+
$ref: '#/components/schemas/TransactionIndices'
16+
TransactionIndices:
17+
title: Transaction index list
18+
type: array
19+
description: Indices of transactions an address appears in within a block
20+
items:
21+
$ref: '#/components/schemas/uint64'

0 commit comments

Comments
 (0)