Skip to content

Commit

Permalink
Unisender Go: Fix docs inconsistency and add more info about extra op…
Browse files Browse the repository at this point in the history
…tions
  • Loading branch information
Arondit committed Jan 22, 2024
1 parent 441c884 commit 9d8974d
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 29 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ vNext
Features
~~~~~~~~
* **Unisender GO**: Add support for this ESP
(`docs <https://godocs.unisender.ru/>`__).
(`docs <https://anymail.dev/en/latest/esps/unisender_go/>`__).

v10.2
-----
Expand Down
36 changes: 18 additions & 18 deletions docs/esps/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,33 +36,33 @@ The table below summarizes the Anymail features supported for each ESP.

.. rst-class:: sticky-left

============================================ ============ ======= ============ =========== ========== =========== ========== ========== ======== ========== ============== ===========
Email Service Provider |Amazon SES| |Brevo| |MailerSend| |Mailgun| |Mailjet| |Mandrill| |Postal| |Postmark| |Resend| |SendGrid| |Unisender Go| |SparkPost|
============================================ ============ ======= ============ =========== ========== =========== ========== ========== ======== ========== ============== ===========
============================================ ============ ======= ============ =========== ========== =========== ========== ========== ======== ========== =========== ==============
Email Service Provider |Amazon SES| |Brevo| |MailerSend| |Mailgun| |Mailjet| |Mandrill| |Postal| |Postmark| |Resend| |SendGrid| |SparkPost| |Unisender Go|
============================================ ============ ======= ============ =========== ========== =========== ========== ========== ======== ========== =========== ==============
.. rubric:: :ref:`Anymail send options <anymail-send-options>`
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
:attr:`~AnymailMessage.envelope_sender` Yes No No Domain only Yes Domain only Yes No No No No Yes
:attr:`~AnymailMessage.metadata` Yes Yes No Yes Yes Yes No Yes Yes Yes Yes Yes
:attr:`~AnymailMessage.merge_metadata` No No No Yes Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.send_at` No Yes Yes Yes No Yes No No No Yes Yes Yes
:attr:`~AnymailMessage.tags` Yes Yes Yes Yes Max 1 tag Yes Max 1 tag Max 1 tag Yes Yes Yes Max 1 tag
:attr:`~AnymailMessage.track_clicks` No No Yes Yes Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.track_opens` No No Yes Yes Yes Yes No Yes No Yes Yes Yes
:ref:`amp-email` Yes No No Yes No No No No No Yes Yes Yes
:attr:`~AnymailMessage.envelope_sender` Yes No No Domain only Yes Domain only Yes No No No Yes No
:attr:`~AnymailMessage.metadata` Yes Yes No Yes Yes Yes No Yes Yes Yes Yes Yes
:attr:`~AnymailMessage.merge_metadata` No No No Yes Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.send_at` No Yes Yes Yes No Yes No No No Yes Yes Yes
:attr:`~AnymailMessage.tags` Yes Yes Yes Yes Max 1 tag Yes Max 1 tag Max 1 tag Yes Yes Max 1 tag Yes
:attr:`~AnymailMessage.track_clicks` No No Yes Yes Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.track_opens` No No Yes Yes Yes Yes No Yes No Yes Yes Yes
:ref:`amp-email` Yes No No Yes No No No No No Yes Yes Yes

