Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Added new diagram

...

The diagram below illustrates the structure of this middle tier application and how to use an external store application to consume the WSO2 REST APIs. The middle tier application also known as the backend application will be responsible for handling the operations shown inside the red box. 

Image RemovedImage Added

Expand
titleExpand to see the description of the numbered steps in the diagram.
  1. External user interaction with the API Store(front end application).
  2. The front end application sends the request to the middle tier application.
  3. The middle tier application send a request to the WSO2 token generation service, to generate/regenerate the access token.
  4. The WSO2 token generation service sends back the access token to the middle tier application.
  5. The middle tier application calls the WSO2 Admin REST APIs in the backend.
  6. WSO2 REST APIs return the response to the middle tier application. This is transferred to the API Store.
  7. The middle tier application transfers the response to the API Store.
  8. The API Store displays the response to the end user.

The following are the three middle tier application functionalities handled by the middle tier(backend) application. Make sure that all these functions are implemented when you write your backend application.

  1. Invoking Admin REST APIs
    Image Removed
    Image Added
    (a) Password Grant
    (b) Refresh Token Grant 
  2. Logging in and storing subscriber access tokens
    Image RemovedImage Added
  3. Invoking Store REST APIs
    Image RemovedImage Added



Info

To secure the connection between the front end application and the middle tier application, enable CORS for the backend application. When enabling CORS you need to make sure to only allow the host of your front end application so that users accessing from other hosts are unable to attack your system.