emailguard_sdk 1.0.0
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.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/README.md +169 -0
- data/Rakefile +10 -0
- data/docs/BaseResponse.md +20 -0
- data/docs/BillingApi.md +85 -0
- data/docs/BillingUsageEvent.md +26 -0
- data/docs/BillingUsageItem.md +28 -0
- data/docs/BillingUsageResponse.md +22 -0
- data/docs/ChannelsApi.md +366 -0
- data/docs/CreateNotificationChannelInput.md +22 -0
- data/docs/CreateNotificationRuleInput.md +28 -0
- data/docs/EmailApi.md +72 -0
- data/docs/EmailDetectData.md +44 -0
- data/docs/EmailDetectResponse.md +22 -0
- data/docs/EventsApi.md +76 -0
- data/docs/GetNotificationChannelResponse.md +22 -0
- data/docs/GetNotificationChannelsResponse.md +22 -0
- data/docs/GetNotificationEventsResponse.md +22 -0
- data/docs/GetNotificationRulesResponse.md +22 -0
- data/docs/GetPublicTeamResponse.md +22 -0
- data/docs/IdDataResponse.md +22 -0
- data/docs/IdDataStruct.md +18 -0
- data/docs/InviteTeamMemberInput.md +20 -0
- data/docs/InvitesApi.md +220 -0
- data/docs/ListPublicTeamInvitesResponse.md +22 -0
- data/docs/ListPublicTeamMembersResponse.md +22 -0
- data/docs/MembersApi.md +222 -0
- data/docs/MessageResponse.md +20 -0
- data/docs/NotificationChannelResponse.md +28 -0
- data/docs/NotificationRuleChannelInput.md +22 -0
- data/docs/NotificationRuleChannelResponse.md +28 -0
- data/docs/NotificationRuleResponse.md +32 -0
- data/docs/PublicTeamInviteResponse.md +24 -0
- data/docs/PublicTeamMemberResponse.md +34 -0
- data/docs/PublicTeamResponse.md +28 -0
- data/docs/RulesApi.md +294 -0
- data/docs/TeamsApi.md +148 -0
- data/docs/UpdateNotificationChannelInput.md +20 -0
- data/docs/UpdateNotificationRuleInput.md +28 -0
- data/docs/UpdateTeamInput.md +24 -0
- data/docs/UpdateTeamMemberInput.md +22 -0
- data/emailguard_sdk.gemspec +39 -0
- data/git_push.sh +57 -0
- data/lib/emailguard_sdk/api/billing_api.rb +92 -0
- data/lib/emailguard_sdk/api/channels_api.rb +347 -0
- data/lib/emailguard_sdk/api/email_api.rb +86 -0
- data/lib/emailguard_sdk/api/events_api.rb +79 -0
- data/lib/emailguard_sdk/api/invites_api.rb +210 -0
- data/lib/emailguard_sdk/api/members_api.rb +216 -0
- data/lib/emailguard_sdk/api/rules_api.rb +284 -0
- data/lib/emailguard_sdk/api/teams_api.rb +147 -0
- data/lib/emailguard_sdk/api_client.rb +397 -0
- data/lib/emailguard_sdk/api_error.rb +58 -0
- data/lib/emailguard_sdk/api_model_base.rb +88 -0
- data/lib/emailguard_sdk/configuration.rb +322 -0
- data/lib/emailguard_sdk/models/base_response.rb +175 -0
- data/lib/emailguard_sdk/models/billing_usage_event.rb +268 -0
- data/lib/emailguard_sdk/models/billing_usage_item.rb +262 -0
- data/lib/emailguard_sdk/models/billing_usage_response.rb +186 -0
- data/lib/emailguard_sdk/models/create_notification_channel_input.rb +204 -0
- data/lib/emailguard_sdk/models/create_notification_rule_input.rb +264 -0
- data/lib/emailguard_sdk/models/email_detect_data.rb +266 -0
- data/lib/emailguard_sdk/models/email_detect_response.rb +184 -0
- data/lib/emailguard_sdk/models/get_notification_channel_response.rb +184 -0
- data/lib/emailguard_sdk/models/get_notification_channels_response.rb +186 -0
- data/lib/emailguard_sdk/models/get_notification_events_response.rb +186 -0
- data/lib/emailguard_sdk/models/get_notification_rules_response.rb +186 -0
- data/lib/emailguard_sdk/models/get_public_team_response.rb +184 -0
- data/lib/emailguard_sdk/models/id_data_response.rb +184 -0
- data/lib/emailguard_sdk/models/id_data_struct.rb +148 -0
- data/lib/emailguard_sdk/models/invite_team_member_input.rb +192 -0
- data/lib/emailguard_sdk/models/list_public_team_invites_response.rb +186 -0
- data/lib/emailguard_sdk/models/list_public_team_members_response.rb +186 -0
- data/lib/emailguard_sdk/models/message_response.rb +175 -0
- data/lib/emailguard_sdk/models/notification_channel_response.rb +200 -0
- data/lib/emailguard_sdk/models/notification_rule_channel_input.rb +168 -0
- data/lib/emailguard_sdk/models/notification_rule_channel_response.rb +198 -0
- data/lib/emailguard_sdk/models/notification_rule_response.rb +224 -0
- data/lib/emailguard_sdk/models/public_team_invite_response.rb +246 -0
- data/lib/emailguard_sdk/models/public_team_member_response.rb +347 -0
- data/lib/emailguard_sdk/models/public_team_response.rb +198 -0
- data/lib/emailguard_sdk/models/update_notification_channel_input.rb +160 -0
- data/lib/emailguard_sdk/models/update_notification_rule_input.rb +204 -0
- data/lib/emailguard_sdk/models/update_team_input.rb +195 -0
- data/lib/emailguard_sdk/models/update_team_member_input.rb +185 -0
- data/lib/emailguard_sdk/version.rb +15 -0
- data/lib/emailguard_sdk.rb +78 -0
- data/spec/api/billing_api_spec.rb +49 -0
- data/spec/api/channels_api_spec.rb +95 -0
- data/spec/api/email_api_spec.rb +47 -0
- data/spec/api/events_api_spec.rb +46 -0
- data/spec/api/invites_api_spec.rb +70 -0
- data/spec/api/members_api_spec.rb +71 -0
- data/spec/api/rules_api_spec.rb +83 -0
- data/spec/api/teams_api_spec.rb +58 -0
- data/spec/models/base_response_spec.rb +42 -0
- data/spec/models/billing_usage_event_spec.rb +60 -0
- data/spec/models/billing_usage_item_spec.rb +66 -0
- data/spec/models/billing_usage_response_spec.rb +48 -0
- data/spec/models/create_notification_channel_input_spec.rb +48 -0
- data/spec/models/create_notification_rule_input_spec.rb +66 -0
- data/spec/models/email_detect_data_spec.rb +114 -0
- data/spec/models/email_detect_response_spec.rb +48 -0
- data/spec/models/get_notification_channel_response_spec.rb +48 -0
- data/spec/models/get_notification_channels_response_spec.rb +48 -0
- data/spec/models/get_notification_events_response_spec.rb +48 -0
- data/spec/models/get_notification_rules_response_spec.rb +48 -0
- data/spec/models/get_public_team_response_spec.rb +48 -0
- data/spec/models/id_data_response_spec.rb +48 -0
- data/spec/models/id_data_struct_spec.rb +36 -0
- data/spec/models/invite_team_member_input_spec.rb +42 -0
- data/spec/models/list_public_team_invites_response_spec.rb +48 -0
- data/spec/models/list_public_team_members_response_spec.rb +48 -0
- data/spec/models/message_response_spec.rb +42 -0
- data/spec/models/notification_channel_response_spec.rb +66 -0
- data/spec/models/notification_rule_channel_input_spec.rb +48 -0
- data/spec/models/notification_rule_channel_response_spec.rb +66 -0
- data/spec/models/notification_rule_response_spec.rb +78 -0
- data/spec/models/public_team_invite_response_spec.rb +54 -0
- data/spec/models/public_team_member_response_spec.rb +84 -0
- data/spec/models/public_team_response_spec.rb +66 -0
- data/spec/models/update_notification_channel_input_spec.rb +42 -0
- data/spec/models/update_notification_rule_input_spec.rb +66 -0
- data/spec/models/update_team_input_spec.rb +54 -0
- data/spec/models/update_team_member_input_spec.rb +48 -0
- data/spec/spec_helper.rb +111 -0
- metadata +251 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Emailguard::GetNotificationEventsResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **code** | **String** | Machine-readable status code (for example OK or INVALID_BODY). | |
|
|
8
|
+
| **data** | **Array<String>** | | [optional] |
|
|
9
|
+
| **message** | **String** | Human-readable detail when the code is not OK. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'emailguard_sdk'
|
|
15
|
+
|
|
16
|
+
instance = Emailguard::GetNotificationEventsResponse.new(
|
|
17
|
+
code: null,
|
|
18
|
+
data: null,
|
|
19
|
+
message: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Emailguard::GetNotificationRulesResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **code** | **String** | Machine-readable status code (for example OK or INVALID_BODY). | |
|
|
8
|
+
| **data** | [**Array<NotificationRuleResponse>**](NotificationRuleResponse.md) | | [optional] |
|
|
9
|
+
| **message** | **String** | Human-readable detail when the code is not OK. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'emailguard_sdk'
|
|
15
|
+
|
|
16
|
+
instance = Emailguard::GetNotificationRulesResponse.new(
|
|
17
|
+
code: null,
|
|
18
|
+
data: null,
|
|
19
|
+
message: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Emailguard::GetPublicTeamResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **code** | **String** | Machine-readable status code (for example OK or INVALID_BODY). | |
|
|
8
|
+
| **data** | [**PublicTeamResponse**](PublicTeamResponse.md) | | [optional] |
|
|
9
|
+
| **message** | **String** | Human-readable detail when the code is not OK. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'emailguard_sdk'
|
|
15
|
+
|
|
16
|
+
instance = Emailguard::GetPublicTeamResponse.new(
|
|
17
|
+
code: null,
|
|
18
|
+
data: null,
|
|
19
|
+
message: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Emailguard::IdDataResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **code** | **String** | Machine-readable status code (for example OK or INVALID_BODY). | |
|
|
8
|
+
| **data** | [**IdDataStruct**](IdDataStruct.md) | | [optional] |
|
|
9
|
+
| **message** | **String** | Human-readable detail when the code is not OK. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'emailguard_sdk'
|
|
15
|
+
|
|
16
|
+
instance = Emailguard::IdDataResponse.new(
|
|
17
|
+
code: null,
|
|
18
|
+
data: null,
|
|
19
|
+
message: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Emailguard::IdDataStruct
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **id** | **String** | UUID of the created or referenced record. | [optional] |
|
|
8
|
+
|
|
9
|
+
## Example
|
|
10
|
+
|
|
11
|
+
```ruby
|
|
12
|
+
require 'emailguard_sdk'
|
|
13
|
+
|
|
14
|
+
instance = Emailguard::IdDataStruct.new(
|
|
15
|
+
id: null
|
|
16
|
+
)
|
|
17
|
+
```
|
|
18
|
+
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Emailguard::InviteTeamMemberInput
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **email** | **String** | Email address that will receive the invite. | |
|
|
8
|
+
| **role** | **String** | Team role to assign when the invite is accepted (for example Owner, Admin, Member). See [Team roles and permissions](/docs/knowledge-base/team-roles-and-permissions). | |
|
|
9
|
+
|
|
10
|
+
## Example
|
|
11
|
+
|
|
12
|
+
```ruby
|
|
13
|
+
require 'emailguard_sdk'
|
|
14
|
+
|
|
15
|
+
instance = Emailguard::InviteTeamMemberInput.new(
|
|
16
|
+
email: null,
|
|
17
|
+
role: null
|
|
18
|
+
)
|
|
19
|
+
```
|
|
20
|
+
|
data/docs/InvitesApi.md
ADDED
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
# Emailguard::InvitesApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *http://api.emailguard.co*
|
|
4
|
+
|
|
5
|
+
| Method | HTTP request | Description |
|
|
6
|
+
| ------ | ------------ | ----------- |
|
|
7
|
+
| [**api_v1_team_members_invites_get**](InvitesApi.md#api_v1_team_members_invites_get) | **GET** /api/v1/team/members/invites | List pending team invites |
|
|
8
|
+
| [**api_v1_team_members_invites_invite_id_delete**](InvitesApi.md#api_v1_team_members_invites_invite_id_delete) | **DELETE** /api/v1/team/members/invites/{inviteId} | Cancel a pending invite |
|
|
9
|
+
| [**api_v1_team_members_invites_post**](InvitesApi.md#api_v1_team_members_invites_post) | **POST** /api/v1/team/members/invites | Invite a team member |
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
## api_v1_team_members_invites_get
|
|
13
|
+
|
|
14
|
+
> <ListPublicTeamInvitesResponse> api_v1_team_members_invites_get
|
|
15
|
+
|
|
16
|
+
List pending team invites
|
|
17
|
+
|
|
18
|
+
Returns invites that have not yet been accepted or expired. Each invite includes the target email, assigned role, and expiry time.
|
|
19
|
+
|
|
20
|
+
### Examples
|
|
21
|
+
|
|
22
|
+
```ruby
|
|
23
|
+
require 'time'
|
|
24
|
+
require 'emailguard_sdk'
|
|
25
|
+
# setup authorization
|
|
26
|
+
Emailguard.configure do |config|
|
|
27
|
+
# Configure API key authorization: ApiKeyAuth
|
|
28
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
29
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
|
30
|
+
# config.api_key_prefix['Authorization'] = 'Bearer'
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
api_instance = Emailguard::InvitesApi.new
|
|
34
|
+
|
|
35
|
+
begin
|
|
36
|
+
# List pending team invites
|
|
37
|
+
result = api_instance.api_v1_team_members_invites_get
|
|
38
|
+
p result
|
|
39
|
+
rescue Emailguard::ApiError => e
|
|
40
|
+
puts "Error when calling InvitesApi->api_v1_team_members_invites_get: #{e}"
|
|
41
|
+
end
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
#### Using the api_v1_team_members_invites_get_with_http_info variant
|
|
45
|
+
|
|
46
|
+
This returns an Array which contains the response data, status code and headers.
|
|
47
|
+
|
|
48
|
+
> <Array(<ListPublicTeamInvitesResponse>, Integer, Hash)> api_v1_team_members_invites_get_with_http_info
|
|
49
|
+
|
|
50
|
+
```ruby
|
|
51
|
+
begin
|
|
52
|
+
# List pending team invites
|
|
53
|
+
data, status_code, headers = api_instance.api_v1_team_members_invites_get_with_http_info
|
|
54
|
+
p status_code # => 2xx
|
|
55
|
+
p headers # => { ... }
|
|
56
|
+
p data # => <ListPublicTeamInvitesResponse>
|
|
57
|
+
rescue Emailguard::ApiError => e
|
|
58
|
+
puts "Error when calling InvitesApi->api_v1_team_members_invites_get_with_http_info: #{e}"
|
|
59
|
+
end
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### Parameters
|
|
63
|
+
|
|
64
|
+
This endpoint does not need any parameter.
|
|
65
|
+
|
|
66
|
+
### Return type
|
|
67
|
+
|
|
68
|
+
[**ListPublicTeamInvitesResponse**](ListPublicTeamInvitesResponse.md)
|
|
69
|
+
|
|
70
|
+
### Authorization
|
|
71
|
+
|
|
72
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
|
73
|
+
|
|
74
|
+
### HTTP request headers
|
|
75
|
+
|
|
76
|
+
- **Content-Type**: Not defined
|
|
77
|
+
- **Accept**: application/json
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
## api_v1_team_members_invites_invite_id_delete
|
|
81
|
+
|
|
82
|
+
> <MessageResponse> api_v1_team_members_invites_invite_id_delete(invite_id)
|
|
83
|
+
|
|
84
|
+
Cancel a pending invite
|
|
85
|
+
|
|
86
|
+
Revokes a pending invite so it can no longer be accepted. The invite is identified by its UUID from the list invites response.
|
|
87
|
+
|
|
88
|
+
### Examples
|
|
89
|
+
|
|
90
|
+
```ruby
|
|
91
|
+
require 'time'
|
|
92
|
+
require 'emailguard_sdk'
|
|
93
|
+
# setup authorization
|
|
94
|
+
Emailguard.configure do |config|
|
|
95
|
+
# Configure API key authorization: ApiKeyAuth
|
|
96
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
97
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
|
98
|
+
# config.api_key_prefix['Authorization'] = 'Bearer'
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
api_instance = Emailguard::InvitesApi.new
|
|
102
|
+
invite_id = 'invite_id_example' # String | UUID of the pending invite to cancel
|
|
103
|
+
|
|
104
|
+
begin
|
|
105
|
+
# Cancel a pending invite
|
|
106
|
+
result = api_instance.api_v1_team_members_invites_invite_id_delete(invite_id)
|
|
107
|
+
p result
|
|
108
|
+
rescue Emailguard::ApiError => e
|
|
109
|
+
puts "Error when calling InvitesApi->api_v1_team_members_invites_invite_id_delete: #{e}"
|
|
110
|
+
end
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
#### Using the api_v1_team_members_invites_invite_id_delete_with_http_info variant
|
|
114
|
+
|
|
115
|
+
This returns an Array which contains the response data, status code and headers.
|
|
116
|
+
|
|
117
|
+
> <Array(<MessageResponse>, Integer, Hash)> api_v1_team_members_invites_invite_id_delete_with_http_info(invite_id)
|
|
118
|
+
|
|
119
|
+
```ruby
|
|
120
|
+
begin
|
|
121
|
+
# Cancel a pending invite
|
|
122
|
+
data, status_code, headers = api_instance.api_v1_team_members_invites_invite_id_delete_with_http_info(invite_id)
|
|
123
|
+
p status_code # => 2xx
|
|
124
|
+
p headers # => { ... }
|
|
125
|
+
p data # => <MessageResponse>
|
|
126
|
+
rescue Emailguard::ApiError => e
|
|
127
|
+
puts "Error when calling InvitesApi->api_v1_team_members_invites_invite_id_delete_with_http_info: #{e}"
|
|
128
|
+
end
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
### Parameters
|
|
132
|
+
|
|
133
|
+
| Name | Type | Description | Notes |
|
|
134
|
+
| ---- | ---- | ----------- | ----- |
|
|
135
|
+
| **invite_id** | **String** | UUID of the pending invite to cancel | |
|
|
136
|
+
|
|
137
|
+
### Return type
|
|
138
|
+
|
|
139
|
+
[**MessageResponse**](MessageResponse.md)
|
|
140
|
+
|
|
141
|
+
### Authorization
|
|
142
|
+
|
|
143
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
|
144
|
+
|
|
145
|
+
### HTTP request headers
|
|
146
|
+
|
|
147
|
+
- **Content-Type**: Not defined
|
|
148
|
+
- **Accept**: application/json
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
## api_v1_team_members_invites_post
|
|
152
|
+
|
|
153
|
+
> <MessageResponse> api_v1_team_members_invites_post(invite_team_member_input)
|
|
154
|
+
|
|
155
|
+
Invite a team member
|
|
156
|
+
|
|
157
|
+
Sends an email invite to join the team with the specified role. The invitee must accept before they appear in the members list.
|
|
158
|
+
|
|
159
|
+
### Examples
|
|
160
|
+
|
|
161
|
+
```ruby
|
|
162
|
+
require 'time'
|
|
163
|
+
require 'emailguard_sdk'
|
|
164
|
+
# setup authorization
|
|
165
|
+
Emailguard.configure do |config|
|
|
166
|
+
# Configure API key authorization: ApiKeyAuth
|
|
167
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
168
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
|
169
|
+
# config.api_key_prefix['Authorization'] = 'Bearer'
|
|
170
|
+
end
|
|
171
|
+
|
|
172
|
+
api_instance = Emailguard::InvitesApi.new
|
|
173
|
+
invite_team_member_input = Emailguard::InviteTeamMemberInput.new({email: 'email_example', role: 'role_example'}) # InviteTeamMemberInput | Invitee email and role to assign on acceptance
|
|
174
|
+
|
|
175
|
+
begin
|
|
176
|
+
# Invite a team member
|
|
177
|
+
result = api_instance.api_v1_team_members_invites_post(invite_team_member_input)
|
|
178
|
+
p result
|
|
179
|
+
rescue Emailguard::ApiError => e
|
|
180
|
+
puts "Error when calling InvitesApi->api_v1_team_members_invites_post: #{e}"
|
|
181
|
+
end
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
#### Using the api_v1_team_members_invites_post_with_http_info variant
|
|
185
|
+
|
|
186
|
+
This returns an Array which contains the response data, status code and headers.
|
|
187
|
+
|
|
188
|
+
> <Array(<MessageResponse>, Integer, Hash)> api_v1_team_members_invites_post_with_http_info(invite_team_member_input)
|
|
189
|
+
|
|
190
|
+
```ruby
|
|
191
|
+
begin
|
|
192
|
+
# Invite a team member
|
|
193
|
+
data, status_code, headers = api_instance.api_v1_team_members_invites_post_with_http_info(invite_team_member_input)
|
|
194
|
+
p status_code # => 2xx
|
|
195
|
+
p headers # => { ... }
|
|
196
|
+
p data # => <MessageResponse>
|
|
197
|
+
rescue Emailguard::ApiError => e
|
|
198
|
+
puts "Error when calling InvitesApi->api_v1_team_members_invites_post_with_http_info: #{e}"
|
|
199
|
+
end
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
### Parameters
|
|
203
|
+
|
|
204
|
+
| Name | Type | Description | Notes |
|
|
205
|
+
| ---- | ---- | ----------- | ----- |
|
|
206
|
+
| **invite_team_member_input** | [**InviteTeamMemberInput**](InviteTeamMemberInput.md) | Invitee email and role to assign on acceptance | |
|
|
207
|
+
|
|
208
|
+
### Return type
|
|
209
|
+
|
|
210
|
+
[**MessageResponse**](MessageResponse.md)
|
|
211
|
+
|
|
212
|
+
### Authorization
|
|
213
|
+
|
|
214
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
|
215
|
+
|
|
216
|
+
### HTTP request headers
|
|
217
|
+
|
|
218
|
+
- **Content-Type**: application/json
|
|
219
|
+
- **Accept**: application/json
|
|
220
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Emailguard::ListPublicTeamInvitesResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **code** | **String** | Machine-readable status code (for example OK or INVALID_BODY). | |
|
|
8
|
+
| **data** | [**Array<PublicTeamInviteResponse>**](PublicTeamInviteResponse.md) | | [optional] |
|
|
9
|
+
| **message** | **String** | Human-readable detail when the code is not OK. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'emailguard_sdk'
|
|
15
|
+
|
|
16
|
+
instance = Emailguard::ListPublicTeamInvitesResponse.new(
|
|
17
|
+
code: null,
|
|
18
|
+
data: null,
|
|
19
|
+
message: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Emailguard::ListPublicTeamMembersResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **code** | **String** | Machine-readable status code (for example OK or INVALID_BODY). | |
|
|
8
|
+
| **data** | [**Array<PublicTeamMemberResponse>**](PublicTeamMemberResponse.md) | | [optional] |
|
|
9
|
+
| **message** | **String** | Human-readable detail when the code is not OK. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'emailguard_sdk'
|
|
15
|
+
|
|
16
|
+
instance = Emailguard::ListPublicTeamMembersResponse.new(
|
|
17
|
+
code: null,
|
|
18
|
+
data: null,
|
|
19
|
+
message: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
data/docs/MembersApi.md
ADDED
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
# Emailguard::MembersApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *http://api.emailguard.co*
|
|
4
|
+
|
|
5
|
+
| Method | HTTP request | Description |
|
|
6
|
+
| ------ | ------------ | ----------- |
|
|
7
|
+
| [**api_v1_team_members_get**](MembersApi.md#api_v1_team_members_get) | **GET** /api/v1/team/members | List team members |
|
|
8
|
+
| [**api_v1_team_members_user_id_delete**](MembersApi.md#api_v1_team_members_user_id_delete) | **DELETE** /api/v1/team/members/{userId} | Remove a team member |
|
|
9
|
+
| [**api_v1_team_members_user_id_patch**](MembersApi.md#api_v1_team_members_user_id_patch) | **PATCH** /api/v1/team/members/{userId} | Update a team member role |
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
## api_v1_team_members_get
|
|
13
|
+
|
|
14
|
+
> <ListPublicTeamMembersResponse> api_v1_team_members_get
|
|
15
|
+
|
|
16
|
+
List team members
|
|
17
|
+
|
|
18
|
+
Returns every member of the team, including role, profile fields, and join timestamp. Use the `user_id` field when calling member update or remove routes.
|
|
19
|
+
|
|
20
|
+
### Examples
|
|
21
|
+
|
|
22
|
+
```ruby
|
|
23
|
+
require 'time'
|
|
24
|
+
require 'emailguard_sdk'
|
|
25
|
+
# setup authorization
|
|
26
|
+
Emailguard.configure do |config|
|
|
27
|
+
# Configure API key authorization: ApiKeyAuth
|
|
28
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
29
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
|
30
|
+
# config.api_key_prefix['Authorization'] = 'Bearer'
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
api_instance = Emailguard::MembersApi.new
|
|
34
|
+
|
|
35
|
+
begin
|
|
36
|
+
# List team members
|
|
37
|
+
result = api_instance.api_v1_team_members_get
|
|
38
|
+
p result
|
|
39
|
+
rescue Emailguard::ApiError => e
|
|
40
|
+
puts "Error when calling MembersApi->api_v1_team_members_get: #{e}"
|
|
41
|
+
end
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
#### Using the api_v1_team_members_get_with_http_info variant
|
|
45
|
+
|
|
46
|
+
This returns an Array which contains the response data, status code and headers.
|
|
47
|
+
|
|
48
|
+
> <Array(<ListPublicTeamMembersResponse>, Integer, Hash)> api_v1_team_members_get_with_http_info
|
|
49
|
+
|
|
50
|
+
```ruby
|
|
51
|
+
begin
|
|
52
|
+
# List team members
|
|
53
|
+
data, status_code, headers = api_instance.api_v1_team_members_get_with_http_info
|
|
54
|
+
p status_code # => 2xx
|
|
55
|
+
p headers # => { ... }
|
|
56
|
+
p data # => <ListPublicTeamMembersResponse>
|
|
57
|
+
rescue Emailguard::ApiError => e
|
|
58
|
+
puts "Error when calling MembersApi->api_v1_team_members_get_with_http_info: #{e}"
|
|
59
|
+
end
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### Parameters
|
|
63
|
+
|
|
64
|
+
This endpoint does not need any parameter.
|
|
65
|
+
|
|
66
|
+
### Return type
|
|
67
|
+
|
|
68
|
+
[**ListPublicTeamMembersResponse**](ListPublicTeamMembersResponse.md)
|
|
69
|
+
|
|
70
|
+
### Authorization
|
|
71
|
+
|
|
72
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
|
73
|
+
|
|
74
|
+
### HTTP request headers
|
|
75
|
+
|
|
76
|
+
- **Content-Type**: Not defined
|
|
77
|
+
- **Accept**: application/json
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
## api_v1_team_members_user_id_delete
|
|
81
|
+
|
|
82
|
+
> <MessageResponse> api_v1_team_members_user_id_delete(user_id)
|
|
83
|
+
|
|
84
|
+
Remove a team member
|
|
85
|
+
|
|
86
|
+
Removes a user from the team. Identify the member by user account UUID in the path. The team owner cannot be removed through this endpoint.
|
|
87
|
+
|
|
88
|
+
### Examples
|
|
89
|
+
|
|
90
|
+
```ruby
|
|
91
|
+
require 'time'
|
|
92
|
+
require 'emailguard_sdk'
|
|
93
|
+
# setup authorization
|
|
94
|
+
Emailguard.configure do |config|
|
|
95
|
+
# Configure API key authorization: ApiKeyAuth
|
|
96
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
97
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
|
98
|
+
# config.api_key_prefix['Authorization'] = 'Bearer'
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
api_instance = Emailguard::MembersApi.new
|
|
102
|
+
user_id = 'user_id_example' # String | User account UUID of the member to remove
|
|
103
|
+
|
|
104
|
+
begin
|
|
105
|
+
# Remove a team member
|
|
106
|
+
result = api_instance.api_v1_team_members_user_id_delete(user_id)
|
|
107
|
+
p result
|
|
108
|
+
rescue Emailguard::ApiError => e
|
|
109
|
+
puts "Error when calling MembersApi->api_v1_team_members_user_id_delete: #{e}"
|
|
110
|
+
end
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
#### Using the api_v1_team_members_user_id_delete_with_http_info variant
|
|
114
|
+
|
|
115
|
+
This returns an Array which contains the response data, status code and headers.
|
|
116
|
+
|
|
117
|
+
> <Array(<MessageResponse>, Integer, Hash)> api_v1_team_members_user_id_delete_with_http_info(user_id)
|
|
118
|
+
|
|
119
|
+
```ruby
|
|
120
|
+
begin
|
|
121
|
+
# Remove a team member
|
|
122
|
+
data, status_code, headers = api_instance.api_v1_team_members_user_id_delete_with_http_info(user_id)
|
|
123
|
+
p status_code # => 2xx
|
|
124
|
+
p headers # => { ... }
|
|
125
|
+
p data # => <MessageResponse>
|
|
126
|
+
rescue Emailguard::ApiError => e
|
|
127
|
+
puts "Error when calling MembersApi->api_v1_team_members_user_id_delete_with_http_info: #{e}"
|
|
128
|
+
end
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
### Parameters
|
|
132
|
+
|
|
133
|
+
| Name | Type | Description | Notes |
|
|
134
|
+
| ---- | ---- | ----------- | ----- |
|
|
135
|
+
| **user_id** | **String** | User account UUID of the member to remove | |
|
|
136
|
+
|
|
137
|
+
### Return type
|
|
138
|
+
|
|
139
|
+
[**MessageResponse**](MessageResponse.md)
|
|
140
|
+
|
|
141
|
+
### Authorization
|
|
142
|
+
|
|
143
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
|
144
|
+
|
|
145
|
+
### HTTP request headers
|
|
146
|
+
|
|
147
|
+
- **Content-Type**: Not defined
|
|
148
|
+
- **Accept**: application/json
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
## api_v1_team_members_user_id_patch
|
|
152
|
+
|
|
153
|
+
> <MessageResponse> api_v1_team_members_user_id_patch(user_id, update_team_member_input)
|
|
154
|
+
|
|
155
|
+
Update a team member role
|
|
156
|
+
|
|
157
|
+
Changes a member's role or internal notes. Identify the member by user account UUID in the path (not the team membership record ID).
|
|
158
|
+
|
|
159
|
+
### Examples
|
|
160
|
+
|
|
161
|
+
```ruby
|
|
162
|
+
require 'time'
|
|
163
|
+
require 'emailguard_sdk'
|
|
164
|
+
# setup authorization
|
|
165
|
+
Emailguard.configure do |config|
|
|
166
|
+
# Configure API key authorization: ApiKeyAuth
|
|
167
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
168
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
|
169
|
+
# config.api_key_prefix['Authorization'] = 'Bearer'
|
|
170
|
+
end
|
|
171
|
+
|
|
172
|
+
api_instance = Emailguard::MembersApi.new
|
|
173
|
+
user_id = 'user_id_example' # String | User account UUID of the member to update
|
|
174
|
+
update_team_member_input = Emailguard::UpdateTeamMemberInput.new({id: 'id_example'}) # UpdateTeamMemberInput | New role and/or notes for the member
|
|
175
|
+
|
|
176
|
+
begin
|
|
177
|
+
# Update a team member role
|
|
178
|
+
result = api_instance.api_v1_team_members_user_id_patch(user_id, update_team_member_input)
|
|
179
|
+
p result
|
|
180
|
+
rescue Emailguard::ApiError => e
|
|
181
|
+
puts "Error when calling MembersApi->api_v1_team_members_user_id_patch: #{e}"
|
|
182
|
+
end
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
#### Using the api_v1_team_members_user_id_patch_with_http_info variant
|
|
186
|
+
|
|
187
|
+
This returns an Array which contains the response data, status code and headers.
|
|
188
|
+
|
|
189
|
+
> <Array(<MessageResponse>, Integer, Hash)> api_v1_team_members_user_id_patch_with_http_info(user_id, update_team_member_input)
|
|
190
|
+
|
|
191
|
+
```ruby
|
|
192
|
+
begin
|
|
193
|
+
# Update a team member role
|
|
194
|
+
data, status_code, headers = api_instance.api_v1_team_members_user_id_patch_with_http_info(user_id, update_team_member_input)
|
|
195
|
+
p status_code # => 2xx
|
|
196
|
+
p headers # => { ... }
|
|
197
|
+
p data # => <MessageResponse>
|
|
198
|
+
rescue Emailguard::ApiError => e
|
|
199
|
+
puts "Error when calling MembersApi->api_v1_team_members_user_id_patch_with_http_info: #{e}"
|
|
200
|
+
end
|
|
201
|
+
```
|
|
202
|
+
|
|
203
|
+
### Parameters
|
|
204
|
+
|
|
205
|
+
| Name | Type | Description | Notes |
|
|
206
|
+
| ---- | ---- | ----------- | ----- |
|
|
207
|
+
| **user_id** | **String** | User account UUID of the member to update | |
|
|
208
|
+
| **update_team_member_input** | [**UpdateTeamMemberInput**](UpdateTeamMemberInput.md) | New role and/or notes for the member | |
|
|
209
|
+
|
|
210
|
+
### Return type
|
|
211
|
+
|
|
212
|
+
[**MessageResponse**](MessageResponse.md)
|
|
213
|
+
|
|
214
|
+
### Authorization
|
|
215
|
+
|
|
216
|
+
[ApiKeyAuth](../README.md#ApiKeyAuth)
|
|
217
|
+
|
|
218
|
+
### HTTP request headers
|
|
219
|
+
|
|
220
|
+
- **Content-Type**: application/json
|
|
221
|
+
- **Accept**: application/json
|
|
222
|
+
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Emailguard::MessageResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **code** | **String** | Machine-readable status code (for example OK or INVALID_BODY). | |
|
|
8
|
+
| **message** | **String** | Human-readable detail when the code is not OK. | [optional] |
|
|
9
|
+
|
|
10
|
+
## Example
|
|
11
|
+
|
|
12
|
+
```ruby
|
|
13
|
+
require 'emailguard_sdk'
|
|
14
|
+
|
|
15
|
+
instance = Emailguard::MessageResponse.new(
|
|
16
|
+
code: null,
|
|
17
|
+
message: null
|
|
18
|
+
)
|
|
19
|
+
```
|
|
20
|
+
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# Emailguard::NotificationChannelResponse
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **config** | **Hash<String, Object>** | Type-specific configuration. Sensitive values may be redacted in responses. | [optional] |
|
|
8
|
+
| **created_at** | **String** | When the channel was created (RFC3339). | [optional] |
|
|
9
|
+
| **id** | **String** | Channel record ID. | [optional] |
|
|
10
|
+
| **is_verified** | **Boolean** | Whether the channel has completed verification (email link or webhook test). | [optional] |
|
|
11
|
+
| **name** | **String** | Display name in notification settings. | [optional] |
|
|
12
|
+
| **type** | **String** | Channel type (for example email or webhook). | [optional] |
|
|
13
|
+
|
|
14
|
+
## Example
|
|
15
|
+
|
|
16
|
+
```ruby
|
|
17
|
+
require 'emailguard_sdk'
|
|
18
|
+
|
|
19
|
+
instance = Emailguard::NotificationChannelResponse.new(
|
|
20
|
+
config: null,
|
|
21
|
+
created_at: null,
|
|
22
|
+
id: null,
|
|
23
|
+
is_verified: null,
|
|
24
|
+
name: null,
|
|
25
|
+
type: null
|
|
26
|
+
)
|
|
27
|
+
```
|
|
28
|
+
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Emailguard::NotificationRuleChannelInput
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **channel_id** | **String** | UUID of a team notification channel. Use this or predefined, not both. | [optional] |
|
|
8
|
+
| **predefined** | **String** | Built-in channel identifier when not using a custom channel. | [optional] |
|
|
9
|
+
| **target_user_id** | **String** | Restrict delivery to a specific team member's user ID. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'emailguard_sdk'
|
|
15
|
+
|
|
16
|
+
instance = Emailguard::NotificationRuleChannelInput.new(
|
|
17
|
+
channel_id: null,
|
|
18
|
+
predefined: null,
|
|
19
|
+
target_user_id: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|