.. rubric:: :ref:`templates-and-merge`
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
:attr:`~AnymailMessage.template_id` Yes Yes Yes Yes Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.merge_data` Yes No Yes Yes Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.merge_global_data` Yes Yes (emulated) (emulated) Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.template_id` Yes Yes Yes Yes Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.merge_data` Yes No Yes Yes Yes Yes No Yes No Yes Yes Yes
:attr:`~AnymailMessage.merge_global_data` Yes Yes (emulated) (emulated) Yes Yes No Yes No Yes Yes Yes
.. rubric:: :ref:`Status <esp-send-status>` and :ref:`event tracking <event-tracking>`
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
:attr:`~AnymailMessage.anymail_status` Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes
|AnymailTrackingEvent| from webhooks Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes
:attr:`~AnymailMessage.anymail_status` Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes
|AnymailTrackingEvent| from webhooks Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes Yes
.. rubric:: :ref:`Inbound handling <inbound>`
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|AnymailInboundEvent| from webhooks Yes Yes Yes Yes Yes Yes Yes Yes No Yes No Yes
============================================ ============ ======= ============ =========== ========== =========== ========== ========== ======== ========== ============== ===========
|AnymailInboundEvent| from webhooks Yes Yes Yes Yes Yes Yes Yes Yes No Yes Yes No
============================================ ============ ======= ============ =========== ========== =========== ========== ========== ======== ========== =========== ==============


Trying to choose an ESP? Please **don't** start with this table. It's far more
Expand Down
30 changes: 20 additions & 10 deletions docs/esps/unisender_go.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,34 +18,34 @@ To use Anymail's Unisender Go backend, set:
in your settings.py.

.. rubric:: UNISENDERGO_API_KEY
.. rubric:: UNISENDER_GO_API_KEY

.. setting:: ANYMAIL_UNISENDERGO_API_KEY
.. setting:: ANYMAIL_UNISENDER_GO_API_KEY

Unisender Go API key

.. code-block:: python
ANYMAIL = {
...
"UNISENDERG_API_KEY": "<your API key>",
"UNISENDER_GO_API_KEY": "<your API key>",
}
Anymail will also look for ``UNISENDERG_API_KEY`` at the
root of the settings file if neither ``ANYMAIL["UNISENDERG_API_KEY"]``
nor ``ANYMAIL_UNISENDERG_API_KEY`` is set.
Anymail will also look for ``UNISENDER_GO_API_KEY`` at the
root of the settings file if neither ``ANYMAIL["UNISENDER_GO_API_KEY"]``
nor ``ANYMAIL_UNISENDER_GO_API_KEY`` is set.

.. setting:: ANYMAIL_UNISENDERGO_API_URL
.. setting:: ANYMAIL_UNISENDER_GO_API_URL

.. rubric:: UNISENDERGO_API_URL
.. rubric:: UNISENDER_GO_API_URL

`Unisender GO API endpoint`_ to use. It can depend on server location.

.. code-block:: python
ANYMAIL = {
...
"UNISENDERGO_API_URL": "https://go1.unisender.ru/ru/transactional/api/v1/", # use Unisender Go RU
"UNISENDER_GO_API_URL": "https://go1.unisender.ru/ru/transactional/api/v1/", # use Unisender Go RU
}
You must specify the full, versioned API endpoint as shown above (not just the base_uri).
Expand All @@ -65,16 +65,26 @@ Limitations and quirks
By default, Unisender Go add in the end of email link to unsubscribe.
If you want to avoid it, you have to ask tech support to enable this option for you.
Then you should set it in settings, like this.
For flexibility, you can set it in "esp_extra" arg in backend.

.. code-block:: python
ANYMAIL_UNISENDERGO_SKIP_UNSUBSCRIBE = True
ANYMAIL_UNISENDER_GO_SKIP_UNSUBSCRIBE = True
**global_language option**
Language for link language and unsubscribe page.
Options: 'be', 'de', 'en', 'es', 'fr', 'it', 'pl', 'pt', 'ru', 'ua', 'kz'.

.. code-block:: python
ANYMAIL_UNISENDER_GO_GLOBAL_LANGUAGE = 'en'
.. _unisender-templates:

ESP templates
-------------------------------------
In Unisender Go you can send email with templates. You just create it and set as `template_id='...'`.
Also you can choose simple template with just `{{ x }}` substitutions or velocity templates with loops, arrays, etc.
You will have to put merge data to put it in template gaps. For example:

.. code-block:: python
Expand Down

0 comments on commit 9d8974d

Please sign in to comment.