At this point you may have created your on module or used a public one. It’s time to see how to integrate it through MonkeyLearn web API. 

If you are an experienced web developer, you may have done web API integrations before, also you may have seen some of the code snippets at

Getting your API token

The first step will be to look at your API token, you can get your token at your My account details:

If you click the API Keys tab, you’ll see the token that you must use to authenticate with the web API every time you make a request:

The following sections show ways to integrate MonkeyLearn API with some of the most popular programming languages (Python, Ruby, Java, PHP, Javascript and .Net). Of course, there are other options that you can also use.


The simplest way to check an API is through curl command, the following shows how to perform a simple text classification with curl:

curl --data '{"text_list": ["lions are very big animals", "i want to buy an iphone"]}' \
-H "Authorization:Token <YOUR TOKEN GOES HERE>" \
-H "Content-Type: application/json" \
-D - \<MODULE ID GOES HERE>/classify/

You have to change the place holder <YOUR TOKEN GOES HERE> to your particular token obtained from your account details, and the place holder <MODULE ID GOES HERE> set the id of the corresponding module. The id of the module can be obtained from the URL when you open a module in the GUI or from the API tab.

The text_list parameter is used to set the texts you want to classify.

Official API clients:

Unofficial API clients:

Did this answer your question?