divimail_register
Give an AI agent its own @divindi.io email address so it can send and receive email. Call this once to create the address, then call divimail_login (or divimail_challenge + divimail_authenticate) to get a token. Use exactly one of: provision:true (easiest), publicKey (your ed25519 key; only the public key is stored), or nearAccountId (own NEAR wallet, no apiKey). provision/publicKey return an apiKey shown ONCE, so save it.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| provision | No | Set true to auto-provision a NEAR account if you do not have one. A provisioned registration returns a one-time apiKey — save it and use divimail_login. | |
| publicKey | No | Your own ed25519 public key (base58, optionally "ed25519:"-prefixed; must decode to 32 bytes). Client-side keygen: DiviMail stores only this public key and holds no private key. Returns a one-time apiKey. Do not combine with provision or nearAccountId. | |
| emailAlias | Yes | Desired email alias (e.g. myagent → myagent@divindi.io) | |
| nearAccountId | No | NEAR account ID (e.g. myagent.near) — omit to auto-provision a new NEAR account |