tornadoABI.json 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499
  1. [
  2. {
  3. "constant": false,
  4. "inputs": [
  5. {
  6. "internalType": "address",
  7. "name": "_newOperator",
  8. "type": "address"
  9. }
  10. ],
  11. "name": "changeOperator",
  12. "outputs": [],
  13. "payable": false,
  14. "stateMutability": "nonpayable",
  15. "type": "function"
  16. },
  17. {
  18. "constant": true,
  19. "inputs": [
  20. {
  21. "internalType": "bytes32",
  22. "name": "",
  23. "type": "bytes32"
  24. }
  25. ],
  26. "name": "nullifierHashes",
  27. "outputs": [
  28. {
  29. "internalType": "bool",
  30. "name": "",
  31. "type": "bool"
  32. }
  33. ],
  34. "payable": false,
  35. "stateMutability": "view",
  36. "type": "function"
  37. },
  38. {
  39. "constant": false,
  40. "inputs": [
  41. {
  42. "internalType": "bytes",
  43. "name": "_proof",
  44. "type": "bytes"
  45. },
  46. {
  47. "internalType": "bytes32",
  48. "name": "_root",
  49. "type": "bytes32"
  50. },
  51. {
  52. "internalType": "bytes32",
  53. "name": "_nullifierHash",
  54. "type": "bytes32"
  55. },
  56. {
  57. "internalType": "address payable",
  58. "name": "_recipient",
  59. "type": "address"
  60. },
  61. {
  62. "internalType": "address payable",
  63. "name": "_relayer",
  64. "type": "address"
  65. },
  66. {
  67. "internalType": "uint256",
  68. "name": "_fee",
  69. "type": "uint256"
  70. },
  71. {
  72. "internalType": "uint256",
  73. "name": "_refund",
  74. "type": "uint256"
  75. }
  76. ],
  77. "name": "withdraw",
  78. "outputs": [],
  79. "payable": true,
  80. "stateMutability": "payable",
  81. "type": "function"
  82. },
  83. {
  84. "constant": true,
  85. "inputs": [],
  86. "name": "verifier",
  87. "outputs": [
  88. {
  89. "internalType": "contract IVerifier",
  90. "name": "",
  91. "type": "address"
  92. }
  93. ],
  94. "payable": false,
  95. "stateMutability": "view",
  96. "type": "function"
  97. },
  98. {
  99. "constant": true,
  100. "inputs": [
  101. {
  102. "internalType": "bytes32",
  103. "name": "_left",
  104. "type": "bytes32"
  105. },
  106. {
  107. "internalType": "bytes32",
  108. "name": "_right",
  109. "type": "bytes32"
  110. }
  111. ],
  112. "name": "hashLeftRight",
  113. "outputs": [
  114. {
  115. "internalType": "bytes32",
  116. "name": "",
  117. "type": "bytes32"
  118. }
  119. ],
  120. "payable": false,
  121. "stateMutability": "pure",
  122. "type": "function"
  123. },
  124. {
  125. "constant": true,
  126. "inputs": [],
  127. "name": "FIELD_SIZE",
  128. "outputs": [
  129. {
  130. "internalType": "uint256",
  131. "name": "",
  132. "type": "uint256"
  133. }
  134. ],
  135. "payable": false,
  136. "stateMutability": "view",
  137. "type": "function"
  138. },
  139. {
  140. "constant": true,
  141. "inputs": [],
  142. "name": "levels",
  143. "outputs": [
  144. {
  145. "internalType": "uint32",
  146. "name": "",
  147. "type": "uint32"
  148. }
  149. ],
  150. "payable": false,
  151. "stateMutability": "view",
  152. "type": "function"
  153. },
  154. {
  155. "constant": true,
  156. "inputs": [],
  157. "name": "operator",
  158. "outputs": [
  159. {
  160. "internalType": "address",
  161. "name": "",
  162. "type": "address"
  163. }
  164. ],
  165. "payable": false,
  166. "stateMutability": "view",
  167. "type": "function"
  168. },
  169. {
  170. "constant": true,
  171. "inputs": [
  172. {
  173. "internalType": "bytes32",
  174. "name": "_root",
  175. "type": "bytes32"
  176. }
  177. ],
  178. "name": "isKnownRoot",
  179. "outputs": [
  180. {
  181. "internalType": "bool",
  182. "name": "",
  183. "type": "bool"
  184. }
  185. ],
  186. "payable": false,
  187. "stateMutability": "view",
  188. "type": "function"
  189. },
  190. {
  191. "constant": true,
  192. "inputs": [
  193. {
  194. "internalType": "bytes32",
  195. "name": "",
  196. "type": "bytes32"
  197. }
  198. ],
  199. "name": "commitments",
  200. "outputs": [
  201. {
  202. "internalType": "bool",
  203. "name": "",
  204. "type": "bool"
  205. }
  206. ],
  207. "payable": false,
  208. "stateMutability": "view",
  209. "type": "function"
  210. },
  211. {
  212. "constant": true,
  213. "inputs": [],
  214. "name": "denomination",
  215. "outputs": [
  216. {
  217. "internalType": "uint256",
  218. "name": "",
  219. "type": "uint256"
  220. }
  221. ],
  222. "payable": false,
  223. "stateMutability": "view",
  224. "type": "function"
  225. },
  226. {
  227. "constant": true,
  228. "inputs": [],
  229. "name": "currentRootIndex",
  230. "outputs": [
  231. {
  232. "internalType": "uint32",
  233. "name": "",
  234. "type": "uint32"
  235. }
  236. ],
  237. "payable": false,
  238. "stateMutability": "view",
  239. "type": "function"
  240. },
  241. {
  242. "constant": false,
  243. "inputs": [
  244. {
  245. "internalType": "address",
  246. "name": "_newVerifier",
  247. "type": "address"
  248. }
  249. ],
  250. "name": "updateVerifier",
  251. "outputs": [],
  252. "payable": false,
  253. "stateMutability": "nonpayable",
  254. "type": "function"
  255. },
  256. {
  257. "constant": false,
  258. "inputs": [
  259. {
  260. "internalType": "bytes32",
  261. "name": "_commitment",
  262. "type": "bytes32"
  263. }
  264. ],
  265. "name": "deposit",
  266. "outputs": [],
  267. "payable": true,
  268. "stateMutability": "payable",
  269. "type": "function"
  270. },
  271. {
  272. "constant": true,
  273. "inputs": [],
  274. "name": "getLastRoot",
  275. "outputs": [
  276. {
  277. "internalType": "bytes32",
  278. "name": "",
  279. "type": "bytes32"
  280. }
  281. ],
  282. "payable": false,
  283. "stateMutability": "view",
  284. "type": "function"
  285. },
  286. {
  287. "constant": true,
  288. "inputs": [
  289. {
  290. "internalType": "uint256",
  291. "name": "",
  292. "type": "uint256"
  293. }
  294. ],
  295. "name": "roots",
  296. "outputs": [
  297. {
  298. "internalType": "bytes32",
  299. "name": "",
  300. "type": "bytes32"
  301. }
  302. ],
  303. "payable": false,
  304. "stateMutability": "view",
  305. "type": "function"
  306. },
  307. {
  308. "constant": true,
  309. "inputs": [],
  310. "name": "ROOT_HISTORY_SIZE",
  311. "outputs": [
  312. {
  313. "internalType": "uint32",
  314. "name": "",
  315. "type": "uint32"
  316. }
  317. ],
  318. "payable": false,
  319. "stateMutability": "view",
  320. "type": "function"
  321. },
  322. {
  323. "constant": true,
  324. "inputs": [
  325. {
  326. "internalType": "bytes32",
  327. "name": "_nullifierHash",
  328. "type": "bytes32"
  329. }
  330. ],
  331. "name": "isSpent",
  332. "outputs": [
  333. {
  334. "internalType": "bool",
  335. "name": "",
  336. "type": "bool"
  337. }
  338. ],
  339. "payable": false,
  340. "stateMutability": "view",
  341. "type": "function"
  342. },
  343. {
  344. "constant": true,
  345. "inputs": [
  346. {
  347. "internalType": "uint256",
  348. "name": "",
  349. "type": "uint256"
  350. }
  351. ],
  352. "name": "zeros",
  353. "outputs": [
  354. {
  355. "internalType": "bytes32",
  356. "name": "",
  357. "type": "bytes32"
  358. }
  359. ],
  360. "payable": false,
  361. "stateMutability": "view",
  362. "type": "function"
  363. },
  364. {
  365. "constant": true,
  366. "inputs": [],
  367. "name": "ZERO_VALUE",
  368. "outputs": [
  369. {
  370. "internalType": "uint256",
  371. "name": "",
  372. "type": "uint256"
  373. }
  374. ],
  375. "payable": false,
  376. "stateMutability": "view",
  377. "type": "function"
  378. },
  379. {
  380. "constant": true,
  381. "inputs": [
  382. {
  383. "internalType": "uint256",
  384. "name": "",
  385. "type": "uint256"
  386. }
  387. ],
  388. "name": "filledSubtrees",
  389. "outputs": [
  390. {
  391. "internalType": "bytes32",
  392. "name": "",
  393. "type": "bytes32"
  394. }
  395. ],
  396. "payable": false,
  397. "stateMutability": "view",
  398. "type": "function"
  399. },
  400. {
  401. "constant": true,
  402. "inputs": [],
  403. "name": "nextIndex",
  404. "outputs": [
  405. {
  406. "internalType": "uint32",
  407. "name": "",
  408. "type": "uint32"
  409. }
  410. ],
  411. "payable": false,
  412. "stateMutability": "view",
  413. "type": "function"
  414. },
  415. {
  416. "inputs": [
  417. {
  418. "internalType": "contract IVerifier",
  419. "name": "_verifier",
  420. "type": "address"
  421. },
  422. {
  423. "internalType": "uint256",
  424. "name": "_denomination",
  425. "type": "uint256"
  426. },
  427. {
  428. "internalType": "uint32",
  429. "name": "_merkleTreeHeight",
  430. "type": "uint32"
  431. },
  432. {
  433. "internalType": "address",
  434. "name": "_operator",
  435. "type": "address"
  436. }
  437. ],
  438. "payable": false,
  439. "stateMutability": "nonpayable",
  440. "type": "constructor"
  441. },
  442. {
  443. "anonymous": false,
  444. "inputs": [
  445. {
  446. "indexed": true,
  447. "internalType": "bytes32",
  448. "name": "commitment",
  449. "type": "bytes32"
  450. },
  451. {
  452. "indexed": false,
  453. "internalType": "uint32",
  454. "name": "leafIndex",
  455. "type": "uint32"
  456. },
  457. {
  458. "indexed": false,
  459. "internalType": "uint256",
  460. "name": "timestamp",
  461. "type": "uint256"
  462. }
  463. ],
  464. "name": "Deposit",
  465. "type": "event"
  466. },
  467. {
  468. "anonymous": false,
  469. "inputs": [
  470. {
  471. "indexed": false,
  472. "internalType": "address",
  473. "name": "to",
  474. "type": "address"
  475. },
  476. {
  477. "indexed": false,
  478. "internalType": "bytes32",
  479. "name": "nullifierHash",
  480. "type": "bytes32"
  481. },
  482. {
  483. "indexed": true,
  484. "internalType": "address",
  485. "name": "relayer",
  486. "type": "address"
  487. },
  488. {
  489. "indexed": false,
  490. "internalType": "uint256",
  491. "name": "fee",
  492. "type": "uint256"
  493. }
  494. ],
  495. "name": "Withdrawal",
  496. "type": "event"
  497. }
  498. ]