Skip to content

Commit 311a4ea

Browse files
Merge pull request #303 from amanusk/feat/tx_underpriced_error
Add errors for fee too low and underpriced replacement transaction
2 parents 3473dbc + eef47b0 commit 311a4ea

File tree

1 file changed

+28
-1
lines changed

1 file changed

+28
-1
lines changed

api/starknet_write_api.json

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,12 @@
4444
{
4545
"$ref": "#/components/errors/INVALID_TRANSACTION_NONCE"
4646
},
47+
{
48+
"$ref": "#/components/errors/REPLACEMENT_TRANSACTION_UNDERPRICED"
49+
},
50+
{
51+
"$ref": "#/components/errors/FEE_BELOW_MINIMUM"
52+
},
4753
{
4854
"$ref": "#/components/errors/VALIDATION_FAILURE"
4955
},
@@ -112,6 +118,12 @@
112118
{
113119
"$ref": "#/components/errors/INVALID_TRANSACTION_NONCE"
114120
},
121+
{
122+
"$ref": "#/components/errors/REPLACEMENT_TRANSACTION_UNDERPRICED"
123+
},
124+
{
125+
"$ref": "#/components/errors/FEE_BELOW_MINIMUM"
126+
},
115127
{
116128
"$ref": "#/components/errors/VALIDATION_FAILURE"
117129
},
@@ -176,6 +188,12 @@
176188
{
177189
"$ref": "#/components/errors/INVALID_TRANSACTION_NONCE"
178190
},
191+
{
192+
"$ref": "#/components/errors/REPLACEMENT_TRANSACTION_UNDERPRICED"
193+
},
194+
{
195+
"$ref": "#/components/errors/FEE_BELOW_MINIMUM"
196+
},
179197
{
180198
"$ref": "#/components/errors/VALIDATION_FAILURE"
181199
},
@@ -232,7 +250,8 @@
232250
},
233251
"INVALID_TRANSACTION_NONCE": {
234252
"code": 52,
235-
"message": "Invalid transaction nonce"
253+
"message": "Invalid transaction nonce",
254+
"data": "Invalid transaction nonce of contract at address <ADDRESS>. Account nonce: <NONCE>; got: <PAYLOAD_NONCE>."
236255
},
237256
"INSUFFICIENT_RESOURCES_FOR_VALIDATE": {
238257
"code": 53,
@@ -280,6 +299,14 @@
280299
"code": 63,
281300
"message": "An unexpected error occurred",
282301
"data": "string"
302+
},
303+
"REPLACEMENT_TRANSACTION_UNDERPRICED": {
304+
"code": 64,
305+
"message": "Replacement transaction is underpriced"
306+
},
307+
"FEE_BELOW_MINIMUM": {
308+
"code": 65,
309+
"message": "Transaction fee below minimum"
283310
}
284311
}
285312
}

0 commit comments

Comments
 (0)