Class: ZoomUs::Contacts
- Inherits:
-
Object
- Object
- ZoomUs::Contacts
- Defined in:
- lib/zoom_us/contacts.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#get_user_contact(contact_id, opts = {}) ⇒ InlineResponse2009
Get User’s Contact Details A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client.
-
#get_user_contact_with_http_info(contact_id, opts = {}) ⇒ Array<(InlineResponse2009, Fixnum, Hash)>
Get User's Contact Details A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client.
-
#get_user_contacts(opts = {}) ⇒ InlineResponse2008
List User’s Contacts A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client.
-
#get_user_contacts_with_http_info(opts = {}) ⇒ Array<(InlineResponse2008, Fixnum, Hash)>
List User's Contacts A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client.
-
#initialize(api_client = ApiClient.default) ⇒ Contacts
constructor
A new instance of Contacts.
-
#search_company_contacts(search_key, opts = {}) ⇒ InlineResponse2005
Search Company Contacts A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client.
-
#search_company_contacts_with_http_info(search_key, opts = {}) ⇒ Array<(InlineResponse2005, Fixnum, Hash)>
Search Company Contacts A user under an organization's Zoom account has internal users listed under Company Contacts in the Zoom Client.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ Contacts
Returns a new instance of Contacts.
19 20 21 |
# File 'lib/zoom_us/contacts.rb', line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/zoom_us/contacts.rb', line 17 def api_client @api_client end |
Instance Method Details
#get_user_contact(contact_id, opts = {}) ⇒ InlineResponse2009
Get User’s Contact Details A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client. A Zoom user can also add another Zoom user as a [contact](support.zoom.us/hc/en-us/articles/115004055706-Managing-Contacts). Call this API to get information on a specific contact of the Zoom user. <p style="background-color:#e1f5fe; color:#01579b; padding:8px"> Note: This API only supports user-managed <a href="marketplace.zoom.us/docs/guides/getting-started/app-types/create-oauth-app">OAuth app</a>.</p>
Scope: ‘chat_contact:read`
28 29 30 31 |
# File 'lib/zoom_us/contacts.rb', line 28 def get_user_contact(contact_id, opts = {}) data, _status_code, _headers = get_user_contact_with_http_info(contact_id, opts) data end |
#get_user_contact_with_http_info(contact_id, opts = {}) ⇒ Array<(InlineResponse2009, Fixnum, Hash)>
Get User's Contact Details A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client. A Zoom user can also add another Zoom user as a [contact](support.zoom.us/hc/en-us/articles/115004055706-Managing-Contacts). Call this API to get information on a specific contact of the Zoom user. <p style="background-color:#e1f5fe; color:#01579b; padding:8px"> <b>Note: </b>This API only supports <b>user-managed</b> <a href="marketplace.zoom.us/docs/guides/getting-started/app-types/create-oauth-app">OAuth app</a>.</p><br> Scope: `chat_contact:read`<br>
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
# File 'lib/zoom_us/contacts.rb', line 39 def get_user_contact_with_http_info(contact_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ContactsApi.get_user_contact ...' end # verify the required parameter 'contact_id' is set if @api_client.config.client_side_validation && contact_id.nil? fail ArgumentError, "Missing the required parameter 'contact_id' when calling ContactsApi.get_user_contact" end # resource path local_var_path = '/chat/users/me/contacts/{contactId}'.sub('{' + 'contactId' + '}', contact_id.to_s) # query parameters query_params = {} query_params[:'query_presence_status'] = opts[:'query_presence_status'] if !opts[:'query_presence_status'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/xml']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'multipart/form-data']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['OAuth'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'InlineResponse2009') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContactsApi#get_user_contact\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_user_contacts(opts = {}) ⇒ InlineResponse2008
List User’s Contacts A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client. A Zoom user can also add another Zoom user as a [contact](support.zoom.us/hc/en-us/articles/115004055706-Managing-Contacts). Call this API to list all the contacts of a Zoom user. Zoom contacts are categorized into "company contacts" and "external contacts". You must specify the contact type in the ‘type` query parameter. If you do not specify, by default, the type will be set as company contact. <p style="background-color:#e1f5fe; color:#01579b; padding:8px"> Note: This API only supports user-managed <a href="marketplace.zoom.us/docs/guides/getting-started/app-types/create-oauth-app">OAuth app</a>.</p>
Scope: `chat_contact:read`
86 87 88 89 |
# File 'lib/zoom_us/contacts.rb', line 86 def get_user_contacts(opts = {}) data, _status_code, _headers = get_user_contacts_with_http_info(opts) data end |
#get_user_contacts_with_http_info(opts = {}) ⇒ Array<(InlineResponse2008, Fixnum, Hash)>
List User's Contacts A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client. A Zoom user can also add another Zoom user as a [contact](support.zoom.us/hc/en-us/articles/115004055706-Managing-Contacts). Call this API to list all the contacts of a Zoom user. Zoom contacts are categorized into "company contacts" and "external contacts". You must specify the contact type in the `type` query parameter. If you do not specify, by default, the type will be set as company contact. <p style="background-color:#e1f5fe; color:#01579b; padding:8px"> <b>Note: </b> This API only supports <b>user-managed</b> <a href="marketplace.zoom.us/docs/guides/getting-started/app-types/create-oauth-app">OAuth app</a>.</p><br> Scope: `chat_contact:read`<br>
98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 |
# File 'lib/zoom_us/contacts.rb', line 98 def get_user_contacts_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ContactsApi.get_user_contacts ...' end if @api_client.config.client_side_validation && !opts[:'page_size'].nil? && opts[:'page_size'] > 50 fail ArgumentError, 'invalid value for "opts[:"page_size"]" when calling ContactsApi.get_user_contacts, must be smaller than or equal to 50.' end # resource path local_var_path = '/chat/users/me/contacts' # query parameters query_params = {} query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil? query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil? query_params[:'next_page_token'] = opts[:'next_page_token'] if !opts[:'next_page_token'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/xml']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'multipart/form-data']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['OAuth'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'InlineResponse2008') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContactsApi#get_user_contacts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#search_company_contacts(search_key, opts = {}) ⇒ InlineResponse2005
Search Company Contacts A user under an organization’s Zoom account has internal users listed under Company Contacts in the Zoom Client. Use this API to search users that are in the company contacts of a Zoom account. Using the ‘search_key` query parameter, provide either first name, last name or the email address of the user that you would like to search for. Optionally, set `query_presence_status` to `true` in order to include the presence status of a contact.
Scopes: `contact:read:admin`, `contact:read`
148 149 150 151 |
# File 'lib/zoom_us/contacts.rb', line 148 def search_company_contacts(search_key, opts = {}) data, _status_code, _headers = search_company_contacts_with_http_info(search_key, opts) data end |
#search_company_contacts_with_http_info(search_key, opts = {}) ⇒ Array<(InlineResponse2005, Fixnum, Hash)>
Search Company Contacts A user under an organization's Zoom account has internal users listed under Company Contacts in the Zoom Client. Use this API to search users that are in the company contacts of a Zoom account. Using the `search_key` query parameter, provide either first name, last name or the email address of the user that you would like to search for. Optionally, set `query_presence_status` to `true` in order to include the presence status of a contact. <br><br> Scopes: `contact:read:admin`, `contact:read`<br>
161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 |
# File 'lib/zoom_us/contacts.rb', line 161 def search_company_contacts_with_http_info(search_key, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ContactsApi.search_company_contacts ...' end # verify the required parameter 'search_key' is set if @api_client.config.client_side_validation && search_key.nil? fail ArgumentError, "Missing the required parameter 'search_key' when calling ContactsApi.search_company_contacts" end if @api_client.config.client_side_validation && !opts[:'page_size'].nil? && opts[:'page_size'] > 25 fail ArgumentError, 'invalid value for "opts[:"page_size"]" when calling ContactsApi.search_company_contacts, must be smaller than or equal to 25.' end # resource path local_var_path = '/contacts' # query parameters query_params = {} query_params[:'search_key'] = search_key query_params[:'query_presence_status'] = opts[:'query_presence_status'] if !opts[:'query_presence_status'].nil? query_params[:'page_size'] = opts[:'page_size'] if !opts[:'page_size'].nil? query_params[:'next_page_token'] = opts[:'next_page_token'] if !opts[:'next_page_token'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/xml']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'multipart/form-data']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['OAuth'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'InlineResponse2005') if @api_client.config.debugging @api_client.config.logger.debug "API called: ContactsApi#search_company_contacts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |