Class: GongAPI::DataPrivacyApi
- Inherits:
-
Object
- Object
- GongAPI::DataPrivacyApi
- Defined in:
- lib/gong_api/api/data_privacy_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#find_all_references_to_email_address_using_get(email_address, opts = {}) ⇒ EmailAddressReferences
Retrieve all references to an email address.
-
#find_all_references_to_email_address_using_get_with_http_info(email_address, opts = {}) ⇒ Array<(EmailAddressReferences, Integer, Hash)>
Retrieve all references to an email address.
-
#find_all_references_to_phone_number_using_get(phone_number, opts = {}) ⇒ PhoneNumberReferences
Retrieve all references to a phone number.
-
#find_all_references_to_phone_number_using_get_with_http_info(phone_number, opts = {}) ⇒ Array<(PhoneNumberReferences, Integer, Hash)>
Retrieve all references to a phone number.
-
#initialize(api_client = ApiClient.default) ⇒ DataPrivacyApi
constructor
A new instance of DataPrivacyApi.
-
#purge_email_address_using_post(email_address, opts = {}) ⇒ BaseResponse
Delete the email address, and all associated elements (/v2/data-privacy/erase-data-for-email-address) Given an email address, this endpoint deletes from the Gong system any calls or email messages that reference this address.
-
#purge_email_address_using_post_with_http_info(email_address, opts = {}) ⇒ Array<(BaseResponse, Integer, Hash)>
Delete the email address, and all associated elements (/v2/data-privacy/erase-data-for-email-address) Given an email address, this endpoint deletes from the Gong system any calls or email messages that reference this address.
-
#purge_phone_number_using_post(phone_number, opts = {}) ⇒ BaseResponse
Delete the phone number, and all associated elements (/v2/data-privacy/erase-data-for-phone-number) Given a phone number, this endpoint deletes from the Gong system any leads or contacts with a matching phone number or mobile phone number.
-
#purge_phone_number_using_post_with_http_info(phone_number, opts = {}) ⇒ Array<(BaseResponse, Integer, Hash)>
Delete the phone number, and all associated elements (/v2/data-privacy/erase-data-for-phone-number) Given a phone number, this endpoint deletes from the Gong system any leads or contacts with a matching phone number or mobile phone number.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ DataPrivacyApi
Returns a new instance of DataPrivacyApi.
16 17 18 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 16 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
14 15 16 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 14 def api_client @api_client end |
Instance Method Details
#find_all_references_to_email_address_using_get(email_address, opts = {}) ⇒ EmailAddressReferences
Retrieve all references to an email address. (/v2/data-privacy/data-for-email-address) Shows the elements in the Gong system that reference the given email address. Given an emails address, this endpoint returns details of all calls and email messages that reference this address, and any leads or contacts with this email address. When accessed through a Bearer token authorization method, this endpoint requires the scope ‘api:data-privacy:read’.
24 25 26 27 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 24 def find_all_references_to_email_address_using_get(email_address, opts = {}) data, _status_code, _headers = find_all_references_to_email_address_using_get_with_http_info(email_address, opts) data end |
#find_all_references_to_email_address_using_get_with_http_info(email_address, opts = {}) ⇒ Array<(EmailAddressReferences, Integer, Hash)>
Retrieve all references to an email address. (/v2/data-privacy/data-for-email-address) Shows the elements in the Gong system that reference the given email address. Given an emails address, this endpoint returns details of all calls and email messages that reference this address, and any leads or contacts with this email address. When accessed through a Bearer token authorization method, this endpoint requires the scope 'api:data-privacy:read'.
34 35 36 37 38 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 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 34 def find_all_references_to_email_address_using_get_with_http_info(email_address, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: DataPrivacyApi.find_all_references_to_email_address_using_get ...' end # verify the required parameter 'email_address' is set if @api_client.config.client_side_validation && email_address.nil? fail ArgumentError, "Missing the required parameter 'email_address' when calling DataPrivacyApi.find_all_references_to_email_address_using_get" end # resource path local_var_path = '/v2/data-privacy/data-for-email-address' # query parameters query_params = opts[:query_params] || {} query_params[:'emailAddress'] = email_address # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'EmailAddressReferences' auth_names = opts[:auth_names] || [] 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 => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: DataPrivacyApi#find_all_references_to_email_address_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#find_all_references_to_phone_number_using_get(phone_number, opts = {}) ⇒ PhoneNumberReferences
Retrieve all references to a phone number. (/v2/data-privacy/data-for-phone-number) Shows the elements in the Gong system that reference the given phone number. Given a phone number, this endpoint returns details of any leads or contacts with this phone number and their associated calls and email messages. When accessed through a Bearer token authorization method, this endpoint requires the scope ‘api:data-privacy:read’.
81 82 83 84 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 81 def find_all_references_to_phone_number_using_get(phone_number, opts = {}) data, _status_code, _headers = find_all_references_to_phone_number_using_get_with_http_info(phone_number, opts) data end |
#find_all_references_to_phone_number_using_get_with_http_info(phone_number, opts = {}) ⇒ Array<(PhoneNumberReferences, Integer, Hash)>
Retrieve all references to a phone number. (/v2/data-privacy/data-for-phone-number) Shows the elements in the Gong system that reference the given phone number. Given a phone number, this endpoint returns details of any leads or contacts with this phone number and their associated calls and email messages. When accessed through a Bearer token authorization method, this endpoint requires the scope 'api:data-privacy:read'.
91 92 93 94 95 96 97 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 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 91 def find_all_references_to_phone_number_using_get_with_http_info(phone_number, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: DataPrivacyApi.find_all_references_to_phone_number_using_get ...' end # verify the required parameter 'phone_number' is set if @api_client.config.client_side_validation && phone_number.nil? fail ArgumentError, "Missing the required parameter 'phone_number' when calling DataPrivacyApi.find_all_references_to_phone_number_using_get" end # resource path local_var_path = '/v2/data-privacy/data-for-phone-number' # query parameters query_params = opts[:query_params] || {} query_params[:'phoneNumber'] = phone_number # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'PhoneNumberReferences' auth_names = opts[:auth_names] || [] 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 => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: DataPrivacyApi#find_all_references_to_phone_number_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#purge_email_address_using_post(email_address, opts = {}) ⇒ BaseResponse
Delete the email address, and all associated elements (/v2/data-privacy/erase-data-for-email-address) Given an email address, this endpoint deletes from the Gong system any calls or email messages that reference this address. Email messages sent to or from the address are deleted. Calls where the email address appears (as a lead, contact, attendee or speaker) are deleted. Leads or Contacts with the email address are deleted. The deletion is not immediate, and may take several hours to complete. This endpoint contains a data integrity protection mechanism to prevent the deletion of an abnormal number of objects. If the deletion fails please contact support at [email protected] Delete the data from your CRM and email system before performing this operation so that private data is not re-imported into Gong. When accessed through a Bearer token authorization method, this endpoint requires the scope ‘api:data-privacy:delete’.
138 139 140 141 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 138 def purge_email_address_using_post(email_address, opts = {}) data, _status_code, _headers = purge_email_address_using_post_with_http_info(email_address, opts) data end |
#purge_email_address_using_post_with_http_info(email_address, opts = {}) ⇒ Array<(BaseResponse, Integer, Hash)>
Delete the email address, and all associated elements (/v2/data-privacy/erase-data-for-email-address) Given an email address, this endpoint deletes from the Gong system any calls or email messages that reference this address. Email messages sent to or from the address are deleted. Calls where the email address appears (as a lead, contact, attendee or speaker) are deleted. Leads or Contacts with the email address are deleted. The deletion is not immediate, and may take several hours to complete. This endpoint contains a data integrity protection mechanism to prevent the deletion of an abnormal number of objects. If the deletion fails please contact support at [email protected] Delete the data from your CRM and email system before performing this operation so that private data is not re-imported into Gong. When accessed through a Bearer token authorization method, this endpoint requires the scope 'api:data-privacy:delete'.
148 149 150 151 152 153 154 155 156 157 158 159 160 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 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 148 def purge_email_address_using_post_with_http_info(email_address, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: DataPrivacyApi.purge_email_address_using_post ...' end # verify the required parameter 'email_address' is set if @api_client.config.client_side_validation && email_address.nil? fail ArgumentError, "Missing the required parameter 'email_address' when calling DataPrivacyApi.purge_email_address_using_post" end # resource path local_var_path = '/v2/data-privacy/erase-data-for-email-address' # query parameters query_params = opts[:query_params] || {} query_params[:'emailAddress'] = email_address # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'BaseResponse' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: DataPrivacyApi#purge_email_address_using_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#purge_phone_number_using_post(phone_number, opts = {}) ⇒ BaseResponse
Delete the phone number, and all associated elements (/v2/data-privacy/erase-data-for-phone-number) Given a phone number, this endpoint deletes from the Gong system any leads or contacts with a matching phone number or mobile phone number. Email messages sent to or from these leads/contacts are deleted. Calls where the leads/contacts appear are deleted. The deletion is not immediate, and may take several hours to complete. This endpoint contains a data integrity protection mechanism to prevent the deletion of an abnormal number of objects. If the deletion fails please contact support at [email protected] Delete the data from your CRM and email system before performing this operation so that private data is not re-imported into Gong. When accessed through a Bearer token authorization method, this endpoint requires the scope ‘api:data-privacy:delete’.
195 196 197 198 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 195 def purge_phone_number_using_post(phone_number, opts = {}) data, _status_code, _headers = purge_phone_number_using_post_with_http_info(phone_number, opts) data end |
#purge_phone_number_using_post_with_http_info(phone_number, opts = {}) ⇒ Array<(BaseResponse, Integer, Hash)>
Delete the phone number, and all associated elements (/v2/data-privacy/erase-data-for-phone-number) Given a phone number, this endpoint deletes from the Gong system any leads or contacts with a matching phone number or mobile phone number. Email messages sent to or from these leads/contacts are deleted. Calls where the leads/contacts appear are deleted. The deletion is not immediate, and may take several hours to complete. This endpoint contains a data integrity protection mechanism to prevent the deletion of an abnormal number of objects. If the deletion fails please contact support at [email protected] Delete the data from your CRM and email system before performing this operation so that private data is not re-imported into Gong. When accessed through a Bearer token authorization method, this endpoint requires the scope 'api:data-privacy:delete'.
205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 |
# File 'lib/gong_api/api/data_privacy_api.rb', line 205 def purge_phone_number_using_post_with_http_info(phone_number, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: DataPrivacyApi.purge_phone_number_using_post ...' end # verify the required parameter 'phone_number' is set if @api_client.config.client_side_validation && phone_number.nil? fail ArgumentError, "Missing the required parameter 'phone_number' when calling DataPrivacyApi.purge_phone_number_using_post" end # resource path local_var_path = '/v2/data-privacy/erase-data-for-phone-number' # query parameters query_params = opts[:query_params] || {} query_params[:'phoneNumber'] = phone_number # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'BaseResponse' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: DataPrivacyApi#purge_phone_number_using_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |