From 95bec19103709b912d965a9767a24d5945368613 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 19 Jun 2024 15:12:30 -1000 Subject: [PATCH 01/42] initial commit for trace filter wip --- api/api_full.go | 3 + api/api_gateway.go | 1 + api/eth_aliases.go | 1 + api/mocks/mock_full.go | 15 + api/proxy_gen.go | 26 + build/openrpc/full.json | 595 +++++++++++++------- build/openrpc/gateway.json | 355 ++++++++---- build/openrpc/miner.json | 176 +++--- build/openrpc/worker.json | 74 +-- chain/types/ethtypes/eth_types.go | 16 + documentation/en/api-v1-unstable-methods.md | 45 ++ gateway/proxy_eth.go | 8 + itests/eth_transactions_test.go | 45 ++ node/impl/full/dummy.go | 4 + node/impl/full/eth.go | 10 + 15 files changed, 931 insertions(+), 443 deletions(-) diff --git a/api/api_full.go b/api/api_full.go index 5d2f6d4176e..b65ef301e26 100644 --- a/api/api_full.go +++ b/api/api_full.go @@ -827,6 +827,9 @@ type FullNode interface { // Implmements OpenEthereum-compatible API method trace_transaction EthTraceTransaction(ctx context.Context, txHash string) ([]*ethtypes.EthTraceTransaction, error) //perm:read + // Implements OpenEthereum-compatible API method trace_filter + EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) //perm:read + // CreateBackup creates node backup onder the specified file name. The // method requires that the lotus daemon is running with the // LOTUS_BACKUP_BASE_PATH environment variable set to some path, and that diff --git a/api/api_gateway.go b/api/api_gateway.go index a9f0e3962e6..90cbb1798be 100644 --- a/api/api_gateway.go +++ b/api/api_gateway.go @@ -133,6 +133,7 @@ type Gateway interface { EthTraceBlock(ctx context.Context, blkNum string) ([]*ethtypes.EthTraceBlock, error) EthTraceReplayBlockTransactions(ctx context.Context, blkNum string, traceTypes []string) ([]*ethtypes.EthTraceReplayBlockTransaction, error) EthTraceTransaction(ctx context.Context, txHash string) ([]*ethtypes.EthTraceTransaction, error) + EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) GetActorEventsRaw(ctx context.Context, filter *types.ActorEventFilter) ([]*types.ActorEvent, error) SubscribeActorEventsRaw(ctx context.Context, filter *types.ActorEventFilter) (<-chan *types.ActorEvent, error) diff --git a/api/eth_aliases.go b/api/eth_aliases.go index 6a7901cf920..bfd8ba16ebd 100644 --- a/api/eth_aliases.go +++ b/api/eth_aliases.go @@ -43,6 +43,7 @@ func CreateEthRPCAliases(as apitypes.Aliaser) { as.AliasMethod("trace_block", "Filecoin.EthTraceBlock") as.AliasMethod("trace_replayBlockTransactions", "Filecoin.EthTraceReplayBlockTransactions") as.AliasMethod("trace_transaction", "Filecoin.EthTraceTransaction") + as.AliasMethod("trace_filter", "Filecoin.EthTraceFilter") as.AliasMethod("net_version", "Filecoin.NetVersion") as.AliasMethod("net_listening", "Filecoin.NetListening") diff --git a/api/mocks/mock_full.go b/api/mocks/mock_full.go index b15eea34111..e02b9fcb68a 100644 --- a/api/mocks/mock_full.go +++ b/api/mocks/mock_full.go @@ -1092,6 +1092,21 @@ func (mr *MockFullNodeMockRecorder) EthTraceBlock(arg0, arg1 interface{}) *gomoc return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "EthTraceBlock", reflect.TypeOf((*MockFullNode)(nil).EthTraceBlock), arg0, arg1) } +// EthTraceFilter mocks base method. +func (m *MockFullNode) EthTraceFilter(arg0 context.Context, arg1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "EthTraceFilter", arg0, arg1) + ret0, _ := ret[0].([]*ethtypes.EthTraceFilterResult) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +// EthTraceFilter indicates an expected call of EthTraceFilter. +func (mr *MockFullNodeMockRecorder) EthTraceFilter(arg0, arg1 interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "EthTraceFilter", reflect.TypeOf((*MockFullNode)(nil).EthTraceFilter), arg0, arg1) +} + // EthTraceReplayBlockTransactions mocks base method. func (m *MockFullNode) EthTraceReplayBlockTransactions(arg0 context.Context, arg1 string, arg2 []string) ([]*ethtypes.EthTraceReplayBlockTransaction, error) { m.ctrl.T.Helper() diff --git a/api/proxy_gen.go b/api/proxy_gen.go index 1881a6f9dac..8805b3045c5 100644 --- a/api/proxy_gen.go +++ b/api/proxy_gen.go @@ -241,6 +241,8 @@ type FullNodeMethods struct { EthTraceBlock func(p0 context.Context, p1 string) ([]*ethtypes.EthTraceBlock, error) `perm:"read"` + EthTraceFilter func(p0 context.Context, p1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) `perm:"read"` + EthTraceReplayBlockTransactions func(p0 context.Context, p1 string, p2 []string) ([]*ethtypes.EthTraceReplayBlockTransaction, error) `perm:"read"` EthTraceTransaction func(p0 context.Context, p1 string) ([]*ethtypes.EthTraceTransaction, error) `perm:"read"` @@ -673,6 +675,8 @@ type GatewayMethods struct { EthTraceBlock func(p0 context.Context, p1 string) ([]*ethtypes.EthTraceBlock, error) `` + EthTraceFilter func(p0 context.Context, p1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) `` + EthTraceReplayBlockTransactions func(p0 context.Context, p1 string, p2 []string) ([]*ethtypes.EthTraceReplayBlockTransaction, error) `` EthTraceTransaction func(p0 context.Context, p1 string) ([]*ethtypes.EthTraceTransaction, error) `` @@ -2019,6 +2023,17 @@ func (s *FullNodeStub) EthTraceBlock(p0 context.Context, p1 string) ([]*ethtypes return *new([]*ethtypes.EthTraceBlock), ErrNotSupported } +func (s *FullNodeStruct) EthTraceFilter(p0 context.Context, p1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + if s.Internal.EthTraceFilter == nil { + return *new([]*ethtypes.EthTraceFilterResult), ErrNotSupported + } + return s.Internal.EthTraceFilter(p0, p1) +} + +func (s *FullNodeStub) EthTraceFilter(p0 context.Context, p1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + return *new([]*ethtypes.EthTraceFilterResult), ErrNotSupported +} + func (s *FullNodeStruct) EthTraceReplayBlockTransactions(p0 context.Context, p1 string, p2 []string) ([]*ethtypes.EthTraceReplayBlockTransaction, error) { if s.Internal.EthTraceReplayBlockTransactions == nil { return *new([]*ethtypes.EthTraceReplayBlockTransaction), ErrNotSupported @@ -4329,6 +4344,17 @@ func (s *GatewayStub) EthTraceBlock(p0 context.Context, p1 string) ([]*ethtypes. return *new([]*ethtypes.EthTraceBlock), ErrNotSupported } +func (s *GatewayStruct) EthTraceFilter(p0 context.Context, p1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + if s.Internal.EthTraceFilter == nil { + return *new([]*ethtypes.EthTraceFilterResult), ErrNotSupported + } + return s.Internal.EthTraceFilter(p0, p1) +} + +func (s *GatewayStub) EthTraceFilter(p0 context.Context, p1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + return *new([]*ethtypes.EthTraceFilterResult), ErrNotSupported +} + func (s *GatewayStruct) EthTraceReplayBlockTransactions(p0 context.Context, p1 string, p2 []string) ([]*ethtypes.EthTraceReplayBlockTransaction, error) { if s.Internal.EthTraceReplayBlockTransactions == nil { return *new([]*ethtypes.EthTraceReplayBlockTransaction), ErrNotSupported diff --git a/build/openrpc/full.json b/build/openrpc/full.json index e5dd67d09cc..def1797a74e 100644 --- a/build/openrpc/full.json +++ b/build/openrpc/full.json @@ -37,7 +37,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1307" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1311" } }, { @@ -60,7 +60,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1318" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1322" } }, { @@ -103,7 +103,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1329" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1333" } }, { @@ -214,7 +214,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1351" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1355" } }, { @@ -454,7 +454,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1362" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1366" } }, { @@ -685,7 +685,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1373" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1377" } }, { @@ -784,7 +784,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1384" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1388" } }, { @@ -816,7 +816,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1395" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1399" } }, { @@ -922,7 +922,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1406" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1410" } }, { @@ -1019,7 +1019,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1417" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1421" } }, { @@ -1078,7 +1078,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1428" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1432" } }, { @@ -1171,7 +1171,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1439" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1443" } }, { @@ -1255,7 +1255,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1450" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1454" } }, { @@ -1355,7 +1355,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1461" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1465" } }, { @@ -1411,7 +1411,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1472" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1476" } }, { @@ -1484,7 +1484,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1483" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1487" } }, { @@ -1557,7 +1557,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1494" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1498" } }, { @@ -1604,7 +1604,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1505" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1509" } }, { @@ -1636,7 +1636,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1516" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1520" } }, { @@ -1691,7 +1691,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1527" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1531" } }, { @@ -1743,7 +1743,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1549" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1553" } }, { @@ -1780,7 +1780,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1560" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1564" } }, { @@ -1827,7 +1827,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1571" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1575" } }, { @@ -1874,7 +1874,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1582" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1586" } }, { @@ -1954,7 +1954,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1593" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1597" } }, { @@ -2006,7 +2006,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1604" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1608" } }, { @@ -2045,7 +2045,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1615" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1619" } }, { @@ -2092,7 +2092,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1626" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1630" } }, { @@ -2147,7 +2147,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1637" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1641" } }, { @@ -2176,7 +2176,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1648" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1652" } }, { @@ -2313,7 +2313,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1659" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1663" } }, { @@ -2342,7 +2342,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1670" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1674" } }, { @@ -2396,7 +2396,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1681" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1685" } }, { @@ -2487,7 +2487,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1692" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1696" } }, { @@ -2515,7 +2515,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1703" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1707" } }, { @@ -2605,7 +2605,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1714" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1718" } }, { @@ -2861,7 +2861,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1725" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1729" } }, { @@ -3106,7 +3106,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1736" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1740" } }, { @@ -3162,7 +3162,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1747" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1751" } }, { @@ -3209,7 +3209,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1758" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1762" } }, { @@ -3307,7 +3307,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1769" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1773" } }, { @@ -3373,7 +3373,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1780" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1784" } }, { @@ -3439,7 +3439,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1791" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1795" } }, { @@ -3548,7 +3548,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1802" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1806" } }, { @@ -3606,7 +3606,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1813" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1817" } }, { @@ -3728,7 +3728,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1824" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1828" } }, { @@ -3937,7 +3937,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1835" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1839" } }, { @@ -4137,7 +4137,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1846" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1850" } }, { @@ -4329,7 +4329,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1857" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1861" } }, { @@ -4538,7 +4538,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1868" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1872" } }, { @@ -4629,7 +4629,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1879" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1883" } }, { @@ -4687,7 +4687,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1890" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1894" } }, { @@ -4945,7 +4945,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1901" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1905" } }, { @@ -5220,7 +5220,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1912" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1916" } }, { @@ -5248,7 +5248,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1923" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1927" } }, { @@ -5286,7 +5286,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1934" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1938" } }, { @@ -5394,7 +5394,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1945" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1949" } }, { @@ -5432,7 +5432,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1956" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1960" } }, { @@ -5461,7 +5461,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1967" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1971" } }, { @@ -5524,7 +5524,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1978" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1982" } }, { @@ -5587,7 +5587,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1989" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L1993" } }, { @@ -5632,7 +5632,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2000" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2004" } }, { @@ -5754,7 +5754,164 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2011" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2015" + } + }, + { + "name": "Filecoin.EthTraceFilter", + "description": "```go\nfunc (s *FullNodeStruct) EthTraceFilter(p0 context.Context, p1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) {\n\tif s.Internal.EthTraceFilter == nil {\n\t\treturn *new([]*ethtypes.EthTraceFilterResult), ErrNotSupported\n\t}\n\treturn s.Internal.EthTraceFilter(p0, p1)\n}\n```", + "summary": "Implements OpenEthereum-compatible API method trace_filter\n", + "paramStructure": "by-position", + "params": [ + { + "name": "p1", + "description": "ethtypes.EthTraceFilterCriteria", + "summary": "", + "schema": { + "examples": [ + { + "fromBlock": "string value", + "toBlock": "string value", + "addresses": [ + "string value" + ], + "topics": [ + [ + "string value" + ] + ] + } + ], + "additionalProperties": false, + "properties": { + "addresses": { + "items": { + "type": "string" + }, + "type": "array" + }, + "fromBlock": { + "type": "string" + }, + "toBlock": { + "type": "string" + }, + "topics": { + "items": { + "items": { + "type": "string" + }, + "type": "array" + }, + "type": "array" + } + }, + "type": [ + "object" + ] + }, + "required": true, + "deprecated": false + } + ], + "result": { + "name": "[]*ethtypes.EthTraceFilterResult", + "description": "[]*ethtypes.EthTraceFilterResult", + "summary": "", + "schema": { + "examples": [ + [ + { + "type": "string value", + "error": "string value", + "subtraces": 123, + "traceAddress": [ + 123 + ], + "action": {}, + "result": {}, + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": 9, + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionPosition": 123 + } + ] + ], + "items": [ + { + "additionalProperties": false, + "properties": { + "action": { + "additionalProperties": true, + "type": "object" + }, + "blockHash": { + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "maxItems": 32, + "minItems": 32, + "type": "array" + }, + "blockNumber": { + "title": "number", + "type": "number" + }, + "error": { + "type": "string" + }, + "result": { + "additionalProperties": true, + "type": "object" + }, + "subtraces": { + "title": "number", + "type": "number" + }, + "traceAddress": { + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "type": "array" + }, + "transactionHash": { + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "maxItems": 32, + "minItems": 32, + "type": "array" + }, + "transactionPosition": { + "title": "number", + "type": "number" + }, + "type": { + "type": "string" + } + }, + "type": [ + "object" + ] + } + ], + "type": [ + "array" + ] + }, + "required": true, + "deprecated": false + }, + "deprecated": false, + "externalDocs": { + "description": "Github remote link", + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2026" } }, { @@ -5909,7 +6066,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2022" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2037" } }, { @@ -6031,7 +6188,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2033" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2048" } }, { @@ -6085,7 +6242,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2044" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2059" } }, { @@ -6139,7 +6296,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2055" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2070" } }, { @@ -6194,7 +6351,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2066" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2081" } }, { @@ -6337,7 +6494,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2077" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2092" } }, { @@ -6464,7 +6621,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2088" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2103" } }, { @@ -6566,7 +6723,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2099" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2114" } }, { @@ -6789,7 +6946,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2110" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2125" } }, { @@ -6972,7 +7129,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2121" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2136" } }, { @@ -7052,7 +7209,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2132" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2147" } }, { @@ -7097,7 +7254,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2143" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2158" } }, { @@ -7153,7 +7310,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2154" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2169" } }, { @@ -7233,7 +7390,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2165" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2180" } }, { @@ -7313,7 +7470,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2176" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2191" } }, { @@ -7798,7 +7955,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2187" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2202" } }, { @@ -7992,7 +8149,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2198" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2213" } }, { @@ -8147,7 +8304,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2209" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2224" } }, { @@ -8396,7 +8553,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2220" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2235" } }, { @@ -8551,7 +8708,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2231" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2246" } }, { @@ -8728,7 +8885,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2242" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2257" } }, { @@ -8826,7 +8983,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2253" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2268" } }, { @@ -8991,7 +9148,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2264" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2279" } }, { @@ -9030,7 +9187,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2275" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2290" } }, { @@ -9095,7 +9252,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2286" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2301" } }, { @@ -9141,7 +9298,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2297" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2312" } }, { @@ -9291,7 +9448,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2308" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2323" } }, { @@ -9428,7 +9585,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2319" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2334" } }, { @@ -9659,7 +9816,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2330" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2345" } }, { @@ -9796,7 +9953,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2341" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2356" } }, { @@ -9961,7 +10118,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2352" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2367" } }, { @@ -10038,7 +10195,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2363" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2378" } }, { @@ -10233,7 +10390,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2385" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2400" } }, { @@ -10412,7 +10569,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2396" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2411" } }, { @@ -10574,7 +10731,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2407" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2422" } }, { @@ -10722,7 +10879,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2418" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2433" } }, { @@ -10950,7 +11107,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2429" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2444" } }, { @@ -11098,7 +11255,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2440" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2455" } }, { @@ -11310,7 +11467,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2451" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2466" } }, { @@ -11516,7 +11673,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2462" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2477" } }, { @@ -11584,7 +11741,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2473" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2488" } }, { @@ -11701,7 +11858,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2484" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2499" } }, { @@ -11792,7 +11949,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2495" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2510" } }, { @@ -11878,7 +12035,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2506" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2521" } }, { @@ -12073,7 +12230,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2517" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2532" } }, { @@ -12235,7 +12392,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2528" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2543" } }, { @@ -12431,7 +12588,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2539" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2554" } }, { @@ -12611,7 +12768,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2550" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2565" } }, { @@ -12774,7 +12931,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2561" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2576" } }, { @@ -12801,7 +12958,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2572" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2587" } }, { @@ -12828,7 +12985,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2583" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2598" } }, { @@ -12927,7 +13084,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2594" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2609" } }, { @@ -12973,7 +13130,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2605" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2620" } }, { @@ -13073,7 +13230,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2616" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2631" } }, { @@ -13189,7 +13346,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2627" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2642" } }, { @@ -13237,7 +13394,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2638" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2653" } }, { @@ -13329,7 +13486,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2649" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2664" } }, { @@ -13444,7 +13601,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2660" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2675" } }, { @@ -13492,7 +13649,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2671" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2686" } }, { @@ -13529,7 +13686,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2682" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2697" } }, { @@ -13801,7 +13958,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2693" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2708" } }, { @@ -13849,7 +14006,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2704" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2719" } }, { @@ -13907,7 +14064,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2715" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2730" } }, { @@ -14112,7 +14269,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2726" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2741" } }, { @@ -14315,7 +14472,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2737" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2752" } }, { @@ -14484,7 +14641,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2748" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2763" } }, { @@ -14688,7 +14845,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2759" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2774" } }, { @@ -14855,7 +15012,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2770" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2785" } }, { @@ -15062,7 +15219,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2781" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2796" } }, { @@ -15130,7 +15287,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2792" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2807" } }, { @@ -15182,7 +15339,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2803" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2818" } }, { @@ -15231,7 +15388,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2814" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2829" } }, { @@ -15322,7 +15479,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2825" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2840" } }, { @@ -15828,7 +15985,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2836" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2851" } }, { @@ -15934,7 +16091,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2847" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2862" } }, { @@ -15986,7 +16143,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2858" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2873" } }, { @@ -16538,7 +16695,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2869" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2884" } }, { @@ -16652,7 +16809,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2880" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2895" } }, { @@ -16749,7 +16906,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2891" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2906" } }, { @@ -16849,7 +17006,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2902" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2917" } }, { @@ -16937,7 +17094,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2913" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2928" } }, { @@ -17037,7 +17194,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2924" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2939" } }, { @@ -17124,7 +17281,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2935" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2950" } }, { @@ -17215,7 +17372,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2946" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2961" } }, { @@ -17340,7 +17497,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2957" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2972" } }, { @@ -17449,7 +17606,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2968" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2983" } }, { @@ -17519,7 +17676,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2979" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2994" } }, { @@ -17622,7 +17779,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L2990" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3005" } }, { @@ -17683,7 +17840,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3001" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3016" } }, { @@ -17813,7 +17970,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3012" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3027" } }, { @@ -17920,7 +18077,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3023" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3038" } }, { @@ -18134,7 +18291,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3034" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3049" } }, { @@ -18211,7 +18368,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3045" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3060" } }, { @@ -18288,7 +18445,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3056" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3071" } }, { @@ -18397,7 +18554,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3067" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3082" } }, { @@ -18506,7 +18663,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3078" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3093" } }, { @@ -18567,7 +18724,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3089" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3104" } }, { @@ -18677,7 +18834,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3100" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3115" } }, { @@ -18738,7 +18895,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3111" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3126" } }, { @@ -18806,7 +18963,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3122" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3137" } }, { @@ -18874,7 +19031,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3133" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3148" } }, { @@ -18955,7 +19112,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3144" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3159" } }, { @@ -19109,7 +19266,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3155" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3170" } }, { @@ -19181,7 +19338,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3166" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3181" } }, { @@ -19345,7 +19502,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3177" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3192" } }, { @@ -19510,7 +19667,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3188" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3203" } }, { @@ -19580,7 +19737,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3199" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3214" } }, { @@ -19648,7 +19805,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3210" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3225" } }, { @@ -19741,7 +19898,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3221" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3236" } }, { @@ -19812,7 +19969,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3232" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3247" } }, { @@ -20013,7 +20170,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3243" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3258" } }, { @@ -20145,7 +20302,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3254" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3269" } }, { @@ -20282,7 +20439,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3265" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3280" } }, { @@ -20393,7 +20550,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3276" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3291" } }, { @@ -20525,7 +20682,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3287" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3302" } }, { @@ -20656,7 +20813,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3298" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3313" } }, { @@ -20727,7 +20884,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3309" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3324" } }, { @@ -20811,7 +20968,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3320" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3335" } }, { @@ -20897,7 +21054,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3331" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3346" } }, { @@ -21080,7 +21237,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3342" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3357" } }, { @@ -21107,7 +21264,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3353" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3368" } }, { @@ -21160,7 +21317,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3364" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3379" } }, { @@ -21248,7 +21405,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3375" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3390" } }, { @@ -21699,7 +21856,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3386" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3401" } }, { @@ -21866,7 +22023,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3397" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3412" } }, { @@ -21964,7 +22121,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3408" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3423" } }, { @@ -22137,7 +22294,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3419" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3434" } }, { @@ -22235,7 +22392,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3430" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3445" } }, { @@ -22386,7 +22543,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3441" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3456" } }, { @@ -22471,7 +22628,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3452" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3467" } }, { @@ -22539,7 +22696,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3463" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3478" } }, { @@ -22591,7 +22748,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3474" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3489" } }, { @@ -22659,7 +22816,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3485" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3500" } }, { @@ -22820,7 +22977,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3496" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3511" } }, { @@ -22867,7 +23024,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3518" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3533" } }, { @@ -22914,7 +23071,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3529" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3544" } }, { @@ -22957,7 +23114,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3551" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3566" } }, { @@ -23053,7 +23210,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3562" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3577" } }, { @@ -23319,7 +23476,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3573" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3588" } }, { @@ -23342,7 +23499,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3584" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3599" } }, { @@ -23385,7 +23542,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3595" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3610" } }, { @@ -23436,7 +23593,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3606" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3621" } }, { @@ -23481,7 +23638,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3617" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3632" } }, { @@ -23509,7 +23666,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3628" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3643" } }, { @@ -23549,7 +23706,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3639" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3654" } }, { @@ -23608,7 +23765,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3650" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3665" } }, { @@ -23652,7 +23809,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3661" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3676" } }, { @@ -23711,7 +23868,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3672" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3687" } }, { @@ -23748,7 +23905,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3683" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3698" } }, { @@ -23792,7 +23949,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3694" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3709" } }, { @@ -23832,7 +23989,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3705" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3720" } }, { @@ -23907,7 +24064,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3716" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3731" } }, { @@ -24115,7 +24272,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3727" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3742" } }, { @@ -24159,7 +24316,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3738" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3753" } }, { @@ -24249,7 +24406,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3749" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3764" } }, { @@ -24276,7 +24433,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3760" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3775" } } ] diff --git a/build/openrpc/gateway.json b/build/openrpc/gateway.json index da9cc2d57ec..2c8299dd638 100644 --- a/build/openrpc/gateway.json +++ b/build/openrpc/gateway.json @@ -242,7 +242,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3771" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3786" } }, { @@ -473,7 +473,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3782" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3797" } }, { @@ -572,7 +572,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3793" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3808" } }, { @@ -604,7 +604,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3804" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3819" } }, { @@ -710,7 +710,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3815" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3830" } }, { @@ -803,7 +803,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3826" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3841" } }, { @@ -887,7 +887,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3837" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3852" } }, { @@ -987,7 +987,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3848" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3863" } }, { @@ -1043,7 +1043,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3859" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3874" } }, { @@ -1116,7 +1116,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3870" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3885" } }, { @@ -1189,7 +1189,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3881" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3896" } }, { @@ -1236,7 +1236,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3892" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3907" } }, { @@ -1268,7 +1268,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3903" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3918" } }, { @@ -1305,7 +1305,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3925" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3940" } }, { @@ -1352,7 +1352,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3936" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3951" } }, { @@ -1392,7 +1392,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3947" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3962" } }, { @@ -1439,7 +1439,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3958" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3973" } }, { @@ -1494,7 +1494,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3969" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3984" } }, { @@ -1523,7 +1523,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3980" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3995" } }, { @@ -1660,7 +1660,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L3991" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4006" } }, { @@ -1689,7 +1689,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4002" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4017" } }, { @@ -1743,7 +1743,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4013" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4028" } }, { @@ -1834,7 +1834,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4024" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4039" } }, { @@ -1862,7 +1862,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4035" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4050" } }, { @@ -1952,7 +1952,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4046" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4061" } }, { @@ -2208,7 +2208,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4057" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4072" } }, { @@ -2453,7 +2453,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4068" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4083" } }, { @@ -2509,7 +2509,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4079" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4094" } }, { @@ -2556,7 +2556,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4090" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4105" } }, { @@ -2654,7 +2654,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4101" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4116" } }, { @@ -2720,7 +2720,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4112" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4127" } }, { @@ -2786,7 +2786,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4123" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4138" } }, { @@ -2895,7 +2895,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4134" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4149" } }, { @@ -2953,7 +2953,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4145" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4160" } }, { @@ -3075,7 +3075,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4156" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4171" } }, { @@ -3267,7 +3267,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4167" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4182" } }, { @@ -3476,7 +3476,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4178" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4193" } }, { @@ -3567,7 +3567,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4189" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4204" } }, { @@ -3625,7 +3625,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4200" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4215" } }, { @@ -3883,7 +3883,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4211" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4226" } }, { @@ -4158,7 +4158,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4222" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4237" } }, { @@ -4186,7 +4186,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4233" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4248" } }, { @@ -4224,7 +4224,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4244" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4259" } }, { @@ -4332,7 +4332,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4255" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4270" } }, { @@ -4370,7 +4370,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4266" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4281" } }, { @@ -4399,7 +4399,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4277" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4292" } }, { @@ -4462,7 +4462,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4288" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4303" } }, { @@ -4525,7 +4525,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4299" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4314" } }, { @@ -4570,7 +4570,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4310" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4325" } }, { @@ -4692,7 +4692,164 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4321" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4336" + } + }, + { + "name": "Filecoin.EthTraceFilter", + "description": "```go\nfunc (s *GatewayStruct) EthTraceFilter(p0 context.Context, p1 ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) {\n\tif s.Internal.EthTraceFilter == nil {\n\t\treturn *new([]*ethtypes.EthTraceFilterResult), ErrNotSupported\n\t}\n\treturn s.Internal.EthTraceFilter(p0, p1)\n}\n```", + "summary": "There are not yet any comments for this method.", + "paramStructure": "by-position", + "params": [ + { + "name": "p1", + "description": "ethtypes.EthTraceFilterCriteria", + "summary": "", + "schema": { + "examples": [ + { + "fromBlock": "string value", + "toBlock": "string value", + "addresses": [ + "string value" + ], + "topics": [ + [ + "string value" + ] + ] + } + ], + "additionalProperties": false, + "properties": { + "addresses": { + "items": { + "type": "string" + }, + "type": "array" + }, + "fromBlock": { + "type": "string" + }, + "toBlock": { + "type": "string" + }, + "topics": { + "items": { + "items": { + "type": "string" + }, + "type": "array" + }, + "type": "array" + } + }, + "type": [ + "object" + ] + }, + "required": true, + "deprecated": false + } + ], + "result": { + "name": "[]*ethtypes.EthTraceFilterResult", + "description": "[]*ethtypes.EthTraceFilterResult", + "summary": "", + "schema": { + "examples": [ + [ + { + "type": "string value", + "error": "string value", + "subtraces": 123, + "traceAddress": [ + 123 + ], + "action": {}, + "result": {}, + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": 9, + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionPosition": 123 + } + ] + ], + "items": [ + { + "additionalProperties": false, + "properties": { + "action": { + "additionalProperties": true, + "type": "object" + }, + "blockHash": { + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "maxItems": 32, + "minItems": 32, + "type": "array" + }, + "blockNumber": { + "title": "number", + "type": "number" + }, + "error": { + "type": "string" + }, + "result": { + "additionalProperties": true, + "type": "object" + }, + "subtraces": { + "title": "number", + "type": "number" + }, + "traceAddress": { + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "type": "array" + }, + "transactionHash": { + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "maxItems": 32, + "minItems": 32, + "type": "array" + }, + "transactionPosition": { + "title": "number", + "type": "number" + }, + "type": { + "type": "string" + } + }, + "type": [ + "object" + ] + } + ], + "type": [ + "array" + ] + }, + "required": true, + "deprecated": false + }, + "deprecated": false, + "externalDocs": { + "description": "Github remote link", + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4347" } }, { @@ -4847,7 +5004,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4332" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4358" } }, { @@ -4969,7 +5126,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4343" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4369" } }, { @@ -5023,7 +5180,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4354" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4380" } }, { @@ -5077,7 +5234,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4365" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4391" } }, { @@ -5132,7 +5289,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4376" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4402" } }, { @@ -5234,7 +5391,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4387" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4413" } }, { @@ -5457,7 +5614,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4398" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4424" } }, { @@ -5640,7 +5797,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4409" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4435" } }, { @@ -5834,7 +5991,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4420" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4446" } }, { @@ -5880,7 +6037,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4431" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4457" } }, { @@ -6030,7 +6187,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4442" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4468" } }, { @@ -6167,7 +6324,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4453" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4479" } }, { @@ -6235,7 +6392,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4464" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4490" } }, { @@ -6352,7 +6509,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4475" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4501" } }, { @@ -6443,7 +6600,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4486" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4512" } }, { @@ -6529,7 +6686,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4497" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4523" } }, { @@ -6556,7 +6713,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4508" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4534" } }, { @@ -6583,7 +6740,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4519" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4545" } }, { @@ -6651,7 +6808,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4530" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4556" } }, { @@ -7157,7 +7314,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4541" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4567" } }, { @@ -7254,7 +7411,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4552" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4578" } }, { @@ -7354,7 +7511,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4563" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4589" } }, { @@ -7454,7 +7611,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4574" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4600" } }, { @@ -7579,7 +7736,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4585" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4611" } }, { @@ -7688,7 +7845,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4596" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4622" } }, { @@ -7791,7 +7948,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4607" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4633" } }, { @@ -7921,7 +8078,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4618" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4644" } }, { @@ -8028,7 +8185,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4629" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4655" } }, { @@ -8089,7 +8246,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4640" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4666" } }, { @@ -8157,7 +8314,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4651" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4677" } }, { @@ -8238,7 +8395,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4662" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4688" } }, { @@ -8402,7 +8559,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4673" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4699" } }, { @@ -8495,7 +8652,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4684" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4710" } }, { @@ -8696,7 +8853,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4695" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4721" } }, { @@ -8807,7 +8964,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4706" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4732" } }, { @@ -8938,7 +9095,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4717" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4743" } }, { @@ -9024,7 +9181,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4728" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4754" } }, { @@ -9051,7 +9208,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4739" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4765" } }, { @@ -9104,7 +9261,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4750" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4776" } }, { @@ -9192,7 +9349,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4761" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4787" } }, { @@ -9643,7 +9800,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4772" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4798" } }, { @@ -9810,7 +9967,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4783" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4809" } }, { @@ -9983,7 +10140,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4794" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4820" } }, { @@ -10051,7 +10208,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4805" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4831" } }, { @@ -10119,7 +10276,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4816" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4842" } }, { @@ -10280,7 +10437,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4827" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4853" } }, { @@ -10325,7 +10482,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4849" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4875" } }, { @@ -10370,7 +10527,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4860" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4886" } }, { @@ -10397,7 +10554,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4871" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L4897" } } ] diff --git a/build/openrpc/miner.json b/build/openrpc/miner.json index 31cb403d560..1987b85aa7a 100644 --- a/build/openrpc/miner.json +++ b/build/openrpc/miner.json @@ -30,7 +30,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5157" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5183" } }, { @@ -109,7 +109,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5168" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5194" } }, { @@ -155,7 +155,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5179" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5205" } }, { @@ -203,7 +203,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5190" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5216" } }, { @@ -251,7 +251,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5201" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5227" } }, { @@ -354,7 +354,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5212" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5238" } }, { @@ -428,7 +428,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5223" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5249" } }, { @@ -591,7 +591,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5234" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5260" } }, { @@ -742,7 +742,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5245" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5271" } }, { @@ -781,7 +781,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5256" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5282" } }, { @@ -913,7 +913,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5267" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5293" } }, { @@ -945,7 +945,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5278" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5304" } }, { @@ -986,7 +986,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5289" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5315" } }, { @@ -1054,7 +1054,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5300" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5326" } }, { @@ -1185,7 +1185,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5311" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5337" } }, { @@ -1316,7 +1316,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5322" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5348" } }, { @@ -1416,7 +1416,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5333" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5359" } }, { @@ -1516,7 +1516,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5344" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5370" } }, { @@ -1616,7 +1616,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5355" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5381" } }, { @@ -1716,7 +1716,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5366" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5392" } }, { @@ -1816,7 +1816,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5377" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5403" } }, { @@ -1916,7 +1916,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5388" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5414" } }, { @@ -2040,7 +2040,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5399" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5425" } }, { @@ -2164,7 +2164,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5410" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5436" } }, { @@ -2279,7 +2279,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5421" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5447" } }, { @@ -2379,7 +2379,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5432" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5458" } }, { @@ -2512,7 +2512,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5443" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5469" } }, { @@ -2636,7 +2636,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5454" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5480" } }, { @@ -2760,7 +2760,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5465" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5491" } }, { @@ -2884,7 +2884,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5476" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5502" } }, { @@ -3017,7 +3017,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5487" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5513" } }, { @@ -3117,7 +3117,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5498" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5524" } }, { @@ -3157,7 +3157,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5509" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5535" } }, { @@ -3229,7 +3229,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5520" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5546" } }, { @@ -3279,7 +3279,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5531" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5557" } }, { @@ -3323,7 +3323,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5542" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5568" } }, { @@ -3364,7 +3364,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5553" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5579" } }, { @@ -3608,7 +3608,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5564" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5590" } }, { @@ -3682,7 +3682,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5575" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5601" } }, { @@ -3732,7 +3732,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5586" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5612" } }, { @@ -3761,7 +3761,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5597" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5623" } }, { @@ -3790,7 +3790,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5608" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5634" } }, { @@ -3846,7 +3846,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5619" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5645" } }, { @@ -3869,7 +3869,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5630" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5656" } }, { @@ -3929,7 +3929,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5641" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5667" } }, { @@ -3968,7 +3968,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5652" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5678" } }, { @@ -4008,7 +4008,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5663" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5689" } }, { @@ -4081,7 +4081,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5674" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5700" } }, { @@ -4145,7 +4145,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5685" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5711" } }, { @@ -4208,7 +4208,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5696" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5722" } }, { @@ -4258,7 +4258,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5707" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5733" } }, { @@ -4817,7 +4817,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5718" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5744" } }, { @@ -4858,7 +4858,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5729" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5755" } }, { @@ -4899,7 +4899,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5740" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5766" } }, { @@ -4940,7 +4940,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5751" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5777" } }, { @@ -4981,7 +4981,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5762" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5788" } }, { @@ -5022,7 +5022,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5773" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5799" } }, { @@ -5053,7 +5053,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5784" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5810" } }, { @@ -5103,7 +5103,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5795" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5821" } }, { @@ -5144,7 +5144,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5806" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5832" } }, { @@ -5183,7 +5183,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5817" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5843" } }, { @@ -5247,7 +5247,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5828" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5854" } }, { @@ -5305,7 +5305,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5839" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5865" } }, { @@ -5752,7 +5752,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5850" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5876" } }, { @@ -5788,7 +5788,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5861" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5887" } }, { @@ -5931,7 +5931,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5872" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5898" } }, { @@ -5987,7 +5987,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5883" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5909" } }, { @@ -6026,7 +6026,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5894" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5920" } }, { @@ -6203,7 +6203,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5905" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5931" } }, { @@ -6255,7 +6255,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5916" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5942" } }, { @@ -6447,7 +6447,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5927" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5953" } }, { @@ -6547,7 +6547,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5938" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5964" } }, { @@ -6601,7 +6601,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5949" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5975" } }, { @@ -6640,7 +6640,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5960" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5986" } }, { @@ -6725,7 +6725,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5971" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5997" } }, { @@ -6919,7 +6919,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5982" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6008" } }, { @@ -7017,7 +7017,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L5993" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6019" } }, { @@ -7149,7 +7149,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6004" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6030" } }, { @@ -7203,7 +7203,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6015" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6041" } }, { @@ -7237,7 +7237,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6026" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6052" } }, { @@ -7324,7 +7324,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6037" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6063" } }, { @@ -7378,7 +7378,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6048" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6074" } }, { @@ -7478,7 +7478,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6059" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6085" } }, { @@ -7555,7 +7555,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6070" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6096" } }, { @@ -7646,7 +7646,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6081" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6107" } }, { @@ -7685,7 +7685,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6092" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6118" } }, { @@ -7801,7 +7801,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6103" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6129" } }, { @@ -9901,7 +9901,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6114" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6140" } } ] diff --git a/build/openrpc/worker.json b/build/openrpc/worker.json index 9f0bc1cccbf..5df472f5351 100644 --- a/build/openrpc/worker.json +++ b/build/openrpc/worker.json @@ -161,7 +161,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6202" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6228" } }, { @@ -252,7 +252,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6213" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6239" } }, { @@ -420,7 +420,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6224" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6250" } }, { @@ -447,7 +447,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6235" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6261" } }, { @@ -597,7 +597,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6246" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6272" } }, { @@ -700,7 +700,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6257" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6283" } }, { @@ -803,7 +803,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6268" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6294" } }, { @@ -925,7 +925,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6279" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6305" } }, { @@ -1135,7 +1135,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6290" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6316" } }, { @@ -1306,7 +1306,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6301" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6327" } }, { @@ -3350,7 +3350,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6312" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6338" } }, { @@ -3470,7 +3470,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6323" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6349" } }, { @@ -3531,7 +3531,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6334" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6360" } }, { @@ -3569,7 +3569,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6345" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6371" } }, { @@ -3729,7 +3729,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6356" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6382" } }, { @@ -3913,7 +3913,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6367" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6393" } }, { @@ -4054,7 +4054,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6378" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6404" } }, { @@ -4107,7 +4107,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6389" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6415" } }, { @@ -4250,7 +4250,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6400" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6426" } }, { @@ -4474,7 +4474,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6411" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6437" } }, { @@ -4601,7 +4601,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6422" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6448" } }, { @@ -4768,7 +4768,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6433" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6459" } }, { @@ -4895,7 +4895,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6444" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6470" } }, { @@ -4933,7 +4933,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6455" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6481" } }, { @@ -4972,7 +4972,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6466" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6492" } }, { @@ -4995,7 +4995,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6477" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6503" } }, { @@ -5034,7 +5034,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6488" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6514" } }, { @@ -5057,7 +5057,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6499" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6525" } }, { @@ -5096,7 +5096,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6510" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6536" } }, { @@ -5130,7 +5130,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6521" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6547" } }, { @@ -5184,7 +5184,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6532" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6558" } }, { @@ -5223,7 +5223,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6543" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6569" } }, { @@ -5262,7 +5262,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6554" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6580" } }, { @@ -5297,7 +5297,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6565" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6591" } }, { @@ -5477,7 +5477,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6576" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6602" } }, { @@ -5506,7 +5506,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6587" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6613" } }, { @@ -5529,7 +5529,7 @@ "deprecated": false, "externalDocs": { "description": "Github remote link", - "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6598" + "url": "https://github.com/filecoin-project/lotus/blob/master/api/proxy_gen.go#L6624" } } ] diff --git a/chain/types/ethtypes/eth_types.go b/chain/types/ethtypes/eth_types.go index 3c2b9bec031..2f6ceb7af81 100644 --- a/chain/types/ethtypes/eth_types.go +++ b/chain/types/ethtypes/eth_types.go @@ -1019,6 +1019,22 @@ type EthTraceTransaction struct { TransactionPosition int `json:"transactionPosition"` } +type EthTraceFilterResult struct { + *EthTrace + BlockHash EthHash `json:"blockHash"` + BlockNumber int64 `json:"blockNumber"` + TransactionHash EthHash `json:"transactionHash"` + TransactionPosition int `json:"transactionPosition"` +} + +// EthTraceFilterCriteria defines the criteria for filtering traces. +type EthTraceFilterCriteria struct { + FromBlock string `json:"fromBlock,omitempty"` + ToBlock string `json:"toBlock,omitempty"` + Addresses []string `json:"addresses,omitempty"` + Topics [][]string `json:"topics,omitempty"` +} + type EthCallTraceAction struct { CallType string `json:"callType"` From EthAddress `json:"from"` diff --git a/documentation/en/api-v1-unstable-methods.md b/documentation/en/api-v1-unstable-methods.md index b9ba51cb355..91abe50d2cd 100644 --- a/documentation/en/api-v1-unstable-methods.md +++ b/documentation/en/api-v1-unstable-methods.md @@ -76,6 +76,7 @@ * [EthSubscribe](#EthSubscribe) * [EthSyncing](#EthSyncing) * [EthTraceBlock](#EthTraceBlock) + * [EthTraceFilter](#EthTraceFilter) * [EthTraceReplayBlockTransactions](#EthTraceReplayBlockTransactions) * [EthTraceTransaction](#EthTraceTransaction) * [EthUninstallFilter](#EthUninstallFilter) @@ -2059,6 +2060,50 @@ Response: ] ``` +### EthTraceFilter +Implements OpenEthereum-compatible API method trace_filter + + +Perms: read + +Inputs: +```json +[ + { + "fromBlock": "string value", + "toBlock": "string value", + "addresses": [ + "string value" + ], + "topics": [ + [ + "string value" + ] + ] + } +] +``` + +Response: +```json +[ + { + "type": "string value", + "error": "string value", + "subtraces": 123, + "traceAddress": [ + 123 + ], + "action": {}, + "result": {}, + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": 9, + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionPosition": 123 + } +] +``` + ### EthTraceReplayBlockTransactions Replays all transactions in a block returning the requested traces for each transaction diff --git a/gateway/proxy_eth.go b/gateway/proxy_eth.go index eca6ae2bf41..a1ce418041f 100644 --- a/gateway/proxy_eth.go +++ b/gateway/proxy_eth.go @@ -629,6 +629,14 @@ func (gw *Node) EthTraceTransaction(ctx context.Context, txHash string) ([]*etht return gw.target.EthTraceTransaction(ctx, txHash) } +func (gw *Node) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + if err := gw.limit(ctx, stateRateLimitTokens); err != nil { + return nil, err + } + + return gw.target.EthTraceFilter(ctx, filter) +} + var EthMaxFiltersPerConn = 16 // todo make this configurable func addUserFilterLimited(ctx context.Context, cb func() (ethtypes.EthFilterID, error)) (ethtypes.EthFilterID, error) { diff --git a/itests/eth_transactions_test.go b/itests/eth_transactions_test.go index 3cb11d4a3a6..b975e243541 100644 --- a/itests/eth_transactions_test.go +++ b/itests/eth_transactions_test.go @@ -644,3 +644,48 @@ func TestTraceTransaction(t *testing.T) { require.EqualValues(t, traces[0].TransactionHash, hash) require.EqualValues(t, traces[0].BlockNumber, receipt.BlockNumber) } + +func TestTraceFilter(t *testing.T) { + blockTime := 100 * time.Millisecond + client, _, ens := kit.EnsembleMinimal(t, kit.MockProofs(), kit.ThroughRPC()) + + ens.InterconnectAll().BeginMining(blockTime) + + ctx, cancel := context.WithTimeout(context.Background(), time.Minute) + defer cancel() + + // Define filter criteria + filter := ethtypes.EthTraceFilterCriteria{ + FromBlock: "0x1", + ToBlock: "latest", + } + + // Example of creating and submitting a transaction + // Replace with actual test setup as needed + contractHex, err := os.ReadFile("./contracts/SimpleCoin.hex") + require.NoError(t, err) + + contract, err := hex.DecodeString(string(contractHex)) + require.NoError(t, err) + + key, ethAddr, deployer := client.EVM().NewAccount() + kit.SendFunds(ctx, t, client, deployer, types.FromFil(10)) + + tx, err := deployContractTx(ctx, client, ethAddr, contract) + require.NoError(t, err) + + client.EVM().SignTransaction(tx, key.PrivateKey) + hash := client.EVM().SubmitTransaction(ctx, tx) + + // Wait for the transaction to be mined + receipt, err := client.EVM().WaitTransaction(ctx, hash) + require.NoError(t, err) + require.NotNil(t, receipt) + require.EqualValues(t, ethtypes.EthUint64(0x1), receipt.Status) + + // Trace filter should find the transaction + traces, err := client.EthTraceFilter(ctx, filter) + require.NoError(t, err) + require.NotNil(t, traces) + require.NotEmpty(t, traces) +} diff --git a/node/impl/full/dummy.go b/node/impl/full/dummy.go index 867d5f5a47d..491fd136c31 100644 --- a/node/impl/full/dummy.go +++ b/node/impl/full/dummy.go @@ -191,6 +191,10 @@ func (e *EthModuleDummy) EthTraceTransaction(ctx context.Context, txHash string) return nil, ErrModuleDisabled } +func (e *EthModuleDummy) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + return nil, ErrModuleDisabled +} + var _ EthModuleAPI = &EthModuleDummy{} var _ EthEventAPI = &EthModuleDummy{} diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 82f272c6cff..3b098330f78 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -76,6 +76,7 @@ type EthModuleAPI interface { EthTraceBlock(ctx context.Context, blkNum string) ([]*ethtypes.EthTraceBlock, error) EthTraceReplayBlockTransactions(ctx context.Context, blkNum string, traceTypes []string) ([]*ethtypes.EthTraceReplayBlockTransaction, error) EthTraceTransaction(ctx context.Context, txHash string) ([]*ethtypes.EthTraceTransaction, error) + EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) } type EthEventAPI interface { @@ -1022,6 +1023,15 @@ func (a *EthModule) EthTraceTransaction(ctx context.Context, txHash string) ([]* return txTraces, nil } +func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + // Logic to implement the filter criteria for tracing + // This is a placeholder implementation. Replace it with actual logic. + var results []*ethtypes.EthTraceFilterResult + + // Add the actual implementation here + return results, nil +} + func (a *EthModule) applyMessage(ctx context.Context, msg *types.Message, tsk types.TipSetKey) (res *api.InvocResult, err error) { ts, err := a.Chain.GetTipSetFromKey(ctx, tsk) if err != nil { From 0ec7286a8992a8c27781cec78a019b6e6b49248a Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 19 Jun 2024 15:30:14 -1000 Subject: [PATCH 02/42] trace filter for gateway --- gateway/node.go | 1 + 1 file changed, 1 insertion(+) diff --git a/gateway/node.go b/gateway/node.go index 0d7a04109fb..01bc551937d 100644 --- a/gateway/node.go +++ b/gateway/node.go @@ -147,6 +147,7 @@ type TargetAPI interface { EthTraceBlock(ctx context.Context, blkNum string) ([]*ethtypes.EthTraceBlock, error) EthTraceReplayBlockTransactions(ctx context.Context, blkNum string, traceTypes []string) ([]*ethtypes.EthTraceReplayBlockTransaction, error) EthTraceTransaction(ctx context.Context, txHash string) ([]*ethtypes.EthTraceTransaction, error) + EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) GetActorEventsRaw(ctx context.Context, filter *types.ActorEventFilter) ([]*types.ActorEvent, error) SubscribeActorEventsRaw(ctx context.Context, filter *types.ActorEventFilter) (<-chan *types.ActorEvent, error) From 5751fba7cc6eba499fffc0bd2e1973e8671f7099 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 19 Jun 2024 16:50:08 -1000 Subject: [PATCH 03/42] trace filter implementation --- chain/types/ethtypes/eth_types.go | 10 ++-- node/impl/full/eth.go | 89 +++++++++++++++++++++++++++++-- 2 files changed, 92 insertions(+), 7 deletions(-) diff --git a/chain/types/ethtypes/eth_types.go b/chain/types/ethtypes/eth_types.go index 2f6ceb7af81..43f71f832e4 100644 --- a/chain/types/ethtypes/eth_types.go +++ b/chain/types/ethtypes/eth_types.go @@ -1029,10 +1029,12 @@ type EthTraceFilterResult struct { // EthTraceFilterCriteria defines the criteria for filtering traces. type EthTraceFilterCriteria struct { - FromBlock string `json:"fromBlock,omitempty"` - ToBlock string `json:"toBlock,omitempty"` - Addresses []string `json:"addresses,omitempty"` - Topics [][]string `json:"topics,omitempty"` + FromBlock string `json:"fromBlock,omitempty"` + ToBlock string `json:"toBlock,omitempty"` + FromAddress []string `json:"fromAddress,omitempty"` + ToAddress []string `json:"toAddress,omitempty"` + After int `json:"after,omitempty"` + Count int `json:"count,omitempty"` } type EthCallTraceAction struct { diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 3b098330f78..ca9a293b633 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1024,14 +1024,97 @@ func (a *EthModule) EthTraceTransaction(ctx context.Context, txHash string) ([]* } func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { - // Logic to implement the filter criteria for tracing - // This is a placeholder implementation. Replace it with actual logic. + fromBlock, err := strconv.ParseUint(filter.FromBlock, 10, 64) + if err != nil { + return nil, xerrors.Errorf("cannot parse fromBlock: %w", err) + } + + toBlock, err := strconv.ParseUint(filter.ToBlock, 10, 64) + if err != nil { + return nil, xerrors.Errorf("cannot parse toBlock: %w", err) + } + var results []*ethtypes.EthTraceFilterResult + for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { + blockTraces, err := a.EthTraceBlock(ctx, strconv.FormatUint(blkNum, 10)) + if err != nil { + return nil, xerrors.Errorf("cannot get trace for block %d: %w", blkNum, err) + } + + for _, blockTrace := range blockTraces { + if matchFilterCriteria(blockTrace, filter) { + txTrace := ethtypes.EthTraceFilterResult{ + EthTrace: blockTrace.EthTrace, + BlockHash: blockTrace.BlockHash, + BlockNumber: blockTrace.BlockNumber, + TransactionHash: blockTrace.TransactionHash, + TransactionPosition: blockTrace.TransactionPosition, + } + results = append(results, &txTrace) + + // If Count is specified, limit the results + if filter.Count > 0 && len(results) >= filter.Count { + return results, nil + } + } + } + } - // Add the actual implementation here return results, nil } +// matchFilterCriteria checks if a trace matches the filter criteria. +func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria) bool { + action, ok := trace.Action.(*ethtypes.EthCallTraceAction) + if !ok { + fmt.Printf("Action type: %T, value: %+v\n", trace.Action, trace.Action) + return false + } + + // Match FromAddress + if len(filter.FromAddress) > 0 { + fromMatch := false + for _, addr := range filter.FromAddress { + ethAddr, err := ethtypes.ParseEthAddress(addr) + if err != nil { + continue + } + if action.From == ethAddr { + fromMatch = true + break + } + } + if !fromMatch { + return false + } + } + + // Match ToAddress + if len(filter.ToAddress) > 0 { + toMatch := false + for _, addr := range filter.ToAddress { + ethAddr, err := ethtypes.ParseEthAddress(addr) + if err != nil { + continue + } + if action.To == ethAddr { + toMatch = true + break + } + } + if !toMatch { + return false + } + } + + // Apply After offset + if filter.After > 0 && len(trace.TraceAddress) > 0 && trace.TraceAddress[0] <= filter.After { + return false + } + + return true +} + func (a *EthModule) applyMessage(ctx context.Context, msg *types.Message, tsk types.TipSetKey) (res *api.InvocResult, err error) { ts, err := a.Chain.GetTipSetFromKey(ctx, tsk) if err != nil { From f773ca503f7a59f218e8b9fa1873f59572fb971d Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 19 Jun 2024 16:53:06 -1000 Subject: [PATCH 04/42] make gen --- build/openrpc/full.json | 35 ++++++++++++--------- build/openrpc/gateway.json | 35 ++++++++++++--------- documentation/en/api-v1-unstable-methods.md | 12 +++---- 3 files changed, 46 insertions(+), 36 deletions(-) diff --git a/build/openrpc/full.json b/build/openrpc/full.json index def1797a74e..788e40e91d7 100644 --- a/build/openrpc/full.json +++ b/build/openrpc/full.json @@ -5772,19 +5772,27 @@ { "fromBlock": "string value", "toBlock": "string value", - "addresses": [ + "fromAddress": [ "string value" ], - "topics": [ - [ - "string value" - ] - ] + "toAddress": [ + "string value" + ], + "after": 123, + "count": 123 } ], "additionalProperties": false, "properties": { - "addresses": { + "after": { + "title": "number", + "type": "number" + }, + "count": { + "title": "number", + "type": "number" + }, + "fromAddress": { "items": { "type": "string" }, @@ -5793,17 +5801,14 @@ "fromBlock": { "type": "string" }, - "toBlock": { - "type": "string" - }, - "topics": { + "toAddress": { "items": { - "items": { - "type": "string" - }, - "type": "array" + "type": "string" }, "type": "array" + }, + "toBlock": { + "type": "string" } }, "type": [ diff --git a/build/openrpc/gateway.json b/build/openrpc/gateway.json index 2c8299dd638..f3008089e7c 100644 --- a/build/openrpc/gateway.json +++ b/build/openrpc/gateway.json @@ -4710,19 +4710,27 @@ { "fromBlock": "string value", "toBlock": "string value", - "addresses": [ + "fromAddress": [ "string value" ], - "topics": [ - [ - "string value" - ] - ] + "toAddress": [ + "string value" + ], + "after": 123, + "count": 123 } ], "additionalProperties": false, "properties": { - "addresses": { + "after": { + "title": "number", + "type": "number" + }, + "count": { + "title": "number", + "type": "number" + }, + "fromAddress": { "items": { "type": "string" }, @@ -4731,17 +4739,14 @@ "fromBlock": { "type": "string" }, - "toBlock": { - "type": "string" - }, - "topics": { + "toAddress": { "items": { - "items": { - "type": "string" - }, - "type": "array" + "type": "string" }, "type": "array" + }, + "toBlock": { + "type": "string" } }, "type": [ diff --git a/documentation/en/api-v1-unstable-methods.md b/documentation/en/api-v1-unstable-methods.md index 91abe50d2cd..34ce56ae1a7 100644 --- a/documentation/en/api-v1-unstable-methods.md +++ b/documentation/en/api-v1-unstable-methods.md @@ -2072,14 +2072,14 @@ Inputs: { "fromBlock": "string value", "toBlock": "string value", - "addresses": [ + "fromAddress": [ "string value" ], - "topics": [ - [ - "string value" - ] - ] + "toAddress": [ + "string value" + ], + "after": 123, + "count": 123 } ] ``` From 9fd949d32bc455f7aa22259a71f7b753c5942fc2 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 19 Jun 2024 17:42:14 -1000 Subject: [PATCH 05/42] implement after properly in trace_filter --- node/impl/full/eth.go | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index ca9a293b633..a02da7db9a2 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1035,6 +1035,8 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace } var results []*ethtypes.EthTraceFilterResult + traceCounter := 0 + for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { blockTraces, err := a.EthTraceBlock(ctx, strconv.FormatUint(blkNum, 10)) if err != nil { @@ -1043,6 +1045,11 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace for _, blockTrace := range blockTraces { if matchFilterCriteria(blockTrace, filter) { + traceCounter++ + if traceCounter <= filter.After { + continue + } + txTrace := ethtypes.EthTraceFilterResult{ EthTrace: blockTrace.EthTrace, BlockHash: blockTrace.BlockHash, @@ -1067,7 +1074,6 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria) bool { action, ok := trace.Action.(*ethtypes.EthCallTraceAction) if !ok { - fmt.Printf("Action type: %T, value: %+v\n", trace.Action, trace.Action) return false } @@ -1107,11 +1113,6 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace } } - // Apply After offset - if filter.After > 0 && len(trace.TraceAddress) > 0 && trace.TraceAddress[0] <= filter.After { - return false - } - return true } From afae8214919f5827084d943f6f20c0456323d6c0 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 19 Jun 2024 21:38:52 -1000 Subject: [PATCH 06/42] accept block numbers in hex format --- node/impl/full/eth.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index a02da7db9a2..8ffdc83eab3 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1024,12 +1024,12 @@ func (a *EthModule) EthTraceTransaction(ctx context.Context, txHash string) ([]* } func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { - fromBlock, err := strconv.ParseUint(filter.FromBlock, 10, 64) + fromBlock, err := ethtypes.EthUint64FromHex(filter.FromBlock) if err != nil { return nil, xerrors.Errorf("cannot parse fromBlock: %w", err) } - toBlock, err := strconv.ParseUint(filter.ToBlock, 10, 64) + toBlock, err := ethtypes.EthUint64FromHex(filter.ToBlock) if err != nil { return nil, xerrors.Errorf("cannot parse toBlock: %w", err) } @@ -1038,7 +1038,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace traceCounter := 0 for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { - blockTraces, err := a.EthTraceBlock(ctx, strconv.FormatUint(blkNum, 10)) + blockTraces, err := a.EthTraceBlock(ctx, strconv.FormatUint(uint64(blkNum), 10)) if err != nil { return nil, xerrors.Errorf("cannot get trace for block %d: %w", blkNum, err) } From ee51aacc7a78da452510436284bd62e11450bd35 Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 24 Jun 2024 14:10:50 -1000 Subject: [PATCH 07/42] trace_filter support for pending/latest/safe block numbers --- node/impl/full/eth.go | 31 +++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index e415b044cfc..e037f5b4a6d 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1028,13 +1028,40 @@ func (a *EthModule) EthTraceTransaction(ctx context.Context, txHash string) ([]* return txTraces, nil } +func (a *EthModule) EthBlockNumberFromString(ctx context.Context, block string) (ethtypes.EthUint64, error) { + + head := a.Chain.GetHeaviestTipSet() + switch block { + case "earliest": + return 0, xerrors.Errorf("block param \"earliest\" is not supported") + case "pending": + return ethtypes.EthUint64(head.Height()), nil + case "latest": + parent, err := a.Chain.GetTipSetFromKey(ctx, head.Parents()) + if err != nil { + return 0, fmt.Errorf("cannot get parent tipset") + } + return ethtypes.EthUint64(parent.Height()), nil + case "safe": + latestHeight := head.Height() - 1 + safeHeight := latestHeight - ethtypes.SafeEpochDelay + return ethtypes.EthUint64(safeHeight), nil + default: + blockNum, err := ethtypes.EthUint64FromHex(block) + if err != nil { + return 0, xerrors.Errorf("cannot parse fromBlock: %w", err) + } + return blockNum, err + } +} + func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { - fromBlock, err := ethtypes.EthUint64FromHex(filter.FromBlock) + fromBlock, err := a.EthBlockNumberFromString(ctx, filter.FromBlock) if err != nil { return nil, xerrors.Errorf("cannot parse fromBlock: %w", err) } - toBlock, err := ethtypes.EthUint64FromHex(filter.ToBlock) + toBlock, err := a.EthBlockNumberFromString(ctx, filter.ToBlock) if err != nil { return nil, xerrors.Errorf("cannot parse toBlock: %w", err) } From ac53ddbec2ee9997a7f699b5d6bf1389dbe72ede Mon Sep 17 00:00:00 2001 From: Mikers Date: Thu, 27 Jun 2024 13:37:53 -1000 Subject: [PATCH 08/42] run filter.FromBlock and filter.ToBlock through gw.checkBlkParam to make sure we stick to lookback limits --- gateway/proxy_eth.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gateway/proxy_eth.go b/gateway/proxy_eth.go index 9c552ba6acb..a01c257b6ac 100644 --- a/gateway/proxy_eth.go +++ b/gateway/proxy_eth.go @@ -639,6 +639,14 @@ func (gw *Node) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilt return nil, err } + if err := gw.checkBlkParam(ctx, filter.ToBlock, 0); err != nil { + return nil, err + } + + if err := gw.checkBlkParam(ctx, filter.FromBlock, 0); err != nil { + return nil, err + } + return gw.target.EthTraceFilter(ctx, filter) } From 10bdb5802a18b9c1eb00f866ab96192b5937d62d Mon Sep 17 00:00:00 2001 From: Mikers Date: Thu, 27 Jun 2024 13:38:34 -1000 Subject: [PATCH 09/42] Update node/impl/full/eth.go Co-authored-by: Rod Vagg --- node/impl/full/eth.go | 1 - 1 file changed, 1 deletion(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index e037f5b4a6d..3383affdb42 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1029,7 +1029,6 @@ func (a *EthModule) EthTraceTransaction(ctx context.Context, txHash string) ([]* } func (a *EthModule) EthBlockNumberFromString(ctx context.Context, block string) (ethtypes.EthUint64, error) { - head := a.Chain.GetHeaviestTipSet() switch block { case "earliest": From f67055d9e916269c912bad75bc417723dfcdc803 Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 1 Jul 2024 13:23:59 -1000 Subject: [PATCH 10/42] document EthTraceFilterCriteria --- chain/types/ethtypes/eth_types.go | 35 +++++++++++++++++++++++++------ 1 file changed, 29 insertions(+), 6 deletions(-) diff --git a/chain/types/ethtypes/eth_types.go b/chain/types/ethtypes/eth_types.go index 1f974cdacdf..82b32f36fc9 100644 --- a/chain/types/ethtypes/eth_types.go +++ b/chain/types/ethtypes/eth_types.go @@ -1035,12 +1035,35 @@ type EthTraceFilterResult struct { // EthTraceFilterCriteria defines the criteria for filtering traces. type EthTraceFilterCriteria struct { - FromBlock string `json:"fromBlock,omitempty"` - ToBlock string `json:"toBlock,omitempty"` - FromAddress []string `json:"fromAddress,omitempty"` - ToAddress []string `json:"toAddress,omitempty"` - After int `json:"after,omitempty"` - Count int `json:"count,omitempty"` + // Interpreted as an epoch (in hex) or one of "latest" for last mined block, "earliest" for first, + // "pending" for not yet committed messages. + // Optional, default: "latest". + FromBlock *string `json:"fromBlock,omitempty"` + + // Interpreted as an epoch (in hex) or one of "latest" for last mined block, "earliest" for first, + // "pending" for not yet committed messages. + // Optional, default: "latest". + ToBlock *string `json:"toBlock,omitempty"` + + // Actor address or a list of addresses from which event logs should originate. + // Optional, default: nil. + // The JSON decoding must treat a string as equivalent to an array with one value, for example + // "0x8888f1f195afa192cfee86069858" must be decoded as [ "0x8888f1f195afa192cfee86069858" ] + FromAddress *[]string `json:"fromAddress,omitempty"` + + // Actor address or a list of addresses to which event logs should be sent. + // Optional, default: nil. + // The JSON decoding must treat a string as equivalent to an array with one value, for example + // "0x8888f1f195afa192cfee86069858" must be decoded as [ "0x8888f1f195afa192cfee86069858" ] + ToAddress *[]string `json:"toAddress,omitempty"` + + // Restricts traces returned to those emitted after this epoch (in hex). + // Optional, default: 0. + After *int `json:"after,omitempty"` + + // Limits the number of traces returned. + // Optional, default: all traces. + Count *int `json:"count,omitempty"` } type EthCallTraceAction struct { From f74fd6001db51dd44395de1e6326216ded063a4e Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 1 Jul 2024 13:58:32 -1000 Subject: [PATCH 11/42] refactor: Handle nil pointers and optional defaults in EthBlockNumberFromString and EthTraceFilter functions. --- node/impl/full/eth.go | 30 +++++++++++++++++++++--------- 1 file changed, 21 insertions(+), 9 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 3383affdb42..d083f2a96eb 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1028,9 +1028,15 @@ func (a *EthModule) EthTraceTransaction(ctx context.Context, txHash string) ([]* return txTraces, nil } -func (a *EthModule) EthBlockNumberFromString(ctx context.Context, block string) (ethtypes.EthUint64, error) { +func (a *EthModule) EthBlockNumberFromString(ctx context.Context, block *string) (ethtypes.EthUint64, error) { head := a.Chain.GetHeaviestTipSet() - switch block { + + blockValue := "latest" + if block != nil { + blockValue = *block + } + + switch blockValue { case "earliest": return 0, xerrors.Errorf("block param \"earliest\" is not supported") case "pending": @@ -1046,7 +1052,7 @@ func (a *EthModule) EthBlockNumberFromString(ctx context.Context, block string) safeHeight := latestHeight - ethtypes.SafeEpochDelay return ethtypes.EthUint64(safeHeight), nil default: - blockNum, err := ethtypes.EthUint64FromHex(block) + blockNum, err := ethtypes.EthUint64FromHex(blockValue) if err != nil { return 0, xerrors.Errorf("cannot parse fromBlock: %w", err) } @@ -1066,6 +1072,12 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace } var results []*ethtypes.EthTraceFilterResult + + // If filter.Count is specified and it is 0, return an empty result set immediately. + if filter.Count != nil && *filter.Count == 0 { + return []*ethtypes.EthTraceFilterResult{}, nil + } + traceCounter := 0 for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { @@ -1077,7 +1089,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace for _, blockTrace := range blockTraces { if matchFilterCriteria(blockTrace, filter) { traceCounter++ - if traceCounter <= filter.After { + if traceCounter <= *filter.After { continue } @@ -1091,7 +1103,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace results = append(results, &txTrace) // If Count is specified, limit the results - if filter.Count > 0 && len(results) >= filter.Count { + if filter.Count != nil && len(results) >= *filter.Count { return results, nil } } @@ -1109,9 +1121,9 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace } // Match FromAddress - if len(filter.FromAddress) > 0 { + if filter.FromAddress != nil && len(*filter.FromAddress) > 0 { fromMatch := false - for _, addr := range filter.FromAddress { + for _, addr := range *filter.FromAddress { ethAddr, err := ethtypes.ParseEthAddress(addr) if err != nil { continue @@ -1127,9 +1139,9 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace } // Match ToAddress - if len(filter.ToAddress) > 0 { + if filter.ToAddress != nil && len(*filter.ToAddress) > 0 { toMatch := false - for _, addr := range filter.ToAddress { + for _, addr := range *filter.ToAddress { ethAddr, err := ethtypes.ParseEthAddress(addr) if err != nil { continue From 3d3609b8650e0822014014a39c7933df7c5ee71c Mon Sep 17 00:00:00 2001 From: Mikers Date: Tue, 2 Jul 2024 12:42:27 -1000 Subject: [PATCH 12/42] decode ToAddress and FromAddress in the caller function and re-use them in each call --- node/impl/full/eth.go | 47 ++++++++++++++++++++++++++++++------------- 1 file changed, 33 insertions(+), 14 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index d083f2a96eb..22009219176 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1080,6 +1080,16 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace traceCounter := 0 + fromDecodedAddresses, fromErr := decodeAddressFilter(filter.FromAddress) + if fromErr != nil { + return nil, xerrors.Errorf("cannot decode FromAddress: %w", fromErr) + } + + toDecodedAddresses, toErr := decodeAddressFilter(filter.ToAddress) + if toErr != nil { + return nil, xerrors.Errorf("cannot decode ToAddress: %w", toErr) + } + for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { blockTraces, err := a.EthTraceBlock(ctx, strconv.FormatUint(uint64(blkNum), 10)) if err != nil { @@ -1087,7 +1097,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace } for _, blockTrace := range blockTraces { - if matchFilterCriteria(blockTrace, filter) { + if matchFilterCriteria(blockTrace, filter, fromDecodedAddresses, toDecodedAddresses) { traceCounter++ if traceCounter <= *filter.After { continue @@ -1113,21 +1123,34 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace return results, nil } +func decodeAddressFilter(addresses *[]string) (*[]ethtypes.EthAddress, error) { + if addresses == nil || len(*addresses) == 0 { + return nil, errors.New("addresses is nil or empty") + } + var decodedAddresses []ethtypes.EthAddress + for _, addr := range *addresses { + ethAddr, err := ethtypes.ParseEthAddress(addr) + if err != nil { + return nil, xerrors.Errorf("invalid address: %w", err) + } + decodedAddresses = append(decodedAddresses, ethAddr) + } + + return &decodedAddresses, nil + +} + // matchFilterCriteria checks if a trace matches the filter criteria. -func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria) bool { +func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria, fromDecodedAddresses *[]ethtypes.EthAddress, toDecodedAddresses *[]ethtypes.EthAddress) bool { action, ok := trace.Action.(*ethtypes.EthCallTraceAction) if !ok { return false } // Match FromAddress - if filter.FromAddress != nil && len(*filter.FromAddress) > 0 { + if fromDecodedAddresses != nil && len(*fromDecodedAddresses) > 0 { fromMatch := false - for _, addr := range *filter.FromAddress { - ethAddr, err := ethtypes.ParseEthAddress(addr) - if err != nil { - continue - } + for _, ethAddr := range *fromDecodedAddresses { if action.From == ethAddr { fromMatch = true break @@ -1139,13 +1162,9 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace } // Match ToAddress - if filter.ToAddress != nil && len(*filter.ToAddress) > 0 { + if toDecodedAddresses != nil && len(*toDecodedAddresses) > 0 { toMatch := false - for _, addr := range *filter.ToAddress { - ethAddr, err := ethtypes.ParseEthAddress(addr) - if err != nil { - continue - } + for _, ethAddr := range *toDecodedAddresses { if action.To == ethAddr { toMatch = true break From 9edb692f8f4d60ef68f9394c0dc46a63f48adc2f Mon Sep 17 00:00:00 2001 From: Mikers Date: Tue, 2 Jul 2024 14:57:46 -1000 Subject: [PATCH 13/42] bugfix for create trace and improve tests for trace filter --- gateway/proxy_eth.go | 12 ++++++--- itests/eth_transactions_test.go | 12 +++++++-- node/impl/full/eth.go | 48 +++++++++++++++++++++++++-------- 3 files changed, 55 insertions(+), 17 deletions(-) diff --git a/gateway/proxy_eth.go b/gateway/proxy_eth.go index a01c257b6ac..f9ad9448a85 100644 --- a/gateway/proxy_eth.go +++ b/gateway/proxy_eth.go @@ -639,12 +639,16 @@ func (gw *Node) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilt return nil, err } - if err := gw.checkBlkParam(ctx, filter.ToBlock, 0); err != nil { - return nil, err + if filter.ToBlock != nil { + if err := gw.checkBlkParam(ctx, *filter.ToBlock, 0); err != nil { + return nil, err + } } - if err := gw.checkBlkParam(ctx, filter.FromBlock, 0); err != nil { - return nil, err + if filter.FromBlock != nil { + if err := gw.checkBlkParam(ctx, *filter.FromBlock, 0); err != nil { + return nil, err + } } return gw.target.EthTraceFilter(ctx, filter) diff --git a/itests/eth_transactions_test.go b/itests/eth_transactions_test.go index b975e243541..3633cdd65f9 100644 --- a/itests/eth_transactions_test.go +++ b/itests/eth_transactions_test.go @@ -655,9 +655,11 @@ func TestTraceFilter(t *testing.T) { defer cancel() // Define filter criteria + fromBlock := "0x1" + toBlock := "latest" filter := ethtypes.EthTraceFilterCriteria{ - FromBlock: "0x1", - ToBlock: "latest", + FromBlock: &fromBlock, + ToBlock: &toBlock, } // Example of creating and submitting a transaction @@ -688,4 +690,10 @@ func TestTraceFilter(t *testing.T) { require.NoError(t, err) require.NotNil(t, traces) require.NotEmpty(t, traces) + + //our transaction will be in the third element of traces at block 8 with the expected hash + require.EqualValues(t, traces[2].BlockNumber, 8) + require.EqualValues(t, traces[2].TransactionPosition, 1) + require.EqualValues(t, traces[2].TransactionHash, hash) + } diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 22009219176..a39564cc635 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1080,14 +1080,21 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace traceCounter := 0 - fromDecodedAddresses, fromErr := decodeAddressFilter(filter.FromAddress) - if fromErr != nil { - return nil, xerrors.Errorf("cannot decode FromAddress: %w", fromErr) + var fromDecodedAddresses *[]ethtypes.EthAddress + var toDecodedAddresses *[]ethtypes.EthAddress + + if filter.FromAddress != nil { + fromDecodedAddresses, err = decodeAddressFilter(filter.FromAddress) + if err != nil { + return nil, xerrors.Errorf("cannot decode FromAddress: %w", err) + } } - toDecodedAddresses, toErr := decodeAddressFilter(filter.ToAddress) - if toErr != nil { - return nil, xerrors.Errorf("cannot decode ToAddress: %w", toErr) + if filter.ToAddress != nil { + toDecodedAddresses, err = decodeAddressFilter(filter.ToAddress) + if err != nil { + return nil, xerrors.Errorf("cannot decode ToAddress: %w", err) + } } for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { @@ -1099,7 +1106,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace for _, blockTrace := range blockTraces { if matchFilterCriteria(blockTrace, filter, fromDecodedAddresses, toDecodedAddresses) { traceCounter++ - if traceCounter <= *filter.After { + if filter.After != nil && traceCounter <= *filter.After { continue } @@ -1142,16 +1149,35 @@ func decodeAddressFilter(addresses *[]string) (*[]ethtypes.EthAddress, error) { // matchFilterCriteria checks if a trace matches the filter criteria. func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria, fromDecodedAddresses *[]ethtypes.EthAddress, toDecodedAddresses *[]ethtypes.EthAddress) bool { + var actionTo ethtypes.EthAddress + var actionFrom ethtypes.EthAddress action, ok := trace.Action.(*ethtypes.EthCallTraceAction) - if !ok { - return false + if ok { + actionTo = action.To + actionFrom = action.From + } else { + actionCreate, okCreate := trace.Action.(*ethtypes.EthCreateTraceAction) + if okCreate { + //actionTo = actionCreate.To + actionFrom = actionCreate.From + resultCreate, okResult := trace.Action.(*ethtypes.EthCreateTraceResult) + if okResult { + if resultCreate.Address != nil { + actionTo = *resultCreate.Address + } + } else { + return false + } + } else { + return false + } } // Match FromAddress if fromDecodedAddresses != nil && len(*fromDecodedAddresses) > 0 { fromMatch := false for _, ethAddr := range *fromDecodedAddresses { - if action.From == ethAddr { + if actionFrom == ethAddr { fromMatch = true break } @@ -1165,7 +1191,7 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace if toDecodedAddresses != nil && len(*toDecodedAddresses) > 0 { toMatch := false for _, ethAddr := range *toDecodedAddresses { - if action.To == ethAddr { + if actionTo == ethAddr { toMatch = true break } From f2f545867d5ec07188e9a1eb264663bb76231fd8 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 3 Jul 2024 14:48:53 -1000 Subject: [PATCH 14/42] Update node/impl/full/eth.go Co-authored-by: Rod Vagg --- node/impl/full/eth.go | 1 - 1 file changed, 1 deletion(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index a39564cc635..367c39e69e6 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1158,7 +1158,6 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace } else { actionCreate, okCreate := trace.Action.(*ethtypes.EthCreateTraceAction) if okCreate { - //actionTo = actionCreate.To actionFrom = actionCreate.From resultCreate, okResult := trace.Action.(*ethtypes.EthCreateTraceResult) if okResult { From 4344a529e0f526bb8479cc9d2cc2b46584036598 Mon Sep 17 00:00:00 2001 From: Michael Seiler Date: Wed, 3 Jul 2024 16:04:12 -1000 Subject: [PATCH 15/42] fix for create type eth trace filter and improve tests --- itests/eth_transactions_test.go | 77 +++++++++++++++++++++++++++++---- node/impl/full/eth.go | 64 +++++++++++++++------------ 2 files changed, 105 insertions(+), 36 deletions(-) diff --git a/itests/eth_transactions_test.go b/itests/eth_transactions_test.go index 3633cdd65f9..69ac555a5c0 100644 --- a/itests/eth_transactions_test.go +++ b/itests/eth_transactions_test.go @@ -4,6 +4,7 @@ import ( "context" "encoding/hex" "encoding/json" + "fmt" "os" "testing" "time" @@ -653,15 +654,6 @@ func TestTraceFilter(t *testing.T) { ctx, cancel := context.WithTimeout(context.Background(), time.Minute) defer cancel() - - // Define filter criteria - fromBlock := "0x1" - toBlock := "latest" - filter := ethtypes.EthTraceFilterCriteria{ - FromBlock: &fromBlock, - ToBlock: &toBlock, - } - // Example of creating and submitting a transaction // Replace with actual test setup as needed contractHex, err := os.ReadFile("./contracts/SimpleCoin.hex") @@ -685,15 +677,82 @@ func TestTraceFilter(t *testing.T) { require.NotNil(t, receipt) require.EqualValues(t, ethtypes.EthUint64(0x1), receipt.Status) + // Get contract address. + contractAddr := client.EVM().ComputeContractAddress(ethAddr, 0) + + // get trace and verify values + tracesx, err := client.EthTraceTransaction(ctx, hash.String()) + require.NoError(t, err) + require.NotNil(t, tracesx) + require.EqualValues(t, tracesx[0].TransactionHash, hash) + require.EqualValues(t, tracesx[0].BlockNumber, receipt.BlockNumber) + + // Define filter criteria + fromBlock := "0x1" + toBlock := fmt.Sprint(receipt.BlockNumber) + filter := ethtypes.EthTraceFilterCriteria{ + FromBlock: &fromBlock, + ToBlock: &toBlock, + } + // Trace filter should find the transaction traces, err := client.EthTraceFilter(ctx, filter) require.NoError(t, err) require.NotNil(t, traces) require.NotEmpty(t, traces) + // Assert that iniital transactions returned by the trace are valid + require.EqualValues(t, len(traces), 3) + require.EqualValues(t, traces[0].BlockNumber, 1) + require.EqualValues(t, traces[0].TransactionPosition, 1) + require.EqualValues(t, traces[0].EthTrace.Type, "call") + require.EqualValues(t, traces[1].TransactionPosition, 1) + require.EqualValues(t, traces[1].EthTrace.Type, "call") + //our transaction will be in the third element of traces at block 8 with the expected hash require.EqualValues(t, traces[2].BlockNumber, 8) require.EqualValues(t, traces[2].TransactionPosition, 1) require.EqualValues(t, traces[2].TransactionHash, hash) + require.EqualValues(t, traces[2].EthTrace.Type, "create") + + toBlock = "latest" + filter = ethtypes.EthTraceFilterCriteria{ + FromBlock: &fromBlock, + ToBlock: &toBlock, + FromAddress: &[]string{ethAddr.String()}, + ToAddress: &[]string{contractAddr.String()}, + } + + // Trace filter should find the transaction + tracesAddressFilter, err := client.EthTraceFilter(ctx, filter) + require.NoError(t, err) + require.NotNil(t, tracesAddressFilter) + require.NotEmpty(t, tracesAddressFilter) + + //we should only get our contract deploy transaction + require.EqualValues(t, len(tracesAddressFilter), 1) + require.EqualValues(t, tracesAddressFilter[0].BlockNumber, 8) + require.EqualValues(t, tracesAddressFilter[0].TransactionPosition, 1) + require.EqualValues(t, tracesAddressFilter[0].TransactionHash, hash) + require.EqualValues(t, tracesAddressFilter[0].EthTrace.Type, "create") + + after := 1 + count := 2 + filter = ethtypes.EthTraceFilterCriteria{ + FromBlock: &fromBlock, + ToBlock: &toBlock, + After: &after, + Count: &count, + } + // Trace filter should find the transaction + tracesAfterCount, err := client.EthTraceFilter(ctx, filter) + require.NoError(t, err) + require.NotNil(t, traces) + require.NotEmpty(t, traces) + + //we should only get the last two results from the first trace query + require.EqualValues(t, len(tracesAfterCount), 2) + require.EqualValues(t, tracesAfterCount[0].TransactionHash, traces[1].TransactionHash) + require.EqualValues(t, tracesAfterCount[1].TransactionHash, traces[2].TransactionHash) } diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 367c39e69e6..8f26be410c7 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1104,7 +1104,11 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace } for _, blockTrace := range blockTraces { - if matchFilterCriteria(blockTrace, filter, fromDecodedAddresses, toDecodedAddresses) { + match, err := matchFilterCriteria(blockTrace, filter, fromDecodedAddresses, toDecodedAddresses) + if err != nil { + return nil, xerrors.Errorf("cannot match filter for block %d: %w", blkNum, err) + } + if match { traceCounter++ if filter.After != nil && traceCounter <= *filter.After { continue @@ -1148,41 +1152,47 @@ func decodeAddressFilter(addresses *[]string) (*[]ethtypes.EthAddress, error) { } // matchFilterCriteria checks if a trace matches the filter criteria. -func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria, fromDecodedAddresses *[]ethtypes.EthAddress, toDecodedAddresses *[]ethtypes.EthAddress) bool { - var actionTo ethtypes.EthAddress - var actionFrom ethtypes.EthAddress - action, ok := trace.Action.(*ethtypes.EthCallTraceAction) - if ok { - actionTo = action.To - actionFrom = action.From - } else { - actionCreate, okCreate := trace.Action.(*ethtypes.EthCreateTraceAction) - if okCreate { - actionFrom = actionCreate.From - resultCreate, okResult := trace.Action.(*ethtypes.EthCreateTraceResult) - if okResult { - if resultCreate.Address != nil { - actionTo = *resultCreate.Address - } - } else { - return false - } - } else { - return false +func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria, fromDecodedAddresses *[]ethtypes.EthAddress, toDecodedAddresses *[]ethtypes.EthAddress) (bool, error) { + + var traceTo ethtypes.EthAddress + var traceFrom ethtypes.EthAddress + + switch trace.Type { + case "call": + action, ok := trace.Action.(*ethtypes.EthCallTraceAction) + if !ok { + return false, xerrors.Errorf("invalid call trace action") } + traceTo = action.To + traceFrom = action.From + case "create": + result, okResult := trace.Result.(*ethtypes.EthCreateTraceResult) + if !okResult { + return false, xerrors.Errorf("invalid create trace result") + } + + action, okAction := trace.Action.(*ethtypes.EthCreateTraceAction) + if !okAction { + return false, xerrors.Errorf("invalid create trace action") + } + + traceTo = *result.Address + traceFrom = action.From + default: + return false, xerrors.Errorf("invalid trace type: %s", trace.Type) } // Match FromAddress if fromDecodedAddresses != nil && len(*fromDecodedAddresses) > 0 { fromMatch := false for _, ethAddr := range *fromDecodedAddresses { - if actionFrom == ethAddr { + if traceFrom == ethAddr { fromMatch = true break } } if !fromMatch { - return false + return false, nil } } @@ -1190,17 +1200,17 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace if toDecodedAddresses != nil && len(*toDecodedAddresses) > 0 { toMatch := false for _, ethAddr := range *toDecodedAddresses { - if actionTo == ethAddr { + if traceTo == ethAddr { toMatch = true break } } if !toMatch { - return false + return false, nil } } - return true + return true, nil } func (a *EthModule) applyMessage(ctx context.Context, msg *types.Message, tsk types.TipSetKey) (res *api.InvocResult, err error) { From 4bdd290e90f786614939b4b5b4fdb74317c0261b Mon Sep 17 00:00:00 2001 From: Michael Seiler Date: Wed, 3 Jul 2024 16:08:04 -1000 Subject: [PATCH 16/42] make gen --- documentation/en/api-v1-unstable-methods.md | 8584 ------------------- 1 file changed, 8584 deletions(-) diff --git a/documentation/en/api-v1-unstable-methods.md b/documentation/en/api-v1-unstable-methods.md index d3b12ad8b7e..e69de29bb2d 100644 --- a/documentation/en/api-v1-unstable-methods.md +++ b/documentation/en/api-v1-unstable-methods.md @@ -1,8584 +0,0 @@ -# Groups -* [](#) - * [Closing](#Closing) - * [Discover](#Discover) - * [Session](#Session) - * [Shutdown](#Shutdown) - * [Version](#Version) -* [Auth](#Auth) - * [AuthNew](#AuthNew) - * [AuthVerify](#AuthVerify) -* [Chain](#Chain) - * [ChainBlockstoreInfo](#ChainBlockstoreInfo) - * [ChainCheckBlockstore](#ChainCheckBlockstore) - * [ChainDeleteObj](#ChainDeleteObj) - * [ChainExport](#ChainExport) - * [ChainExportRangeInternal](#ChainExportRangeInternal) - * [ChainGetBlock](#ChainGetBlock) - * [ChainGetBlockMessages](#ChainGetBlockMessages) - * [ChainGetEvents](#ChainGetEvents) - * [ChainGetGenesis](#ChainGetGenesis) - * [ChainGetMessage](#ChainGetMessage) - * [ChainGetMessagesInTipset](#ChainGetMessagesInTipset) - * [ChainGetNode](#ChainGetNode) - * [ChainGetParentMessages](#ChainGetParentMessages) - * [ChainGetParentReceipts](#ChainGetParentReceipts) - * [ChainGetPath](#ChainGetPath) - * [ChainGetTipSet](#ChainGetTipSet) - * [ChainGetTipSetAfterHeight](#ChainGetTipSetAfterHeight) - * [ChainGetTipSetByHeight](#ChainGetTipSetByHeight) - * [ChainHasObj](#ChainHasObj) - * [ChainHead](#ChainHead) - * [ChainHotGC](#ChainHotGC) - * [ChainNotify](#ChainNotify) - * [ChainPrune](#ChainPrune) - * [ChainPutObj](#ChainPutObj) - * [ChainReadObj](#ChainReadObj) - * [ChainSetHead](#ChainSetHead) - * [ChainStatObj](#ChainStatObj) - * [ChainTipSetWeight](#ChainTipSetWeight) -* [Create](#Create) - * [CreateBackup](#CreateBackup) -* [Eth](#Eth) - * [EthAccounts](#EthAccounts) - * [EthAddressToFilecoinAddress](#EthAddressToFilecoinAddress) - * [EthBlockNumber](#EthBlockNumber) - * [EthCall](#EthCall) - * [EthChainId](#EthChainId) - * [EthEstimateGas](#EthEstimateGas) - * [EthFeeHistory](#EthFeeHistory) - * [EthGasPrice](#EthGasPrice) - * [EthGetBalance](#EthGetBalance) - * [EthGetBlockByHash](#EthGetBlockByHash) - * [EthGetBlockByNumber](#EthGetBlockByNumber) - * [EthGetBlockTransactionCountByHash](#EthGetBlockTransactionCountByHash) - * [EthGetBlockTransactionCountByNumber](#EthGetBlockTransactionCountByNumber) - * [EthGetCode](#EthGetCode) - * [EthGetFilterChanges](#EthGetFilterChanges) - * [EthGetFilterLogs](#EthGetFilterLogs) - * [EthGetLogs](#EthGetLogs) - * [EthGetMessageCidByTransactionHash](#EthGetMessageCidByTransactionHash) - * [EthGetStorageAt](#EthGetStorageAt) - * [EthGetTransactionByBlockHashAndIndex](#EthGetTransactionByBlockHashAndIndex) - * [EthGetTransactionByBlockNumberAndIndex](#EthGetTransactionByBlockNumberAndIndex) - * [EthGetTransactionByHash](#EthGetTransactionByHash) - * [EthGetTransactionByHashLimited](#EthGetTransactionByHashLimited) - * [EthGetTransactionCount](#EthGetTransactionCount) - * [EthGetTransactionHashByCid](#EthGetTransactionHashByCid) - * [EthGetTransactionReceipt](#EthGetTransactionReceipt) - * [EthGetTransactionReceiptLimited](#EthGetTransactionReceiptLimited) - * [EthMaxPriorityFeePerGas](#EthMaxPriorityFeePerGas) - * [EthNewBlockFilter](#EthNewBlockFilter) - * [EthNewFilter](#EthNewFilter) - * [EthNewPendingTransactionFilter](#EthNewPendingTransactionFilter) - * [EthProtocolVersion](#EthProtocolVersion) - * [EthSendRawTransaction](#EthSendRawTransaction) - * [EthSubscribe](#EthSubscribe) - * [EthSyncing](#EthSyncing) - * [EthTraceBlock](#EthTraceBlock) - * [EthTraceFilter](#EthTraceFilter) - * [EthTraceReplayBlockTransactions](#EthTraceReplayBlockTransactions) - * [EthTraceTransaction](#EthTraceTransaction) - * [EthUninstallFilter](#EthUninstallFilter) - * [EthUnsubscribe](#EthUnsubscribe) -* [F3](#F3) - * [F3GetCertificate](#F3GetCertificate) - * [F3GetLatestCertificate](#F3GetLatestCertificate) - * [F3Participate](#F3Participate) -* [Filecoin](#Filecoin) - * [FilecoinAddressToEthAddress](#FilecoinAddressToEthAddress) -* [Gas](#Gas) - * [GasEstimateFeeCap](#GasEstimateFeeCap) - * [GasEstimateGasLimit](#GasEstimateGasLimit) - * [GasEstimateGasPremium](#GasEstimateGasPremium) - * [GasEstimateMessageGas](#GasEstimateMessageGas) -* [Get](#Get) - * [GetActorEventsRaw](#GetActorEventsRaw) -* [I](#I) - * [ID](#ID) -* [Log](#Log) - * [LogAlerts](#LogAlerts) - * [LogList](#LogList) - * [LogSetLevel](#LogSetLevel) -* [Market](#Market) - * [MarketAddBalance](#MarketAddBalance) - * [MarketGetReserved](#MarketGetReserved) - * [MarketReleaseFunds](#MarketReleaseFunds) - * [MarketReserveFunds](#MarketReserveFunds) - * [MarketWithdraw](#MarketWithdraw) -* [Miner](#Miner) - * [MinerCreateBlock](#MinerCreateBlock) - * [MinerGetBaseInfo](#MinerGetBaseInfo) -* [Mpool](#Mpool) - * [MpoolBatchPush](#MpoolBatchPush) - * [MpoolBatchPushMessage](#MpoolBatchPushMessage) - * [MpoolBatchPushUntrusted](#MpoolBatchPushUntrusted) - * [MpoolCheckMessages](#MpoolCheckMessages) - * [MpoolCheckPendingMessages](#MpoolCheckPendingMessages) - * [MpoolCheckReplaceMessages](#MpoolCheckReplaceMessages) - * [MpoolClear](#MpoolClear) - * [MpoolGetConfig](#MpoolGetConfig) - * [MpoolGetNonce](#MpoolGetNonce) - * [MpoolPending](#MpoolPending) - * [MpoolPush](#MpoolPush) - * [MpoolPushMessage](#MpoolPushMessage) - * [MpoolPushUntrusted](#MpoolPushUntrusted) - * [MpoolSelect](#MpoolSelect) - * [MpoolSetConfig](#MpoolSetConfig) - * [MpoolSub](#MpoolSub) -* [Msig](#Msig) - * [MsigAddApprove](#MsigAddApprove) - * [MsigAddCancel](#MsigAddCancel) - * [MsigAddPropose](#MsigAddPropose) - * [MsigApprove](#MsigApprove) - * [MsigApproveTxnHash](#MsigApproveTxnHash) - * [MsigCancel](#MsigCancel) - * [MsigCancelTxnHash](#MsigCancelTxnHash) - * [MsigCreate](#MsigCreate) - * [MsigGetAvailableBalance](#MsigGetAvailableBalance) - * [MsigGetPending](#MsigGetPending) - * [MsigGetVested](#MsigGetVested) - * [MsigGetVestingSchedule](#MsigGetVestingSchedule) - * [MsigPropose](#MsigPropose) - * [MsigRemoveSigner](#MsigRemoveSigner) - * [MsigSwapApprove](#MsigSwapApprove) - * [MsigSwapCancel](#MsigSwapCancel) - * [MsigSwapPropose](#MsigSwapPropose) -* [Net](#Net) - * [NetAddrsListen](#NetAddrsListen) - * [NetAgentVersion](#NetAgentVersion) - * [NetAutoNatStatus](#NetAutoNatStatus) - * [NetBandwidthStats](#NetBandwidthStats) - * [NetBandwidthStatsByPeer](#NetBandwidthStatsByPeer) - * [NetBandwidthStatsByProtocol](#NetBandwidthStatsByProtocol) - * [NetBlockAdd](#NetBlockAdd) - * [NetBlockList](#NetBlockList) - * [NetBlockRemove](#NetBlockRemove) - * [NetConnect](#NetConnect) - * [NetConnectedness](#NetConnectedness) - * [NetDisconnect](#NetDisconnect) - * [NetFindPeer](#NetFindPeer) - * [NetLimit](#NetLimit) - * [NetListening](#NetListening) - * [NetPeerInfo](#NetPeerInfo) - * [NetPeers](#NetPeers) - * [NetPing](#NetPing) - * [NetProtectAdd](#NetProtectAdd) - * [NetProtectList](#NetProtectList) - * [NetProtectRemove](#NetProtectRemove) - * [NetPubsubScores](#NetPubsubScores) - * [NetSetLimit](#NetSetLimit) - * [NetStat](#NetStat) - * [NetVersion](#NetVersion) -* [Node](#Node) - * [NodeStatus](#NodeStatus) -* [Paych](#Paych) - * [PaychAllocateLane](#PaychAllocateLane) - * [PaychAvailableFunds](#PaychAvailableFunds) - * [PaychAvailableFundsByFromTo](#PaychAvailableFundsByFromTo) - * [PaychCollect](#PaychCollect) - * [PaychFund](#PaychFund) - * [PaychGet](#PaychGet) - * [PaychGetWaitReady](#PaychGetWaitReady) - * [PaychList](#PaychList) - * [PaychNewPayment](#PaychNewPayment) - * [PaychSettle](#PaychSettle) - * [PaychStatus](#PaychStatus) - * [PaychVoucherAdd](#PaychVoucherAdd) - * [PaychVoucherCheckSpendable](#PaychVoucherCheckSpendable) - * [PaychVoucherCheckValid](#PaychVoucherCheckValid) - * [PaychVoucherCreate](#PaychVoucherCreate) - * [PaychVoucherList](#PaychVoucherList) - * [PaychVoucherSubmit](#PaychVoucherSubmit) -* [Start](#Start) - * [StartTime](#StartTime) -* [State](#State) - * [StateAccountKey](#StateAccountKey) - * [StateActorCodeCIDs](#StateActorCodeCIDs) - * [StateActorManifestCID](#StateActorManifestCID) - * [StateAllMinerFaults](#StateAllMinerFaults) - * [StateCall](#StateCall) - * [StateChangedActors](#StateChangedActors) - * [StateCirculatingSupply](#StateCirculatingSupply) - * [StateCompute](#StateCompute) - * [StateComputeDataCID](#StateComputeDataCID) - * [StateDealProviderCollateralBounds](#StateDealProviderCollateralBounds) - * [StateDecodeParams](#StateDecodeParams) - * [StateEncodeParams](#StateEncodeParams) - * [StateGetActor](#StateGetActor) - * [StateGetAllAllocations](#StateGetAllAllocations) - * [StateGetAllClaims](#StateGetAllClaims) - * [StateGetAllocation](#StateGetAllocation) - * [StateGetAllocationForPendingDeal](#StateGetAllocationForPendingDeal) - * [StateGetAllocationIdForPendingDeal](#StateGetAllocationIdForPendingDeal) - * [StateGetAllocations](#StateGetAllocations) - * [StateGetBeaconEntry](#StateGetBeaconEntry) - * [StateGetClaim](#StateGetClaim) - * [StateGetClaims](#StateGetClaims) - * [StateGetNetworkParams](#StateGetNetworkParams) - * [StateGetRandomnessDigestFromBeacon](#StateGetRandomnessDigestFromBeacon) - * [StateGetRandomnessDigestFromTickets](#StateGetRandomnessDigestFromTickets) - * [StateGetRandomnessFromBeacon](#StateGetRandomnessFromBeacon) - * [StateGetRandomnessFromTickets](#StateGetRandomnessFromTickets) - * [StateListActors](#StateListActors) - * [StateListMessages](#StateListMessages) - * [StateListMiners](#StateListMiners) - * [StateLookupID](#StateLookupID) - * [StateLookupRobustAddress](#StateLookupRobustAddress) - * [StateMarketBalance](#StateMarketBalance) - * [StateMarketDeals](#StateMarketDeals) - * [StateMarketParticipants](#StateMarketParticipants) - * [StateMarketStorageDeal](#StateMarketStorageDeal) - * [StateMinerActiveSectors](#StateMinerActiveSectors) - * [StateMinerAllocated](#StateMinerAllocated) - * [StateMinerAvailableBalance](#StateMinerAvailableBalance) - * [StateMinerDeadlines](#StateMinerDeadlines) - * [StateMinerFaults](#StateMinerFaults) - * [StateMinerInfo](#StateMinerInfo) - * [StateMinerInitialPledgeCollateral](#StateMinerInitialPledgeCollateral) - * [StateMinerPartitions](#StateMinerPartitions) - * [StateMinerPower](#StateMinerPower) - * [StateMinerPreCommitDepositForPower](#StateMinerPreCommitDepositForPower) - * [StateMinerProvingDeadline](#StateMinerProvingDeadline) - * [StateMinerRecoveries](#StateMinerRecoveries) - * [StateMinerSectorAllocated](#StateMinerSectorAllocated) - * [StateMinerSectorCount](#StateMinerSectorCount) - * [StateMinerSectors](#StateMinerSectors) - * [StateNetworkName](#StateNetworkName) - * [StateNetworkVersion](#StateNetworkVersion) - * [StateReadState](#StateReadState) - * [StateReplay](#StateReplay) - * [StateSearchMsg](#StateSearchMsg) - * [StateSectorExpiration](#StateSectorExpiration) - * [StateSectorGetInfo](#StateSectorGetInfo) - * [StateSectorPartition](#StateSectorPartition) - * [StateSectorPreCommitInfo](#StateSectorPreCommitInfo) - * [StateVMCirculatingSupplyInternal](#StateVMCirculatingSupplyInternal) - * [StateVerifiedClientStatus](#StateVerifiedClientStatus) - * [StateVerifiedRegistryRootKey](#StateVerifiedRegistryRootKey) - * [StateVerifierStatus](#StateVerifierStatus) - * [StateWaitMsg](#StateWaitMsg) -* [Subscribe](#Subscribe) - * [SubscribeActorEventsRaw](#SubscribeActorEventsRaw) -* [Sync](#Sync) - * [SyncCheckBad](#SyncCheckBad) - * [SyncCheckpoint](#SyncCheckpoint) - * [SyncIncomingBlocks](#SyncIncomingBlocks) - * [SyncMarkBad](#SyncMarkBad) - * [SyncState](#SyncState) - * [SyncSubmitBlock](#SyncSubmitBlock) - * [SyncUnmarkAllBad](#SyncUnmarkAllBad) - * [SyncUnmarkBad](#SyncUnmarkBad) - * [SyncValidateTipset](#SyncValidateTipset) -* [Wallet](#Wallet) - * [WalletBalance](#WalletBalance) - * [WalletDefaultAddress](#WalletDefaultAddress) - * [WalletDelete](#WalletDelete) - * [WalletExport](#WalletExport) - * [WalletHas](#WalletHas) - * [WalletImport](#WalletImport) - * [WalletList](#WalletList) - * [WalletNew](#WalletNew) - * [WalletSetDefault](#WalletSetDefault) - * [WalletSign](#WalletSign) - * [WalletSignMessage](#WalletSignMessage) - * [WalletValidateAddress](#WalletValidateAddress) - * [WalletVerify](#WalletVerify) -* [Web3](#Web3) - * [Web3ClientVersion](#Web3ClientVersion) -## - - -### Closing - - -Perms: read - -Inputs: `null` - -Response: `{}` - -### Discover - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "info": { - "title": "Lotus RPC API", - "version": "1.2.1/generated=2020-11-22T08:22:42-06:00" - }, - "methods": [], - "openrpc": "1.2.6" -} -``` - -### Session - - -Perms: read - -Inputs: `null` - -Response: `"07070707-0707-0707-0707-070707070707"` - -### Shutdown - - -Perms: admin - -Inputs: `null` - -Response: `{}` - -### Version - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "Version": "string value", - "APIVersion": 131840, - "BlockDelay": 42 -} -``` - -## Auth - - -### AuthNew - - -Perms: admin - -Inputs: -```json -[ - [ - "write" - ] -] -``` - -Response: `"Ynl0ZSBhcnJheQ=="` - -### AuthVerify - - -Perms: read - -Inputs: -```json -[ - "string value" -] -``` - -Response: -```json -[ - "write" -] -``` - -## Chain -The Chain method group contains methods for interacting with the -blockchain, but that do not require any form of state computation. - - -### ChainBlockstoreInfo -ChainBlockstoreInfo returns some basic information about the blockstore - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "abc": 123 -} -``` - -### ChainCheckBlockstore -ChainCheckBlockstore performs an (asynchronous) health check on the chain/state blockstore -if supported by the underlying implementation. - - -Perms: admin - -Inputs: `null` - -Response: `{}` - -### ChainDeleteObj -ChainDeleteObj deletes node referenced by the given CID - - -Perms: admin - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: `{}` - -### ChainExport -ChainExport returns a stream of bytes with CAR dump of chain data. -The exported chain data includes the header chain from the given tipset -back to genesis, the entire genesis state, and the most recent 'nroots' -state trees. -If oldmsgskip is set, messages from before the requested roots are also not included. - - -Perms: read - -Inputs: -```json -[ - 10101, - true, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"Ynl0ZSBhcnJheQ=="` - -### ChainExportRangeInternal -ChainExportRangeInternal triggers the export of a chain -CAR-snapshot directly to disk. It is similar to ChainExport, -except, depending on options, the snapshot can include receipts, -messages and stateroots for the length between the specified head -and tail, thus producing "archival-grade" snapshots that include -all the on-chain data. The header chain is included back to -genesis and these snapshots can be used to initialize Filecoin -nodes. - - -Perms: admin - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - { - "WriteBufferSize": 123, - "NumWorkers": 123, - "IncludeMessages": true, - "IncludeReceipts": true, - "IncludeStateRoots": true - } -] -``` - -Response: `{}` - -### ChainGetBlock -ChainGetBlock returns the block specified by the given CID. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -{ - "Miner": "f01234", - "Ticket": { - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "ElectionProof": { - "WinCount": 9, - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "BeaconEntries": [ - { - "Round": 42, - "Data": "Ynl0ZSBhcnJheQ==" - } - ], - "WinPoStProof": [ - { - "PoStProof": 8, - "ProofBytes": "Ynl0ZSBhcnJheQ==" - } - ], - "Parents": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ], - "ParentWeight": "0", - "Height": 10101, - "ParentStateRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "ParentMessageReceipts": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Messages": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "BLSAggregate": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Timestamp": 42, - "BlockSig": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "ForkSignaling": 42, - "ParentBaseFee": "0" -} -``` - -### ChainGetBlockMessages -ChainGetBlockMessages returns messages stored in the specified block. - -Note: If there are multiple blocks in a tipset, it's likely that some -messages will be duplicated. It's also possible for blocks in a tipset to have -different messages from the same sender at the same nonce. When that happens, -only the first message (in a block with lowest ticket) will be considered -for execution - -NOTE: THIS METHOD SHOULD ONLY BE USED FOR GETTING MESSAGES IN A SPECIFIC BLOCK - -DO NOT USE THIS METHOD TO GET MESSAGES INCLUDED IN A TIPSET -Use ChainGetParentMessages, which will perform correct message deduplication - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -{ - "BlsMessages": [ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - ], - "SecpkMessages": [ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - ], - "Cids": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ] -} -``` - -### ChainGetEvents -ChainGetEvents returns the events under an event AMT root CID. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -[ - { - "Emitter": 1000, - "Entries": [ - { - "Flags": 7, - "Key": "string value", - "Codec": 42, - "Value": "Ynl0ZSBhcnJheQ==" - } - ] - } -] -``` - -### ChainGetGenesis -ChainGetGenesis returns the genesis tipset. - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "Cids": null, - "Blocks": null, - "Height": 0 -} -``` - -### ChainGetMessage -ChainGetMessage reads a message referenced by the specified CID from the -chain blockstore. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -{ - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } -} -``` - -### ChainGetMessagesInTipset -ChainGetMessagesInTipset returns message stores in current tipset - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "Cid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - } -] -``` - -### ChainGetNode - - -Perms: read - -Inputs: -```json -[ - "string value" -] -``` - -Response: -```json -{ - "Cid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Obj": {} -} -``` - -### ChainGetParentMessages -ChainGetParentMessages returns messages stored in parent tipset of the -specified block. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -[ - { - "Cid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - } -] -``` - -### ChainGetParentReceipts -ChainGetParentReceipts returns receipts for messages in parent tipset of -the specified block. The receipts in the list returned is one-to-one with the -messages returned by a call to ChainGetParentMessages with the same blockCid. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -[ - { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "GasUsed": 9, - "EventsRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - } -] -``` - -### ChainGetPath -ChainGetPath returns a set of revert/apply operations needed to get from -one tipset to another, for example: -``` - to - ^ -from tAA - ^ ^ -tBA tAB - ^---*--^ - ^ - tRR -``` -Would return `[revert(tBA), apply(tAB), apply(tAA)]` - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "Type": "string value", - "Val": { - "Cids": null, - "Blocks": null, - "Height": 0 - } - } -] -``` - -### ChainGetTipSet -ChainGetTipSet returns the tipset specified by the given TipSetKey. - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Cids": null, - "Blocks": null, - "Height": 0 -} -``` - -### ChainGetTipSetAfterHeight -ChainGetTipSetAfterHeight looks back for a tipset at the specified epoch. -If there are no blocks at the specified epoch, the first non-nil tipset at a later epoch -will be returned. - - -Perms: read - -Inputs: -```json -[ - 10101, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Cids": null, - "Blocks": null, - "Height": 0 -} -``` - -### ChainGetTipSetByHeight -ChainGetTipSetByHeight looks back for a tipset at the specified epoch. -If there are no blocks at the specified epoch, a tipset at an earlier epoch -will be returned. - - -Perms: read - -Inputs: -```json -[ - 10101, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Cids": null, - "Blocks": null, - "Height": 0 -} -``` - -### ChainHasObj -ChainHasObj checks if a given CID exists in the chain blockstore. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: `true` - -### ChainHead -ChainHead returns the current head of the chain. - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "Cids": null, - "Blocks": null, - "Height": 0 -} -``` - -### ChainHotGC -ChainHotGC does online (badger) GC on the hot store; only supported if you are using -the splitstore - - -Perms: admin - -Inputs: -```json -[ - { - "Threshold": 12.3, - "Periodic": true, - "Moving": true - } -] -``` - -Response: `{}` - -### ChainNotify -ChainNotify returns channel with chain head updates. -First message is guaranteed to be of len == 1, and type == 'current'. - - -Perms: read - -Inputs: `null` - -Response: -```json -[ - { - "Type": "string value", - "Val": { - "Cids": null, - "Blocks": null, - "Height": 0 - } - } -] -``` - -### ChainPrune -ChainPrune forces compaction on cold store and garbage collects; only supported if you -are using the splitstore - - -Perms: admin - -Inputs: -```json -[ - { - "MovingGC": true, - "RetainState": 9 - } -] -``` - -Response: `{}` - -### ChainPutObj -ChainPutObj puts a given object into the block store - - -Perms: admin - -Inputs: -```json -[ - {} -] -``` - -Response: `{}` - -### ChainReadObj -ChainReadObj reads ipld nodes referenced by the specified CID from chain -blockstore and returns raw bytes. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: `"Ynl0ZSBhcnJheQ=="` - -### ChainSetHead -ChainSetHead forcefully sets current chain head. Use with caution. - - -Perms: admin - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `{}` - -### ChainStatObj -ChainStatObj returns statistics about the graph referenced by 'obj'. -If 'base' is also specified, then the returned stat will be a diff -between the two objects. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -{ - "Size": 42, - "Links": 42 -} -``` - -### ChainTipSetWeight -ChainTipSetWeight computes weight for the specified tipset. - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -## Create - - -### CreateBackup -CreateBackup creates node backup onder the specified file name. The -method requires that the lotus daemon is running with the -LOTUS_BACKUP_BASE_PATH environment variable set to some path, and that -the path specified when calling CreateBackup is within the base path - - -Perms: admin - -Inputs: -```json -[ - "string value" -] -``` - -Response: `{}` - -## Eth -These methods are used for Ethereum-compatible JSON-RPC calls - -EthAccounts will always return [] since we don't expect Lotus to manage private keys - - -### EthAccounts -There are not yet any comments for this method. - -Perms: read - -Inputs: `null` - -Response: -```json -[ - "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" -] -``` - -### EthAddressToFilecoinAddress -EthAddressToFilecoinAddress converts an EthAddress into an f410 Filecoin Address - - -Perms: read - -Inputs: -```json -[ - "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" -] -``` - -Response: `"f01234"` - -### EthBlockNumber -EthBlockNumber returns the height of the latest (heaviest) TipSet - - -Perms: read - -Inputs: `null` - -Response: `"0x5"` - -### EthCall - - -Perms: read - -Inputs: -```json -[ - { - "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "gas": "0x5", - "gasPrice": "0x0", - "value": "0x0", - "data": "0x07" - }, - "string value" -] -``` - -Response: `"0x07"` - -### EthChainId - - -Perms: read - -Inputs: `null` - -Response: `"0x5"` - -### EthEstimateGas - - -Perms: read - -Inputs: -```json -[ - "Bw==" -] -``` - -Response: `"0x5"` - -### EthFeeHistory - - -Perms: read - -Inputs: -```json -[ - "Bw==" -] -``` - -Response: -```json -{ - "oldestBlock": "0x5", - "baseFeePerGas": [ - "0x0" - ], - "gasUsedRatio": [ - 12.3 - ], - "reward": [] -} -``` - -### EthGasPrice - - -Perms: read - -Inputs: `null` - -Response: `"0x0"` - -### EthGetBalance - - -Perms: read - -Inputs: -```json -[ - "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "string value" -] -``` - -Response: `"0x0"` - -### EthGetBlockByHash - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - true -] -``` - -Response: -```json -{ - "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "parentHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "sha3Uncles": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "miner": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "stateRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "transactionsRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "receiptsRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "logsBloom": "0x07", - "difficulty": "0x5", - "totalDifficulty": "0x5", - "number": "0x5", - "gasLimit": "0x5", - "gasUsed": "0x5", - "timestamp": "0x5", - "extraData": "0x07", - "mixHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "nonce": "0x0707070707070707", - "baseFeePerGas": "0x0", - "size": "0x5", - "transactions": [ - {} - ], - "uncles": [ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" - ] -} -``` - -### EthGetBlockByNumber - - -Perms: read - -Inputs: -```json -[ - "string value", - true -] -``` - -Response: -```json -{ - "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "parentHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "sha3Uncles": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "miner": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "stateRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "transactionsRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "receiptsRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "logsBloom": "0x07", - "difficulty": "0x5", - "totalDifficulty": "0x5", - "number": "0x5", - "gasLimit": "0x5", - "gasUsed": "0x5", - "timestamp": "0x5", - "extraData": "0x07", - "mixHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "nonce": "0x0707070707070707", - "baseFeePerGas": "0x0", - "size": "0x5", - "transactions": [ - {} - ], - "uncles": [ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" - ] -} -``` - -### EthGetBlockTransactionCountByHash -EthGetBlockTransactionCountByHash returns the number of messages in the TipSet - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" -] -``` - -Response: `"0x5"` - -### EthGetBlockTransactionCountByNumber -EthGetBlockTransactionCountByNumber returns the number of messages in the TipSet - - -Perms: read - -Inputs: -```json -[ - "0x5" -] -``` - -Response: `"0x5"` - -### EthGetCode - - -Perms: read - -Inputs: -```json -[ - "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "string value" -] -``` - -Response: `"0x07"` - -### EthGetFilterChanges -Polling method for a filter, returns event logs which occurred since last poll. -(requires write perm since timestamp of last filter execution will be written) - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" -] -``` - -Response: -```json -[ - {} -] -``` - -### EthGetFilterLogs -Returns event logs matching filter with given id. -(requires write perm since timestamp of last filter execution will be written) - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" -] -``` - -Response: -```json -[ - {} -] -``` - -### EthGetLogs -Returns event logs matching given filter spec. - - -Perms: read - -Inputs: -```json -[ - { - "fromBlock": "2301220", - "address": [ - "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" - ], - "topics": null - } -] -``` - -Response: -```json -[ - {} -] -``` - -### EthGetMessageCidByTransactionHash - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### EthGetStorageAt - - -Perms: read - -Inputs: -```json -[ - "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "0x07", - "string value" -] -``` - -Response: `"0x07"` - -### EthGetTransactionByBlockHashAndIndex - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "0x5" -] -``` - -Response: -```json -{ - "chainId": "0x5", - "nonce": "0x5", - "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": "0x5", - "transactionIndex": "0x5", - "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "value": "0x0", - "type": "0x5", - "input": "0x07", - "gas": "0x5", - "maxFeePerGas": "0x0", - "maxPriorityFeePerGas": "0x0", - "gasPrice": "0x0", - "accessList": [ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" - ], - "v": "0x0", - "r": "0x0", - "s": "0x0" -} -``` - -### EthGetTransactionByBlockNumberAndIndex - - -Perms: read - -Inputs: -```json -[ - "0x5", - "0x5" -] -``` - -Response: -```json -{ - "chainId": "0x5", - "nonce": "0x5", - "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": "0x5", - "transactionIndex": "0x5", - "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "value": "0x0", - "type": "0x5", - "input": "0x07", - "gas": "0x5", - "maxFeePerGas": "0x0", - "maxPriorityFeePerGas": "0x0", - "gasPrice": "0x0", - "accessList": [ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" - ], - "v": "0x0", - "r": "0x0", - "s": "0x0" -} -``` - -### EthGetTransactionByHash - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" -] -``` - -Response: -```json -{ - "chainId": "0x5", - "nonce": "0x5", - "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": "0x5", - "transactionIndex": "0x5", - "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "value": "0x0", - "type": "0x5", - "input": "0x07", - "gas": "0x5", - "maxFeePerGas": "0x0", - "maxPriorityFeePerGas": "0x0", - "gasPrice": "0x0", - "accessList": [ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" - ], - "v": "0x0", - "r": "0x0", - "s": "0x0" -} -``` - -### EthGetTransactionByHashLimited - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - 10101 -] -``` - -Response: -```json -{ - "chainId": "0x5", - "nonce": "0x5", - "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": "0x5", - "transactionIndex": "0x5", - "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "value": "0x0", - "type": "0x5", - "input": "0x07", - "gas": "0x5", - "maxFeePerGas": "0x0", - "maxPriorityFeePerGas": "0x0", - "gasPrice": "0x0", - "accessList": [ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" - ], - "v": "0x0", - "r": "0x0", - "s": "0x0" -} -``` - -### EthGetTransactionCount - - -Perms: read - -Inputs: -```json -[ - "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "string value" -] -``` - -Response: `"0x5"` - -### EthGetTransactionHashByCid - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` - -### EthGetTransactionReceipt - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" -] -``` - -Response: -```json -{ - "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "transactionIndex": "0x5", - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": "0x5", - "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "root": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "status": "0x5", - "contractAddress": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "cumulativeGasUsed": "0x5", - "gasUsed": "0x5", - "effectiveGasPrice": "0x0", - "logsBloom": "0x07", - "logs": [ - { - "address": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "data": "0x07", - "topics": [ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" - ], - "removed": true, - "logIndex": "0x5", - "transactionIndex": "0x5", - "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": "0x5" - } - ], - "type": "0x5" -} -``` - -### EthGetTransactionReceiptLimited - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - 10101 -] -``` - -Response: -```json -{ - "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "transactionIndex": "0x5", - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": "0x5", - "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "root": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "status": "0x5", - "contractAddress": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "cumulativeGasUsed": "0x5", - "gasUsed": "0x5", - "effectiveGasPrice": "0x0", - "logsBloom": "0x07", - "logs": [ - { - "address": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", - "data": "0x07", - "topics": [ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" - ], - "removed": true, - "logIndex": "0x5", - "transactionIndex": "0x5", - "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": "0x5" - } - ], - "type": "0x5" -} -``` - -### EthMaxPriorityFeePerGas - - -Perms: read - -Inputs: `null` - -Response: `"0x0"` - -### EthNewBlockFilter -Installs a persistent filter to notify when a new block arrives. - - -Perms: read - -Inputs: `null` - -Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` - -### EthNewFilter -Installs a persistent filter based on given filter spec. - - -Perms: read - -Inputs: -```json -[ - { - "fromBlock": "2301220", - "address": [ - "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" - ], - "topics": null - } -] -``` - -Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` - -### EthNewPendingTransactionFilter -Installs a persistent filter to notify when new messages arrive in the message pool. - - -Perms: read - -Inputs: `null` - -Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` - -### EthProtocolVersion - - -Perms: read - -Inputs: `null` - -Response: `"0x5"` - -### EthSendRawTransaction - - -Perms: read - -Inputs: -```json -[ - "0x07" -] -``` - -Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` - -### EthSubscribe -Subscribe to different event types using websockets -eventTypes is one or more of: - - newHeads: notify when new blocks arrive. - - pendingTransactions: notify when new messages arrive in the message pool. - - logs: notify new event logs that match a criteria -params contains additional parameters used with the log event type -The client will receive a stream of EthSubscriptionResponse values until EthUnsubscribe is called. - - -Perms: read - -Inputs: -```json -[ - "Bw==" -] -``` - -Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` - -### EthSyncing - - -Perms: read - -Inputs: `null` - -Response: `false` - -### EthTraceBlock -Returns an OpenEthereum-compatible trace of the given block (implementing `trace_block`), -translating Filecoin semantics into Ethereum semantics and tracing both EVM and FVM calls. - -Features: - -- FVM actor create events, calls, etc. show up as if they were EVM smart contract events. -- Native FVM call inputs are ABI-encoded (Solidity ABI) as if they were calls to a - `handle_filecoin_method(uint64 method, uint64 codec, bytes params)` function - (where `codec` is the IPLD codec of `params`). -- Native FVM call outputs (return values) are ABI-encoded as `(uint32 exit_code, uint64 - codec, bytes output)` where `codec` is the IPLD codec of `output`. - -Limitations (for now): - -1. Block rewards are not included in the trace. -2. SELFDESTRUCT operations are not included in the trace. -3. EVM smart contract "create" events always specify `0xfe` as the "code" for newly created EVM smart contracts. - - -Perms: read - -Inputs: -```json -[ - "string value" -] -``` - -Response: -```json -[ - { - "type": "string value", - "error": "string value", - "subtraces": 123, - "traceAddress": [ - 123 - ], - "action": {}, - "result": {}, - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": 9, - "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "transactionPosition": 123 - } -] -``` - -### EthTraceFilter -Implements OpenEthereum-compatible API method trace_filter - - -Perms: read - -Inputs: -```json -[ - { - "fromBlock": "string value", - "toBlock": "string value", - "fromAddress": [ - "string value" - ], - "toAddress": [ - "string value" - ], - "after": 123, - "count": 123 - } -] -``` - -Response: -```json -[ - { - "type": "string value", - "error": "string value", - "subtraces": 123, - "traceAddress": [ - 123 - ], - "action": {}, - "result": {}, - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": 9, - "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "transactionPosition": 123 - } -] -``` - -### EthTraceReplayBlockTransactions -Replays all transactions in a block returning the requested traces for each transaction - - -Perms: read - -Inputs: -```json -[ - "string value", - [ - "string value" - ] -] -``` - -Response: -```json -[ - { - "output": "0x07", - "stateDiff": "string value", - "trace": [ - { - "type": "string value", - "error": "string value", - "subtraces": 123, - "traceAddress": [ - 123 - ], - "action": {}, - "result": {} - } - ], - "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "vmTrace": "string value" - } -] -``` - -### EthTraceTransaction -Implmements OpenEthereum-compatible API method trace_transaction - - -Perms: read - -Inputs: -```json -[ - "string value" -] -``` - -Response: -```json -[ - { - "type": "string value", - "error": "string value", - "subtraces": 123, - "traceAddress": [ - 123 - ], - "action": {}, - "result": {}, - "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "blockNumber": 9, - "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", - "transactionPosition": 123 - } -] -``` - -### EthUninstallFilter -Uninstalls a filter with given id. - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" -] -``` - -Response: `true` - -### EthUnsubscribe -Unsubscribe from a websocket subscription - - -Perms: read - -Inputs: -```json -[ - "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" -] -``` - -Response: `true` - -## F3 - - -### F3GetCertificate -F3GetCertificate returns a finality certificate at given instance number - - -Perms: read - -Inputs: -```json -[ - 42 -] -``` - -Response: -```json -{ - "GPBFTInstance": 0, - "ECChain": null, - "SupplementalData": { - "Commitments": [ - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0 - ], - "PowerTable": null - }, - "Signers": [ - 0 - ], - "Signature": null, - "PowerTableDelta": null -} -``` - -### F3GetLatestCertificate -F3GetLatestCertificate returns the latest finality certificate - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "GPBFTInstance": 0, - "ECChain": null, - "SupplementalData": { - "Commitments": [ - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0, - 0 - ], - "PowerTable": null - }, - "Signers": [ - 0 - ], - "Signature": null, - "PowerTableDelta": null -} -``` - -### F3Participate -F3Participate should be called by a miner node to participate in signing F3 consensus. -The address should be of type ID -The returned channel will never be closed by the F3 -If it is closed without the context being cancelled, the caller should retry. -The values returned on the channel will inform the caller about participation -Empty strings will be sent if participation succeeded, non-empty strings explain possible errors. - - -Perms: admin - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `"string value"` - -## Filecoin - - -### FilecoinAddressToEthAddress -FilecoinAddressToEthAddress converts an f410 or f0 Filecoin Address to an EthAddress - - -Perms: read - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `"0x5cbeecf99d3fdb3f25e309cc264f240bb0664031"` - -## Gas - - -### GasEstimateFeeCap -GasEstimateFeeCap estimates gas fee cap - - -Perms: read - -Inputs: -```json -[ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - 9, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### GasEstimateGasLimit -GasEstimateGasLimit estimates gas used by the message and returns it. -It fails if message fails to execute. - - -Perms: read - -Inputs: -```json -[ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `9` - -### GasEstimateGasPremium -GasEstimateGasPremium estimates what gas price should be used for a -message to have high likelihood of inclusion in `nblocksincl` epochs. - - -Perms: read - -Inputs: -```json -[ - 42, - "f01234", - 9, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### GasEstimateMessageGas -GasEstimateMessageGas estimates gas values for unset message gas fields - - -Perms: read - -Inputs: -```json -[ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - { - "MaxFee": "0", - "MsgUuid": "07070707-0707-0707-0707-070707070707", - "MaximizeFeeCap": true - }, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } -} -``` - -## Get - - -### GetActorEventsRaw -GetActorEventsRaw returns all user-programmed and built-in actor events that match the given -filter. -This is a request/response API. -Results available from this API may be limited by the MaxFilterResults and MaxFilterHeightRange -configuration options and also the amount of historical data available in the node. - -This is an EXPERIMENTAL API and may be subject to change. - - -Perms: read - -Inputs: -```json -[ - { - "addresses": [ - "f01234" - ], - "fields": { - "abc": [ - { - "codec": 81, - "value": "ZGRhdGE=" - } - ] - }, - "fromHeight": 1010, - "toHeight": 1020 - } -] -``` - -Response: -```json -[ - { - "entries": [ - { - "Flags": 7, - "Key": "string value", - "Codec": 42, - "Value": "Ynl0ZSBhcnJheQ==" - } - ], - "emitter": "f01234", - "reverted": true, - "height": 10101, - "tipsetKey": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - "msgCid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - } -] -``` - -## I - - -### ID - - -Perms: read - -Inputs: `null` - -Response: `"12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf"` - -## Log - - -### LogAlerts - - -Perms: admin - -Inputs: `null` - -Response: -```json -[ - { - "Type": { - "System": "string value", - "Subsystem": "string value" - }, - "Active": true, - "LastActive": { - "Type": "string value", - "Message": "json raw message", - "Time": "0001-01-01T00:00:00Z" - }, - "LastResolved": { - "Type": "string value", - "Message": "json raw message", - "Time": "0001-01-01T00:00:00Z" - } - } -] -``` - -### LogList - - -Perms: write - -Inputs: `null` - -Response: -```json -[ - "string value" -] -``` - -### LogSetLevel - - -Perms: write - -Inputs: -```json -[ - "string value", - "string value" -] -``` - -Response: `{}` - -## Market - - -### MarketAddBalance -MarketAddBalance adds funds to the market actor - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "0" -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### MarketGetReserved -MarketGetReserved gets the amount of funds that are currently reserved for the address - - -Perms: sign - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `"0"` - -### MarketReleaseFunds -MarketReleaseFunds releases funds reserved by MarketReserveFunds - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "0" -] -``` - -Response: `{}` - -### MarketReserveFunds -MarketReserveFunds reserves funds for a deal - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "0" -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### MarketWithdraw -MarketWithdraw withdraws unlocked funds from the market actor - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "0" -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -## Miner - - -### MinerCreateBlock - - -Perms: write - -Inputs: -```json -[ - { - "Miner": "f01234", - "Parents": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - "Ticket": { - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "Eproof": { - "WinCount": 9, - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "BeaconValues": [ - { - "Round": 42, - "Data": "Ynl0ZSBhcnJheQ==" - } - ], - "Messages": [ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - ], - "Epoch": 10101, - "Timestamp": 42, - "WinningPoStProof": [ - { - "PoStProof": 8, - "ProofBytes": "Ynl0ZSBhcnJheQ==" - } - ] - } -] -``` - -Response: -```json -{ - "Header": { - "Miner": "f01234", - "Ticket": { - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "ElectionProof": { - "WinCount": 9, - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "BeaconEntries": [ - { - "Round": 42, - "Data": "Ynl0ZSBhcnJheQ==" - } - ], - "WinPoStProof": [ - { - "PoStProof": 8, - "ProofBytes": "Ynl0ZSBhcnJheQ==" - } - ], - "Parents": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ], - "ParentWeight": "0", - "Height": 10101, - "ParentStateRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "ParentMessageReceipts": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Messages": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "BLSAggregate": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Timestamp": 42, - "BlockSig": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "ForkSignaling": 42, - "ParentBaseFee": "0" - }, - "BlsMessages": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ], - "SecpkMessages": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ] -} -``` - -### MinerGetBaseInfo -There are not yet any comments for this method. - -Perms: read - -Inputs: -```json -[ - "f01234", - 10101, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "MinerPower": "0", - "NetworkPower": "0", - "Sectors": [ - { - "SealProof": 8, - "SectorNumber": 9, - "SectorKey": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "SealedCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - } - ], - "WorkerKey": "f01234", - "SectorSize": 34359738368, - "PrevBeaconEntry": { - "Round": 42, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "BeaconEntries": [ - { - "Round": 42, - "Data": "Ynl0ZSBhcnJheQ==" - } - ], - "EligibleForMining": true -} -``` - -## Mpool -The Mpool methods are for interacting with the message pool. The message pool -manages all incoming and outgoing 'messages' going over the network. - - -### MpoolBatchPush -MpoolBatchPush batch pushes a signed message to mempool. - - -Perms: write - -Inputs: -```json -[ - [ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - ] -] -``` - -Response: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -### MpoolBatchPushMessage -MpoolBatchPushMessage batch pushes a unsigned message to mempool. - - -Perms: sign - -Inputs: -```json -[ - [ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - ], - { - "MaxFee": "0", - "MsgUuid": "07070707-0707-0707-0707-070707070707", - "MaximizeFeeCap": true - } -] -``` - -Response: -```json -[ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } -] -``` - -### MpoolBatchPushUntrusted -MpoolBatchPushUntrusted batch pushes a signed message to mempool from untrusted sources. - - -Perms: write - -Inputs: -```json -[ - [ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - ] -] -``` - -Response: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -### MpoolCheckMessages -MpoolCheckMessages performs logical checks on a batch of messages - - -Perms: read - -Inputs: -```json -[ - [ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true - } - ] -] -``` - -Response: -```json -[ - [ - { - "Cid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Code": 0, - "OK": true, - "Err": "string value", - "Hint": { - "abc": 123 - } - } - ] -] -``` - -### MpoolCheckPendingMessages -MpoolCheckPendingMessages performs logical checks for all pending messages from a given address - - -Perms: read - -Inputs: -```json -[ - "f01234" -] -``` - -Response: -```json -[ - [ - { - "Cid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Code": 0, - "OK": true, - "Err": "string value", - "Hint": { - "abc": 123 - } - } - ] -] -``` - -### MpoolCheckReplaceMessages -MpoolCheckReplaceMessages performs logical checks on pending messages with replacement - - -Perms: read - -Inputs: -```json -[ - [ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - ] -] -``` - -Response: -```json -[ - [ - { - "Cid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Code": 0, - "OK": true, - "Err": "string value", - "Hint": { - "abc": 123 - } - } - ] -] -``` - -### MpoolClear -MpoolClear clears pending messages from the mpool. -If clearLocal is true, ALL messages will be cleared. -If clearLocal is false, local messages will be protected, all others will be cleared. - - -Perms: write - -Inputs: -```json -[ - true -] -``` - -Response: `{}` - -### MpoolGetConfig -MpoolGetConfig returns (a copy of) the current mpool config - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "PriorityAddrs": [ - "f01234" - ], - "SizeLimitHigh": 123, - "SizeLimitLow": 123, - "ReplaceByFeeRatio": 1.23, - "PruneCooldown": 60000000000, - "GasLimitOverestimation": 12.3 -} -``` - -### MpoolGetNonce -MpoolGetNonce gets next nonce for the specified sender. -Note that this method may not be atomic. Use MpoolPushMessage instead. - - -Perms: read - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `42` - -### MpoolPending -MpoolPending returns pending mempool messages. - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } -] -``` - -### MpoolPush -MpoolPush pushes a signed message to mempool. - - -Perms: write - -Inputs: -```json -[ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### MpoolPushMessage -MpoolPushMessage atomically assigns a nonce, signs, and pushes a message -to mempool. -maxFee is only used when GasFeeCap/GasPremium fields aren't specified - -When maxFee is set to 0, MpoolPushMessage will guess appropriate fee -based on current chain conditions - - -Perms: sign - -Inputs: -```json -[ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - { - "MaxFee": "0", - "MsgUuid": "07070707-0707-0707-0707-070707070707", - "MaximizeFeeCap": true - } -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } -} -``` - -### MpoolPushUntrusted -MpoolPushUntrusted pushes a signed message to mempool from untrusted sources. - - -Perms: write - -Inputs: -```json -[ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### MpoolSelect -MpoolSelect returns a list of pending messages for inclusion in the next block - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - 12.3 -] -``` - -Response: -```json -[ - { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } -] -``` - -### MpoolSetConfig -MpoolSetConfig sets the mpool config to (a copy of) the supplied config - - -Perms: admin - -Inputs: -```json -[ - { - "PriorityAddrs": [ - "f01234" - ], - "SizeLimitHigh": 123, - "SizeLimitLow": 123, - "ReplaceByFeeRatio": 1.23, - "PruneCooldown": 60000000000, - "GasLimitOverestimation": 12.3 - } -] -``` - -Response: `{}` - -### MpoolSub - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "Type": 0, - "Message": { - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } -} -``` - -## Msig -The Msig methods are used to interact with multisig wallets on the -filecoin network - - -### MsigAddApprove -MsigAddApprove approves a previously proposed AddSigner message -It takes the following params: , , , -, , - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - 42, - "f01234", - "f01234", - true -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigAddCancel -MsigAddCancel cancels a previously proposed AddSigner message -It takes the following params: , , , -, - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - 42, - "f01234", - true -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigAddPropose -MsigAddPropose proposes adding a signer in the multisig -It takes the following params: , , -, - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "f01234", - true -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigApprove -MsigApprove approves a previously-proposed multisig message by transaction ID -It takes the following params: , - - -Perms: sign - -Inputs: -```json -[ - "f01234", - 42, - "f01234" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigApproveTxnHash -MsigApproveTxnHash approves a previously-proposed multisig message, specified -using both transaction ID and a hash of the parameters used in the -proposal. This method of approval can be used to ensure you only approve -exactly the transaction you think you are. -It takes the following params: , , , , , -, , - - -Perms: sign - -Inputs: -```json -[ - "f01234", - 42, - "f01234", - "f01234", - "0", - "f01234", - 42, - "Ynl0ZSBhcnJheQ==" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigCancel -MsigCancel cancels a previously-proposed multisig message -It takes the following params: , - - -Perms: sign - -Inputs: -```json -[ - "f01234", - 42, - "f01234" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigCancelTxnHash -MsigCancel cancels a previously-proposed multisig message -It takes the following params: , , , , -, , - - -Perms: sign - -Inputs: -```json -[ - "f01234", - 42, - "f01234", - "0", - "f01234", - 42, - "Ynl0ZSBhcnJheQ==" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigCreate -MsigCreate creates a multisig wallet -It takes the following params: , , -, , - - -Perms: sign - -Inputs: -```json -[ - 42, - [ - "f01234" - ], - 10101, - "0", - "f01234", - "0" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigGetAvailableBalance -MsigGetAvailableBalance returns the portion of a multisig's balance that can be withdrawn or spent - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### MsigGetPending -MsigGetPending returns pending transactions for the given multisig -wallet. Once pending transactions are fully approved, they will no longer -appear here. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "ID": 9, - "To": "f01234", - "Value": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "Approved": [ - "f01234" - ] - } -] -``` - -### MsigGetVested -MsigGetVested returns the amount of FIL that vested in a multisig in a certain period. -It takes the following params: , , - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### MsigGetVestingSchedule -MsigGetVestingSchedule returns the vesting details of a given multisig. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "InitialBalance": "0", - "StartEpoch": 10101, - "UnlockDuration": 10101 -} -``` - -### MsigPropose -MsigPropose proposes a multisig message -It takes the following params: , , , -, , - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "0", - "f01234", - 42, - "Ynl0ZSBhcnJheQ==" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigRemoveSigner -MsigRemoveSigner proposes the removal of a signer from the multisig. -It accepts the multisig to make the change on, the proposer address to -send the message from, the address to be removed, and a boolean -indicating whether or not the signing threshold should be lowered by one -along with the address removal. - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "f01234", - true -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigSwapApprove -MsigSwapApprove approves a previously proposed SwapSigner -It takes the following params: , , , -, , - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - 42, - "f01234", - "f01234", - "f01234" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigSwapCancel -MsigSwapCancel cancels a previously proposed SwapSigner message -It takes the following params: , , , -, - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - 42, - "f01234", - "f01234" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -### MsigSwapPropose -MsigSwapPropose proposes swapping 2 signers in the multisig -It takes the following params: , , -, - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "f01234", - "f01234" -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "ValidNonce": true -} -``` - -## Net - - -### NetAddrsListen - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", - "Addrs": [ - "/ip4/52.36.61.156/tcp/1347/p2p/12D3KooWFETiESTf1v4PGUvtnxMAcEFMzLZbJGg4tjWfGEimYior" - ] -} -``` - -### NetAgentVersion - - -Perms: read - -Inputs: -```json -[ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" -] -``` - -Response: `"string value"` - -### NetAutoNatStatus - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "Reachability": 1, - "PublicAddrs": [ - "string value" - ] -} -``` - -### NetBandwidthStats - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "TotalIn": 9, - "TotalOut": 9, - "RateIn": 12.3, - "RateOut": 12.3 -} -``` - -### NetBandwidthStatsByPeer - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "12D3KooWSXmXLJmBR1M7i9RW9GQPNUhZSzXKzxDHWtAgNuJAbyEJ": { - "TotalIn": 174000, - "TotalOut": 12500, - "RateIn": 100, - "RateOut": 50 - } -} -``` - -### NetBandwidthStatsByProtocol - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "/fil/hello/1.0.0": { - "TotalIn": 174000, - "TotalOut": 12500, - "RateIn": 100, - "RateOut": 50 - } -} -``` - -### NetBlockAdd - - -Perms: admin - -Inputs: -```json -[ - { - "Peers": [ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" - ], - "IPAddrs": [ - "string value" - ], - "IPSubnets": [ - "string value" - ] - } -] -``` - -Response: `{}` - -### NetBlockList - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "Peers": [ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" - ], - "IPAddrs": [ - "string value" - ], - "IPSubnets": [ - "string value" - ] -} -``` - -### NetBlockRemove - - -Perms: admin - -Inputs: -```json -[ - { - "Peers": [ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" - ], - "IPAddrs": [ - "string value" - ], - "IPSubnets": [ - "string value" - ] - } -] -``` - -Response: `{}` - -### NetConnect - - -Perms: write - -Inputs: -```json -[ - { - "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", - "Addrs": [ - "/ip4/52.36.61.156/tcp/1347/p2p/12D3KooWFETiESTf1v4PGUvtnxMAcEFMzLZbJGg4tjWfGEimYior" - ] - } -] -``` - -Response: `{}` - -### NetConnectedness - - -Perms: read - -Inputs: -```json -[ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" -] -``` - -Response: `1` - -### NetDisconnect - - -Perms: write - -Inputs: -```json -[ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" -] -``` - -Response: `{}` - -### NetFindPeer - - -Perms: read - -Inputs: -```json -[ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" -] -``` - -Response: -```json -{ - "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", - "Addrs": [ - "/ip4/52.36.61.156/tcp/1347/p2p/12D3KooWFETiESTf1v4PGUvtnxMAcEFMzLZbJGg4tjWfGEimYior" - ] -} -``` - -### NetLimit - - -Perms: read - -Inputs: -```json -[ - "string value" -] -``` - -Response: -```json -{ - "Memory": 123, - "Streams": 3, - "StreamsInbound": 1, - "StreamsOutbound": 2, - "Conns": 4, - "ConnsInbound": 3, - "ConnsOutbound": 4, - "FD": 5 -} -``` - -### NetListening - - -Perms: read - -Inputs: `null` - -Response: `true` - -### NetPeerInfo - - -Perms: read - -Inputs: -```json -[ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" -] -``` - -Response: -```json -{ - "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", - "Agent": "string value", - "Addrs": [ - "string value" - ], - "Protocols": [ - "string value" - ], - "ConnMgrMeta": { - "FirstSeen": "0001-01-01T00:00:00Z", - "Value": 123, - "Tags": { - "name": 42 - }, - "Conns": { - "name": "2021-03-08T22:52:18Z" - } - } -} -``` - -### NetPeers - - -Perms: read - -Inputs: `null` - -Response: -```json -[ - { - "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", - "Addrs": [ - "/ip4/52.36.61.156/tcp/1347/p2p/12D3KooWFETiESTf1v4PGUvtnxMAcEFMzLZbJGg4tjWfGEimYior" - ] - } -] -``` - -### NetPing - - -Perms: read - -Inputs: -```json -[ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" -] -``` - -Response: `60000000000` - -### NetProtectAdd - - -Perms: admin - -Inputs: -```json -[ - [ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" - ] -] -``` - -Response: `{}` - -### NetProtectList - - -Perms: read - -Inputs: `null` - -Response: -```json -[ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" -] -``` - -### NetProtectRemove - - -Perms: admin - -Inputs: -```json -[ - [ - "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" - ] -] -``` - -Response: `{}` - -### NetPubsubScores - - -Perms: read - -Inputs: `null` - -Response: -```json -[ - { - "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", - "Score": { - "Score": 12.3, - "Topics": { - "/blocks": { - "TimeInMesh": 60000000000, - "FirstMessageDeliveries": 122, - "MeshMessageDeliveries": 1234, - "InvalidMessageDeliveries": 3 - } - }, - "AppSpecificScore": 12.3, - "IPColocationFactor": 12.3, - "BehaviourPenalty": 12.3 - } - } -] -``` - -### NetSetLimit - - -Perms: admin - -Inputs: -```json -[ - "string value", - { - "Memory": 123, - "Streams": 3, - "StreamsInbound": 1, - "StreamsOutbound": 2, - "Conns": 4, - "ConnsInbound": 3, - "ConnsOutbound": 4, - "FD": 5 - } -] -``` - -Response: `{}` - -### NetStat - - -Perms: read - -Inputs: -```json -[ - "string value" -] -``` - -Response: -```json -{ - "System": { - "NumStreamsInbound": 123, - "NumStreamsOutbound": 123, - "NumConnsInbound": 123, - "NumConnsOutbound": 123, - "NumFD": 123, - "Memory": 9 - }, - "Transient": { - "NumStreamsInbound": 123, - "NumStreamsOutbound": 123, - "NumConnsInbound": 123, - "NumConnsOutbound": 123, - "NumFD": 123, - "Memory": 9 - }, - "Services": { - "abc": { - "NumStreamsInbound": 1, - "NumStreamsOutbound": 2, - "NumConnsInbound": 3, - "NumConnsOutbound": 4, - "NumFD": 5, - "Memory": 123 - } - }, - "Protocols": { - "abc": { - "NumStreamsInbound": 1, - "NumStreamsOutbound": 2, - "NumConnsInbound": 3, - "NumConnsOutbound": 4, - "NumFD": 5, - "Memory": 123 - } - }, - "Peers": { - "abc": { - "NumStreamsInbound": 1, - "NumStreamsOutbound": 2, - "NumConnsInbound": 3, - "NumConnsOutbound": 4, - "NumFD": 5, - "Memory": 123 - } - } -} -``` - -### NetVersion - - -Perms: read - -Inputs: `null` - -Response: `"string value"` - -## Node -These methods are general node management and status commands - - -### NodeStatus -There are not yet any comments for this method. - -Perms: read - -Inputs: -```json -[ - true -] -``` - -Response: -```json -{ - "SyncStatus": { - "Epoch": 42, - "Behind": 42 - }, - "PeerStatus": { - "PeersToPublishMsgs": 123, - "PeersToPublishBlocks": 123 - }, - "ChainStatus": { - "BlocksPerTipsetLast100": 12.3, - "BlocksPerTipsetLastFinality": 12.3 - } -} -``` - -## Paych -The Paych methods are for interacting with and managing payment channels - - -### PaychAllocateLane - - -Perms: sign - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `42` - -### PaychAvailableFunds - - -Perms: sign - -Inputs: -```json -[ - "f01234" -] -``` - -Response: -```json -{ - "Channel": "f01234", - "From": "f01234", - "To": "f01234", - "ConfirmedAmt": "0", - "PendingAmt": "0", - "NonReservedAmt": "0", - "PendingAvailableAmt": "0", - "PendingWaitSentinel": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "QueuedAmt": "0", - "VoucherReedeemedAmt": "0" -} -``` - -### PaychAvailableFundsByFromTo - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234" -] -``` - -Response: -```json -{ - "Channel": "f01234", - "From": "f01234", - "To": "f01234", - "ConfirmedAmt": "0", - "PendingAmt": "0", - "NonReservedAmt": "0", - "PendingAvailableAmt": "0", - "PendingWaitSentinel": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "QueuedAmt": "0", - "VoucherReedeemedAmt": "0" -} -``` - -### PaychCollect - - -Perms: sign - -Inputs: -```json -[ - "f01234" -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### PaychFund -PaychFund gets or creates a payment channel between address pair. -The specified amount will be added to the channel through on-chain send for future use - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "0" -] -``` - -Response: -```json -{ - "Channel": "f01234", - "WaitSentinel": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -} -``` - -### PaychGet -PaychGet gets or creates a payment channel between address pair - The specified amount will be reserved for use. If there aren't enough non-reserved funds - available, funds will be added through an on-chain message. - - When opts.OffChain is true, this call will not cause any messages to be sent to the chain (no automatic - channel creation/funds adding). If the operation can't be performed without sending a message an error will be - returned. Note that even when this option is specified, this call can be blocked by previous operations on the - channel waiting for on-chain operations. - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - "0", - { - "OffChain": true - } -] -``` - -Response: -```json -{ - "Channel": "f01234", - "WaitSentinel": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -} -``` - -### PaychGetWaitReady - - -Perms: sign - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: `"f01234"` - -### PaychList - - -Perms: read - -Inputs: `null` - -Response: -```json -[ - "f01234" -] -``` - -### PaychNewPayment - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "f01234", - [ - { - "Amount": "0", - "TimeLockMin": 10101, - "TimeLockMax": 10101, - "MinSettle": 10101, - "Extra": { - "Actor": "f01234", - "Method": 1, - "Data": "Ynl0ZSBhcnJheQ==" - } - } - ] -] -``` - -Response: -```json -{ - "Channel": "f01234", - "WaitSentinel": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Vouchers": [ - { - "ChannelAddr": "f01234", - "TimeLockMin": 10101, - "TimeLockMax": 10101, - "SecretHash": "Ynl0ZSBhcnJheQ==", - "Extra": { - "Actor": "f01234", - "Method": 1, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Lane": 42, - "Nonce": 42, - "Amount": "0", - "MinSettleHeight": 10101, - "Merges": [ - { - "Lane": 42, - "Nonce": 42 - } - ], - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - } - } - ] -} -``` - -### PaychSettle - - -Perms: sign - -Inputs: -```json -[ - "f01234" -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### PaychStatus - - -Perms: read - -Inputs: -```json -[ - "f01234" -] -``` - -Response: -```json -{ - "ControlAddr": "f01234", - "Direction": 1 -} -``` - -### PaychVoucherAdd - - -Perms: write - -Inputs: -```json -[ - "f01234", - { - "ChannelAddr": "f01234", - "TimeLockMin": 10101, - "TimeLockMax": 10101, - "SecretHash": "Ynl0ZSBhcnJheQ==", - "Extra": { - "Actor": "f01234", - "Method": 1, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Lane": 42, - "Nonce": 42, - "Amount": "0", - "MinSettleHeight": 10101, - "Merges": [ - { - "Lane": 42, - "Nonce": 42 - } - ], - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - } - }, - "Ynl0ZSBhcnJheQ==", - "0" -] -``` - -Response: `"0"` - -### PaychVoucherCheckSpendable - - -Perms: read - -Inputs: -```json -[ - "f01234", - { - "ChannelAddr": "f01234", - "TimeLockMin": 10101, - "TimeLockMax": 10101, - "SecretHash": "Ynl0ZSBhcnJheQ==", - "Extra": { - "Actor": "f01234", - "Method": 1, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Lane": 42, - "Nonce": 42, - "Amount": "0", - "MinSettleHeight": 10101, - "Merges": [ - { - "Lane": 42, - "Nonce": 42 - } - ], - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - } - }, - "Ynl0ZSBhcnJheQ==", - "Ynl0ZSBhcnJheQ==" -] -``` - -Response: `true` - -### PaychVoucherCheckValid - - -Perms: read - -Inputs: -```json -[ - "f01234", - { - "ChannelAddr": "f01234", - "TimeLockMin": 10101, - "TimeLockMax": 10101, - "SecretHash": "Ynl0ZSBhcnJheQ==", - "Extra": { - "Actor": "f01234", - "Method": 1, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Lane": 42, - "Nonce": 42, - "Amount": "0", - "MinSettleHeight": 10101, - "Merges": [ - { - "Lane": 42, - "Nonce": 42 - } - ], - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - } - } -] -``` - -Response: `{}` - -### PaychVoucherCreate - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "0", - 42 -] -``` - -Response: -```json -{ - "Voucher": { - "ChannelAddr": "f01234", - "TimeLockMin": 10101, - "TimeLockMax": 10101, - "SecretHash": "Ynl0ZSBhcnJheQ==", - "Extra": { - "Actor": "f01234", - "Method": 1, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Lane": 42, - "Nonce": 42, - "Amount": "0", - "MinSettleHeight": 10101, - "Merges": [ - { - "Lane": 42, - "Nonce": 42 - } - ], - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - } - }, - "Shortfall": "0" -} -``` - -### PaychVoucherList - - -Perms: write - -Inputs: -```json -[ - "f01234" -] -``` - -Response: -```json -[ - { - "ChannelAddr": "f01234", - "TimeLockMin": 10101, - "TimeLockMax": 10101, - "SecretHash": "Ynl0ZSBhcnJheQ==", - "Extra": { - "Actor": "f01234", - "Method": 1, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Lane": 42, - "Nonce": 42, - "Amount": "0", - "MinSettleHeight": 10101, - "Merges": [ - { - "Lane": 42, - "Nonce": 42 - } - ], - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - } - } -] -``` - -### PaychVoucherSubmit - - -Perms: sign - -Inputs: -```json -[ - "f01234", - { - "ChannelAddr": "f01234", - "TimeLockMin": 10101, - "TimeLockMax": 10101, - "SecretHash": "Ynl0ZSBhcnJheQ==", - "Extra": { - "Actor": "f01234", - "Method": 1, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Lane": 42, - "Nonce": 42, - "Amount": "0", - "MinSettleHeight": 10101, - "Merges": [ - { - "Lane": 42, - "Nonce": 42 - } - ], - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - } - }, - "Ynl0ZSBhcnJheQ==", - "Ynl0ZSBhcnJheQ==" -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -## Start - - -### StartTime - - -Perms: read - -Inputs: `null` - -Response: `"0001-01-01T00:00:00Z"` - -## State -The State methods are used to query, inspect, and interact with chain state. -Most methods take a TipSetKey as a parameter. The state looked up is the parent state of the tipset. -A nil TipSetKey can be provided as a param, this will cause the heaviest tipset in the chain to be used. - - -### StateAccountKey -StateAccountKey returns the public key address of the given ID address for secp and bls accounts - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"f01234"` - -### StateActorCodeCIDs -StateActorCodeCIDs returns the CIDs of all the builtin actors for the given network version - - -Perms: read - -Inputs: -```json -[ - 23 -] -``` - -Response: `{}` - -### StateActorManifestCID -StateActorManifestCID returns the CID of the builtin actors manifest for the given network version - - -Perms: read - -Inputs: -```json -[ - 23 -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### StateAllMinerFaults -StateAllMinerFaults returns all non-expired Faults that occur within lookback epochs of the given tipset - - -Perms: read - -Inputs: -```json -[ - 10101, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "Miner": "f01234", - "Epoch": 10101 - } -] -``` - -### StateCall -StateCall runs the given message and returns its result without any persisted changes. - -StateCall applies the message to the tipset's parent state. The -message is not applied on-top-of the messages in the passed-in -tipset. - - -Perms: read - -Inputs: -```json -[ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "MsgCid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Msg": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "GasUsed": 9, - "EventsRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - }, - "GasCost": { - "Message": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "GasUsed": "0", - "BaseFeeBurn": "0", - "OverEstimationBurn": "0", - "MinerPenalty": "0", - "MinerTip": "0", - "Refund": "0", - "TotalCost": "0" - }, - "ExecutionTrace": { - "Msg": { - "From": "f01234", - "To": "f01234", - "Value": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "ParamsCodec": 42, - "GasLimit": 42, - "ReadOnly": true - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "ReturnCodec": 42 - }, - "InvokedActor": { - "Id": 1000, - "State": { - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Head": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Nonce": 42, - "Balance": "0", - "DelegatedAddress": "f01234" - } - }, - "GasCharges": [ - { - "Name": "string value", - "tg": 9, - "cg": 9, - "sg": 9, - "tt": 60000000000 - } - ], - "Subcalls": [ - { - "Msg": { - "From": "f01234", - "To": "f01234", - "Value": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "ParamsCodec": 42, - "GasLimit": 42, - "ReadOnly": true - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "ReturnCodec": 42 - }, - "InvokedActor": { - "Id": 1000, - "State": { - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Head": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Nonce": 42, - "Balance": "0", - "DelegatedAddress": "f01234" - } - }, - "GasCharges": [ - { - "Name": "string value", - "tg": 9, - "cg": 9, - "sg": 9, - "tt": 60000000000 - } - ], - "Subcalls": null - } - ] - }, - "Error": "string value", - "Duration": 60000000000 -} -``` - -### StateChangedActors -StateChangedActors returns all the actors whose states change between the two given state CIDs -TODO: Should this take tipset keys instead? - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -{ - "t01236": { - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Head": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Nonce": 42, - "Balance": "0", - "DelegatedAddress": "f01234" - } -} -``` - -### StateCirculatingSupply -StateCirculatingSupply returns the exact circulating supply of Filecoin at the given tipset. -This is not used anywhere in the protocol itself, and is only for external consumption. - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### StateCompute -StateCompute is a flexible command that applies the given messages on the given tipset. -The messages are run as though the VM were at the provided height. - -When called, StateCompute will: -- Load the provided tipset, or use the current chain head if not provided -- Compute the tipset state of the provided tipset on top of the parent state - - (note that this step runs before vmheight is applied to the execution) - - Execute state upgrade if any were scheduled at the epoch, or in null - blocks preceding the tipset - - Call the cron actor on null blocks preceding the tipset - - For each block in the tipset - - Apply messages in blocks in the specified - - Award block reward by calling the reward actor - - Call the cron actor for the current epoch -- If the specified vmheight is higher than the current epoch, apply any - needed state upgrades to the state -- Apply the specified messages to the state - -The vmheight parameter sets VM execution epoch, and can be used to simulate -message execution in different network versions. If the specified vmheight -epoch is higher than the epoch of the specified tipset, any state upgrades -until the vmheight will be executed on the state before applying messages -specified by the user. - -Note that the initial tipset state computation is not affected by the -vmheight parameter - only the messages in the `apply` set are - -If the caller wants to simply compute the state, vmheight should be set to -the epoch of the specified tipset. - -Messages in the `apply` parameter must have the correct nonces, and gas -values set. - - -Perms: read - -Inputs: -```json -[ - 10101, - [ - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } - ], - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Root": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Trace": [ - { - "MsgCid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Msg": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "GasUsed": 9, - "EventsRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - }, - "GasCost": { - "Message": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "GasUsed": "0", - "BaseFeeBurn": "0", - "OverEstimationBurn": "0", - "MinerPenalty": "0", - "MinerTip": "0", - "Refund": "0", - "TotalCost": "0" - }, - "ExecutionTrace": { - "Msg": { - "From": "f01234", - "To": "f01234", - "Value": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "ParamsCodec": 42, - "GasLimit": 42, - "ReadOnly": true - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "ReturnCodec": 42 - }, - "InvokedActor": { - "Id": 1000, - "State": { - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Head": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Nonce": 42, - "Balance": "0", - "DelegatedAddress": "f01234" - } - }, - "GasCharges": [ - { - "Name": "string value", - "tg": 9, - "cg": 9, - "sg": 9, - "tt": 60000000000 - } - ], - "Subcalls": [ - { - "Msg": { - "From": "f01234", - "To": "f01234", - "Value": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "ParamsCodec": 42, - "GasLimit": 42, - "ReadOnly": true - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "ReturnCodec": 42 - }, - "InvokedActor": { - "Id": 1000, - "State": { - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Head": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Nonce": 42, - "Balance": "0", - "DelegatedAddress": "f01234" - } - }, - "GasCharges": [ - { - "Name": "string value", - "tg": 9, - "cg": 9, - "sg": 9, - "tt": 60000000000 - } - ], - "Subcalls": null - } - ] - }, - "Error": "string value", - "Duration": 60000000000 - } - ] -} -``` - -### StateComputeDataCID -StateComputeDataCID computes DataCID from a set of on-chain deals - - -Perms: read - -Inputs: -```json -[ - "f01234", - 8, - [ - 5432 - ], - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" -} -``` - -### StateDealProviderCollateralBounds -StateDealProviderCollateralBounds returns the min and max collateral a storage provider -can issue. It takes the deal size and verified status as parameters. - - -Perms: read - -Inputs: -```json -[ - 1032, - true, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Min": "0", - "Max": "0" -} -``` - -### StateDecodeParams -StateDecodeParams attempts to decode the provided params, based on the recipient actor address and method number. - - -Perms: read - -Inputs: -```json -[ - "f01234", - 1, - "Ynl0ZSBhcnJheQ==", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `{}` - -### StateEncodeParams -StateEncodeParams attempts to encode the provided json params to the binary from - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - 1, - "json raw message" -] -``` - -Response: `"Ynl0ZSBhcnJheQ=="` - -### StateGetActor -StateGetActor returns the indicated actor's nonce and balance. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Head": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Nonce": 42, - "Balance": "0", - "DelegatedAddress": "f01234" -} -``` - -### StateGetAllAllocations -StateGetAllAllocations returns the all the allocations available in verified registry actor. - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `{}` - -### StateGetAllClaims -StateGetAllClaims returns the all the claims available in verified registry actor. - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `{}` - -### StateGetAllocation -StateGetAllocation returns the allocation for a given address and allocation ID. - - -Perms: read - -Inputs: -```json -[ - "f01234", - 0, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Client": 1000, - "Provider": 1000, - "Data": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Size": 1032, - "TermMin": 10101, - "TermMax": 10101, - "Expiration": 10101 -} -``` - -### StateGetAllocationForPendingDeal -StateGetAllocationForPendingDeal returns the allocation for a given deal ID of a pending deal. Returns nil if -pending allocation is not found. - - -Perms: read - -Inputs: -```json -[ - 5432, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Client": 1000, - "Provider": 1000, - "Data": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Size": 1032, - "TermMin": 10101, - "TermMax": 10101, - "Expiration": 10101 -} -``` - -### StateGetAllocationIdForPendingDeal -StateGetAllocationIdForPendingDeal is like StateGetAllocationForPendingDeal except it returns the allocation ID - - -Perms: read - -Inputs: -```json -[ - 5432, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `0` - -### StateGetAllocations -StateGetAllocations returns the all the allocations for a given client. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `{}` - -### StateGetBeaconEntry -StateGetBeaconEntry returns the beacon entry for the given filecoin epoch. If -the entry has not yet been produced, the call will block until the entry -becomes available - - -Perms: read - -Inputs: -```json -[ - 10101 -] -``` - -Response: -```json -{ - "Round": 42, - "Data": "Ynl0ZSBhcnJheQ==" -} -``` - -### StateGetClaim -StateGetClaim returns the claim for a given address and claim ID. - - -Perms: read - -Inputs: -```json -[ - "f01234", - 0, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Provider": 1000, - "Client": 1000, - "Data": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Size": 1032, - "TermMin": 10101, - "TermMax": 10101, - "TermStart": 10101, - "Sector": 9 -} -``` - -### StateGetClaims -StateGetClaims returns the all the claims for a given provider. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `{}` - -### StateGetNetworkParams -StateGetNetworkParams return current network params - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "NetworkName": "lotus", - "BlockDelaySecs": 42, - "ConsensusMinerMinPower": "0", - "SupportedProofTypes": [ - 8 - ], - "PreCommitChallengeDelay": 10101, - "ForkUpgradeParams": { - "UpgradeSmokeHeight": 10101, - "UpgradeBreezeHeight": 10101, - "UpgradeIgnitionHeight": 10101, - "UpgradeLiftoffHeight": 10101, - "UpgradeAssemblyHeight": 10101, - "UpgradeRefuelHeight": 10101, - "UpgradeTapeHeight": 10101, - "UpgradeKumquatHeight": 10101, - "BreezeGasTampingDuration": 10101, - "UpgradeCalicoHeight": 10101, - "UpgradePersianHeight": 10101, - "UpgradeOrangeHeight": 10101, - "UpgradeClausHeight": 10101, - "UpgradeTrustHeight": 10101, - "UpgradeNorwegianHeight": 10101, - "UpgradeTurboHeight": 10101, - "UpgradeHyperdriveHeight": 10101, - "UpgradeChocolateHeight": 10101, - "UpgradeOhSnapHeight": 10101, - "UpgradeSkyrHeight": 10101, - "UpgradeSharkHeight": 10101, - "UpgradeHyggeHeight": 10101, - "UpgradeLightningHeight": 10101, - "UpgradeThunderHeight": 10101, - "UpgradeWatermelonHeight": 10101, - "UpgradeDragonHeight": 10101, - "UpgradePhoenixHeight": 10101, - "UpgradeWaffleHeight": 10101 - }, - "Eip155ChainID": 123 -} -``` - -### StateGetRandomnessDigestFromBeacon -StateGetRandomnessDigestFromBeacon is used to sample the beacon for randomness. - - -Perms: read - -Inputs: -```json -[ - 10101, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"Bw=="` - -### StateGetRandomnessDigestFromTickets -StateGetRandomnessDigestFromTickets. is used to sample the chain for randomness. - - -Perms: read - -Inputs: -```json -[ - 10101, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"Bw=="` - -### StateGetRandomnessFromBeacon -StateGetRandomnessFromBeacon is used to sample the beacon for randomness. - - -Perms: read - -Inputs: -```json -[ - 2, - 10101, - "Ynl0ZSBhcnJheQ==", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"Bw=="` - -### StateGetRandomnessFromTickets -StateGetRandomnessFromTickets is used to sample the chain for randomness. - - -Perms: read - -Inputs: -```json -[ - 2, - 10101, - "Ynl0ZSBhcnJheQ==", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"Bw=="` - -### StateListActors -StateListActors returns the addresses of every actor in the state - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - "f01234" -] -``` - -### StateListMessages -StateListMessages looks back and returns all messages with a matching to or from address, stopping at the given height. - - -Perms: read - -Inputs: -```json -[ - { - "To": "f01234", - "From": "f01234" - }, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - 10101 -] -``` - -Response: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -### StateListMiners -StateListMiners returns the addresses of every miner that has claimed power in the Power Actor - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - "f01234" -] -``` - -### StateLookupID -StateLookupID retrieves the ID address of the given address - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"f01234"` - -### StateLookupRobustAddress -StateLookupRobustAddress returns the public key address of the given ID address for non-account addresses (multisig, miners etc) - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"f01234"` - -### StateMarketBalance -StateMarketBalance looks up the Escrow and Locked balances of the given address in the Storage Market - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Escrow": "0", - "Locked": "0" -} -``` - -### StateMarketDeals -StateMarketDeals returns information about every deal in the Storage Market - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "t026363": { - "Proposal": { - "PieceCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "PieceSize": 1032, - "VerifiedDeal": true, - "Client": "f01234", - "Provider": "f01234", - "Label": "", - "StartEpoch": 10101, - "EndEpoch": 10101, - "StoragePricePerEpoch": "0", - "ProviderCollateral": "0", - "ClientCollateral": "0" - }, - "State": { - "SectorNumber": 9, - "SectorStartEpoch": 10101, - "LastUpdatedEpoch": 10101, - "SlashEpoch": 10101 - } - } -} -``` - -### StateMarketParticipants -StateMarketParticipants returns the Escrow and Locked balances of every participant in the Storage Market - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "t026363": { - "Escrow": "0", - "Locked": "0" - } -} -``` - -### StateMarketStorageDeal -StateMarketStorageDeal returns information about the indicated deal - - -Perms: read - -Inputs: -```json -[ - 5432, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Proposal": { - "PieceCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "PieceSize": 1032, - "VerifiedDeal": true, - "Client": "f01234", - "Provider": "f01234", - "Label": "", - "StartEpoch": 10101, - "EndEpoch": 10101, - "StoragePricePerEpoch": "0", - "ProviderCollateral": "0", - "ClientCollateral": "0" - }, - "State": { - "SectorNumber": 9, - "SectorStartEpoch": 10101, - "LastUpdatedEpoch": 10101, - "SlashEpoch": 10101 - } -} -``` - -### StateMinerActiveSectors -StateMinerActiveSectors returns info about sectors that a given miner is actively proving. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "SectorNumber": 9, - "SealProof": 8, - "SealedCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "DealIDs": [ - 5432 - ], - "Activation": 10101, - "Expiration": 10101, - "DealWeight": "0", - "VerifiedDealWeight": "0", - "InitialPledge": "0", - "ExpectedDayReward": "0", - "ExpectedStoragePledge": "0", - "PowerBaseEpoch": 10101, - "ReplacedDayReward": "0", - "SectorKeyCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Flags": 0 - } -] -``` - -### StateMinerAllocated -StateMinerAllocated returns a bitfield containing all sector numbers marked as allocated in miner state - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - 0 -] -``` - -### StateMinerAvailableBalance -StateMinerAvailableBalance returns the portion of a miner's balance that can be withdrawn or spent - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### StateMinerDeadlines -StateMinerDeadlines returns all the proving deadlines for the given miner - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "PostSubmissions": [ - 5, - 1 - ], - "DisputableProofCount": 42 - } -] -``` - -### StateMinerFaults -StateMinerFaults returns a bitfield indicating the faulty sectors of the given miner - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - 5, - 1 -] -``` - -### StateMinerInfo -StateMinerInfo returns info about the indicated miner - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Owner": "f01234", - "Worker": "f01234", - "NewWorker": "f01234", - "ControlAddresses": [ - "f01234" - ], - "WorkerChangeEpoch": 10101, - "PeerId": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", - "Multiaddrs": [ - "Ynl0ZSBhcnJheQ==" - ], - "WindowPoStProofType": 8, - "SectorSize": 34359738368, - "WindowPoStPartitionSectors": 42, - "ConsensusFaultElapsed": 10101, - "PendingOwnerAddress": "f01234", - "Beneficiary": "f01234", - "BeneficiaryTerm": { - "Quota": "0", - "UsedQuota": "0", - "Expiration": 10101 - }, - "PendingBeneficiaryTerm": { - "NewBeneficiary": "f01234", - "NewQuota": "0", - "NewExpiration": 10101, - "ApprovedByBeneficiary": true, - "ApprovedByNominee": true - } -} -``` - -### StateMinerInitialPledgeCollateral -StateMinerInitialPledgeCollateral returns the initial pledge collateral for the specified miner's sector - - -Perms: read - -Inputs: -```json -[ - "f01234", - { - "SealProof": 8, - "SectorNumber": 9, - "SealedCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "SealRandEpoch": 10101, - "DealIDs": [ - 5432 - ], - "Expiration": 10101, - "UnsealedCid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - }, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### StateMinerPartitions -StateMinerPartitions returns all partitions in the specified deadline - - -Perms: read - -Inputs: -```json -[ - "f01234", - 42, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "AllSectors": [ - 5, - 1 - ], - "FaultySectors": [ - 5, - 1 - ], - "RecoveringSectors": [ - 5, - 1 - ], - "LiveSectors": [ - 5, - 1 - ], - "ActiveSectors": [ - 5, - 1 - ] - } -] -``` - -### StateMinerPower -StateMinerPower returns the power of the indicated miner - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "MinerPower": { - "RawBytePower": "0", - "QualityAdjPower": "0" - }, - "TotalPower": { - "RawBytePower": "0", - "QualityAdjPower": "0" - }, - "HasMinPower": true -} -``` - -### StateMinerPreCommitDepositForPower -StateMinerInitialPledgeCollateral returns the precommit deposit for the specified miner's sector - - -Perms: read - -Inputs: -```json -[ - "f01234", - { - "SealProof": 8, - "SectorNumber": 9, - "SealedCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "SealRandEpoch": 10101, - "DealIDs": [ - 5432 - ], - "Expiration": 10101, - "UnsealedCid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - }, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### StateMinerProvingDeadline -StateMinerProvingDeadline calculates the deadline at some epoch for a proving period -and returns the deadline-related calculations. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "CurrentEpoch": 10101, - "PeriodStart": 10101, - "Index": 42, - "Open": 10101, - "Close": 10101, - "Challenge": 10101, - "FaultCutoff": 10101, - "WPoStPeriodDeadlines": 42, - "WPoStProvingPeriod": 10101, - "WPoStChallengeWindow": 10101, - "WPoStChallengeLookback": 10101, - "FaultDeclarationCutoff": 10101 -} -``` - -### StateMinerRecoveries -StateMinerRecoveries returns a bitfield indicating the recovering sectors of the given miner - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - 5, - 1 -] -``` - -### StateMinerSectorAllocated -StateMinerSectorAllocated checks if a sector number is marked as allocated. - - -Perms: read - -Inputs: -```json -[ - "f01234", - 9, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `true` - -### StateMinerSectorCount -StateMinerSectorCount returns the number of sectors in a miner's sector set and proving set - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Live": 42, - "Active": 42, - "Faulty": 42 -} -``` - -### StateMinerSectors -StateMinerSectors returns info about the given miner's sectors. If the filter bitfield is nil, all sectors are included. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - 0 - ], - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -[ - { - "SectorNumber": 9, - "SealProof": 8, - "SealedCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "DealIDs": [ - 5432 - ], - "Activation": 10101, - "Expiration": 10101, - "DealWeight": "0", - "VerifiedDealWeight": "0", - "InitialPledge": "0", - "ExpectedDayReward": "0", - "ExpectedStoragePledge": "0", - "PowerBaseEpoch": 10101, - "ReplacedDayReward": "0", - "SectorKeyCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Flags": 0 - } -] -``` - -### StateNetworkName -StateNetworkName returns the name of the network the node is synced to - - -Perms: read - -Inputs: `null` - -Response: `"lotus"` - -### StateNetworkVersion -StateNetworkVersion returns the network version at the given tipset - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `23` - -### StateReadState -StateReadState returns the indicated actor's state. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Balance": "0", - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "State": {} -} -``` - -### StateReplay -StateReplay replays a given message, assuming it was included in a block in the specified tipset. - -If a tipset key is provided, and a replacing message is not found on chain, -the method will return an error saying that the message wasn't found - -If no tipset key is provided, the appropriate tipset is looked up, and if -the message was gas-repriced, the on-chain message will be replayed - in -that case the returned InvocResult.MsgCid will not match the Cid param - -If the caller wants to ensure that exactly the requested message was executed, -they MUST check that InvocResult.MsgCid is equal to the provided Cid. -Without this check both the requested and original message may appear as -successfully executed on-chain, which may look like a double-spend. - -A replacing message is a message with a different CID, any of Gas values, and -different signature, but with all other parameters matching (source/destination, -nonce, params, etc.) - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: -```json -{ - "MsgCid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Msg": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "GasUsed": 9, - "EventsRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - }, - "GasCost": { - "Message": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "GasUsed": "0", - "BaseFeeBurn": "0", - "OverEstimationBurn": "0", - "MinerPenalty": "0", - "MinerTip": "0", - "Refund": "0", - "TotalCost": "0" - }, - "ExecutionTrace": { - "Msg": { - "From": "f01234", - "To": "f01234", - "Value": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "ParamsCodec": 42, - "GasLimit": 42, - "ReadOnly": true - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "ReturnCodec": 42 - }, - "InvokedActor": { - "Id": 1000, - "State": { - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Head": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Nonce": 42, - "Balance": "0", - "DelegatedAddress": "f01234" - } - }, - "GasCharges": [ - { - "Name": "string value", - "tg": 9, - "cg": 9, - "sg": 9, - "tt": 60000000000 - } - ], - "Subcalls": [ - { - "Msg": { - "From": "f01234", - "To": "f01234", - "Value": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "ParamsCodec": 42, - "GasLimit": 42, - "ReadOnly": true - }, - "MsgRct": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "ReturnCodec": 42 - }, - "InvokedActor": { - "Id": 1000, - "State": { - "Code": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Head": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Nonce": 42, - "Balance": "0", - "DelegatedAddress": "f01234" - } - }, - "GasCharges": [ - { - "Name": "string value", - "tg": 9, - "cg": 9, - "sg": 9, - "tt": 60000000000 - } - ], - "Subcalls": null - } - ] - }, - "Error": "string value", - "Duration": 60000000000 -} -``` - -### StateSearchMsg -StateSearchMsg looks back up to limit epochs in the chain for a message, and returns its receipt and the tipset where it was executed - -NOTE: If a replacing message is found on chain, this method will return -a MsgLookup for the replacing message - the MsgLookup.Message will be a different -CID than the one provided in the 'cid' param, MsgLookup.Receipt will contain the -result of the execution of the replacing message. - -If the caller wants to ensure that exactly the requested message was executed, -they must check that MsgLookup.Message is equal to the provided 'cid', or set the -`allowReplaced` parameter to false. Without this check, and with `allowReplaced` -set to true, both the requested and original message may appear as -successfully executed on-chain, which may look like a double-spend. - -A replacing message is a message with a different CID, any of Gas values, and -different signature, but with all other parameters matching (source/destination, -nonce, params, etc.) - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - 10101, - true -] -``` - -Response: -```json -{ - "Message": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Receipt": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "GasUsed": 9, - "EventsRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - }, - "ReturnDec": {}, - "TipSet": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - "Height": 10101 -} -``` - -### StateSectorExpiration -StateSectorExpiration returns epoch at which given sector will expire - - -Perms: read - -Inputs: -```json -[ - "f01234", - 9, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "OnTime": 10101, - "Early": 10101 -} -``` - -### StateSectorGetInfo -StateSectorGetInfo returns the on-chain info for the specified miner's sector. Returns null in case the sector info isn't found -NOTE: returned info.Expiration may not be accurate in some cases, use StateSectorExpiration to get accurate -expiration epoch - - -Perms: read - -Inputs: -```json -[ - "f01234", - 9, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "SectorNumber": 9, - "SealProof": 8, - "SealedCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "DealIDs": [ - 5432 - ], - "Activation": 10101, - "Expiration": 10101, - "DealWeight": "0", - "VerifiedDealWeight": "0", - "InitialPledge": "0", - "ExpectedDayReward": "0", - "ExpectedStoragePledge": "0", - "PowerBaseEpoch": 10101, - "ReplacedDayReward": "0", - "SectorKeyCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Flags": 0 -} -``` - -### StateSectorPartition -StateSectorPartition finds deadline/partition with the specified sector - - -Perms: read - -Inputs: -```json -[ - "f01234", - 9, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Deadline": 42, - "Partition": 42 -} -``` - -### StateSectorPreCommitInfo -StateSectorPreCommitInfo returns the PreCommit info for the specified miner's sector. -Returns nil and no error if the sector isn't precommitted. - -Note that the sector number may be allocated while PreCommitInfo is nil. This means that either allocated sector -numbers were compacted, and the sector number was marked as allocated in order to reduce size of the allocated -sectors bitfield, or that the sector was precommitted, but the precommit has expired. - - -Perms: read - -Inputs: -```json -[ - "f01234", - 9, - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "Info": { - "SealProof": 8, - "SectorNumber": 9, - "SealedCID": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "SealRandEpoch": 10101, - "DealIDs": [ - 5432 - ], - "Expiration": 10101, - "UnsealedCid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - }, - "PreCommitDeposit": "0", - "PreCommitEpoch": 10101 -} -``` - -### StateVMCirculatingSupplyInternal -StateVMCirculatingSupplyInternal returns an approximation of the circulating supply of Filecoin at the given tipset. -This is the value reported by the runtime interface to actors code. - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: -```json -{ - "FilVested": "0", - "FilMined": "0", - "FilBurnt": "0", - "FilLocked": "0", - "FilCirculating": "0", - "FilReserveDisbursed": "0" -} -``` - -### StateVerifiedClientStatus -StateVerifiedClientStatus returns the data cap for the given address. -Returns nil if there is no entry in the data cap table for the -address. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### StateVerifiedRegistryRootKey -StateVerifiedRegistryRootKey returns the address of the Verified Registry's root key - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"f01234"` - -### StateVerifierStatus -StateVerifierStatus returns the data cap for the given address. -Returns nil if there is no entry in the data cap table for the -address. - - -Perms: read - -Inputs: -```json -[ - "f01234", - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `"0"` - -### StateWaitMsg -StateWaitMsg looks back up to limit epochs in the chain for a message. -If not found, it blocks until the message arrives on chain, and gets to the -indicated confidence depth. - -NOTE: If a replacing message is found on chain, this method will return -a MsgLookup for the replacing message - the MsgLookup.Message will be a different -CID than the one provided in the 'cid' param, MsgLookup.Receipt will contain the -result of the execution of the replacing message. - -If the caller wants to ensure that exactly the requested message was executed, -they must check that MsgLookup.Message is equal to the provided 'cid', or set the -`allowReplaced` parameter to false. Without this check, and with `allowReplaced` -set to true, both the requested and original message may appear as -successfully executed on-chain, which may look like a double-spend. - -A replacing message is a message with a different CID, any of Gas values, and -different signature, but with all other parameters matching (source/destination, -nonce, params, etc.) - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - 42, - 10101, - true -] -``` - -Response: -```json -{ - "Message": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Receipt": { - "ExitCode": 0, - "Return": "Ynl0ZSBhcnJheQ==", - "GasUsed": 9, - "EventsRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - }, - "ReturnDec": {}, - "TipSet": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - "Height": 10101 -} -``` - -## Subscribe - - -### SubscribeActorEventsRaw -SubscribeActorEventsRaw returns a long-lived stream of all user-programmed and built-in actor -events that match the given filter. -Events that match the given filter are written to the stream in real-time as they are emitted -from the FVM. -The response stream is closed when the client disconnects, when a ToHeight is specified and is -reached, or if there is an error while writing an event to the stream. -This API also allows clients to read all historical events matching the given filter before any -real-time events are written to the response stream if the filter specifies an earlier -FromHeight. -Results available from this API may be limited by the MaxFilterResults and MaxFilterHeightRange -configuration options and also the amount of historical data available in the node. - -Note: this API is only available via websocket connections. -This is an EXPERIMENTAL API and may be subject to change. - - -Perms: read - -Inputs: -```json -[ - { - "addresses": [ - "f01234" - ], - "fields": { - "abc": [ - { - "codec": 81, - "value": "ZGRhdGE=" - } - ] - }, - "fromHeight": 1010, - "toHeight": 1020 - } -] -``` - -Response: -```json -{ - "entries": [ - { - "Flags": 7, - "Key": "string value", - "Codec": 42, - "Value": "Ynl0ZSBhcnJheQ==" - } - ], - "emitter": "f01234", - "reverted": true, - "height": 10101, - "tipsetKey": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ], - "msgCid": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -} -``` - -## Sync -The Sync method group contains methods for interacting with and -observing the lotus sync service. - - -### SyncCheckBad -SyncCheckBad checks if a block was marked as bad, and if it was, returns -the reason. - - -Perms: read - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: `"string value"` - -### SyncCheckpoint -SyncCheckpoint marks a blocks as checkpointed, meaning that it won't ever fork away from it. - - -Perms: admin - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `{}` - -### SyncIncomingBlocks -SyncIncomingBlocks returns a channel streaming incoming, potentially not -yet synced block headers. - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "Miner": "f01234", - "Ticket": { - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "ElectionProof": { - "WinCount": 9, - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "BeaconEntries": [ - { - "Round": 42, - "Data": "Ynl0ZSBhcnJheQ==" - } - ], - "WinPoStProof": [ - { - "PoStProof": 8, - "ProofBytes": "Ynl0ZSBhcnJheQ==" - } - ], - "Parents": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ], - "ParentWeight": "0", - "Height": 10101, - "ParentStateRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "ParentMessageReceipts": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Messages": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "BLSAggregate": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Timestamp": 42, - "BlockSig": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "ForkSignaling": 42, - "ParentBaseFee": "0" -} -``` - -### SyncMarkBad -SyncMarkBad marks a blocks as bad, meaning that it won't ever by synced. -Use with extreme caution. - - -Perms: admin - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: `{}` - -### SyncState -SyncState returns the current status of the lotus sync system. - - -Perms: read - -Inputs: `null` - -Response: -```json -{ - "ActiveSyncs": [ - { - "WorkerID": 42, - "Base": { - "Cids": null, - "Blocks": null, - "Height": 0 - }, - "Target": { - "Cids": null, - "Blocks": null, - "Height": 0 - }, - "Stage": 1, - "Height": 10101, - "Start": "0001-01-01T00:00:00Z", - "End": "0001-01-01T00:00:00Z", - "Message": "string value" - } - ], - "VMApplied": 42 -} -``` - -### SyncSubmitBlock -SyncSubmitBlock can be used to submit a newly created block to the. -network through this node - - -Perms: write - -Inputs: -```json -[ - { - "Header": { - "Miner": "f01234", - "Ticket": { - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "ElectionProof": { - "WinCount": 9, - "VRFProof": "Ynl0ZSBhcnJheQ==" - }, - "BeaconEntries": [ - { - "Round": 42, - "Data": "Ynl0ZSBhcnJheQ==" - } - ], - "WinPoStProof": [ - { - "PoStProof": 8, - "ProofBytes": "Ynl0ZSBhcnJheQ==" - } - ], - "Parents": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ], - "ParentWeight": "0", - "Height": 10101, - "ParentStateRoot": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "ParentMessageReceipts": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "Messages": { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - "BLSAggregate": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "Timestamp": 42, - "BlockSig": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "ForkSignaling": 42, - "ParentBaseFee": "0" - }, - "BlsMessages": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ], - "SecpkMessages": [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } - ] - } -] -``` - -Response: `{}` - -### SyncUnmarkAllBad -SyncUnmarkAllBad purges bad block cache, making it possible to sync to chains previously marked as bad - - -Perms: admin - -Inputs: `null` - -Response: `{}` - -### SyncUnmarkBad -SyncUnmarkBad unmarks a blocks as bad, making it possible to be validated and synced again. - - -Perms: admin - -Inputs: -```json -[ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - } -] -``` - -Response: `{}` - -### SyncValidateTipset -SyncValidateTipset indicates whether the provided tipset is valid or not - - -Perms: read - -Inputs: -```json -[ - [ - { - "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" - }, - { - "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" - } - ] -] -``` - -Response: `true` - -## Wallet - - -### WalletBalance -WalletBalance returns the balance of the given address at the current head of the chain. - - -Perms: read - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `"0"` - -### WalletDefaultAddress -WalletDefaultAddress returns the address marked as default in the wallet. - - -Perms: write - -Inputs: `null` - -Response: `"f01234"` - -### WalletDelete -WalletDelete deletes an address from the wallet. - - -Perms: admin - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `{}` - -### WalletExport -WalletExport returns the private key of an address in the wallet. - - -Perms: admin - -Inputs: -```json -[ - "f01234" -] -``` - -Response: -```json -{ - "Type": "bls", - "PrivateKey": "Ynl0ZSBhcnJheQ==" -} -``` - -### WalletHas -WalletHas indicates whether the given address is in the wallet. - - -Perms: write - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `true` - -### WalletImport -WalletImport receives a KeyInfo, which includes a private key, and imports it into the wallet. - - -Perms: admin - -Inputs: -```json -[ - { - "Type": "bls", - "PrivateKey": "Ynl0ZSBhcnJheQ==" - } -] -``` - -Response: `"f01234"` - -### WalletList -WalletList lists all the addresses in the wallet. - - -Perms: write - -Inputs: `null` - -Response: -```json -[ - "f01234" -] -``` - -### WalletNew -WalletNew creates a new address in the wallet with the given sigType. -Available key types: bls, secp256k1, secp256k1-ledger -Support for numerical types: 1 - secp256k1, 2 - BLS is deprecated - - -Perms: write - -Inputs: -```json -[ - "bls" -] -``` - -Response: `"f01234"` - -### WalletSetDefault -WalletSetDefault marks the given address as the default one. - - -Perms: write - -Inputs: -```json -[ - "f01234" -] -``` - -Response: `{}` - -### WalletSign -WalletSign signs the given bytes using the given address. - - -Perms: sign - -Inputs: -```json -[ - "f01234", - "Ynl0ZSBhcnJheQ==" -] -``` - -Response: -```json -{ - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" -} -``` - -### WalletSignMessage -WalletSignMessage signs the given message using the given address. - - -Perms: sign - -Inputs: -```json -[ - "f01234", - { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - } -] -``` - -Response: -```json -{ - "Message": { - "Version": 42, - "To": "f01234", - "From": "f01234", - "Nonce": 42, - "Value": "0", - "GasLimit": 9, - "GasFeeCap": "0", - "GasPremium": "0", - "Method": 1, - "Params": "Ynl0ZSBhcnJheQ==", - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } - }, - "Signature": { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - }, - "CID": { - "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" - } -} -``` - -### WalletValidateAddress -WalletValidateAddress validates whether a given string can be decoded as a well-formed address - - -Perms: read - -Inputs: -```json -[ - "string value" -] -``` - -Response: `"f01234"` - -### WalletVerify -WalletVerify takes an address, a signature, and some bytes, and indicates whether the signature is valid. -The address does not have to be in the wallet. - - -Perms: read - -Inputs: -```json -[ - "f01234", - "Ynl0ZSBhcnJheQ==", - { - "Type": 2, - "Data": "Ynl0ZSBhcnJheQ==" - } -] -``` - -Response: `true` - -## Web3 - - -### Web3ClientVersion -Returns the client version - - -Perms: read - -Inputs: `null` - -Response: `"string value"` - From 347383772a91a0a0114b3dbee60f8edeb9f0bb84 Mon Sep 17 00:00:00 2001 From: Michael Seiler Date: Wed, 3 Jul 2024 17:19:05 -1000 Subject: [PATCH 17/42] To and From slices do not need to be pointers --- chain/types/ethtypes/eth_types.go | 4 ++-- itests/eth_transactions_test.go | 4 ++-- node/impl/full/eth.go | 39 +++++++++++++------------------ 3 files changed, 20 insertions(+), 27 deletions(-) diff --git a/chain/types/ethtypes/eth_types.go b/chain/types/ethtypes/eth_types.go index 82b32f36fc9..99302576662 100644 --- a/chain/types/ethtypes/eth_types.go +++ b/chain/types/ethtypes/eth_types.go @@ -1049,13 +1049,13 @@ type EthTraceFilterCriteria struct { // Optional, default: nil. // The JSON decoding must treat a string as equivalent to an array with one value, for example // "0x8888f1f195afa192cfee86069858" must be decoded as [ "0x8888f1f195afa192cfee86069858" ] - FromAddress *[]string `json:"fromAddress,omitempty"` + FromAddress []string `json:"fromAddress,omitempty"` // Actor address or a list of addresses to which event logs should be sent. // Optional, default: nil. // The JSON decoding must treat a string as equivalent to an array with one value, for example // "0x8888f1f195afa192cfee86069858" must be decoded as [ "0x8888f1f195afa192cfee86069858" ] - ToAddress *[]string `json:"toAddress,omitempty"` + ToAddress []string `json:"toAddress,omitempty"` // Restricts traces returned to those emitted after this epoch (in hex). // Optional, default: 0. diff --git a/itests/eth_transactions_test.go b/itests/eth_transactions_test.go index 69ac555a5c0..f73a0fe3edc 100644 --- a/itests/eth_transactions_test.go +++ b/itests/eth_transactions_test.go @@ -719,8 +719,8 @@ func TestTraceFilter(t *testing.T) { filter = ethtypes.EthTraceFilterCriteria{ FromBlock: &fromBlock, ToBlock: &toBlock, - FromAddress: &[]string{ethAddr.String()}, - ToAddress: &[]string{contractAddr.String()}, + FromAddress: []string{ethAddr.String()}, + ToAddress: []string{contractAddr.String()}, } // Trace filter should find the transaction diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 8f26be410c7..04789a3043e 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1080,21 +1080,17 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace traceCounter := 0 - var fromDecodedAddresses *[]ethtypes.EthAddress - var toDecodedAddresses *[]ethtypes.EthAddress + var fromDecodedAddresses []ethtypes.EthAddress + var toDecodedAddresses []ethtypes.EthAddress - if filter.FromAddress != nil { - fromDecodedAddresses, err = decodeAddressFilter(filter.FromAddress) - if err != nil { - return nil, xerrors.Errorf("cannot decode FromAddress: %w", err) - } + fromDecodedAddresses, err = decodeAddressFilter(filter.FromAddress) + if err != nil { + return nil, xerrors.Errorf("cannot decode FromAddress: %w", err) } - if filter.ToAddress != nil { - toDecodedAddresses, err = decodeAddressFilter(filter.ToAddress) - if err != nil { - return nil, xerrors.Errorf("cannot decode ToAddress: %w", err) - } + toDecodedAddresses, err = decodeAddressFilter(filter.ToAddress) + if err != nil { + return nil, xerrors.Errorf("cannot decode ToAddress: %w", err) } for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { @@ -1134,12 +1130,9 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace return results, nil } -func decodeAddressFilter(addresses *[]string) (*[]ethtypes.EthAddress, error) { - if addresses == nil || len(*addresses) == 0 { - return nil, errors.New("addresses is nil or empty") - } +func decodeAddressFilter(addresses []string) ([]ethtypes.EthAddress, error) { var decodedAddresses []ethtypes.EthAddress - for _, addr := range *addresses { + for _, addr := range addresses { ethAddr, err := ethtypes.ParseEthAddress(addr) if err != nil { return nil, xerrors.Errorf("invalid address: %w", err) @@ -1147,12 +1140,12 @@ func decodeAddressFilter(addresses *[]string) (*[]ethtypes.EthAddress, error) { decodedAddresses = append(decodedAddresses, ethAddr) } - return &decodedAddresses, nil + return decodedAddresses, nil } // matchFilterCriteria checks if a trace matches the filter criteria. -func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria, fromDecodedAddresses *[]ethtypes.EthAddress, toDecodedAddresses *[]ethtypes.EthAddress) (bool, error) { +func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria, fromDecodedAddresses []ethtypes.EthAddress, toDecodedAddresses []ethtypes.EthAddress) (bool, error) { var traceTo ethtypes.EthAddress var traceFrom ethtypes.EthAddress @@ -1183,9 +1176,9 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace } // Match FromAddress - if fromDecodedAddresses != nil && len(*fromDecodedAddresses) > 0 { + if len(fromDecodedAddresses) > 0 { fromMatch := false - for _, ethAddr := range *fromDecodedAddresses { + for _, ethAddr := range fromDecodedAddresses { if traceFrom == ethAddr { fromMatch = true break @@ -1197,9 +1190,9 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace } // Match ToAddress - if toDecodedAddresses != nil && len(*toDecodedAddresses) > 0 { + if len(toDecodedAddresses) > 0 { toMatch := false - for _, ethAddr := range *toDecodedAddresses { + for _, ethAddr := range toDecodedAddresses { if traceTo == ethAddr { toMatch = true break From 7598de6fc2c3c0f26aa15a7a800c936ad6a8028a Mon Sep 17 00:00:00 2001 From: Michael Seiler Date: Thu, 4 Jul 2024 15:06:35 -1000 Subject: [PATCH 18/42] use ethtypes.EthAddressList for FromAddress/ToAddress for trace_filter --- chain/types/ethtypes/eth_types.go | 4 ++-- itests/eth_transactions_test.go | 4 ++-- node/impl/full/eth.go | 15 +-------------- 3 files changed, 5 insertions(+), 18 deletions(-) diff --git a/chain/types/ethtypes/eth_types.go b/chain/types/ethtypes/eth_types.go index 99302576662..635d4022b1c 100644 --- a/chain/types/ethtypes/eth_types.go +++ b/chain/types/ethtypes/eth_types.go @@ -1049,13 +1049,13 @@ type EthTraceFilterCriteria struct { // Optional, default: nil. // The JSON decoding must treat a string as equivalent to an array with one value, for example // "0x8888f1f195afa192cfee86069858" must be decoded as [ "0x8888f1f195afa192cfee86069858" ] - FromAddress []string `json:"fromAddress,omitempty"` + FromAddress EthAddressList `json:"fromAddress,omitempty"` // Actor address or a list of addresses to which event logs should be sent. // Optional, default: nil. // The JSON decoding must treat a string as equivalent to an array with one value, for example // "0x8888f1f195afa192cfee86069858" must be decoded as [ "0x8888f1f195afa192cfee86069858" ] - ToAddress []string `json:"toAddress,omitempty"` + ToAddress EthAddressList `json:"toAddress,omitempty"` // Restricts traces returned to those emitted after this epoch (in hex). // Optional, default: 0. diff --git a/itests/eth_transactions_test.go b/itests/eth_transactions_test.go index f73a0fe3edc..c7c85cd1398 100644 --- a/itests/eth_transactions_test.go +++ b/itests/eth_transactions_test.go @@ -719,8 +719,8 @@ func TestTraceFilter(t *testing.T) { filter = ethtypes.EthTraceFilterCriteria{ FromBlock: &fromBlock, ToBlock: &toBlock, - FromAddress: []string{ethAddr.String()}, - ToAddress: []string{contractAddr.String()}, + FromAddress: ethtypes.EthAddressList{ethAddr}, + ToAddress: ethtypes.EthAddressList{contractAddr}, } // Trace filter should find the transaction diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 04789a3043e..ef4f3792f3d 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1080,19 +1080,6 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace traceCounter := 0 - var fromDecodedAddresses []ethtypes.EthAddress - var toDecodedAddresses []ethtypes.EthAddress - - fromDecodedAddresses, err = decodeAddressFilter(filter.FromAddress) - if err != nil { - return nil, xerrors.Errorf("cannot decode FromAddress: %w", err) - } - - toDecodedAddresses, err = decodeAddressFilter(filter.ToAddress) - if err != nil { - return nil, xerrors.Errorf("cannot decode ToAddress: %w", err) - } - for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { blockTraces, err := a.EthTraceBlock(ctx, strconv.FormatUint(uint64(blkNum), 10)) if err != nil { @@ -1100,7 +1087,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace } for _, blockTrace := range blockTraces { - match, err := matchFilterCriteria(blockTrace, filter, fromDecodedAddresses, toDecodedAddresses) + match, err := matchFilterCriteria(blockTrace, filter, filter.FromAddress, filter.ToAddress) if err != nil { return nil, xerrors.Errorf("cannot match filter for block %d: %w", blkNum, err) } From 9e5eac6c85103f3d08909a7f40c224df565a45ee Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 15 Jul 2024 14:39:48 -1000 Subject: [PATCH 19/42] use *EthUint64 for filter.Count and filter.After --- build/openrpc/full.json | 26 +- build/openrpc/gateway.json | 26 +- chain/types/ethtypes/eth_types.go | 4 +- documentation/en/api-v1-unstable-methods.md | 8584 +++++++++++++++++++ node/impl/full/eth.go | 5 +- 5 files changed, 8628 insertions(+), 17 deletions(-) diff --git a/build/openrpc/full.json b/build/openrpc/full.json index c856d8a9a06..f17ab5574ac 100644 --- a/build/openrpc/full.json +++ b/build/openrpc/full.json @@ -5773,13 +5773,13 @@ "fromBlock": "string value", "toBlock": "string value", "fromAddress": [ - "string value" + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], "toAddress": [ - "string value" + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], - "after": 123, - "count": 123 + "after": "0x5", + "count": "0x5" } ], "additionalProperties": false, @@ -5794,7 +5794,14 @@ }, "fromAddress": { "items": { - "type": "string" + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "maxItems": 20, + "minItems": 20, + "type": "array" }, "type": "array" }, @@ -5803,7 +5810,14 @@ }, "toAddress": { "items": { - "type": "string" + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "maxItems": 20, + "minItems": 20, + "type": "array" }, "type": "array" }, diff --git a/build/openrpc/gateway.json b/build/openrpc/gateway.json index 34827877497..01fe4c587fb 100644 --- a/build/openrpc/gateway.json +++ b/build/openrpc/gateway.json @@ -4711,13 +4711,13 @@ "fromBlock": "string value", "toBlock": "string value", "fromAddress": [ - "string value" + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], "toAddress": [ - "string value" + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], - "after": 123, - "count": 123 + "after": "0x5", + "count": "0x5" } ], "additionalProperties": false, @@ -4732,7 +4732,14 @@ }, "fromAddress": { "items": { - "type": "string" + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "maxItems": 20, + "minItems": 20, + "type": "array" }, "type": "array" }, @@ -4741,7 +4748,14 @@ }, "toAddress": { "items": { - "type": "string" + "items": { + "description": "Number is a number", + "title": "number", + "type": "number" + }, + "maxItems": 20, + "minItems": 20, + "type": "array" }, "type": "array" }, diff --git a/chain/types/ethtypes/eth_types.go b/chain/types/ethtypes/eth_types.go index 635d4022b1c..c7718e8c0a9 100644 --- a/chain/types/ethtypes/eth_types.go +++ b/chain/types/ethtypes/eth_types.go @@ -1059,11 +1059,11 @@ type EthTraceFilterCriteria struct { // Restricts traces returned to those emitted after this epoch (in hex). // Optional, default: 0. - After *int `json:"after,omitempty"` + After *EthUint64 `json:"after,omitempty"` // Limits the number of traces returned. // Optional, default: all traces. - Count *int `json:"count,omitempty"` + Count *EthUint64 `json:"count,omitempty"` } type EthCallTraceAction struct { diff --git a/documentation/en/api-v1-unstable-methods.md b/documentation/en/api-v1-unstable-methods.md index e69de29bb2d..86039f3cee2 100644 --- a/documentation/en/api-v1-unstable-methods.md +++ b/documentation/en/api-v1-unstable-methods.md @@ -0,0 +1,8584 @@ +# Groups +* [](#) + * [Closing](#Closing) + * [Discover](#Discover) + * [Session](#Session) + * [Shutdown](#Shutdown) + * [Version](#Version) +* [Auth](#Auth) + * [AuthNew](#AuthNew) + * [AuthVerify](#AuthVerify) +* [Chain](#Chain) + * [ChainBlockstoreInfo](#ChainBlockstoreInfo) + * [ChainCheckBlockstore](#ChainCheckBlockstore) + * [ChainDeleteObj](#ChainDeleteObj) + * [ChainExport](#ChainExport) + * [ChainExportRangeInternal](#ChainExportRangeInternal) + * [ChainGetBlock](#ChainGetBlock) + * [ChainGetBlockMessages](#ChainGetBlockMessages) + * [ChainGetEvents](#ChainGetEvents) + * [ChainGetGenesis](#ChainGetGenesis) + * [ChainGetMessage](#ChainGetMessage) + * [ChainGetMessagesInTipset](#ChainGetMessagesInTipset) + * [ChainGetNode](#ChainGetNode) + * [ChainGetParentMessages](#ChainGetParentMessages) + * [ChainGetParentReceipts](#ChainGetParentReceipts) + * [ChainGetPath](#ChainGetPath) + * [ChainGetTipSet](#ChainGetTipSet) + * [ChainGetTipSetAfterHeight](#ChainGetTipSetAfterHeight) + * [ChainGetTipSetByHeight](#ChainGetTipSetByHeight) + * [ChainHasObj](#ChainHasObj) + * [ChainHead](#ChainHead) + * [ChainHotGC](#ChainHotGC) + * [ChainNotify](#ChainNotify) + * [ChainPrune](#ChainPrune) + * [ChainPutObj](#ChainPutObj) + * [ChainReadObj](#ChainReadObj) + * [ChainSetHead](#ChainSetHead) + * [ChainStatObj](#ChainStatObj) + * [ChainTipSetWeight](#ChainTipSetWeight) +* [Create](#Create) + * [CreateBackup](#CreateBackup) +* [Eth](#Eth) + * [EthAccounts](#EthAccounts) + * [EthAddressToFilecoinAddress](#EthAddressToFilecoinAddress) + * [EthBlockNumber](#EthBlockNumber) + * [EthCall](#EthCall) + * [EthChainId](#EthChainId) + * [EthEstimateGas](#EthEstimateGas) + * [EthFeeHistory](#EthFeeHistory) + * [EthGasPrice](#EthGasPrice) + * [EthGetBalance](#EthGetBalance) + * [EthGetBlockByHash](#EthGetBlockByHash) + * [EthGetBlockByNumber](#EthGetBlockByNumber) + * [EthGetBlockTransactionCountByHash](#EthGetBlockTransactionCountByHash) + * [EthGetBlockTransactionCountByNumber](#EthGetBlockTransactionCountByNumber) + * [EthGetCode](#EthGetCode) + * [EthGetFilterChanges](#EthGetFilterChanges) + * [EthGetFilterLogs](#EthGetFilterLogs) + * [EthGetLogs](#EthGetLogs) + * [EthGetMessageCidByTransactionHash](#EthGetMessageCidByTransactionHash) + * [EthGetStorageAt](#EthGetStorageAt) + * [EthGetTransactionByBlockHashAndIndex](#EthGetTransactionByBlockHashAndIndex) + * [EthGetTransactionByBlockNumberAndIndex](#EthGetTransactionByBlockNumberAndIndex) + * [EthGetTransactionByHash](#EthGetTransactionByHash) + * [EthGetTransactionByHashLimited](#EthGetTransactionByHashLimited) + * [EthGetTransactionCount](#EthGetTransactionCount) + * [EthGetTransactionHashByCid](#EthGetTransactionHashByCid) + * [EthGetTransactionReceipt](#EthGetTransactionReceipt) + * [EthGetTransactionReceiptLimited](#EthGetTransactionReceiptLimited) + * [EthMaxPriorityFeePerGas](#EthMaxPriorityFeePerGas) + * [EthNewBlockFilter](#EthNewBlockFilter) + * [EthNewFilter](#EthNewFilter) + * [EthNewPendingTransactionFilter](#EthNewPendingTransactionFilter) + * [EthProtocolVersion](#EthProtocolVersion) + * [EthSendRawTransaction](#EthSendRawTransaction) + * [EthSubscribe](#EthSubscribe) + * [EthSyncing](#EthSyncing) + * [EthTraceBlock](#EthTraceBlock) + * [EthTraceFilter](#EthTraceFilter) + * [EthTraceReplayBlockTransactions](#EthTraceReplayBlockTransactions) + * [EthTraceTransaction](#EthTraceTransaction) + * [EthUninstallFilter](#EthUninstallFilter) + * [EthUnsubscribe](#EthUnsubscribe) +* [F3](#F3) + * [F3GetCertificate](#F3GetCertificate) + * [F3GetLatestCertificate](#F3GetLatestCertificate) + * [F3Participate](#F3Participate) +* [Filecoin](#Filecoin) + * [FilecoinAddressToEthAddress](#FilecoinAddressToEthAddress) +* [Gas](#Gas) + * [GasEstimateFeeCap](#GasEstimateFeeCap) + * [GasEstimateGasLimit](#GasEstimateGasLimit) + * [GasEstimateGasPremium](#GasEstimateGasPremium) + * [GasEstimateMessageGas](#GasEstimateMessageGas) +* [Get](#Get) + * [GetActorEventsRaw](#GetActorEventsRaw) +* [I](#I) + * [ID](#ID) +* [Log](#Log) + * [LogAlerts](#LogAlerts) + * [LogList](#LogList) + * [LogSetLevel](#LogSetLevel) +* [Market](#Market) + * [MarketAddBalance](#MarketAddBalance) + * [MarketGetReserved](#MarketGetReserved) + * [MarketReleaseFunds](#MarketReleaseFunds) + * [MarketReserveFunds](#MarketReserveFunds) + * [MarketWithdraw](#MarketWithdraw) +* [Miner](#Miner) + * [MinerCreateBlock](#MinerCreateBlock) + * [MinerGetBaseInfo](#MinerGetBaseInfo) +* [Mpool](#Mpool) + * [MpoolBatchPush](#MpoolBatchPush) + * [MpoolBatchPushMessage](#MpoolBatchPushMessage) + * [MpoolBatchPushUntrusted](#MpoolBatchPushUntrusted) + * [MpoolCheckMessages](#MpoolCheckMessages) + * [MpoolCheckPendingMessages](#MpoolCheckPendingMessages) + * [MpoolCheckReplaceMessages](#MpoolCheckReplaceMessages) + * [MpoolClear](#MpoolClear) + * [MpoolGetConfig](#MpoolGetConfig) + * [MpoolGetNonce](#MpoolGetNonce) + * [MpoolPending](#MpoolPending) + * [MpoolPush](#MpoolPush) + * [MpoolPushMessage](#MpoolPushMessage) + * [MpoolPushUntrusted](#MpoolPushUntrusted) + * [MpoolSelect](#MpoolSelect) + * [MpoolSetConfig](#MpoolSetConfig) + * [MpoolSub](#MpoolSub) +* [Msig](#Msig) + * [MsigAddApprove](#MsigAddApprove) + * [MsigAddCancel](#MsigAddCancel) + * [MsigAddPropose](#MsigAddPropose) + * [MsigApprove](#MsigApprove) + * [MsigApproveTxnHash](#MsigApproveTxnHash) + * [MsigCancel](#MsigCancel) + * [MsigCancelTxnHash](#MsigCancelTxnHash) + * [MsigCreate](#MsigCreate) + * [MsigGetAvailableBalance](#MsigGetAvailableBalance) + * [MsigGetPending](#MsigGetPending) + * [MsigGetVested](#MsigGetVested) + * [MsigGetVestingSchedule](#MsigGetVestingSchedule) + * [MsigPropose](#MsigPropose) + * [MsigRemoveSigner](#MsigRemoveSigner) + * [MsigSwapApprove](#MsigSwapApprove) + * [MsigSwapCancel](#MsigSwapCancel) + * [MsigSwapPropose](#MsigSwapPropose) +* [Net](#Net) + * [NetAddrsListen](#NetAddrsListen) + * [NetAgentVersion](#NetAgentVersion) + * [NetAutoNatStatus](#NetAutoNatStatus) + * [NetBandwidthStats](#NetBandwidthStats) + * [NetBandwidthStatsByPeer](#NetBandwidthStatsByPeer) + * [NetBandwidthStatsByProtocol](#NetBandwidthStatsByProtocol) + * [NetBlockAdd](#NetBlockAdd) + * [NetBlockList](#NetBlockList) + * [NetBlockRemove](#NetBlockRemove) + * [NetConnect](#NetConnect) + * [NetConnectedness](#NetConnectedness) + * [NetDisconnect](#NetDisconnect) + * [NetFindPeer](#NetFindPeer) + * [NetLimit](#NetLimit) + * [NetListening](#NetListening) + * [NetPeerInfo](#NetPeerInfo) + * [NetPeers](#NetPeers) + * [NetPing](#NetPing) + * [NetProtectAdd](#NetProtectAdd) + * [NetProtectList](#NetProtectList) + * [NetProtectRemove](#NetProtectRemove) + * [NetPubsubScores](#NetPubsubScores) + * [NetSetLimit](#NetSetLimit) + * [NetStat](#NetStat) + * [NetVersion](#NetVersion) +* [Node](#Node) + * [NodeStatus](#NodeStatus) +* [Paych](#Paych) + * [PaychAllocateLane](#PaychAllocateLane) + * [PaychAvailableFunds](#PaychAvailableFunds) + * [PaychAvailableFundsByFromTo](#PaychAvailableFundsByFromTo) + * [PaychCollect](#PaychCollect) + * [PaychFund](#PaychFund) + * [PaychGet](#PaychGet) + * [PaychGetWaitReady](#PaychGetWaitReady) + * [PaychList](#PaychList) + * [PaychNewPayment](#PaychNewPayment) + * [PaychSettle](#PaychSettle) + * [PaychStatus](#PaychStatus) + * [PaychVoucherAdd](#PaychVoucherAdd) + * [PaychVoucherCheckSpendable](#PaychVoucherCheckSpendable) + * [PaychVoucherCheckValid](#PaychVoucherCheckValid) + * [PaychVoucherCreate](#PaychVoucherCreate) + * [PaychVoucherList](#PaychVoucherList) + * [PaychVoucherSubmit](#PaychVoucherSubmit) +* [Start](#Start) + * [StartTime](#StartTime) +* [State](#State) + * [StateAccountKey](#StateAccountKey) + * [StateActorCodeCIDs](#StateActorCodeCIDs) + * [StateActorManifestCID](#StateActorManifestCID) + * [StateAllMinerFaults](#StateAllMinerFaults) + * [StateCall](#StateCall) + * [StateChangedActors](#StateChangedActors) + * [StateCirculatingSupply](#StateCirculatingSupply) + * [StateCompute](#StateCompute) + * [StateComputeDataCID](#StateComputeDataCID) + * [StateDealProviderCollateralBounds](#StateDealProviderCollateralBounds) + * [StateDecodeParams](#StateDecodeParams) + * [StateEncodeParams](#StateEncodeParams) + * [StateGetActor](#StateGetActor) + * [StateGetAllAllocations](#StateGetAllAllocations) + * [StateGetAllClaims](#StateGetAllClaims) + * [StateGetAllocation](#StateGetAllocation) + * [StateGetAllocationForPendingDeal](#StateGetAllocationForPendingDeal) + * [StateGetAllocationIdForPendingDeal](#StateGetAllocationIdForPendingDeal) + * [StateGetAllocations](#StateGetAllocations) + * [StateGetBeaconEntry](#StateGetBeaconEntry) + * [StateGetClaim](#StateGetClaim) + * [StateGetClaims](#StateGetClaims) + * [StateGetNetworkParams](#StateGetNetworkParams) + * [StateGetRandomnessDigestFromBeacon](#StateGetRandomnessDigestFromBeacon) + * [StateGetRandomnessDigestFromTickets](#StateGetRandomnessDigestFromTickets) + * [StateGetRandomnessFromBeacon](#StateGetRandomnessFromBeacon) + * [StateGetRandomnessFromTickets](#StateGetRandomnessFromTickets) + * [StateListActors](#StateListActors) + * [StateListMessages](#StateListMessages) + * [StateListMiners](#StateListMiners) + * [StateLookupID](#StateLookupID) + * [StateLookupRobustAddress](#StateLookupRobustAddress) + * [StateMarketBalance](#StateMarketBalance) + * [StateMarketDeals](#StateMarketDeals) + * [StateMarketParticipants](#StateMarketParticipants) + * [StateMarketStorageDeal](#StateMarketStorageDeal) + * [StateMinerActiveSectors](#StateMinerActiveSectors) + * [StateMinerAllocated](#StateMinerAllocated) + * [StateMinerAvailableBalance](#StateMinerAvailableBalance) + * [StateMinerDeadlines](#StateMinerDeadlines) + * [StateMinerFaults](#StateMinerFaults) + * [StateMinerInfo](#StateMinerInfo) + * [StateMinerInitialPledgeCollateral](#StateMinerInitialPledgeCollateral) + * [StateMinerPartitions](#StateMinerPartitions) + * [StateMinerPower](#StateMinerPower) + * [StateMinerPreCommitDepositForPower](#StateMinerPreCommitDepositForPower) + * [StateMinerProvingDeadline](#StateMinerProvingDeadline) + * [StateMinerRecoveries](#StateMinerRecoveries) + * [StateMinerSectorAllocated](#StateMinerSectorAllocated) + * [StateMinerSectorCount](#StateMinerSectorCount) + * [StateMinerSectors](#StateMinerSectors) + * [StateNetworkName](#StateNetworkName) + * [StateNetworkVersion](#StateNetworkVersion) + * [StateReadState](#StateReadState) + * [StateReplay](#StateReplay) + * [StateSearchMsg](#StateSearchMsg) + * [StateSectorExpiration](#StateSectorExpiration) + * [StateSectorGetInfo](#StateSectorGetInfo) + * [StateSectorPartition](#StateSectorPartition) + * [StateSectorPreCommitInfo](#StateSectorPreCommitInfo) + * [StateVMCirculatingSupplyInternal](#StateVMCirculatingSupplyInternal) + * [StateVerifiedClientStatus](#StateVerifiedClientStatus) + * [StateVerifiedRegistryRootKey](#StateVerifiedRegistryRootKey) + * [StateVerifierStatus](#StateVerifierStatus) + * [StateWaitMsg](#StateWaitMsg) +* [Subscribe](#Subscribe) + * [SubscribeActorEventsRaw](#SubscribeActorEventsRaw) +* [Sync](#Sync) + * [SyncCheckBad](#SyncCheckBad) + * [SyncCheckpoint](#SyncCheckpoint) + * [SyncIncomingBlocks](#SyncIncomingBlocks) + * [SyncMarkBad](#SyncMarkBad) + * [SyncState](#SyncState) + * [SyncSubmitBlock](#SyncSubmitBlock) + * [SyncUnmarkAllBad](#SyncUnmarkAllBad) + * [SyncUnmarkBad](#SyncUnmarkBad) + * [SyncValidateTipset](#SyncValidateTipset) +* [Wallet](#Wallet) + * [WalletBalance](#WalletBalance) + * [WalletDefaultAddress](#WalletDefaultAddress) + * [WalletDelete](#WalletDelete) + * [WalletExport](#WalletExport) + * [WalletHas](#WalletHas) + * [WalletImport](#WalletImport) + * [WalletList](#WalletList) + * [WalletNew](#WalletNew) + * [WalletSetDefault](#WalletSetDefault) + * [WalletSign](#WalletSign) + * [WalletSignMessage](#WalletSignMessage) + * [WalletValidateAddress](#WalletValidateAddress) + * [WalletVerify](#WalletVerify) +* [Web3](#Web3) + * [Web3ClientVersion](#Web3ClientVersion) +## + + +### Closing + + +Perms: read + +Inputs: `null` + +Response: `{}` + +### Discover + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "info": { + "title": "Lotus RPC API", + "version": "1.2.1/generated=2020-11-22T08:22:42-06:00" + }, + "methods": [], + "openrpc": "1.2.6" +} +``` + +### Session + + +Perms: read + +Inputs: `null` + +Response: `"07070707-0707-0707-0707-070707070707"` + +### Shutdown + + +Perms: admin + +Inputs: `null` + +Response: `{}` + +### Version + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "Version": "string value", + "APIVersion": 131840, + "BlockDelay": 42 +} +``` + +## Auth + + +### AuthNew + + +Perms: admin + +Inputs: +```json +[ + [ + "write" + ] +] +``` + +Response: `"Ynl0ZSBhcnJheQ=="` + +### AuthVerify + + +Perms: read + +Inputs: +```json +[ + "string value" +] +``` + +Response: +```json +[ + "write" +] +``` + +## Chain +The Chain method group contains methods for interacting with the +blockchain, but that do not require any form of state computation. + + +### ChainBlockstoreInfo +ChainBlockstoreInfo returns some basic information about the blockstore + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "abc": 123 +} +``` + +### ChainCheckBlockstore +ChainCheckBlockstore performs an (asynchronous) health check on the chain/state blockstore +if supported by the underlying implementation. + + +Perms: admin + +Inputs: `null` + +Response: `{}` + +### ChainDeleteObj +ChainDeleteObj deletes node referenced by the given CID + + +Perms: admin + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: `{}` + +### ChainExport +ChainExport returns a stream of bytes with CAR dump of chain data. +The exported chain data includes the header chain from the given tipset +back to genesis, the entire genesis state, and the most recent 'nroots' +state trees. +If oldmsgskip is set, messages from before the requested roots are also not included. + + +Perms: read + +Inputs: +```json +[ + 10101, + true, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"Ynl0ZSBhcnJheQ=="` + +### ChainExportRangeInternal +ChainExportRangeInternal triggers the export of a chain +CAR-snapshot directly to disk. It is similar to ChainExport, +except, depending on options, the snapshot can include receipts, +messages and stateroots for the length between the specified head +and tail, thus producing "archival-grade" snapshots that include +all the on-chain data. The header chain is included back to +genesis and these snapshots can be used to initialize Filecoin +nodes. + + +Perms: admin + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + { + "WriteBufferSize": 123, + "NumWorkers": 123, + "IncludeMessages": true, + "IncludeReceipts": true, + "IncludeStateRoots": true + } +] +``` + +Response: `{}` + +### ChainGetBlock +ChainGetBlock returns the block specified by the given CID. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +{ + "Miner": "f01234", + "Ticket": { + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "ElectionProof": { + "WinCount": 9, + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "BeaconEntries": [ + { + "Round": 42, + "Data": "Ynl0ZSBhcnJheQ==" + } + ], + "WinPoStProof": [ + { + "PoStProof": 8, + "ProofBytes": "Ynl0ZSBhcnJheQ==" + } + ], + "Parents": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ], + "ParentWeight": "0", + "Height": 10101, + "ParentStateRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "ParentMessageReceipts": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Messages": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "BLSAggregate": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Timestamp": 42, + "BlockSig": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "ForkSignaling": 42, + "ParentBaseFee": "0" +} +``` + +### ChainGetBlockMessages +ChainGetBlockMessages returns messages stored in the specified block. + +Note: If there are multiple blocks in a tipset, it's likely that some +messages will be duplicated. It's also possible for blocks in a tipset to have +different messages from the same sender at the same nonce. When that happens, +only the first message (in a block with lowest ticket) will be considered +for execution + +NOTE: THIS METHOD SHOULD ONLY BE USED FOR GETTING MESSAGES IN A SPECIFIC BLOCK + +DO NOT USE THIS METHOD TO GET MESSAGES INCLUDED IN A TIPSET +Use ChainGetParentMessages, which will perform correct message deduplication + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +{ + "BlsMessages": [ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + ], + "SecpkMessages": [ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + ], + "Cids": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ] +} +``` + +### ChainGetEvents +ChainGetEvents returns the events under an event AMT root CID. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +[ + { + "Emitter": 1000, + "Entries": [ + { + "Flags": 7, + "Key": "string value", + "Codec": 42, + "Value": "Ynl0ZSBhcnJheQ==" + } + ] + } +] +``` + +### ChainGetGenesis +ChainGetGenesis returns the genesis tipset. + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "Cids": null, + "Blocks": null, + "Height": 0 +} +``` + +### ChainGetMessage +ChainGetMessage reads a message referenced by the specified CID from the +chain blockstore. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +{ + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } +} +``` + +### ChainGetMessagesInTipset +ChainGetMessagesInTipset returns message stores in current tipset + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "Cid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + } +] +``` + +### ChainGetNode + + +Perms: read + +Inputs: +```json +[ + "string value" +] +``` + +Response: +```json +{ + "Cid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Obj": {} +} +``` + +### ChainGetParentMessages +ChainGetParentMessages returns messages stored in parent tipset of the +specified block. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +[ + { + "Cid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + } +] +``` + +### ChainGetParentReceipts +ChainGetParentReceipts returns receipts for messages in parent tipset of +the specified block. The receipts in the list returned is one-to-one with the +messages returned by a call to ChainGetParentMessages with the same blockCid. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +[ + { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "GasUsed": 9, + "EventsRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + } +] +``` + +### ChainGetPath +ChainGetPath returns a set of revert/apply operations needed to get from +one tipset to another, for example: +``` + to + ^ +from tAA + ^ ^ +tBA tAB + ^---*--^ + ^ + tRR +``` +Would return `[revert(tBA), apply(tAB), apply(tAA)]` + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "Type": "string value", + "Val": { + "Cids": null, + "Blocks": null, + "Height": 0 + } + } +] +``` + +### ChainGetTipSet +ChainGetTipSet returns the tipset specified by the given TipSetKey. + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Cids": null, + "Blocks": null, + "Height": 0 +} +``` + +### ChainGetTipSetAfterHeight +ChainGetTipSetAfterHeight looks back for a tipset at the specified epoch. +If there are no blocks at the specified epoch, the first non-nil tipset at a later epoch +will be returned. + + +Perms: read + +Inputs: +```json +[ + 10101, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Cids": null, + "Blocks": null, + "Height": 0 +} +``` + +### ChainGetTipSetByHeight +ChainGetTipSetByHeight looks back for a tipset at the specified epoch. +If there are no blocks at the specified epoch, a tipset at an earlier epoch +will be returned. + + +Perms: read + +Inputs: +```json +[ + 10101, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Cids": null, + "Blocks": null, + "Height": 0 +} +``` + +### ChainHasObj +ChainHasObj checks if a given CID exists in the chain blockstore. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: `true` + +### ChainHead +ChainHead returns the current head of the chain. + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "Cids": null, + "Blocks": null, + "Height": 0 +} +``` + +### ChainHotGC +ChainHotGC does online (badger) GC on the hot store; only supported if you are using +the splitstore + + +Perms: admin + +Inputs: +```json +[ + { + "Threshold": 12.3, + "Periodic": true, + "Moving": true + } +] +``` + +Response: `{}` + +### ChainNotify +ChainNotify returns channel with chain head updates. +First message is guaranteed to be of len == 1, and type == 'current'. + + +Perms: read + +Inputs: `null` + +Response: +```json +[ + { + "Type": "string value", + "Val": { + "Cids": null, + "Blocks": null, + "Height": 0 + } + } +] +``` + +### ChainPrune +ChainPrune forces compaction on cold store and garbage collects; only supported if you +are using the splitstore + + +Perms: admin + +Inputs: +```json +[ + { + "MovingGC": true, + "RetainState": 9 + } +] +``` + +Response: `{}` + +### ChainPutObj +ChainPutObj puts a given object into the block store + + +Perms: admin + +Inputs: +```json +[ + {} +] +``` + +Response: `{}` + +### ChainReadObj +ChainReadObj reads ipld nodes referenced by the specified CID from chain +blockstore and returns raw bytes. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: `"Ynl0ZSBhcnJheQ=="` + +### ChainSetHead +ChainSetHead forcefully sets current chain head. Use with caution. + + +Perms: admin + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `{}` + +### ChainStatObj +ChainStatObj returns statistics about the graph referenced by 'obj'. +If 'base' is also specified, then the returned stat will be a diff +between the two objects. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +{ + "Size": 42, + "Links": 42 +} +``` + +### ChainTipSetWeight +ChainTipSetWeight computes weight for the specified tipset. + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +## Create + + +### CreateBackup +CreateBackup creates node backup onder the specified file name. The +method requires that the lotus daemon is running with the +LOTUS_BACKUP_BASE_PATH environment variable set to some path, and that +the path specified when calling CreateBackup is within the base path + + +Perms: admin + +Inputs: +```json +[ + "string value" +] +``` + +Response: `{}` + +## Eth +These methods are used for Ethereum-compatible JSON-RPC calls + +EthAccounts will always return [] since we don't expect Lotus to manage private keys + + +### EthAccounts +There are not yet any comments for this method. + +Perms: read + +Inputs: `null` + +Response: +```json +[ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" +] +``` + +### EthAddressToFilecoinAddress +EthAddressToFilecoinAddress converts an EthAddress into an f410 Filecoin Address + + +Perms: read + +Inputs: +```json +[ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" +] +``` + +Response: `"f01234"` + +### EthBlockNumber +EthBlockNumber returns the height of the latest (heaviest) TipSet + + +Perms: read + +Inputs: `null` + +Response: `"0x5"` + +### EthCall + + +Perms: read + +Inputs: +```json +[ + { + "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "gas": "0x5", + "gasPrice": "0x0", + "value": "0x0", + "data": "0x07" + }, + "string value" +] +``` + +Response: `"0x07"` + +### EthChainId + + +Perms: read + +Inputs: `null` + +Response: `"0x5"` + +### EthEstimateGas + + +Perms: read + +Inputs: +```json +[ + "Bw==" +] +``` + +Response: `"0x5"` + +### EthFeeHistory + + +Perms: read + +Inputs: +```json +[ + "Bw==" +] +``` + +Response: +```json +{ + "oldestBlock": "0x5", + "baseFeePerGas": [ + "0x0" + ], + "gasUsedRatio": [ + 12.3 + ], + "reward": [] +} +``` + +### EthGasPrice + + +Perms: read + +Inputs: `null` + +Response: `"0x0"` + +### EthGetBalance + + +Perms: read + +Inputs: +```json +[ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "string value" +] +``` + +Response: `"0x0"` + +### EthGetBlockByHash + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + true +] +``` + +Response: +```json +{ + "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "parentHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "sha3Uncles": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "miner": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "stateRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionsRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "receiptsRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "logsBloom": "0x07", + "difficulty": "0x5", + "totalDifficulty": "0x5", + "number": "0x5", + "gasLimit": "0x5", + "gasUsed": "0x5", + "timestamp": "0x5", + "extraData": "0x07", + "mixHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "nonce": "0x0707070707070707", + "baseFeePerGas": "0x0", + "size": "0x5", + "transactions": [ + {} + ], + "uncles": [ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" + ] +} +``` + +### EthGetBlockByNumber + + +Perms: read + +Inputs: +```json +[ + "string value", + true +] +``` + +Response: +```json +{ + "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "parentHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "sha3Uncles": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "miner": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "stateRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionsRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "receiptsRoot": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "logsBloom": "0x07", + "difficulty": "0x5", + "totalDifficulty": "0x5", + "number": "0x5", + "gasLimit": "0x5", + "gasUsed": "0x5", + "timestamp": "0x5", + "extraData": "0x07", + "mixHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "nonce": "0x0707070707070707", + "baseFeePerGas": "0x0", + "size": "0x5", + "transactions": [ + {} + ], + "uncles": [ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" + ] +} +``` + +### EthGetBlockTransactionCountByHash +EthGetBlockTransactionCountByHash returns the number of messages in the TipSet + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" +] +``` + +Response: `"0x5"` + +### EthGetBlockTransactionCountByNumber +EthGetBlockTransactionCountByNumber returns the number of messages in the TipSet + + +Perms: read + +Inputs: +```json +[ + "0x5" +] +``` + +Response: `"0x5"` + +### EthGetCode + + +Perms: read + +Inputs: +```json +[ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "string value" +] +``` + +Response: `"0x07"` + +### EthGetFilterChanges +Polling method for a filter, returns event logs which occurred since last poll. +(requires write perm since timestamp of last filter execution will be written) + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" +] +``` + +Response: +```json +[ + {} +] +``` + +### EthGetFilterLogs +Returns event logs matching filter with given id. +(requires write perm since timestamp of last filter execution will be written) + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" +] +``` + +Response: +```json +[ + {} +] +``` + +### EthGetLogs +Returns event logs matching given filter spec. + + +Perms: read + +Inputs: +```json +[ + { + "fromBlock": "2301220", + "address": [ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" + ], + "topics": null + } +] +``` + +Response: +```json +[ + {} +] +``` + +### EthGetMessageCidByTransactionHash + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### EthGetStorageAt + + +Perms: read + +Inputs: +```json +[ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "0x07", + "string value" +] +``` + +Response: `"0x07"` + +### EthGetTransactionByBlockHashAndIndex + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "0x5" +] +``` + +Response: +```json +{ + "chainId": "0x5", + "nonce": "0x5", + "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": "0x5", + "transactionIndex": "0x5", + "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "value": "0x0", + "type": "0x5", + "input": "0x07", + "gas": "0x5", + "maxFeePerGas": "0x0", + "maxPriorityFeePerGas": "0x0", + "gasPrice": "0x0", + "accessList": [ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" + ], + "v": "0x0", + "r": "0x0", + "s": "0x0" +} +``` + +### EthGetTransactionByBlockNumberAndIndex + + +Perms: read + +Inputs: +```json +[ + "0x5", + "0x5" +] +``` + +Response: +```json +{ + "chainId": "0x5", + "nonce": "0x5", + "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": "0x5", + "transactionIndex": "0x5", + "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "value": "0x0", + "type": "0x5", + "input": "0x07", + "gas": "0x5", + "maxFeePerGas": "0x0", + "maxPriorityFeePerGas": "0x0", + "gasPrice": "0x0", + "accessList": [ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" + ], + "v": "0x0", + "r": "0x0", + "s": "0x0" +} +``` + +### EthGetTransactionByHash + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" +] +``` + +Response: +```json +{ + "chainId": "0x5", + "nonce": "0x5", + "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": "0x5", + "transactionIndex": "0x5", + "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "value": "0x0", + "type": "0x5", + "input": "0x07", + "gas": "0x5", + "maxFeePerGas": "0x0", + "maxPriorityFeePerGas": "0x0", + "gasPrice": "0x0", + "accessList": [ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" + ], + "v": "0x0", + "r": "0x0", + "s": "0x0" +} +``` + +### EthGetTransactionByHashLimited + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + 10101 +] +``` + +Response: +```json +{ + "chainId": "0x5", + "nonce": "0x5", + "hash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": "0x5", + "transactionIndex": "0x5", + "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "value": "0x0", + "type": "0x5", + "input": "0x07", + "gas": "0x5", + "maxFeePerGas": "0x0", + "maxPriorityFeePerGas": "0x0", + "gasPrice": "0x0", + "accessList": [ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" + ], + "v": "0x0", + "r": "0x0", + "s": "0x0" +} +``` + +### EthGetTransactionCount + + +Perms: read + +Inputs: +```json +[ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "string value" +] +``` + +Response: `"0x5"` + +### EthGetTransactionHashByCid + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` + +### EthGetTransactionReceipt + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" +] +``` + +Response: +```json +{ + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionIndex": "0x5", + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": "0x5", + "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "root": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "status": "0x5", + "contractAddress": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "cumulativeGasUsed": "0x5", + "gasUsed": "0x5", + "effectiveGasPrice": "0x0", + "logsBloom": "0x07", + "logs": [ + { + "address": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "data": "0x07", + "topics": [ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" + ], + "removed": true, + "logIndex": "0x5", + "transactionIndex": "0x5", + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": "0x5" + } + ], + "type": "0x5" +} +``` + +### EthGetTransactionReceiptLimited + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + 10101 +] +``` + +Response: +```json +{ + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionIndex": "0x5", + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": "0x5", + "from": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "to": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "root": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "status": "0x5", + "contractAddress": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "cumulativeGasUsed": "0x5", + "gasUsed": "0x5", + "effectiveGasPrice": "0x0", + "logsBloom": "0x07", + "logs": [ + { + "address": "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031", + "data": "0x07", + "topics": [ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" + ], + "removed": true, + "logIndex": "0x5", + "transactionIndex": "0x5", + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": "0x5" + } + ], + "type": "0x5" +} +``` + +### EthMaxPriorityFeePerGas + + +Perms: read + +Inputs: `null` + +Response: `"0x0"` + +### EthNewBlockFilter +Installs a persistent filter to notify when a new block arrives. + + +Perms: read + +Inputs: `null` + +Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` + +### EthNewFilter +Installs a persistent filter based on given filter spec. + + +Perms: read + +Inputs: +```json +[ + { + "fromBlock": "2301220", + "address": [ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" + ], + "topics": null + } +] +``` + +Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` + +### EthNewPendingTransactionFilter +Installs a persistent filter to notify when new messages arrive in the message pool. + + +Perms: read + +Inputs: `null` + +Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` + +### EthProtocolVersion + + +Perms: read + +Inputs: `null` + +Response: `"0x5"` + +### EthSendRawTransaction + + +Perms: read + +Inputs: +```json +[ + "0x07" +] +``` + +Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` + +### EthSubscribe +Subscribe to different event types using websockets +eventTypes is one or more of: + - newHeads: notify when new blocks arrive. + - pendingTransactions: notify when new messages arrive in the message pool. + - logs: notify new event logs that match a criteria +params contains additional parameters used with the log event type +The client will receive a stream of EthSubscriptionResponse values until EthUnsubscribe is called. + + +Perms: read + +Inputs: +```json +[ + "Bw==" +] +``` + +Response: `"0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e"` + +### EthSyncing + + +Perms: read + +Inputs: `null` + +Response: `false` + +### EthTraceBlock +Returns an OpenEthereum-compatible trace of the given block (implementing `trace_block`), +translating Filecoin semantics into Ethereum semantics and tracing both EVM and FVM calls. + +Features: + +- FVM actor create events, calls, etc. show up as if they were EVM smart contract events. +- Native FVM call inputs are ABI-encoded (Solidity ABI) as if they were calls to a + `handle_filecoin_method(uint64 method, uint64 codec, bytes params)` function + (where `codec` is the IPLD codec of `params`). +- Native FVM call outputs (return values) are ABI-encoded as `(uint32 exit_code, uint64 + codec, bytes output)` where `codec` is the IPLD codec of `output`. + +Limitations (for now): + +1. Block rewards are not included in the trace. +2. SELFDESTRUCT operations are not included in the trace. +3. EVM smart contract "create" events always specify `0xfe` as the "code" for newly created EVM smart contracts. + + +Perms: read + +Inputs: +```json +[ + "string value" +] +``` + +Response: +```json +[ + { + "type": "string value", + "error": "string value", + "subtraces": 123, + "traceAddress": [ + 123 + ], + "action": {}, + "result": {}, + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": 9, + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionPosition": 123 + } +] +``` + +### EthTraceFilter +Implements OpenEthereum-compatible API method trace_filter + + +Perms: read + +Inputs: +```json +[ + { + "fromBlock": "string value", + "toBlock": "string value", + "fromAddress": [ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" + ], + "toAddress": [ + "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" + ], + "after": "0x5", + "count": "0x5" + } +] +``` + +Response: +```json +[ + { + "type": "string value", + "error": "string value", + "subtraces": 123, + "traceAddress": [ + 123 + ], + "action": {}, + "result": {}, + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": 9, + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionPosition": 123 + } +] +``` + +### EthTraceReplayBlockTransactions +Replays all transactions in a block returning the requested traces for each transaction + + +Perms: read + +Inputs: +```json +[ + "string value", + [ + "string value" + ] +] +``` + +Response: +```json +[ + { + "output": "0x07", + "stateDiff": "string value", + "trace": [ + { + "type": "string value", + "error": "string value", + "subtraces": 123, + "traceAddress": [ + 123 + ], + "action": {}, + "result": {} + } + ], + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "vmTrace": "string value" + } +] +``` + +### EthTraceTransaction +Implmements OpenEthereum-compatible API method trace_transaction + + +Perms: read + +Inputs: +```json +[ + "string value" +] +``` + +Response: +```json +[ + { + "type": "string value", + "error": "string value", + "subtraces": 123, + "traceAddress": [ + 123 + ], + "action": {}, + "result": {}, + "blockHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "blockNumber": 9, + "transactionHash": "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e", + "transactionPosition": 123 + } +] +``` + +### EthUninstallFilter +Uninstalls a filter with given id. + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" +] +``` + +Response: `true` + +### EthUnsubscribe +Unsubscribe from a websocket subscription + + +Perms: read + +Inputs: +```json +[ + "0x37690cfec6c1bf4c3b9288c7a5d783e98731e90b0a4c177c2a374c7a9427355e" +] +``` + +Response: `true` + +## F3 + + +### F3GetCertificate +F3GetCertificate returns a finality certificate at given instance number + + +Perms: read + +Inputs: +```json +[ + 42 +] +``` + +Response: +```json +{ + "GPBFTInstance": 0, + "ECChain": null, + "SupplementalData": { + "Commitments": [ + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "PowerTable": null + }, + "Signers": [ + 0 + ], + "Signature": null, + "PowerTableDelta": null +} +``` + +### F3GetLatestCertificate +F3GetLatestCertificate returns the latest finality certificate + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "GPBFTInstance": 0, + "ECChain": null, + "SupplementalData": { + "Commitments": [ + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "PowerTable": null + }, + "Signers": [ + 0 + ], + "Signature": null, + "PowerTableDelta": null +} +``` + +### F3Participate +F3Participate should be called by a miner node to participate in signing F3 consensus. +The address should be of type ID +The returned channel will never be closed by the F3 +If it is closed without the context being cancelled, the caller should retry. +The values returned on the channel will inform the caller about participation +Empty strings will be sent if participation succeeded, non-empty strings explain possible errors. + + +Perms: admin + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `"string value"` + +## Filecoin + + +### FilecoinAddressToEthAddress +FilecoinAddressToEthAddress converts an f410 or f0 Filecoin Address to an EthAddress + + +Perms: read + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `"0x5cbeecf99d3fdb3f25e309cc264f240bb0664031"` + +## Gas + + +### GasEstimateFeeCap +GasEstimateFeeCap estimates gas fee cap + + +Perms: read + +Inputs: +```json +[ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + 9, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### GasEstimateGasLimit +GasEstimateGasLimit estimates gas used by the message and returns it. +It fails if message fails to execute. + + +Perms: read + +Inputs: +```json +[ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `9` + +### GasEstimateGasPremium +GasEstimateGasPremium estimates what gas price should be used for a +message to have high likelihood of inclusion in `nblocksincl` epochs. + + +Perms: read + +Inputs: +```json +[ + 42, + "f01234", + 9, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### GasEstimateMessageGas +GasEstimateMessageGas estimates gas values for unset message gas fields + + +Perms: read + +Inputs: +```json +[ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + { + "MaxFee": "0", + "MsgUuid": "07070707-0707-0707-0707-070707070707", + "MaximizeFeeCap": true + }, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } +} +``` + +## Get + + +### GetActorEventsRaw +GetActorEventsRaw returns all user-programmed and built-in actor events that match the given +filter. +This is a request/response API. +Results available from this API may be limited by the MaxFilterResults and MaxFilterHeightRange +configuration options and also the amount of historical data available in the node. + +This is an EXPERIMENTAL API and may be subject to change. + + +Perms: read + +Inputs: +```json +[ + { + "addresses": [ + "f01234" + ], + "fields": { + "abc": [ + { + "codec": 81, + "value": "ZGRhdGE=" + } + ] + }, + "fromHeight": 1010, + "toHeight": 1020 + } +] +``` + +Response: +```json +[ + { + "entries": [ + { + "Flags": 7, + "Key": "string value", + "Codec": 42, + "Value": "Ynl0ZSBhcnJheQ==" + } + ], + "emitter": "f01234", + "reverted": true, + "height": 10101, + "tipsetKey": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + "msgCid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + } +] +``` + +## I + + +### ID + + +Perms: read + +Inputs: `null` + +Response: `"12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf"` + +## Log + + +### LogAlerts + + +Perms: admin + +Inputs: `null` + +Response: +```json +[ + { + "Type": { + "System": "string value", + "Subsystem": "string value" + }, + "Active": true, + "LastActive": { + "Type": "string value", + "Message": "json raw message", + "Time": "0001-01-01T00:00:00Z" + }, + "LastResolved": { + "Type": "string value", + "Message": "json raw message", + "Time": "0001-01-01T00:00:00Z" + } + } +] +``` + +### LogList + + +Perms: write + +Inputs: `null` + +Response: +```json +[ + "string value" +] +``` + +### LogSetLevel + + +Perms: write + +Inputs: +```json +[ + "string value", + "string value" +] +``` + +Response: `{}` + +## Market + + +### MarketAddBalance +MarketAddBalance adds funds to the market actor + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "0" +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### MarketGetReserved +MarketGetReserved gets the amount of funds that are currently reserved for the address + + +Perms: sign + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `"0"` + +### MarketReleaseFunds +MarketReleaseFunds releases funds reserved by MarketReserveFunds + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "0" +] +``` + +Response: `{}` + +### MarketReserveFunds +MarketReserveFunds reserves funds for a deal + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "0" +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### MarketWithdraw +MarketWithdraw withdraws unlocked funds from the market actor + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "0" +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +## Miner + + +### MinerCreateBlock + + +Perms: write + +Inputs: +```json +[ + { + "Miner": "f01234", + "Parents": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + "Ticket": { + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "Eproof": { + "WinCount": 9, + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "BeaconValues": [ + { + "Round": 42, + "Data": "Ynl0ZSBhcnJheQ==" + } + ], + "Messages": [ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + ], + "Epoch": 10101, + "Timestamp": 42, + "WinningPoStProof": [ + { + "PoStProof": 8, + "ProofBytes": "Ynl0ZSBhcnJheQ==" + } + ] + } +] +``` + +Response: +```json +{ + "Header": { + "Miner": "f01234", + "Ticket": { + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "ElectionProof": { + "WinCount": 9, + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "BeaconEntries": [ + { + "Round": 42, + "Data": "Ynl0ZSBhcnJheQ==" + } + ], + "WinPoStProof": [ + { + "PoStProof": 8, + "ProofBytes": "Ynl0ZSBhcnJheQ==" + } + ], + "Parents": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ], + "ParentWeight": "0", + "Height": 10101, + "ParentStateRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "ParentMessageReceipts": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Messages": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "BLSAggregate": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Timestamp": 42, + "BlockSig": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "ForkSignaling": 42, + "ParentBaseFee": "0" + }, + "BlsMessages": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ], + "SecpkMessages": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ] +} +``` + +### MinerGetBaseInfo +There are not yet any comments for this method. + +Perms: read + +Inputs: +```json +[ + "f01234", + 10101, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "MinerPower": "0", + "NetworkPower": "0", + "Sectors": [ + { + "SealProof": 8, + "SectorNumber": 9, + "SectorKey": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "SealedCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + } + ], + "WorkerKey": "f01234", + "SectorSize": 34359738368, + "PrevBeaconEntry": { + "Round": 42, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "BeaconEntries": [ + { + "Round": 42, + "Data": "Ynl0ZSBhcnJheQ==" + } + ], + "EligibleForMining": true +} +``` + +## Mpool +The Mpool methods are for interacting with the message pool. The message pool +manages all incoming and outgoing 'messages' going over the network. + + +### MpoolBatchPush +MpoolBatchPush batch pushes a signed message to mempool. + + +Perms: write + +Inputs: +```json +[ + [ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + ] +] +``` + +Response: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +### MpoolBatchPushMessage +MpoolBatchPushMessage batch pushes a unsigned message to mempool. + + +Perms: sign + +Inputs: +```json +[ + [ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + ], + { + "MaxFee": "0", + "MsgUuid": "07070707-0707-0707-0707-070707070707", + "MaximizeFeeCap": true + } +] +``` + +Response: +```json +[ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } +] +``` + +### MpoolBatchPushUntrusted +MpoolBatchPushUntrusted batch pushes a signed message to mempool from untrusted sources. + + +Perms: write + +Inputs: +```json +[ + [ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + ] +] +``` + +Response: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +### MpoolCheckMessages +MpoolCheckMessages performs logical checks on a batch of messages + + +Perms: read + +Inputs: +```json +[ + [ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true + } + ] +] +``` + +Response: +```json +[ + [ + { + "Cid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Code": 0, + "OK": true, + "Err": "string value", + "Hint": { + "abc": 123 + } + } + ] +] +``` + +### MpoolCheckPendingMessages +MpoolCheckPendingMessages performs logical checks for all pending messages from a given address + + +Perms: read + +Inputs: +```json +[ + "f01234" +] +``` + +Response: +```json +[ + [ + { + "Cid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Code": 0, + "OK": true, + "Err": "string value", + "Hint": { + "abc": 123 + } + } + ] +] +``` + +### MpoolCheckReplaceMessages +MpoolCheckReplaceMessages performs logical checks on pending messages with replacement + + +Perms: read + +Inputs: +```json +[ + [ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + ] +] +``` + +Response: +```json +[ + [ + { + "Cid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Code": 0, + "OK": true, + "Err": "string value", + "Hint": { + "abc": 123 + } + } + ] +] +``` + +### MpoolClear +MpoolClear clears pending messages from the mpool. +If clearLocal is true, ALL messages will be cleared. +If clearLocal is false, local messages will be protected, all others will be cleared. + + +Perms: write + +Inputs: +```json +[ + true +] +``` + +Response: `{}` + +### MpoolGetConfig +MpoolGetConfig returns (a copy of) the current mpool config + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "PriorityAddrs": [ + "f01234" + ], + "SizeLimitHigh": 123, + "SizeLimitLow": 123, + "ReplaceByFeeRatio": 1.23, + "PruneCooldown": 60000000000, + "GasLimitOverestimation": 12.3 +} +``` + +### MpoolGetNonce +MpoolGetNonce gets next nonce for the specified sender. +Note that this method may not be atomic. Use MpoolPushMessage instead. + + +Perms: read + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `42` + +### MpoolPending +MpoolPending returns pending mempool messages. + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } +] +``` + +### MpoolPush +MpoolPush pushes a signed message to mempool. + + +Perms: write + +Inputs: +```json +[ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### MpoolPushMessage +MpoolPushMessage atomically assigns a nonce, signs, and pushes a message +to mempool. +maxFee is only used when GasFeeCap/GasPremium fields aren't specified + +When maxFee is set to 0, MpoolPushMessage will guess appropriate fee +based on current chain conditions + + +Perms: sign + +Inputs: +```json +[ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + { + "MaxFee": "0", + "MsgUuid": "07070707-0707-0707-0707-070707070707", + "MaximizeFeeCap": true + } +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } +} +``` + +### MpoolPushUntrusted +MpoolPushUntrusted pushes a signed message to mempool from untrusted sources. + + +Perms: write + +Inputs: +```json +[ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### MpoolSelect +MpoolSelect returns a list of pending messages for inclusion in the next block + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + 12.3 +] +``` + +Response: +```json +[ + { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } +] +``` + +### MpoolSetConfig +MpoolSetConfig sets the mpool config to (a copy of) the supplied config + + +Perms: admin + +Inputs: +```json +[ + { + "PriorityAddrs": [ + "f01234" + ], + "SizeLimitHigh": 123, + "SizeLimitLow": 123, + "ReplaceByFeeRatio": 1.23, + "PruneCooldown": 60000000000, + "GasLimitOverestimation": 12.3 + } +] +``` + +Response: `{}` + +### MpoolSub + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "Type": 0, + "Message": { + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } +} +``` + +## Msig +The Msig methods are used to interact with multisig wallets on the +filecoin network + + +### MsigAddApprove +MsigAddApprove approves a previously proposed AddSigner message +It takes the following params: , , , +, , + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + 42, + "f01234", + "f01234", + true +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigAddCancel +MsigAddCancel cancels a previously proposed AddSigner message +It takes the following params: , , , +, + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + 42, + "f01234", + true +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigAddPropose +MsigAddPropose proposes adding a signer in the multisig +It takes the following params: , , +, + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "f01234", + true +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigApprove +MsigApprove approves a previously-proposed multisig message by transaction ID +It takes the following params: , + + +Perms: sign + +Inputs: +```json +[ + "f01234", + 42, + "f01234" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigApproveTxnHash +MsigApproveTxnHash approves a previously-proposed multisig message, specified +using both transaction ID and a hash of the parameters used in the +proposal. This method of approval can be used to ensure you only approve +exactly the transaction you think you are. +It takes the following params: , , , , , +, , + + +Perms: sign + +Inputs: +```json +[ + "f01234", + 42, + "f01234", + "f01234", + "0", + "f01234", + 42, + "Ynl0ZSBhcnJheQ==" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigCancel +MsigCancel cancels a previously-proposed multisig message +It takes the following params: , + + +Perms: sign + +Inputs: +```json +[ + "f01234", + 42, + "f01234" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigCancelTxnHash +MsigCancel cancels a previously-proposed multisig message +It takes the following params: , , , , +, , + + +Perms: sign + +Inputs: +```json +[ + "f01234", + 42, + "f01234", + "0", + "f01234", + 42, + "Ynl0ZSBhcnJheQ==" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigCreate +MsigCreate creates a multisig wallet +It takes the following params: , , +, , + + +Perms: sign + +Inputs: +```json +[ + 42, + [ + "f01234" + ], + 10101, + "0", + "f01234", + "0" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigGetAvailableBalance +MsigGetAvailableBalance returns the portion of a multisig's balance that can be withdrawn or spent + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### MsigGetPending +MsigGetPending returns pending transactions for the given multisig +wallet. Once pending transactions are fully approved, they will no longer +appear here. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "ID": 9, + "To": "f01234", + "Value": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "Approved": [ + "f01234" + ] + } +] +``` + +### MsigGetVested +MsigGetVested returns the amount of FIL that vested in a multisig in a certain period. +It takes the following params: , , + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### MsigGetVestingSchedule +MsigGetVestingSchedule returns the vesting details of a given multisig. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "InitialBalance": "0", + "StartEpoch": 10101, + "UnlockDuration": 10101 +} +``` + +### MsigPropose +MsigPropose proposes a multisig message +It takes the following params: , , , +, , + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "0", + "f01234", + 42, + "Ynl0ZSBhcnJheQ==" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigRemoveSigner +MsigRemoveSigner proposes the removal of a signer from the multisig. +It accepts the multisig to make the change on, the proposer address to +send the message from, the address to be removed, and a boolean +indicating whether or not the signing threshold should be lowered by one +along with the address removal. + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "f01234", + true +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigSwapApprove +MsigSwapApprove approves a previously proposed SwapSigner +It takes the following params: , , , +, , + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + 42, + "f01234", + "f01234", + "f01234" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigSwapCancel +MsigSwapCancel cancels a previously proposed SwapSigner message +It takes the following params: , , , +, + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + 42, + "f01234", + "f01234" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +### MsigSwapPropose +MsigSwapPropose proposes swapping 2 signers in the multisig +It takes the following params: , , +, + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "f01234", + "f01234" +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "ValidNonce": true +} +``` + +## Net + + +### NetAddrsListen + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", + "Addrs": [ + "/ip4/52.36.61.156/tcp/1347/p2p/12D3KooWFETiESTf1v4PGUvtnxMAcEFMzLZbJGg4tjWfGEimYior" + ] +} +``` + +### NetAgentVersion + + +Perms: read + +Inputs: +```json +[ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" +] +``` + +Response: `"string value"` + +### NetAutoNatStatus + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "Reachability": 1, + "PublicAddrs": [ + "string value" + ] +} +``` + +### NetBandwidthStats + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "TotalIn": 9, + "TotalOut": 9, + "RateIn": 12.3, + "RateOut": 12.3 +} +``` + +### NetBandwidthStatsByPeer + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "12D3KooWSXmXLJmBR1M7i9RW9GQPNUhZSzXKzxDHWtAgNuJAbyEJ": { + "TotalIn": 174000, + "TotalOut": 12500, + "RateIn": 100, + "RateOut": 50 + } +} +``` + +### NetBandwidthStatsByProtocol + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "/fil/hello/1.0.0": { + "TotalIn": 174000, + "TotalOut": 12500, + "RateIn": 100, + "RateOut": 50 + } +} +``` + +### NetBlockAdd + + +Perms: admin + +Inputs: +```json +[ + { + "Peers": [ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" + ], + "IPAddrs": [ + "string value" + ], + "IPSubnets": [ + "string value" + ] + } +] +``` + +Response: `{}` + +### NetBlockList + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "Peers": [ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" + ], + "IPAddrs": [ + "string value" + ], + "IPSubnets": [ + "string value" + ] +} +``` + +### NetBlockRemove + + +Perms: admin + +Inputs: +```json +[ + { + "Peers": [ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" + ], + "IPAddrs": [ + "string value" + ], + "IPSubnets": [ + "string value" + ] + } +] +``` + +Response: `{}` + +### NetConnect + + +Perms: write + +Inputs: +```json +[ + { + "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", + "Addrs": [ + "/ip4/52.36.61.156/tcp/1347/p2p/12D3KooWFETiESTf1v4PGUvtnxMAcEFMzLZbJGg4tjWfGEimYior" + ] + } +] +``` + +Response: `{}` + +### NetConnectedness + + +Perms: read + +Inputs: +```json +[ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" +] +``` + +Response: `1` + +### NetDisconnect + + +Perms: write + +Inputs: +```json +[ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" +] +``` + +Response: `{}` + +### NetFindPeer + + +Perms: read + +Inputs: +```json +[ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" +] +``` + +Response: +```json +{ + "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", + "Addrs": [ + "/ip4/52.36.61.156/tcp/1347/p2p/12D3KooWFETiESTf1v4PGUvtnxMAcEFMzLZbJGg4tjWfGEimYior" + ] +} +``` + +### NetLimit + + +Perms: read + +Inputs: +```json +[ + "string value" +] +``` + +Response: +```json +{ + "Memory": 123, + "Streams": 3, + "StreamsInbound": 1, + "StreamsOutbound": 2, + "Conns": 4, + "ConnsInbound": 3, + "ConnsOutbound": 4, + "FD": 5 +} +``` + +### NetListening + + +Perms: read + +Inputs: `null` + +Response: `true` + +### NetPeerInfo + + +Perms: read + +Inputs: +```json +[ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" +] +``` + +Response: +```json +{ + "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", + "Agent": "string value", + "Addrs": [ + "string value" + ], + "Protocols": [ + "string value" + ], + "ConnMgrMeta": { + "FirstSeen": "0001-01-01T00:00:00Z", + "Value": 123, + "Tags": { + "name": 42 + }, + "Conns": { + "name": "2021-03-08T22:52:18Z" + } + } +} +``` + +### NetPeers + + +Perms: read + +Inputs: `null` + +Response: +```json +[ + { + "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", + "Addrs": [ + "/ip4/52.36.61.156/tcp/1347/p2p/12D3KooWFETiESTf1v4PGUvtnxMAcEFMzLZbJGg4tjWfGEimYior" + ] + } +] +``` + +### NetPing + + +Perms: read + +Inputs: +```json +[ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" +] +``` + +Response: `60000000000` + +### NetProtectAdd + + +Perms: admin + +Inputs: +```json +[ + [ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" + ] +] +``` + +Response: `{}` + +### NetProtectList + + +Perms: read + +Inputs: `null` + +Response: +```json +[ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" +] +``` + +### NetProtectRemove + + +Perms: admin + +Inputs: +```json +[ + [ + "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf" + ] +] +``` + +Response: `{}` + +### NetPubsubScores + + +Perms: read + +Inputs: `null` + +Response: +```json +[ + { + "ID": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", + "Score": { + "Score": 12.3, + "Topics": { + "/blocks": { + "TimeInMesh": 60000000000, + "FirstMessageDeliveries": 122, + "MeshMessageDeliveries": 1234, + "InvalidMessageDeliveries": 3 + } + }, + "AppSpecificScore": 12.3, + "IPColocationFactor": 12.3, + "BehaviourPenalty": 12.3 + } + } +] +``` + +### NetSetLimit + + +Perms: admin + +Inputs: +```json +[ + "string value", + { + "Memory": 123, + "Streams": 3, + "StreamsInbound": 1, + "StreamsOutbound": 2, + "Conns": 4, + "ConnsInbound": 3, + "ConnsOutbound": 4, + "FD": 5 + } +] +``` + +Response: `{}` + +### NetStat + + +Perms: read + +Inputs: +```json +[ + "string value" +] +``` + +Response: +```json +{ + "System": { + "NumStreamsInbound": 123, + "NumStreamsOutbound": 123, + "NumConnsInbound": 123, + "NumConnsOutbound": 123, + "NumFD": 123, + "Memory": 9 + }, + "Transient": { + "NumStreamsInbound": 123, + "NumStreamsOutbound": 123, + "NumConnsInbound": 123, + "NumConnsOutbound": 123, + "NumFD": 123, + "Memory": 9 + }, + "Services": { + "abc": { + "NumStreamsInbound": 1, + "NumStreamsOutbound": 2, + "NumConnsInbound": 3, + "NumConnsOutbound": 4, + "NumFD": 5, + "Memory": 123 + } + }, + "Protocols": { + "abc": { + "NumStreamsInbound": 1, + "NumStreamsOutbound": 2, + "NumConnsInbound": 3, + "NumConnsOutbound": 4, + "NumFD": 5, + "Memory": 123 + } + }, + "Peers": { + "abc": { + "NumStreamsInbound": 1, + "NumStreamsOutbound": 2, + "NumConnsInbound": 3, + "NumConnsOutbound": 4, + "NumFD": 5, + "Memory": 123 + } + } +} +``` + +### NetVersion + + +Perms: read + +Inputs: `null` + +Response: `"string value"` + +## Node +These methods are general node management and status commands + + +### NodeStatus +There are not yet any comments for this method. + +Perms: read + +Inputs: +```json +[ + true +] +``` + +Response: +```json +{ + "SyncStatus": { + "Epoch": 42, + "Behind": 42 + }, + "PeerStatus": { + "PeersToPublishMsgs": 123, + "PeersToPublishBlocks": 123 + }, + "ChainStatus": { + "BlocksPerTipsetLast100": 12.3, + "BlocksPerTipsetLastFinality": 12.3 + } +} +``` + +## Paych +The Paych methods are for interacting with and managing payment channels + + +### PaychAllocateLane + + +Perms: sign + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `42` + +### PaychAvailableFunds + + +Perms: sign + +Inputs: +```json +[ + "f01234" +] +``` + +Response: +```json +{ + "Channel": "f01234", + "From": "f01234", + "To": "f01234", + "ConfirmedAmt": "0", + "PendingAmt": "0", + "NonReservedAmt": "0", + "PendingAvailableAmt": "0", + "PendingWaitSentinel": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "QueuedAmt": "0", + "VoucherReedeemedAmt": "0" +} +``` + +### PaychAvailableFundsByFromTo + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234" +] +``` + +Response: +```json +{ + "Channel": "f01234", + "From": "f01234", + "To": "f01234", + "ConfirmedAmt": "0", + "PendingAmt": "0", + "NonReservedAmt": "0", + "PendingAvailableAmt": "0", + "PendingWaitSentinel": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "QueuedAmt": "0", + "VoucherReedeemedAmt": "0" +} +``` + +### PaychCollect + + +Perms: sign + +Inputs: +```json +[ + "f01234" +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### PaychFund +PaychFund gets or creates a payment channel between address pair. +The specified amount will be added to the channel through on-chain send for future use + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "0" +] +``` + +Response: +```json +{ + "Channel": "f01234", + "WaitSentinel": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +} +``` + +### PaychGet +PaychGet gets or creates a payment channel between address pair + The specified amount will be reserved for use. If there aren't enough non-reserved funds + available, funds will be added through an on-chain message. + - When opts.OffChain is true, this call will not cause any messages to be sent to the chain (no automatic + channel creation/funds adding). If the operation can't be performed without sending a message an error will be + returned. Note that even when this option is specified, this call can be blocked by previous operations on the + channel waiting for on-chain operations. + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + "0", + { + "OffChain": true + } +] +``` + +Response: +```json +{ + "Channel": "f01234", + "WaitSentinel": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +} +``` + +### PaychGetWaitReady + + +Perms: sign + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: `"f01234"` + +### PaychList + + +Perms: read + +Inputs: `null` + +Response: +```json +[ + "f01234" +] +``` + +### PaychNewPayment + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "f01234", + [ + { + "Amount": "0", + "TimeLockMin": 10101, + "TimeLockMax": 10101, + "MinSettle": 10101, + "Extra": { + "Actor": "f01234", + "Method": 1, + "Data": "Ynl0ZSBhcnJheQ==" + } + } + ] +] +``` + +Response: +```json +{ + "Channel": "f01234", + "WaitSentinel": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Vouchers": [ + { + "ChannelAddr": "f01234", + "TimeLockMin": 10101, + "TimeLockMax": 10101, + "SecretHash": "Ynl0ZSBhcnJheQ==", + "Extra": { + "Actor": "f01234", + "Method": 1, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Lane": 42, + "Nonce": 42, + "Amount": "0", + "MinSettleHeight": 10101, + "Merges": [ + { + "Lane": 42, + "Nonce": 42 + } + ], + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + } + } + ] +} +``` + +### PaychSettle + + +Perms: sign + +Inputs: +```json +[ + "f01234" +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### PaychStatus + + +Perms: read + +Inputs: +```json +[ + "f01234" +] +``` + +Response: +```json +{ + "ControlAddr": "f01234", + "Direction": 1 +} +``` + +### PaychVoucherAdd + + +Perms: write + +Inputs: +```json +[ + "f01234", + { + "ChannelAddr": "f01234", + "TimeLockMin": 10101, + "TimeLockMax": 10101, + "SecretHash": "Ynl0ZSBhcnJheQ==", + "Extra": { + "Actor": "f01234", + "Method": 1, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Lane": 42, + "Nonce": 42, + "Amount": "0", + "MinSettleHeight": 10101, + "Merges": [ + { + "Lane": 42, + "Nonce": 42 + } + ], + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + } + }, + "Ynl0ZSBhcnJheQ==", + "0" +] +``` + +Response: `"0"` + +### PaychVoucherCheckSpendable + + +Perms: read + +Inputs: +```json +[ + "f01234", + { + "ChannelAddr": "f01234", + "TimeLockMin": 10101, + "TimeLockMax": 10101, + "SecretHash": "Ynl0ZSBhcnJheQ==", + "Extra": { + "Actor": "f01234", + "Method": 1, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Lane": 42, + "Nonce": 42, + "Amount": "0", + "MinSettleHeight": 10101, + "Merges": [ + { + "Lane": 42, + "Nonce": 42 + } + ], + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + } + }, + "Ynl0ZSBhcnJheQ==", + "Ynl0ZSBhcnJheQ==" +] +``` + +Response: `true` + +### PaychVoucherCheckValid + + +Perms: read + +Inputs: +```json +[ + "f01234", + { + "ChannelAddr": "f01234", + "TimeLockMin": 10101, + "TimeLockMax": 10101, + "SecretHash": "Ynl0ZSBhcnJheQ==", + "Extra": { + "Actor": "f01234", + "Method": 1, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Lane": 42, + "Nonce": 42, + "Amount": "0", + "MinSettleHeight": 10101, + "Merges": [ + { + "Lane": 42, + "Nonce": 42 + } + ], + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + } + } +] +``` + +Response: `{}` + +### PaychVoucherCreate + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "0", + 42 +] +``` + +Response: +```json +{ + "Voucher": { + "ChannelAddr": "f01234", + "TimeLockMin": 10101, + "TimeLockMax": 10101, + "SecretHash": "Ynl0ZSBhcnJheQ==", + "Extra": { + "Actor": "f01234", + "Method": 1, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Lane": 42, + "Nonce": 42, + "Amount": "0", + "MinSettleHeight": 10101, + "Merges": [ + { + "Lane": 42, + "Nonce": 42 + } + ], + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + } + }, + "Shortfall": "0" +} +``` + +### PaychVoucherList + + +Perms: write + +Inputs: +```json +[ + "f01234" +] +``` + +Response: +```json +[ + { + "ChannelAddr": "f01234", + "TimeLockMin": 10101, + "TimeLockMax": 10101, + "SecretHash": "Ynl0ZSBhcnJheQ==", + "Extra": { + "Actor": "f01234", + "Method": 1, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Lane": 42, + "Nonce": 42, + "Amount": "0", + "MinSettleHeight": 10101, + "Merges": [ + { + "Lane": 42, + "Nonce": 42 + } + ], + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + } + } +] +``` + +### PaychVoucherSubmit + + +Perms: sign + +Inputs: +```json +[ + "f01234", + { + "ChannelAddr": "f01234", + "TimeLockMin": 10101, + "TimeLockMax": 10101, + "SecretHash": "Ynl0ZSBhcnJheQ==", + "Extra": { + "Actor": "f01234", + "Method": 1, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Lane": 42, + "Nonce": 42, + "Amount": "0", + "MinSettleHeight": 10101, + "Merges": [ + { + "Lane": 42, + "Nonce": 42 + } + ], + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + } + }, + "Ynl0ZSBhcnJheQ==", + "Ynl0ZSBhcnJheQ==" +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +## Start + + +### StartTime + + +Perms: read + +Inputs: `null` + +Response: `"0001-01-01T00:00:00Z"` + +## State +The State methods are used to query, inspect, and interact with chain state. +Most methods take a TipSetKey as a parameter. The state looked up is the parent state of the tipset. +A nil TipSetKey can be provided as a param, this will cause the heaviest tipset in the chain to be used. + + +### StateAccountKey +StateAccountKey returns the public key address of the given ID address for secp and bls accounts + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"f01234"` + +### StateActorCodeCIDs +StateActorCodeCIDs returns the CIDs of all the builtin actors for the given network version + + +Perms: read + +Inputs: +```json +[ + 23 +] +``` + +Response: `{}` + +### StateActorManifestCID +StateActorManifestCID returns the CID of the builtin actors manifest for the given network version + + +Perms: read + +Inputs: +```json +[ + 23 +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### StateAllMinerFaults +StateAllMinerFaults returns all non-expired Faults that occur within lookback epochs of the given tipset + + +Perms: read + +Inputs: +```json +[ + 10101, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "Miner": "f01234", + "Epoch": 10101 + } +] +``` + +### StateCall +StateCall runs the given message and returns its result without any persisted changes. + +StateCall applies the message to the tipset's parent state. The +message is not applied on-top-of the messages in the passed-in +tipset. + + +Perms: read + +Inputs: +```json +[ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "MsgCid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Msg": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "GasUsed": 9, + "EventsRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + }, + "GasCost": { + "Message": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "GasUsed": "0", + "BaseFeeBurn": "0", + "OverEstimationBurn": "0", + "MinerPenalty": "0", + "MinerTip": "0", + "Refund": "0", + "TotalCost": "0" + }, + "ExecutionTrace": { + "Msg": { + "From": "f01234", + "To": "f01234", + "Value": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "ParamsCodec": 42, + "GasLimit": 42, + "ReadOnly": true + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "ReturnCodec": 42 + }, + "InvokedActor": { + "Id": 1000, + "State": { + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Head": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Nonce": 42, + "Balance": "0", + "DelegatedAddress": "f01234" + } + }, + "GasCharges": [ + { + "Name": "string value", + "tg": 9, + "cg": 9, + "sg": 9, + "tt": 60000000000 + } + ], + "Subcalls": [ + { + "Msg": { + "From": "f01234", + "To": "f01234", + "Value": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "ParamsCodec": 42, + "GasLimit": 42, + "ReadOnly": true + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "ReturnCodec": 42 + }, + "InvokedActor": { + "Id": 1000, + "State": { + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Head": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Nonce": 42, + "Balance": "0", + "DelegatedAddress": "f01234" + } + }, + "GasCharges": [ + { + "Name": "string value", + "tg": 9, + "cg": 9, + "sg": 9, + "tt": 60000000000 + } + ], + "Subcalls": null + } + ] + }, + "Error": "string value", + "Duration": 60000000000 +} +``` + +### StateChangedActors +StateChangedActors returns all the actors whose states change between the two given state CIDs +TODO: Should this take tipset keys instead? + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +{ + "t01236": { + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Head": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Nonce": 42, + "Balance": "0", + "DelegatedAddress": "f01234" + } +} +``` + +### StateCirculatingSupply +StateCirculatingSupply returns the exact circulating supply of Filecoin at the given tipset. +This is not used anywhere in the protocol itself, and is only for external consumption. + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### StateCompute +StateCompute is a flexible command that applies the given messages on the given tipset. +The messages are run as though the VM were at the provided height. + +When called, StateCompute will: +- Load the provided tipset, or use the current chain head if not provided +- Compute the tipset state of the provided tipset on top of the parent state + - (note that this step runs before vmheight is applied to the execution) + - Execute state upgrade if any were scheduled at the epoch, or in null + blocks preceding the tipset + - Call the cron actor on null blocks preceding the tipset + - For each block in the tipset + - Apply messages in blocks in the specified + - Award block reward by calling the reward actor + - Call the cron actor for the current epoch +- If the specified vmheight is higher than the current epoch, apply any + needed state upgrades to the state +- Apply the specified messages to the state + +The vmheight parameter sets VM execution epoch, and can be used to simulate +message execution in different network versions. If the specified vmheight +epoch is higher than the epoch of the specified tipset, any state upgrades +until the vmheight will be executed on the state before applying messages +specified by the user. + +Note that the initial tipset state computation is not affected by the +vmheight parameter - only the messages in the `apply` set are + +If the caller wants to simply compute the state, vmheight should be set to +the epoch of the specified tipset. + +Messages in the `apply` parameter must have the correct nonces, and gas +values set. + + +Perms: read + +Inputs: +```json +[ + 10101, + [ + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } + ], + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Root": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Trace": [ + { + "MsgCid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Msg": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "GasUsed": 9, + "EventsRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + }, + "GasCost": { + "Message": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "GasUsed": "0", + "BaseFeeBurn": "0", + "OverEstimationBurn": "0", + "MinerPenalty": "0", + "MinerTip": "0", + "Refund": "0", + "TotalCost": "0" + }, + "ExecutionTrace": { + "Msg": { + "From": "f01234", + "To": "f01234", + "Value": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "ParamsCodec": 42, + "GasLimit": 42, + "ReadOnly": true + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "ReturnCodec": 42 + }, + "InvokedActor": { + "Id": 1000, + "State": { + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Head": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Nonce": 42, + "Balance": "0", + "DelegatedAddress": "f01234" + } + }, + "GasCharges": [ + { + "Name": "string value", + "tg": 9, + "cg": 9, + "sg": 9, + "tt": 60000000000 + } + ], + "Subcalls": [ + { + "Msg": { + "From": "f01234", + "To": "f01234", + "Value": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "ParamsCodec": 42, + "GasLimit": 42, + "ReadOnly": true + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "ReturnCodec": 42 + }, + "InvokedActor": { + "Id": 1000, + "State": { + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Head": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Nonce": 42, + "Balance": "0", + "DelegatedAddress": "f01234" + } + }, + "GasCharges": [ + { + "Name": "string value", + "tg": 9, + "cg": 9, + "sg": 9, + "tt": 60000000000 + } + ], + "Subcalls": null + } + ] + }, + "Error": "string value", + "Duration": 60000000000 + } + ] +} +``` + +### StateComputeDataCID +StateComputeDataCID computes DataCID from a set of on-chain deals + + +Perms: read + +Inputs: +```json +[ + "f01234", + 8, + [ + 5432 + ], + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" +} +``` + +### StateDealProviderCollateralBounds +StateDealProviderCollateralBounds returns the min and max collateral a storage provider +can issue. It takes the deal size and verified status as parameters. + + +Perms: read + +Inputs: +```json +[ + 1032, + true, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Min": "0", + "Max": "0" +} +``` + +### StateDecodeParams +StateDecodeParams attempts to decode the provided params, based on the recipient actor address and method number. + + +Perms: read + +Inputs: +```json +[ + "f01234", + 1, + "Ynl0ZSBhcnJheQ==", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `{}` + +### StateEncodeParams +StateEncodeParams attempts to encode the provided json params to the binary from + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + 1, + "json raw message" +] +``` + +Response: `"Ynl0ZSBhcnJheQ=="` + +### StateGetActor +StateGetActor returns the indicated actor's nonce and balance. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Head": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Nonce": 42, + "Balance": "0", + "DelegatedAddress": "f01234" +} +``` + +### StateGetAllAllocations +StateGetAllAllocations returns the all the allocations available in verified registry actor. + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `{}` + +### StateGetAllClaims +StateGetAllClaims returns the all the claims available in verified registry actor. + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `{}` + +### StateGetAllocation +StateGetAllocation returns the allocation for a given address and allocation ID. + + +Perms: read + +Inputs: +```json +[ + "f01234", + 0, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Client": 1000, + "Provider": 1000, + "Data": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Size": 1032, + "TermMin": 10101, + "TermMax": 10101, + "Expiration": 10101 +} +``` + +### StateGetAllocationForPendingDeal +StateGetAllocationForPendingDeal returns the allocation for a given deal ID of a pending deal. Returns nil if +pending allocation is not found. + + +Perms: read + +Inputs: +```json +[ + 5432, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Client": 1000, + "Provider": 1000, + "Data": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Size": 1032, + "TermMin": 10101, + "TermMax": 10101, + "Expiration": 10101 +} +``` + +### StateGetAllocationIdForPendingDeal +StateGetAllocationIdForPendingDeal is like StateGetAllocationForPendingDeal except it returns the allocation ID + + +Perms: read + +Inputs: +```json +[ + 5432, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `0` + +### StateGetAllocations +StateGetAllocations returns the all the allocations for a given client. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `{}` + +### StateGetBeaconEntry +StateGetBeaconEntry returns the beacon entry for the given filecoin epoch. If +the entry has not yet been produced, the call will block until the entry +becomes available + + +Perms: read + +Inputs: +```json +[ + 10101 +] +``` + +Response: +```json +{ + "Round": 42, + "Data": "Ynl0ZSBhcnJheQ==" +} +``` + +### StateGetClaim +StateGetClaim returns the claim for a given address and claim ID. + + +Perms: read + +Inputs: +```json +[ + "f01234", + 0, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Provider": 1000, + "Client": 1000, + "Data": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Size": 1032, + "TermMin": 10101, + "TermMax": 10101, + "TermStart": 10101, + "Sector": 9 +} +``` + +### StateGetClaims +StateGetClaims returns the all the claims for a given provider. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `{}` + +### StateGetNetworkParams +StateGetNetworkParams return current network params + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "NetworkName": "lotus", + "BlockDelaySecs": 42, + "ConsensusMinerMinPower": "0", + "SupportedProofTypes": [ + 8 + ], + "PreCommitChallengeDelay": 10101, + "ForkUpgradeParams": { + "UpgradeSmokeHeight": 10101, + "UpgradeBreezeHeight": 10101, + "UpgradeIgnitionHeight": 10101, + "UpgradeLiftoffHeight": 10101, + "UpgradeAssemblyHeight": 10101, + "UpgradeRefuelHeight": 10101, + "UpgradeTapeHeight": 10101, + "UpgradeKumquatHeight": 10101, + "BreezeGasTampingDuration": 10101, + "UpgradeCalicoHeight": 10101, + "UpgradePersianHeight": 10101, + "UpgradeOrangeHeight": 10101, + "UpgradeClausHeight": 10101, + "UpgradeTrustHeight": 10101, + "UpgradeNorwegianHeight": 10101, + "UpgradeTurboHeight": 10101, + "UpgradeHyperdriveHeight": 10101, + "UpgradeChocolateHeight": 10101, + "UpgradeOhSnapHeight": 10101, + "UpgradeSkyrHeight": 10101, + "UpgradeSharkHeight": 10101, + "UpgradeHyggeHeight": 10101, + "UpgradeLightningHeight": 10101, + "UpgradeThunderHeight": 10101, + "UpgradeWatermelonHeight": 10101, + "UpgradeDragonHeight": 10101, + "UpgradePhoenixHeight": 10101, + "UpgradeWaffleHeight": 10101 + }, + "Eip155ChainID": 123 +} +``` + +### StateGetRandomnessDigestFromBeacon +StateGetRandomnessDigestFromBeacon is used to sample the beacon for randomness. + + +Perms: read + +Inputs: +```json +[ + 10101, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"Bw=="` + +### StateGetRandomnessDigestFromTickets +StateGetRandomnessDigestFromTickets. is used to sample the chain for randomness. + + +Perms: read + +Inputs: +```json +[ + 10101, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"Bw=="` + +### StateGetRandomnessFromBeacon +StateGetRandomnessFromBeacon is used to sample the beacon for randomness. + + +Perms: read + +Inputs: +```json +[ + 2, + 10101, + "Ynl0ZSBhcnJheQ==", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"Bw=="` + +### StateGetRandomnessFromTickets +StateGetRandomnessFromTickets is used to sample the chain for randomness. + + +Perms: read + +Inputs: +```json +[ + 2, + 10101, + "Ynl0ZSBhcnJheQ==", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"Bw=="` + +### StateListActors +StateListActors returns the addresses of every actor in the state + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + "f01234" +] +``` + +### StateListMessages +StateListMessages looks back and returns all messages with a matching to or from address, stopping at the given height. + + +Perms: read + +Inputs: +```json +[ + { + "To": "f01234", + "From": "f01234" + }, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + 10101 +] +``` + +Response: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +### StateListMiners +StateListMiners returns the addresses of every miner that has claimed power in the Power Actor + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + "f01234" +] +``` + +### StateLookupID +StateLookupID retrieves the ID address of the given address + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"f01234"` + +### StateLookupRobustAddress +StateLookupRobustAddress returns the public key address of the given ID address for non-account addresses (multisig, miners etc) + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"f01234"` + +### StateMarketBalance +StateMarketBalance looks up the Escrow and Locked balances of the given address in the Storage Market + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Escrow": "0", + "Locked": "0" +} +``` + +### StateMarketDeals +StateMarketDeals returns information about every deal in the Storage Market + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "t026363": { + "Proposal": { + "PieceCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "PieceSize": 1032, + "VerifiedDeal": true, + "Client": "f01234", + "Provider": "f01234", + "Label": "", + "StartEpoch": 10101, + "EndEpoch": 10101, + "StoragePricePerEpoch": "0", + "ProviderCollateral": "0", + "ClientCollateral": "0" + }, + "State": { + "SectorNumber": 9, + "SectorStartEpoch": 10101, + "LastUpdatedEpoch": 10101, + "SlashEpoch": 10101 + } + } +} +``` + +### StateMarketParticipants +StateMarketParticipants returns the Escrow and Locked balances of every participant in the Storage Market + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "t026363": { + "Escrow": "0", + "Locked": "0" + } +} +``` + +### StateMarketStorageDeal +StateMarketStorageDeal returns information about the indicated deal + + +Perms: read + +Inputs: +```json +[ + 5432, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Proposal": { + "PieceCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "PieceSize": 1032, + "VerifiedDeal": true, + "Client": "f01234", + "Provider": "f01234", + "Label": "", + "StartEpoch": 10101, + "EndEpoch": 10101, + "StoragePricePerEpoch": "0", + "ProviderCollateral": "0", + "ClientCollateral": "0" + }, + "State": { + "SectorNumber": 9, + "SectorStartEpoch": 10101, + "LastUpdatedEpoch": 10101, + "SlashEpoch": 10101 + } +} +``` + +### StateMinerActiveSectors +StateMinerActiveSectors returns info about sectors that a given miner is actively proving. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "SectorNumber": 9, + "SealProof": 8, + "SealedCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "DealIDs": [ + 5432 + ], + "Activation": 10101, + "Expiration": 10101, + "DealWeight": "0", + "VerifiedDealWeight": "0", + "InitialPledge": "0", + "ExpectedDayReward": "0", + "ExpectedStoragePledge": "0", + "PowerBaseEpoch": 10101, + "ReplacedDayReward": "0", + "SectorKeyCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Flags": 0 + } +] +``` + +### StateMinerAllocated +StateMinerAllocated returns a bitfield containing all sector numbers marked as allocated in miner state + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + 0 +] +``` + +### StateMinerAvailableBalance +StateMinerAvailableBalance returns the portion of a miner's balance that can be withdrawn or spent + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### StateMinerDeadlines +StateMinerDeadlines returns all the proving deadlines for the given miner + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "PostSubmissions": [ + 5, + 1 + ], + "DisputableProofCount": 42 + } +] +``` + +### StateMinerFaults +StateMinerFaults returns a bitfield indicating the faulty sectors of the given miner + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + 5, + 1 +] +``` + +### StateMinerInfo +StateMinerInfo returns info about the indicated miner + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Owner": "f01234", + "Worker": "f01234", + "NewWorker": "f01234", + "ControlAddresses": [ + "f01234" + ], + "WorkerChangeEpoch": 10101, + "PeerId": "12D3KooWGzxzKZYveHXtpG6AsrUJBcWxHBFS2HsEoGTxrMLvKXtf", + "Multiaddrs": [ + "Ynl0ZSBhcnJheQ==" + ], + "WindowPoStProofType": 8, + "SectorSize": 34359738368, + "WindowPoStPartitionSectors": 42, + "ConsensusFaultElapsed": 10101, + "PendingOwnerAddress": "f01234", + "Beneficiary": "f01234", + "BeneficiaryTerm": { + "Quota": "0", + "UsedQuota": "0", + "Expiration": 10101 + }, + "PendingBeneficiaryTerm": { + "NewBeneficiary": "f01234", + "NewQuota": "0", + "NewExpiration": 10101, + "ApprovedByBeneficiary": true, + "ApprovedByNominee": true + } +} +``` + +### StateMinerInitialPledgeCollateral +StateMinerInitialPledgeCollateral returns the initial pledge collateral for the specified miner's sector + + +Perms: read + +Inputs: +```json +[ + "f01234", + { + "SealProof": 8, + "SectorNumber": 9, + "SealedCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "SealRandEpoch": 10101, + "DealIDs": [ + 5432 + ], + "Expiration": 10101, + "UnsealedCid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + }, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### StateMinerPartitions +StateMinerPartitions returns all partitions in the specified deadline + + +Perms: read + +Inputs: +```json +[ + "f01234", + 42, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "AllSectors": [ + 5, + 1 + ], + "FaultySectors": [ + 5, + 1 + ], + "RecoveringSectors": [ + 5, + 1 + ], + "LiveSectors": [ + 5, + 1 + ], + "ActiveSectors": [ + 5, + 1 + ] + } +] +``` + +### StateMinerPower +StateMinerPower returns the power of the indicated miner + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "MinerPower": { + "RawBytePower": "0", + "QualityAdjPower": "0" + }, + "TotalPower": { + "RawBytePower": "0", + "QualityAdjPower": "0" + }, + "HasMinPower": true +} +``` + +### StateMinerPreCommitDepositForPower +StateMinerInitialPledgeCollateral returns the precommit deposit for the specified miner's sector + + +Perms: read + +Inputs: +```json +[ + "f01234", + { + "SealProof": 8, + "SectorNumber": 9, + "SealedCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "SealRandEpoch": 10101, + "DealIDs": [ + 5432 + ], + "Expiration": 10101, + "UnsealedCid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + }, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### StateMinerProvingDeadline +StateMinerProvingDeadline calculates the deadline at some epoch for a proving period +and returns the deadline-related calculations. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "CurrentEpoch": 10101, + "PeriodStart": 10101, + "Index": 42, + "Open": 10101, + "Close": 10101, + "Challenge": 10101, + "FaultCutoff": 10101, + "WPoStPeriodDeadlines": 42, + "WPoStProvingPeriod": 10101, + "WPoStChallengeWindow": 10101, + "WPoStChallengeLookback": 10101, + "FaultDeclarationCutoff": 10101 +} +``` + +### StateMinerRecoveries +StateMinerRecoveries returns a bitfield indicating the recovering sectors of the given miner + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + 5, + 1 +] +``` + +### StateMinerSectorAllocated +StateMinerSectorAllocated checks if a sector number is marked as allocated. + + +Perms: read + +Inputs: +```json +[ + "f01234", + 9, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `true` + +### StateMinerSectorCount +StateMinerSectorCount returns the number of sectors in a miner's sector set and proving set + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Live": 42, + "Active": 42, + "Faulty": 42 +} +``` + +### StateMinerSectors +StateMinerSectors returns info about the given miner's sectors. If the filter bitfield is nil, all sectors are included. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + 0 + ], + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +[ + { + "SectorNumber": 9, + "SealProof": 8, + "SealedCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "DealIDs": [ + 5432 + ], + "Activation": 10101, + "Expiration": 10101, + "DealWeight": "0", + "VerifiedDealWeight": "0", + "InitialPledge": "0", + "ExpectedDayReward": "0", + "ExpectedStoragePledge": "0", + "PowerBaseEpoch": 10101, + "ReplacedDayReward": "0", + "SectorKeyCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Flags": 0 + } +] +``` + +### StateNetworkName +StateNetworkName returns the name of the network the node is synced to + + +Perms: read + +Inputs: `null` + +Response: `"lotus"` + +### StateNetworkVersion +StateNetworkVersion returns the network version at the given tipset + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `23` + +### StateReadState +StateReadState returns the indicated actor's state. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Balance": "0", + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "State": {} +} +``` + +### StateReplay +StateReplay replays a given message, assuming it was included in a block in the specified tipset. + +If a tipset key is provided, and a replacing message is not found on chain, +the method will return an error saying that the message wasn't found + +If no tipset key is provided, the appropriate tipset is looked up, and if +the message was gas-repriced, the on-chain message will be replayed - in +that case the returned InvocResult.MsgCid will not match the Cid param + +If the caller wants to ensure that exactly the requested message was executed, +they MUST check that InvocResult.MsgCid is equal to the provided Cid. +Without this check both the requested and original message may appear as +successfully executed on-chain, which may look like a double-spend. + +A replacing message is a message with a different CID, any of Gas values, and +different signature, but with all other parameters matching (source/destination, +nonce, params, etc.) + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: +```json +{ + "MsgCid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Msg": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "GasUsed": 9, + "EventsRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + }, + "GasCost": { + "Message": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "GasUsed": "0", + "BaseFeeBurn": "0", + "OverEstimationBurn": "0", + "MinerPenalty": "0", + "MinerTip": "0", + "Refund": "0", + "TotalCost": "0" + }, + "ExecutionTrace": { + "Msg": { + "From": "f01234", + "To": "f01234", + "Value": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "ParamsCodec": 42, + "GasLimit": 42, + "ReadOnly": true + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "ReturnCodec": 42 + }, + "InvokedActor": { + "Id": 1000, + "State": { + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Head": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Nonce": 42, + "Balance": "0", + "DelegatedAddress": "f01234" + } + }, + "GasCharges": [ + { + "Name": "string value", + "tg": 9, + "cg": 9, + "sg": 9, + "tt": 60000000000 + } + ], + "Subcalls": [ + { + "Msg": { + "From": "f01234", + "To": "f01234", + "Value": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "ParamsCodec": 42, + "GasLimit": 42, + "ReadOnly": true + }, + "MsgRct": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "ReturnCodec": 42 + }, + "InvokedActor": { + "Id": 1000, + "State": { + "Code": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Head": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Nonce": 42, + "Balance": "0", + "DelegatedAddress": "f01234" + } + }, + "GasCharges": [ + { + "Name": "string value", + "tg": 9, + "cg": 9, + "sg": 9, + "tt": 60000000000 + } + ], + "Subcalls": null + } + ] + }, + "Error": "string value", + "Duration": 60000000000 +} +``` + +### StateSearchMsg +StateSearchMsg looks back up to limit epochs in the chain for a message, and returns its receipt and the tipset where it was executed + +NOTE: If a replacing message is found on chain, this method will return +a MsgLookup for the replacing message - the MsgLookup.Message will be a different +CID than the one provided in the 'cid' param, MsgLookup.Receipt will contain the +result of the execution of the replacing message. + +If the caller wants to ensure that exactly the requested message was executed, +they must check that MsgLookup.Message is equal to the provided 'cid', or set the +`allowReplaced` parameter to false. Without this check, and with `allowReplaced` +set to true, both the requested and original message may appear as +successfully executed on-chain, which may look like a double-spend. + +A replacing message is a message with a different CID, any of Gas values, and +different signature, but with all other parameters matching (source/destination, +nonce, params, etc.) + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + 10101, + true +] +``` + +Response: +```json +{ + "Message": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Receipt": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "GasUsed": 9, + "EventsRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + }, + "ReturnDec": {}, + "TipSet": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + "Height": 10101 +} +``` + +### StateSectorExpiration +StateSectorExpiration returns epoch at which given sector will expire + + +Perms: read + +Inputs: +```json +[ + "f01234", + 9, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "OnTime": 10101, + "Early": 10101 +} +``` + +### StateSectorGetInfo +StateSectorGetInfo returns the on-chain info for the specified miner's sector. Returns null in case the sector info isn't found +NOTE: returned info.Expiration may not be accurate in some cases, use StateSectorExpiration to get accurate +expiration epoch + + +Perms: read + +Inputs: +```json +[ + "f01234", + 9, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "SectorNumber": 9, + "SealProof": 8, + "SealedCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "DealIDs": [ + 5432 + ], + "Activation": 10101, + "Expiration": 10101, + "DealWeight": "0", + "VerifiedDealWeight": "0", + "InitialPledge": "0", + "ExpectedDayReward": "0", + "ExpectedStoragePledge": "0", + "PowerBaseEpoch": 10101, + "ReplacedDayReward": "0", + "SectorKeyCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Flags": 0 +} +``` + +### StateSectorPartition +StateSectorPartition finds deadline/partition with the specified sector + + +Perms: read + +Inputs: +```json +[ + "f01234", + 9, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Deadline": 42, + "Partition": 42 +} +``` + +### StateSectorPreCommitInfo +StateSectorPreCommitInfo returns the PreCommit info for the specified miner's sector. +Returns nil and no error if the sector isn't precommitted. + +Note that the sector number may be allocated while PreCommitInfo is nil. This means that either allocated sector +numbers were compacted, and the sector number was marked as allocated in order to reduce size of the allocated +sectors bitfield, or that the sector was precommitted, but the precommit has expired. + + +Perms: read + +Inputs: +```json +[ + "f01234", + 9, + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "Info": { + "SealProof": 8, + "SectorNumber": 9, + "SealedCID": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "SealRandEpoch": 10101, + "DealIDs": [ + 5432 + ], + "Expiration": 10101, + "UnsealedCid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + }, + "PreCommitDeposit": "0", + "PreCommitEpoch": 10101 +} +``` + +### StateVMCirculatingSupplyInternal +StateVMCirculatingSupplyInternal returns an approximation of the circulating supply of Filecoin at the given tipset. +This is the value reported by the runtime interface to actors code. + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: +```json +{ + "FilVested": "0", + "FilMined": "0", + "FilBurnt": "0", + "FilLocked": "0", + "FilCirculating": "0", + "FilReserveDisbursed": "0" +} +``` + +### StateVerifiedClientStatus +StateVerifiedClientStatus returns the data cap for the given address. +Returns nil if there is no entry in the data cap table for the +address. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### StateVerifiedRegistryRootKey +StateVerifiedRegistryRootKey returns the address of the Verified Registry's root key + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"f01234"` + +### StateVerifierStatus +StateVerifierStatus returns the data cap for the given address. +Returns nil if there is no entry in the data cap table for the +address. + + +Perms: read + +Inputs: +```json +[ + "f01234", + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `"0"` + +### StateWaitMsg +StateWaitMsg looks back up to limit epochs in the chain for a message. +If not found, it blocks until the message arrives on chain, and gets to the +indicated confidence depth. + +NOTE: If a replacing message is found on chain, this method will return +a MsgLookup for the replacing message - the MsgLookup.Message will be a different +CID than the one provided in the 'cid' param, MsgLookup.Receipt will contain the +result of the execution of the replacing message. + +If the caller wants to ensure that exactly the requested message was executed, +they must check that MsgLookup.Message is equal to the provided 'cid', or set the +`allowReplaced` parameter to false. Without this check, and with `allowReplaced` +set to true, both the requested and original message may appear as +successfully executed on-chain, which may look like a double-spend. + +A replacing message is a message with a different CID, any of Gas values, and +different signature, but with all other parameters matching (source/destination, +nonce, params, etc.) + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + 42, + 10101, + true +] +``` + +Response: +```json +{ + "Message": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Receipt": { + "ExitCode": 0, + "Return": "Ynl0ZSBhcnJheQ==", + "GasUsed": 9, + "EventsRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + }, + "ReturnDec": {}, + "TipSet": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + "Height": 10101 +} +``` + +## Subscribe + + +### SubscribeActorEventsRaw +SubscribeActorEventsRaw returns a long-lived stream of all user-programmed and built-in actor +events that match the given filter. +Events that match the given filter are written to the stream in real-time as they are emitted +from the FVM. +The response stream is closed when the client disconnects, when a ToHeight is specified and is +reached, or if there is an error while writing an event to the stream. +This API also allows clients to read all historical events matching the given filter before any +real-time events are written to the response stream if the filter specifies an earlier +FromHeight. +Results available from this API may be limited by the MaxFilterResults and MaxFilterHeightRange +configuration options and also the amount of historical data available in the node. + +Note: this API is only available via websocket connections. +This is an EXPERIMENTAL API and may be subject to change. + + +Perms: read + +Inputs: +```json +[ + { + "addresses": [ + "f01234" + ], + "fields": { + "abc": [ + { + "codec": 81, + "value": "ZGRhdGE=" + } + ] + }, + "fromHeight": 1010, + "toHeight": 1020 + } +] +``` + +Response: +```json +{ + "entries": [ + { + "Flags": 7, + "Key": "string value", + "Codec": 42, + "Value": "Ynl0ZSBhcnJheQ==" + } + ], + "emitter": "f01234", + "reverted": true, + "height": 10101, + "tipsetKey": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ], + "msgCid": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +} +``` + +## Sync +The Sync method group contains methods for interacting with and +observing the lotus sync service. + + +### SyncCheckBad +SyncCheckBad checks if a block was marked as bad, and if it was, returns +the reason. + + +Perms: read + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: `"string value"` + +### SyncCheckpoint +SyncCheckpoint marks a blocks as checkpointed, meaning that it won't ever fork away from it. + + +Perms: admin + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `{}` + +### SyncIncomingBlocks +SyncIncomingBlocks returns a channel streaming incoming, potentially not +yet synced block headers. + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "Miner": "f01234", + "Ticket": { + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "ElectionProof": { + "WinCount": 9, + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "BeaconEntries": [ + { + "Round": 42, + "Data": "Ynl0ZSBhcnJheQ==" + } + ], + "WinPoStProof": [ + { + "PoStProof": 8, + "ProofBytes": "Ynl0ZSBhcnJheQ==" + } + ], + "Parents": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ], + "ParentWeight": "0", + "Height": 10101, + "ParentStateRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "ParentMessageReceipts": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Messages": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "BLSAggregate": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Timestamp": 42, + "BlockSig": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "ForkSignaling": 42, + "ParentBaseFee": "0" +} +``` + +### SyncMarkBad +SyncMarkBad marks a blocks as bad, meaning that it won't ever by synced. +Use with extreme caution. + + +Perms: admin + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: `{}` + +### SyncState +SyncState returns the current status of the lotus sync system. + + +Perms: read + +Inputs: `null` + +Response: +```json +{ + "ActiveSyncs": [ + { + "WorkerID": 42, + "Base": { + "Cids": null, + "Blocks": null, + "Height": 0 + }, + "Target": { + "Cids": null, + "Blocks": null, + "Height": 0 + }, + "Stage": 1, + "Height": 10101, + "Start": "0001-01-01T00:00:00Z", + "End": "0001-01-01T00:00:00Z", + "Message": "string value" + } + ], + "VMApplied": 42 +} +``` + +### SyncSubmitBlock +SyncSubmitBlock can be used to submit a newly created block to the. +network through this node + + +Perms: write + +Inputs: +```json +[ + { + "Header": { + "Miner": "f01234", + "Ticket": { + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "ElectionProof": { + "WinCount": 9, + "VRFProof": "Ynl0ZSBhcnJheQ==" + }, + "BeaconEntries": [ + { + "Round": 42, + "Data": "Ynl0ZSBhcnJheQ==" + } + ], + "WinPoStProof": [ + { + "PoStProof": 8, + "ProofBytes": "Ynl0ZSBhcnJheQ==" + } + ], + "Parents": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ], + "ParentWeight": "0", + "Height": 10101, + "ParentStateRoot": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "ParentMessageReceipts": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "Messages": { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + "BLSAggregate": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "Timestamp": 42, + "BlockSig": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "ForkSignaling": 42, + "ParentBaseFee": "0" + }, + "BlsMessages": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ], + "SecpkMessages": [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } + ] + } +] +``` + +Response: `{}` + +### SyncUnmarkAllBad +SyncUnmarkAllBad purges bad block cache, making it possible to sync to chains previously marked as bad + + +Perms: admin + +Inputs: `null` + +Response: `{}` + +### SyncUnmarkBad +SyncUnmarkBad unmarks a blocks as bad, making it possible to be validated and synced again. + + +Perms: admin + +Inputs: +```json +[ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + } +] +``` + +Response: `{}` + +### SyncValidateTipset +SyncValidateTipset indicates whether the provided tipset is valid or not + + +Perms: read + +Inputs: +```json +[ + [ + { + "/": "bafy2bzacea3wsdh6y3a36tb3skempjoxqpuyompjbmfeyf34fi3uy6uue42v4" + }, + { + "/": "bafy2bzacebp3shtrn43k7g3unredz7fxn4gj533d3o43tqn2p2ipxxhrvchve" + } + ] +] +``` + +Response: `true` + +## Wallet + + +### WalletBalance +WalletBalance returns the balance of the given address at the current head of the chain. + + +Perms: read + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `"0"` + +### WalletDefaultAddress +WalletDefaultAddress returns the address marked as default in the wallet. + + +Perms: write + +Inputs: `null` + +Response: `"f01234"` + +### WalletDelete +WalletDelete deletes an address from the wallet. + + +Perms: admin + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `{}` + +### WalletExport +WalletExport returns the private key of an address in the wallet. + + +Perms: admin + +Inputs: +```json +[ + "f01234" +] +``` + +Response: +```json +{ + "Type": "bls", + "PrivateKey": "Ynl0ZSBhcnJheQ==" +} +``` + +### WalletHas +WalletHas indicates whether the given address is in the wallet. + + +Perms: write + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `true` + +### WalletImport +WalletImport receives a KeyInfo, which includes a private key, and imports it into the wallet. + + +Perms: admin + +Inputs: +```json +[ + { + "Type": "bls", + "PrivateKey": "Ynl0ZSBhcnJheQ==" + } +] +``` + +Response: `"f01234"` + +### WalletList +WalletList lists all the addresses in the wallet. + + +Perms: write + +Inputs: `null` + +Response: +```json +[ + "f01234" +] +``` + +### WalletNew +WalletNew creates a new address in the wallet with the given sigType. +Available key types: bls, secp256k1, secp256k1-ledger +Support for numerical types: 1 - secp256k1, 2 - BLS is deprecated + + +Perms: write + +Inputs: +```json +[ + "bls" +] +``` + +Response: `"f01234"` + +### WalletSetDefault +WalletSetDefault marks the given address as the default one. + + +Perms: write + +Inputs: +```json +[ + "f01234" +] +``` + +Response: `{}` + +### WalletSign +WalletSign signs the given bytes using the given address. + + +Perms: sign + +Inputs: +```json +[ + "f01234", + "Ynl0ZSBhcnJheQ==" +] +``` + +Response: +```json +{ + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" +} +``` + +### WalletSignMessage +WalletSignMessage signs the given message using the given address. + + +Perms: sign + +Inputs: +```json +[ + "f01234", + { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + } +] +``` + +Response: +```json +{ + "Message": { + "Version": 42, + "To": "f01234", + "From": "f01234", + "Nonce": 42, + "Value": "0", + "GasLimit": 9, + "GasFeeCap": "0", + "GasPremium": "0", + "Method": 1, + "Params": "Ynl0ZSBhcnJheQ==", + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } + }, + "Signature": { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + }, + "CID": { + "/": "bafy2bzacebbpdegvr3i4cosewthysg5xkxpqfn2wfcz6mv2hmoktwbdxkax4s" + } +} +``` + +### WalletValidateAddress +WalletValidateAddress validates whether a given string can be decoded as a well-formed address + + +Perms: read + +Inputs: +```json +[ + "string value" +] +``` + +Response: `"f01234"` + +### WalletVerify +WalletVerify takes an address, a signature, and some bytes, and indicates whether the signature is valid. +The address does not have to be in the wallet. + + +Perms: read + +Inputs: +```json +[ + "f01234", + "Ynl0ZSBhcnJheQ==", + { + "Type": 2, + "Data": "Ynl0ZSBhcnJheQ==" + } +] +``` + +Response: `true` + +## Web3 + + +### Web3ClientVersion +Returns the client version + + +Perms: read + +Inputs: `null` + +Response: `"string value"` + diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index ef4f3792f3d..9bf926f69e2 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1078,8 +1078,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace return []*ethtypes.EthTraceFilterResult{}, nil } - traceCounter := 0 - + traceCounter := ethtypes.EthUint64(0) for blkNum := fromBlock; blkNum <= toBlock; blkNum++ { blockTraces, err := a.EthTraceBlock(ctx, strconv.FormatUint(uint64(blkNum), 10)) if err != nil { @@ -1107,7 +1106,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace results = append(results, &txTrace) // If Count is specified, limit the results - if filter.Count != nil && len(results) >= *filter.Count { + if filter.Count != nil && ethtypes.EthUint64(len(results)) >= *filter.Count { return results, nil } } From c6597eb0c82d080f9b459d2bc06331c31468e169 Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 15 Jul 2024 15:10:46 -1000 Subject: [PATCH 20/42] changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8e93ff6e2ec..16437288446 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ ## New features - feat: Add trace transaction API supporting RPC method `trace_transaction` ([filecoin-project/lotus#12068](https://github.com/filecoin-project/lotus/pull/12068)) +- feat: Add trace filter API supporting RPC method `trace_filter` ([filecoin-project/lotus#12123](https://github.com/filecoin-project/lotus/pull/12123)) ## Improvements From 0173fc4306d7e44bb9a00f3396b28ee80d027439 Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 15 Jul 2024 15:24:04 -1000 Subject: [PATCH 21/42] fix test type --- itests/eth_transactions_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/itests/eth_transactions_test.go b/itests/eth_transactions_test.go index c7c85cd1398..f7972b6edf6 100644 --- a/itests/eth_transactions_test.go +++ b/itests/eth_transactions_test.go @@ -736,8 +736,8 @@ func TestTraceFilter(t *testing.T) { require.EqualValues(t, tracesAddressFilter[0].TransactionHash, hash) require.EqualValues(t, tracesAddressFilter[0].EthTrace.Type, "create") - after := 1 - count := 2 + after := ethtypes.EthUint64(1) + count := ethtypes.EthUint64(2) filter = ethtypes.EthTraceFilterCriteria{ FromBlock: &fromBlock, ToBlock: &toBlock, From 5cc2b26daef91b25446cb7672ecfb7c948ae54d8 Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 15 Jul 2024 15:31:22 -1000 Subject: [PATCH 22/42] decodeAddressFilter is unused --- node/impl/full/eth.go | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index f75aab67812..cefe2a470bb 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1128,20 +1128,6 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace return results, nil } -func decodeAddressFilter(addresses []string) ([]ethtypes.EthAddress, error) { - var decodedAddresses []ethtypes.EthAddress - for _, addr := range addresses { - ethAddr, err := ethtypes.ParseEthAddress(addr) - if err != nil { - return nil, xerrors.Errorf("invalid address: %w", err) - } - decodedAddresses = append(decodedAddresses, ethAddr) - } - - return decodedAddresses, nil - -} - // matchFilterCriteria checks if a trace matches the filter criteria. func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTraceFilterCriteria, fromDecodedAddresses []ethtypes.EthAddress, toDecodedAddresses []ethtypes.EthAddress) (bool, error) { From 1323ec76263f1e41be01e6293ed026b2f0b7fd05 Mon Sep 17 00:00:00 2001 From: Mikers Date: Tue, 16 Jul 2024 15:56:43 -1000 Subject: [PATCH 23/42] improve trace filter example doc --- api/docgen/docgen.go | 14 ++++++++++++++ build/openrpc/full.json | 8 ++++---- build/openrpc/gateway.json | 8 ++++---- documentation/en/api-v1-unstable-methods.md | 8 ++++---- 4 files changed, 26 insertions(+), 12 deletions(-) diff --git a/api/docgen/docgen.go b/api/docgen/docgen.go index b8190ce187a..7df2489a010 100644 --- a/api/docgen/docgen.go +++ b/api/docgen/docgen.go @@ -372,6 +372,20 @@ func init() { Address: []ethtypes.EthAddress{ethaddr}, }) + after := ethtypes.EthUint64(0) + count := ethtypes.EthUint64(100) + + ethTraceFilterCriteria := ethtypes.EthTraceFilterCriteria{ + FromBlock: pstring("latest"), + ToBlock: pstring("latest"), + FromAddress: ethtypes.EthAddressList{ethaddr}, + ToAddress: ethtypes.EthAddressList{ethaddr}, + After: &after, + Count: &count, + } + addExample(ðTraceFilterCriteria) + addExample(ethTraceFilterCriteria) + percent := types.Percent(123) addExample(percent) addExample(&percent) diff --git a/build/openrpc/full.json b/build/openrpc/full.json index 01ca3d539e2..8cd0c67b1b9 100644 --- a/build/openrpc/full.json +++ b/build/openrpc/full.json @@ -5770,16 +5770,16 @@ "schema": { "examples": [ { - "fromBlock": "string value", - "toBlock": "string value", + "fromBlock": "latest", + "toBlock": "latest", "fromAddress": [ "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], "toAddress": [ "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], - "after": "0x5", - "count": "0x5" + "after": "0x0", + "count": "0x64" } ], "additionalProperties": false, diff --git a/build/openrpc/gateway.json b/build/openrpc/gateway.json index a6a041e0cd5..9e18131ecfd 100644 --- a/build/openrpc/gateway.json +++ b/build/openrpc/gateway.json @@ -4708,16 +4708,16 @@ "schema": { "examples": [ { - "fromBlock": "string value", - "toBlock": "string value", + "fromBlock": "latest", + "toBlock": "latest", "fromAddress": [ "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], "toAddress": [ "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], - "after": "0x5", - "count": "0x5" + "after": "0x0", + "count": "0x64" } ], "additionalProperties": false, diff --git a/documentation/en/api-v1-unstable-methods.md b/documentation/en/api-v1-unstable-methods.md index b3b6b091dfe..cbeda3d409f 100644 --- a/documentation/en/api-v1-unstable-methods.md +++ b/documentation/en/api-v1-unstable-methods.md @@ -2075,16 +2075,16 @@ Inputs: ```json [ { - "fromBlock": "string value", - "toBlock": "string value", + "fromBlock": "latest", + "toBlock": "latest", "fromAddress": [ "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], "toAddress": [ "0x5cbeecf99d3fdb3f25e309cc264f240bb0664031" ], - "after": "0x5", - "count": "0x5" + "after": "0x0", + "count": "0x64" } ] ``` From 78c6162b318b74552d8d8a11b536fad77b139c1b Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 17 Jul 2024 16:17:59 -1000 Subject: [PATCH 24/42] Configuring EthTraceFilterMaxResults sets a limit to how many results are returned in an individual trace_filter RPC API call. --- CHANGELOG.md | 3 ++- node/config/def.go | 1 + node/config/types.go | 4 ++++ node/impl/full/eth.go | 22 +++++++++++++++------- node/modules/ethmodule.go | 3 ++- 5 files changed, 24 insertions(+), 9 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 16437288446..18d8adedb26 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,7 +14,8 @@ ## New features - feat: Add trace transaction API supporting RPC method `trace_transaction` ([filecoin-project/lotus#12068](https://github.com/filecoin-project/lotus/pull/12068)) -- feat: Add trace filter API supporting RPC method `trace_filter` ([filecoin-project/lotus#12123](https://github.com/filecoin-project/lotus/pull/12123)) +- feat: Add trace filter API supporting RPC method `trace_filter` ([filecoin-project/lotus#12123](https://github.com/filecoin-project/lotus/pull/12123)). Configuring `EthTraceFilterMaxResults` sets a limit on how many results are returned in any individual `trace_filter` RPC API call. + ## Improvements diff --git a/node/config/def.go b/node/config/def.go index d8b8e0babb3..7f014e5a753 100644 --- a/node/config/def.go +++ b/node/config/def.go @@ -83,6 +83,7 @@ func DefaultFullNode() *FullNode { Fevm: FevmConfig{ EnableEthRPC: false, EthTxHashMappingLifetimeDays: 0, + EthTraceFilterMaxResults: 100, }, Events: EventsConfig{ DisableRealTimeFilterAPI: false, diff --git a/node/config/types.go b/node/config/types.go index fdda3b84f7a..958ad19a1bc 100644 --- a/node/config/types.go +++ b/node/config/types.go @@ -2,6 +2,7 @@ package config import ( "github.com/filecoin-project/lotus/chain/types" + "github.com/filecoin-project/lotus/chain/types/ethtypes" ) // // NOTE: ONLY PUT STRUCT DEFINITIONS IN THIS FILE @@ -545,6 +546,9 @@ type FevmConfig struct { // Set to 0 to keep all mappings EthTxHashMappingLifetimeDays int + // EthTraceFilterMaxResults sets the maximum results returned per request by trace_filter + EthTraceFilterMaxResults ethtypes.EthUint64 + Events DeprecatedEvents `toml:"Events,omitempty"` } diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index cefe2a470bb..92c1f5b9b66 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -132,10 +132,11 @@ var ( // accepts as the best parent tipset, based on the blocks it is accumulating // within the HEAD tipset. type EthModule struct { - Chain *store.ChainStore - Mpool *messagepool.MessagePool - StateManager *stmgr.StateManager - EthTxHashManager *EthTxHashManager + Chain *store.ChainStore + Mpool *messagepool.MessagePool + StateManager *stmgr.StateManager + EthTxHashManager *EthTxHashManager + EthTraceFilterMaxResults ethtypes.EthUint64 ChainAPI MpoolAPI @@ -1085,9 +1086,16 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace var results []*ethtypes.EthTraceFilterResult - // If filter.Count is specified and it is 0, return an empty result set immediately. - if filter.Count != nil && *filter.Count == 0 { - return []*ethtypes.EthTraceFilterResult{}, nil + if filter.Count != nil { + // If filter.Count is specified and it is 0, return an empty result set immediately. + if *filter.Count == 0 { + return []*ethtypes.EthTraceFilterResult{}, nil + } + + // If filter.Count is specified and is greater than the EthTraceFilterMaxResults config return error + if *filter.Count > a.EthTraceFilterMaxResults { + return nil, xerrors.Errorf("invalid response count") + } } traceCounter := ethtypes.EthUint64(0) diff --git a/node/modules/ethmodule.go b/node/modules/ethmodule.go index 1360daf1a89..1c981f89dda 100644 --- a/node/modules/ethmodule.go +++ b/node/modules/ethmodule.go @@ -101,7 +101,8 @@ func EthModuleAPI(cfg config.FevmConfig) func(helpers.MetricsCtx, repo.LockedRep StateAPI: stateapi, SyncAPI: syncapi, - EthTxHashManager: ðTxHashManager, + EthTxHashManager: ðTxHashManager, + EthTraceFilterMaxResults: cfg.EthTraceFilterMaxResults, }, nil } } From d981c8f1169042078e70979d89ec579e0c2f423e Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 17 Jul 2024 16:21:37 -1000 Subject: [PATCH 25/42] config gen --- documentation/en/default-lotus-config.toml | 6 ++++++ node/config/doc_gen.go | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/documentation/en/default-lotus-config.toml b/documentation/en/default-lotus-config.toml index 2971a4e9199..b2194f558c0 100644 --- a/documentation/en/default-lotus-config.toml +++ b/documentation/en/default-lotus-config.toml @@ -235,6 +235,12 @@ # env var: LOTUS_FEVM_ETHTXHASHMAPPINGLIFETIMEDAYS #EthTxHashMappingLifetimeDays = 0 + # EthTraceFilterMaxResults sets the maximum results returned per request by trace_filter + # + # type: ethtypes.EthUint64 + # env var: LOTUS_FEVM_ETHTRACEFILTERMAXRESULTS + #EthTraceFilterMaxResults = 100 + [Events] # DisableRealTimeFilterAPI will disable the RealTimeFilterAPI that can create and query filters for actor events as they are emitted. diff --git a/node/config/doc_gen.go b/node/config/doc_gen.go index a3360627741..50ae901e344 100644 --- a/node/config/doc_gen.go +++ b/node/config/doc_gen.go @@ -238,6 +238,12 @@ This will also enable the RealTimeFilterAPI and HistoricFilterAPI by default, bu Comment: `EthTxHashMappingLifetimeDays the transaction hash lookup database will delete mappings that have been stored for more than x days Set to 0 to keep all mappings`, }, + { + Name: "EthTraceFilterMaxResults", + Type: "ethtypes.EthUint64", + + Comment: `EthTraceFilterMaxResults sets the maximum results returned per request by trace_filter`, + }, { Name: "Events", Type: "DeprecatedEvents", From d470b2f45e50cc270ee9b9068c0507f69d03c42b Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 17 Jul 2024 16:30:46 -1000 Subject: [PATCH 26/42] block number is flaky and not needed for test --- itests/eth_transactions_test.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/itests/eth_transactions_test.go b/itests/eth_transactions_test.go index f7972b6edf6..8910dc60f8b 100644 --- a/itests/eth_transactions_test.go +++ b/itests/eth_transactions_test.go @@ -703,14 +703,12 @@ func TestTraceFilter(t *testing.T) { // Assert that iniital transactions returned by the trace are valid require.EqualValues(t, len(traces), 3) - require.EqualValues(t, traces[0].BlockNumber, 1) require.EqualValues(t, traces[0].TransactionPosition, 1) require.EqualValues(t, traces[0].EthTrace.Type, "call") require.EqualValues(t, traces[1].TransactionPosition, 1) require.EqualValues(t, traces[1].EthTrace.Type, "call") - //our transaction will be in the third element of traces at block 8 with the expected hash - require.EqualValues(t, traces[2].BlockNumber, 8) + //our transaction will be in the third element of traces with the expected hash require.EqualValues(t, traces[2].TransactionPosition, 1) require.EqualValues(t, traces[2].TransactionHash, hash) require.EqualValues(t, traces[2].EthTrace.Type, "create") @@ -731,7 +729,6 @@ func TestTraceFilter(t *testing.T) { //we should only get our contract deploy transaction require.EqualValues(t, len(tracesAddressFilter), 1) - require.EqualValues(t, tracesAddressFilter[0].BlockNumber, 8) require.EqualValues(t, tracesAddressFilter[0].TransactionPosition, 1) require.EqualValues(t, tracesAddressFilter[0].TransactionHash, hash) require.EqualValues(t, tracesAddressFilter[0].EthTrace.Type, "create") From 0569aefdbfe26296b25095845b29ae4c3d806bca Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 22 Jul 2024 15:17:03 -1000 Subject: [PATCH 27/42] Update node/impl/full/eth.go Co-authored-by: Rod Vagg --- node/impl/full/eth.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 92c1f5b9b66..f34f7221174 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1094,7 +1094,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace // If filter.Count is specified and is greater than the EthTraceFilterMaxResults config return error if *filter.Count > a.EthTraceFilterMaxResults { - return nil, xerrors.Errorf("invalid response count") + return nil, xerrors.Errorf("invalid response count, requested %d, maximum supported is %d", *filter.Count, a.EthTraceFilterMaxResults) } } From aabb500a2c08aabca6b2940e92dceb6300379a29 Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 22 Jul 2024 16:46:50 -1000 Subject: [PATCH 28/42] Update node/impl/full/eth.go Co-authored-by: Rod Vagg --- node/impl/full/eth.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index f34f7221174..3cc2c37b34a 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1128,6 +1128,8 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace // If Count is specified, limit the results if filter.Count != nil && ethtypes.EthUint64(len(results)) >= *filter.Count { return results, nil + } else if filter.Count == nil && len(results) > a.EthTraceFilterMaxResults { + return nil, xerrors.Errorf("too many results, maximum supported is %d, try paginating requests with After and Count", *filter.Count, a.EthTraceFilterMaxResults) } } } From bfe56fbb26befdd7fe249b50430f495d7dd21b6f Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 22 Jul 2024 22:49:19 -1000 Subject: [PATCH 29/42] bugfix --- node/impl/full/eth.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 3cc2c37b34a..efd64ba3d1b 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1128,7 +1128,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace // If Count is specified, limit the results if filter.Count != nil && ethtypes.EthUint64(len(results)) >= *filter.Count { return results, nil - } else if filter.Count == nil && len(results) > a.EthTraceFilterMaxResults { + } else if filter.Count == nil && ethtypes.EthUint64(len(results)) > a.EthTraceFilterMaxResults { return nil, xerrors.Errorf("too many results, maximum supported is %d, try paginating requests with After and Count", *filter.Count, a.EthTraceFilterMaxResults) } } From 1deb787082dbcb2fe17f8246a6986bdba935c8fa Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 22 Jul 2024 23:18:53 -1000 Subject: [PATCH 30/42] remove indentation style fix --- node/impl/full/eth.go | 39 ++++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index efd64ba3d1b..353653b0927 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1110,27 +1110,28 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace if err != nil { return nil, xerrors.Errorf("cannot match filter for block %d: %w", blkNum, err) } - if match { - traceCounter++ - if filter.After != nil && traceCounter <= *filter.After { - continue - } + if !match { + continue + } + traceCounter++ + if filter.After != nil && traceCounter <= *filter.After { + continue + } - txTrace := ethtypes.EthTraceFilterResult{ - EthTrace: blockTrace.EthTrace, - BlockHash: blockTrace.BlockHash, - BlockNumber: blockTrace.BlockNumber, - TransactionHash: blockTrace.TransactionHash, - TransactionPosition: blockTrace.TransactionPosition, - } - results = append(results, &txTrace) + txTrace := ethtypes.EthTraceFilterResult{ + EthTrace: blockTrace.EthTrace, + BlockHash: blockTrace.BlockHash, + BlockNumber: blockTrace.BlockNumber, + TransactionHash: blockTrace.TransactionHash, + TransactionPosition: blockTrace.TransactionPosition, + } + results = append(results, &txTrace) - // If Count is specified, limit the results - if filter.Count != nil && ethtypes.EthUint64(len(results)) >= *filter.Count { - return results, nil - } else if filter.Count == nil && ethtypes.EthUint64(len(results)) > a.EthTraceFilterMaxResults { - return nil, xerrors.Errorf("too many results, maximum supported is %d, try paginating requests with After and Count", *filter.Count, a.EthTraceFilterMaxResults) - } + // If Count is specified, limit the results + if filter.Count != nil && ethtypes.EthUint64(len(results)) >= *filter.Count { + return results, nil + } else if filter.Count == nil && ethtypes.EthUint64(len(results)) > a.EthTraceFilterMaxResults { + return nil, xerrors.Errorf("too many results, maximum supported is %d, try paginating requests with After and Count", *filter.Count, a.EthTraceFilterMaxResults) } } } From 3b30a55530f46976a1c8ad03ebe6a6f28c7edaee Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 22 Jul 2024 23:26:10 -1000 Subject: [PATCH 31/42] add null pointer check --- node/impl/full/eth.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 353653b0927..68960f99eb5 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1164,6 +1164,10 @@ func matchFilterCriteria(trace *ethtypes.EthTraceBlock, filter ethtypes.EthTrace return false, xerrors.Errorf("invalid create trace action") } + if result.Address == nil { + return false, xerrors.Errorf("address is nil in create trace result") + } + traceTo = *result.Address traceFrom = action.From default: From 63e6cf3205559699b6ee5e3cbf08a92d0ddb16ad Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 22 Jul 2024 23:30:14 -1000 Subject: [PATCH 32/42] Create a copy of blockTrace to avoid pointer quirks --- node/impl/full/eth.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 68960f99eb5..cd553a80403 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1105,8 +1105,10 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace return nil, xerrors.Errorf("cannot get trace for block %d: %w", blkNum, err) } - for _, blockTrace := range blockTraces { - match, err := matchFilterCriteria(blockTrace, filter, filter.FromAddress, filter.ToAddress) + for _, _blockTrace := range blockTraces { + // Create a copy of blockTrace to avoid pointer quirks + blockTrace := *_blockTrace + match, err := matchFilterCriteria(&blockTrace, filter, filter.FromAddress, filter.ToAddress) if err != nil { return nil, xerrors.Errorf("cannot match filter for block %d: %w", blkNum, err) } From 5a30419d10a19aee411a331750971304f2289c59 Mon Sep 17 00:00:00 2001 From: Mikers Date: Mon, 22 Jul 2024 23:31:18 -1000 Subject: [PATCH 33/42] method can be private --- node/impl/full/eth.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index cd553a80403..b87dcb9f526 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1041,7 +1041,7 @@ func (a *EthModule) EthTraceTransaction(ctx context.Context, txHash string) ([]* return txTraces, nil } -func (a *EthModule) EthBlockNumberFromString(ctx context.Context, block *string) (ethtypes.EthUint64, error) { +func (a *EthModule) ethBlockNumberFromString(ctx context.Context, block *string) (ethtypes.EthUint64, error) { head := a.Chain.GetHeaviestTipSet() blockValue := "latest" @@ -1074,12 +1074,12 @@ func (a *EthModule) EthBlockNumberFromString(ctx context.Context, block *string) } func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { - fromBlock, err := a.EthBlockNumberFromString(ctx, filter.FromBlock) + fromBlock, err := a.ethBlockNumberFromString(ctx, filter.FromBlock) if err != nil { return nil, xerrors.Errorf("cannot parse fromBlock: %w", err) } - toBlock, err := a.EthBlockNumberFromString(ctx, filter.ToBlock) + toBlock, err := a.ethBlockNumberFromString(ctx, filter.ToBlock) if err != nil { return nil, xerrors.Errorf("cannot parse toBlock: %w", err) } From bab6e1e5ed5cf5a0fe57ebf49d5128a8ffa347e5 Mon Sep 17 00:00:00 2001 From: Mikers Date: Tue, 23 Jul 2024 11:26:15 -1000 Subject: [PATCH 34/42] clean up doc for EthTraceFilterCriteria --- chain/types/ethtypes/eth_types.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/chain/types/ethtypes/eth_types.go b/chain/types/ethtypes/eth_types.go index 9de486dba42..9a1193a9521 100644 --- a/chain/types/ethtypes/eth_types.go +++ b/chain/types/ethtypes/eth_types.go @@ -1050,20 +1050,20 @@ type EthTraceFilterCriteria struct { // Optional, default: "latest". ToBlock *string `json:"toBlock,omitempty"` - // Actor address or a list of addresses from which event logs should originate. + // Actor address or a list of addresses from which transactions that generate traces should originate. // Optional, default: nil. // The JSON decoding must treat a string as equivalent to an array with one value, for example // "0x8888f1f195afa192cfee86069858" must be decoded as [ "0x8888f1f195afa192cfee86069858" ] FromAddress EthAddressList `json:"fromAddress,omitempty"` - // Actor address or a list of addresses to which event logs should be sent. + // Actor address or a list of addresses to which transactions that generate traces are sent. // Optional, default: nil. // The JSON decoding must treat a string as equivalent to an array with one value, for example // "0x8888f1f195afa192cfee86069858" must be decoded as [ "0x8888f1f195afa192cfee86069858" ] ToAddress EthAddressList `json:"toAddress,omitempty"` - // Restricts traces returned to those emitted after this epoch (in hex). - // Optional, default: 0. + // After specifies the offset for pagination of trace results. The number of traces to skip before returning results. + // Optional, default: nil. After *EthUint64 `json:"after,omitempty"` // Limits the number of traces returned. From 68def91e8b6e51fbba94e48144769cbfc778f795 Mon Sep 17 00:00:00 2001 From: Mikers Date: Tue, 23 Jul 2024 11:45:36 -1000 Subject: [PATCH 35/42] increase EthTraceFilterMaxResults to 500 --- node/config/def.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/node/config/def.go b/node/config/def.go index 7f014e5a753..328459d9272 100644 --- a/node/config/def.go +++ b/node/config/def.go @@ -83,7 +83,7 @@ func DefaultFullNode() *FullNode { Fevm: FevmConfig{ EnableEthRPC: false, EthTxHashMappingLifetimeDays: 0, - EthTraceFilterMaxResults: 100, + EthTraceFilterMaxResults: 500, }, Events: EventsConfig{ DisableRealTimeFilterAPI: false, From 494deab8abc81f87f5820dac234c6c0cf525e131 Mon Sep 17 00:00:00 2001 From: Mikers Date: Tue, 23 Jul 2024 11:49:11 -1000 Subject: [PATCH 36/42] clean up earliest --- chain/types/ethtypes/eth_types.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/chain/types/ethtypes/eth_types.go b/chain/types/ethtypes/eth_types.go index 9a1193a9521..d6ca11cffcd 100644 --- a/chain/types/ethtypes/eth_types.go +++ b/chain/types/ethtypes/eth_types.go @@ -1040,14 +1040,14 @@ type EthTraceFilterResult struct { // EthTraceFilterCriteria defines the criteria for filtering traces. type EthTraceFilterCriteria struct { - // Interpreted as an epoch (in hex) or one of "latest" for last mined block, "earliest" for first, - // "pending" for not yet committed messages. + // Interpreted as an epoch (in hex) or one of "latest" for last mined block, "pending" for not yet committed messages. // Optional, default: "latest". + // Note: "earliest" is not a permitted value. FromBlock *string `json:"fromBlock,omitempty"` - // Interpreted as an epoch (in hex) or one of "latest" for last mined block, "earliest" for first, - // "pending" for not yet committed messages. + // Interpreted as an epoch (in hex) or one of "latest" for last mined block, "pending" for not yet committed messages. // Optional, default: "latest". + // Note: "earliest" is not a permitted value. ToBlock *string `json:"toBlock,omitempty"` // Actor address or a list of addresses from which transactions that generate traces should originate. From 3a49b84519a82a82e2d8b61e1737b206510b61e5 Mon Sep 17 00:00:00 2001 From: Mikers Date: Tue, 23 Jul 2024 11:55:19 -1000 Subject: [PATCH 37/42] bury getEthBlockNumberFromString into EthTraceFilter to reduce confusion --- node/impl/full/eth.go | 65 ++++++++++++++++++++++--------------------- 1 file changed, 33 insertions(+), 32 deletions(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index b87dcb9f526..f9596440067 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1041,45 +1041,46 @@ func (a *EthModule) EthTraceTransaction(ctx context.Context, txHash string) ([]* return txTraces, nil } -func (a *EthModule) ethBlockNumberFromString(ctx context.Context, block *string) (ethtypes.EthUint64, error) { - head := a.Chain.GetHeaviestTipSet() - - blockValue := "latest" - if block != nil { - blockValue = *block - } - - switch blockValue { - case "earliest": - return 0, xerrors.Errorf("block param \"earliest\" is not supported") - case "pending": - return ethtypes.EthUint64(head.Height()), nil - case "latest": - parent, err := a.Chain.GetTipSetFromKey(ctx, head.Parents()) - if err != nil { - return 0, fmt.Errorf("cannot get parent tipset") - } - return ethtypes.EthUint64(parent.Height()), nil - case "safe": - latestHeight := head.Height() - 1 - safeHeight := latestHeight - ethtypes.SafeEpochDelay - return ethtypes.EthUint64(safeHeight), nil - default: - blockNum, err := ethtypes.EthUint64FromHex(blockValue) - if err != nil { - return 0, xerrors.Errorf("cannot parse fromBlock: %w", err) +func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { + // Define EthBlockNumberFromString as a private function within EthTraceFilter + getEthBlockNumberFromString := func(ctx context.Context, block *string) (ethtypes.EthUint64, error) { + head := a.Chain.GetHeaviestTipSet() + + blockValue := "latest" + if block != nil { + blockValue = *block + } + + switch blockValue { + case "earliest": + return 0, xerrors.Errorf("block param \"earliest\" is not supported") + case "pending": + return ethtypes.EthUint64(head.Height()), nil + case "latest": + parent, err := a.Chain.GetTipSetFromKey(ctx, head.Parents()) + if err != nil { + return 0, fmt.Errorf("cannot get parent tipset") + } + return ethtypes.EthUint64(parent.Height()), nil + case "safe": + latestHeight := head.Height() - 1 + safeHeight := latestHeight - ethtypes.SafeEpochDelay + return ethtypes.EthUint64(safeHeight), nil + default: + blockNum, err := ethtypes.EthUint64FromHex(blockValue) + if err != nil { + return 0, xerrors.Errorf("cannot parse fromBlock: %w", err) + } + return blockNum, err } - return blockNum, err } -} -func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTraceFilterCriteria) ([]*ethtypes.EthTraceFilterResult, error) { - fromBlock, err := a.ethBlockNumberFromString(ctx, filter.FromBlock) + fromBlock, err := getEthBlockNumberFromString(ctx, filter.FromBlock) if err != nil { return nil, xerrors.Errorf("cannot parse fromBlock: %w", err) } - toBlock, err := a.ethBlockNumberFromString(ctx, filter.ToBlock) + toBlock, err := getEthBlockNumberFromString(ctx, filter.ToBlock) if err != nil { return nil, xerrors.Errorf("cannot parse toBlock: %w", err) } From bfbfacc7001f76e0020e2bcb32ab39acf6c52df8 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 24 Jul 2024 10:27:47 -1000 Subject: [PATCH 38/42] Update node/config/types.go Co-authored-by: Rod Vagg --- node/config/types.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/node/config/types.go b/node/config/types.go index 420e4ce6757..43961e62f73 100644 --- a/node/config/types.go +++ b/node/config/types.go @@ -548,7 +548,7 @@ type FevmConfig struct { EthTxHashMappingLifetimeDays int // EthTraceFilterMaxResults sets the maximum results returned per request by trace_filter - EthTraceFilterMaxResults ethtypes.EthUint64 + EthTraceFilterMaxResults uint64 Events DeprecatedEvents `toml:"Events,omitempty"` } From 0db2efe3dd1bb082684133bd755d12fd6efc2bf6 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 24 Jul 2024 10:32:44 -1000 Subject: [PATCH 39/42] Update node/impl/full/eth.go Co-authored-by: Rod Vagg --- node/impl/full/eth.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 14613b86822..750e25d5651 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -136,7 +136,7 @@ type EthModule struct { Mpool *messagepool.MessagePool StateManager *stmgr.StateManager EthTxHashManager *EthTxHashManager - EthTraceFilterMaxResults ethtypes.EthUint64 + EthTraceFilterMaxResults uint64 EthEventHandler *EthEventHandler ChainAPI MpoolAPI From 94dab561aa6a74c1bf93596b77c7bf4c8347a0b7 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 24 Jul 2024 10:33:07 -1000 Subject: [PATCH 40/42] Update node/impl/full/eth.go Co-authored-by: Rod Vagg --- node/impl/full/eth.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 750e25d5651..418883250c9 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1134,7 +1134,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace if filter.Count != nil && ethtypes.EthUint64(len(results)) >= *filter.Count { return results, nil } else if filter.Count == nil && ethtypes.EthUint64(len(results)) > a.EthTraceFilterMaxResults { - return nil, xerrors.Errorf("too many results, maximum supported is %d, try paginating requests with After and Count", *filter.Count, a.EthTraceFilterMaxResults) + return nil, xerrors.Errorf("too many results, maximum supported is %d, try paginating requests with After and Count", a.EthTraceFilterMaxResults) } } } From b9d898f4a2571ca8cae6e4a2be21bea3d2346059 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 24 Jul 2024 11:15:46 -1000 Subject: [PATCH 41/42] type fixes a.EthTraceFilterMaxResults --- node/config/doc_gen.go | 2 +- node/config/types.go | 1 - node/impl/full/eth.go | 4 ++-- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/node/config/doc_gen.go b/node/config/doc_gen.go index b875a43edbf..780d5d073fb 100644 --- a/node/config/doc_gen.go +++ b/node/config/doc_gen.go @@ -228,7 +228,7 @@ Set to 0 to keep all mappings`, }, { Name: "EthTraceFilterMaxResults", - Type: "ethtypes.EthUint64", + Type: "uint64", Comment: `EthTraceFilterMaxResults sets the maximum results returned per request by trace_filter`, }, diff --git a/node/config/types.go b/node/config/types.go index 43961e62f73..aa977285795 100644 --- a/node/config/types.go +++ b/node/config/types.go @@ -2,7 +2,6 @@ package config import ( "github.com/filecoin-project/lotus/chain/types" - "github.com/filecoin-project/lotus/chain/types/ethtypes" ) // // NOTE: ONLY PUT STRUCT DEFINITIONS IN THIS FILE diff --git a/node/impl/full/eth.go b/node/impl/full/eth.go index 418883250c9..83a721542da 100644 --- a/node/impl/full/eth.go +++ b/node/impl/full/eth.go @@ -1094,7 +1094,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace } // If filter.Count is specified and is greater than the EthTraceFilterMaxResults config return error - if *filter.Count > a.EthTraceFilterMaxResults { + if uint64(*filter.Count) > a.EthTraceFilterMaxResults { return nil, xerrors.Errorf("invalid response count, requested %d, maximum supported is %d", *filter.Count, a.EthTraceFilterMaxResults) } } @@ -1133,7 +1133,7 @@ func (a *EthModule) EthTraceFilter(ctx context.Context, filter ethtypes.EthTrace // If Count is specified, limit the results if filter.Count != nil && ethtypes.EthUint64(len(results)) >= *filter.Count { return results, nil - } else if filter.Count == nil && ethtypes.EthUint64(len(results)) > a.EthTraceFilterMaxResults { + } else if filter.Count == nil && uint64(len(results)) > a.EthTraceFilterMaxResults { return nil, xerrors.Errorf("too many results, maximum supported is %d, try paginating requests with After and Count", a.EthTraceFilterMaxResults) } } From 56440b5898e44894b8d740f6fc7440831f370fb8 Mon Sep 17 00:00:00 2001 From: Mikers Date: Wed, 24 Jul 2024 11:16:35 -1000 Subject: [PATCH 42/42] make docsgen-cli --- documentation/en/default-lotus-config.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/documentation/en/default-lotus-config.toml b/documentation/en/default-lotus-config.toml index b2194f558c0..2113c9e1ab7 100644 --- a/documentation/en/default-lotus-config.toml +++ b/documentation/en/default-lotus-config.toml @@ -237,9 +237,9 @@ # EthTraceFilterMaxResults sets the maximum results returned per request by trace_filter # - # type: ethtypes.EthUint64 + # type: uint64 # env var: LOTUS_FEVM_ETHTRACEFILTERMAXRESULTS - #EthTraceFilterMaxResults = 100 + #EthTraceFilterMaxResults = 500 [Events]