Wikibase/Wikibase.cloud/User-Agent Policy
Summary
[edit]- Set a User-Agent Header that reflects the User-Agent making the request.
- Make the description as clear as possible.
- Don't have your User-Agent pretend to be something else.
Intention
[edit]Having a policy makes it easier for users to understand what we expect. This policy mostly inherits its ideas from the WMF's User Agent Policy. It also aims to be clearer and easier to understand.
Having clear User-Agents is important for the maintainers of Wikibase Cloud to ensure that the traffic that is consuming our resources is meaningful. It also allows us to throttle or block requests that are misbehaving.
Policy Details
[edit]Send a descriptive User-Agent Header
[edit]If you are making a request from a bot or a script that isn't a browser, set a descriptive header. An example from the WMF Policy of a good string is:
User-Agent: CoolBot/0.0 (https://example.org/coolbot/; coolbot@example.org) generic-library/0.0
Include "bot" in the User-Agent Header
[edit]If your request is coming from an automated tool or bot, include "bot" in the header.
Make contact with you easy
[edit]Include contact details for the creator/operator of the agent in the string. The Wikibase Cloud maintainers would rather not block traffic, but instead contact users to find a mutually agreeable solution. Examples: email, url, Wikipage, Wiki username, code repository, etc.
Avoid generic agents
[edit]curl or pywikibot are likely to be hard to recognize from other tools that are also using these underlying generic tools. Try to add additional information.
Requests originating from the browser
[edit]For requests coming from a user browsing the site normally, the browser's User-Agent string should be used and, in any case, is likely hard to modify.
If you are writing code (e.g. Javascript) that makes requests from the browser, you can set the Api-User-Agent header as a work around to communicate instead.