Provides integration into Magento 2 via the v2 REST API documented at https://devdocs.magento.com/guides/v2.3/get-started/bk-get-started-api.html.
126.96.36.199 Initial Release
188.8.131.52 Added support for OpenAPI. Magento 2 rest definitions are now processed by OpenAPI. Made some changes among the property names to give all REST related nodes some form of familiarity.
Type: String Input
Populated by a GUID relevant to the selected Sample.
Type: Multiline Text Input
The Request JSON payload, used for POST, PUT, and PATCH operations.
Type: Multiline Text Output
The Response JSON payload, contains the response received from Magento 2.
Type: String Input Output
The Response code that was received from the server such as 200 (success). Can be used to further validate calls.
Type: String Input Output
The short description of the selected sample, usually detailing what kind of transaction that specific API call will perform. E.g. "Get a list of all stores"
Type: Text Input
Custom inputs are automatically created for the node when a sample containing url parameters has been selected. Url parameters that are part of the API call are required, while query type parameters can be removed or added based on individual need.
Example; the custom input "id" from the customerGroupRepositoryV1SavePut api call is required, while the custom input "searchCriteria[pageSize]" from quoteCartRepositoryV1GetListGet is not required.
Setting up a Connection
This Node makes use of token-based authentication as described by Magento Token Based Authentication.
To set up a Connection, follow these steps:
- Capture the domain for the website as HTTPS into the MagentoBaseUrl property.
- Log in to Magento Admin and click System > Integrations to display the Integrations page.
- Click Add New Integration to display the New Integration page.
- Enter a unique name for the integration in the Name field. Then enter your admin password in the Your Password field. Leave all other fields blank.
- Click the API tab. Select the Magento resources the integration can access. You can select all resources, or select a custom list.
- Click Save to save your changes and return to the Integrations page.
- Click the Activate link in the grid that corresponds to the newly-created integration.
- Click Allow .
- Copy the value in Access Token and paste it into the AccessToken property in the Flowgear Connection.
Using Search Criteria
When selecting samples that support query string parameters, your node will be populated with custom properties that look like this "searchCriteria[filterGroups][filters][field]". You can use these properties by filling in values such as the ones specified below.
An example of using search criteria for pulling a list of orders. If we wanted to find orders that belong to a certain customer and we know the customer e-mail address, we will use the following custom properties and their respective values.
searchCriteria[filterGroups][filters][field] = customer_email
searchCriteria[filterGroups][filters][value] = firstname.lastname@example.org
searchCriteria[filterGroups][filters][conditionType] = eq
This will return orders that have a customer e-mail of email@example.com
For a comprehensive guide on using Search Criteria, please see the Documentation.
Access Node Samples to see a list of available calls.
See https://flowgear.me/#s/gSgr1oW for an example.