Calling it
This is your own data, so a call has to say who you are. Make a token at /token and send it as a header.
curl -H "Authorization: Bearer $MU_TOKEN" \ https://micro.mu/api/v1/mail/inbox
Methods
GET /api/v1/mail/inboxList the account's most recent messages — read my mail, check my inbox
| Argument | Type | Description |
|---|---|---|
tag | string | Only messages sent to this plus-address tag |
offset | number | Matching messages to skip |
limit | number | Max messages (default 10) |
curl \ -H "Authorization: Bearer $MU_TOKEN" \ "https://micro.mu/api/v1/mail/inbox"
GET /api/v1/mail/infoHow to reach the caller here: the handle, the email address if this instance has a mail domain, and whether mail from outside can arrive at all. Pass a tag for a separate one (you+tag) — give that out, then read only its messages with mail_inbox(tag)
| Argument | Type | Description |
|---|---|---|
tag | string | A label for this handle, e.g. "research" or "receipts". Omit for the plain one |
curl \ -H "Authorization: Bearer $MU_TOKEN" \ "https://micro.mu/api/v1/mail/info"
POST /api/v1/mail/markreadMark specified inbox message IDs, or explicitly all current inbox messages, as read. Changes read status only; does not read, summarize or triage the content.
| Argument | Type | Description |
|---|---|---|
ids | array | Message IDs to mark read; use all instead to clear the inbox unread count |
all | boolean | Explicitly mark all current inbox mail as read |
curl -X POST \
-H "Authorization: Bearer $MU_TOKEN" \
-H "Content-Type: application/json" \
-d '{}' \
https://micro.mu/api/v1/mail/markreadGET /api/v1/mail/readRead your correspondence by id in bounded body-character pages, including attachment names. Follow the returned next offset for the rest. Omitting id retains the legacy inbox summary
| Argument | Type | Description |
|---|---|---|
offset | number | Body character offset |
limit | number | Body characters per page; default and maximum 2000 |
id | string | Message id from mail_inbox or mail_search |
curl \ -H "Authorization: Bearer $MU_TOKEN" \ "https://micro.mu/api/v1/mail/read"
POST /api/v1/mail/searchSearch the account's mail and return matching messages
| Argument | Type | Description |
|---|---|---|
tag | string | Only messages sent to this plus-address tag |
offset | number | Matching messages to skip |
query | string | What to look for |
limit | number | Max results (default 10) |
curl -X POST \
-H "Authorization: Bearer $MU_TOKEN" \
-H "Content-Type: application/json" \
-d '{}' \
https://micro.mu/api/v1/mail/searchPOST /api/v1/mail/sendWrite to somebody, as you. A username reaches them on this instance and is free; a full email address leaves over SMTP under this instance's domain, so a reply comes back to your inbox, and is charged. Resolve a name with contacts_find first. Mail that leaves needs MAIL_DOMAIN configured on the instance
| Argument | Type | Description |
|---|---|---|
to * | string | Recipient: a username on this instance, or a full email address. Resolve a name with contacts_find first |
subject * | string | Message subject |
body * | string | Message body, plain text |
curl -X POST \
-H "Authorization: Bearer $MU_TOKEN" \
-H "Content-Type: application/json" \
-d '{"body":"body","subject":"subject","to":"to"}' \
https://micro.mu/api/v1/mail/sendThe same methods are tools over MCP, and every service on this instance is in one reference.
