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 monkeylearn.com

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:

_images/my_account_button.png

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:

_images/api_token.png

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.

Curl

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

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.

Integrating Modules tokens example

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

Official API clients:

Unofficial API clients:

If you want to use some other language, you can use http requests as with any other api. See the API Reference.