43 posts
  • Has referred 1+ members
  • Has sold $100+ on Envato Market
  • Has collected 1+ items on Envato Market
  • Located in Germany
+2 more
hupe-graphics says

Hi, I have some questions regarding the use of the Envato API:

- What does the time to live (TTL) value exactly mean. Let’s say on API documentations there’s a TTL of 3600 does it mean the output refreshed every hour (3600 seconds), or 3600 time an hour, or what else?

- How many request can one server put on the API before the 1hour blocking starts. So If I work with caching, what do you think what is the best refresh setting to prevent blocking?

- are there any other alternatives of using the API by PHP-Script than the use of curl or file_get_contents

Thanks in advance Danica

272 posts
  • Has sold $10,000+ on Envato Market
  • Won a Most Wanted contest
  • Made it to the Authors' Hall of Fame
  • Has referred 10+ members
+5 more
GDragoN says

Hi,

1. Yes, TTL is time after the data is refreshed and it is in seconds. 2. No one knows (at least I never found any info on this). My recommendation is to use some sort of cache to avoid problems, and get optimal speed. Envato API is not fast you would like to to use it without cache. I built my own WordPress Envato API wrapper for my Smart Market Widgets plugin with cache use and auto TTL control for it. 3. It is best to use CURL in PHP.

Milan

2196 posts
  • Located in Europe
  • Made it to the Authors' Hall of Fame
  • Had an item featured on Envato Market
  • Participated in a focus group or interview to improve the user experience on Envato Market
+10 more
revaxarts says

I recently counted 90 requests with one API key before the key get locked for one hour

43 posts
  • Has referred 1+ members
  • Has sold $100+ on Envato Market
  • Has collected 1+ items on Envato Market
  • Located in Germany
+2 more
hupe-graphics says

Thank you both!

If anybody else (Staff?) has informations about the number of request (especial for open, non Key-request) ‘I would be glad to read them.

236 posts Marketplace Developer
  • Has collected 1+ items on Envato Market
  • Member of the Envato Team
  • Located in New Zealand
  • Has been part of the Envato Community for over 2 years
madlep Envato team says

- What does the time to live (TTL) value exactly mean. Let’s say on API documentations there’s a TTL of 3600 does it mean the output refreshed every hour (3600 seconds), or 3600 time an hour, or what else?

We cache the output of API calls rather than hitting the main database every time. If you make a request on an API with TTL of 3600, then it will return the same results for (up to) 3600 seconds (1 hour)


- How many request can one server put on the API before the 1hour blocking starts. So If I work with caching, what do you think what is the best refresh setting to prevent blocking?

100 requests per hour is the maximum per API key. Note that this is per hour of the day (i.e 3pm – 4pm) rather than a rolling window. That’s kind of a pitifully small limit, and we can certainly handle more. Hopefully we’ll be raising it in the future.

The public API has no rate limiting in place, so you can hit that as much as you want – within reason. If you make so many requests it sets off alerts on our servers, a grumpy on-call developer might still block your IP address. But you’d need to be making 10,000s of requests an hour to get to that level though.


- are there any other alternatives of using the API by PHP-Script than the use of curl or file_get_contents

It’s just RESTful JSON over HTTP, so you can use tool/library that understands that.

43 posts
  • Has referred 1+ members
  • Has sold $100+ on Envato Market
  • Has collected 1+ items on Envato Market
  • Located in Germany
+2 more
hupe-graphics says

Thank you!

Helpful Information

  • Please read our community guidelines. Self promotion and discussion of piracy is not allowed.
  • Open a support ticket if you would like specific help with your account, deposits or purchases.
  • Item Support by authors is optional and may vary. Please see the Support tab on each item page.

Most of all, enjoy your time here. Thank you for being a valued Envato community member.

Post Reply

Format your entry with some basic HTML. Read the Full Details, or here is a refresher:

<strong></strong> to make things bold
<em></em> to emphasize
<ul><li> or <ol><li> to make lists
<h3> or <h4> to make headings
<pre></pre> for code blocks
<code></code> for a few words of code
<a></a> for links
<img> to paste in an image (it'll need to be hosted somewhere else though)
<blockquote></blockquote> to quote somebody

:grin: :shocked: :cry: Complete List of Smiley Codes

by
by
by
by
by
by