Actions118
- Mailbox Management Actions
- Mailboxes Actions
- Mailboxes > Accesses > Devices Actions
- Mailboxes > Accesses > Invitations Actions
- Mailboxes > Accesses > Webmail Actions
- List User Access And Invitations
- Create Webmail Access
- Set The Primary Mailbox For The Authenticated User
- List Users Having Access
- List Of User Accesses For The Current User
- List Of User Accesses For A Account And A User
- Update Webmail Access
- Delete Webmail Access
- Delete Access To A Mailbox For The Current User
- Mailboxes > Aliases Actions
- Mailboxes > Auto Reply Actions
- Mailboxes > Folders Actions
- Mailboxes > Forwarding Actions
- Mailboxes > Sieve Filters Actions
- Mailboxes > Signatures Actions
- Mailboxes > Users Actions
- Mailing List Actions
- Mailing List > Subscribers Actions
- Service Mail > Auto Reply Actions
- Service Mail > Bimi Actions
- Service Mail > Filters Models Actions
- Service Mail > Preferences Actions
- Service Mail > Redirections Actions
- Service Mail > Redirections > Target Actions
- Service Mail > Signatures Templates Actions
Service Mail > Redirections → Create Redirection
AI-generatedSummary
Create a new mail redirection for a specified Infomaniak hosting using the chosen authentication method.
Inputs
- authentication (required) — Authentication method; either OAuth2 or API Key.
- path_mail_hosting_id (required) — Identifier of the mail hosting to which the redirection belongs.
- body_name (required) — Name of the redirection (the label shown to users).
- body_targets (required) — JSON object or array specifying email addresses that will receive redirected mail.
- returnFullResponse — If true, the full API response is returned; otherwise only a success indication is provided.
Output shape
a single redirection object
Success returns the created object; when returnFullResponse is true the full API response JSON is returned, otherwise only a success status.
Examples
Example 1: Create a redirection via OAuth2
authentication: OAuth2; path_mail_hosting_id: 12345; body_name: "forward-to-gmail"; body_targets: ["user@example.com"]; returnFullResponse: false
Example 2: Create with API Key and request full response
authentication: API Key; path_mail_hosting_id: 67890; body_name: "backup-mail"; body_targets: {"primary":"mail@example.com"}; returnFullResponse: true