Magento is an open-source eCommerce platform with features like order management, business intelligence, and shipping.
Magento 2 documentation: API guide, Authentication
- A. Set up a Magento 2 connection
- B. Provide required Magento 2 application details
- C. Edit advanced Magento 2 settings
- D. Test the connection
A. Set up a Magento 2 connection
Start establishing a connection to Magento 2 in either of the following ways:
- From the Resources menu, select Connections. Then, click + Create connection at the top right.
– or –
- While working in a new or existing integration, you can add an application to a flow simply by clicking Add source or Add destination/lookup.
In the resulting Application list, select Magento 2.
The Create connection panel opens with required and advanced settings.
B. Provide required Magento 2 application details
At this point, you’re presented with options for providing Magento 2 authentication.
Name (required): Provide a clear and distinguishable name. Throughout integrator.io imports and exports, you will have the option to choose this new connection, and a unique identifier will prove helpful later when selecting among a list of connections that you’ve created.
Application (required, non-editable): A reminder of the app you’re editing.
Mode (required): Select one of the following options:
- Cloud to connect to a publicly accessible server application
- On-premise to connect to a server that is publicly inaccessible and has integrator.io agent installed on it
Agent (required, if On-premise selected for Mode; otherwise not displayed): Select an agent from the list. To connect to an on-premise application, integrator.io requires that an agent be installed on a networked computer. An agent is a small application that allows you to connect to data behind your firewall. When installing an agent, you will specify a unique access token, which then populates the Agent drop-down list. The installed agents connect to integrator.io and establish a reverse SSH tunnel, allowing secure communication without the need to whitelist integrator.io IP addresses in your firewall settings. A single agent can be used by multiple different connections.
Base URI (required): Enter the base URI of your Magento 2 account. You can locate this URL in the address bar after you sign in to your Magento 2 account. For example, if your account is located at
http://18.104.22.168/xyz/admin, then replace
rest and enter the base URI as
Username (required): Enter the username of your Magento 2 account.
Password (required): Enter the password of your Magento 2 account. Multiple layers of protection, including AES 256 encryption, are in place to keep your password safe. When editing this connection, you must re-enter this value each time; it is stored only when the connection is saved and never displayed as text.
Generate token (required): Click Generate token to have integrator.io fill in an encrypted access token or enter the token generated for you by Magento 2. Multiple layers of protection are in place, including AES 256 encryption, to keep your connection’s token safe. When editing this form later, you must generate this value again; it is stored only when the connection is saved and never displayed as text.
- Errors while retrieving the token are often attributed to an incorrect base URI being used or your incorrect credentials. It's best to enter them in by hand and ensure that the browser autofill function doesn't override your activity.
- For Magento accounts updated to 2.4.4 and above versions, the integration tokens can no longer be used for API bearer token authentication. To revert to the previous behavior, you should either disable two-factor authentication or run the bin/magento config:set oauth/consumer/enable_integration_as_bearer 1 command to restrict the new behavior. For more information, see Token-based authentication.
- For Magento accounts using two-factor authentication, you have to enter the token in the Token field.
- For Magento accounts using two-factor authentication, when you upgrade to a higher version, integrator.io doesn't get the connection up and running. This is because Magento is expecting a new token for a successful connection with integrator.io. To resolve this, create a token outside of integrator.io, enter the token when logging into Magento, and then enter the same token in the Token field. For more information on how to generate a token, see Token-based authentication.
C. Edit advanced Magento 2 settings
Before continuing, you have the opportunity to provide additional configuration information, if needed, for the Magento 2 connection.
D. Test the connection
Once you have configured the Magento 2 connection, you have a few options for continuing:
- Save – click this button to test the connection, commit the new connection so that it will be available to all integrations for your account
- Save & close – click to test and save the connection and exit the Create connection panel
- Close – click to exit without saving any new changes
- Test connection – click this button to verify that your new connection is free of errors
When you test or save the connection, it is verified before continuing.
The new connection is now successfully added to your account. It will be applied to the current source or destination app if you created it within a flow. Otherwise, you may proceed to register the connection with an integration.
Generate token is not working
I am confused about the generate token step. What should I do if I do not use 2FA on Magento.
In integrator.io it says
"Click the Generate token button to have integrator.io fill in an encrypted access token or enter the token generated for you by Magento 2."
I am under the impression that if I dont use 2FA the generate token would generate one it self. But when I click it, the token entry shows an error, requesting a value to be entered then it just says generating... but nothing is generated and after clicking generate a couple of time, you start getting this error
So its either I must have 2FA or the generate token does not work.
Another issues is I can type in random/incorrect login credential, random/incorrect token value and still get a successful connection message, this is counterintuitive and brings into question, is proper verification being done?
Please sign in to leave a comment.