-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Category API #6
Comments
@rviscomi, should we have any |
I'd say only the category name should be a required parameter, but I'll defer to @sarahfossheim if it'd be useful to have any special behavior when it's omitted. For example, maybe it could list only the category names. |
We do need to get the list of category names as well (for the category filter dropdown), so that'd be useful yes |
Example of how to consume this endpoint One category or Multiple categories
or for only category names
@rviscomi @sarahfossheim let me know if this is helpful in this way. |
Per our chat, change to (here and other APIs):
On the frontend we'll need to URL-encode each input param |
@rviscomi @sarahfossheim all the changes discussed are already deployed. New URL Documentation: https://github.com/HTTPArchive/tech-report-apis#get-categories |
Hi @rviscomi why does the query for categories contain WHERE ... client = 'mobile' ? are there no categories for desktop ? |
Every technology category that exists on desktop pages almost certainly exists on mobile, so this was a small query optimization to avoid processing half the dataset. |
For feature parity in v1 we'll also need an API to list all of the technologies for each category.
You can see how it works in the existing dashboard:
Enter a category name
The Technology dropdown updates to display only the technologies of the filtered category
The shape of the API should be an object where the keys are category names and the values are arrays of technologies sorted by popularity:
Here's an example query to extract the categories:
I've formatted the output and saved the results to a static file: https://github.com/HTTPArchive/tech-report-apis/blob/main/static/categories.json
Also available via the CDN: https://cdn.httparchive.org/reports/cwvtech/categories.json
cc @sarahfossheim
The text was updated successfully, but these errors were encountered: