我已将 Alchemy API 服务添加到我的 Bluemix 仪表板,并且可以使用凭证来调用 API。我已将服务配置为使用“生态系统”计划。
我的应用程序在前几次调用中调用了新闻 API,然后我得到了API transaction limit exceeded. 生态系统计划的调用是否有限制?
谢谢布伦丹
我已将 Alchemy API 服务添加到我的 Bluemix 仪表板,并且可以使用凭证来调用 API。我已将服务配置为使用“生态系统”计划。
我的应用程序在前几次调用中调用了新闻 API,然后我得到了API transaction limit exceeded. 生态系统计划的调用是否有限制?
谢谢布伦丹
Alchemy API 很棘手。您可能每天要完成 1000 个事件。
首先,您需要了解事件的计数方式。
这是一个例子:
To calculate how many transaction credits a query will cost, multiply historical access and targeting.
Historical Access - each hour of historical access costs 1 transaction credit
Targeting - each query parameter costs 1 transaction credit
Example: Give me news about the company "IBM" from the past 3 days.
Historical access: 3 days = 72 transaction credits
Targeting: 1 query parameter = 1 transaction credit
Query cost: 72 transaction credits
有关更多说明,请参见https://www.alchemyapi.com/alchemydata-news-sales
其次,您需要检查您已经使用了多少积分。为此使用此 API
http://access.alchemyapi.com/calls/info/GetAPIKeyInfo?apikey=YOUR_API_KEY
最后,缓存您从 AlchemyAPI 检索到的所有内容(bluemix 有几个选项)
目前可用于 AlchemyAPI 服务的两个计划是免费和标准。免费计划包括每个 Bluemix 组织每天 1,000 个事件。您一次只能拥有一个 AlchemyAPI 服务实例和一个免费计划中的 AlchemyAPI 凭证。如果您需要创建额外的实例或凭证,则需要升级到标准计划。