merge_crm_client 1.0.0 → 1.0.1

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.
Files changed (37) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +9 -4
  3. data/docs/Contact.md +3 -3
  4. data/docs/ContactRequest.md +6 -0
  5. data/docs/OpportunitiesApi.md +154 -0
  6. data/docs/PatchedOpportunityEndpointRequest.md +18 -0
  7. data/docs/PatchedOpportunityRequest.md +40 -0
  8. data/docs/RemoteResponse.md +3 -1
  9. data/docs/ResponseTypeEnum.md +15 -0
  10. data/docs/SyncStatus.md +2 -2
  11. data/lib/merge_crm_client/api/opportunities_api.rb +148 -0
  12. data/lib/merge_crm_client/models/account_request.rb +2 -2
  13. data/lib/merge_crm_client/models/contact_request.rb +36 -3
  14. data/lib/merge_crm_client/models/data_passthrough_request.rb +1 -1
  15. data/lib/merge_crm_client/models/engagement_request.rb +2 -2
  16. data/lib/merge_crm_client/models/issue.rb +1 -1
  17. data/lib/merge_crm_client/models/issue_status_enum.rb +1 -1
  18. data/lib/merge_crm_client/models/lead_request.rb +2 -2
  19. data/lib/merge_crm_client/models/meta_response.rb +1 -1
  20. data/lib/merge_crm_client/models/note_request.rb +2 -2
  21. data/lib/merge_crm_client/models/opportunity_request.rb +2 -2
  22. data/lib/merge_crm_client/models/patched_opportunity_endpoint_request.rb +223 -0
  23. data/lib/merge_crm_client/models/patched_opportunity_request.rb +365 -0
  24. data/lib/merge_crm_client/models/remote_response.rb +14 -11
  25. data/lib/merge_crm_client/models/response_type_enum.rb +45 -0
  26. data/lib/merge_crm_client/models/sync_status.rb +0 -10
  27. data/lib/merge_crm_client/version.rb +1 -1
  28. data/lib/merge_crm_client.rb +3 -0
  29. data/spec/api/contacts_api_spec.rb +1 -13
  30. data/spec/api/opportunities_api_spec.rb +26 -0
  31. data/spec/models/contact_request_spec.rb +18 -0
  32. data/spec/models/issue_status_enum_spec.rb +0 -7
  33. data/spec/models/patched_opportunity_endpoint_request_spec.rb +34 -0
  34. data/spec/models/patched_opportunity_request_spec.rb +100 -0
  35. data/spec/models/remote_response_spec.rb +6 -0
  36. data/spec/models/response_type_enum_spec.rb +28 -0
  37. metadata +100 -88
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6065881a9e8e2b63553cf029a9801cf271f572df3177f7cd893d7adf0cc9c1ac
4
- data.tar.gz: 6926061992d1506875ec4e0d07f1c635dd9ea64b8c6e78d9f56f47d43632afe7
3
+ metadata.gz: d3ebfa647509fe4e5e8e96746dd481233f610a3684953d001dcd052c1aac7e07
4
+ data.tar.gz: a0cc29e1f7738feccc74cee048aabc2635e219644e341dcdcf03e1a248161473
5
5
  SHA512:
6
- metadata.gz: 7e86dfdb7d343f73b6d0ae111da6449dbbdaa24c4df596a6f30dba204c55d6e1022d5f656d1244d2bb2299b48f6d2af6df3a68784a8c59a5e20c6331d1d323ee
7
- data.tar.gz: 9fda8573fc669b382c863610e3d42856b24227782e3b8bc005893955058c9ad1006a28338972006532f3f48b74bfc4ad9b77f5c85c2ab26c0e210afbd3cf7ce4
6
+ metadata.gz: 0f9d7be28205f7235c9f0bfd3a2ff199fbfeab55b5dbfd8d21551a1d9d5fbfde29cf7be24efb57f4071ad34fb247e8e4f50c35a2b45af7e71e0d91859beb6345
7
+ data.tar.gz: 35a1fc27e5aba3f97482d1ddd4a1e720e083dc42976e60ad15f70bf4fd9768532d2a6ca697e6f9244daf3517e9dcae738d0b05070e0cef6ddfebe00b095ad560
data/README.md CHANGED
@@ -7,7 +7,7 @@ The unified API for building rich integrations with multiple CRM platforms.
7
7
  This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
8
8
 
9
9
  - API version: 1.0
10
- - Package version: 1.0.0
10
+ - Package version: 1.0.1
11
11
  - Build package: org.openapitools.codegen.languages.RubyClientCodegen
