Skip to content
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

docs(specs): Review OpenAPI Analytics (search analytics) #1689

Merged
merged 21 commits into from
Jul 17, 2023

Conversation

gazconroy
Copy link
Contributor

@gazconroy gazconroy commented Jul 4, 2023

This is one of several PRs addressing the Analytics API.

This PR reviews just the search operations of the Analytics API.

🧭 What and Why

Questions and notes

In the docs, there are 15 API calls. In the OAS, just 12. Should the missing calls be added to the OAS?

getTopSearches

  • In the response, count is always (much) smaller than nbHits (whatever the setting of clickAnalytics). This doesn’t seem intuitive. What’s the difference between count and nbHits?
  • Response has a clickPositions object which isn’t defined in the OAS

getSearchesCountResponse

  • Response has a withFilterCount field in the searches object which isn’t defined in the OAS

getNoResultsRate

  • In the response, what is noResultCount? I’ve put in the placeholder “Number of occurrences” but that's not very helpful
  • In the response, noClickCount is defined as “Number of click events.” This doesn’t seem to be correct in this context
    getTopHits

getTopHits

  • I’ve changed the description to “Returns the most popular clicked results in the latest 1,000 searches.” Is this accurate?

getTopFilterAttributes/getTopFilterForAttribute/getTopFiltersNoResults

  • Does this apply to the “1,000 most used filters” (for all time?) or the “1,000 most recently used filters”. I’m assuming the latter but the former is the original wording

getTopFilterForAttribute

  • In the response API calls I made, operator is returned as :. What does that indicate? What are the potential settings for operator?

getTopFiltersNoResults

  • I’ve written “Returns top filters for filter-enabled searches that don’t return results.” Is that correct, though?
  • If I don't specify search in the call, I’d either expect a large number of returned values (for all “no result” searches) or an error message saying search is necessary. Instead, I get {"values": null}

getTopCountries

  • What does this do? Is this related to geo searching? To cluster location? To user IP address country correlation?
  • The description says “Returns top countries. Limited to the 1,000 most frequent ones.” Most frequent country?
  • Are there any prerequisites for this to work? When I make a call, I get {"values": null}

🎟 JIRA Ticket: DOC-1112

Changes included:

Changes to summary, description and examples

🧪 Test

@gazconroy gazconroy requested a review from a team as a code owner July 4, 2023 13:13
@gazconroy gazconroy requested review from damcou and mehmetaligok July 4, 2023 13:13
@netlify
Copy link

netlify bot commented Jul 4, 2023

Deploy Preview for api-clients-automation ready!

Name Link
🔨 Latest commit f41adb3
🔍 Latest deploy log https://app.netlify.com/sites/api-clients-automation/deploys/64b5242fd4db590008eb8ba9
😎 Deploy Preview https://deploy-preview-1689--api-clients-automation.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@gazconroy gazconroy marked this pull request as draft July 4, 2023 13:13
@algolia-bot
Copy link
Collaborator

algolia-bot commented Jul 4, 2023

✗ The generated branch has been deleted.

If the PR has been merged, you can check the generated code on the main branch.
You can still access the code generated on main via this commit.

@gazconroy gazconroy changed the base branch from main to fix/review-common-specs July 5, 2023 16:06
@gazconroy gazconroy changed the title docs(specs): Review OpenAPI Analytics docs(specs): Review OpenAPI Analytics (search analytics) Jul 6, 2023
@gazconroy gazconroy marked this pull request as ready for review July 10, 2023 13:38
@gazconroy gazconroy requested a review from kai687 July 10, 2023 13:56
gazconroy and others added 7 commits July 11, 2023 14:52
Co-authored-by: Kai Welke <kai.welke@algolia.com>
Co-authored-by: Kai Welke <kai.welke@algolia.com>
Co-authored-by: Kai Welke <kai.welke@algolia.com>
Co-authored-by: Kai Welke <kai.welke@algolia.com>
Copy link
Contributor

@kai687 kai687 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good for final review by API clients team

Copy link
Member

@shortcuts shortcuts left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awesome!

@shortcuts shortcuts merged commit 7414180 into fix/review-common-specs Jul 17, 2023
@shortcuts shortcuts deleted the fix/openapi-review-analytics branch July 17, 2023 11:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants