Create a payment
Create a payment containing one or more line items using card details or a supported card token. Payments charge immediately with capture: "sale". Authorizing payments for later capture returns 501 CAPTURE_NOT_SUPPORTED. Charging stored cards returns 501 VAULT_NOT_SUPPORTED.
Use the Idempotency-Key header to prevent duplicate charges when retrying a request.
Authorizations
Send your API key as Authorization: ApiKey pc_<your-key>. The API also accepts the key without the ApiKey prefix. API keys authenticate requests to /api/partner/v1/*. Contact GroGov support to rotate your key or deactivate your API account. Rotation invalidates the previous key. Account deactivation blocks both API keys and access tokens.
Headers
Unique key to prevent duplicate charges on retry.
255Body
The ID of an agency's payment configuration in GroGov. The portal determines the payment gateway and service fee configuration. GroGov provides the portal IDs your API account can access.
"a1b2c3d4-e5f6-7890-abcd-ef1234567890"
Total amount in cents. Must equal sum of line item amounts.
10000
USD - Option 1
- Option 2
- Option 3
1 - 50 elementsYour identifier for the payment. This is separate from each line item's referenceId. GroGov also uses this payment-level value to check case-specific payment restrictions.
255"CASE-2024-00123"
sale charges immediately. auth (authorize now, capture later) is not supported and returns 501 CAPTURE_NOT_SUPPORTED. The response reports this as captureMode.
sale, auth Deprecated alias of capture, accepted for clients built against an earlier version of this spec. If both are sent they must match, or the request is rejected with 400 VALIDATION_ERROR.
sale, auth