12
12
  For more information, please visit [https://www.merge.dev/](https://www.merge.dev/)
13
13
 
@@ -24,16 +24,16 @@ gem build merge_crm_client.gemspec
24
24
  Then either install the gem locally:
25
25
 
26
26
  ```shell
27
- gem install ./merge_crm_client-1.0.0.gem
27
+ gem install ./merge_crm_client-1.0.1.gem
28
28
  ```
29
29
 
30
- (for development, run `gem install --dev ./merge_crm_client-1.0.0.gem` to install the development dependencies)
30
+ (for development, run `gem install --dev ./merge_crm_client-1.0.1.gem` to install the development dependencies)
31
31
 
32
32
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
33
33
 
34
34
  Finally add this to the Gemfile:
35
35
 
36
- gem 'merge_crm_client', '~> 1.0.0'
36
+ gem 'merge_crm_client', '~> 1.0.1'
37
37
 
38
38
  ### Install from Git
39
39
 
@@ -117,7 +117,9 @@ Class | Method | HTTP request | Description
117
117
  *MergeCRMClient::NotesApi* | [**notes_retrieve**](docs/NotesApi.md#notes_retrieve) | **GET** /notes/{id} |
118
118
  *MergeCRMClient::OpportunitiesApi* | [**opportunities_create**](docs/OpportunitiesApi.md#opportunities_create) | **POST** /opportunities |
119
119
  *MergeCRMClient::OpportunitiesApi* | [**opportunities_list**](docs/OpportunitiesApi.md#opportunities_list) | **GET** /opportunities |
120
+ *MergeCRMClient::OpportunitiesApi* | [**opportunities_meta_patch_retrieve**](docs/OpportunitiesApi.md#opportunities_meta_patch_retrieve) | **GET** /opportunities/meta/patch/{id} |
120
121
  *MergeCRMClient::OpportunitiesApi* | [**opportunities_meta_post_retrieve**](docs/OpportunitiesApi.md#opportunities_meta_post_retrieve) | **GET** /opportunities/meta/post |
122
+ *MergeCRMClient::OpportunitiesApi* | [**opportunities_partial_update**](docs/OpportunitiesApi.md#opportunities_partial_update) | **PATCH** /opportunities/{id} |
121
123
  *MergeCRMClient::OpportunitiesApi* | [**opportunities_retrieve**](docs/OpportunitiesApi.md#opportunities_retrieve) | **GET** /opportunities/{id} |
122
124
  *MergeCRMClient::PassthroughApi* | [**passthrough_create**](docs/PassthroughApi.md#passthrough_create) | **POST** /passthrough |
123
125
  *MergeCRMClient::RegenerateKeyApi* | [**regenerate_key_create**](docs/RegenerateKeyApi.md#regenerate_key_create) | **POST** /regenerate-key |
@@ -205,6 +207,8 @@ Class | Method | HTTP request | Description
205
207
  - [MergeCRMClient::PaginatedSyncStatusList](docs/PaginatedSyncStatusList.md)
206
208
  - [MergeCRMClient::PaginatedTaskList](docs/PaginatedTaskList.md)
207
209
  - [MergeCRMClient::PaginatedUserList](docs/PaginatedUserList.md)
210
+ - [MergeCRMClient::PatchedOpportunityEndpointRequest](docs/PatchedOpportunityEndpointRequest.md)
211
+ - [MergeCRMClient::PatchedOpportunityRequest](docs/PatchedOpportunityRequest.md)
208
212
  - [MergeCRMClient::PhoneNumber](docs/PhoneNumber.md)
209
213
  - [MergeCRMClient::PhoneNumberRequest](docs/PhoneNumberRequest.md)
210
214
  - [MergeCRMClient::RemoteData](docs/RemoteData.md)
@@ -212,6 +216,7 @@ Class | Method | HTTP request | Description
212
216
  - [MergeCRMClient::RemoteKeyForRegenerationRequest](docs/RemoteKeyForRegenerationRequest.md)
213
217
  - [MergeCRMClient::RemoteResponse](docs/RemoteResponse.md)
214
218
  - [MergeCRMClient::RequestFormatEnum](docs/RequestFormatEnum.md)
219
+ - [MergeCRMClient::ResponseTypeEnum](docs/ResponseTypeEnum.md)
215
220
  - [MergeCRMClient::Stage](docs/Stage.md)
216
221
  - [MergeCRMClient::SyncStatus](docs/SyncStatus.md)
217
222
  - [MergeCRMClient::SyncStatusStatusEnum](docs/SyncStatusStatusEnum.md)
data/docs/Contact.md CHANGED
@@ -9,9 +9,9 @@
9
9
  | **first_name** | **String** | The contact's first name. | [optional] |
10
10
  | **last_name** | **String** | The contact's last name. | [optional] |
11
11
  | **account** | **String** | | [optional] |
12
- | **addresses** | [**Array<Address>**](Address.md) | | [optional][readonly] |
13
- | **email_addresses** | [**Array<EmailAddress>**](EmailAddress.md) | | [optional][readonly] |
14
- | **phone_numbers** | [**Array<PhoneNumber>**](PhoneNumber.md) | | [optional][readonly] |
12
+ | **addresses** | [**Array<Address>**](Address.md) | | [optional] |
13
+ | **email_addresses** | [**Array<EmailAddress>**](EmailAddress.md) | | [optional] |
14
+ | **phone_numbers** | [**Array<PhoneNumber>**](PhoneNumber.md) | | [optional] |
15
15
  | **last_activity_at** | **Time** | When the contact's last activity occurred. | [optional] |
16
16
  | **remote_created_at** | **Time** | When the third party's contact was created. | [optional] |
17
17
  | **remote_data** | [**Array<RemoteData>**](RemoteData.md) | | [optional][readonly] |
@@ -8,6 +8,9 @@
8
8
  | **first_name** | **String** | The contact's first name. | [optional] |
9
9
  | **last_name** | **String** | The contact's last name. | [optional] |
10
10
  | **account** | **String** | | [optional] |
11
+ | **addresses** | [**Array<AddressRequest>**](AddressRequest.md) | | [optional] |
12
+ | **email_addresses** | [**Array<EmailAddressRequest>**](EmailAddressRequest.md) | | [optional] |
13
+ | **phone_numbers** | [**Array<PhoneNumberRequest>**](PhoneNumberRequest.md) | | [optional] |
11
14
  | **last_activity_at** | **Time** | When the contact's last activity occurred. | [optional] |
12
15
  | **remote_created_at** | **Time** | When the third party's contact was created. | [optional] |
13
16
  | **integration_params** | [**Hash<String, AnyType>**](AnyType.md) | | [optional] |
@@ -23,6 +26,9 @@ instance = MergeCRMClient::ContactRequest.new(
23
26
  first_name: Gil,
24
27
  last_name: Feig,
25
28
  account: 0958cbc6-6040-430a-848e-aafacbadf4ae,
29
+ addresses: [{"street_1":"50 Bowling Green Dr","street_2":"Golden Gate Park","city":"San Francisco","state":"CA","postal_code":"94122","country":"USA","address_type":"Shipping"}],
30
+ email_addresses: [{"email_address":"hello@merge.dev","email_address_type":"Work"}],
31
+ phone_numbers: [{"phone_number":"+13785579223","phone_number_type":"Mobile"}],
26
32
  last_activity_at: 2022-02-10T00:00Z,
27
33
  remote_created_at: 2021-11-10T00:00Z,
28
34
  integration_params: null,
@@ -6,7 +6,9 @@ All URIs are relative to *https://api.merge.dev/api/crm/v1*
6
6
  | ------ | ------------ | ----------- |
7
7
  | [**opportunities_create**](OpportunitiesApi.md#opportunities_create) | **POST** /opportunities | |
8
8
  | [**opportunities_list**](OpportunitiesApi.md#opportunities_list) | **GET** /opportunities | |
9
+ | [**opportunities_meta_patch_retrieve**](OpportunitiesApi.md#opportunities_meta_patch_retrieve) | **GET** /opportunities/meta/patch/{id} | |
9
10
  | [**opportunities_meta_post_retrieve**](OpportunitiesApi.md#opportunities_meta_post_retrieve) | **GET** /opportunities/meta/post | |
11
+ | [**opportunities_partial_update**](OpportunitiesApi.md#opportunities_partial_update) | **PATCH** /opportunities/{id} | |
10
12
  | [**opportunities_retrieve**](OpportunitiesApi.md#opportunities_retrieve) | **GET** /opportunities/{id} | |
11
13
 
12
14
 
@@ -192,6 +194,79 @@ end
192
194
  - **Accept**: application/json
193
195
 
194
196
 
197
+ ## opportunities_meta_patch_retrieve
198
+
199
+ > <MetaResponse> opportunities_meta_patch_retrieve(x_account_token, id)
200
+
201
+
202
+
203
+ Returns metadata for `Opportunity` PATCHs.
204
+
205
+ ### Examples
206
+
207
+ ```ruby
208
+ require 'time'
209
+ require 'merge_crm_client'
210
+ # setup authorization
211
+ MergeCRMClient.configure do |config|
212
+ # Configure API key authorization: tokenAuth
213
+ config.api_key['tokenAuth'] = 'YOUR API KEY'
214
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
215
+ # config.api_key_prefix['tokenAuth'] = 'Bearer'
216
+ end
217
+
218
+ api_instance = MergeCRMClient::OpportunitiesApi.new
219
+ x_account_token = 'x_account_token_example' # String | Token identifying the end user.
220
+ id = TODO # String |
221
+
222
+ begin
223
+
224
+ result = api_instance.opportunities_meta_patch_retrieve(x_account_token, id)
225
+ p result
226
+ rescue MergeCRMClient::ApiError => e
227
+ puts "Error when calling OpportunitiesApi->opportunities_meta_patch_retrieve: #{e}"
228
+ end
229
+ ```
230
+
231
+ #### Using the opportunities_meta_patch_retrieve_with_http_info variant
232
+
233
+ This returns an Array which contains the response data, status code and headers.
234
+
235
+ > <Array(<MetaResponse>, Integer, Hash)> opportunities_meta_patch_retrieve_with_http_info(x_account_token, id)
236
+
237
+ ```ruby
238
+ begin
239
+
240
+ data, status_code, headers = api_instance.opportunities_meta_patch_retrieve_with_http_info(x_account_token, id)
241
+ p status_code # => 2xx
242
+ p headers # => { ... }
243
+ p data # => <MetaResponse>
244
+ rescue MergeCRMClient::ApiError => e
245
+ puts "Error when calling OpportunitiesApi->opportunities_meta_patch_retrieve_with_http_info: #{e}"
246
+ end
247
+ ```
248
+
249
+ ### Parameters
250
+
251
+ | Name | Type | Description | Notes |
252
+ | ---- | ---- | ----------- | ----- |
253
+ | **x_account_token** | **String** | Token identifying the end user. | |
254
+ | **id** | [**String**](.md) | | |
255
+
256
+ ### Return type
257
+
258
+ [**MetaResponse**](MetaResponse.md)
259
+
260
+ ### Authorization
261
+
262
+ [tokenAuth](../README.md#tokenAuth)
263
+
264
+ ### HTTP request headers
265
+
266
+ - **Content-Type**: Not defined
267
+ - **Accept**: application/json
268
+
269
+
195
270
  ## opportunities_meta_post_retrieve
196
271
 
197
272
  > <MetaResponse> opportunities_meta_post_retrieve(x_account_token)
@@ -263,6 +338,85 @@ end
263
338
  - **Accept**: application/json
264
339
 
265
340
 
341
+ ## opportunities_partial_update
342
+
343
+ > <OpportunityResponse> opportunities_partial_update(x_account_token, id, patched_opportunity_endpoint_request, opts)
344
+
345
+
346
+
347
+ ### Examples
348
+
349
+ ```ruby
350
+ require 'time'
351
+ require 'merge_crm_client'
352
+ # setup authorization
353
+ MergeCRMClient.configure do |config|
354
+ # Configure API key authorization: tokenAuth
355
+ config.api_key['tokenAuth'] = 'YOUR API KEY'
356
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
357
+ # config.api_key_prefix['tokenAuth'] = 'Bearer'
358
+ end
359
+
360
+ api_instance = MergeCRMClient::OpportunitiesApi.new
361
+ x_account_token = 'x_account_token_example' # String | Token identifying the end user.
362
+ id = TODO # String |
363
+ patched_opportunity_endpoint_request = MergeCRMClient::PatchedOpportunityEndpointRequest.new({model: MergeCRMClient::PatchedOpportunityRequest.new}) # PatchedOpportunityEndpointRequest |
364
+ opts = {
365
+ is_debug_mode: true, # Boolean | Whether to include debug fields (such as log file links) in the response.
366
+ run_async: true # Boolean | Whether or not third-party updates should be run asynchronously.
367
+ }
368
+
369
+ begin
370
+
371
+ result = api_instance.opportunities_partial_update(x_account_token, id, patched_opportunity_endpoint_request, opts)
372
+ p result
373
+ rescue MergeCRMClient::ApiError => e
374
+ puts "Error when calling OpportunitiesApi->opportunities_partial_update: #{e}"
375
+ end
376
+ ```
377
+
378
+ #### Using the opportunities_partial_update_with_http_info variant
379
+
380
+ This returns an Array which contains the response data, status code and headers.
381
+
382
+ > <Array(<OpportunityResponse>, Integer, Hash)> opportunities_partial_update_with_http_info(x_account_token, id, patched_opportunity_endpoint_request, opts)
383
+
384
+ ```ruby
385
+ begin
386
+
387
+ data, status_code, headers = api_instance.opportunities_partial_update_with_http_info(x_account_token, id, patched_opportunity_endpoint_request, opts)
388
+ p status_code # => 2xx
389
+ p headers # => { ... }
390
+ p data # => <OpportunityResponse>
391
+ rescue MergeCRMClient::ApiError => e
392
+ puts "Error when calling OpportunitiesApi->opportunities_partial_update_with_http_info: #{e}"
393
+ end
394
+ ```
395
+
396
+ ### Parameters
397
+
398
+ | Name | Type | Description | Notes |
399
+ | ---- | ---- | ----------- | ----- |
400
+ | **x_account_token** | **String** | Token identifying the end user. | |
401
+ | **id** | [**String**](.md) | | |
402
+ | **patched_opportunity_endpoint_request** | [**PatchedOpportunityEndpointRequest**](PatchedOpportunityEndpointRequest.md) | | |
403
+ | **is_debug_mode** | **Boolean** | Whether to include debug fields (such as log file links) in the response. | [optional] |
404
+ | **run_async** | **Boolean** | Whether or not third-party updates should be run asynchronously. | [optional] |
405
+
406
+ ### Return type
407
+
408
+ [**OpportunityResponse**](OpportunityResponse.md)
409
+
410
+ ### Authorization
411
+
412
+ [tokenAuth](../README.md#tokenAuth)
413
+
414
+ ### HTTP request headers
415
+
416
+ - **Content-Type**: application/json, application/x-www-form-urlencoded, multipart/form-data
417
+ - **Accept**: application/json
418
+
419
+
266
420
  ## opportunities_retrieve
267
421
 
268
422
  > <Opportunity> opportunities_retrieve(x_account_token, id, opts)
@@ -0,0 +1,18 @@
1
+ # MergeCRMClient::PatchedOpportunityEndpointRequest
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **model** | [**PatchedOpportunityRequest**](PatchedOpportunityRequest.md) | | |
8
+
9
+ ## Example
10
+
11
+ ```ruby
12
+ require 'merge_crm_client'
13
+
14
+ instance = MergeCRMClient::PatchedOpportunityEndpointRequest.new(
15
+ model: null
16
+ )
17
+ ```
18
+
@@ -0,0 +1,40 @@
1
+ # MergeCRMClient::PatchedOpportunityRequest
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **name** | **String** | The opportunity&#39;s name. | [optional] |
8
+ | **description** | **String** | The opportunity&#39;s description. | [optional] |
9
+ | **amount** | **Integer** | The opportunity&#39;s amount. | [optional] |
10
+ | **owner** | **String** | | [optional] |
11
+ | **account** | **String** | | [optional] |
12
+ | **stage** | **String** | | [optional] |
13
+ | **status** | [**OpportunityStatusEnum**](OpportunityStatusEnum.md) | The opportunity&#39;s status. | [optional] |
14
+ | **last_activity_at** | **Time** | When the opportunity&#39;s last activity occurred. | [optional] |
15
+ | **close_date** | **Time** | When the opportunity was closed. | [optional] |
16
+ | **remote_created_at** | **Time** | When the third party&#39;s opportunity was created. | [optional] |
17
+ | **integration_params** | [**Hash&lt;String, AnyType&gt;**](AnyType.md) | | [optional] |
18
+ | **linked_account_params** | [**Hash&lt;String, AnyType&gt;**](AnyType.md) | | [optional] |
19
+
20
+ ## Example
21
+
22
+ ```ruby
23
+ require 'merge_crm_client'
24
+
25
+ instance = MergeCRMClient::PatchedOpportunityRequest.new(
26
+ name: Needs Integrations,
27
+ description: Needs a Unified API for Integrations!,
28
+ amount: 100000,
29
+ owner: 0358cbc6-2040-430a-848e-aafacbadf3aa,
30
+ account: 0958cbc6-6040-430a-848e-aafacbadf4ae,
31
+ stage: 1968cbc6-6040-430a-848e-aafacbadf4ad,
32
+ status: WON,
33
+ last_activity_at: 2022-02-10T00:00Z,
34
+ close_date: 2022-02-10T00:00Z,
35
+ remote_created_at: 2021-11-10T00:00Z,
36
+ integration_params: null,
37
+ linked_account_params: null
38
+ )
39
+ ```
40
+
@@ -7,8 +7,9 @@
7
7
  | **method** | **String** | | |
8
8
  | **path** | **String** | | |
9
9
  | **status** | **Integer** | | |
10
- | **response** | [**Hash&lt;String, AnyType&gt;**](AnyType.md) | | |
10
+ | **response** | [**AnyType**](.md) | | |
11
11
  | **response_headers** | [**Hash&lt;String, AnyType&gt;**](AnyType.md) | | [optional] |
12
+ | **response_type** | [**ResponseTypeEnum**](ResponseTypeEnum.md) | | [optional] |
12
13
  | **headers** | [**Hash&lt;String, AnyType&gt;**](AnyType.md) | | [optional] |
13
14
 
14
15
  ## Example
@@ -22,6 +23,7 @@ instance = MergeCRMClient::RemoteResponse.new(
22
23
  status: 200,
23
24
  response: {&quot;scooters&quot;:[{&quot;company&quot;:&quot;Lime&quot;,&quot;model&quot;:&quot;Gen 2.5&quot;},{&quot;company&quot;:&quot;Bird&quot;,&quot;model&quot;:&quot;Bird Zero&quot;}]},
24
25
  response_headers: {&quot;X-Page-Token&quot;:&quot;value&quot;},
26
+ response_type: JSON,
25
27
  headers: {&quot;EXTRA-HEADER&quot;:&quot;value&quot;,&quot;Authorization&quot;:&quot;&lt;redacted&gt;&quot;}
26
28
  )
27
29
  ```
@@ -0,0 +1,15 @@
1
+ # MergeCRMClient::ResponseTypeEnum
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+
8
+ ## Example
9
+
10
+ ```ruby
11
+ require 'merge_crm_client'
12
+
13
+ instance = MergeCRMClient::ResponseTypeEnum.new()
14
+ ```
15
+
data/docs/SyncStatus.md CHANGED
@@ -6,8 +6,8 @@
6
6
  | ---- | ---- | ----------- | ----- |
7
7
  | **model_name** | **String** | | |
8
8
  | **model_id** | **String** | | |
9
- | **last_sync_start** | **Time** | | |
10
- | **next_sync_start** | **Time** | | |
9
+ | **last_sync_start** | **Time** | | [optional] |
10
+ | **next_sync_start** | **Time** | | [optional] |
11
11
  | **status** | [**SyncStatusStatusEnum**](SyncStatusStatusEnum.md) | | |
12
12
  | **is_initial_sync** | **Boolean** | | |
13
13
 
@@ -214,6 +214,74 @@ module MergeCRMClient
214
214
  return data, status_code, headers
215
215
  end
216
216
 
217
+ # Returns metadata for `Opportunity` PATCHs.
218
+ # @param x_account_token [String] Token identifying the end user.
219
+ # @param id [String]
220
+ # @param [Hash] opts the optional parameters
221
+ # @return [MetaResponse]
222
+ def opportunities_meta_patch_retrieve(x_account_token, id, opts = {})
223
+ data, _status_code, _headers = opportunities_meta_patch_retrieve_with_http_info(x_account_token, id, opts)
224
+ data
225
+ end
226
+
227
+ # Returns metadata for &#x60;Opportunity&#x60; PATCHs.
228
+ # @param x_account_token [String] Token identifying the end user.
229
+ # @param id [String]
230
+ # @param [Hash] opts the optional parameters
231
+ # @return [Array<(MetaResponse, Integer, Hash)>] MetaResponse data, response status code and response headers
232
+ def opportunities_meta_patch_retrieve_with_http_info(x_account_token, id, opts = {})
233
+ if @api_client.config.debugging
234
+ @api_client.config.logger.debug 'Calling API: OpportunitiesApi.opportunities_meta_patch_retrieve ...'
235
+ end
236
+ # verify the required parameter 'x_account_token' is set
237
+ if @api_client.config.client_side_validation && x_account_token.nil?
238
+ fail ArgumentError, "Missing the required parameter 'x_account_token' when calling OpportunitiesApi.opportunities_meta_patch_retrieve"
239
+ end
240
+ # verify the required parameter 'id' is set
241
+ if @api_client.config.client_side_validation && id.nil?
242
+ fail ArgumentError, "Missing the required parameter 'id' when calling OpportunitiesApi.opportunities_meta_patch_retrieve"
243
+ end
244
+ # resource path
245
+ local_var_path = '/opportunities/meta/patch/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
246
+
247
+ # query parameters
248
+ query_params = opts[:query_params] || {}
249
+
250
+ # header parameters
251
+ header_params = opts[:header_params] || {}
252
+ # HTTP header 'Accept' (if needed)
253
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
254
+ header_params[:'X-Account-Token'] = x_account_token
255
+
256
+ # form parameters
257
+ form_params = opts[:form_params] || {}
258
+
259
+ # http body (model)
260
+ post_body = opts[:debug_body]
261
+
262
+ # return_type
263
+ return_type = opts[:debug_return_type] || 'MetaResponse'
264
+
265
+ # auth_names
266
+ auth_names = opts[:debug_auth_names] || ['tokenAuth']
267
+
268
+ new_options = opts.merge(
269
+ :operation => :"OpportunitiesApi.opportunities_meta_patch_retrieve",
270
+ :header_params => header_params,
271
+ :query_params => query_params,
272
+ :form_params => form_params,
273
+ :body => post_body,
274
+ :auth_names => auth_names,
275
+ :return_type => return_type
276
+ )
277
+
278
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
279
+ if @api_client.config.debugging
280
+ @api_client.config.logger.debug "API called: OpportunitiesApi#opportunities_meta_patch_retrieve\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
281
+ end
282
+ return data, status_code, headers
283
+ end
284
+
217
285
  # Returns metadata for `Opportunity` POSTs.
218
286
  # @param x_account_token [String] Token identifying the end user.
219
287
  # @param [Hash] opts the optional parameters
@@ -276,6 +344,86 @@ module MergeCRMClient
276
344
  return data, status_code, headers
277
345
  end
278
346
 
347
+ # @param x_account_token [String] Token identifying the end user.
348
+ # @param id [String]
349
+ # @param patched_opportunity_endpoint_request [PatchedOpportunityEndpointRequest]
350
+ # @param [Hash] opts the optional parameters
351
+ # @option opts [Boolean] :is_debug_mode Whether to include debug fields (such as log file links) in the response.
352
+ # @option opts [Boolean] :run_async Whether or not third-party updates should be run asynchronously.
353
+ # @return [OpportunityResponse]
354
+ def opportunities_partial_update(x_account_token, id, patched_opportunity_endpoint_request, opts = {})
355
+ data, _status_code, _headers = opportunities_partial_update_with_http_info(x_account_token, id, patched_opportunity_endpoint_request, opts)
356
+ data
357
+ end
358
+
359
+ # @param x_account_token [String] Token identifying the end user.
360
+ # @param id [String]
361
+ # @param patched_opportunity_endpoint_request [PatchedOpportunityEndpointRequest]
362
+ # @param [Hash] opts the optional parameters
363
+ # @option opts [Boolean] :is_debug_mode Whether to include debug fields (such as log file links) in the response.
364
+ # @option opts [Boolean] :run_async Whether or not third-party updates should be run asynchronously.
365
+ # @return [Array<(OpportunityResponse, Integer, Hash)>] OpportunityResponse data, response status code and response headers
366
+ def opportunities_partial_update_with_http_info(x_account_token, id, patched_opportunity_endpoint_request, opts = {})
367
+ if @api_client.config.debugging
368
+ @api_client.config.logger.debug 'Calling API: OpportunitiesApi.opportunities_partial_update ...'
369
+ end
370
+ # verify the required parameter 'x_account_token' is set
371
+ if @api_client.config.client_side_validation && x_account_token.nil?
372
+ fail ArgumentError, "Missing the required parameter 'x_account_token' when calling OpportunitiesApi.opportunities_partial_update"
373
+ end
374
+ # verify the required parameter 'id' is set
375
+ if @api_client.config.client_side_validation && id.nil?
376
+ fail ArgumentError, "Missing the required parameter 'id' when calling OpportunitiesApi.opportunities_partial_update"
377
+ end
378
+ # verify the required parameter 'patched_opportunity_endpoint_request' is set
379
+ if @api_client.config.client_side_validation && patched_opportunity_endpoint_request.nil?
380
+ fail ArgumentError, "Missing the required parameter 'patched_opportunity_endpoint_request' when calling OpportunitiesApi.opportunities_partial_update"
381
+ end
382
+ # resource path
383
+ local_var_path = '/opportunities/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
384
+
385
+ # query parameters
386
+ query_params = opts[:query_params] || {}
387
+ query_params[:'is_debug_mode'] = opts[:'is_debug_mode'] if !opts[:'is_debug_mode'].nil?
388
+ query_params[:'run_async'] = opts[:'run_async'] if !opts[:'run_async'].nil?
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'])
394
+ # HTTP header 'Content-Type'
395
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
396
+ header_params[:'X-Account-Token'] = x_account_token
397
+
398
+ # form parameters
399
+ form_params = opts[:form_params] || {}
400
+
401
+ # http body (model)
402
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(patched_opportunity_endpoint_request)
403
+
404
+ # return_type
405
+ return_type = opts[:debug_return_type] || 'OpportunityResponse'
406
+
407
+ # auth_names
408
+ auth_names = opts[:debug_auth_names] || ['tokenAuth']
409
+
410
+ new_options = opts.merge(
411
+ :operation => :"OpportunitiesApi.opportunities_partial_update",
412
+ :header_params => header_params,
413
+ :query_params => query_params,
414
+ :form_params => form_params,
415
+ :body => post_body,
416
+ :auth_names => auth_names,
417
+ :return_type => return_type
418
+ )
419
+
420
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
421
+ if @api_client.config.debugging
422
+ @api_client.config.logger.debug "API called: OpportunitiesApi#opportunities_partial_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
423
+ end
424
+ return data, status_code, headers
425
+ end
426
+
279
427
  # Returns an `Opportunity` object with the given `id`.
280
428
  # @param x_account_token [String] Token identifying the end user.
281
429
  # @param id [String]
@@ -85,8 +85,8 @@ module MergeCRMClient
85
85
  :'last_activity_at' => :'Time',
86
86
  :'remote_updated_at' => :'Time',
87
87
  :'remote_created_at' => :'Time',
88
- :'integration_params' => :'Hash<String, AnyType>',
89
- :'linked_account_params' => :'Hash<String, AnyType>'
88
+ :'integration_params' => :'Hash<String, Object>',
89
+ :'linked_account_params' => :'Hash<String, Object>'
90
90
  }
91
91
  end
92
92
 
@@ -27,6 +27,12 @@ module MergeCRMClient
27
27
 
28
28
  attr_accessor :account
29
29
 
30
+ attr_accessor :addresses
31
+
32
+ attr_accessor :email_addresses
33
+
34
+ attr_accessor :phone_numbers
35
+
30
36
  # When the contact's last activity occurred.
31
37
  attr_accessor :last_activity_at
32
38
 
@@ -44,6 +50,9 @@ module MergeCRMClient
44
50
  :'first_name' => :'first_name',
45
51
  :'last_name' => :'last_name',
46
52
  :'account' => :'account',
53
+ :'addresses' => :'addresses',
54
+ :'email_addresses' => :'email_addresses',
55
+ :'phone_numbers' => :'phone_numbers',
47
56
  :'last_activity_at' => :'last_activity_at',
48
57
  :'remote_created_at' => :'remote_created_at',
49
58
  :'integration_params' => :'integration_params',
@@ -63,10 +72,13 @@ module MergeCRMClient
63
72
  :'first_name' => :'String',
64
73
  :'last_name' => :'String',
65
74
  :'account' => :'String',
75
+ :'addresses' => :'Array<AddressRequest>',
76
+ :'email_addresses' => :'Array<EmailAddressRequest>',
77
+ :'phone_numbers' => :'Array<PhoneNumberRequest>',
66
78
  :'last_activity_at' => :'Time',
67
79
  :'remote_created_at' => :'Time',
68
- :'integration_params' => :'Hash<String, AnyType>',
69
- :'linked_account_params' => :'Hash<String, AnyType>'
80
+ :'integration_params' => :'Hash<String, Object>',
81
+ :'linked_account_params' => :'Hash<String, Object>'
70
82
  }
71
83
  end
72
84
 
@@ -115,6 +127,24 @@ module MergeCRMClient
115
127
  self.account = attributes[:'account']
116
128
  end
117
129
 
130
+ if attributes.key?(:'addresses')
131
+ if (value = attributes[:'addresses']).is_a?(Array)
132
+ self.addresses = value
133
+ end
134
+ end
135
+
136
+ if attributes.key?(:'email_addresses')
137
+ if (value = attributes[:'email_addresses']).is_a?(Array)
138
+ self.email_addresses = value
139
+ end
140
+ end
141
+
142
+ if attributes.key?(:'phone_numbers')
143
+ if (value = attributes[:'phone_numbers']).is_a?(Array)
144
+ self.phone_numbers = value
145
+ end
146
+ end
147
+
118
148
  if attributes.key?(:'last_activity_at')
119
149
  self.last_activity_at = attributes[:'last_activity_at']
120
150
  end
@@ -158,6 +188,9 @@ module MergeCRMClient
158
188
  first_name == o.first_name &&
159
189
  last_name == o.last_name &&
160
190
  account == o.account &&
191
+ addresses == o.addresses &&
192
+ email_addresses == o.email_addresses &&
193
+ phone_numbers == o.phone_numbers &&
161
194
  last_activity_at == o.last_activity_at &&
162
195
  remote_created_at == o.remote_created_at &&
163
196
  integration_params == o.integration_params &&
@@ -173,7 +206,7 @@ module MergeCRMClient
173
206
  # Calculates hash code according to all attributes.
174
207
  # @return [Integer] Hash code
175
208
  def hash
176
- [remote_id, first_name, last_name, account, last_activity_at, remote_created_at, integration_params, linked_account_params].hash
209
+ [remote_id, first_name, last_name, account, addresses, email_addresses, phone_numbers, last_activity_at, remote_created_at, integration_params, linked_account_params].hash
177
210
  end
178
211
 
179
212
  # Builds the object from hash
@@ -61,7 +61,7 @@ module MergeCRMClient
61
61
  :'base_url_override' => :'String',
62
62
  :'data' => :'String',
63
63
  :'multipart_form_data' => :'Array<MultipartFormFieldRequest>',
64
- :'headers' => :'Hash<String, AnyType>',
64
+ :'headers' => :'Hash<String, Object>',
65
65
  :'request_format' => :'RequestFormatEnum',
66
66
  :'normalize_response' => :'Boolean'
67
67
  }
@@ -78,8 +78,8 @@ module MergeCRMClient
78
78
  :'start_time' => :'Time',
79
79
  :'end_time' => :'Time',
80
80
  :'account' => :'String',
81
- :'integration_params' => :'Hash<String, AnyType>',
82
- :'linked_account_params' => :'Hash<String, AnyType>'
81
+ :'integration_params' => :'Hash<String, Object>',
82
+ :'linked_account_params' => :'Hash<String, Object>'
83
83
  }
84
84
  end
85
85