Sign Up

Log In


By japerk
Updated 2 months ago
Popularity Score
Success Rate
joannafinkelstein3 years ago
Bought Subscription But Still Have Daily LimitMashape Support sent me to you. I bought the mega subscription to the NLTK API, but it still has the daily limit of 5,000 for me. I have a python script on my desktop that makes curl requests to the API. After I make 5,000 requests (successfully), it stops giving replies (labels) to my requests. It says Throttled. Can you fix this?
japerk3 years ago
Yes, the X-Mashape-Key should be the same as what's show in the code examples. What you should do is wrap each call in a try-except block. Here's a tutorial: If the call fails, you could maybe try it again using something like this: When you're doing lots API calls, things can sometimes fail for random reasons, so it's a good idea to try to handle those using a retry strategy. You can tell when a request succeeds if the response.code is 200.
joannafinkelstein3 years ago
How do I know what my "X-Mashape-Key" is? Is it the same as in the code example for Python? Is there some way to check that the request received a response properly so that it doesn't crash if for some reason one request doesn't work? Also, after making some number (between 1 and 1000) successful requests, I got an error that I don't understand. This is what Terminal says: Traceback (most recent call last): File "", line 157, in <module> "text": comment File "/Library/Python/2.7/site-packages/unirest/", line 144, in post return __dorequest("POST", url, get_parameters(kwargs), kwargs.get(HEADERS_KEY, {}), kwargs.get(AUTH_KEY, None), kwargs.get(CALLBACK_KEY, None)) File "/Library/Python/2.7/site-packages/unirest/", line 174, in __dorequest return __request(method, url, params, headers, auth) File "/Library/Python/2.7/site-packages/unirest/", line 97, in __request response = urllib2.urlopen(req, timeout=_timeout) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 154, in urlopen return, data, timeout) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 431, in open response = self._open(req, data) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 449, in _open '_open', req) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 409, in _call_chain result = func(*args) File "/Library/Python/2.7/site-packages/poster/", line 170, in https_open return self.do_open(StreamingHTTPSConnection, req) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 1197, in do_open raise URLError(err) urllib2.URLError: <urlopen error ('_ssl.c:574: The handshake operation timed out',)>
japerk3 years ago
Take a look at the docs at On the right side, there are client examples, and you can select Python to see code examples using the Unirest client. More details & how to install Unirest python:
joannafinkelstein3 years ago
Yes, I'm still using API for how do I go through the Mashape API, using their client library to make requests?
japerk3 years ago
Are you making the requests thru the Mashape API, or are you still using API for You need to go thru the Mashape API, using their client library to make requests, in order to get past the normal limits.
Hi Developer, feel free to post your answer:
Log inSign up

Install SDK for NodeJS


To utilize unirest for node.js install the the npm module:

$ npm install unirest

After installing the npm package you can now start simplifying requests like so:

var unirest = require('unirest');

Creating Request"")
.header("X-RapidAPI-Host", "undefined")
.header("X-RapidAPI-Key", "undefined")
.header("Content-Type", "application/x-www-form-urlencoded")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication

Sign up for free

to test this endpoint

Join the world’s largest API marketplace with over half a million developers and thousands of APIs.
Testfrom the browser
Connectusing code snippets
Managefrom one dashboard