-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjito-block-engine-openapi.yml
More file actions
353 lines (353 loc) · 10.5 KB
/
Copy pathjito-block-engine-openapi.yml
File metadata and controls
353 lines (353 loc) · 10.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
openapi: 3.1.0
info:
title: Jito Block Engine JSON-RPC API
version: '1.0'
description: >-
JSON-RPC API for the Jito Block Engine. The Block Engine accepts bundles and
transactions from searchers, bots, and dApps and forwards them to Jito-Solana
leader validators for atomic block inclusion. Bundles are ordered, atomic
groups of up to five Solana transactions that must execute together — if any
one fails the entire bundle reverts. A SOL tip to a designated tip account is
required for bundles to be considered by leaders.
contact:
name: Jito Labs
url: https://www.jito.network
license:
name: Apache-2.0
url: https://www.apache.org/licenses/LICENSE-2.0
x-mev: true
x-network: solana
servers:
- url: https://mainnet.block-engine.jito.wtf
description: Mainnet global
- url: https://amsterdam.mainnet.block-engine.jito.wtf
description: Mainnet Amsterdam
- url: https://dublin.mainnet.block-engine.jito.wtf
description: Mainnet Dublin
- url: https://frankfurt.mainnet.block-engine.jito.wtf
description: Mainnet Frankfurt
- url: https://london.mainnet.block-engine.jito.wtf
description: Mainnet London
- url: https://ny.mainnet.block-engine.jito.wtf
description: Mainnet New York
- url: https://slc.mainnet.block-engine.jito.wtf
description: Mainnet Salt Lake City
- url: https://singapore.mainnet.block-engine.jito.wtf
description: Mainnet Singapore
- url: https://tokyo.mainnet.block-engine.jito.wtf
description: Mainnet Tokyo
- url: https://testnet.block-engine.jito.wtf
description: Testnet global
- url: https://dallas.testnet.block-engine.jito.wtf
description: Testnet Dallas
- url: https://ny.testnet.block-engine.jito.wtf
description: Testnet New York
tags:
- name: Bundles
description: Submit and inspect atomic Solana transaction bundles.
- name: Transactions
description: Direct sendTransaction proxy to validator leaders.
paths:
/api/v1/bundles:
post:
summary: Submit Bundle Or Query Bundle State
operationId: bundlesRpc
tags:
- Bundles
description: >-
JSON-RPC 2.0 endpoint that accepts the `sendBundle`,
`getBundleStatuses`, `getInflightBundleStatuses`, `getTipAccounts`, and
`getRandomTipAccount` methods. The `method` field in the request body
selects which operation is invoked.
requestBody:
required: true
content:
application/json:
schema:
oneOf:
- $ref: '#/components/schemas/SendBundleRequest'
- $ref: '#/components/schemas/GetBundleStatusesRequest'
- $ref: '#/components/schemas/GetInflightBundleStatusesRequest'
- $ref: '#/components/schemas/GetTipAccountsRequest'
- $ref: '#/components/schemas/GetRandomTipAccountRequest'
responses:
'200':
description: JSON-RPC response object.
content:
application/json:
schema:
oneOf:
- $ref: '#/components/schemas/SendBundleResponse'
- $ref: '#/components/schemas/GetBundleStatusesResponse'
- $ref: '#/components/schemas/GetInflightBundleStatusesResponse'
- $ref: '#/components/schemas/GetTipAccountsResponse'
- $ref: '#/components/schemas/GetRandomTipAccountResponse'
'429':
description: Rate limited.
/api/v1/transactions:
post:
summary: Send Transaction Through Block Engine
operationId: transactionsRpc
tags:
- Transactions
description: >-
JSON-RPC 2.0 endpoint exposing the `sendTransaction` method. Acts as a
direct proxy to Solana's `sendTransaction`, but routes the transaction
through the Block Engine to the next leader for inclusion. Optional
`bundleOnly=true` query parameter forces the transaction to be wrapped
in a single-tx bundle so it is processed under bundle semantics.
parameters:
- in: query
name: bundleOnly
schema:
type: boolean
description: When true, the transaction is treated as a single-transaction bundle.
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/SendTransactionRequest'
responses:
'200':
description: Signature of the submitted transaction.
content:
application/json:
schema:
$ref: '#/components/schemas/SendTransactionResponse'
'429':
description: Rate limited.
components:
schemas:
JsonRpcEnvelope:
type: object
required:
- jsonrpc
- id
- method
properties:
jsonrpc:
type: string
enum:
- '2.0'
id:
oneOf:
- type: integer
- type: string
method:
type: string
SendBundleRequest:
allOf:
- $ref: '#/components/schemas/JsonRpcEnvelope'
- type: object
properties:
method:
const: sendBundle
params:
type: array
minItems: 1
maxItems: 2
items:
oneOf:
- type: array
description: Array of base-58 (default) or base-64 encoded signed transactions. Max 5.
maxItems: 5
items:
type: string
- type: object
properties:
encoding:
type: string
enum:
- base58
- base64
SendBundleResponse:
type: object
properties:
jsonrpc:
type: string
id:
type: integer
result:
type: string
description: Bundle ID — SHA-256 of the concatenated transaction signatures.
GetBundleStatusesRequest:
allOf:
- $ref: '#/components/schemas/JsonRpcEnvelope'
- type: object
properties:
method:
const: getBundleStatuses
params:
type: array
items:
type: array
maxItems: 5
items:
type: string
GetBundleStatusesResponse:
type: object
properties:
jsonrpc:
type: string
id:
type: integer
result:
type: object
properties:
context:
type: object
properties:
slot:
type: integer
value:
type: array
items:
$ref: '#/components/schemas/BundleStatus'
GetInflightBundleStatusesRequest:
allOf:
- $ref: '#/components/schemas/JsonRpcEnvelope'
- type: object
properties:
method:
const: getInflightBundleStatuses
params:
type: array
items:
type: array
maxItems: 5
items:
type: string
GetInflightBundleStatusesResponse:
type: object
properties:
jsonrpc:
type: string
id:
type: integer
result:
type: object
properties:
context:
type: object
properties:
slot:
type: integer
value:
type: array
items:
$ref: '#/components/schemas/InflightBundleStatus'
GetTipAccountsRequest:
allOf:
- $ref: '#/components/schemas/JsonRpcEnvelope'
- type: object
properties:
method:
const: getTipAccounts
params:
type: array
maxItems: 0
GetTipAccountsResponse:
type: object
properties:
jsonrpc:
type: string
id:
type: integer
result:
type: array
description: Tip account public keys.
items:
type: string
GetRandomTipAccountRequest:
allOf:
- $ref: '#/components/schemas/JsonRpcEnvelope'
- type: object
properties:
method:
const: getRandomTipAccount
GetRandomTipAccountResponse:
type: object
properties:
jsonrpc:
type: string
id:
type: integer
result:
type: string
description: Single randomly selected tip account public key.
SendTransactionRequest:
allOf:
- $ref: '#/components/schemas/JsonRpcEnvelope'
- type: object
properties:
method:
const: sendTransaction
params:
type: array
minItems: 1
maxItems: 2
items:
oneOf:
- type: string
description: Base-58 or base-64 encoded signed transaction.
- type: object
properties:
encoding:
type: string
enum:
- base58
- base64
skipPreflight:
type: boolean
preflightCommitment:
type: string
maxRetries:
type: integer
minContextSlot:
type: integer
SendTransactionResponse:
type: object
properties:
jsonrpc:
type: string
id:
type: integer
result:
type: string
description: Transaction signature.
BundleStatus:
type: object
properties:
bundle_id:
type: string
transactions:
type: array
items:
type: string
slot:
type: integer
confirmationStatus:
type: string
enum:
- processed
- confirmed
- finalized
err:
nullable: true
type: object
InflightBundleStatus:
type: object
properties:
bundle_id:
type: string
status:
type: string
enum:
- Invalid
- Pending
- Failed
- Landed
landed_slot:
nullable: true
type: integer