mailmus 0.2.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- mailmus/__init__.py +129 -0
- mailmus/_default_clients.py +30 -0
- mailmus/account/__init__.py +4 -0
- mailmus/account/client.py +414 -0
- mailmus/account/raw_client.py +423 -0
- mailmus/account_analytics/__init__.py +4 -0
- mailmus/account_analytics/client.py +97 -0
- mailmus/account_analytics/raw_client.py +81 -0
- mailmus/analytics/__init__.py +4 -0
- mailmus/analytics/client.py +243 -0
- mailmus/analytics/raw_client.py +214 -0
- mailmus/api_keys/__init__.py +34 -0
- mailmus/api_keys/client.py +277 -0
- mailmus/api_keys/raw_client.py +256 -0
- mailmus/api_keys/types/__init__.py +34 -0
- mailmus/api_keys/types/create_api_key_dto_type.py +5 -0
- mailmus/app/__init__.py +4 -0
- mailmus/app/client.py +95 -0
- mailmus/app/raw_client.py +79 -0
- mailmus/apps/__init__.py +4 -0
- mailmus/apps/client.py +370 -0
- mailmus/apps/raw_client.py +371 -0
- mailmus/audiences/__init__.py +4 -0
- mailmus/audiences/client.py +822 -0
- mailmus/audiences/raw_client.py +783 -0
- mailmus/auth/__init__.py +4 -0
- mailmus/auth/client.py +428 -0
- mailmus/auth/raw_client.py +478 -0
- mailmus/automations/__init__.py +4 -0
- mailmus/automations/client.py +510 -0
- mailmus/automations/raw_client.py +477 -0
- mailmus/billing/__init__.py +34 -0
- mailmus/billing/client.py +229 -0
- mailmus/billing/raw_client.py +223 -0
- mailmus/billing/types/__init__.py +34 -0
- mailmus/billing/types/create_checkout_dto_plan.py +5 -0
- mailmus/billing_webhook/__init__.py +4 -0
- mailmus/billing_webhook/client.py +111 -0
- mailmus/billing_webhook/raw_client.py +91 -0
- mailmus/campaigns/__init__.py +4 -0
- mailmus/campaigns/client.py +1048 -0
- mailmus/campaigns/raw_client.py +975 -0
- mailmus/client.py +588 -0
- mailmus/contacts/__init__.py +4 -0
- mailmus/contacts/client.py +838 -0
- mailmus/contacts/raw_client.py +799 -0
- mailmus/core/__init__.py +127 -0
- mailmus/core/api_error.py +23 -0
- mailmus/core/client_wrapper.py +118 -0
- mailmus/core/datetime_utils.py +70 -0
- mailmus/core/file.py +67 -0
- mailmus/core/force_multipart.py +18 -0
- mailmus/core/http_client.py +839 -0
- mailmus/core/http_response.py +59 -0
- mailmus/core/http_sse/__init__.py +42 -0
- mailmus/core/http_sse/_api.py +170 -0
- mailmus/core/http_sse/_decoders.py +61 -0
- mailmus/core/http_sse/_exceptions.py +7 -0
- mailmus/core/http_sse/_models.py +17 -0
- mailmus/core/jsonable_encoder.py +120 -0
- mailmus/core/logging.py +107 -0
- mailmus/core/parse_error.py +36 -0
- mailmus/core/pydantic_utilities.py +508 -0
- mailmus/core/query_encoder.py +58 -0
- mailmus/core/remove_none_from_dict.py +11 -0
- mailmus/core/request_options.py +35 -0
- mailmus/core/serialization.py +347 -0
- mailmus/domains/__init__.py +4 -0
- mailmus/domains/client.py +332 -0
- mailmus/domains/raw_client.py +307 -0
- mailmus/emails/__init__.py +4 -0
- mailmus/emails/client.py +500 -0
- mailmus/emails/raw_client.py +466 -0
- mailmus/public/__init__.py +4 -0
- mailmus/public/client.py +150 -0
- mailmus/public/raw_client.py +132 -0
- mailmus/py.typed +0 -0
- mailmus/ses_webhook/__init__.py +4 -0
- mailmus/ses_webhook/client.py +111 -0
- mailmus/ses_webhook/raw_client.py +91 -0
- mailmus/suppressions/__init__.py +4 -0
- mailmus/suppressions/client.py +256 -0
- mailmus/suppressions/raw_client.py +243 -0
- mailmus/templates/__init__.py +4 -0
- mailmus/templates/client.py +544 -0
- mailmus/templates/raw_client.py +511 -0
- mailmus/tracking/__init__.py +4 -0
- mailmus/tracking/client.py +341 -0
- mailmus/tracking/raw_client.py +314 -0
- mailmus/types/__init__.py +38 -0
- mailmus/types/email_attachment_dto.py +29 -0
- mailmus/types/send_transactional_email_dto.py +57 -0
- mailmus/usage/__init__.py +4 -0
- mailmus/usage/client.py +95 -0
- mailmus/usage/raw_client.py +79 -0
- mailmus/webhooks/__init__.py +37 -0
- mailmus/webhooks/client.py +628 -0
- mailmus/webhooks/raw_client.py +577 -0
- mailmus/webhooks/types/__init__.py +38 -0
- mailmus/webhooks/types/create_webhook_dto_events_item.py +22 -0
- mailmus/webhooks/types/update_webhook_dto_events_item.py +22 -0
- mailmus-0.2.0.dist-info/METADATA +192 -0
- mailmus-0.2.0.dist-info/RECORD +105 -0
- mailmus-0.2.0.dist-info/WHEEL +5 -0
- mailmus-0.2.0.dist-info/top_level.txt +1 -0
mailmus/__init__.py
ADDED
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
# isort: skip_file
|
|
4
|
+
|
|
5
|
+
import typing
|
|
6
|
+
from importlib import import_module
|
|
7
|
+
|
|
8
|
+
if typing.TYPE_CHECKING:
|
|
9
|
+
from .types import EmailAttachmentDto, SendTransactionalEmailDto
|
|
10
|
+
from . import (
|
|
11
|
+
account,
|
|
12
|
+
account_analytics,
|
|
13
|
+
analytics,
|
|
14
|
+
api_keys,
|
|
15
|
+
app,
|
|
16
|
+
apps,
|
|
17
|
+
audiences,
|
|
18
|
+
auth,
|
|
19
|
+
automations,
|
|
20
|
+
billing,
|
|
21
|
+
billing_webhook,
|
|
22
|
+
campaigns,
|
|
23
|
+
contacts,
|
|
24
|
+
domains,
|
|
25
|
+
emails,
|
|
26
|
+
public,
|
|
27
|
+
ses_webhook,
|
|
28
|
+
suppressions,
|
|
29
|
+
templates,
|
|
30
|
+
tracking,
|
|
31
|
+
usage,
|
|
32
|
+
webhooks,
|
|
33
|
+
)
|
|
34
|
+
from ._default_clients import DefaultAioHttpClient, DefaultAsyncHttpxClient
|
|
35
|
+
from .api_keys import CreateApiKeyDtoType
|
|
36
|
+
from .billing import CreateCheckoutDtoPlan
|
|
37
|
+
from .client import AsyncMailmusApi, MailmusApi
|
|
38
|
+
from .webhooks import CreateWebhookDtoEventsItem, UpdateWebhookDtoEventsItem
|
|
39
|
+
_dynamic_imports: typing.Dict[str, str] = {
|
|
40
|
+
"AsyncMailmusApi": ".client",
|
|
41
|
+
"CreateApiKeyDtoType": ".api_keys",
|
|
42
|
+
"CreateCheckoutDtoPlan": ".billing",
|
|
43
|
+
"CreateWebhookDtoEventsItem": ".webhooks",
|
|
44
|
+
"DefaultAioHttpClient": "._default_clients",
|
|
45
|
+
"DefaultAsyncHttpxClient": "._default_clients",
|
|
46
|
+
"EmailAttachmentDto": ".types",
|
|
47
|
+
"MailmusApi": ".client",
|
|
48
|
+
"SendTransactionalEmailDto": ".types",
|
|
49
|
+
"UpdateWebhookDtoEventsItem": ".webhooks",
|
|
50
|
+
"account": ".account",
|
|
51
|
+
"account_analytics": ".account_analytics",
|
|
52
|
+
"analytics": ".analytics",
|
|
53
|
+
"api_keys": ".api_keys",
|
|
54
|
+
"app": ".app",
|
|
55
|
+
"apps": ".apps",
|
|
56
|
+
"audiences": ".audiences",
|
|
57
|
+
"auth": ".auth",
|
|
58
|
+
"automations": ".automations",
|
|
59
|
+
"billing": ".billing",
|
|
60
|
+
"billing_webhook": ".billing_webhook",
|
|
61
|
+
"campaigns": ".campaigns",
|
|
62
|
+
"contacts": ".contacts",
|
|
63
|
+
"domains": ".domains",
|
|
64
|
+
"emails": ".emails",
|
|
65
|
+
"public": ".public",
|
|
66
|
+
"ses_webhook": ".ses_webhook",
|
|
67
|
+
"suppressions": ".suppressions",
|
|
68
|
+
"templates": ".templates",
|
|
69
|
+
"tracking": ".tracking",
|
|
70
|
+
"usage": ".usage",
|
|
71
|
+
"webhooks": ".webhooks",
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
def __getattr__(attr_name: str) -> typing.Any:
|
|
76
|
+
module_name = _dynamic_imports.get(attr_name)
|
|
77
|
+
if module_name is None:
|
|
78
|
+
raise AttributeError(f"No {attr_name} found in _dynamic_imports for module name -> {__name__}")
|
|
79
|
+
try:
|
|
80
|
+
module = import_module(module_name, __package__)
|
|
81
|
+
if module_name == f".{attr_name}":
|
|
82
|
+
return module
|
|
83
|
+
else:
|
|
84
|
+
return getattr(module, attr_name)
|
|
85
|
+
except ImportError as e:
|
|
86
|
+
raise ImportError(f"Failed to import {attr_name} from {module_name}: {e}") from e
|
|
87
|
+
except AttributeError as e:
|
|
88
|
+
raise AttributeError(f"Failed to get {attr_name} from {module_name}: {e}") from e
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
def __dir__():
|
|
92
|
+
lazy_attrs = list(_dynamic_imports.keys())
|
|
93
|
+
return sorted(lazy_attrs)
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
__all__ = [
|
|
97
|
+
"AsyncMailmusApi",
|
|
98
|
+
"CreateApiKeyDtoType",
|
|
99
|
+
"CreateCheckoutDtoPlan",
|
|
100
|
+
"CreateWebhookDtoEventsItem",
|
|
101
|
+
"DefaultAioHttpClient",
|
|
102
|
+
"DefaultAsyncHttpxClient",
|
|
103
|
+
"EmailAttachmentDto",
|
|
104
|
+
"MailmusApi",
|
|
105
|
+
"SendTransactionalEmailDto",
|
|
106
|
+
"UpdateWebhookDtoEventsItem",
|
|
107
|
+
"account",
|
|
108
|
+
"account_analytics",
|
|
109
|
+
"analytics",
|
|
110
|
+
"api_keys",
|
|
111
|
+
"app",
|
|
112
|
+
"apps",
|
|
113
|
+
"audiences",
|
|
114
|
+
"auth",
|
|
115
|
+
"automations",
|
|
116
|
+
"billing",
|
|
117
|
+
"billing_webhook",
|
|
118
|
+
"campaigns",
|
|
119
|
+
"contacts",
|
|
120
|
+
"domains",
|
|
121
|
+
"emails",
|
|
122
|
+
"public",
|
|
123
|
+
"ses_webhook",
|
|
124
|
+
"suppressions",
|
|
125
|
+
"templates",
|
|
126
|
+
"tracking",
|
|
127
|
+
"usage",
|
|
128
|
+
"webhooks",
|
|
129
|
+
]
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
import httpx
|
|
6
|
+
|
|
7
|
+
SDK_DEFAULT_TIMEOUT = 60
|
|
8
|
+
|
|
9
|
+
try:
|
|
10
|
+
import httpx_aiohttp # type: ignore[import-not-found]
|
|
11
|
+
except ImportError:
|
|
12
|
+
|
|
13
|
+
class DefaultAioHttpClient(httpx.AsyncClient): # type: ignore
|
|
14
|
+
def __init__(self, **kwargs: typing.Any) -> None:
|
|
15
|
+
raise RuntimeError("To use the aiohttp client, install the aiohttp extra: pip install mailmus[aiohttp]")
|
|
16
|
+
|
|
17
|
+
else:
|
|
18
|
+
|
|
19
|
+
class DefaultAioHttpClient(httpx_aiohttp.HttpxAiohttpClient): # type: ignore
|
|
20
|
+
def __init__(self, **kwargs: typing.Any) -> None:
|
|
21
|
+
kwargs.setdefault("timeout", SDK_DEFAULT_TIMEOUT)
|
|
22
|
+
kwargs.setdefault("follow_redirects", True)
|
|
23
|
+
super().__init__(**kwargs)
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class DefaultAsyncHttpxClient(httpx.AsyncClient):
|
|
27
|
+
def __init__(self, **kwargs: typing.Any) -> None:
|
|
28
|
+
kwargs.setdefault("timeout", SDK_DEFAULT_TIMEOUT)
|
|
29
|
+
kwargs.setdefault("follow_redirects", True)
|
|
30
|
+
super().__init__(**kwargs)
|
|
@@ -0,0 +1,414 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import typing
|
|
4
|
+
|
|
5
|
+
from ..core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
|
|
6
|
+
from ..core.request_options import RequestOptions
|
|
7
|
+
from .raw_client import AsyncRawAccountClient, RawAccountClient
|
|
8
|
+
|
|
9
|
+
# this is used as the default value for optional parameters
|
|
10
|
+
OMIT = typing.cast(typing.Any, ...)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class AccountClient:
|
|
14
|
+
def __init__(self, *, client_wrapper: SyncClientWrapper):
|
|
15
|
+
self._raw_client = RawAccountClient(client_wrapper=client_wrapper)
|
|
16
|
+
|
|
17
|
+
@property
|
|
18
|
+
def with_raw_response(self) -> RawAccountClient:
|
|
19
|
+
"""
|
|
20
|
+
Retrieves a raw implementation of this client that returns raw responses.
|
|
21
|
+
|
|
22
|
+
Returns
|
|
23
|
+
-------
|
|
24
|
+
RawAccountClient
|
|
25
|
+
"""
|
|
26
|
+
return self._raw_client
|
|
27
|
+
|
|
28
|
+
def account_controller_me(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
29
|
+
"""
|
|
30
|
+
Parameters
|
|
31
|
+
----------
|
|
32
|
+
request_options : typing.Optional[RequestOptions]
|
|
33
|
+
Request-specific configuration.
|
|
34
|
+
|
|
35
|
+
Returns
|
|
36
|
+
-------
|
|
37
|
+
None
|
|
38
|
+
|
|
39
|
+
Examples
|
|
40
|
+
--------
|
|
41
|
+
from mailmus import MailmusApi
|
|
42
|
+
|
|
43
|
+
client = MailmusApi(
|
|
44
|
+
token="YOUR_TOKEN",
|
|
45
|
+
base_url="https://yourhost.com/path/to/api",
|
|
46
|
+
)
|
|
47
|
+
client.account.account_controller_me()
|
|
48
|
+
"""
|
|
49
|
+
_response = self._raw_client.account_controller_me(request_options=request_options)
|
|
50
|
+
return _response.data
|
|
51
|
+
|
|
52
|
+
def account_controller_update_name(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
53
|
+
"""
|
|
54
|
+
Parameters
|
|
55
|
+
----------
|
|
56
|
+
request_options : typing.Optional[RequestOptions]
|
|
57
|
+
Request-specific configuration.
|
|
58
|
+
|
|
59
|
+
Returns
|
|
60
|
+
-------
|
|
61
|
+
None
|
|
62
|
+
|
|
63
|
+
Examples
|
|
64
|
+
--------
|
|
65
|
+
from mailmus import MailmusApi
|
|
66
|
+
|
|
67
|
+
client = MailmusApi(
|
|
68
|
+
token="YOUR_TOKEN",
|
|
69
|
+
base_url="https://yourhost.com/path/to/api",
|
|
70
|
+
)
|
|
71
|
+
client.account.account_controller_update_name()
|
|
72
|
+
"""
|
|
73
|
+
_response = self._raw_client.account_controller_update_name(request_options=request_options)
|
|
74
|
+
return _response.data
|
|
75
|
+
|
|
76
|
+
def account_controller_change_password(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
77
|
+
"""
|
|
78
|
+
Parameters
|
|
79
|
+
----------
|
|
80
|
+
request_options : typing.Optional[RequestOptions]
|
|
81
|
+
Request-specific configuration.
|
|
82
|
+
|
|
83
|
+
Returns
|
|
84
|
+
-------
|
|
85
|
+
None
|
|
86
|
+
|
|
87
|
+
Examples
|
|
88
|
+
--------
|
|
89
|
+
from mailmus import MailmusApi
|
|
90
|
+
|
|
91
|
+
client = MailmusApi(
|
|
92
|
+
token="YOUR_TOKEN",
|
|
93
|
+
base_url="https://yourhost.com/path/to/api",
|
|
94
|
+
)
|
|
95
|
+
client.account.account_controller_change_password()
|
|
96
|
+
"""
|
|
97
|
+
_response = self._raw_client.account_controller_change_password(request_options=request_options)
|
|
98
|
+
return _response.data
|
|
99
|
+
|
|
100
|
+
def account_controller_list_members(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
101
|
+
"""
|
|
102
|
+
Parameters
|
|
103
|
+
----------
|
|
104
|
+
request_options : typing.Optional[RequestOptions]
|
|
105
|
+
Request-specific configuration.
|
|
106
|
+
|
|
107
|
+
Returns
|
|
108
|
+
-------
|
|
109
|
+
None
|
|
110
|
+
|
|
111
|
+
Examples
|
|
112
|
+
--------
|
|
113
|
+
from mailmus import MailmusApi
|
|
114
|
+
|
|
115
|
+
client = MailmusApi(
|
|
116
|
+
token="YOUR_TOKEN",
|
|
117
|
+
base_url="https://yourhost.com/path/to/api",
|
|
118
|
+
)
|
|
119
|
+
client.account.account_controller_list_members()
|
|
120
|
+
"""
|
|
121
|
+
_response = self._raw_client.account_controller_list_members(request_options=request_options)
|
|
122
|
+
return _response.data
|
|
123
|
+
|
|
124
|
+
def account_controller_remove_member(
|
|
125
|
+
self, user_id: str, *, request_options: typing.Optional[RequestOptions] = None
|
|
126
|
+
) -> None:
|
|
127
|
+
"""
|
|
128
|
+
Parameters
|
|
129
|
+
----------
|
|
130
|
+
user_id : str
|
|
131
|
+
|
|
132
|
+
request_options : typing.Optional[RequestOptions]
|
|
133
|
+
Request-specific configuration.
|
|
134
|
+
|
|
135
|
+
Returns
|
|
136
|
+
-------
|
|
137
|
+
None
|
|
138
|
+
|
|
139
|
+
Examples
|
|
140
|
+
--------
|
|
141
|
+
from mailmus import MailmusApi
|
|
142
|
+
|
|
143
|
+
client = MailmusApi(
|
|
144
|
+
token="YOUR_TOKEN",
|
|
145
|
+
base_url="https://yourhost.com/path/to/api",
|
|
146
|
+
)
|
|
147
|
+
client.account.account_controller_remove_member(
|
|
148
|
+
user_id="userId",
|
|
149
|
+
)
|
|
150
|
+
"""
|
|
151
|
+
_response = self._raw_client.account_controller_remove_member(user_id, request_options=request_options)
|
|
152
|
+
return _response.data
|
|
153
|
+
|
|
154
|
+
def account_controller_list_audit_log(
|
|
155
|
+
self, *, page: str, limit: str, request_options: typing.Optional[RequestOptions] = None
|
|
156
|
+
) -> None:
|
|
157
|
+
"""
|
|
158
|
+
Parameters
|
|
159
|
+
----------
|
|
160
|
+
page : str
|
|
161
|
+
|
|
162
|
+
limit : str
|
|
163
|
+
|
|
164
|
+
request_options : typing.Optional[RequestOptions]
|
|
165
|
+
Request-specific configuration.
|
|
166
|
+
|
|
167
|
+
Returns
|
|
168
|
+
-------
|
|
169
|
+
None
|
|
170
|
+
|
|
171
|
+
Examples
|
|
172
|
+
--------
|
|
173
|
+
from mailmus import MailmusApi
|
|
174
|
+
|
|
175
|
+
client = MailmusApi(
|
|
176
|
+
token="YOUR_TOKEN",
|
|
177
|
+
base_url="https://yourhost.com/path/to/api",
|
|
178
|
+
)
|
|
179
|
+
client.account.account_controller_list_audit_log(
|
|
180
|
+
page="page",
|
|
181
|
+
limit="limit",
|
|
182
|
+
)
|
|
183
|
+
"""
|
|
184
|
+
_response = self._raw_client.account_controller_list_audit_log(
|
|
185
|
+
page=page, limit=limit, request_options=request_options
|
|
186
|
+
)
|
|
187
|
+
return _response.data
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
class AsyncAccountClient:
|
|
191
|
+
def __init__(self, *, client_wrapper: AsyncClientWrapper):
|
|
192
|
+
self._raw_client = AsyncRawAccountClient(client_wrapper=client_wrapper)
|
|
193
|
+
|
|
194
|
+
@property
|
|
195
|
+
def with_raw_response(self) -> AsyncRawAccountClient:
|
|
196
|
+
"""
|
|
197
|
+
Retrieves a raw implementation of this client that returns raw responses.
|
|
198
|
+
|
|
199
|
+
Returns
|
|
200
|
+
-------
|
|
201
|
+
AsyncRawAccountClient
|
|
202
|
+
"""
|
|
203
|
+
return self._raw_client
|
|
204
|
+
|
|
205
|
+
async def account_controller_me(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
206
|
+
"""
|
|
207
|
+
Parameters
|
|
208
|
+
----------
|
|
209
|
+
request_options : typing.Optional[RequestOptions]
|
|
210
|
+
Request-specific configuration.
|
|
211
|
+
|
|
212
|
+
Returns
|
|
213
|
+
-------
|
|
214
|
+
None
|
|
215
|
+
|
|
216
|
+
Examples
|
|
217
|
+
--------
|
|
218
|
+
import asyncio
|
|
219
|
+
|
|
220
|
+
from mailmus import AsyncMailmusApi
|
|
221
|
+
|
|
222
|
+
client = AsyncMailmusApi(
|
|
223
|
+
token="YOUR_TOKEN",
|
|
224
|
+
base_url="https://yourhost.com/path/to/api",
|
|
225
|
+
)
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
async def main() -> None:
|
|
229
|
+
await client.account.account_controller_me()
|
|
230
|
+
|
|
231
|
+
|
|
232
|
+
asyncio.run(main())
|
|
233
|
+
"""
|
|
234
|
+
_response = await self._raw_client.account_controller_me(request_options=request_options)
|
|
235
|
+
return _response.data
|
|
236
|
+
|
|
237
|
+
async def account_controller_update_name(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
238
|
+
"""
|
|
239
|
+
Parameters
|
|
240
|
+
----------
|
|
241
|
+
request_options : typing.Optional[RequestOptions]
|
|
242
|
+
Request-specific configuration.
|
|
243
|
+
|
|
244
|
+
Returns
|
|
245
|
+
-------
|
|
246
|
+
None
|
|
247
|
+
|
|
248
|
+
Examples
|
|
249
|
+
--------
|
|
250
|
+
import asyncio
|
|
251
|
+
|
|
252
|
+
from mailmus import AsyncMailmusApi
|
|
253
|
+
|
|
254
|
+
client = AsyncMailmusApi(
|
|
255
|
+
token="YOUR_TOKEN",
|
|
256
|
+
base_url="https://yourhost.com/path/to/api",
|
|
257
|
+
)
|
|
258
|
+
|
|
259
|
+
|
|
260
|
+
async def main() -> None:
|
|
261
|
+
await client.account.account_controller_update_name()
|
|
262
|
+
|
|
263
|
+
|
|
264
|
+
asyncio.run(main())
|
|
265
|
+
"""
|
|
266
|
+
_response = await self._raw_client.account_controller_update_name(request_options=request_options)
|
|
267
|
+
return _response.data
|
|
268
|
+
|
|
269
|
+
async def account_controller_change_password(
|
|
270
|
+
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
271
|
+
) -> None:
|
|
272
|
+
"""
|
|
273
|
+
Parameters
|
|
274
|
+
----------
|
|
275
|
+
request_options : typing.Optional[RequestOptions]
|
|
276
|
+
Request-specific configuration.
|
|
277
|
+
|
|
278
|
+
Returns
|
|
279
|
+
-------
|
|
280
|
+
None
|
|
281
|
+
|
|
282
|
+
Examples
|
|
283
|
+
--------
|
|
284
|
+
import asyncio
|
|
285
|
+
|
|
286
|
+
from mailmus import AsyncMailmusApi
|
|
287
|
+
|
|
288
|
+
client = AsyncMailmusApi(
|
|
289
|
+
token="YOUR_TOKEN",
|
|
290
|
+
base_url="https://yourhost.com/path/to/api",
|
|
291
|
+
)
|
|
292
|
+
|
|
293
|
+
|
|
294
|
+
async def main() -> None:
|
|
295
|
+
await client.account.account_controller_change_password()
|
|
296
|
+
|
|
297
|
+
|
|
298
|
+
asyncio.run(main())
|
|
299
|
+
"""
|
|
300
|
+
_response = await self._raw_client.account_controller_change_password(request_options=request_options)
|
|
301
|
+
return _response.data
|
|
302
|
+
|
|
303
|
+
async def account_controller_list_members(self, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
|
304
|
+
"""
|
|
305
|
+
Parameters
|
|
306
|
+
----------
|
|
307
|
+
request_options : typing.Optional[RequestOptions]
|
|
308
|
+
Request-specific configuration.
|
|
309
|
+
|
|
310
|
+
Returns
|
|
311
|
+
-------
|
|
312
|
+
None
|
|
313
|
+
|
|
314
|
+
Examples
|
|
315
|
+
--------
|
|
316
|
+
import asyncio
|
|
317
|
+
|
|
318
|
+
from mailmus import AsyncMailmusApi
|
|
319
|
+
|
|
320
|
+
client = AsyncMailmusApi(
|
|
321
|
+
token="YOUR_TOKEN",
|
|
322
|
+
base_url="https://yourhost.com/path/to/api",
|
|
323
|
+
)
|
|
324
|
+
|
|
325
|
+
|
|
326
|
+
async def main() -> None:
|
|
327
|
+
await client.account.account_controller_list_members()
|
|
328
|
+
|
|
329
|
+
|
|
330
|
+
asyncio.run(main())
|
|
331
|
+
"""
|
|
332
|
+
_response = await self._raw_client.account_controller_list_members(request_options=request_options)
|
|
333
|
+
return _response.data
|
|
334
|
+
|
|
335
|
+
async def account_controller_remove_member(
|
|
336
|
+
self, user_id: str, *, request_options: typing.Optional[RequestOptions] = None
|
|
337
|
+
) -> None:
|
|
338
|
+
"""
|
|
339
|
+
Parameters
|
|
340
|
+
----------
|
|
341
|
+
user_id : str
|
|
342
|
+
|
|
343
|
+
request_options : typing.Optional[RequestOptions]
|
|
344
|
+
Request-specific configuration.
|
|
345
|
+
|
|
346
|
+
Returns
|
|
347
|
+
-------
|
|
348
|
+
None
|
|
349
|
+
|
|
350
|
+
Examples
|
|
351
|
+
--------
|
|
352
|
+
import asyncio
|
|
353
|
+
|
|
354
|
+
from mailmus import AsyncMailmusApi
|
|
355
|
+
|
|
356
|
+
client = AsyncMailmusApi(
|
|
357
|
+
token="YOUR_TOKEN",
|
|
358
|
+
base_url="https://yourhost.com/path/to/api",
|
|
359
|
+
)
|
|
360
|
+
|
|
361
|
+
|
|
362
|
+
async def main() -> None:
|
|
363
|
+
await client.account.account_controller_remove_member(
|
|
364
|
+
user_id="userId",
|
|
365
|
+
)
|
|
366
|
+
|
|
367
|
+
|
|
368
|
+
asyncio.run(main())
|
|
369
|
+
"""
|
|
370
|
+
_response = await self._raw_client.account_controller_remove_member(user_id, request_options=request_options)
|
|
371
|
+
return _response.data
|
|
372
|
+
|
|
373
|
+
async def account_controller_list_audit_log(
|
|
374
|
+
self, *, page: str, limit: str, request_options: typing.Optional[RequestOptions] = None
|
|
375
|
+
) -> None:
|
|
376
|
+
"""
|
|
377
|
+
Parameters
|
|
378
|
+
----------
|
|
379
|
+
page : str
|
|
380
|
+
|
|
381
|
+
limit : str
|
|
382
|
+
|
|
383
|
+
request_options : typing.Optional[RequestOptions]
|
|
384
|
+
Request-specific configuration.
|
|
385
|
+
|
|
386
|
+
Returns
|
|
387
|
+
-------
|
|
388
|
+
None
|
|
389
|
+
|
|
390
|
+
Examples
|
|
391
|
+
--------
|
|
392
|
+
import asyncio
|
|
393
|
+
|
|
394
|
+
from mailmus import AsyncMailmusApi
|
|
395
|
+
|
|
396
|
+
client = AsyncMailmusApi(
|
|
397
|
+
token="YOUR_TOKEN",
|
|
398
|
+
base_url="https://yourhost.com/path/to/api",
|
|
399
|
+
)
|
|
400
|
+
|
|
401
|
+
|
|
402
|
+
async def main() -> None:
|
|
403
|
+
await client.account.account_controller_list_audit_log(
|
|
404
|
+
page="page",
|
|
405
|
+
limit="limit",
|
|
406
|
+
)
|
|
407
|
+
|
|
408
|
+
|
|
409
|
+
asyncio.run(main())
|
|
410
|
+
"""
|
|
411
|
+
_response = await self._raw_client.account_controller_list_audit_log(
|
|
412
|
+
page=page, limit=limit, request_options=request_options
|
|
413
|
+
)
|
|
414
|
+
return _response.data
|