• Resolved patientzero

    (@patienzero)


    Hello,

    I got this error today when i tried to pay with my paypal button:

    INVALID_STRING_LENGTH The value of a field is either too short or too long.
    INVALID_PARAMETER_SYNTAX The value of a field does not conform to the expected format.

    this is my error log:

    2022-03-13T06:00:41+00:00 DEBUG POST https://api.paypal.com/v2/checkout/orders
    Request Body: {“intent”:”CAPTURE”,”purchase_units”:[{“reference_id”:”default”,”amount”:{“currency_code”:”USD”,”value”:”10.00″,”breakdown”:{“item_total”:{“currency_code”:”USD”,”value”:”10.00″},”shipping”:{“currency_code”:”USD”,”value”:”0.00″},”tax_total”:{“currency_code”:”USD”,”value”:”0.00″}}},”description”:””,”items”:[{“name”:”Satellite Product”,”unit_amount”:{“currency_code”:”USD”,”value”:”10.00″},”quantity”:1,”description”:””,”sku”:”SATELLP”,”category”:”PHYSICAL_GOODS”,”tax”:{“currency_code”:”USD”,”value”:”0.00″}}],”payee”:{“merchant_id”:”American Goods”},”shipping”:{“name”:{“full_name”:” “},”address”:{“country_code”:”EC”,”address_line_1″:”Gold Village 3013 north 123″,”admin_area_1″:”EC-I”,”admin_area_2″:”Lima”,”postal_code”:”090888″}}}],”application_context”:{“user_action”:”CONTINUE”,”shipping_preference”:”GET_FROM_FILE”,”landing_page”:”LOGIN”,”locale”:”en-US”,”brand_name”:”AGD”,”return_url”:”https:\/\/americangoods.com\/?wc-ajax=ppc-return-url”,”cancel_url”:”https:\/\/americangoods.com\/checkout\/”},”payer”:{“name”:{“given_name”:”Jhon”,”surname”:”Doe”},”email_address”:”jhondoe@gmail.com”,”address”:{“country_code”:”EC”,”address_line_1″:”Gold Village 3013 north 123″,”admin_area_1″:”EC-I”,”admin_area_2″:”Lima”,”postal_code”:”090888″},”phone”:{“phone_type”:”HOME”,”phone_number”:{“national_number”:”593987254321″}}},”payment_method”:{“payee_preferred”:”IMMEDIATE_PAYMENT_REQUIRED”,”payer_selected”:”PAYPAL”}}
    Response Debug ID: a9171915b641b
    Response: Array
    (
    [code] => 400
    [message] => Bad Request
    )

    Response Body: {"name":"INVALID_REQUEST","message":"Request is not well-formed, syntactically incorrect, or violates schema.","debug_id":"a9171915b641b","details":[{"field":"/purchase_units/@reference_id=='default'/payee/merchant_id","value":"American Goods","location":"body","issue":"INVALID_STRING_LENGTH","description":"The value of a field is either too short or too long."},{"field":"/purchase_units/@reference_id=='default'/payee/merchant_id","value":"American Goods","location":"body","issue":"INVALID_PARAMETER_SYNTAX","description":"The value of a field does not conform to the expected format."}],"links":[{"href":"https://developer.paypal.com/docs/api/orders/v2/#error-INVALID_PARAMETER_SYNTAX","rel":"information_link","encType":"application/json"},{"href":"https://developer.paypal.com/docs/api/orders/v2/#error-INVALID_STRING_LENGTH","rel":"information_link","encType":"application/json"}]}

    2022-03-13T06:00:41+00:00 WARNING Failed to create order. PayPal API response: [INVALID_REQUEST] Request is not well-formed, syntactically incorrect, or violates schema. https://developer.paypal.com/docs/api/orders/v2/#error-INVALID_PARAMETER_SYNTAX https://developer.paypal.com/docs/api/orders/v2/#error-INVALID_STRING_LENGTH
    2022-03-13T06:00:41+00:00 ERROR Order creation failed: [INVALID_REQUEST] Request is not well-formed, syntactically incorrect, or violates schema. https://developer.paypal.com/docs/api/orders/v2/#error-INVALID_PARAMETER_SYNTAX https://developer.paypal.com/docs/api/orders/v2/#error-INVALID_STRING_LENGTH
    2022-03-13T06:00:41+00:00 ERROR Order creation failed: [INVALID_REQUEST] Request is not well-formed, syntactically incorrect, or violates schema. https://developer.paypal.com/docs/api/orders/v2/#error-INVALID_PARAMETER_SYNTAX https://developer.paypal.com/docs/api/orders/v2/#error-INVALID_STRING_LENGTH

    Thanks for your help

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Syde Niklas

    (@niklasinpsyde)

    Hi @patienzero,

    The provided Merchant ID in the plugin settings is invalid. We recommend connecting your account with the onboarding wizard as described here as this will automatically insert the correct credentials for you:
    https://woocommerce.com/document/woocommerce-paypal-payments/#connect-paypal-account

    Otherwise, please refer to the section for manual credential input. There is little reason to manually connect the account though as the onboarding takes care of everything.
    If any questions remain, please don’t hesitate to let us know. Thanks!

    Kind regards,
    Niklas

    I cannot “onboard” as I don’t own the paypal account. I only have admin access. Paypal admin logins are a login name, not an email. “Onboarding” (which is an asinine term) requires an email.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Paypal plugin issue’ is closed to new replies.