mirror of
https://github.com/mjl-/mox.git
synced 2024-12-27 08:53:48 +03:00
webapi: minor tweaks in docs
This commit is contained in:
parent
6c488ead0b
commit
a485df830d
2 changed files with 8 additions and 8 deletions
|
@ -42,7 +42,7 @@ errors). Most successful calls return a JSON object, but some return data
|
||||||
(e.g. a raw message or an attachment of a message). See [Methods] for the
|
(e.g. a raw message or an attachment of a message). See [Methods] for the
|
||||||
methods and and [Client] for their documentation. The first element of their
|
methods and and [Client] for their documentation. The first element of their
|
||||||
return values indicate their JSON object type or io.ReadCloser for non-JSON
|
return values indicate their JSON object type or io.ReadCloser for non-JSON
|
||||||
data. The request and response types are converted from/to JSON. optional and
|
data. The request and response types are converted from/to JSON. Optional and
|
||||||
missing/empty fields/values are converted into Go zero values: zero for
|
missing/empty fields/values are converted into Go zero values: zero for
|
||||||
numbers, empty strings, empty lists and empty objects. New fields may be added
|
numbers, empty strings, empty lists and empty objects. New fields may be added
|
||||||
in response objects in future versions, parsers should ignore unrecognized
|
in response objects in future versions, parsers should ignore unrecognized
|
||||||
|
@ -90,7 +90,7 @@ that spammy behaviour and blocklist your mail server.
|
||||||
Automatic suppression list management already prevents most repeated sending
|
Automatic suppression list management already prevents most repeated sending
|
||||||
attempts. The webhooks make it easy to receive failure notifications.
|
attempts. The webhooks make it easy to receive failure notifications.
|
||||||
|
|
||||||
To keep spam complaints about your messages a minimum, include links to
|
To keep spam complaints about your messages to a minimum, include links to
|
||||||
unsubscribe from future messages without requiring further actions from the
|
unsubscribe from future messages without requiring further actions from the
|
||||||
user, such as logins. Include an unsubscribe link in the footer, and include
|
user, such as logins. Include an unsubscribe link in the footer, and include
|
||||||
List-* message headers, such as List-Id, List-Unsubscribe and
|
List-* message headers, such as List-Id, List-Unsubscribe and
|
||||||
|
@ -262,7 +262,7 @@ Get a raw, unparsed message, as bytes:
|
||||||
$ curl --user mox@localhost:moxmoxmox --data request='{"MsgID": 123}' http://localhost:1080/webapi/v0/MessageRawGet
|
$ curl --user mox@localhost:moxmoxmox --data request='{"MsgID": 123}' http://localhost:1080/webapi/v0/MessageRawGet
|
||||||
[message as bytes in raw form]
|
[message as bytes in raw form]
|
||||||
|
|
||||||
Mark a message as read:
|
Mark a message as read and set flag "custom":
|
||||||
|
|
||||||
$ curl --user mox@localhost:moxmoxmox --data request='{"MsgID": 424, "Flags": ["\\Seen", "custom"]}' http://localhost:1080/webapi/v0/MessageFlagsAdd
|
$ curl --user mox@localhost:moxmoxmox --data request='{"MsgID": 424, "Flags": ["\\Seen", "custom"]}' http://localhost:1080/webapi/v0/MessageFlagsAdd
|
||||||
{}
|
{}
|
||||||
|
|
|
@ -52,7 +52,7 @@ errors). Most successful calls return a JSON object, but some return data
|
||||||
(e.g. a raw message or an attachment of a message). See [Methods] for the
|
(e.g. a raw message or an attachment of a message). See [Methods] for the
|
||||||
methods and and [Client] for their documentation. The first element of their
|
methods and and [Client] for their documentation. The first element of their
|
||||||
return values indicate their JSON object type or io.ReadCloser for non-JSON
|
return values indicate their JSON object type or io.ReadCloser for non-JSON
|
||||||
data. The request and response types are converted from/to JSON. optional and
|
data. The request and response types are converted from/to JSON. Optional and
|
||||||
missing/empty fields/values are converted into Go zero values: zero for
|
missing/empty fields/values are converted into Go zero values: zero for
|
||||||
numbers, empty strings, empty lists and empty objects. New fields may be added
|
numbers, empty strings, empty lists and empty objects. New fields may be added
|
||||||
in response objects in future versions, parsers should ignore unrecognized
|
in response objects in future versions, parsers should ignore unrecognized
|
||||||
|
@ -100,7 +100,7 @@ that spammy behaviour and blocklist your mail server.
|
||||||
Automatic suppression list management already prevents most repeated sending
|
Automatic suppression list management already prevents most repeated sending
|
||||||
attempts. The webhooks make it easy to receive failure notifications.
|
attempts. The webhooks make it easy to receive failure notifications.
|
||||||
|
|
||||||
To keep spam complaints about your messages a minimum, include links to
|
To keep spam complaints about your messages to a minimum, include links to
|
||||||
unsubscribe from future messages without requiring further actions from the
|
unsubscribe from future messages without requiring further actions from the
|
||||||
user, such as logins. Include an unsubscribe link in the footer, and include
|
user, such as logins. Include an unsubscribe link in the footer, and include
|
||||||
List-* message headers, such as List-Id, List-Unsubscribe and
|
List-* message headers, such as List-Id, List-Unsubscribe and
|
||||||
|
@ -273,7 +273,7 @@ Get a raw, unparsed message, as bytes:
|
||||||
\$ curl --user mox@localhost:moxmoxmox --data request='{"MsgID": 123}' http://localhost:1080/webapi/v0/MessageRawGet
|
\$ curl --user mox@localhost:moxmoxmox --data request='{"MsgID": 123}' http://localhost:1080/webapi/v0/MessageRawGet
|
||||||
[message as bytes in raw form]
|
[message as bytes in raw form]
|
||||||
|
|
||||||
Mark a message as read:
|
Mark a message as read and set flag "custom":
|
||||||
|
|
||||||
\$ curl --user mox@localhost:moxmoxmox --data request='{"MsgID": 424, "Flags": ["\\\\Seen", "custom"]}' http://localhost:1080/webapi/v0/MessageFlagsAdd
|
\$ curl --user mox@localhost:moxmoxmox --data request='{"MsgID": 424, "Flags": ["\\\\Seen", "custom"]}' http://localhost:1080/webapi/v0/MessageFlagsAdd
|
||||||
{}
|
{}
|
||||||
|
|
Loading…
Reference in a new issue