Skip to content

Commit 0c9f8ec

Browse files
author
Micah Zoltu
authored
Define pattern for value of transaction type field (#377)
1 parent 8fcafbb commit 0c9f8ec

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/schemas/transaction.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,8 @@ Transaction1559Unsigned:
3030
properties:
3131
type:
3232
title: type
33-
$ref: '#/components/schemas/byte'
33+
type: string
34+
pattern: ^0x2$
3435
nonce:
3536
title: nonce
3637
$ref: '#/components/schemas/uint'
@@ -77,7 +78,8 @@ Transaction2930Unsigned:
7778
properties:
7879
type:
7980
title: type
80-
$ref: '#/components/schemas/byte'
81+
type: string
82+
pattern: ^0x1$
8183
nonce:
8284
title: nonce
8385
$ref: '#/components/schemas/uint'
@@ -118,7 +120,8 @@ TransactionLegacyUnsigned:
118120
properties:
119121
type:
120122
title: type
121-
$ref: '#/components/schemas/byte'
123+
type: string
124+
pattern: ^0x0$
122125
nonce:
123126
title: nonce
124127
$ref: '#/components/schemas/uint'

0 commit comments

Comments
 (0)