Table of contents

Delayed capture

GOV.UK Pay supports the delayed capture of payments.

To use this feature, include "delayed_capture": true in the body of a create new payment request (link opens in new window).

The user experience matches the current payment flow. Once the user selects Confirm on the Confirm your details page, your service can call the POST /v1/payments/{paymentId}/capture endpoint to send a delayed capture request.

There are 4 possible responses:

 
Response Code Meaning
204 Capture request accepted
404 paymentId does not exist
409 Capture request rejected
500 Downstream error
 

Your service must send the delayed capture request within 48 hours of the payment creation, regardless of how long the user takes to complete the payment flow. Otherwise, it will expire.

If your service has enabled payment receipt emails, GOV.UK Pay will send a payment receipt email to the user once your service’s capture request is received and accepted.

See the capture URL for a payment

If a payment is available for capture, you can see its capture URL in GOV.UK Pay API responses such as:

  • GET /v1/payments/<PAYMENT-ID>
  • GET /v1/payments

The "__links" object will contain:`

"capture": {
"href": "https://publicapi.payments.service.gov.uk/v1/payments/<PAYMENT-ID>/capture",
    "method": "POST"
    }

If the payment is not available for capture, the "__links" object will contain:

"capture": null