fix: JMAP integration - #1445
Merged
Merged
Conversation
floatpanebot
previously requested changes
Jun 5, 2026
floatpanebot
left a comment
Member
There was a problem hiding this comment.
Hi @masukomi! Please fix the following issues with your PR:
- Title: Does not follow conventional commits (e.g.,
feat: added something,fix(core): resolved crash).
floatpanebot
previously requested changes
Jun 5, 2026
floatpanebot
left a comment
Member
There was a problem hiding this comment.
Hi @masukomi! Please fix the following issues with your PR:
- Title: Does not follow conventional commits (e.g.,
feat: added something,fix(core): resolved crash).
floatpanebot
dismissed stale reviews from themself
June 5, 2026 12:24
Formatting issues have been resolved. Thank you!
JMAP protocol accounts were being sent to IMAP code Root cause: fetcher/dispatch.go only routed "maildir" accounts through the backend abstraction. JMAP accounts fell through to legacy IMAP code, which tried to find an IMAP server, found none, and produced the misleading "unsupported service_provider:" error. The JMAP backend was registered (imported in main.go) but never actually invoked. Fix: Added "jmap" to the hasBackendProvider check and moved the JMAP backend import to dispatch.go (same pattern as maildir). jmap.go wasn't supporting token auth correctly Fastmail is the largest (only?) JMAP using email provider. They require JMAP clients to use API tokens. This fixes the handling of 'token' account.AuthMethod edit account TUI now shows elements for token AuthMethod
floatpanebot
pushed a commit
that referenced
this pull request
Jun 5, 2026
## What? The code to support JMAP authentication via API tokens was in place, it just wasn't wired up correctly. This fixes that. - JMAP protocol selection ended up getting routed to IMAP code - no way to specify `token` for `account.AuthMethod` - `hasBackendProvider` didn't account for/support `jmap` - modified placeholder when `account.AuthMethod` is `token` to say `API Token` instead of `Password / App Password` - modified tip for `inputAuthMethod` when protocol is `jmap` ## Why? Because I use Fastmail, want to use JMAP, and want to be able to read my email. JMAP authentication with Fastmail via API Tokens wasn't working for multiple reasons. Fastmail is the largest (only?) JMAP supporting email host and they require API Tokens. I have manually confirmed that this authenticates just fine with my Fastmail account via JMAP and the API token. (cherry picked from commit 11d4adb)
Member
|
Cherry-picked |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What?
The code to support JMAP authentication via API tokens was in place, it just wasn't wired up correctly. This fixes that.
tokenforaccount.AuthMethodhasBackendProviderdidn't account for/supportjmapaccount.AuthMethodistokento sayAPI Tokeninstead ofPassword / App PasswordinputAuthMethodwhen protocol isjmapWhy?
Because I use Fastmail, want to use JMAP, and want to be able to read my email.
JMAP authentication with Fastmail via API Tokens wasn't working for multiple reasons. Fastmail is the largest (only?) JMAP supporting email host and they require API Tokens.
I have manually confirmed that this authenticates just fine with my Fastmail account via JMAP and the API token.