docs(batch-payments): add comprehensive implementation guide with examples, workflow diagrams, and demo videos#57
Open
docs(batch-payments): add comprehensive implementation guide with examples, workflow diagrams, and demo videos#57
Conversation
Replace AI-generated placeholder content in `api-features/batch-payments.mdx` with legacy batch payments documentation while keeping Mintlify-compatible formatting. - removed AI warning and outdated placeholder sections - migrated legacy structure: overview, batch types, benefits, limits, workflow, endpoint, implementation examples, and operational notes - kept endpoint reference inline for `POST /v2/payouts/batch` with OpenAPI link - updated conversion reference to internal payment-types path (`/api-features/conversion-payments`) - removed hidden/invalid use-case dependencies (`payouts`, `payroll`) and legacy-domain links - preserved demo resources via embedded EasyInvoice videos and source link
This was referenced Mar 2, 2026
Open
Member
Author
This was referenced Mar 2, 2026
Open
api-features/batch-payments.mdx with legacy batch payments documentation while keeping Mintlify-compatible formatting. - removed AI warning and
Greptile SummaryThis PR successfully migrates batch payments documentation from legacy docs to Mintlify format, replacing placeholder content with comprehensive, production-ready documentation. Key improvements:
Minor improvements needed:
Confidence Score: 4/5
Important Files Changed
Last reviewed commit: 3ad2520 |
Comment on lines
+88
to
+104
| const batchPayResponse = await fetch('https://api.request.network/v2/payouts/batch', { | ||
| method: 'POST', | ||
| headers: { | ||
| 'Content-Type': 'application/json', | ||
| 'x-api-key': 'your-api-key', | ||
| 'x-platform-id': 'your-platform-id' | ||
| }, | ||
| body: JSON.stringify({ | ||
| requestIds: [ | ||
| "01e273ecc29d4b526df3a0f1f05ffc59372af8752c2b678096e49ac270416a7cdb", | ||
| "02f384fdd39e5c627e04b1f2e6fd60593783b8863c3c789197f5bd381527b8ecd" | ||
| ], | ||
| payer: "0x2e2E5C79F571ef1658d4C2d3684a1FE97DD30570" | ||
| }) | ||
| }); | ||
|
|
||
| const { batchPaymentTransaction, ERC20ApprovalTransactions } = await batchPayResponse.json(); |
There was a problem hiding this comment.
Add error handling for the API fetch call. The current example doesn't check if the response was successful before destructuring the JSON.
Suggested change
| const batchPayResponse = await fetch('https://api.request.network/v2/payouts/batch', { | |
| method: 'POST', | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| 'x-api-key': 'your-api-key', | |
| 'x-platform-id': 'your-platform-id' | |
| }, | |
| body: JSON.stringify({ | |
| requestIds: [ | |
| "01e273ecc29d4b526df3a0f1f05ffc59372af8752c2b678096e49ac270416a7cdb", | |
| "02f384fdd39e5c627e04b1f2e6fd60593783b8863c3c789197f5bd381527b8ecd" | |
| ], | |
| payer: "0x2e2E5C79F571ef1658d4C2d3684a1FE97DD30570" | |
| }) | |
| }); | |
| const { batchPaymentTransaction, ERC20ApprovalTransactions } = await batchPayResponse.json(); | |
| const batchPayResponse = await fetch('https://api.request.network/v2/payouts/batch', { | |
| method: 'POST', | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| 'x-api-key': 'your-api-key', | |
| 'x-platform-id': 'your-platform-id' | |
| }, | |
| body: JSON.stringify({ | |
| requestIds: [ | |
| "01e273ecc29d4b526df3a0f1f05ffc59372af8752c2b678096e49ac270416a7cdb", | |
| "02f384fdd39e5c627e04b1f2e6fd60593783b8863c3c789197f5bd381527b8ecd" | |
| ], | |
| payer: "0x2e2E5C79F571ef1658d4C2d3684a1FE97DD30570" | |
| }) | |
| }); | |
| if (!batchPayResponse.ok) { | |
| throw new Error(`API error: ${batchPayResponse.status}`); | |
| } | |
| const { batchPaymentTransaction, ERC20ApprovalTransactions } = await batchPayResponse.json(); |
Comment on lines
+125
to
+151
| const batchPayResponse = await fetch('https://api.request.network/v2/payouts/batch', { | ||
| method: 'POST', | ||
| headers: { | ||
| 'Content-Type': 'application/json', | ||
| 'x-api-key': 'your-api-key', | ||
| 'x-platform-id': 'your-platform-id' | ||
| }, | ||
| body: JSON.stringify({ | ||
| requests: [ | ||
| { | ||
| payee: "0x6923831ACf5c327260D7ac7C9DfF5b1c3cB3C7D7", | ||
| amount: "10", | ||
| invoiceCurrency: "USD", | ||
| paymentCurrency: "USDC-sepolia" | ||
| }, | ||
| { | ||
| payee: "0xb07D2398d2004378cad234DA0EF14f1c94A530e4", | ||
| amount: "25.50", | ||
| invoiceCurrency: "EUR", | ||
| paymentCurrency: "DAI-sepolia" | ||
| } | ||
| ], | ||
| payer: "0x2e2E5C79F571ef1658d4C2d3684a1FE97DD30570" | ||
| }) | ||
| }); | ||
|
|
||
| const { batchPaymentTransaction, ERC20ApprovalTransactions } = await batchPayResponse.json(); |
There was a problem hiding this comment.
Add error handling for the API fetch call (same issue as Batch Pay Invoices example).
Suggested change
| const batchPayResponse = await fetch('https://api.request.network/v2/payouts/batch', { | |
| method: 'POST', | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| 'x-api-key': 'your-api-key', | |
| 'x-platform-id': 'your-platform-id' | |
| }, | |
| body: JSON.stringify({ | |
| requests: [ | |
| { | |
| payee: "0x6923831ACf5c327260D7ac7C9DfF5b1c3cB3C7D7", | |
| amount: "10", | |
| invoiceCurrency: "USD", | |
| paymentCurrency: "USDC-sepolia" | |
| }, | |
| { | |
| payee: "0xb07D2398d2004378cad234DA0EF14f1c94A530e4", | |
| amount: "25.50", | |
| invoiceCurrency: "EUR", | |
| paymentCurrency: "DAI-sepolia" | |
| } | |
| ], | |
| payer: "0x2e2E5C79F571ef1658d4C2d3684a1FE97DD30570" | |
| }) | |
| }); | |
| const { batchPaymentTransaction, ERC20ApprovalTransactions } = await batchPayResponse.json(); | |
| const batchPayResponse = await fetch('https://api.request.network/v2/payouts/batch', { | |
| method: 'POST', | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| 'x-api-key': 'your-api-key', | |
| 'x-platform-id': 'your-platform-id' | |
| }, | |
| body: JSON.stringify({ | |
| requests: [ | |
| { | |
| payee: "0x6923831ACf5c327260D7ac7C9DfF5b1c3cB3C7D7", | |
| amount: "10", | |
| invoiceCurrency: "USD", | |
| paymentCurrency: "USDC-sepolia" | |
| }, | |
| { | |
| payee: "0xb07D2398d2004378cad234DA0EF14f1c94A530e4", | |
| amount: "25.50", | |
| invoiceCurrency: "EUR", | |
| paymentCurrency: "DAI-sepolia" | |
| } | |
| ], | |
| payer: "0x2e2E5C79F571ef1658d4C2d3684a1FE97DD30570" | |
| }) | |
| }); | |
| if (!batchPayResponse.ok) { | |
| throw new Error(`API error: ${batchPayResponse.status}`); | |
| } | |
| const { batchPaymentTransaction, ERC20ApprovalTransactions } = await batchPayResponse.json(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

TL;DR
Completely rewrote the batch payments documentation with comprehensive implementation guides, code examples, and video demonstrations.
What changed?
How to test?
Why make this change?
The previous content was AI-generated placeholder text that provided minimal value to developers. This rewrite provides actionable documentation with real code examples, clear workflows, and practical guidance needed for implementing batch payments in production applications.