For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
GuidesAPI Reference
GuidesAPI Reference
    • Welcome
  • Product Overview
    • How Cash App Pay Works
    • Cash App Pay on Desktop and POS Devices
    • Cash App Pay on Mobile Devices
  • Partnerships
    • Partner with Cash App Pay
    • Partner Onboarding Requirements
    • Merchant Use Policy
    • Program Rules
  • Technical Guides
    • Cash App Pay Integration Basics
      • API Integration Quickstart
      • Comparing Mobile/Web Environments
      • Brands and Merchants
      • Security Requirements
      • Optimizing Performance with Request Chaining
  • Resources
    • Cash App Pay Assets
    • Glossary of Terms
    • Cash App Pay Status
  • Pay Kit SDK
LogoLogo
On this page
  • Request chaining errors
  • What happens if there’s an error making a request?
Technical GuidesIntegrating with Cash App Pay

Optimizing Performance with Request Chaining

Was this page helpful?
Previous

Introduction to Cash App Pay APIs

Next
Built with

If you send multiple consecutive API requests, consider using request chaining to improve performance. Request chaining allows you to combine multiple requests into a single API call. Since all requests stay within Cash App’s infrastructure, it significantly reduces roundtrip latency.

In internal test, chaining 3 requests—create brand, create merchant, and create customer —reduced latency by 50–70%. Actual performance gains may vary, depending on your infrastructure and the number of requests chained.

Example usage:

  • Create Brand > Create Merchant > Create Customer Request
  • Upsert Brand > Upsert Merchant > Create Payment
  • Retrieve Fee Plan > Upsert Merchant
  • Create API Key > Update Webhook Endpoint

For example code snippets and implementation details, see the request chaining API page.

Request chaining errors

What happens if there’s an error making a request?

It depends on where the error occurred, for example:

  • If the error happened at the requested endpoint, such as while creating a brand, then request chaining will stop executing subsequent requests. It will return the error in the list of responses and all subsequent requests will be marked as not started.
  • If the error happened in the request chaining logic, such as accessing a previous response’s value, then it will return a validation error with a status code 400.