Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tmail: Inject user contacts into auto-complete database #1163

Open
chibenwa opened this issue Aug 21, 2024 · 0 comments
Open

Tmail: Inject user contacts into auto-complete database #1163

chibenwa opened this issue Aug 21, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@chibenwa
Copy link
Member

chibenwa commented Aug 21, 2024

Why

GIVEN I create [email protected] in OpenPaaS
WHEN I compose an email in Twake mail and type abc
THEN it proposes [email protected] as a potential recipient

How

Listen to exchange contacts:contact:add

Given

{
    "bookId": "65ae6175751dbd001b5799e8",
    "bookName": "contacts",
    "contactId": "fd9b3c98-fc77-4187-92ac-d9f58d400968",
    "userId": "65ae6175751dbd001b5799e8",
    "vcard": [
        "vcard",
        [
            [
                "version",
                {},
                "text",
                "4.0"
            ],
            [
                "uid",
                {},
                "text",
                "fd9b3c98-fc77-4187-92ac-d9f58d400968"
            ],
            [
                "fn",
                {},
                "text",
                "trst wqbvwerbwerb"
            ],
            [
                "n",
                {},
                "text",
                [
                    "wqbvwerbwerb",
                    "trst",
                    "",
                    "",
                    ""
                ]
            ],
            [
                "email",
                {
                    "type": "Work"
                },
                "text",
                "[email protected]"
            ]
        ],
        []
    ]
}

Do a lookup on OpenPaaS to get the associated email

# API to adapt but it looks like: (with the id instead of the mail)
curl -u "[email protected]:secret" https://backend.poc-mail-avocat.fr/api/[email protected]

and index the mail address onto the relevant user search database.

Updates needs to be handled too:

{
    "bookId": "65ae6175751dbd001b5799e8",
    "bookName": "contacts",
    "contactId": "fd9b3c98-fc77-4187-92ac-d9f58d400968",
    "userId": "65ae6175751dbd001b5799e8",
    "vcard": [
        "vcard",
        [
            [
                "version",
                {},
                "text",
                "4.0"
            ],
            [
                "uid",
                {},
                "text",
                "fd9b3c98-fc77-4187-92ac-d9f58d400968"
            ],
            [
                "fn",
                {},
                "text",
                "trst wqbvwerbwerb"
            ],
            [
                "n",
                {},
                "text",
                [
                    "wqbvwerbwerb",
                    "trst",
                    "",
                    "",
                    ""
                ]
            ],
            [
                "email",
                {
                    "type": "Work"
                },
                "text",
                "[email protected]"
            ]
        ],
        []
    ]
}

Definition of done

  • Names shall be used to set the mailbox display name of the recipient
  • When I send an email to someone it should not override the display name set by the calendar
  • Display name from the calendar should override the one of automatic indexing upon sending email (that likely to not have a display name)
  • Separate optional module, should share AMQP base configuration than Reflect calendar updates into twake mail #1162
@chibenwa chibenwa added the enhancement New feature or request label Aug 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant