POST /v1/mail/services/{mailServiceId}/forwarders
Forward an address, a catch-all, or a whole domain.
אימות
שלחו מפתח API כאסימון נושא (bearer token). על המפתח לכלול את הרשאה mail.manage; מפתח שאינו כולל אותה יידחה בסטטוס 403, ולא 404.
נקודת קצה זו אינה דורשת מזהה ארגון. המפתח שלך כבר מזהה את הארגון שאליו הוא שייך, והתגובה מוגבלת אליו בלבד.
נסה זאת
החלף כל דבר בסוגריים זוויתיים בערכים משלך, ואת מציין מיקום המפתח במפתח מלוח הבקרה שלך.
curl -X POST https://api.zinndigital.com/v1/mail/services/{mailServiceId}/forwarders \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "targets": <string[]> }'מחובר? קונסולת ה-API בלוח הבקרה שלך מזינה את מזהה הארגון האמיתי שלך ואת המפתח שלך, ומריצה את הבקשה מול ה-API הפיזי כך שתוכל לראות את התגובה בפועל. פתח נקודת קצה זו במסוף ה-API
פרטים
`source` is required for `mailbox` and **ignored** for `catchall`/`wildcard`, where the whole domain is the source — so it may be omitted for those rather than sending a value the backend discards. Requires `mail.manage`.
פרמטרים
| שם | סוג | נדרש | מה זה |
|---|---|---|---|
mailServiceId (path) | Uuid | כן | Email service ID (UUIDv7). |
גוף הבקשה
| שם | סוג | נדרש | מה זה |
|---|---|---|---|
source | string | לא | Required for `mailbox`; ignored for `catchall`/`wildcard`. |
targets | string[] | כן | — |
kind | MailForwarderKind | לא | `mailbox` forwards one address; `catchall` takes anything not otherwise matched at the domain; `wildcard` forwards the whole domain to another one. |
תשובה
| שם | סוג | נדרש | מה זה |
|---|---|---|---|
id | string | כן | The mail backend's identifier. |
source | string | כן | The local part being forwarded for `mailbox`; the domain itself for `catchall`/`wildcard`. |
targets | string[] | כן | Where mail goes. May include the backend's reserved drop/reject targets. |
kind | MailForwarderKind | כן | `mailbox` forwards one address; `catchall` takes anything not otherwise matched at the domain; `wildcard` forwards the whole domain to another one. |
שגיאות שנקודה קצה זו עשויה להחזיר
401 · 403 · 404 · 422 · 429 · 503