UNPKG

@hyperse/paypal-node-sdk

Version:

NodeJS SDK for PayPal Checkout APIs

31 lines (30 loc) 1.38 kB
import { HttpRequestBase } from '../core/HttpRequestBase.js'; import { type BasePaymentHeaders, type Money, type PaymentInstruction } from '../types/type-payment.js'; type AuthorizationsCaptureRequestBody = { amount: Money; final_capture: boolean; invoice_id: string; note_to_payer: string; payment_instruction?: PaymentInstruction; soft_descriptor: string; }; interface AuthorizationsCaptureRequestHeaders extends BasePaymentHeaders { 'PayPal-Request-Id'?: string; Prefer?: string; } /** * Captures an authorized payment, by ID. * @see {@link https://developer.paypal.com/api/payments/v2/#authorizations_capture} */ export declare class AuthorizationsCaptureRequest extends HttpRequestBase<AuthorizationsCaptureRequestHeaders, AuthorizationsCaptureRequestBody> { constructor(authorizationId: any); payPalRequestId(payPalRequestId: string): this; /** * 1. return=minimal. The server returns a minimal response to optimize communication between the API caller and the server. A minimal response includes the id, status and HATEOAS links. * 2. return=representation. The server returns a complete resource representation, including the current state of the resource. * @default `return=minimal` */ prefer(prefer: string): this; requestBody(capture: AuthorizationsCaptureRequestBody): this; } export {};