> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://beta-docs.payabli.com/api-reference/moneyout/capture-a-list-of-authorized-payout-transactions/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://beta-docs.payabli.com/_mcp/server. # Capture list of payouts POST https://api-sandbox.payabli.com/api/MoneyOut/captureAll Content-Type: application/json Captures an array of authorized payout transactions for settlement. Reference: https://beta-docs.payabli.com/api-reference/moneyout/capture-a-list-of-authorized-payout-transactions ## Authentication - `requestToken` header (required) — API Key authentication via header ## Servers - `https://api-sandbox.payabli.com/api` (Sandbox, default) - `https://api.payabli.com/api` (Production) ## Request ### Headers - `idempotencyKey` (string, optional) — A unique ID you can include to prevent duplicating objects or transactions if a request is sent more than once. This key is not generated in Payabli, you must generate it yourself. ### Body (application/json) This endpoint expects a list of string. - `list of string` ## Response ### 200 Success - `isSuccess` (boolean, optional) — Boolean indicating whether the operation was successful. A `true` value indicates success. A `false` value indicates failure. - `pageIdentifier` (string, optional) — Auxiliary validation used internally by payment pages and components. - `responseCode` (integer, optional) — Code for the response. Learn more in [API Response Codes](/api-reference/api-responses). - `responseData` (list of CaptureAllOutResponseResponseDataItem, optional) — Array of objects describing the transactions. - `responseText` (string, optional) — Response text for operation: 'Success' or 'Declined'. ## Errors ### 400 Bad Request Error Bad request/ invalid data - `any` ### 401 Unauthorized Error Unauthorized request. - `any` ### 500 Internal Server Error Internal API Error - `any` ### 503 Service Unavailable Error Database connection error - `isSuccess` (boolean, optional) — Boolean indicating whether the operation was successful. A `true` value indicates success. A `false` value indicates failure. - `responseData` (map from string to any, optional) — The object containing the response data. - `responseText` (string, optional) — Response text for operation: 'Success' or 'Declined'. ## Types ### CaptureAllOutResponseResponseDataItem - `CustomerId` (long, optional) — Internal unique Id of vendor owner of transaction. Returns `0` if the transaction was not assigned to an existing vendor or no vendor was created. - `ReferenceId` (string, optional) — The transaction identifier in Payabli. - `ResultCode` (integer, optional) — Result code for the operation. Value 1 indicates a successful operation, values 2 and 3 indicate errors. A value of 10 indicates that an operation has been initiated and is pending. - `ResultText` (string, optional) — Text describing the result. If `ResultCode`` = 1, returns 'Authorized'. If `ResultCode` = 2 or 3, this contains the cause of the decline. ## Examples **Request** ```json [ "2-29", "2-28", "2-27" ] ``` **Response** ```json { "isSuccess": true, "pageIdentifier": "null", "responseCode": 1, "responseData": [ { "CustomerId": 1000000, "ReferenceId": "129-230", "ResultCode": 1, "ResultText": "Captured" }, { "CustomerId": 1000000, "ReferenceId": "129-219", "ResultCode": 1, "ResultText": "Captured" } ], "responseText": "Success" } ``` **SDK Code** ```python CaptureAll import requests url = "https://api-sandbox.payabli.com/api/MoneyOut/captureAll" payload = ["2-29", "2-28", "2-27"] headers = { "requestToken": "", "Content-Type": "application/json" } response = requests.post(url, json=payload, headers=headers) print(response.json()) ``` ```javascript CaptureAll const url = 'https://api-sandbox.payabli.com/api/MoneyOut/captureAll'; const options = { method: 'POST', headers: {requestToken: '', 'Content-Type': 'application/json'}, body: '["2-29","2-28","2-27"]' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go CaptureAll package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-sandbox.payabli.com/api/MoneyOut/captureAll" payload := strings.NewReader("[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("requestToken", "") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby CaptureAll require 'uri' require 'net/http' url = URI("https://api-sandbox.payabli.com/api/MoneyOut/captureAll") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["requestToken"] = '' request["Content-Type"] = 'application/json' request.body = "[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]" response = http.request(request) puts response.read_body ``` ```java CaptureAll import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-sandbox.payabli.com/api/MoneyOut/captureAll") .header("requestToken", "") .header("Content-Type", "application/json") .body("[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]") .asString(); ``` ```php CaptureAll request('POST', 'https://api-sandbox.payabli.com/api/MoneyOut/captureAll', [ 'body' => '[ "2-29", "2-28", "2-27" ]', 'headers' => [ 'Content-Type' => 'application/json', 'requestToken' => '', ], ]); echo $response->getBody(); ``` ```csharp CaptureAll using RestSharp; var client = new RestClient("https://api-sandbox.payabli.com/api/MoneyOut/captureAll"); var request = new RestRequest(Method.POST); request.AddHeader("requestToken", ""); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "[\n \"2-29\",\n \"2-28\",\n \"2-27\"\n]", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift CaptureAll import Foundation let headers = [ "requestToken": "", "Content-Type": "application/json" ] let parameters = ["2-29", "2-28", "2-27"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-sandbox.payabli.com/api/MoneyOut/captureAll")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ``` > If you're a software company, you're a payments company™