Troubleshooting Coupons (for Magento 1x)


Error Message: “Unable to connect to the REST API with the specified REST credentials. Please check that these credentials are valid in your Magento admin."

If you are seeing this error message in Klaviyo, there are two likely root causes:

  1. Your Magento server is not set up to support HMAC-SHA1 signatures for OAuth authentication.
  2. You may have not enabled full role access for the REST API.

To resolve this issue, enable HMAC-SHA1 signatures for OAuth authentication on your Magento server. Then complete the following steps to update your REST permissions:

Please try the following troubleshooting steps:

1. Uncomment, or add, the rewrite rule in your .htaccess file. This is the line you’ll want to ensure is un-commented:

RewriteRule ^api/rest api.php?type=rest [QSA,L]

2. Enable full role access for the REST API.

  • Set up permissions for REST resource operations from Magento Admin Panel
    • Navigate to System -> Web Services -> REST Roles
    • Create new Admin role -- in the field “Role name” enter for example “Administrator”
    • Click on “Role API resources” tab on the left -- “Role Resources” screen is shown, choose "All" and Save Role
  • Configure ACL Attributes Rules and access permissions
    • Navigate to System-> Web Services -> REST attributes
    • Click on “Admin”
    • Under “User type resources” screen, for Resource Access select “All“
    • Save
  • Assign configured Admin REST Role to existing admin user
    • Navigate to System-> Permissions-> Users
    • Click on some admin user from list in order to open “Edit user” screen
    • There is a tab named “REST role” on the left -- click on it and a list of Admin type roles is shown on the screen
    • Click on “Assigned” radio box near the new Admin role you created and Save User

3. Another common cause is that Various Apache modules can strip “Authorization: Basic base64 (user:passwd)” header.

Coupon codes populated into emails by Klaviyo are not unique -- all recipients appear to be receiving the same code.

When creating a Price Rule in Magento, the option to associate a new Price Rule with a specific coupon should be left set to Specific Coupon and you must have the “Use Auto Generation” checkbox selected.

Click on your Price Rule in Magento, and under General Information, scroll down to the line option "Coupon" and change this setting to "Specific Coupon". Next, check the box for auto generation here. This should fix the issue and allow us to generate a new unique coupon code for each email recipient.

Was this article helpful?
0 out of 1 found this helpful