From 5508bfebaf9725b2b2dceef12fd7902442bfe648 Mon Sep 17 00:00:00 2001 From: Jason Hord <51338560+pravus@users.noreply.github.com> Date: Tue, 17 Nov 2020 02:59:02 -0700 Subject: [PATCH] Adds EventCheckoutOrderApproved constant and Intent, PurchaseUnits, Payer fields to Resource type (#181) --- types.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/types.go b/types.go index ef46201..852f5d0 100644 --- a/types.go +++ b/types.go @@ -87,6 +87,7 @@ const ( // https://developer.paypal.com/docs/api/orders/v2/#definition-application_context const ( + EventCheckoutOrderApproved string = "CHECKOUT.ORDER.APPROVED" EventPaymentCaptureCompleted string = "PAYMENT.CAPTURE.COMPLETED" EventPaymentCaptureDenied string = "PAYMENT.CAPTURE.DENIED" EventPaymentCaptureRefunded string = "PAYMENT.CAPTURE.REFUNDED" @@ -1062,6 +1063,10 @@ type ( // merchant-onboarding Resource type PartnerClientID string `json:"partner_client_id,omitempty"` MerchantID string `json:"merchant_id,omitempty"` + // Checkout Resource type + Intent string `json:"intent,omitempty"` + PurchaseUnits []*PurchaseUnitRequest `json:"purchase_units,omitempty"` + Payer *PayerWithNameAndPhone `json:"payer,omitempty"` // Common Links []Link `json:"links,omitempty"` }