pingram 1.0.1 → 1.0.3
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 +4 -4
- data/Gemfile.lock +1 -1
- data/lib/pingram/api/account_api.rb +55 -0
- data/lib/pingram/api/organization_api.rb +146 -0
- data/lib/pingram/api/push_settings_api.rb +370 -0
- data/lib/pingram/api/webhooks_api.rb +196 -0
- data/lib/pingram/api_client.rb +1 -1
- data/lib/pingram/client_wrapper.rb +30 -0
- data/lib/pingram/models/account_get_response.rb +15 -92
- data/lib/pingram/models/apn_config.rb +242 -0
- data/lib/pingram/models/billing_post_request_body.rb +18 -24
- data/lib/pingram/models/billing_post_response_body.rb +285 -63
- data/lib/pingram/models/events_webhook_response.rb +234 -0
- data/lib/pingram/models/events_webhook_upsert_request.rb +207 -0
- data/lib/pingram/models/{account_get_response_pending_downgrade_usage_limit.rb → get_usage_history_query.rb} +53 -61
- data/lib/pingram/models/logs_get_response_logs_inner.rb +76 -1
- data/lib/pingram/models/organization.rb +590 -0
- data/lib/pingram/models/organization_usage.rb +330 -0
- data/lib/pingram/models/{billing_post_response_body_pending_downgrade_usage_limit.rb → organization_usage_history.rb} +31 -65
- data/lib/pingram/models/organization_usage_history_items_inner.rb +303 -0
- data/lib/pingram/models/push_settings_fcm_put_request.rb +164 -0
- data/lib/pingram/models/push_settings_fcm_response.rb +164 -0
- data/lib/pingram/version.rb +1 -1
- data/lib/pingram.rb +13 -2
- metadata +15 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: bc6660f67916fa675695a13305efe810001d1df21c9e285337469d43a3dde6ec
|
|
4
|
+
data.tar.gz: d524333c31763799b4d4c616631e8e17e7302015e067af9e58b4a72131f61722
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: dce1a3f9e59d7157beec155a7e4ec1a96620caec8b6b9d7d14cc32892ba1f5c01c0a405bd5c3870c16d4a26f50d30bb2f51946f7b3b4dc4e82389c9a27554a29
|
|
7
|
+
data.tar.gz: b4498c54781244db68765030f4865c77a9b3ce840e33cd4d9f492d740b41ccc4b6d2373a2fe898ef25885e6e12393b56de949449aaf2a873680b5d3a754611c1
|
data/Gemfile.lock
CHANGED
|
@@ -140,6 +140,61 @@ module Pingram
|
|
|
140
140
|
return data, status_code, headers
|
|
141
141
|
end
|
|
142
142
|
|
|
143
|
+
# Get organization for the authenticated account (new billing model).
|
|
144
|
+
# @param [Hash] opts the optional parameters
|
|
145
|
+
# @return [Organization]
|
|
146
|
+
def account_get_organization(opts = {})
|
|
147
|
+
data, _status_code, _headers = account_get_organization_with_http_info(opts)
|
|
148
|
+
data
|
|
149
|
+
end
|
|
150
|
+
|
|
151
|
+
# Get organization for the authenticated account (new billing model).
|
|
152
|
+
# @param [Hash] opts the optional parameters
|
|
153
|
+
# @return [Array<(Organization, Integer, Hash)>] Organization data, response status code and response headers
|
|
154
|
+
def account_get_organization_with_http_info(opts = {})
|
|
155
|
+
if @api_client.config.debugging
|
|
156
|
+
@api_client.config.logger.debug 'Calling API: AccountApi.account_get_organization ...'
|
|
157
|
+
end
|
|
158
|
+
# resource path
|
|
159
|
+
local_var_path = '/account/organization'
|
|
160
|
+
|
|
161
|
+
# query parameters
|
|
162
|
+
query_params = opts[:query_params] || {}
|
|
163
|
+
|
|
164
|
+
# header parameters
|
|
165
|
+
header_params = opts[:header_params] || {}
|
|
166
|
+
# HTTP header 'Accept' (if needed)
|
|
167
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
168
|
+
|
|
169
|
+
# form parameters
|
|
170
|
+
form_params = opts[:form_params] || {}
|
|
171
|
+
|
|
172
|
+
# http body (model)
|
|
173
|
+
post_body = opts[:debug_body]
|
|
174
|
+
|
|
175
|
+
# return_type
|
|
176
|
+
return_type = opts[:debug_return_type] || 'Organization'
|
|
177
|
+
|
|
178
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
179
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
180
|
+
|
|
181
|
+
new_options = opts.merge(
|
|
182
|
+
:operation => :"AccountApi.account_get_organization",
|
|
183
|
+
:header_params => header_params,
|
|
184
|
+
:query_params => query_params,
|
|
185
|
+
:form_params => form_params,
|
|
186
|
+
:body => post_body,
|
|
187
|
+
:auth_names => auth_names,
|
|
188
|
+
:return_type => return_type
|
|
189
|
+
)
|
|
190
|
+
|
|
191
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
192
|
+
if @api_client.config.debugging
|
|
193
|
+
@api_client.config.logger.debug "API called: AccountApi#account_get_organization\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
194
|
+
end
|
|
195
|
+
return data, status_code, headers
|
|
196
|
+
end
|
|
197
|
+
|
|
143
198
|
# Get Supabase integration status for the account
|
|
144
199
|
# @param [Hash] opts the optional parameters
|
|
145
200
|
# @return [SupabaseStatusResponse]
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Pingram
|
|
3
|
+
|
|
4
|
+
#Internal API for notification delivery and management
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.19.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'cgi'
|
|
14
|
+
|
|
15
|
+
module Pingram
|
|
16
|
+
class OrganizationApi
|
|
17
|
+
attr_accessor :api_client
|
|
18
|
+
|
|
19
|
+
def initialize(api_client = ApiClient.default)
|
|
20
|
+
@api_client = api_client
|
|
21
|
+
end
|
|
22
|
+
# Get usage for the authenticated account's organization (new billing model).
|
|
23
|
+
# @param [Hash] opts the optional parameters
|
|
24
|
+
# @return [OrganizationUsage]
|
|
25
|
+
def organization_get_usage(opts = {})
|
|
26
|
+
data, _status_code, _headers = organization_get_usage_with_http_info(opts)
|
|
27
|
+
data
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
# Get usage for the authenticated account's organization (new billing model).
|
|
31
|
+
# @param [Hash] opts the optional parameters
|
|
32
|
+
# @return [Array<(OrganizationUsage, Integer, Hash)>] OrganizationUsage data, response status code and response headers
|
|
33
|
+
def organization_get_usage_with_http_info(opts = {})
|
|
34
|
+
if @api_client.config.debugging
|
|
35
|
+
@api_client.config.logger.debug 'Calling API: OrganizationApi.organization_get_usage ...'
|
|
36
|
+
end
|
|
37
|
+
# resource path
|
|
38
|
+
local_var_path = '/organization/usage'
|
|
39
|
+
|
|
40
|
+
# query parameters
|
|
41
|
+
query_params = opts[:query_params] || {}
|
|
42
|
+
|
|
43
|
+
# header parameters
|
|
44
|
+
header_params = opts[:header_params] || {}
|
|
45
|
+
# HTTP header 'Accept' (if needed)
|
|
46
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
47
|
+
|
|
48
|
+
# form parameters
|
|
49
|
+
form_params = opts[:form_params] || {}
|
|
50
|
+
|
|
51
|
+
# http body (model)
|
|
52
|
+
post_body = opts[:debug_body]
|
|
53
|
+
|
|
54
|
+
# return_type
|
|
55
|
+
return_type = opts[:debug_return_type] || 'OrganizationUsage'
|
|
56
|
+
|
|
57
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
58
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
59
|
+
|
|
60
|
+
new_options = opts.merge(
|
|
61
|
+
:operation => :"OrganizationApi.organization_get_usage",
|
|
62
|
+
:header_params => header_params,
|
|
63
|
+
:query_params => query_params,
|
|
64
|
+
:form_params => form_params,
|
|
65
|
+
:body => post_body,
|
|
66
|
+
:auth_names => auth_names,
|
|
67
|
+
:return_type => return_type
|
|
68
|
+
)
|
|
69
|
+
|
|
70
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
71
|
+
if @api_client.config.debugging
|
|
72
|
+
@api_client.config.logger.debug "API called: OrganizationApi#organization_get_usage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
73
|
+
end
|
|
74
|
+
return data, status_code, headers
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
# Get historical usage for the authenticated account's organization over a date range.
|
|
78
|
+
# @param start_date [String] Start date (YYYY-MM-DD) for the range
|
|
79
|
+
# @param end_date [String] End date (YYYY-MM-DD) for the range
|
|
80
|
+
# @param [Hash] opts the optional parameters
|
|
81
|
+
# @return [OrganizationUsageHistory]
|
|
82
|
+
def organization_get_usage_history(start_date, end_date, opts = {})
|
|
83
|
+
data, _status_code, _headers = organization_get_usage_history_with_http_info(start_date, end_date, opts)
|
|
84
|
+
data
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
# Get historical usage for the authenticated account's organization over a date range.
|
|
88
|
+
# @param start_date [String] Start date (YYYY-MM-DD) for the range
|
|
89
|
+
# @param end_date [String] End date (YYYY-MM-DD) for the range
|
|
90
|
+
# @param [Hash] opts the optional parameters
|
|
91
|
+
# @return [Array<(OrganizationUsageHistory, Integer, Hash)>] OrganizationUsageHistory data, response status code and response headers
|
|
92
|
+
def organization_get_usage_history_with_http_info(start_date, end_date, opts = {})
|
|
93
|
+
if @api_client.config.debugging
|
|
94
|
+
@api_client.config.logger.debug 'Calling API: OrganizationApi.organization_get_usage_history ...'
|
|
95
|
+
end
|
|
96
|
+
# verify the required parameter 'start_date' is set
|
|
97
|
+
if @api_client.config.client_side_validation && start_date.nil?
|
|
98
|
+
fail ArgumentError, "Missing the required parameter 'start_date' when calling OrganizationApi.organization_get_usage_history"
|
|
99
|
+
end
|
|
100
|
+
# verify the required parameter 'end_date' is set
|
|
101
|
+
if @api_client.config.client_side_validation && end_date.nil?
|
|
102
|
+
fail ArgumentError, "Missing the required parameter 'end_date' when calling OrganizationApi.organization_get_usage_history"
|
|
103
|
+
end
|
|
104
|
+
# resource path
|
|
105
|
+
local_var_path = '/organization/usage/history'
|
|
106
|
+
|
|
107
|
+
# query parameters
|
|
108
|
+
query_params = opts[:query_params] || {}
|
|
109
|
+
query_params[:'startDate'] = start_date
|
|
110
|
+
query_params[:'endDate'] = end_date
|
|
111
|
+
|
|
112
|
+
# header parameters
|
|
113
|
+
header_params = opts[:header_params] || {}
|
|
114
|
+
# HTTP header 'Accept' (if needed)
|
|
115
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
116
|
+
|
|
117
|
+
# form parameters
|
|
118
|
+
form_params = opts[:form_params] || {}
|
|
119
|
+
|
|
120
|
+
# http body (model)
|
|
121
|
+
post_body = opts[:debug_body]
|
|
122
|
+
|
|
123
|
+
# return_type
|
|
124
|
+
return_type = opts[:debug_return_type] || 'OrganizationUsageHistory'
|
|
125
|
+
|
|
126
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
127
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
128
|
+
|
|
129
|
+
new_options = opts.merge(
|
|
130
|
+
:operation => :"OrganizationApi.organization_get_usage_history",
|
|
131
|
+
:header_params => header_params,
|
|
132
|
+
:query_params => query_params,
|
|
133
|
+
:form_params => form_params,
|
|
134
|
+
:body => post_body,
|
|
135
|
+
:auth_names => auth_names,
|
|
136
|
+
:return_type => return_type
|
|
137
|
+
)
|
|
138
|
+
|
|
139
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
140
|
+
if @api_client.config.debugging
|
|
141
|
+
@api_client.config.logger.debug "API called: OrganizationApi#organization_get_usage_history\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
142
|
+
end
|
|
143
|
+
return data, status_code, headers
|
|
144
|
+
end
|
|
145
|
+
end
|
|
146
|
+
end
|
|
@@ -0,0 +1,370 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Pingram
|
|
3
|
+
|
|
4
|
+
#Internal API for notification delivery and management
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.19.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'cgi'
|
|
14
|
+
|
|
15
|
+
module Pingram
|
|
16
|
+
class PushSettingsApi
|
|
17
|
+
attr_accessor :api_client
|
|
18
|
+
|
|
19
|
+
def initialize(api_client = ApiClient.default)
|
|
20
|
+
@api_client = api_client
|
|
21
|
+
end
|
|
22
|
+
# Delete Apple Push Notification (APN) configuration for the current account.
|
|
23
|
+
# @param [Hash] opts the optional parameters
|
|
24
|
+
# @return [nil]
|
|
25
|
+
def push_settings_delete_push_apn_settings(opts = {})
|
|
26
|
+
push_settings_delete_push_apn_settings_with_http_info(opts)
|
|
27
|
+
nil
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
# Delete Apple Push Notification (APN) configuration for the current account.
|
|
31
|
+
# @param [Hash] opts the optional parameters
|
|
32
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
33
|
+
def push_settings_delete_push_apn_settings_with_http_info(opts = {})
|
|
34
|
+
if @api_client.config.debugging
|
|
35
|
+
@api_client.config.logger.debug 'Calling API: PushSettingsApi.push_settings_delete_push_apn_settings ...'
|
|
36
|
+
end
|
|
37
|
+
# resource path
|
|
38
|
+
local_var_path = '/settings/push/apn'
|
|
39
|
+
|
|
40
|
+
# query parameters
|
|
41
|
+
query_params = opts[:query_params] || {}
|
|
42
|
+
|
|
43
|
+
# header parameters
|
|
44
|
+
header_params = opts[:header_params] || {}
|
|
45
|
+
|
|
46
|
+
# form parameters
|
|
47
|
+
form_params = opts[:form_params] || {}
|
|
48
|
+
|
|
49
|
+
# http body (model)
|
|
50
|
+
post_body = opts[:debug_body]
|
|
51
|
+
|
|
52
|
+
# return_type
|
|
53
|
+
return_type = opts[:debug_return_type]
|
|
54
|
+
|
|
55
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
56
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
57
|
+
|
|
58
|
+
new_options = opts.merge(
|
|
59
|
+
:operation => :"PushSettingsApi.push_settings_delete_push_apn_settings",
|
|
60
|
+
:header_params => header_params,
|
|
61
|
+
:query_params => query_params,
|
|
62
|
+
:form_params => form_params,
|
|
63
|
+
:body => post_body,
|
|
64
|
+
:auth_names => auth_names,
|
|
65
|
+
:return_type => return_type
|
|
66
|
+
)
|
|
67
|
+
|
|
68
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
69
|
+
if @api_client.config.debugging
|
|
70
|
+
@api_client.config.logger.debug "API called: PushSettingsApi#push_settings_delete_push_apn_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
71
|
+
end
|
|
72
|
+
return data, status_code, headers
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
# Delete Firebase Cloud Messaging (FCM) configuration for the current account.
|
|
76
|
+
# @param [Hash] opts the optional parameters
|
|
77
|
+
# @return [nil]
|
|
78
|
+
def push_settings_delete_push_fcm_settings(opts = {})
|
|
79
|
+
push_settings_delete_push_fcm_settings_with_http_info(opts)
|
|
80
|
+
nil
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
# Delete Firebase Cloud Messaging (FCM) configuration for the current account.
|
|
84
|
+
# @param [Hash] opts the optional parameters
|
|
85
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
86
|
+
def push_settings_delete_push_fcm_settings_with_http_info(opts = {})
|
|
87
|
+
if @api_client.config.debugging
|
|
88
|
+
@api_client.config.logger.debug 'Calling API: PushSettingsApi.push_settings_delete_push_fcm_settings ...'
|
|
89
|
+
end
|
|
90
|
+
# resource path
|
|
91
|
+
local_var_path = '/settings/push/fcm'
|
|
92
|
+
|
|
93
|
+
# query parameters
|
|
94
|
+
query_params = opts[:query_params] || {}
|
|
95
|
+
|
|
96
|
+
# header parameters
|
|
97
|
+
header_params = opts[:header_params] || {}
|
|
98
|
+
|
|
99
|
+
# form parameters
|
|
100
|
+
form_params = opts[:form_params] || {}
|
|
101
|
+
|
|
102
|
+
# http body (model)
|
|
103
|
+
post_body = opts[:debug_body]
|
|
104
|
+
|
|
105
|
+
# return_type
|
|
106
|
+
return_type = opts[:debug_return_type]
|
|
107
|
+
|
|
108
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
109
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
110
|
+
|
|
111
|
+
new_options = opts.merge(
|
|
112
|
+
:operation => :"PushSettingsApi.push_settings_delete_push_fcm_settings",
|
|
113
|
+
:header_params => header_params,
|
|
114
|
+
:query_params => query_params,
|
|
115
|
+
:form_params => form_params,
|
|
116
|
+
:body => post_body,
|
|
117
|
+
:auth_names => auth_names,
|
|
118
|
+
:return_type => return_type
|
|
119
|
+
)
|
|
120
|
+
|
|
121
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
122
|
+
if @api_client.config.debugging
|
|
123
|
+
@api_client.config.logger.debug "API called: PushSettingsApi#push_settings_delete_push_fcm_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
124
|
+
end
|
|
125
|
+
return data, status_code, headers
|
|
126
|
+
end
|
|
127
|
+
|
|
128
|
+
# Get Apple Push Notification (APN) configuration for the current account.
|
|
129
|
+
# @param [Hash] opts the optional parameters
|
|
130
|
+
# @return [APNConfig]
|
|
131
|
+
def push_settings_get_push_apn_settings(opts = {})
|
|
132
|
+
data, _status_code, _headers = push_settings_get_push_apn_settings_with_http_info(opts)
|
|
133
|
+
data
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
# Get Apple Push Notification (APN) configuration for the current account.
|
|
137
|
+
# @param [Hash] opts the optional parameters
|
|
138
|
+
# @return [Array<(APNConfig, Integer, Hash)>] APNConfig data, response status code and response headers
|
|
139
|
+
def push_settings_get_push_apn_settings_with_http_info(opts = {})
|
|
140
|
+
if @api_client.config.debugging
|
|
141
|
+
@api_client.config.logger.debug 'Calling API: PushSettingsApi.push_settings_get_push_apn_settings ...'
|
|
142
|
+
end
|
|
143
|
+
# resource path
|
|
144
|
+
local_var_path = '/settings/push/apn'
|
|
145
|
+
|
|
146
|
+
# query parameters
|
|
147
|
+
query_params = opts[:query_params] || {}
|
|
148
|
+
|
|
149
|
+
# header parameters
|
|
150
|
+
header_params = opts[:header_params] || {}
|
|
151
|
+
# HTTP header 'Accept' (if needed)
|
|
152
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
153
|
+
|
|
154
|
+
# form parameters
|
|
155
|
+
form_params = opts[:form_params] || {}
|
|
156
|
+
|
|
157
|
+
# http body (model)
|
|
158
|
+
post_body = opts[:debug_body]
|
|
159
|
+
|
|
160
|
+
# return_type
|
|
161
|
+
return_type = opts[:debug_return_type] || 'APNConfig'
|
|
162
|
+
|
|
163
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
164
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
165
|
+
|
|
166
|
+
new_options = opts.merge(
|
|
167
|
+
:operation => :"PushSettingsApi.push_settings_get_push_apn_settings",
|
|
168
|
+
:header_params => header_params,
|
|
169
|
+
:query_params => query_params,
|
|
170
|
+
:form_params => form_params,
|
|
171
|
+
:body => post_body,
|
|
172
|
+
:auth_names => auth_names,
|
|
173
|
+
:return_type => return_type
|
|
174
|
+
)
|
|
175
|
+
|
|
176
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
177
|
+
if @api_client.config.debugging
|
|
178
|
+
@api_client.config.logger.debug "API called: PushSettingsApi#push_settings_get_push_apn_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
179
|
+
end
|
|
180
|
+
return data, status_code, headers
|
|
181
|
+
end
|
|
182
|
+
|
|
183
|
+
# Get Firebase Cloud Messaging (FCM) configuration for the current account.
|
|
184
|
+
# @param [Hash] opts the optional parameters
|
|
185
|
+
# @return [PushSettingsFCMResponse]
|
|
186
|
+
def push_settings_get_push_fcm_settings(opts = {})
|
|
187
|
+
data, _status_code, _headers = push_settings_get_push_fcm_settings_with_http_info(opts)
|
|
188
|
+
data
|
|
189
|
+
end
|
|
190
|
+
|
|
191
|
+
# Get Firebase Cloud Messaging (FCM) configuration for the current account.
|
|
192
|
+
# @param [Hash] opts the optional parameters
|
|
193
|
+
# @return [Array<(PushSettingsFCMResponse, Integer, Hash)>] PushSettingsFCMResponse data, response status code and response headers
|
|
194
|
+
def push_settings_get_push_fcm_settings_with_http_info(opts = {})
|
|
195
|
+
if @api_client.config.debugging
|
|
196
|
+
@api_client.config.logger.debug 'Calling API: PushSettingsApi.push_settings_get_push_fcm_settings ...'
|
|
197
|
+
end
|
|
198
|
+
# resource path
|
|
199
|
+
local_var_path = '/settings/push/fcm'
|
|
200
|
+
|
|
201
|
+
# query parameters
|
|
202
|
+
query_params = opts[:query_params] || {}
|
|
203
|
+
|
|
204
|
+
# header parameters
|
|
205
|
+
header_params = opts[:header_params] || {}
|
|
206
|
+
# HTTP header 'Accept' (if needed)
|
|
207
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
208
|
+
|
|
209
|
+
# form parameters
|
|
210
|
+
form_params = opts[:form_params] || {}
|
|
211
|
+
|
|
212
|
+
# http body (model)
|
|
213
|
+
post_body = opts[:debug_body]
|
|
214
|
+
|
|
215
|
+
# return_type
|
|
216
|
+
return_type = opts[:debug_return_type] || 'PushSettingsFCMResponse'
|
|
217
|
+
|
|
218
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
219
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
220
|
+
|
|
221
|
+
new_options = opts.merge(
|
|
222
|
+
:operation => :"PushSettingsApi.push_settings_get_push_fcm_settings",
|
|
223
|
+
:header_params => header_params,
|
|
224
|
+
:query_params => query_params,
|
|
225
|
+
:form_params => form_params,
|
|
226
|
+
:body => post_body,
|
|
227
|
+
:auth_names => auth_names,
|
|
228
|
+
:return_type => return_type
|
|
229
|
+
)
|
|
230
|
+
|
|
231
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
232
|
+
if @api_client.config.debugging
|
|
233
|
+
@api_client.config.logger.debug "API called: PushSettingsApi#push_settings_get_push_fcm_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
234
|
+
end
|
|
235
|
+
return data, status_code, headers
|
|
236
|
+
end
|
|
237
|
+
|
|
238
|
+
# Create or update Apple Push Notification (APN) configuration for the current account.
|
|
239
|
+
# @param apn_config [APNConfig]
|
|
240
|
+
# @param [Hash] opts the optional parameters
|
|
241
|
+
# @return [APNConfig]
|
|
242
|
+
def push_settings_upsert_push_apn_settings(apn_config, opts = {})
|
|
243
|
+
data, _status_code, _headers = push_settings_upsert_push_apn_settings_with_http_info(apn_config, opts)
|
|
244
|
+
data
|
|
245
|
+
end
|
|
246
|
+
|
|
247
|
+
# Create or update Apple Push Notification (APN) configuration for the current account.
|
|
248
|
+
# @param apn_config [APNConfig]
|
|
249
|
+
# @param [Hash] opts the optional parameters
|
|
250
|
+
# @return [Array<(APNConfig, Integer, Hash)>] APNConfig data, response status code and response headers
|
|
251
|
+
def push_settings_upsert_push_apn_settings_with_http_info(apn_config, opts = {})
|
|
252
|
+
if @api_client.config.debugging
|
|
253
|
+
@api_client.config.logger.debug 'Calling API: PushSettingsApi.push_settings_upsert_push_apn_settings ...'
|
|
254
|
+
end
|
|
255
|
+
# verify the required parameter 'apn_config' is set
|
|
256
|
+
if @api_client.config.client_side_validation && apn_config.nil?
|
|
257
|
+
fail ArgumentError, "Missing the required parameter 'apn_config' when calling PushSettingsApi.push_settings_upsert_push_apn_settings"
|
|
258
|
+
end
|
|
259
|
+
# resource path
|
|
260
|
+
local_var_path = '/settings/push/apn'
|
|
261
|
+
|
|
262
|
+
# query parameters
|
|
263
|
+
query_params = opts[:query_params] || {}
|
|
264
|
+
|
|
265
|
+
# header parameters
|
|
266
|
+
header_params = opts[:header_params] || {}
|
|
267
|
+
# HTTP header 'Accept' (if needed)
|
|
268
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
269
|
+
# HTTP header 'Content-Type'
|
|
270
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
271
|
+
if !content_type.nil?
|
|
272
|
+
header_params['Content-Type'] = content_type
|
|
273
|
+
end
|
|
274
|
+
|
|
275
|
+
# form parameters
|
|
276
|
+
form_params = opts[:form_params] || {}
|
|
277
|
+
|
|
278
|
+
# http body (model)
|
|
279
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(apn_config)
|
|
280
|
+
|
|
281
|
+
# return_type
|
|
282
|
+
return_type = opts[:debug_return_type] || 'APNConfig'
|
|
283
|
+
|
|
284
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
285
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
286
|
+
|
|
287
|
+
new_options = opts.merge(
|
|
288
|
+
:operation => :"PushSettingsApi.push_settings_upsert_push_apn_settings",
|
|
289
|
+
:header_params => header_params,
|
|
290
|
+
:query_params => query_params,
|
|
291
|
+
:form_params => form_params,
|
|
292
|
+
:body => post_body,
|
|
293
|
+
:auth_names => auth_names,
|
|
294
|
+
:return_type => return_type
|
|
295
|
+
)
|
|
296
|
+
|
|
297
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
|
298
|
+
if @api_client.config.debugging
|
|
299
|
+
@api_client.config.logger.debug "API called: PushSettingsApi#push_settings_upsert_push_apn_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
300
|
+
end
|
|
301
|
+
return data, status_code, headers
|
|
302
|
+
end
|
|
303
|
+
|
|
304
|
+
# Create or update Firebase Cloud Messaging (FCM) configuration for the current account.
|
|
305
|
+
# @param push_settings_fcm_put_request [PushSettingsFCMPutRequest]
|
|
306
|
+
# @param [Hash] opts the optional parameters
|
|
307
|
+
# @return [PushSettingsFCMResponse]
|
|
308
|
+
def push_settings_upsert_push_fcm_settings(push_settings_fcm_put_request, opts = {})
|
|
309
|
+
data, _status_code, _headers = push_settings_upsert_push_fcm_settings_with_http_info(push_settings_fcm_put_request, opts)
|
|
310
|
+
data
|
|
311
|
+
end
|
|
312
|
+
|
|
313
|
+
# Create or update Firebase Cloud Messaging (FCM) configuration for the current account.
|
|
314
|
+
# @param push_settings_fcm_put_request [PushSettingsFCMPutRequest]
|
|
315
|
+
# @param [Hash] opts the optional parameters
|
|
316
|
+
# @return [Array<(PushSettingsFCMResponse, Integer, Hash)>] PushSettingsFCMResponse data, response status code and response headers
|
|
317
|
+
def push_settings_upsert_push_fcm_settings_with_http_info(push_settings_fcm_put_request, opts = {})
|
|
318
|
+
if @api_client.config.debugging
|
|
319
|
+
@api_client.config.logger.debug 'Calling API: PushSettingsApi.push_settings_upsert_push_fcm_settings ...'
|
|
320
|
+
end
|
|
321
|
+
# verify the required parameter 'push_settings_fcm_put_request' is set
|
|
322
|
+
if @api_client.config.client_side_validation && push_settings_fcm_put_request.nil?
|
|
323
|
+
fail ArgumentError, "Missing the required parameter 'push_settings_fcm_put_request' when calling PushSettingsApi.push_settings_upsert_push_fcm_settings"
|
|
324
|
+
end
|
|
325
|
+
# resource path
|
|
326
|
+
local_var_path = '/settings/push/fcm'
|
|
327
|
+
|
|
328
|
+
# query parameters
|
|
329
|
+
query_params = opts[:query_params] || {}
|
|
330
|
+
|
|
331
|
+
# header parameters
|
|
332
|
+
header_params = opts[:header_params] || {}
|
|
333
|
+
# HTTP header 'Accept' (if needed)
|
|
334
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
335
|
+
# HTTP header 'Content-Type'
|
|
336
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
337
|
+
if !content_type.nil?
|
|
338
|
+
header_params['Content-Type'] = content_type
|
|
339
|
+
end
|
|
340
|
+
|
|
341
|
+
# form parameters
|
|
342
|
+
form_params = opts[:form_params] || {}
|
|
343
|
+
|
|
344
|
+
# http body (model)
|
|
345
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(push_settings_fcm_put_request)
|
|
346
|
+
|
|
347
|
+
# return_type
|
|
348
|
+
return_type = opts[:debug_return_type] || 'PushSettingsFCMResponse'
|
|
349
|
+
|
|
350
|
+
# auth_names (apiKey last so Bearer wins when multiple schemes set Authorization)
|
|
351
|
+
auth_names = opts[:debug_auth_names] || ['endUserHashed', 'endUser', 'clientCredentials', 'apiKey']
|
|
352
|
+
|
|
353
|
+
new_options = opts.merge(
|
|
354
|
+
:operation => :"PushSettingsApi.push_settings_upsert_push_fcm_settings",
|
|
355
|
+
:header_params => header_params,
|
|
356
|
+
:query_params => query_params,
|
|
357
|
+
:form_params => form_params,
|
|
358
|
+
:body => post_body,
|
|
359
|
+
:auth_names => auth_names,
|
|
360
|
+
:return_type => return_type
|
|
361
|
+
)
|
|
362
|
+
|
|
363
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
|
364
|
+
if @api_client.config.debugging
|
|
365
|
+
@api_client.config.logger.debug "API called: PushSettingsApi#push_settings_upsert_push_fcm_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
366
|
+
end
|
|
367
|
+
return data, status_code, headers
|
|
368
|
+
end
|
|
369
|
+
end
|
|
370
|
+
end
|