From dcf83a8d3b56e5cd6b5836eb8847f166c7adeec0 Mon Sep 17 00:00:00 2001 From: Roshan Jonnalagadda Date: Thu, 11 Jun 2026 17:11:59 +1000 Subject: [PATCH] Document multi-mailbox MCP grants --- changelog.mdx | 11 + docs.json | 1 + guides/api-keys.mdx | 6 +- guides/mcp.mdx | 14 +- mailbox-api/introduction.mdx | 29 +- openapi-app.json | 490 ++++++++++++++++++ .../sendmux-mailbox.postman_collection.json | 380 +++++++++++++- 7 files changed, 902 insertions(+), 29 deletions(-) diff --git a/changelog.mdx b/changelog.mdx index 2ba4252..56358d1 100644 --- a/changelog.mdx +++ b/changelog.mdx @@ -4,6 +4,17 @@ description: "New features, improvements, and fixes across the Sendmux platform. rss: true --- + + ## Hosted MCP + +Hosted Product MCP can now grant one or more selected mailboxes in the same connected app. Agents can search the granted mailbox set, target a mailbox for each mailbox action, and remain blocked from any mailbox that was not authorised. + + ## Mailbox API + +Connected-app Mailbox API requests now support `mailbox_id` targeting. Use `GET /mailbox/mailboxes` to list or search the mailboxes available to the token before making a mailbox-specific request. + + + ## Bug fixes diff --git a/docs.json b/docs.json index d32dfbc..dc05a7c 100644 --- a/docs.json +++ b/docs.json @@ -198,6 +198,7 @@ { "group": "Mailbox", "pages": [ + "GET /mailbox/mailboxes", "GET /mailbox/me", "GET /mailbox/session", "GET /mailbox/identity", diff --git a/guides/api-keys.mdx b/guides/api-keys.mdx index 9895d23..ebc699c 100644 --- a/guides/api-keys.mdx +++ b/guides/api-keys.mdx @@ -43,9 +43,9 @@ Sending keys and mailbox keys share the `smx_mbx_` prefix. Their permissions and ## Connected apps -Connected apps let tools such as Product MCP act with the product lines you authorise. During authorisation, you can choose Management, Mailbox, Sending, or a combination. Sendmux then issues a short-lived access token for the app and a refresh token that rotates when used. +Connected apps let tools such as Product MCP act with the product lines you authorise. During authorisation, you can choose Management, Mailbox, Sending, or a combination. If you choose Mailbox, you also choose the mailbox set the app can use. Sendmux then issues a short-lived access token for the app and a refresh token that rotates when used. -Connected apps do not create `smx_root_` or `smx_mbx_` secrets. They are listed separately from manual API keys so you can see which app is connected, which product lines it can use, who authorised it, when it was last used, and how many requests it has made. +Connected apps do not create `smx_root_` or `smx_mbx_` secrets. They are listed separately from manual API keys so you can see which app is connected, which product lines it can use, which mailbox set is selected, who authorised it, when it was last used, and how many requests it has made. To manage connected apps: @@ -61,7 +61,7 @@ To manage connected apps: -Re-authorising the same app updates the existing connection instead of creating unused manual API keys. If you choose fewer product lines during re-authorisation, tools from the removed product lines stop being available to that app. +Re-authorising the same app updates the existing connection instead of creating unused manual API keys. If you choose fewer product lines or mailboxes during re-authorisation, removed tools and mailbox targets stop being available to that app. ## Create a key diff --git a/guides/mcp.mdx b/guides/mcp.mdx index 907fb97..d30a1d2 100644 --- a/guides/mcp.mdx +++ b/guides/mcp.mdx @@ -81,12 +81,12 @@ Use the Product MCP when you want an agent to act inside Sendmux. A single conne | Product line | What the agent can do | Credential authority | | --- | --- | --- | | Management | Manage domains, mailboxes, sending accounts, webhooks, logs, metrics, and billing data. | Team-level access | -| Mailbox | Read, search, organise, thread, and send from one mailbox. | Mailbox access | +| Mailbox | Read, search, organise, thread, and send from selected mailboxes. | Selected mailbox access | | Sending | Send outbound email without mailbox reading tools. | Sending access | Choosing more product lines never grants more authority than your team role, - selected mailbox, and consent allow. Tools for product lines you did not + selected mailbox set, and consent allow. Tools for product lines you did not authorise are not shown to the agent. @@ -112,6 +112,10 @@ When you connect: Select Management, Mailbox, Sending, or any combination. Choose all three when the agent should see every curated Sendmux tool. + + If you select Mailbox, choose one or more mailboxes the agent can use. Use + search or select all when your team has many mailboxes. + Review the requested access and select **Authorise**. @@ -119,7 +123,9 @@ When you connect: Connected apps use short-lived access tokens that last 15 minutes. Refresh tokens rotate on use and can last up to 30 days unless the connection is disconnected or the grant expires. The connection does not create a manual `smx_root_` or `smx_mbx_` API key. -Re-authorising the same hosted connection replaces the previous product-line selection for that app. Product lines you remove during re-authorisation disappear from the agent's tool list. +When more than one mailbox is granted, agents can call `mailbox_list_granted_mailboxes` to search the granted set and pass `mailbox_id` to mailbox tools. If only one mailbox is granted, mailbox tools use it by default. + +Re-authorising the same hosted connection replaces the previous product-line and mailbox selections for that app. Product lines or mailboxes you remove during re-authorisation disappear from the agent's tool list or allowed mailbox targets. Hosted Product MCP requests keep the same permission, sending-scope, and rate-limit checks as direct Sendmux API requests before each request is accepted. For example, adding Sending tools to an agent does not let it send from mailboxes, sending accounts, or account groups outside the access you granted. @@ -167,6 +173,8 @@ Management requires an `smx_root_` key. Mailbox and Sending require an `smx_mbx_ Use separate keys for separate local product lines when that is how your team grants least-privilege access. For example, a local all-three setup can use one management key plus separate mailbox and sending keys. +Local MCP with a manual mailbox key acts as that one mailbox. Hosted Product MCP can grant a mailbox set and target each mailbox by `mailbox_id`. + ## Tool coverage diff --git a/mailbox-api/introduction.mdx b/mailbox-api/introduction.mdx index 5210f92..837efe0 100644 --- a/mailbox-api/introduction.mdx +++ b/mailbox-api/introduction.mdx @@ -1,6 +1,6 @@ --- title: "Introduction" -description: "Mailbox-scoped API endpoints for a single Sendmux mailbox." +description: "Mailbox-scoped API endpoints for Sendmux mailbox credentials and connected apps." keywords: [ "mailbox API", @@ -14,7 +14,7 @@ keywords: ] --- -The Sendmux Mailbox API is for mailbox-scoped credentials. Use it when a client should act only as the mailbox tied to its API key, not manage team-wide resources. +The Sendmux Mailbox API is for mailbox-scoped access. Use it when a client should act as a mailbox, or as one mailbox from a connected-app mailbox set, without managing team-wide resources. Team-wide mailbox provisioning stays in the [Management API](/api/introduction). High-volume provider-routed sending stays in the [Sending API](/sending-api/introduction). @@ -28,19 +28,20 @@ https://app.sendmux.ai/api/v1 ## Authentication -Authenticate with a mailbox credential from the Sendmux app. Pass it as a Bearer token in the `Authorization` header. +Authenticate with a mailbox credential or connected-app access token from the Sendmux app. Pass it as a Bearer token in the `Authorization` header. ```bash curl https://app.sendmux.ai/api/v1/mailbox/me \ -H "Authorization: Bearer smx_mbx_your_key_here" ``` -Mailbox credentials are scoped to one mailbox. Root API keys are rejected on Mailbox API endpoints. The same credential is also accepted as the mailbox password for SMTP submission and IMAP retrieval. +Manual mailbox credentials are scoped to one mailbox. The same credential is also accepted as the mailbox password for SMTP submission and IMAP retrieval. Connected-app tokens can be granted one or more mailboxes, and each mailbox request is limited to that granted set. Root API keys are rejected on Mailbox API endpoints. ## Current endpoints | Endpoint | Purpose | | ---------------------------------------------------------------- | ----------------------------------------------------------------- | +| `GET /mailbox/mailboxes` | List and search mailboxes granted to the bearer token. | | `GET /mailbox/me` | Return the mailbox associated with the bearer token. | | `GET /mailbox/session` | Return supported capabilities, limits, and current state tokens. | | `GET /mailbox/identity` | Return the mailbox's default sender identity and signatures. | @@ -83,10 +84,28 @@ Mailbox credentials are scoped to one mailbox. Root API keys are rejected on Mai Import the [Mailbox API Postman collection](/guides/postman-collection#choose-a-collection) when you want ready-made requests. +## Mailbox targeting for connected apps + +Manual mailbox credentials always target their single mailbox. Omit `mailbox_id` when you use a manual `smx_mbx_` credential. + +Connected-app tokens can grant a set of mailboxes. Use `GET /mailbox/mailboxes` to list or search the granted set, then pass the selected mailbox's `id` as `mailbox_id` on Mailbox API requests. + +```bash +curl "https://app.sendmux.ai/api/v1/mailbox/mailboxes?q=support" \ + -H "Authorization: Bearer connected_app_access_token" +``` + +```bash +curl "https://app.sendmux.ai/api/v1/mailbox/messages?mailbox_id=mbx_clxxxxxxxxxxxxxxxxxxxxxxxxx&limit=10" \ + -H "Authorization: Bearer connected_app_access_token" +``` + +If a connected app has exactly one granted mailbox, Mailbox API requests use that mailbox by default. If several mailboxes are granted and you omit `mailbox_id`, Sendmux returns `400 missing_parameter`. If you pass a mailbox outside the grant, Sendmux returns `403 insufficient_permissions`. + ## Capability discovery Use `GET /mailbox/session` before planning a mailbox workflow. It returns the -mailbox tied to the credential, supported Mailbox API features, current state +selected mailbox, supported Mailbox API features, current state tokens, request limits, and gated features. A gated feature is intentionally unavailable through the Mailbox API. diff --git a/openapi-app.json b/openapi-app.json index feac98c..2644a9d 100644 --- a/openapi-app.json +++ b/openapi-app.json @@ -826,6 +826,55 @@ ], "unevaluatedProperties": false }, + "GrantedMailbox": { + "additionalProperties": false, + "properties": { + "email": { + "description": "Mailbox email address", + "example": "agent@acme.com", + "type": "string" + }, + "id": { + "description": "Mailbox public ID", + "example": "mbx_clxxxxxxxxxxxxxxxxxxxxxxxxx", + "type": "string" + } + }, + "required": [ + "id", + "email" + ], + "type": "object" + }, + "GrantedMailboxListResponse": { + "allOf": [ + { + "$ref": "#/components/schemas/SuccessEnvelope" + }, + { + "properties": { + "data": { + "items": { + "$ref": "#/components/schemas/GrantedMailbox" + }, + "type": "array" + }, + "meta": { + "$ref": "#/components/schemas/ResponseMeta" + }, + "pagination": { + "$ref": "#/components/schemas/CursorPagination" + } + }, + "required": [ + "data", + "pagination" + ], + "type": "object" + } + ], + "unevaluatedProperties": false + }, "IncomingLogItem": { "additionalProperties": false, "properties": { @@ -8693,6 +8742,15 @@ "description": "Filename to use when sending the uploaded attachment.", "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "requestBody": { @@ -8838,6 +8896,15 @@ "minimum": 1, "type": "integer" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -8929,6 +8996,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9026,6 +9102,15 @@ "minimum": 1, "type": "integer" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9053,6 +9138,17 @@ "post": { "description": "Creates a folder in the authenticated mailbox.", "operationId": "mailboxCreateFolder", + "parameters": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } + } + ], "requestBody": { "content": { "application/json": { @@ -9125,6 +9221,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9178,6 +9283,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9234,6 +9348,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "requestBody": { @@ -9320,6 +9443,15 @@ "minimum": 1, "type": "integer" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9377,6 +9509,15 @@ "minimum": 1, "type": "integer" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9434,6 +9575,15 @@ "minimum": 1, "type": "integer" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9493,6 +9643,17 @@ "get": { "description": "Returns the default sender identity and signatures for the authenticated mailbox.", "operationId": "mailboxGetIdentity", + "parameters": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } + } + ], "responses": { "200": { "content": { @@ -9548,6 +9709,17 @@ "patch": { "description": "Updates the default sender name, plain text signature, and HTML signature for the authenticated mailbox.", "operationId": "mailboxUpdateIdentity", + "parameters": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } + } + ], "requestBody": { "content": { "application/json": { @@ -9630,6 +9802,84 @@ ] } }, + "/mailbox/mailboxes": { + "get": { + "description": "Lists the mailboxes available to the current mailbox credential or connected app. Use this before choosing a `mailbox_id` for mailbox actions when more than one mailbox is available.", + "operationId": "mailboxListGrantedMailboxes", + "parameters": [ + { + "in": "query", + "name": "cursor", + "required": false, + "schema": { + "description": "Cursor from the previous response.", + "type": "string" + } + }, + { + "in": "query", + "name": "limit", + "required": false, + "schema": { + "description": "Maximum results (default 50).", + "maximum": 100, + "minimum": 1, + "type": "integer" + } + }, + { + "in": "query", + "name": "q", + "required": false, + "schema": { + "description": "Search by mailbox ID or email address.", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/GrantedMailboxListResponse" + } + } + }, + "description": "Granted mailboxes" + }, + "401": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiError" + } + } + }, + "description": "Authentication required" + }, + "403": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ApiError" + } + } + }, + "description": "Mailbox access required" + } + }, + "security": [ + { + "bearerAuth": [] + } + ], + "summary": "List granted mailboxes", + "tags": [ + "Mailbox API" + ] + } + }, "/mailbox/me": { "get": { "description": "Returns the mailbox the bearer token is scoped to, including live storage usage. Intended for SDK auto-discovery — call once on startup to resolve the mailbox ID. Requires a mailbox-scoped API key; root keys receive 403.\n\nResponses carry a weak `ETag` header — send it back as `If-None-Match` on the next request and the server will return `304 Not Modified` (no body) when the mailbox state has not changed.", @@ -9643,6 +9893,15 @@ "description": "Weak ETag from a previous response. Returns 304 when unchanged.", "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9922,6 +10181,15 @@ ], "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -9981,6 +10249,17 @@ "post": { "description": "Moves up to 100 messages to Trash by default with state-safe conflict handling. Set `permanent=true` to permanently delete them.", "operationId": "mailboxBatchDeleteMessages", + "parameters": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } + } + ], "requestBody": { "content": { "application/json": { @@ -10037,6 +10316,17 @@ "post": { "description": "Returns exact messages by ID. Use `body_mode` to choose summary-only output, raw body output, or clean JSON content. Attachment output remains metadata only; attachment contents are not parsed.", "operationId": "mailboxBatchGetMessages", + "parameters": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } + } + ], "requestBody": { "content": { "application/json": { @@ -10093,6 +10383,17 @@ "post": { "description": "Updates allowed message flags and keywords for up to 100 messages with state-safe conflict handling.", "operationId": "mailboxBatchUpdateMessages", + "parameters": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } + } + ], "requestBody": { "content": { "application/json": { @@ -10173,6 +10474,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -10236,6 +10546,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -10292,6 +10611,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "requestBody": { @@ -10385,6 +10713,15 @@ "description": "Optional byte range, for example `bytes=0-1048575`.", "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -10469,6 +10806,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -10617,6 +10963,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -10823,6 +11178,15 @@ "schema": { "type": "boolean" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11070,6 +11434,15 @@ ], "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11274,6 +11647,15 @@ "minimum": 1, "type": "integer" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11322,6 +11704,15 @@ "maxLength": 255, "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "requestBody": { @@ -11483,6 +11874,15 @@ ], "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11540,6 +11940,15 @@ "minimum": 1, "type": "integer" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11587,6 +11996,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11748,6 +12166,15 @@ ], "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11803,6 +12230,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11863,6 +12299,15 @@ "minimum": 1, "type": "integer" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -11988,6 +12433,15 @@ ], "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -12063,6 +12517,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -12231,6 +12694,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -12321,6 +12793,15 @@ ], "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { @@ -12378,6 +12859,15 @@ "schema": { "type": "string" } + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "in": "query", + "name": "mailbox_id", + "required": false, + "schema": { + "type": "string" + } } ], "responses": { diff --git a/postman/sendmux-mailbox.postman_collection.json b/postman/sendmux-mailbox.postman_collection.json index 1ace3d4..74c0168 100644 --- a/postman/sendmux-mailbox.postman_collection.json +++ b/postman/sendmux-mailbox.postman_collection.json @@ -67,6 +67,12 @@ "disabled": false, "key": "filename", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -203,6 +209,12 @@ "disabled": true, "key": "limit", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -292,6 +304,12 @@ "disabled": true, "key": "close_after", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -421,6 +439,12 @@ "disabled": true, "key": "limit", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -483,7 +507,14 @@ "mailbox", "folders" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -566,7 +597,14 @@ "folders", ":folder_id" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [ { "description": "(Required) ", @@ -643,7 +681,14 @@ "folders", ":folder_id" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [ { "description": "(Required) ", @@ -747,7 +792,14 @@ "folders", ":folder_id" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [ { "description": "(Required) ", @@ -856,6 +908,12 @@ "disabled": true, "key": "limit", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -930,6 +988,12 @@ "disabled": true, "key": "limit", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -1003,6 +1067,12 @@ "disabled": true, "key": "limit", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -1094,7 +1164,14 @@ "mailbox", "identity" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -1197,7 +1274,14 @@ "mailbox", "identity" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -1288,6 +1372,98 @@ } ] }, + { + "event": [], + "name": "List granted mailboxes", + "protocolProfileBehavior": { + "disableBodyPruning": true + }, + "request": { + "description": { + "content": "Lists the mailboxes available to the current mailbox credential or connected app. Use this before choosing a `mailbox_id` for mailbox actions when more than one mailbox is available.", + "type": "text/plain" + }, + "header": [ + { + "key": "Accept", + "value": "application/json" + } + ], + "method": "GET", + "name": "List granted mailboxes", + "url": { + "host": [ + "{{mailbox_base_url}}" + ], + "path": [ + "mailbox", + "mailboxes" + ], + "query": [ + { + "disabled": true, + "key": "cursor", + "value": "" + }, + { + "disabled": true, + "key": "limit", + "value": "" + }, + { + "disabled": true, + "key": "q", + "value": "" + } + ], + "variable": [] + } + }, + "response": [ + { + "_postman_previewlanguage": "json", + "body": "", + "code": 200, + "cookie": [], + "header": [ + { + "key": "Content-Type", + "value": "application/json" + } + ], + "name": "Granted mailboxes", + "status": "OK" + }, + { + "_postman_previewlanguage": "json", + "body": "", + "code": 401, + "cookie": [], + "header": [ + { + "key": "Content-Type", + "value": "application/json" + } + ], + "name": "Authentication required", + "status": "Unauthorized" + }, + { + "_postman_previewlanguage": "json", + "body": "", + "code": 403, + "cookie": [], + "header": [ + { + "key": "Content-Type", + "value": "application/json" + } + ], + "name": "Mailbox access required", + "status": "Forbidden" + } + ] + }, { "event": [], "name": "Self-introspect the calling mailbox", @@ -1321,7 +1497,14 @@ "mailbox", "me" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -1552,6 +1735,12 @@ "disabled": true, "key": "sort_direction", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -1656,7 +1845,14 @@ "mailbox", "messages:batch-delete" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -1745,7 +1941,14 @@ "mailbox", "messages:batch-get" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -1834,7 +2037,14 @@ "mailbox", "messages:batch-update" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -1922,6 +2132,12 @@ "disabled": true, "key": "permanent", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [ @@ -2014,7 +2230,14 @@ "messages", ":message_id" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [ { "description": "(Required) ", @@ -2118,7 +2341,14 @@ "messages", ":message_id" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [ { "description": "(Required) ", @@ -2225,7 +2455,14 @@ "attachments", ":attachment_id" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [ { "description": "(Required) ", @@ -2348,6 +2585,12 @@ "disabled": true, "key": "max_body_chars", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [ @@ -2495,6 +2738,12 @@ "disabled": true, "key": "include_attachments", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [ @@ -2690,6 +2939,12 @@ "disabled": true, "key": "is_unread", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -2874,6 +3129,12 @@ "disabled": true, "key": "sort_direction", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -3039,6 +3300,12 @@ "disabled": true, "key": "limit", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -3122,7 +3389,14 @@ "messages", "send" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -3266,6 +3540,12 @@ "disabled": true, "key": "sort_direction", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -3340,6 +3620,12 @@ "disabled": true, "key": "limit", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -3409,7 +3695,14 @@ "mailbox", "session" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } }, @@ -3563,6 +3856,12 @@ "disabled": true, "key": "sort_direction", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -3633,7 +3932,14 @@ "submissions", ":submission_id" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [ { "description": "(Required) ", @@ -3728,6 +4034,12 @@ "disabled": true, "key": "limit", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -3841,6 +4153,12 @@ "disabled": true, "key": "sort_direction", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [] @@ -3939,7 +4257,14 @@ "threads", ":thread_id" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [ { "description": "(Required) ", @@ -4086,6 +4411,12 @@ "disabled": true, "key": "sort", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [ @@ -4202,6 +4533,12 @@ "disabled": true, "key": "sort", "value": "" + }, + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" } ], "variable": [ @@ -4293,7 +4630,14 @@ "mailbox", "usage" ], - "query": [], + "query": [ + { + "description": "Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox.", + "disabled": true, + "key": "mailbox_id", + "value": "" + } + ], "variable": [] } },