@noah/hey-email
HEY.com email integration with Kody: search threads, read messages/attachments, create drafts, and send with explicit confirmation.
- Version
- 1.2.0
- License
- Published
- September 18, 2026
- Pinned commit
c1a2829- Rating
- No ratings yet
- Forks
- 0
- Adaptation effort
- —
README
Agent docs@noah/hey-email
Intent
Give Kody packages a thin, secret-backed way to search, read, and draft the
signed-in user's HEY mail without running the local hey CLI inside Workers.
Powered by the heyToken user secret against https://app.hey.com.
Success means another package can search threads, read bodies, download PDF
receipts, and save a reply draft that the user opens in HEY. Nothing in this
package sends mail unless sendDraft({ confirm: true }) is called on purpose.
Prerequisites
- Save secret
heyToken(fromhey auth token) with allowed hostapp.hey.com. - Approve host access if prompted on first fetch.
The token is read from the secret at request time and is only ever sent to
app.hey.com. Requests to any other origin are refused.
Exports
kody:@noah/hey-email— identity smoke testkody:@noah/hey-email/search— advanced searchkody:@noah/hey-email/boxes— list boxeskody:@noah/hey-email/topic— get topic JSONkody:@noah/hey-email/entries— list topic entrieskody:@noah/hey-email/message— full message JSON (/messages/{id}.json)kody:@noah/hey-email/attachments— list/download PDF attachments from message HTMLkody:@noah/hey-email/drafts— list / create / read drafts; optional send with confirmkody:@noah/hey-email/reply— alias forcreateReplyDraftkody:@noah/hey-email/send—sendMessage/sendReply/sendDraft(confirm required)
Draft vs send
HEY's POST /entries/{id}/replies.json sends when to is present and
saves a draft when to is omitted. createReplyDraft never sends to.
Draft edit URL: https://app.hey.com/messages/{id}/edit
Topic URL: https://app.hey.com/topics/{topicId}
License
MIT. See LICENSE.
Smoke test
import identity from 'kody:@noah/hey-email'
import { listDrafts } from 'kody:@noah/hey-email/drafts'
await identity()
await listDrafts()Report this listing
Log in to report this listing.