Subscribe Bundle

介紹

目前Searcher無需訂閱計劃即可通過RPC端點接收bundle數據流

Scutum數據流基於SSE協議構建,數據流統一以bundle形式推送,包含經eth_sendRawTransaction提交的交易和經eth_sendMevBundle提交的bundle。數據流中的交易統一經脫敏處理,僅披露經授權允許披露的交易數據。

Searcher可通過RPC端點訂閱數據執行backrun策略。為避免由於網絡波動導致的數據斷流,建議建立重連機制。

RPC端點

Ethereum:https://eth.blockrazor.xyz/stream

BSC:https://bsc.blockrazor.xyz/stream

限流

數據流上限:5 Streams / IP

Bundle類型

Raw Bundle

Raw Bundle是指尚未被Scutum的Searcher執行backrun策略的bundle,Raw Bundle中的交易來源於兩個渠道。

通過eth_sendRawTransaction提交的交易,會由Scutum自動構建為bundle推送給Searcher,以執行backrun策略,該場景下的Raw Bundle僅包含一筆交易;

通過eth_sendMevBundle提交的Raw Bundle,交易來自於公開內存池或自行構建,該場景下的Raw Bundle至多可包含50筆交易。

Backrun Bundle

Searcher在對Raw Bundle執行backrun策略後,可以通過開啟hint繼續將backrun bundle披露給其他Seacher以執行嵌套的backrun策略,backrun bundle包含raw bundle中的全部交易,以及1筆backrun交易。

數據流結構

Bundle

txs

log

state

默認數據推流中不包含state,如需獲取,請將訂閱地址修改為

Ethereum:https://eth.blockrazor.xyz/stream?state=true

BSC:https://bsc.blockrazor.xyz/stream?state=true

數據流示例(默認)

{
    "chainID":"56" //ETH: 1, BSC:56
    "hash":"0x2ba4c05436d4a48a0ce30341a3164b34b31c091a28ed62618f7b0512aba41f51" // bundle hash
    "txs":[{
          "hash":"0x2ba4c05436d4a48a0ce30341a3164b34b31c091a28ed62618f7b0512aba41f51"
          "from":"0xB4647b856CB9C3856d559C885Bed8B43e0846a47"
          "to":"0x0000000000000000000000000000000000001000"
          "value":"0x1c4eda9192000"
          "nonce":88036
          "calldata":"0xf340fa01000000000000000000000000b4647b856cb9c3856d559c885bed8b43e0846a47"
          "gasLimit":35000
          "gasPrice":1
          "functionSelector":"0xe47d166c"
          "logs":[
              {
                "address": "0x6c1bcf1b99d9f0819459dad661795802d232437e",
                "topics": ["0xc42079f94a6350d7e6235f29174924f928cc2ac818eb64fed8004e115fbcca67", "0x0000000000000000000000000000000000000000000000000000000000000000", "0x0000000000000000000000000000000000000000000000000000000000000000"],
                "data": "0x"
              }
              {
                "address": "0x6c1bcf1b99d9f0819459dad661795802d232437e",
                "topics": ["0xc42079f94a6350d7e6235f29174924f928cc2ac818eb64fed8004e115fbcca67", "0x0000000000000000000000000000000000000000000000000000000000000000", "0x0000000000000000000000000000000000000000000000000000000000000000"],
                "data": "0x"
              }
          ]
    }]
    "nextBlockNumber":39177841  //該bundle所在區塊號
    "maxBlockNumber":39177941  //該bundle有效的最大區塊號
    "proxyBidContract":"0xE7cFc930d385783B3AD156A533EF097202014982" //Scutum的bundle競拍合約地址,調用合約的proxyBid方法可進行競拍
    "refundAddress":"0x6c1bcf1b99d9f0819459dad661795802d232437e", //返利接收地址,競拍金額將按比例返利至refundAddress
    "refundCfg":10380050 //返利配置
}

數據流示例(包含state)

默認數據推流中不包含state,如需獲取,請將訂閱地址修改為

Ethereum:https://eth.blockrazor.xyz/stream?state=true

BSC:https://bsc.blockrazor.xyz/stream?state=true

{
    "chainID":"56" //ETH: 1, BSC:56
    "hash":"0x2ba4c05436d4a48a0ce30341a3164b34b31c091a28ed62618f7b0512aba41f51" // bundle hash
    "txs":[{
          "hash":"0x2ba4c05436d4a48a0ce30341a3164b34b31c091a28ed62618f7b0512aba41f51"
          "from":"0xB4647b856CB9C3856d559C885Bed8B43e0846a47"
          "to":"0x0000000000000000000000000000000000001000"
          "value":"0x1c4eda9192000"
          "nonce":88036
          "calldata":"0xf340fa01000000000000000000000000b4647b856cb9c3856d559c885bed8b43e0846a47"
          "gasLimit":35000
          "gasPrice":1
          "functionSelector":"0xe47d166c"
          "logs":[
              {
                "address": "0x6c1bcf1b99d9f0819459dad661795802d232437e",
                "topics": ["0xc42079f94a6350d7e6235f29174924f928cc2ac818eb64fed8004e115fbcca67", "0x0000000000000000000000000000000000000000000000000000000000000000", "0x0000000000000000000000000000000000000000000000000000000000000000"],
                "data": "0x"
              }
              {
                "address": "0x6c1bcf1b99d9f0819459dad661795802d232437e",
                "topics": ["0xc42079f94a6350d7e6235f29174924f928cc2ac818eb64fed8004e115fbcca67", "0x0000000000000000000000000000000000000000000000000000000000000000", "0x0000000000000000000000000000000000000000000000000000000000000000"],
                "data": "0x"
              }
          ]
    }]
    "nextBlockNumber":39177841  //該bundle所在區塊號
    "maxBlockNumber":39177941  //該bundle有效的最大區塊號
    "proxyBidContract":"0xE7cFc930d385783B3AD156A533EF097202014982" //Scutum的bundle競拍合約地址,調用合約的proxyBid方法可進行競拍
    "refundAddress":"0x6c1bcf1b99d9f0819459dad661795802d232437e", //返利接收地址,競拍金額將按比例返利至refundAddress
    "refundCfg":10380050 //返利配置
    "state": {
	"0x7C3b00CB3B40Cc77d88329A58574E29cFA3cb9E2": { //數據發生變化的狀態對象地址,可以是一個EOA地址或智能合約地址      
	      "0x935b605129a438014d6ae0692623c5e1fbf83d5a631f5a0f8489a301966cf608": "0x00000000000000000000000000000000000000000000010c86a7e418723ffc00"
	      //"狀態對象數據發生變化的Key":"狀態對象數據變化後的Value"
            }      
      }
}

Last updated