one_msg_chat_api 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/LICENSE.txt +21 -0
- data/Rakefile +10 -0
- data/docs/AddTemplateRequest.md +24 -0
- data/docs/BlockUserRequest.md +18 -0
- data/docs/CallingApi.md +231 -0
- data/docs/CatalogApi.md +153 -0
- data/docs/ChannelApi.md +225 -0
- data/docs/ConversationalAutomation.md +22 -0
- data/docs/ConversationalAutomationCommandsInner.md +20 -0
- data/docs/CreateCommerce200Response.md +18 -0
- data/docs/CreateCommerceRequest.md +18 -0
- data/docs/CreateCommerceRequestParams.md +20 -0
- data/docs/CreateGroups200Response.md +18 -0
- data/docs/CreateReadMessage200Response.md +18 -0
- data/docs/CreateReadMessage401Response.md +18 -0
- data/docs/CreateReadMessageRequest.md +22 -0
- data/docs/DeleteFlowsFlowId200Response.md +20 -0
- data/docs/DeleteGroupsGroupId200Response.md +20 -0
- data/docs/DeleteMediaLegacyRequest.md +18 -0
- data/docs/ErrorResponse.md +18 -0
- data/docs/FlowsApi.md +836 -0
- data/docs/GetCommerce200ResponseInner.md +22 -0
- data/docs/GetMmLiteStatus200Response.md +22 -0
- data/docs/GetWebhook200Response.md +18 -0
- data/docs/GetWhatsappBusinessEncryption200Response.md +22 -0
- data/docs/GroupsApi.md +507 -0
- data/docs/ListBlockedUsers200Response.md +18 -0
- data/docs/ListFlows200Response.md +26 -0
- data/docs/ListMessages200Response.md +20 -0
- data/docs/ListTemplates200Response.md +22 -0
- data/docs/MessageSentResponse.md +24 -0
- data/docs/MessagingApi.md +1784 -0
- data/docs/PatchFlowsFlowIdAssets200Response.md +22 -0
- data/docs/ProfileApi.md +155 -0
- data/docs/ProfileInfo.md +32 -0
- data/docs/RetrieveMedia200Response.md +26 -0
- data/docs/SendAddressMessageRequest.md +32 -0
- data/docs/SendButtonRequest.md +24 -0
- data/docs/SendButtonRequestSectionsInner.md +20 -0
- data/docs/SendButtonRequestSectionsInnerReply.md +20 -0
- data/docs/SendCarouselRequest1.md +26 -0
- data/docs/SendContactRequest.md +20 -0
- data/docs/SendContactRequestContactsInner.md +30 -0
- data/docs/SendContactRequestContactsInnerName.md +28 -0
- data/docs/SendContactRequestContactsInnerOrg.md +22 -0
- data/docs/SendContactRequestContactsInnerPhonesInner.md +22 -0
- data/docs/SendCtaUrlRequest.md +32 -0
- data/docs/SendFileRequest.md +34 -0
- data/docs/SendFlowRequest1.md +46 -0
- data/docs/SendFlowRequest1Header.md +49 -0
- data/docs/SendFlowRequestHeader.md +49 -0
- data/docs/SendListRequest.md +26 -0
- data/docs/SendListRequestSectionsInner.md +20 -0
- data/docs/SendListRequestSectionsInnerRowsInner.md +22 -0
- data/docs/SendLocationRequest1.md +30 -0
- data/docs/SendLocationRequestRequest.md +20 -0
- data/docs/SendMessageRequest.md +24 -0
- data/docs/SendOrderDetailsRequest.md +36 -0
- data/docs/SendOrderDetailsRequestLanguage.md +20 -0
- data/docs/SendOrderDetailsRequestOrder.md +28 -0
- data/docs/SendOrderDetailsRequestOrderItemsInner.md +24 -0
- data/docs/SendOrderDetailsRequestOrderItemsInnerAmount.md +20 -0
- data/docs/SendPaymentRequestRequest.md +26 -0
- data/docs/SendReactionRequest.md +22 -0
- data/docs/SendStickerRequest.md +26 -0
- data/docs/SendTemplateRequest.md +32 -0
- data/docs/SendTemplateRequestLanguage.md +20 -0
- data/docs/SetWhatsappBusinessEncryptionRequest.md +21 -0
- data/docs/SuccessResponse.md +18 -0
- data/docs/TemplatesApi.md +301 -0
- data/docs/UpdateMeRequest.md +30 -0
- data/docs/UsersApi.md +223 -0
- data/docs/WebhooksApi.md +155 -0
- data/git_push.sh +57 -0
- data/lib/one_msg_chat_api/api/calling_api.rb +228 -0
- data/lib/one_msg_chat_api/api/catalog_api.rb +161 -0
- data/lib/one_msg_chat_api/api/channel_api.rb +225 -0
- data/lib/one_msg_chat_api/api/flows_api.rb +788 -0
- data/lib/one_msg_chat_api/api/groups_api.rb +486 -0
- data/lib/one_msg_chat_api/api/messaging_api.rb +1833 -0
- data/lib/one_msg_chat_api/api/profile_api.rb +157 -0
- data/lib/one_msg_chat_api/api/templates_api.rb +293 -0
- data/lib/one_msg_chat_api/api/users_api.rb +232 -0
- data/lib/one_msg_chat_api/api/webhooks_api.rb +157 -0
- data/lib/one_msg_chat_api/api_client.rb +441 -0
- data/lib/one_msg_chat_api/api_error.rb +58 -0
- data/lib/one_msg_chat_api/api_model_base.rb +88 -0
- data/lib/one_msg_chat_api/configuration.rb +400 -0
- data/lib/one_msg_chat_api/models/add_template_request.rb +176 -0
- data/lib/one_msg_chat_api/models/block_user_request.rb +164 -0
- data/lib/one_msg_chat_api/models/conversational_automation.rb +210 -0
- data/lib/one_msg_chat_api/models/conversational_automation_commands_inner.rb +208 -0
- data/lib/one_msg_chat_api/models/create_commerce200_response.rb +147 -0
- data/lib/one_msg_chat_api/models/create_commerce_request.rb +164 -0
- data/lib/one_msg_chat_api/models/create_commerce_request_params.rb +192 -0
- data/lib/one_msg_chat_api/models/create_groups200_response.rb +149 -0
- data/lib/one_msg_chat_api/models/create_read_message200_response.rb +147 -0
- data/lib/one_msg_chat_api/models/create_read_message401_response.rb +147 -0
- data/lib/one_msg_chat_api/models/create_read_message_request.rb +168 -0
- data/lib/one_msg_chat_api/models/delete_flows_flow_id200_response.rb +158 -0
- data/lib/one_msg_chat_api/models/delete_groups_group_id200_response.rb +158 -0
- data/lib/one_msg_chat_api/models/delete_media_legacy_request.rb +165 -0
- data/lib/one_msg_chat_api/models/error_response.rb +149 -0
- data/lib/one_msg_chat_api/models/get_commerce200_response_inner.rb +168 -0
- data/lib/one_msg_chat_api/models/get_mm_lite_status200_response.rb +165 -0
- data/lib/one_msg_chat_api/models/get_webhook200_response.rb +147 -0
- data/lib/one_msg_chat_api/models/get_whatsapp_business_encryption200_response.rb +202 -0
- data/lib/one_msg_chat_api/models/list_blocked_users200_response.rb +149 -0
- data/lib/one_msg_chat_api/models/list_flows200_response.rb +189 -0
- data/lib/one_msg_chat_api/models/list_messages200_response.rb +158 -0
- data/lib/one_msg_chat_api/models/list_templates200_response.rb +169 -0
- data/lib/one_msg_chat_api/models/message_sent_response.rb +179 -0
- data/lib/one_msg_chat_api/models/patch_flows_flow_id_assets200_response.rb +169 -0
- data/lib/one_msg_chat_api/models/profile_info.rb +254 -0
- data/lib/one_msg_chat_api/models/retrieve_media200_response.rb +183 -0
- data/lib/one_msg_chat_api/models/send_address_message_request.rb +273 -0
- data/lib/one_msg_chat_api/models/send_button_request.rb +176 -0
- data/lib/one_msg_chat_api/models/send_button_request_sections_inner.rb +156 -0
- data/lib/one_msg_chat_api/models/send_button_request_sections_inner_reply.rb +156 -0
- data/lib/one_msg_chat_api/models/send_carousel_request1.rb +202 -0
- data/lib/one_msg_chat_api/models/send_contact_request.rb +158 -0
- data/lib/one_msg_chat_api/models/send_contact_request_contacts_inner.rb +209 -0
- data/lib/one_msg_chat_api/models/send_contact_request_contacts_inner_name.rb +192 -0
- data/lib/one_msg_chat_api/models/send_contact_request_contacts_inner_org.rb +165 -0
- data/lib/one_msg_chat_api/models/send_contact_request_contacts_inner_phones_inner.rb +165 -0
- data/lib/one_msg_chat_api/models/send_cta_url_request.rb +264 -0
- data/lib/one_msg_chat_api/models/send_file_request.rb +278 -0
- data/lib/one_msg_chat_api/models/send_flow_request1.rb +387 -0
- data/lib/one_msg_chat_api/models/send_flow_request1_header.rb +104 -0
- data/lib/one_msg_chat_api/models/send_flow_request_header.rb +105 -0
- data/lib/one_msg_chat_api/models/send_list_request.rb +185 -0
- data/lib/one_msg_chat_api/models/send_list_request_sections_inner.rb +158 -0
- data/lib/one_msg_chat_api/models/send_list_request_sections_inner_rows_inner.rb +165 -0
- data/lib/one_msg_chat_api/models/send_location_request1.rb +235 -0
- data/lib/one_msg_chat_api/models/send_location_request_request.rb +156 -0
- data/lib/one_msg_chat_api/models/send_message_request.rb +284 -0
- data/lib/one_msg_chat_api/models/send_order_details_request.rb +308 -0
- data/lib/one_msg_chat_api/models/send_order_details_request_language.rb +176 -0
- data/lib/one_msg_chat_api/models/send_order_details_request_order.rb +220 -0
- data/lib/one_msg_chat_api/models/send_order_details_request_order_items_inner.rb +174 -0
- data/lib/one_msg_chat_api/models/send_order_details_request_order_items_inner_amount.rb +156 -0
- data/lib/one_msg_chat_api/models/send_payment_request_request.rb +245 -0
- data/lib/one_msg_chat_api/models/send_reaction_request.rb +165 -0
- data/lib/one_msg_chat_api/models/send_sticker_request.rb +185 -0
- data/lib/one_msg_chat_api/models/send_template_request.rb +215 -0
- data/lib/one_msg_chat_api/models/send_template_request_language.rb +156 -0
- data/lib/one_msg_chat_api/models/set_whatsapp_business_encryption_request.rb +165 -0
- data/lib/one_msg_chat_api/models/success_response.rb +149 -0
- data/lib/one_msg_chat_api/models/update_me_request.rb +207 -0
- data/lib/one_msg_chat_api/version.rb +15 -0
- data/lib/one_msg_chat_api.rb +111 -0
- data/one_msg_chat_api.gemspec +41 -0
- data/spec/api/calling_api_spec.rb +73 -0
- data/spec/api/catalog_api_spec.rb +60 -0
- data/spec/api/channel_api_spec.rb +72 -0
- data/spec/api/flows_api_spec.rb +175 -0
- data/spec/api/groups_api_spec.rb +117 -0
- data/spec/api/messaging_api_spec.rb +359 -0
- data/spec/api/profile_api_spec.rb +60 -0
- data/spec/api/templates_api_spec.rb +83 -0
- data/spec/api/users_api_spec.rb +71 -0
- data/spec/api/webhooks_api_spec.rb +60 -0
- data/spec/models/add_template_request_spec.rb +54 -0
- data/spec/models/block_user_request_spec.rb +36 -0
- data/spec/models/conversational_automation_commands_inner_spec.rb +42 -0
- data/spec/models/conversational_automation_spec.rb +48 -0
- data/spec/models/create_commerce200_response_spec.rb +36 -0
- data/spec/models/create_commerce_request_params_spec.rb +42 -0
- data/spec/models/create_commerce_request_spec.rb +36 -0
- data/spec/models/create_groups200_response_spec.rb +36 -0
- data/spec/models/create_read_message200_response_spec.rb +36 -0
- data/spec/models/create_read_message401_response_spec.rb +36 -0
- data/spec/models/create_read_message_request_spec.rb +48 -0
- data/spec/models/delete_flows_flow_id200_response_spec.rb +42 -0
- data/spec/models/delete_groups_group_id200_response_spec.rb +42 -0
- data/spec/models/delete_media_legacy_request_spec.rb +36 -0
- data/spec/models/error_response_spec.rb +36 -0
- data/spec/models/get_commerce200_response_inner_spec.rb +48 -0
- data/spec/models/get_mm_lite_status200_response_spec.rb +48 -0
- data/spec/models/get_webhook200_response_spec.rb +36 -0
- data/spec/models/get_whatsapp_business_encryption200_response_spec.rb +52 -0
- data/spec/models/list_blocked_users200_response_spec.rb +36 -0
- data/spec/models/list_flows200_response_spec.rb +60 -0
- data/spec/models/list_messages200_response_spec.rb +42 -0
- data/spec/models/list_templates200_response_spec.rb +48 -0
- data/spec/models/message_sent_response_spec.rb +54 -0
- data/spec/models/patch_flows_flow_id_assets200_response_spec.rb +48 -0
- data/spec/models/profile_info_spec.rb +82 -0
- data/spec/models/retrieve_media200_response_spec.rb +60 -0
- data/spec/models/send_address_message_request_spec.rb +82 -0
- data/spec/models/send_button_request_sections_inner_reply_spec.rb +42 -0
- data/spec/models/send_button_request_sections_inner_spec.rb +42 -0
- data/spec/models/send_button_request_spec.rb +54 -0
- data/spec/models/send_carousel_request1_spec.rb +60 -0
- data/spec/models/send_contact_request_contacts_inner_name_spec.rb +66 -0
- data/spec/models/send_contact_request_contacts_inner_org_spec.rb +48 -0
- data/spec/models/send_contact_request_contacts_inner_phones_inner_spec.rb +48 -0
- data/spec/models/send_contact_request_contacts_inner_spec.rb +72 -0
- data/spec/models/send_contact_request_spec.rb +42 -0
- data/spec/models/send_cta_url_request_spec.rb +78 -0
- data/spec/models/send_file_request_spec.rb +88 -0
- data/spec/models/send_flow_request1_header_spec.rb +32 -0
- data/spec/models/send_flow_request1_spec.rb +128 -0
- data/spec/models/send_flow_request_header_spec.rb +32 -0
- data/spec/models/send_list_request_sections_inner_rows_inner_spec.rb +48 -0
- data/spec/models/send_list_request_sections_inner_spec.rb +42 -0
- data/spec/models/send_list_request_spec.rb +60 -0
- data/spec/models/send_location_request1_spec.rb +72 -0
- data/spec/models/send_location_request_request_spec.rb +42 -0
- data/spec/models/send_message_request_spec.rb +54 -0
- data/spec/models/send_order_details_request_language_spec.rb +42 -0
- data/spec/models/send_order_details_request_order_items_inner_amount_spec.rb +42 -0
- data/spec/models/send_order_details_request_order_items_inner_spec.rb +54 -0
- data/spec/models/send_order_details_request_order_spec.rb +66 -0
- data/spec/models/send_order_details_request_spec.rb +90 -0
- data/spec/models/send_payment_request_request_spec.rb +64 -0
- data/spec/models/send_reaction_request_spec.rb +48 -0
- data/spec/models/send_sticker_request_spec.rb +60 -0
- data/spec/models/send_template_request_language_spec.rb +42 -0
- data/spec/models/send_template_request_spec.rb +78 -0
- data/spec/models/set_whatsapp_business_encryption_request_spec.rb +36 -0
- data/spec/models/success_response_spec.rb +36 -0
- data/spec/models/update_me_request_spec.rb +72 -0
- data/spec/spec_helper.rb +111 -0
- metadata +408 -0
|
@@ -0,0 +1,486 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#1MSG WhatsApp Business API (Public)
|
|
3
|
+
|
|
4
|
+
#Public client API for sending messages, managing groups, flows, and templates. This is the API exposed to end customers via platform.1msg.io **Authentication:** All requests require `token` query parameter with JWT or API key. **Documentation:** https://help.1msg.io/platform-1msg/getting-start/quick-start **API Docs:** https://docs.1msg.io/
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
Contact: support@1msg.io
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.22.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'cgi'
|
|
14
|
+
|
|
15
|
+
module OneMsgChatApi
|
|
16
|
+
class GroupsApi
|
|
17
|
+
attr_accessor :api_client
|
|
18
|
+
|
|
19
|
+
def initialize(api_client = ApiClient.default)
|
|
20
|
+
@api_client = api_client
|
|
21
|
+
end
|
|
22
|
+
# Create Group
|
|
23
|
+
# @param token [String] JWT token or API key for authorization
|
|
24
|
+
# @param [Hash] opts the optional parameters
|
|
25
|
+
# @return [CreateGroups200Response]
|
|
26
|
+
def create_groups(token, opts = {})
|
|
27
|
+
data, _status_code, _headers = create_groups_with_http_info(token, opts)
|
|
28
|
+
data
|
|
29
|
+
end
|
|
30
|
+
|
|
31
|
+
# Create Group
|
|
32
|
+
# @param token [String] JWT token or API key for authorization
|
|
33
|
+
# @param [Hash] opts the optional parameters
|
|
34
|
+
# @return [Array<(CreateGroups200Response, Integer, Hash)>] CreateGroups200Response data, response status code and response headers
|
|
35
|
+
def create_groups_with_http_info(token, opts = {})
|
|
36
|
+
if @api_client.config.debugging
|
|
37
|
+
@api_client.config.logger.debug 'Calling API: GroupsApi.create_groups ...'
|
|
38
|
+
end
|
|
39
|
+
# verify the required parameter 'token' is set
|
|
40
|
+
if @api_client.config.client_side_validation && token.nil?
|
|
41
|
+
fail ArgumentError, "Missing the required parameter 'token' when calling GroupsApi.create_groups"
|
|
42
|
+
end
|
|
43
|
+
# resource path
|
|
44
|
+
local_var_path = '/groups'
|
|
45
|
+
|
|
46
|
+
# query parameters
|
|
47
|
+
query_params = opts[:query_params] || {}
|
|
48
|
+
query_params[:'token'] = token
|
|
49
|
+
|
|
50
|
+
# header parameters
|
|
51
|
+
header_params = opts[:header_params] || {}
|
|
52
|
+
# HTTP header 'Accept' (if needed)
|
|
53
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
54
|
+
|
|
55
|
+
# form parameters
|
|
56
|
+
form_params = opts[:form_params] || {}
|
|
57
|
+
|
|
58
|
+
# http body (model)
|
|
59
|
+
post_body = opts[:debug_body]
|
|
60
|
+
|
|
61
|
+
# return_type
|
|
62
|
+
return_type = opts[:debug_return_type] || 'CreateGroups200Response'
|
|
63
|
+
|
|
64
|
+
# auth_names
|
|
65
|
+
auth_names = opts[:debug_auth_names] || ['tokenAuth']
|
|
66
|
+
|
|
67
|
+
new_options = opts.merge(
|
|
68
|
+
:operation => :"GroupsApi.create_groups",
|
|
69
|
+
:header_params => header_params,
|
|
70
|
+
:query_params => query_params,
|
|
71
|
+
:form_params => form_params,
|
|
72
|
+
:body => post_body,
|
|
73
|
+
:auth_names => auth_names,
|
|
74
|
+
:return_type => return_type
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
78
|
+
if @api_client.config.debugging
|
|
79
|
+
@api_client.config.logger.debug "API called: GroupsApi#create_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
80
|
+
end
|
|
81
|
+
return data, status_code, headers
|
|
82
|
+
end
|
|
83
|
+
|
|
84
|
+
# Update Group Info
|
|
85
|
+
# @param group_id [String]
|
|
86
|
+
# @param token [String] JWT token or API key for authorization
|
|
87
|
+
# @param [Hash] opts the optional parameters
|
|
88
|
+
# @return [Hash<String, Object>]
|
|
89
|
+
def create_groups_group_id(group_id, token, opts = {})
|
|
90
|
+
data, _status_code, _headers = create_groups_group_id_with_http_info(group_id, token, opts)
|
|
91
|
+
data
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
# Update Group Info
|
|
95
|
+
# @param group_id [String]
|
|
96
|
+
# @param token [String] JWT token or API key for authorization
|
|
97
|
+
# @param [Hash] opts the optional parameters
|
|
98
|
+
# @return [Array<(Hash<String, Object>, Integer, Hash)>] Hash<String, Object> data, response status code and response headers
|
|
99
|
+
def create_groups_group_id_with_http_info(group_id, token, opts = {})
|
|
100
|
+
if @api_client.config.debugging
|
|
101
|
+
@api_client.config.logger.debug 'Calling API: GroupsApi.create_groups_group_id ...'
|
|
102
|
+
end
|
|
103
|
+
# verify the required parameter 'group_id' is set
|
|
104
|
+
if @api_client.config.client_side_validation && group_id.nil?
|
|
105
|
+
fail ArgumentError, "Missing the required parameter 'group_id' when calling GroupsApi.create_groups_group_id"
|
|
106
|
+
end
|
|
107
|
+
# verify the required parameter 'token' is set
|
|
108
|
+
if @api_client.config.client_side_validation && token.nil?
|
|
109
|
+
fail ArgumentError, "Missing the required parameter 'token' when calling GroupsApi.create_groups_group_id"
|
|
110
|
+
end
|
|
111
|
+
# resource path
|
|
112
|
+
local_var_path = '/groups/{groupId}'.sub('{groupId}', CGI.escape(group_id.to_s))
|
|
113
|
+
|
|
114
|
+
# query parameters
|
|
115
|
+
query_params = opts[:query_params] || {}
|
|
116
|
+
query_params[:'token'] = token
|
|
117
|
+
|
|
118
|
+
# header parameters
|
|
119
|
+
header_params = opts[:header_params] || {}
|
|
120
|
+
# HTTP header 'Accept' (if needed)
|
|
121
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
122
|
+
|
|
123
|
+
# form parameters
|
|
124
|
+
form_params = opts[:form_params] || {}
|
|
125
|
+
|
|
126
|
+
# http body (model)
|
|
127
|
+
post_body = opts[:debug_body]
|
|
128
|
+
|
|
129
|
+
# return_type
|
|
130
|
+
return_type = opts[:debug_return_type] || 'Hash<String, Object>'
|
|
131
|
+
|
|
132
|
+
# auth_names
|
|
133
|
+
auth_names = opts[:debug_auth_names] || ['tokenAuth']
|
|
134
|
+
|
|
135
|
+
new_options = opts.merge(
|
|
136
|
+
:operation => :"GroupsApi.create_groups_group_id",
|
|
137
|
+
:header_params => header_params,
|
|
138
|
+
:query_params => query_params,
|
|
139
|
+
:form_params => form_params,
|
|
140
|
+
:body => post_body,
|
|
141
|
+
:auth_names => auth_names,
|
|
142
|
+
:return_type => return_type
|
|
143
|
+
)
|
|
144
|
+
|
|
145
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
146
|
+
if @api_client.config.debugging
|
|
147
|
+
@api_client.config.logger.debug "API called: GroupsApi#create_groups_group_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
148
|
+
end
|
|
149
|
+
return data, status_code, headers
|
|
150
|
+
end
|
|
151
|
+
|
|
152
|
+
# Reset Invite Link
|
|
153
|
+
# @param group_id [String]
|
|
154
|
+
# @param token [String] JWT token or API key for authorization
|
|
155
|
+
# @param [Hash] opts the optional parameters
|
|
156
|
+
# @return [Hash<String, Object>]
|
|
157
|
+
def create_groups_group_id_invitelink(group_id, token, opts = {})
|
|
158
|
+
data, _status_code, _headers = create_groups_group_id_invitelink_with_http_info(group_id, token, opts)
|
|
159
|
+
data
|
|
160
|
+
end
|
|
161
|
+
|
|
162
|
+
# Reset Invite Link
|
|
163
|
+
# @param group_id [String]
|
|
164
|
+
# @param token [String] JWT token or API key for authorization
|
|
165
|
+
# @param [Hash] opts the optional parameters
|
|
166
|
+
# @return [Array<(Hash<String, Object>, Integer, Hash)>] Hash<String, Object> data, response status code and response headers
|
|
167
|
+
def create_groups_group_id_invitelink_with_http_info(group_id, token, opts = {})
|
|
168
|
+
if @api_client.config.debugging
|
|
169
|
+
@api_client.config.logger.debug 'Calling API: GroupsApi.create_groups_group_id_invitelink ...'
|
|
170
|
+
end
|
|
171
|
+
# verify the required parameter 'group_id' is set
|
|
172
|
+
if @api_client.config.client_side_validation && group_id.nil?
|
|
173
|
+
fail ArgumentError, "Missing the required parameter 'group_id' when calling GroupsApi.create_groups_group_id_invitelink"
|
|
174
|
+
end
|
|
175
|
+
# verify the required parameter 'token' is set
|
|
176
|
+
if @api_client.config.client_side_validation && token.nil?
|
|
177
|
+
fail ArgumentError, "Missing the required parameter 'token' when calling GroupsApi.create_groups_group_id_invitelink"
|
|
178
|
+
end
|
|
179
|
+
# resource path
|
|
180
|
+
local_var_path = '/groups/{groupId}/inviteLink'.sub('{groupId}', CGI.escape(group_id.to_s))
|
|
181
|
+
|
|
182
|
+
# query parameters
|
|
183
|
+
query_params = opts[:query_params] || {}
|
|
184
|
+
query_params[:'token'] = token
|
|
185
|
+
|
|
186
|
+
# header parameters
|
|
187
|
+
header_params = opts[:header_params] || {}
|
|
188
|
+
# HTTP header 'Accept' (if needed)
|
|
189
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
190
|
+
|
|
191
|
+
# form parameters
|
|
192
|
+
form_params = opts[:form_params] || {}
|
|
193
|
+
|
|
194
|
+
# http body (model)
|
|
195
|
+
post_body = opts[:debug_body]
|
|
196
|
+
|
|
197
|
+
# return_type
|
|
198
|
+
return_type = opts[:debug_return_type] || 'Hash<String, Object>'
|
|
199
|
+
|
|
200
|
+
# auth_names
|
|
201
|
+
auth_names = opts[:debug_auth_names] || ['tokenAuth']
|
|
202
|
+
|
|
203
|
+
new_options = opts.merge(
|
|
204
|
+
:operation => :"GroupsApi.create_groups_group_id_invitelink",
|
|
205
|
+
:header_params => header_params,
|
|
206
|
+
:query_params => query_params,
|
|
207
|
+
:form_params => form_params,
|
|
208
|
+
:body => post_body,
|
|
209
|
+
:auth_names => auth_names,
|
|
210
|
+
:return_type => return_type
|
|
211
|
+
)
|
|
212
|
+
|
|
213
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
214
|
+
if @api_client.config.debugging
|
|
215
|
+
@api_client.config.logger.debug "API called: GroupsApi#create_groups_group_id_invitelink\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
216
|
+
end
|
|
217
|
+
return data, status_code, headers
|
|
218
|
+
end
|
|
219
|
+
|
|
220
|
+
# Delete Group
|
|
221
|
+
# @param group_id [String]
|
|
222
|
+
# @param token [String] JWT token or API key for authorization
|
|
223
|
+
# @param [Hash] opts the optional parameters
|
|
224
|
+
# @return [DeleteGroupsGroupId200Response]
|
|
225
|
+
def delete_groups_group_id(group_id, token, opts = {})
|
|
226
|
+
data, _status_code, _headers = delete_groups_group_id_with_http_info(group_id, token, opts)
|
|
227
|
+
data
|
|
228
|
+
end
|
|
229
|
+
|
|
230
|
+
# Delete Group
|
|
231
|
+
# @param group_id [String]
|
|
232
|
+
# @param token [String] JWT token or API key for authorization
|
|
233
|
+
# @param [Hash] opts the optional parameters
|
|
234
|
+
# @return [Array<(DeleteGroupsGroupId200Response, Integer, Hash)>] DeleteGroupsGroupId200Response data, response status code and response headers
|
|
235
|
+
def delete_groups_group_id_with_http_info(group_id, token, opts = {})
|
|
236
|
+
if @api_client.config.debugging
|
|
237
|
+
@api_client.config.logger.debug 'Calling API: GroupsApi.delete_groups_group_id ...'
|
|
238
|
+
end
|
|
239
|
+
# verify the required parameter 'group_id' is set
|
|
240
|
+
if @api_client.config.client_side_validation && group_id.nil?
|
|
241
|
+
fail ArgumentError, "Missing the required parameter 'group_id' when calling GroupsApi.delete_groups_group_id"
|
|
242
|
+
end
|
|
243
|
+
# verify the required parameter 'token' is set
|
|
244
|
+
if @api_client.config.client_side_validation && token.nil?
|
|
245
|
+
fail ArgumentError, "Missing the required parameter 'token' when calling GroupsApi.delete_groups_group_id"
|
|
246
|
+
end
|
|
247
|
+
# resource path
|
|
248
|
+
local_var_path = '/groups/{groupId}'.sub('{groupId}', CGI.escape(group_id.to_s))
|
|
249
|
+
|
|
250
|
+
# query parameters
|
|
251
|
+
query_params = opts[:query_params] || {}
|
|
252
|
+
query_params[:'token'] = token
|
|
253
|
+
|
|
254
|
+
# header parameters
|
|
255
|
+
header_params = opts[:header_params] || {}
|
|
256
|
+
# HTTP header 'Accept' (if needed)
|
|
257
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
258
|
+
|
|
259
|
+
# form parameters
|
|
260
|
+
form_params = opts[:form_params] || {}
|
|
261
|
+
|
|
262
|
+
# http body (model)
|
|
263
|
+
post_body = opts[:debug_body]
|
|
264
|
+
|
|
265
|
+
# return_type
|
|
266
|
+
return_type = opts[:debug_return_type] || 'DeleteGroupsGroupId200Response'
|
|
267
|
+
|
|
268
|
+
# auth_names
|
|
269
|
+
auth_names = opts[:debug_auth_names] || ['tokenAuth']
|
|
270
|
+
|
|
271
|
+
new_options = opts.merge(
|
|
272
|
+
:operation => :"GroupsApi.delete_groups_group_id",
|
|
273
|
+
:header_params => header_params,
|
|
274
|
+
:query_params => query_params,
|
|
275
|
+
:form_params => form_params,
|
|
276
|
+
:body => post_body,
|
|
277
|
+
:auth_names => auth_names,
|
|
278
|
+
:return_type => return_type
|
|
279
|
+
)
|
|
280
|
+
|
|
281
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
282
|
+
if @api_client.config.debugging
|
|
283
|
+
@api_client.config.logger.debug "API called: GroupsApi#delete_groups_group_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
284
|
+
end
|
|
285
|
+
return data, status_code, headers
|
|
286
|
+
end
|
|
287
|
+
|
|
288
|
+
# Get Group Info
|
|
289
|
+
# @param group_id [String]
|
|
290
|
+
# @param token [String] JWT token or API key for authorization
|
|
291
|
+
# @param [Hash] opts the optional parameters
|
|
292
|
+
# @return [Hash<String, Object>]
|
|
293
|
+
def get_groups_group_id(group_id, token, opts = {})
|
|
294
|
+
data, _status_code, _headers = get_groups_group_id_with_http_info(group_id, token, opts)
|
|
295
|
+
data
|
|
296
|
+
end
|
|
297
|
+
|
|
298
|
+
# Get Group Info
|
|
299
|
+
# @param group_id [String]
|
|
300
|
+
# @param token [String] JWT token or API key for authorization
|
|
301
|
+
# @param [Hash] opts the optional parameters
|
|
302
|
+
# @return [Array<(Hash<String, Object>, Integer, Hash)>] Hash<String, Object> data, response status code and response headers
|
|
303
|
+
def get_groups_group_id_with_http_info(group_id, token, opts = {})
|
|
304
|
+
if @api_client.config.debugging
|
|
305
|
+
@api_client.config.logger.debug 'Calling API: GroupsApi.get_groups_group_id ...'
|
|
306
|
+
end
|
|
307
|
+
# verify the required parameter 'group_id' is set
|
|
308
|
+
if @api_client.config.client_side_validation && group_id.nil?
|
|
309
|
+
fail ArgumentError, "Missing the required parameter 'group_id' when calling GroupsApi.get_groups_group_id"
|
|
310
|
+
end
|
|
311
|
+
# verify the required parameter 'token' is set
|
|
312
|
+
if @api_client.config.client_side_validation && token.nil?
|
|
313
|
+
fail ArgumentError, "Missing the required parameter 'token' when calling GroupsApi.get_groups_group_id"
|
|
314
|
+
end
|
|
315
|
+
# resource path
|
|
316
|
+
local_var_path = '/groups/{groupId}'.sub('{groupId}', CGI.escape(group_id.to_s))
|
|
317
|
+
|
|
318
|
+
# query parameters
|
|
319
|
+
query_params = opts[:query_params] || {}
|
|
320
|
+
query_params[:'token'] = token
|
|
321
|
+
|
|
322
|
+
# header parameters
|
|
323
|
+
header_params = opts[:header_params] || {}
|
|
324
|
+
# HTTP header 'Accept' (if needed)
|
|
325
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
326
|
+
|
|
327
|
+
# form parameters
|
|
328
|
+
form_params = opts[:form_params] || {}
|
|
329
|
+
|
|
330
|
+
# http body (model)
|
|
331
|
+
post_body = opts[:debug_body]
|
|
332
|
+
|
|
333
|
+
# return_type
|
|
334
|
+
return_type = opts[:debug_return_type] || 'Hash<String, Object>'
|
|
335
|
+
|
|
336
|
+
# auth_names
|
|
337
|
+
auth_names = opts[:debug_auth_names] || ['tokenAuth']
|
|
338
|
+
|
|
339
|
+
new_options = opts.merge(
|
|
340
|
+
:operation => :"GroupsApi.get_groups_group_id",
|
|
341
|
+
:header_params => header_params,
|
|
342
|
+
:query_params => query_params,
|
|
343
|
+
:form_params => form_params,
|
|
344
|
+
:body => post_body,
|
|
345
|
+
:auth_names => auth_names,
|
|
346
|
+
:return_type => return_type
|
|
347
|
+
)
|
|
348
|
+
|
|
349
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
350
|
+
if @api_client.config.debugging
|
|
351
|
+
@api_client.config.logger.debug "API called: GroupsApi#get_groups_group_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
352
|
+
end
|
|
353
|
+
return data, status_code, headers
|
|
354
|
+
end
|
|
355
|
+
|
|
356
|
+
# Get Invite Link
|
|
357
|
+
# @param group_id [String]
|
|
358
|
+
# @param token [String] JWT token or API key for authorization
|
|
359
|
+
# @param [Hash] opts the optional parameters
|
|
360
|
+
# @return [Hash<String, Object>]
|
|
361
|
+
def get_groups_group_id_invitelink(group_id, token, opts = {})
|
|
362
|
+
data, _status_code, _headers = get_groups_group_id_invitelink_with_http_info(group_id, token, opts)
|
|
363
|
+
data
|
|
364
|
+
end
|
|
365
|
+
|
|
366
|
+
# Get Invite Link
|
|
367
|
+
# @param group_id [String]
|
|
368
|
+
# @param token [String] JWT token or API key for authorization
|
|
369
|
+
# @param [Hash] opts the optional parameters
|
|
370
|
+
# @return [Array<(Hash<String, Object>, Integer, Hash)>] Hash<String, Object> data, response status code and response headers
|
|
371
|
+
def get_groups_group_id_invitelink_with_http_info(group_id, token, opts = {})
|
|
372
|
+
if @api_client.config.debugging
|
|
373
|
+
@api_client.config.logger.debug 'Calling API: GroupsApi.get_groups_group_id_invitelink ...'
|
|
374
|
+
end
|
|
375
|
+
# verify the required parameter 'group_id' is set
|
|
376
|
+
if @api_client.config.client_side_validation && group_id.nil?
|
|
377
|
+
fail ArgumentError, "Missing the required parameter 'group_id' when calling GroupsApi.get_groups_group_id_invitelink"
|
|
378
|
+
end
|
|
379
|
+
# verify the required parameter 'token' is set
|
|
380
|
+
if @api_client.config.client_side_validation && token.nil?
|
|
381
|
+
fail ArgumentError, "Missing the required parameter 'token' when calling GroupsApi.get_groups_group_id_invitelink"
|
|
382
|
+
end
|
|
383
|
+
# resource path
|
|
384
|
+
local_var_path = '/groups/{groupId}/inviteLink'.sub('{groupId}', CGI.escape(group_id.to_s))
|
|
385
|
+
|
|
386
|
+
# query parameters
|
|
387
|
+
query_params = opts[:query_params] || {}
|
|
388
|
+
query_params[:'token'] = token
|
|
389
|
+
|
|
390
|
+
# header parameters
|
|
391
|
+
header_params = opts[:header_params] || {}
|
|
392
|
+
# HTTP header 'Accept' (if needed)
|
|
393
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
394
|
+
|
|
395
|
+
# form parameters
|
|
396
|
+
form_params = opts[:form_params] || {}
|
|
397
|
+
|
|
398
|
+
# http body (model)
|
|
399
|
+
post_body = opts[:debug_body]
|
|
400
|
+
|
|
401
|
+
# return_type
|
|
402
|
+
return_type = opts[:debug_return_type] || 'Hash<String, Object>'
|
|
403
|
+
|
|
404
|
+
# auth_names
|
|
405
|
+
auth_names = opts[:debug_auth_names] || ['tokenAuth']
|
|
406
|
+
|
|
407
|
+
new_options = opts.merge(
|
|
408
|
+
:operation => :"GroupsApi.get_groups_group_id_invitelink",
|
|
409
|
+
:header_params => header_params,
|
|
410
|
+
:query_params => query_params,
|
|
411
|
+
:form_params => form_params,
|
|
412
|
+
:body => post_body,
|
|
413
|
+
:auth_names => auth_names,
|
|
414
|
+
:return_type => return_type
|
|
415
|
+
)
|
|
416
|
+
|
|
417
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
418
|
+
if @api_client.config.debugging
|
|
419
|
+
@api_client.config.logger.debug "API called: GroupsApi#get_groups_group_id_invitelink\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
420
|
+
end
|
|
421
|
+
return data, status_code, headers
|
|
422
|
+
end
|
|
423
|
+
|
|
424
|
+
# Get Groups List
|
|
425
|
+
# @param token [String] JWT token or API key for authorization
|
|
426
|
+
# @param [Hash] opts the optional parameters
|
|
427
|
+
# @return [Hash<String, Object>]
|
|
428
|
+
def list_groups(token, opts = {})
|
|
429
|
+
data, _status_code, _headers = list_groups_with_http_info(token, opts)
|
|
430
|
+
data
|
|
431
|
+
end
|
|
432
|
+
|
|
433
|
+
# Get Groups List
|
|
434
|
+
# @param token [String] JWT token or API key for authorization
|
|
435
|
+
# @param [Hash] opts the optional parameters
|
|
436
|
+
# @return [Array<(Hash<String, Object>, Integer, Hash)>] Hash<String, Object> data, response status code and response headers
|
|
437
|
+
def list_groups_with_http_info(token, opts = {})
|
|
438
|
+
if @api_client.config.debugging
|
|
439
|
+
@api_client.config.logger.debug 'Calling API: GroupsApi.list_groups ...'
|
|
440
|
+
end
|
|
441
|
+
# verify the required parameter 'token' is set
|
|
442
|
+
if @api_client.config.client_side_validation && token.nil?
|
|
443
|
+
fail ArgumentError, "Missing the required parameter 'token' when calling GroupsApi.list_groups"
|
|
444
|
+
end
|
|
445
|
+
# resource path
|
|
446
|
+
local_var_path = '/groups'
|
|
447
|
+
|
|
448
|
+
# query parameters
|
|
449
|
+
query_params = opts[:query_params] || {}
|
|
450
|
+
query_params[:'token'] = token
|
|
451
|
+
|
|
452
|
+
# header parameters
|
|
453
|
+
header_params = opts[:header_params] || {}
|
|
454
|
+
# HTTP header 'Accept' (if needed)
|
|
455
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
456
|
+
|
|
457
|
+
# form parameters
|
|
458
|
+
form_params = opts[:form_params] || {}
|
|
459
|
+
|
|
460
|
+
# http body (model)
|
|
461
|
+
post_body = opts[:debug_body]
|
|
462
|
+
|
|
463
|
+
# return_type
|
|
464
|
+
return_type = opts[:debug_return_type] || 'Hash<String, Object>'
|
|
465
|
+
|
|
466
|
+
# auth_names
|
|
467
|
+
auth_names = opts[:debug_auth_names] || ['tokenAuth']
|
|
468
|
+
|
|
469
|
+
new_options = opts.merge(
|
|
470
|
+
:operation => :"GroupsApi.list_groups",
|
|
471
|
+
:header_params => header_params,
|
|
472
|
+
:query_params => query_params,
|
|
473
|
+
:form_params => form_params,
|
|
474
|
+
:body => post_body,
|
|
475
|
+
:auth_names => auth_names,
|
|
476
|
+
:return_type => return_type
|
|
477
|
+
)
|
|
478
|
+
|
|
479
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
480
|
+
if @api_client.config.debugging
|
|
481
|
+
@api_client.config.logger.debug "API called: GroupsApi#list_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
482
|
+
end
|
|
483
|
+
return data, status_code, headers
|
|
484
|
+
end
|
|
485
|
+
end
|
|
486
|
+
end
|