{"modulePath":"github.com/ethereum-optimism/optimism","version":"v1.21.0","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package fetch\n\n## Functions\n\n```go\nfunc Batches(client *ethclient.Client, beacon *sources.L1BeaconClient, config Config) (totalValid, totalInvalid uint64)\n```\nBatches fetches \u0026 stores all transactions sent to the batch inbox address in the given block range (inclusive to exclusive). The transactions \u0026 metadata are written to the out directory.\n\n## Types\n\n```go\ntype Config struct {\n\tStart, End         uint64\n\tChainID            *big.Int\n\tBatchInbox         common.Address\n\tBatchSenders       map[common.Address]struct{}\n\tOutDirectory       string\n\tConcurrentRequests uint64\n}\n```\n\n```go\ntype TransactionWithMetadata struct {\n\tTxIndex     uint64             `json:\"tx_index\"`\n\tInboxAddr   common.Address     `json:\"inbox_address\"`\n\tBlockNumber uint64             `json:\"block_number\"`\n\tBlockHash   common.Hash        `json:\"block_hash\"`\n\tBlockTime   uint64             `json:\"block_time\"`\n\tChainId     uint64             `json:\"chain_id\"`\n\tSender      common.Address     `json:\"sender\"`\n\tValidSender bool               `json:\"valid_sender\"`\n\tFrames      []derive.Frame     `json:\"frames\"`\n\tFrameErrs   []string           `json:\"frame_parse_error\"`\n\tValidFrames []bool             `json:\"valid_data\"`\n\tTx          *types.Transaction `json:\"tx\"`\n}\n```\n\n","path":"github.com/ethereum-optimism/optimism/op-node/cmd/batch_decoder/fetch","name":"fetch","synopsis":"","isRedistributable":true}
