SES volume
This commit is contained in:
@@ -46,29 +46,17 @@ export const mailboxesAPI = {
|
||||
remove: async (email) =>
|
||||
(await api.delete(`/api/mailboxes/${encodeURIComponent(email)}`)).data,
|
||||
setPassword: async (email, password) =>
|
||||
(await api.post(
|
||||
`/api/mailboxes/${encodeURIComponent(email)}/password`,
|
||||
{ password }
|
||||
)).data,
|
||||
(await api.post(`/api/mailboxes/${encodeURIComponent(email)}/password`, { password })).data,
|
||||
setQuota: async (email, quota_gb) =>
|
||||
(await api.post(
|
||||
`/api/mailboxes/${encodeURIComponent(email)}/quota`,
|
||||
{ quota_gb }
|
||||
)).data,
|
||||
(await api.post(`/api/mailboxes/${encodeURIComponent(email)}/quota`, { quota_gb })).data,
|
||||
getRules: async (email) =>
|
||||
(await api.get(`/api/mailboxes/${encodeURIComponent(email)}/rules`)).data,
|
||||
putRules: async (email, payload) =>
|
||||
(await api.put(
|
||||
`/api/mailboxes/${encodeURIComponent(email)}/rules`,
|
||||
payload
|
||||
)).data,
|
||||
(await api.put(`/api/mailboxes/${encodeURIComponent(email)}/rules`, payload)).data,
|
||||
getBlocklist: async (email) =>
|
||||
(await api.get(`/api/mailboxes/${encodeURIComponent(email)}/blocklist`)).data,
|
||||
putBlocklist: async (email, blocked_patterns) =>
|
||||
(await api.put(
|
||||
`/api/mailboxes/${encodeURIComponent(email)}/blocklist`,
|
||||
{ blocked_patterns }
|
||||
)).data,
|
||||
(await api.put(`/api/mailboxes/${encodeURIComponent(email)}/blocklist`, { blocked_patterns })).data,
|
||||
};
|
||||
|
||||
export const auditAPI = {
|
||||
@@ -107,6 +95,12 @@ export const billingAPI = {
|
||||
if (ym) params.set('ym', ym);
|
||||
return (await api.get(`/api/billing/volume?${params.toString()}`)).data;
|
||||
},
|
||||
volumeOverview: async ({ ym } = {}) => {
|
||||
const params = new URLSearchParams();
|
||||
if (ym) params.set('ym', ym);
|
||||
const qs = params.toString();
|
||||
return (await api.get(`/api/billing/volume-overview${qs ? '?' + qs : ''}`)).data;
|
||||
},
|
||||
};
|
||||
|
||||
export const healthAPI = {
|
||||
|
||||
Reference in New Issue
Block a user