Skip to content

PayPalCaptureMintingDistributionOrder

Walter Lara edited this page Aug 6, 2025 · 1 revision

PayPal - Capture Minting & Distribution Order

Allows to capture a PayPal order for minting and drisribution of a song.

Request

URL: v1/paypal/minting-distribution/orders/{orderId}/capture

Method: POST

Path Parameters:

Parameter Type Description
orderId string PayPal Order ID.

Query Parameters: None

Headers:

Authorization: Bearer {accessToken}

Content-Type: application/json

Content: None

✅ Success Response

Code: 200 OK

Headers: None

Content: None

❌ Error Responses

1. Unauthorized

Code: 401 UNAUTHORIZED

Condition: If {accessToken} is invalid or expired.

2. Not Found

Code: 404 NOT FOUND

Condition: If the underlying Song (by songId) is not found.

Headers:

Content-Type: application/json

Content example:

{
    "code": 404,
    "description": "Not Found",
    "cause": "Entity SonglistEntity, id=d0907e3d-a9a7-43b1-93dc-f3b0ee929021 not found in the database"
}

3. Unprocessable Entity

Code: 422 UNPROCESSABLE ENTITY

Condition: If the PayPal backend fails to capture the underying order or produces an unexpected response.

Headers:

Content-Type: application/json

Content example:

{
    "code": 422,
    "description": "Unprocessable Entity",
    "cause": "Unexpected capture amount - expected 16.44 USD, received: 8.45 USD"
}

See Also

PayPal - Create Minting & Distribution Order

Clone this wiki locally