daknode 0.1.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.
- daknode/__init__.py +8 -0
- daknode/api/__init__.py +1 -0
- daknode/api/block_rules/__init__.py +1 -0
- daknode/api/block_rules/create_block_rule.py +211 -0
- daknode/api/block_rules/create_inbox_block_rule.py +225 -0
- daknode/api/block_rules/delete_block_rule.py +192 -0
- daknode/api/block_rules/list_block_rules.py +214 -0
- daknode/api/block_rules/list_inbox_block_rules.py +228 -0
- daknode/api/consent/__init__.py +1 -0
- daknode/api/consent/create_consent.py +203 -0
- daknode/api/consent/revoke.py +195 -0
- daknode/api/control_plane/__init__.py +1 -0
- daknode/api/control_plane/close_workspace.py +184 -0
- daknode/api/control_plane/create_workspace.py +211 -0
- daknode/api/control_plane/list_workspaces.py +155 -0
- daknode/api/control_plane/read_workspace.py +176 -0
- daknode/api/control_plane/update_workspace.py +197 -0
- daknode/api/dead_letters/__init__.py +1 -0
- daknode/api/dead_letters/list_dead_letters.py +198 -0
- daknode/api/dead_letters/replay_dead_letter.py +216 -0
- daknode/api/inboxes/__init__.py +1 -0
- daknode/api/inboxes/create_inbox.py +183 -0
- daknode/api/inboxes/register_webhook.py +225 -0
- daknode/api/inboxes/rotate_webhook_secret.py +224 -0
- daknode/api/messages/__init__.py +1 -0
- daknode/api/messages/get_message.py +176 -0
- daknode/api/messages/get_thread.py +184 -0
- daknode/api/messages/list_messages.py +228 -0
- daknode/api/messages/list_threads.py +228 -0
- daknode/api/privacy/__init__.py +1 -0
- daknode/api/privacy/create_erasure_request.py +227 -0
- daknode/api/privacy/read_erasure_request.py +200 -0
- daknode/api/public/__init__.py +1 -0
- daknode/api/public/agent_signup.py +191 -0
- daknode/api/public/agent_verify.py +191 -0
- daknode/api/search/__init__.py +1 -0
- daknode/api/search/search.py +207 -0
- daknode/api/send/__init__.py +1 -0
- daknode/api/send/send.py +254 -0
- daknode/client.py +270 -0
- daknode/errors.py +14 -0
- daknode/models/__init__.py +79 -0
- daknode/models/block_rule_create.py +104 -0
- daknode/models/block_rule_out.py +160 -0
- daknode/models/block_rule_page.py +116 -0
- daknode/models/consent_request.py +104 -0
- daknode/models/consent_response.py +105 -0
- daknode/models/create_erasure_request_response_create_erasure_request.py +63 -0
- daknode/models/create_in.py +119 -0
- daknode/models/dead_letter_response.py +205 -0
- daknode/models/erasure_request_body.py +60 -0
- daknode/models/http_validation_error.py +97 -0
- daknode/models/inbox_create_request.py +120 -0
- daknode/models/inbox_response.py +148 -0
- daknode/models/message_out.py +309 -0
- daknode/models/message_page.py +116 -0
- daknode/models/read_erasure_request_response_read_erasure_request.py +63 -0
- daknode/models/replay_response.py +113 -0
- daknode/models/revoke_request.py +74 -0
- daknode/models/revoke_response_revoke.py +63 -0
- daknode/models/search_match.py +170 -0
- daknode/models/search_request.py +107 -0
- daknode/models/search_response.py +124 -0
- daknode/models/send_request.py +162 -0
- daknode/models/send_response_send.py +63 -0
- daknode/models/signup_in.py +63 -0
- daknode/models/signup_out.py +102 -0
- daknode/models/thread_detail_out.py +223 -0
- daknode/models/thread_out.py +163 -0
- daknode/models/thread_page.py +116 -0
- daknode/models/timeline_item_out.py +280 -0
- daknode/models/update_in.py +111 -0
- daknode/models/validation_error.py +141 -0
- daknode/models/validation_error_context.py +63 -0
- daknode/models/verify_in.py +67 -0
- daknode/models/verify_out.py +74 -0
- daknode/models/webhook_register_request.py +74 -0
- daknode/models/workspace_list_out.py +92 -0
- daknode/models/workspace_out.py +147 -0
- daknode/py.typed +1 -0
- daknode/types.py +53 -0
- daknode-0.1.0.dist-info/METADATA +143 -0
- daknode-0.1.0.dist-info/RECORD +84 -0
- daknode-0.1.0.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar, Optional, BinaryIO, TextIO, TYPE_CHECKING, Generator
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
from ..types import UNSET, Unset
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
T = TypeVar("T", bound="ErasureRequestBody")
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
@_attrs_define
|
|
20
|
+
class ErasureRequestBody:
|
|
21
|
+
""" The address is in the BODY, never the path or a query parameter.
|
|
22
|
+
|
|
23
|
+
A URL is written to every proxy, load balancer and access log on the path
|
|
24
|
+
and leaks through `Referer`. Putting a data subject's address there would
|
|
25
|
+
scatter it across systems this erasure cannot reach.
|
|
26
|
+
|
|
27
|
+
Attributes:
|
|
28
|
+
subject_email (str):
|
|
29
|
+
"""
|
|
30
|
+
|
|
31
|
+
subject_email: str
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
def to_dict(self) -> dict[str, Any]:
|
|
38
|
+
subject_email = self.subject_email
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
field_dict: dict[str, Any] = {}
|
|
42
|
+
|
|
43
|
+
field_dict.update({
|
|
44
|
+
"subject_email": subject_email,
|
|
45
|
+
})
|
|
46
|
+
|
|
47
|
+
return field_dict
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
@classmethod
|
|
52
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
53
|
+
d = dict(src_dict)
|
|
54
|
+
subject_email = d.pop("subject_email")
|
|
55
|
+
|
|
56
|
+
erasure_request_body = cls(
|
|
57
|
+
subject_email=subject_email,
|
|
58
|
+
)
|
|
59
|
+
|
|
60
|
+
return erasure_request_body
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar, Optional, BinaryIO, TextIO, TYPE_CHECKING, Generator
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
from ..types import UNSET, Unset
|
|
8
|
+
|
|
9
|
+
from ..types import UNSET, Unset
|
|
10
|
+
from typing import cast
|
|
11
|
+
from typing import Union
|
|
12
|
+
|
|
13
|
+
if TYPE_CHECKING:
|
|
14
|
+
from ..models.validation_error import ValidationError
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
T = TypeVar("T", bound="HTTPValidationError")
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
@_attrs_define
|
|
25
|
+
class HTTPValidationError:
|
|
26
|
+
"""
|
|
27
|
+
Attributes:
|
|
28
|
+
detail (Union[Unset, list['ValidationError']]):
|
|
29
|
+
"""
|
|
30
|
+
|
|
31
|
+
detail: Union[Unset, list['ValidationError']] = UNSET
|
|
32
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
def to_dict(self) -> dict[str, Any]:
|
|
39
|
+
from ..models.validation_error import ValidationError
|
|
40
|
+
detail: Union[Unset, list[dict[str, Any]]] = UNSET
|
|
41
|
+
if not isinstance(self.detail, Unset):
|
|
42
|
+
detail = []
|
|
43
|
+
for detail_item_data in self.detail:
|
|
44
|
+
detail_item = detail_item_data.to_dict()
|
|
45
|
+
detail.append(detail_item)
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
field_dict: dict[str, Any] = {}
|
|
51
|
+
field_dict.update(self.additional_properties)
|
|
52
|
+
field_dict.update({
|
|
53
|
+
})
|
|
54
|
+
if detail is not UNSET:
|
|
55
|
+
field_dict["detail"] = detail
|
|
56
|
+
|
|
57
|
+
return field_dict
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
@classmethod
|
|
62
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
63
|
+
from ..models.validation_error import ValidationError
|
|
64
|
+
d = dict(src_dict)
|
|
65
|
+
detail = []
|
|
66
|
+
_detail = d.pop("detail", UNSET)
|
|
67
|
+
for detail_item_data in (_detail or []):
|
|
68
|
+
detail_item = ValidationError.from_dict(detail_item_data)
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
detail.append(detail_item)
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
http_validation_error = cls(
|
|
76
|
+
detail=detail,
|
|
77
|
+
)
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
http_validation_error.additional_properties = d
|
|
81
|
+
return http_validation_error
|
|
82
|
+
|
|
83
|
+
@property
|
|
84
|
+
def additional_keys(self) -> list[str]:
|
|
85
|
+
return list(self.additional_properties.keys())
|
|
86
|
+
|
|
87
|
+
def __getitem__(self, key: str) -> Any:
|
|
88
|
+
return self.additional_properties[key]
|
|
89
|
+
|
|
90
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
91
|
+
self.additional_properties[key] = value
|
|
92
|
+
|
|
93
|
+
def __delitem__(self, key: str) -> None:
|
|
94
|
+
del self.additional_properties[key]
|
|
95
|
+
|
|
96
|
+
def __contains__(self, key: str) -> bool:
|
|
97
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar, Optional, BinaryIO, TextIO, TYPE_CHECKING, Generator
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
from ..types import UNSET, Unset
|
|
8
|
+
|
|
9
|
+
from ..types import UNSET, Unset
|
|
10
|
+
from typing import cast, Union
|
|
11
|
+
from typing import Union
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
T = TypeVar("T", bound="InboxCreateRequest")
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
@_attrs_define
|
|
23
|
+
class InboxCreateRequest:
|
|
24
|
+
"""
|
|
25
|
+
Attributes:
|
|
26
|
+
alias (str): Local part of the address, e.g. 'support' for support@…
|
|
27
|
+
display_name (Union[None, Unset, str]):
|
|
28
|
+
webhook_url (Union[None, Unset, str]): HTTPS destination for inbound message events. Validated against the
|
|
29
|
+
egress policy before it is stored.
|
|
30
|
+
"""
|
|
31
|
+
|
|
32
|
+
alias: str
|
|
33
|
+
display_name: Union[None, Unset, str] = UNSET
|
|
34
|
+
webhook_url: Union[None, Unset, str] = UNSET
|
|
35
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def to_dict(self) -> dict[str, Any]:
|
|
42
|
+
alias = self.alias
|
|
43
|
+
|
|
44
|
+
display_name: Union[None, Unset, str]
|
|
45
|
+
if isinstance(self.display_name, Unset):
|
|
46
|
+
display_name = UNSET
|
|
47
|
+
else:
|
|
48
|
+
display_name = self.display_name
|
|
49
|
+
|
|
50
|
+
webhook_url: Union[None, Unset, str]
|
|
51
|
+
if isinstance(self.webhook_url, Unset):
|
|
52
|
+
webhook_url = UNSET
|
|
53
|
+
else:
|
|
54
|
+
webhook_url = self.webhook_url
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
field_dict: dict[str, Any] = {}
|
|
58
|
+
field_dict.update(self.additional_properties)
|
|
59
|
+
field_dict.update({
|
|
60
|
+
"alias": alias,
|
|
61
|
+
})
|
|
62
|
+
if display_name is not UNSET:
|
|
63
|
+
field_dict["display_name"] = display_name
|
|
64
|
+
if webhook_url is not UNSET:
|
|
65
|
+
field_dict["webhook_url"] = webhook_url
|
|
66
|
+
|
|
67
|
+
return field_dict
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
@classmethod
|
|
72
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
73
|
+
d = dict(src_dict)
|
|
74
|
+
alias = d.pop("alias")
|
|
75
|
+
|
|
76
|
+
def _parse_display_name(data: object) -> Union[None, Unset, str]:
|
|
77
|
+
if data is None:
|
|
78
|
+
return data
|
|
79
|
+
if isinstance(data, Unset):
|
|
80
|
+
return data
|
|
81
|
+
return cast(Union[None, Unset, str], data)
|
|
82
|
+
|
|
83
|
+
display_name = _parse_display_name(d.pop("display_name", UNSET))
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
def _parse_webhook_url(data: object) -> Union[None, Unset, str]:
|
|
87
|
+
if data is None:
|
|
88
|
+
return data
|
|
89
|
+
if isinstance(data, Unset):
|
|
90
|
+
return data
|
|
91
|
+
return cast(Union[None, Unset, str], data)
|
|
92
|
+
|
|
93
|
+
webhook_url = _parse_webhook_url(d.pop("webhook_url", UNSET))
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
inbox_create_request = cls(
|
|
97
|
+
alias=alias,
|
|
98
|
+
display_name=display_name,
|
|
99
|
+
webhook_url=webhook_url,
|
|
100
|
+
)
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
inbox_create_request.additional_properties = d
|
|
104
|
+
return inbox_create_request
|
|
105
|
+
|
|
106
|
+
@property
|
|
107
|
+
def additional_keys(self) -> list[str]:
|
|
108
|
+
return list(self.additional_properties.keys())
|
|
109
|
+
|
|
110
|
+
def __getitem__(self, key: str) -> Any:
|
|
111
|
+
return self.additional_properties[key]
|
|
112
|
+
|
|
113
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
114
|
+
self.additional_properties[key] = value
|
|
115
|
+
|
|
116
|
+
def __delitem__(self, key: str) -> None:
|
|
117
|
+
del self.additional_properties[key]
|
|
118
|
+
|
|
119
|
+
def __contains__(self, key: str) -> bool:
|
|
120
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar, Optional, BinaryIO, TextIO, TYPE_CHECKING, Generator
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
from ..types import UNSET, Unset
|
|
8
|
+
|
|
9
|
+
from ..types import UNSET, Unset
|
|
10
|
+
from typing import cast, Union
|
|
11
|
+
from typing import Union
|
|
12
|
+
from uuid import UUID
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
T = TypeVar("T", bound="InboxResponse")
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
@_attrs_define
|
|
24
|
+
class InboxResponse:
|
|
25
|
+
"""
|
|
26
|
+
Attributes:
|
|
27
|
+
address (str):
|
|
28
|
+
channel (str):
|
|
29
|
+
display_name (Union[None, str]):
|
|
30
|
+
inbox_id (UUID):
|
|
31
|
+
webhook_url (Union[None, str]):
|
|
32
|
+
webhook_secret (Union[None, Unset, str]):
|
|
33
|
+
"""
|
|
34
|
+
|
|
35
|
+
address: str
|
|
36
|
+
channel: str
|
|
37
|
+
display_name: Union[None, str]
|
|
38
|
+
inbox_id: UUID
|
|
39
|
+
webhook_url: Union[None, str]
|
|
40
|
+
webhook_secret: Union[None, Unset, str] = UNSET
|
|
41
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
def to_dict(self) -> dict[str, Any]:
|
|
48
|
+
address = self.address
|
|
49
|
+
|
|
50
|
+
channel = self.channel
|
|
51
|
+
|
|
52
|
+
display_name: Union[None, str]
|
|
53
|
+
display_name = self.display_name
|
|
54
|
+
|
|
55
|
+
inbox_id = str(self.inbox_id)
|
|
56
|
+
|
|
57
|
+
webhook_url: Union[None, str]
|
|
58
|
+
webhook_url = self.webhook_url
|
|
59
|
+
|
|
60
|
+
webhook_secret: Union[None, Unset, str]
|
|
61
|
+
if isinstance(self.webhook_secret, Unset):
|
|
62
|
+
webhook_secret = UNSET
|
|
63
|
+
else:
|
|
64
|
+
webhook_secret = self.webhook_secret
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
field_dict: dict[str, Any] = {}
|
|
68
|
+
field_dict.update(self.additional_properties)
|
|
69
|
+
field_dict.update({
|
|
70
|
+
"address": address,
|
|
71
|
+
"channel": channel,
|
|
72
|
+
"display_name": display_name,
|
|
73
|
+
"inbox_id": inbox_id,
|
|
74
|
+
"webhook_url": webhook_url,
|
|
75
|
+
})
|
|
76
|
+
if webhook_secret is not UNSET:
|
|
77
|
+
field_dict["webhook_secret"] = webhook_secret
|
|
78
|
+
|
|
79
|
+
return field_dict
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
@classmethod
|
|
84
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
85
|
+
d = dict(src_dict)
|
|
86
|
+
address = d.pop("address")
|
|
87
|
+
|
|
88
|
+
channel = d.pop("channel")
|
|
89
|
+
|
|
90
|
+
def _parse_display_name(data: object) -> Union[None, str]:
|
|
91
|
+
if data is None:
|
|
92
|
+
return data
|
|
93
|
+
return cast(Union[None, str], data)
|
|
94
|
+
|
|
95
|
+
display_name = _parse_display_name(d.pop("display_name"))
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
inbox_id = UUID(d.pop("inbox_id"))
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
def _parse_webhook_url(data: object) -> Union[None, str]:
|
|
104
|
+
if data is None:
|
|
105
|
+
return data
|
|
106
|
+
return cast(Union[None, str], data)
|
|
107
|
+
|
|
108
|
+
webhook_url = _parse_webhook_url(d.pop("webhook_url"))
|
|
109
|
+
|
|
110
|
+
|
|
111
|
+
def _parse_webhook_secret(data: object) -> Union[None, Unset, str]:
|
|
112
|
+
if data is None:
|
|
113
|
+
return data
|
|
114
|
+
if isinstance(data, Unset):
|
|
115
|
+
return data
|
|
116
|
+
return cast(Union[None, Unset, str], data)
|
|
117
|
+
|
|
118
|
+
webhook_secret = _parse_webhook_secret(d.pop("webhook_secret", UNSET))
|
|
119
|
+
|
|
120
|
+
|
|
121
|
+
inbox_response = cls(
|
|
122
|
+
address=address,
|
|
123
|
+
channel=channel,
|
|
124
|
+
display_name=display_name,
|
|
125
|
+
inbox_id=inbox_id,
|
|
126
|
+
webhook_url=webhook_url,
|
|
127
|
+
webhook_secret=webhook_secret,
|
|
128
|
+
)
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
inbox_response.additional_properties = d
|
|
132
|
+
return inbox_response
|
|
133
|
+
|
|
134
|
+
@property
|
|
135
|
+
def additional_keys(self) -> list[str]:
|
|
136
|
+
return list(self.additional_properties.keys())
|
|
137
|
+
|
|
138
|
+
def __getitem__(self, key: str) -> Any:
|
|
139
|
+
return self.additional_properties[key]
|
|
140
|
+
|
|
141
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
142
|
+
self.additional_properties[key] = value
|
|
143
|
+
|
|
144
|
+
def __delitem__(self, key: str) -> None:
|
|
145
|
+
del self.additional_properties[key]
|
|
146
|
+
|
|
147
|
+
def __contains__(self, key: str) -> bool:
|
|
148
|
+
return key in self.additional_properties
|