Skip to content

Commit 4db6b8f

Browse files
docs: [submit] restructure page sections and add reference links
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent c27d3f8 commit 4db6b8f

1 file changed

Lines changed: 62 additions & 70 deletions

File tree

transaction/submit.mdx

Lines changed: 62 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ llmsDescription: "How to submit signed transactions through Jupiter's proprietar
1010

1111
Jupiter's transaction landing stack is purpose-built for high throughput and low latency:
1212

13-
- **SWQoS via high-stake validator.** Jupiter operates [one of the highest-staked validators on Solana](https://solanabeach.io/validators). Solana's Stake-Weighted Quality of Service (SWQoS) reserves ~80% of a leader's TPU capacity for staked validators proportional to their stake. Higher stake means more reserved bandwidth when forwarding transactions to the current leader.
13+
- **SWQoS via high-stake validator.** Jupiter operates [one of the highest-staked validators on Solana](https://solanabeach.io/validators). Solana's [Stake-Weighted Quality of Service (SWQoS)](https://solana.com/developers/guides/advanced/stake-weighted-qos) reserves ~80% of a leader's TPU capacity for staked validators proportional to their stake. Higher stake means more reserved bandwidth when forwarding transactions to the current leader.
1414
- **Beam (custom TPU forwarder).** Jupiter's own TPU client bypasses standard RPC nodes and sends transactions directly to leaders via staked QUIC connections. This removes intermediaries that could be malicious actors and eliminates RPC processing overhead.
15-
- **DoubleZero.** Dedicated fiber network for validator communication, with FPGA-based spam filtering and transaction deduplication at the network edge. Cleaner transaction set, faster propagation between validators.
15+
- **[DoubleZero](https://doublezero.xyz/).** Dedicated fiber network for validator communication, with FPGA-based spam filtering and transaction deduplication at the network edge. Cleaner transaction set, faster propagation between validators.
1616
- **Ultra-low-latency fiber.** Private fiber links from Tokyo to Frankfurt reduce physical propagation time between Jupiter's infrastructure and leader validators globally.
1717
- **High-performance, scalable infrastructure.** Built to handle the volume of Jupiter's own products, where millions of swaps land daily.
1818

@@ -34,19 +34,11 @@ For `/build` transactions, use the `tipAmount` parameter to have the tip instruc
3434
| **Transaction size** | Must not exceed the Solana transaction size limit (1232 bytes) |
3535
| **API access** | Works with any API key (free, Developer, Launch, Pro) or keyless at 0.5 RPS |
3636

37-
## How /submit differs from /execute
38-
39-
| | `/execute` | `/submit` |
40-
|---|---|---|
41-
| **Paired with** | `/order` (meta-aggregator flow) | `/build` or any signed transaction |
42-
| **Fee model** | Jupiter swap fees (included in the order) | SOL tips (minimum 0.001 SOL) |
43-
| **Transaction source** | Must match the exact transaction from `/order` | Any valid signed Solana transaction |
44-
| **Credit cost** | 0 credits | 0 credits |
45-
| **Use case** | Managed swap execution for `/order` transactions | Any transaction: `/build` swaps, non-Jupiter transactions |
37+
## Code example
4638

47-
## Quick start
39+
### Using /build
4840

49-
The quickest way to use `/submit` is with `/build`'s built-in `tipAmount` parameter, which automatically adds a tip instruction to the response.
41+
Use [`/build`](/swap/build) with the `tipAmount` parameter to automatically include a tip instruction in the response.
5042

5143
<CodeGroup>
5244
```typescript @solana/web3.js expandable
@@ -446,64 +438,9 @@ console.log("Confirmed:", signature);
446438
```
447439
</CodeGroup>
448440
449-
<Tip>
450-
See the [Build](/swap/build) page for complete transaction assembly code, including imports, instruction ordering, and address lookup table handling.
451-
</Tip>
452-
453-
## Use /submit in parallel
454-
455-
You do not need to switch entirely to `/submit`. Run it alongside your existing submission path and compare results directly.
456-
457-
Submit via all paths simultaneously, then poll for confirmation. Whichever lands first wins. This gives you a direct comparison of landing rates with zero risk.
458-
459-
```typescript
460-
// Submit via /submit and your existing RPC in parallel
461-
const [submitResult, rpcResult] = await Promise.allSettled([
462-
// Path 1: Jupiter's landing pipeline
463-
fetch("https://api.jup.ag/tx/v1/submit", {
464-
method: "POST",
465-
headers: { "Content-Type": "application/json" },
466-
body: JSON.stringify({
467-
signedTransaction: base64SignedTx,
468-
}),
469-
}).then((res) => res.json()),
470-
471-
// Path 2: Your existing RPC
472-
connection.sendRawTransaction(serializedTx, {
473-
skipPreflight: true,
474-
maxRetries: 0,
475-
}),
476-
]);
477-
478-
// Both paths return the same signature (the tx hash is deterministic)
479-
const signature =
480-
submitResult.status === "fulfilled"
481-
? submitResult.value.signature
482-
: rpcResult.status === "fulfilled"
483-
? bs58.encode(rpcResult.value)
484-
: null;
485-
486-
// Poll for confirmation, whichever path landed it
487-
const confirmation = await connection.confirmTransaction(
488-
{ signature, blockhash, lastValidBlockHeight },
489-
"confirmed",
490-
);
491-
```
492-
493-
## Best practices
494-
495-
- **Randomise tip accounts:** there are 16 permitted tip accounts. Randomise which one you send to on each transaction to reduce write-lock contention across concurrent submissions.
496-
- **Use `tipAmount` with `/build`:** pass `tipAmount` as a query parameter to have the tip instruction included automatically, rather than adding it manually.
497-
- **Set `maxRetries: 0` on RPC fallback:** if you run `/submit` in parallel with `sendRawTransaction`, let your application control retry logic rather than the RPC node, so you can refresh the blockhash between attempts.
498-
- **Poll for confirmation:** use `confirmTransaction` with the blockhash and `lastValidBlockHeight` from your transaction. If the blockhash expires without confirmation, rebuild with a fresh blockhash and resubmit.
499-
500-
## Standalone tip instructions
441+
### Adding tip instruction manually
501442
502-
If you are submitting a non-Jupiter transaction (another swap protocol, a program call, a transfer), add a tip instruction yourself. It is a standard SOL transfer to any one of the 16 permitted tip accounts.
503-
504-
<Tip>
505-
Randomise which account you send to, to reduce write-lock contention.
506-
</Tip>
443+
For non-Jupiter transactions (another swap protocol, a program call, a transfer), add a standard SOL transfer to one of the 16 permitted tip accounts. Randomise which account you send to on each transaction to reduce write-lock contention.
507444
508445
<CodeGroup>
509446
```typescript @solana/web3.js
@@ -573,6 +510,61 @@ const tipIx = getTransferSolInstruction({
573510
```
574511
</CodeGroup>
575512
513+
## Best practices
514+
515+
- **Randomise tip accounts:** there are 16 permitted tip accounts. Randomise which one you send to on each transaction to reduce write-lock contention across concurrent submissions.
516+
- **Use `tipAmount` with `/build`:** pass `tipAmount` as a query parameter to have the tip instruction included automatically, rather than adding it manually.
517+
- **Set `maxRetries: 0` on RPC fallback:** if you run `/submit` in parallel with `sendRawTransaction`, let your application control retry logic rather than the RPC node, so you can refresh the blockhash between attempts.
518+
- **Poll for confirmation:** use `confirmTransaction` with the blockhash and `lastValidBlockHeight` from your transaction. If the blockhash expires without confirmation, rebuild with a fresh blockhash and resubmit.
519+
520+
## How /submit differs from /execute
521+
522+
| | `/execute` | `/submit` |
523+
|---|---|---|
524+
| **Paired with** | `/order` (meta-aggregator flow) | `/build` or any signed transaction |
525+
| **Fee model** | Jupiter swap fees (included in the order) | SOL tips (minimum 0.001 SOL) |
526+
| **Transaction source** | Must match the exact transaction from `/order` | Any valid signed Solana transaction |
527+
| **Credit cost** | 0 credits | 0 credits |
528+
| **Use case** | Managed swap execution for `/order` transactions | Any transaction: `/build` swaps, non-Jupiter transactions |
529+
530+
## Use /submit in parallel
531+
532+
You do not need to switch entirely to `/submit`. Run it alongside your existing submission path and compare results directly. Submit via all paths simultaneously, then poll for confirmation. Whichever lands first wins.
533+
534+
```typescript
535+
// Submit via /submit and your existing RPC in parallel
536+
const [submitResult, rpcResult] = await Promise.allSettled([
537+
// Path 1: Jupiter's landing pipeline
538+
fetch("https://api.jup.ag/tx/v1/submit", {
539+
method: "POST",
540+
headers: { "Content-Type": "application/json" },
541+
body: JSON.stringify({
542+
signedTransaction: base64SignedTx,
543+
}),
544+
}).then((res) => res.json()),
545+
546+
// Path 2: Your existing RPC
547+
connection.sendRawTransaction(serializedTx, {
548+
skipPreflight: true,
549+
maxRetries: 0,
550+
}),
551+
]);
552+
553+
// Both paths return the same signature (the tx hash is deterministic)
554+
const signature =
555+
submitResult.status === "fulfilled"
556+
? submitResult.value.signature
557+
: rpcResult.status === "fulfilled"
558+
? bs58.encode(rpcResult.value)
559+
: null;
560+
561+
// Poll for confirmation, whichever path landed it
562+
const confirmation = await connection.confirmTransaction(
563+
{ signature, blockhash, lastValidBlockHeight },
564+
"confirmed",
565+
);
566+
```
567+
576568
## API reference
577569
578570
**Endpoint:** `POST https://api.jup.ag/tx/v1/submit`

0 commit comments

Comments
 (0)