mozillabrasil / sumo_live_helper

Helper Add-on for SUMO forum contributors
https://addons.mozilla.org/firefox/addon/sumo-live-helper-/
Mozilla Public License 2.0
7 stars 8 forks source link

Sometimes 429 (too many requests) #205

Open jhonatasrm opened 2 months ago

jhonatasrm commented 2 months ago

Description

429 - too many requests

Steps to Reproduce

  1. In about:debugging#/runtime/this-firefox add the SUMO Live Helper on Load Temporary Add-on...
  2. Open Inspect
  3. See the console behavior when selecting locales and products

Expected behavior:

Optimize API requests by refraining from calling the API each time a product is selected, which results in multiple API calls. Instead, utilize a single call to retrieve product information. For example:

https://support.mozilla.org/api/2/question/?format=json&ordering=-id&is_solved=false&is_spam=false&is_locked=false&products=ios,firefox,thunderbird&is_taken=false&is_archived=false&locale=pt-BR&num_answers=0

image

Actual behavior:

The API is being called repeatedly for each selected product/locale.

image

System information

Additional Information

Documentation to reference: https://mozilla.github.io/kitsune/api/#optional-arguments