square-payments
Use when working with Square Payments, Orders, Checkout, Invoices, Subscriptions, or Refunds. Also use when implementing payment flows, creating checkout links, managing recurring billing, or handling refunds with the Square API.
| Model | Source |
|---|---|
| sonnet | pack: payments |
Overview
Section titled “Overview”Square API (version 2026-01-22) for accepting payments, managing orders, and building checkout experiences. Uses source tokens from Square Web Payments SDK client-side; processes payments server-side via Payments API.
Full Reference
┏━ 🔧 square-payments ━━━━━━━━━━━━━━━━━━━━━━━━━━━┓ ┃ Use when working with Square Payments, Orders,… ┃ ┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛
Square Payments
Section titled “Square Payments”Overview
Section titled “Overview”Square API (version 2026-01-22) for accepting payments, managing orders, and building checkout experiences. Uses source tokens from Square Web Payments SDK client-side; processes payments server-side via Payments API.
Quick Reference
Section titled “Quick Reference”| Item | Value |
|---|---|
| Current API Version | 2026-01-22 |
| Base URL | https://connect.squareup.com/v2 |
| Auth | Bearer access token (EAAAl... for sandbox, EAAA... for prod) |
| Node.js | npm install square (v40+) |
| Python | pip install squareup (v42+) |
| Sandbox | https://connect.squareupsandbox.com/v2 |
Reference Index
Section titled “Reference Index”Load the specific file for the task at hand:
| I want to… | File |
|---|---|
reference/auth-and-setup.md | Token types, scopes, client init, idempotency |
reference/payments.md | Payment lifecycle, create, delayed capture, card-on-file, external |
reference/orders.md | Order lifecycle, create with line items/taxes/discounts, pay, search |
reference/checkout.md | Payment links, quick pay, checkout options |
reference/invoices.md | Invoice workflow, create + publish, payment request types, delivery methods |
reference/subscriptions.md | Subscription model, cadences, create, free trials, pause/cancel |
reference/refunds.md | Refund rules, partial and full refunds |
reference/error-handling.md | Error structure, common codes, handling patterns |
reference/testing.md | Sandbox setup, test nonces, test card numbers |
Usage: Read the reference file matching your current task from the index above. Each file is self-contained with code examples and inline gotchas.