We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The major issue is ShippingAddress is not reference type; PayerID is not omitempty.
Subscriber struct { PayerID string json:"payer_id,**omitempty**" ShippingAddress *ShippingDetail json:"shipping_address,omitempty" Name CreateOrderPayerName json:"name,omitempty" EmailAddress string json:"email_address,omitempty" }
json:"payer_id,**omitempty**"
json:"shipping_address,omitempty"
json:"name,omitempty"
json:"email_address,omitempty"
If not fixed as above indicated, always send shipping_address: {}, payerid:'' to paypal, then rejected with invalid address.
shipping_address: {}, payerid:''
Sample payload without above fix,
{"plan_id":"P-9A585647VE5076042M4X5HUI","start_time":"2024-12-03T06:25:00Z","subscriber":{"payer_id":"","shipping_address":{},"name":{"given_name":"John","surname":"Doe"},"email_address":"[email protected]"},"application_context":{"brand_name":"Example Store","locale":"en-US","shipping_preference":"NO_SHIPPING","user_action":"SUBSCRIBE_NOW","payment_method":{"payee_preferred":"IMMEDIATE_PAYMENT_REQUIRED","standard_entry_class_code":"WEB"},"return_url":"https://example.com/return","cancel_url":"https://example.com/cancel"}}
Could you fix this issue?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The major issue is ShippingAddress is not reference type; PayerID is not omitempty.
Subscriber struct {
PayerID string
json:"payer_id,**omitempty**"
ShippingAddress *ShippingDetail
json:"shipping_address,omitempty"
Name CreateOrderPayerName
json:"name,omitempty"
EmailAddress string
json:"email_address,omitempty"
}
If not fixed as above indicated, always send
shipping_address: {}, payerid:''
to paypal, then rejected with invalid address.Sample payload without above fix,
{"plan_id":"P-9A585647VE5076042M4X5HUI","start_time":"2024-12-03T06:25:00Z","subscriber":{"payer_id":"","shipping_address":{},"name":{"given_name":"John","surname":"Doe"},"email_address":"[email protected]"},"application_context":{"brand_name":"Example Store","locale":"en-US","shipping_preference":"NO_SHIPPING","user_action":"SUBSCRIBE_NOW","payment_method":{"payee_preferred":"IMMEDIATE_PAYMENT_REQUIRED","standard_entry_class_code":"WEB"},"return_url":"https://example.com/return","cancel_url":"https://example.com/cancel"}}
Could you fix this issue?
The text was updated successfully, but these errors were encountered: