|
471 | 471 | "$ref": "#/components/schemas/Integer"
|
472 | 472 | }
|
473 | 473 | }
|
| 474 | + }, |
| 475 | + { |
| 476 | + "name": "zkevm_forkId", |
| 477 | + "summary": "Returns the network's current fork ID.", |
| 478 | + "params": [], |
| 479 | + "result": { |
| 480 | + "$ref": "#/components/contentDescriptors/ForkID" |
| 481 | + }, |
| 482 | + "examples": [ |
| 483 | + { |
| 484 | + "name": "example", |
| 485 | + "description": "", |
| 486 | + "params": [], |
| 487 | + "result": { |
| 488 | + "name": "exampleResult", |
| 489 | + "description": "", |
| 490 | + "value": "0x1" |
| 491 | + } |
| 492 | + } |
| 493 | + ] |
| 494 | + }, |
| 495 | + { |
| 496 | + "name": "zkevm_getForkById", |
| 497 | + "summary": "returns the network fork ID interval given the provided fork id", |
| 498 | + "params": [ |
| 499 | + { |
| 500 | + "$ref": "#/components/contentDescriptors/ForkID" |
| 501 | + } |
| 502 | + ], |
| 503 | + "result": { |
| 504 | + "$ref": "#/components/contentDescriptors/Fork" |
| 505 | + }, |
| 506 | + "examples": [ |
| 507 | + { |
| 508 | + "name": "example", |
| 509 | + "description": "", |
| 510 | + "params": [ |
| 511 | + { |
| 512 | + "name": "fork id", |
| 513 | + "value": "0x1" |
| 514 | + } |
| 515 | + ], |
| 516 | + "result": { |
| 517 | + "name": "Fork", |
| 518 | + "value": { |
| 519 | + "forkId": "0x8", |
| 520 | + "fromBatchNumber": "0x1", |
| 521 | + "toBatchNumber": "0xffffffffffffffff", |
| 522 | + "version": "", |
| 523 | + "blockNumber": "0x88" |
| 524 | + } |
| 525 | + } |
| 526 | + } |
| 527 | + ] |
| 528 | + }, |
| 529 | + { |
| 530 | + "name": "zkevm_getForkIdByBatchNumber", |
| 531 | + "summary": "returns the fork ID given the provided batch number", |
| 532 | + "params": [ |
| 533 | + { |
| 534 | + "$ref": "#/components/contentDescriptors/BatchNumber" |
| 535 | + } |
| 536 | + ], |
| 537 | + "result": { |
| 538 | + "$ref": "#/components/contentDescriptors/ForkID" |
| 539 | + }, |
| 540 | + "examples": [ |
| 541 | + { |
| 542 | + "name": "example", |
| 543 | + "description": "", |
| 544 | + "params": [], |
| 545 | + "result": { |
| 546 | + "name": "exampleResult", |
| 547 | + "description": "", |
| 548 | + "value": "0x1" |
| 549 | + } |
| 550 | + } |
| 551 | + ] |
| 552 | + }, |
| 553 | + { |
| 554 | + "name": "zkevm_getForks", |
| 555 | + "summary": "returns the network fork ID interval given the provided fork id", |
| 556 | + "params": [], |
| 557 | + "result": { |
| 558 | + "name": "result", |
| 559 | + "schema": { |
| 560 | + "description": "Array of forks", |
| 561 | + "type": "array", |
| 562 | + "items": { |
| 563 | + "title": "fork", |
| 564 | + "$ref": "#/components/contentDescriptors/Fork" |
| 565 | + } |
| 566 | + } |
| 567 | + }, |
| 568 | + "examples": [ |
| 569 | + { |
| 570 | + "name": "example", |
| 571 | + "description": "", |
| 572 | + "params": [], |
| 573 | + "result": { |
| 574 | + "name": "Fork", |
| 575 | + "value": [ |
| 576 | + { |
| 577 | + "forkId": "0x8", |
| 578 | + "fromBatchNumber": "0x1", |
| 579 | + "toBatchNumber": "0xa", |
| 580 | + "version": "", |
| 581 | + "blockNumber": "0x88" |
| 582 | + }, |
| 583 | + { |
| 584 | + "forkId": "0x9", |
| 585 | + "fromBatchNumber": "0xb", |
| 586 | + "toBatchNumber": "0xffffffffffffffff", |
| 587 | + "version": "", |
| 588 | + "blockNumber": "0x188" |
| 589 | + } |
| 590 | + ] |
| 591 | + } |
| 592 | + } |
| 593 | + ] |
474 | 594 | }
|
475 | 595 | ],
|
476 | 596 | "components": {
|
|
520 | 640 | "$ref": "#/components/schemas/Block"
|
521 | 641 | }
|
522 | 642 | },
|
| 643 | + "Fork": { |
| 644 | + "name": "fork", |
| 645 | + "description": "fork", |
| 646 | + "required": true, |
| 647 | + "schema": { |
| 648 | + "$ref": "#/components/schemas/Fork" |
| 649 | + } |
| 650 | + }, |
523 | 651 | "Transaction": {
|
524 | 652 | "required": true,
|
525 | 653 | "name": "transaction",
|
|
548 | 676 | }
|
549 | 677 | ]
|
550 | 678 | }
|
| 679 | + }, |
| 680 | + "ForkID": { |
| 681 | + "name": "forkID", |
| 682 | + "required": true, |
| 683 | + "schema": { |
| 684 | + "$ref": "#/components/schemas/ForkID" |
| 685 | + } |
551 | 686 | }
|
552 | 687 | },
|
553 | 688 | "schemas": {
|
|
1437 | 1572 | "$ref": "#/components/schemas/Integer"
|
1438 | 1573 | }
|
1439 | 1574 | }
|
| 1575 | + }, |
| 1576 | + "ForkID": { |
| 1577 | + "title": "forkID", |
| 1578 | + "type": "string", |
| 1579 | + "description": "The hex representation of the fork's id", |
| 1580 | + "$ref": "#/components/schemas/Integer" |
| 1581 | + }, |
| 1582 | + "Fork": { |
| 1583 | + "title": "Fork", |
| 1584 | + "type": "object", |
| 1585 | + "readOnly": true, |
| 1586 | + "properties": { |
| 1587 | + "forkId": { |
| 1588 | + "$ref": "#/components/schemas/ForkID" |
| 1589 | + }, |
| 1590 | + "fromBatchNumber": { |
| 1591 | + "$ref": "#/components/schemas/BatchNumber" |
| 1592 | + }, |
| 1593 | + "toBatchNumber": { |
| 1594 | + "$ref": "#/components/schemas/BatchNumber" |
| 1595 | + }, |
| 1596 | + "Version": { |
| 1597 | + "title": "batchNumberTag", |
| 1598 | + "type": "string", |
| 1599 | + "description": "fork version" |
| 1600 | + }, |
| 1601 | + "BlockNumber": { |
| 1602 | + "$ref": "#/components/schemas/BlockNumber" |
| 1603 | + } |
| 1604 | + } |
1440 | 1605 | }
|
1441 | 1606 | }
|
1442 | 1607 | }
|
|
0 commit comments