Add mail relay settings

This commit is contained in:
Johannes Zellner
2025-03-12 15:05:46 +01:00
parent 0865b9bbc5
commit 19e08942ed
3 changed files with 208 additions and 0 deletions
+11
View File
@@ -314,6 +314,17 @@ function create() {
if (result.status !== 200) return [result];
return [null, result.body.eventlogs];
},
async setMailRelay(domain, data) {
let result;
try {
result = await fetcher.post(`${API_ORIGIN}/api/v1/mail/${domain}/relay`, data, { access_token: accessToken });
} catch (e) {
return [e];
}
if (result.status !== 202) return [result];
return [null];
},
};
}