0

When I run requests series like

https://api.sparkpost.com:443/api/v1/suppression-list/he**0@gmail.com

Sometimes, I get error:

name: 'SparkPostError', errors: [ { message: 'Too many requests' } ], statusCode: 429

Too many - this is how many? How long the server keeps track of period? How long the server resets the counter? How to solve this problem?

4

3 回答 3

0

支持的答案

如前所述,我们会限制端点上的请求以防止滥用,虽然我们无法透露实际限制,但我们建议您在发出连续请求之前等待几秒钟。如果您通过某种类型的自动化过程(脚本、代码等)发出这些请求,我们强烈建议您在看到此 429 错误后添加等待几秒钟,然后重新尝试。减少请求的频率并在重新尝试之前等待是解决此错误消息的唯一方法。

于 2016-09-29T04:47:18.743 回答
0

https://developers.sparkpost.com/api/index.html#header-rate-limiting

快速浏览网站后...

于 2016-09-28T13:46:11.073 回答
0

https://developers.sparkpost.com/api/index.html#header-rate-limiting

速率限制注意:为了防止滥用,我们的服务器强制执行请求速率限制,这可能会触发带有 HTTP 状态代码 429 的响应。SparkPost 在以下 API 端点上实现速率限制:

/api/v1/message-events

/api/v1/metrics/*

此处施加的限制是动态的,但作为一般规则,在 2 分钟内多次轮询这些端点可能会遇到速率限制和 429 状态代码。

于 2017-12-29T17:21:24.463 回答