Things you can do with WSO2 API Manager


You might never heard about WSO2 API manager before. Well, it’s a tool which can be used to manage your APIs. You can learn everything that you need to know from the documentation provided by WSO2. 

Before talking about the things that they have not mentioned it would be better to have a clear understanding about how API works. Since there are a lot of resources I’m not going to explain that. Please refer following links to find more details.

Now let’s talk about what else you can do using WSO2 API manager other than the mentioned features.

Overview of the technology

WSO2 Api manager is implemented using swagger. (Swagger is a simple yet powerful representation of your RESTful API). To use the API manager you don’t need any knowledge on swagger but you can do a lot more things if you have a better understanding about swagger.

You need to provide the swagger specification to represent your API using swagger. Swagger specification can be coded using YAML or JSON.

  • YAML –
    • YAML stands for YAML Ain’t Markup Language and is a human friendly data serialization standard for all programming languages.
  • JSON –
    • JSON stands for JavaScript Object Notation and is a lightweight data interchange format.

Please take some time to read and learn more about YAML and JSON.

What else can you do using API manager?

You can simply create your server side code or the client side code for your API using the swagger specification. (API manager only manages your APIs but using swagger you can do a lot more things that have not mentioned there)
After creating the API you can find the swagger specification there.

Screenshot from 2015-12-18 14:29:46

From here you can get the swagger API specification for your API.

Screenshot from 2015-12-18 14:31:52

Swagger provides an open source tool called swagger codegen. This tool generates server side codes and client side codes for many programming languages such as java,python,php and etc. 

There are two options that you can do to generate codes.

  1. Swagger online editor –
    • You can simply import your json file, which you got from API manager and create the server code or the client code.
  2. Swagger codegen from github –
    • You can manually download codegen and generate codes.( Instructions can be found in the above github repo)

Generating codes is not a requirement of API manager, so the json that you got from the API manager doesn’t contain the swagger specification that is required to generate all the classes in the code. So you need to add those specifications before generating.

This is all that you need to know in order to generate client side and server side codes for APIs.So happy Code Generating 🙂

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.