AgreementService / Client / accept_agreement_payment_request

accept_agreement_payment_request

AgreementService.Client.accept_agreement_payment_request(**kwargs)

Allows buyers (acceptors) to accept a payment request that is in PENDING_APPROVAL status. Once accepted, the payment request transitions to APPROVED status and the charge will be processed. Buyers can optionally provide a purchase order reference for their internal tracking.

Note

Only payment requests in PENDING_APPROVAL status can be accepted. A ConflictException is thrown if the payment request is in any other status.

See also: AWS API Documentation

Request Syntax

response = client.accept_agreement_payment_request(
    paymentRequestId='string',
    agreementId='string',
    purchaseOrderReference='string'
)
Parameters:
  • paymentRequestId (string) –

    [REQUIRED]

    The unique identifier of the payment request to accept.

  • agreementId (string) –

    [REQUIRED]

    The unique identifier of the agreement associated with the payment request.

  • purchaseOrderReference (string) – An optional purchase order reference that buyers can provide to associate the payment request with their internal purchase order system.

Return type:

dict

Returns:

Response Syntax

{
    'paymentRequestId': 'string',
    'agreementId': 'string',
    'status': 'VALIDATING'|'VALIDATION_FAILED'|'PENDING_APPROVAL'|'APPROVED'|'REJECTED'|'CANCELLED',
    'name': 'string',
    'description': 'string',
    'chargeAmount': 'string',
    'currencyCode': 'string',
    'createdAt': datetime(2015, 1, 1),
    'updatedAt': datetime(2015, 1, 1)
}

Response Structure

  • (dict) –

    • paymentRequestId (string) –

      The unique identifier of the accepted payment request.

    • agreementId (string) –

      The unique identifier of the agreement associated with this payment request.

    • status (string) –

      The updated status of the payment request, which is APPROVED.

    • name (string) –

      The descriptive name of the payment request.

    • description (string) –

      The detailed description of the payment request, if provided.

    • chargeAmount (string) –

      The amount that was approved to be charged.

    • currencyCode (string) –

      The currency code for the charge amount.

    • createdAt (datetime) –

      The date and time when the payment request was originally created.

    • updatedAt (datetime) –

      The date and time when the payment request was accepted.

Exceptions

  • AgreementService.Client.exceptions.ValidationException

  • AgreementService.Client.exceptions.AccessDeniedException

  • AgreementService.Client.exceptions.ResourceNotFoundException

  • AgreementService.Client.exceptions.ThrottlingException

  • AgreementService.Client.exceptions.InternalServerException

  • AgreementService.Client.exceptions.ConflictException