Description
Replaces: #58
Currently, we have no analytics about integrations.
As a first step, we would like to know the proportion of each integration.
Thanks to the new spec implementation, the User-Agent
header will be sent to Segment (and then to Amplitude) via the MeiliSearch server 🎉
Here is the expected format:
User-Agent: Meilisearch <language> (<version>)
-> The version should be in parenthesis and the information must start with Meilisearch
Ex:
User-Agent: Meilisearch JS (v0.22.1)
If multiple integrations are used during the user path, they should be separated by ;
.
User-Agent: Meilisearch Rails (v0.2.3) ; Meilisearch Ruby (v0.16.0)
-> In this example, it means the Ruby SDK should be able to accept a custom User-Agent
that the Rails plugin can pass when initializing the Ruby client.
First step: do it basically in all the SDKs
The SDKs should send the expected User-Agent
header. In this step, no need to implement a way to pass a custom User-Agent
header.
We only need to find a smart way (if possible) to pass the version, and/or to check the version is well updated for each release (using the .github/script/check-release.sh
script for example)
- meilisearch-dotnet (Feature/Analytics meilisearch-dotnet#241)
- meilisearch-dart (Feature/Analytics meilisearch-dart#129)
- meilisearch-go (Feature/Analytics meilisearch-go#279)
- meilisearch-java (Feature/Analytics meilisearch-java#503)
- meilisearch-js (Add client header with package information meilisearch-js#1272)
- meilisearch-php (Feature/Analytics meilisearch-php#294) and Add the ability to provide extra custom user-agents meilisearch-php#369
- meilisearch-python (Feature/Analytics meilisearch-python#433)
- meilisearch-ruby (Feature/Analytics meilisearch-ruby#292) and (Support custom agents meilisearch-ruby#354)
- meilisearch-rust (Feature/Analytics meilisearch-rust#254)
- meilisearch-swift (Feature/Analytics meilisearch-swift#277)
- meilisearch-strapi-plugin (Pass strapi client agent to meilisearch-js strapi-plugin-meilisearch#455)
- docs-searchbar.js (Pass client agent to meilisearch-js docs-searchbar.js#621)
- meilisearch-firebase (Pass firebase client agent to meilisearch-js firestore-meilisearch#91)
- meilisearch-rails (Feature/Analytics meilisearch-rails#179)
- meilisearch-symfony (Feature/Add analytics meilisearch-symfony#193)
- meilisearch-vuepress (Pass client agents to meilisearch vuepress-plugin-meilisearch#244)
- meilisearch-gatsby (Pass gatsby client agent to meilisearch-js gatsby-plugin-meilisearch#147)
- instant-meilisearch (Pass client agent to meilisearch-js meilisearch-js-plugins#780)
- laravel scout ([9.x] Add analytics for meilisearch engine laravel/scout#681)
- docs-scraper (Feature/add analytics docs-scraper#387)
Second step: do it in every integration
This step involves some SDKs (JS, PHP, Ruby, and probably more in the future) that can accept a custom User-Agent
header. This needs an internal discussion for implementation and, why not, might deserve another issue.