Skip to content

feat(gmail): add first-class RFC822/EML message import command #956

Description

@holgergruenhagen

Hi, thank you for building gogcli and for the Discovery API escape hatch in #867.

A generic use case: Gmail/Workspace no longer provides server-side POP fetching for external mailboxes. A small service can read messages from another provider over IMAP, but it still needs a clean way to place the original RFC822 message into Gmail.

SMTP forwarding is not always reliable. Shared relay IP reputation or forwarding authentication can cause Gmail to reject otherwise valid messages.

gmail.users.messages.import already supports this, and gog api call can invoke it. For regular automation, however, users must Base64URL-encode each message, build JSON, and enable the generic API method.

Would you consider a first-class command such as:

gog gmail import message.eml
gog gmail import --stdin

Useful options might include --label, --internal-date-source, --never-mark-spam, and --process-for-calendar.

This command would only import an existing RFC822/EML message. IMAP fetching and synchronization would remain outside gogcli.

Thank you for considering it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Low-risk cleanup, docs, polish, ergonomics, or speculative feature.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.issue-rating: 🌊 off-meta tidepoolIssue quality rating does not apply to this item.

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions