We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6fb262a commit 64bfbc9Copy full SHA for 64bfbc9
authorization.go
@@ -71,7 +71,7 @@ func (c *Client) VoidAuthorization(ctx context.Context, authID string) (*Authori
71
// PayPal recommends reauthorizing payment after ~3 days
72
// Endpoint: POST /v2/payments/authorizations/ID/reauthorize
73
func (c *Client) ReauthorizeAuthorization(ctx context.Context, authID string, a *Amount) (*Authorization, error) {
74
- buf := bytes.NewBuffer([]byte(`{"amount":{"currency_code":"` + a.Currency + `","total":"` + a.Total + `"}}`))
+ buf := bytes.NewBuffer([]byte(`{"amount":{"currency_code":"` + a.Currency + `","value":"` + a.Total + `"}}`))
75
req, err := http.NewRequestWithContext(ctx, "POST", fmt.Sprintf("%s%s", c.APIBase, "/v2/payments/authorizations/"+authID+"/reauthorize"), buf)
76
auth := &Authorization{}
77
0 commit comments