mirror of https://github.com/zulip/zulip.git
api-docs: Add comma to all uses of "e.g." in API docs.
This commit is contained in:
parent
f325a7667a
commit
2bb037f2a0
|
@ -2301,7 +2301,7 @@ No changes; feature level used for Zulip 3.0 release.
|
|||
deprecating and replacing the `is_announcement_only` boolean.
|
||||
* [`GET /user_uploads/{realm_id_str}/{filename}`](/api/get-file-temporary-url):
|
||||
New endpoint added for requesting a temporary URL for an uploaded
|
||||
file that does not require authentication to access (e.g. for passing
|
||||
file that does not require authentication to access (e.g., for passing
|
||||
from a Zulip desktop, mobile, or terminal app to the user's default
|
||||
browser).
|
||||
* [`POST /register`](/api/register-queue), [`GET /events`](/api/get-events),
|
||||
|
|
|
@ -47,7 +47,7 @@ for details.
|
|||
|
||||
Clients should note that the `is:unread` filter takes advantage of the
|
||||
fact that there is a database index for unread messages, which can be an
|
||||
important optimization when fetching messages in certain cases (e.g.
|
||||
important optimization when fetching messages in certain cases (e.g.,
|
||||
when [adding the `read` flag to a user's personal
|
||||
messages](/api/update-message-flags-for-narrow)).
|
||||
|
||||
|
|
|
@ -178,7 +178,7 @@ running it manually.
|
|||
|
||||
{start_tabs}
|
||||
|
||||
1. Install *supervisord* via your package manager; e.g. on Debian/Ubuntu:
|
||||
1. Install *supervisord* via your package manager; e.g., on Debian/Ubuntu:
|
||||
|
||||
```
|
||||
sudo apt-get install supervisor
|
||||
|
|
|
@ -125,12 +125,12 @@ below are for a webhook named `MyWebHook`.
|
|||
## General advice
|
||||
|
||||
* Consider using our Zulip markup to make the output from your
|
||||
integration especially attractive or useful (e.g. emoji, Markdown
|
||||
integration especially attractive or useful (e.g., emoji, Markdown
|
||||
emphasis, or @-mentions).
|
||||
|
||||
* Use topics effectively to ensure sequential messages about the same
|
||||
thing are threaded together; this makes for much better consumption
|
||||
by users. E.g. for a bug tracker integration, put the bug number in
|
||||
by users. E.g., for a bug tracker integration, put the bug number in
|
||||
the topic for all messages; for an integration like Nagios, put the
|
||||
service in the topic.
|
||||
|
||||
|
|
|
@ -71,7 +71,7 @@ integration uses.
|
|||
In the `zerver/webhooks/` directory, create new subdirectory that will
|
||||
contain all of the corresponding code. In our example it will be
|
||||
`helloworld`. The new directory will be a python package, so you have
|
||||
to create an empty `__init__.py` file in that directory via e.g.
|
||||
to create an empty `__init__.py` file in that directory via e.g.,
|
||||
`touch zerver/webhooks/helloworld/__init__.py`.
|
||||
|
||||
## Step 2: Create main webhook code
|
||||
|
@ -128,7 +128,7 @@ https://zulip.readthedocs.io/en/latest/tutorials/writing-views.html#request-vari
|
|||
|
||||
You must pass the name of your integration to the
|
||||
`webhook_view` decorator; that name will be used to
|
||||
describe your integration in Zulip's analytics (e.g. the `/stats`
|
||||
describe your integration in Zulip's analytics (e.g., the `/stats`
|
||||
page). Here we have used `HelloWorld`. To be consistent with other
|
||||
integrations, use the name of the product you are integrating in camel
|
||||
case, spelled as the product spells its own name (except always first
|
||||
|
|
|
@ -19,7 +19,7 @@ Every error response will also contain an additional key:
|
|||
|
||||
Clients should always check `code`, rather than `msg`, when looking for
|
||||
specific error conditions. The string values for `msg` are
|
||||
internationalized (e.g. the server will send the error message
|
||||
internationalized (e.g., the server will send the error message
|
||||
translated into French if the user has a French locale), so checking
|
||||
those strings will result in buggy code.
|
||||
|
||||
|
@ -53,7 +53,7 @@ In JSON success responses, all Zulip REST API endpoints may return
|
|||
an array of parameters sent in the request that are not supported
|
||||
by that specific endpoint.
|
||||
|
||||
While this can be expected, e.g. when sending both current and legacy
|
||||
While this can be expected, e.g., when sending both current and legacy
|
||||
names for a parameter to a Zulip server of unknown version, this often
|
||||
indicates either a bug in the client implementation or an attempt to
|
||||
configure a new feature while connected to an older Zulip server that
|
||||
|
|
|
@ -6,7 +6,7 @@ you can do in Zulip, you can do with Zulip's REST API. To use this API:
|
|||
* You'll need to [get an API key](/api/api-keys). You will likely
|
||||
want to [create a bot](/help/add-a-bot-or-integration), unless you're
|
||||
using the API to interact with
|
||||
your own account (e.g. exporting your personal message history).
|
||||
your own account (e.g., exporting your personal message history).
|
||||
* Choose what language you'd like to use. You can download the
|
||||
[Python or JavaScript bindings](/api/installation-instructions), projects in
|
||||
[other languages](/api/client-libraries), or
|
||||
|
|
|
@ -12,7 +12,7 @@ https://github.com/zulip/python-zulip-api/tree/main/zulip_bots/zulip_bots/bots).
|
|||
You'll need:
|
||||
|
||||
* An account in a Zulip organization
|
||||
(e.g. [the Zulip development community](https://zulip.com/development-community/),
|
||||
(e.g., [the Zulip development community](https://zulip.com/development-community/),
|
||||
`<yourSubdomain>.zulipchat.com`, or a Zulip organization on your own
|
||||
[development](https://zulip.readthedocs.io/en/latest/development/overview.html) or
|
||||
[production](https://zulip.readthedocs.io/en/latest/production/install.html) server).
|
||||
|
|
|
@ -151,7 +151,7 @@ Response: stream: followup topic: foo_sender@zulip.com
|
|||
```
|
||||
|
||||
Note that the `-b` (aka `--bot-config-file`) argument is for an optional third party
|
||||
config file (e.g. ~/giphy.conf), which only applies to certain types of bots.
|
||||
config file (e.g., ~/giphy.conf), which only applies to certain types of bots.
|
||||
|
||||
## Bot API
|
||||
|
||||
|
@ -208,7 +208,7 @@ handles user message.
|
|||
|
||||
* message - a dictionary describing a Zulip message
|
||||
|
||||
* bot_handler - used to interact with the server, e.g. to send a message
|
||||
* bot_handler - used to interact with the server, e.g., to send a message
|
||||
|
||||
#### Return values
|
||||
|
||||
|
@ -290,7 +290,7 @@ bot_handler.update_message(dict(
|
|||
### bot_handler.storage
|
||||
|
||||
A common problem when writing an interactive bot is that you want to
|
||||
be able to store a bit of persistent state for the bot (e.g. for an
|
||||
be able to store a bit of persistent state for the bot (e.g., for an
|
||||
RSVP bot, the RSVPs). For a sufficiently complex bot, you want need
|
||||
your own database, but for simpler bots, we offer a convenient way for
|
||||
bot code to persistently store data.
|
||||
|
@ -382,7 +382,7 @@ every call to `put` and `get`, respectively.
|
|||
* key - the API key you created for the bot; this is how Zulip knows
|
||||
the request is from an authorized user.
|
||||
|
||||
* email - the email address of the bot, e.g. `some-bot@zulip.com`
|
||||
* email - the email address of the bot, e.g., `some-bot@zulip.com`
|
||||
|
||||
* site - your development environment URL; if you are working on a
|
||||
development environment hosted on your computer, use
|
||||
|
|
Loading…
Reference in New Issue