Developer Docs
  • 👋Get Started
  • Add Payment Methods in Optty
  • Custom API | Headless
    • 🖥️Direct API Integration
      • Environments
      • Order Flow
      • 1️⃣Create Access Token
      • 2️⃣Get APM Options
      • 3️⃣Create Order
      • 4️⃣Handle Payment Response
      • 5️⃣Refund Order
      • 🔥Handling Exceptions
  • Platforms
    • ◾BigCommerce
      • 🚀Activate Optty
      • ⚡Add Optty Widgets
        • 1️⃣Install the App
        • 2️⃣Create Widget Token
        • 3️⃣Edit Your Template
        • 4️⃣Widget Configuration
      • 💳Refunds
    • Magento 2
      • Install Optty Module
      • Configure the Optty Extension
      • One Step Checkout
    • Salesforce Commerce Cloud
      • Component Overview
      • Implementation Guide
      • Operation and Management
      • User Guide
    • 🟪WooCommerce
      • 🚀Install Optty
      • ⚡Setup Widgets
      • 💳Refunds
  • Widget
    • Widget Setup and Integration
    • Create Order Widget Integration
    • Handle Order Payment Widget Integration
  • API References
    • Create Order
      • Create Order Response
    • Refund Order
    • Void Order
    • Capture Order
    • Transaction Details
    • Create Customer Session
    • Best Practice
  • Go Live
  • Universal Payment Platform
    • Support Articles
Powered by GitBook
On this page
  • Resource URL
  • Path Parameters
  • Headers
  • Parameters
  • Request Parameters
  • Response Parameters
  • Sample Request/Response
  1. API References

Capture Order

This endpoint is for fully or partially capture an authorised order. (deferred payment request.)

Resource URL

POST http://api.qa.optty.com/orders/{orderReference}/capture

For live environment, please update the endpoint to https://api.optty.com

Path Parameters

Name
Type
Description

ORDER-ID*

string

The ORDER-ID provided in the original createOrder request is called 'orderReference' in createOrder.

Headers

Key
Value

Content-Type

application/json

Authorization

Bearer {GENERATED_ACCESS_TOKEN}

Parameters

Request Parameters

Field
Type
Description
Required

captureReference

string

The order capture reference, it needs to be unique per capture order request.

Yes

description

string

The description or reason for the capturing.

No

amount

numeric

amount to be captured

Yes

Response Parameters

Field
Type
Description

captureReference

string

The reference passed for the capturing request

captureId

string

The reference submitted upon requesting for capture.

capturedAmount

numeric

The amount processed for the capturing operation

Sample Request/Response

{
    "captureReference": "LatEHAuPtpN2HSrTMK-1",
    "description": "Please capture this order",
    "amount": 100
}
{
    "captureReference": "LatEHAuPtpN2HSrTMK-1",
    "capturedAmount": 100,
    "captureId": "LatEHAuPtpN2HSrTMK-1"
}

PreviousVoid OrderNextTransaction Details

Last updated 3 months ago