DealMakerAPI 0.107.0 → 0.107.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +12 -6
  3. data/docs/CampaignApi.md +9 -9
  4. data/docs/DealApi.md +69 -0
  5. data/docs/ShwApi.md +141 -0
  6. data/docs/TtwCampaignsApi.md +141 -0
  7. data/docs/V1EntitiesPage.md +34 -0
  8. data/docs/V1EntitiesTtwReservationCreate.md +2 -4
  9. data/docs/V1EntitiesTtwReservationGetResponse.md +20 -0
  10. data/lib/DealMakerAPI/api/campaign_api.rb +15 -15
  11. data/lib/DealMakerAPI/api/company_api.rb +20 -20
  12. data/lib/DealMakerAPI/api/country_api.rb +1 -1
  13. data/lib/DealMakerAPI/api/custom_emails_api.rb +1 -1
  14. data/lib/DealMakerAPI/api/deal_api.rb +77 -8
  15. data/lib/DealMakerAPI/api/default_api.rb +15 -15
  16. data/lib/DealMakerAPI/api/incentive_plan_api.rb +3 -3
  17. data/lib/DealMakerAPI/api/investor_api.rb +13 -13
  18. data/lib/DealMakerAPI/api/investor_profile_api.rb +13 -13
  19. data/lib/DealMakerAPI/api/reservation_api.rb +2 -2
  20. data/lib/DealMakerAPI/api/shareholder_api.rb +2 -2
  21. data/lib/DealMakerAPI/api/shw_api.rb +148 -0
  22. data/lib/DealMakerAPI/api/ttw_campaigns_api.rb +148 -0
  23. data/lib/DealMakerAPI/api/upload_api.rb +1 -1
  24. data/lib/DealMakerAPI/api/user_api.rb +9 -9
  25. data/lib/DealMakerAPI/api/users_api.rb +2 -2
  26. data/lib/DealMakerAPI/models/v1_entities_page.rb +296 -0
  27. data/lib/DealMakerAPI/models/v1_entities_ttw_reservation_create.rb +7 -17
  28. data/lib/DealMakerAPI/models/{v1_entities_ttw_reservation_user_id.rb → v1_entities_ttw_reservation_get_response.rb} +22 -12
  29. data/lib/DealMakerAPI/version.rb +1 -1
  30. data/lib/DealMakerAPI.rb +4 -1
  31. data/spec/api/campaign_api_spec.rb +2 -2
  32. data/spec/api/deal_api_spec.rb +13 -0
  33. data/spec/api/shw_api_spec.rb +59 -0
  34. data/spec/api/ttw_campaigns_api_spec.rb +59 -0
  35. data/spec/models/v1_entities_page_spec.rb +84 -0
  36. data/spec/models/v1_entities_ttw_reservation_create_spec.rb +1 -7
  37. data/spec/models/{v1_entities_ttw_reservation_user_id_spec.rb → v1_entities_ttw_reservation_get_response_spec.rb} +13 -7
  38. metadata +154 -142
  39. data/docs/V1EntitiesTtwReservationUserId.md +0 -18
@@ -51,7 +51,7 @@ module DealMakerAPI
51
51
  # header parameters
52
52
  header_params = opts[:header_params] || {}
53
53
  # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
55
55
  # HTTP header 'Content-Type'
56
56
  content_type = @api_client.select_header_content_type(['application/json'])
57
57
  if !content_type.nil?
@@ -119,7 +119,7 @@ module DealMakerAPI
119
119
  # header parameters
120
120
  header_params = opts[:header_params] || {}
121
121
  # HTTP header 'Accept' (if needed)
122
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
122
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
123
123
  # HTTP header 'Content-Type'
124
124
  content_type = @api_client.select_header_content_type(['application/json'])
125
125
  if !content_type.nil?
@@ -187,7 +187,7 @@ module DealMakerAPI
187
187
  # header parameters
188
188
  header_params = opts[:header_params] || {}
189
189
  # HTTP header 'Accept' (if needed)
190
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
190
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
191
191
  # HTTP header 'Content-Type'
192
192
  content_type = @api_client.select_header_content_type(['application/json'])
193
193
  if !content_type.nil?
@@ -255,7 +255,7 @@ module DealMakerAPI
255
255
  # header parameters
256
256
  header_params = opts[:header_params] || {}
257
257
  # HTTP header 'Accept' (if needed)
258
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
258
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
259
259
  # HTTP header 'Content-Type'
260
260
  content_type = @api_client.select_header_content_type(['application/json'])
261
261
  if !content_type.nil?
@@ -323,7 +323,7 @@ module DealMakerAPI
323
323
  # header parameters
324
324
  header_params = opts[:header_params] || {}
325
325
  # HTTP header 'Accept' (if needed)
326
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
326
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
327
327
  # HTTP header 'Content-Type'
328
328
  content_type = @api_client.select_header_content_type(['application/json'])
329
329
  if !content_type.nil?
@@ -403,7 +403,7 @@ module DealMakerAPI
403
403
  # header parameters
404
404
  header_params = opts[:header_params] || {}
405
405
  # HTTP header 'Accept' (if needed)
406
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
406
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
407
407
 
408
408
  # form parameters
409
409
  form_params = opts[:form_params] || {}
@@ -466,7 +466,7 @@ module DealMakerAPI
466
466
  # header parameters
467
467
  header_params = opts[:header_params] || {}
468
468
  # HTTP header 'Accept' (if needed)
469
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
469
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
470
470
 
471
471
  # form parameters
472
472
  form_params = opts[:form_params] || {}
@@ -532,7 +532,7 @@ module DealMakerAPI
532
532
  # header parameters
533
533
  header_params = opts[:header_params] || {}
534
534
  # HTTP header 'Accept' (if needed)
535
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
535
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
536
536
 
537
537
  # form parameters
538
538
  form_params = opts[:form_params] || {}
@@ -601,7 +601,7 @@ module DealMakerAPI
601
601
  # header parameters
602
602
  header_params = opts[:header_params] || {}
603
603
  # HTTP header 'Accept' (if needed)
604
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
604
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
605
605
  # HTTP header 'Content-Type'
606
606
  content_type = @api_client.select_header_content_type(['application/json'])
607
607
  if !content_type.nil?
@@ -675,7 +675,7 @@ module DealMakerAPI
675
675
  # header parameters
676
676
  header_params = opts[:header_params] || {}
677
677
  # HTTP header 'Accept' (if needed)
678
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
678
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
679
679
  # HTTP header 'Content-Type'
680
680
  content_type = @api_client.select_header_content_type(['application/json'])
681
681
  if !content_type.nil?
@@ -749,7 +749,7 @@ module DealMakerAPI
749
749
  # header parameters
750
750
  header_params = opts[:header_params] || {}
751
751
  # HTTP header 'Accept' (if needed)
752
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
752
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
753
753
  # HTTP header 'Content-Type'
754
754
  content_type = @api_client.select_header_content_type(['application/json'])
755
755
  if !content_type.nil?
@@ -823,7 +823,7 @@ module DealMakerAPI
823
823
  # header parameters
824
824
  header_params = opts[:header_params] || {}
825
825
  # HTTP header 'Accept' (if needed)
826
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
826
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
827
827
  # HTTP header 'Content-Type'
828
828
  content_type = @api_client.select_header_content_type(['application/json'])
829
829
  if !content_type.nil?
@@ -897,7 +897,7 @@ module DealMakerAPI
897
897
  # header parameters
898
898
  header_params = opts[:header_params] || {}
899
899
  # HTTP header 'Accept' (if needed)
900
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
900
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
901
901
  # HTTP header 'Content-Type'
902
902
  content_type = @api_client.select_header_content_type(['application/json'])
903
903
  if !content_type.nil?
@@ -51,7 +51,7 @@ module DealMakerAPI
51
51
  # header parameters
52
52
  header_params = opts[:header_params] || {}
53
53
  # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
55
55
  # HTTP header 'Content-Type'
56
56
  content_type = @api_client.select_header_content_type(['application/json'])
57
57
  if !content_type.nil?
@@ -119,7 +119,7 @@ module DealMakerAPI
119
119
  # header parameters
120
120
  header_params = opts[:header_params] || {}
121
121
  # HTTP header 'Accept' (if needed)
122
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
122
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
123
123
 
124
124
  # form parameters
125
125
  form_params = opts[:form_params] || {}
@@ -51,7 +51,7 @@ module DealMakerAPI
51
51
  # header parameters
52
52
  header_params = opts[:header_params] || {}
53
53
  # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
55
55
 
56
56
  # form parameters
57
57
  form_params = opts[:form_params] || {}
@@ -114,7 +114,7 @@ module DealMakerAPI
114
114
  # header parameters
115
115
  header_params = opts[:header_params] || {}
116
116
  # HTTP header 'Accept' (if needed)
117
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
117
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
118
118
 
119
119
  # form parameters
120
120
  form_params = opts[:form_params] || {}
@@ -0,0 +1,148 @@
1
+ =begin
2
+ #DealMaker API
3
+
4
+ ## Introduction Welcome to DealMaker’s Web API v1! This API is RESTful, easy to integrate with, and offers support in 2 different languages. This is the technical documentation for our API. There are tutorials and examples of integrations with our API available on our [knowledge centre](https://help.dealmaker.tech/training-centre) as well. # Libraries - Javascript - Ruby # Authentication To authenticate, add an Authorization header to your API request that contains an access token. Before you [generate an access token](#how-to-generate-an-access-token) your must first [create an application](#create-an-application) on your portal and retrieve the your client ID and secret ## Create an Application DealMaker’s Web API v1 supports the use of OAuth applications. Applications can be generated in your [account](https://app.dealmaker.tech/developer/applications). To create an API Application, click on your user name in the top right corner to open a dropdown menu, and select \"Integrations\". Under the API settings tab, click the `Create New Application` button ![Screenshot](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/api-application-1.png) Name your application and assign the level of permissions for this application ![Screenshot](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/api-application-2.png) Once your application is created, save in a secure space your client ID and secret. **WARNING**: The secret key will not be visible after you click the close button ![Screenshot](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/api-application-3.png) From the developer tab, you will be able to view and manage all the available applications ![Screenshot](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/api-application-4.png) Each Application consists of a client id, secret and set of scopes. The scopes define what resources you want to have access to. The client ID and secret are used to generate an access token. You will need to create an application to use API endpoints. ## How to generate an access token After creating an application, you must make a call to obtain a bearer token using the Generate an OAuth token operation. This operation requires the following parameters: `token endpoint` - https://app.dealmaker.tech/oauth/token `grant_type` - must be set to `client_credentials` `client_id` - the Client ID displayed when you created the OAuth application in the previous step `client_secret` - the Client Secret displayed when you created the OAuth application in the previous step `scope` - the scope is established when you created the OAuth application in the previous step Note: The Generate an OAuth token response specifies how long the bearer token is valid for. You should reuse the bearer token until it is expired. When the token is expired, call Generate an OAuth token again to generate a new one. To use the access token, you must set a plain text header named `Authorization` with the contents of the header being “Bearer XXX” where XXX is your generated access token. ### Example #### Postman Here's an example on how to generate the access token with Postman, where `{{CLIENT_ID}}` and `{{CLIENT_SECRET}}` are the values generated after following the steps on [Create an Application](#create-an-application) ![Get access token postman example](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/token-postman.png) # Status Codes ## Content-Type Header All responses are returned in JSON format. We specify this by sending the Content-Type header. ## Status Codes Below is a table containing descriptions of the various status codes we currently support against various resources. Sometimes your API call will generate an error. Here you will find additional information about what to expect if you don’t format your request properly, or we fail to properly process your request. | Status Code | Description | | ----------- | ----------- | | `200` | Success | | `403` | Forbidden | | `404` | Not found | # Pagination Pagination is used to divide large responses is smaller portions (pages). By default, all endpoints return a maximum of 25 records per page. You can change the number of records on a per request basis by passing a `per_page` parameter in the request header parameters. The largest supported `per_page` parameter is 100. When the response exceeds the `per_page` parameter, you can paginate through the records by increasing the `offset` parameter. Example: `offset=25` will return 25 records starting from 26th record. You may also paginate using the `page` parameter to indicate the page number you would like to show on the response. Please review the table below for the input parameters ## Inputs | Parameter | Description | | ---------- | ------------------------------------------------------------------------------- | | `per_page` | Amount of records included on each page (Default is 25) | | `page` | Page number | | `offset` | Amount of records offset on the API request where 0 represents the first record | ## Response Headers | Response Header | Description | | --------------- | -------------------------------------------- | | `X-Total` | Total number of records of response | | `X-Total-Pages` | Total number of pages of response | | `X-Per-Page` | Total number of records per page of response | | `X-Page` | Number of current page | | `X-Next-Page` | Number of next page | | `X-Prev-Page` | Number of previous page | | `X-Offset` | Total number of records offset | # Search and Filtering (The q parameter) The q optional parameter accepts a string as input and allows you to filter the request based on that string. Please note that search strings must be encoded according to ASCII. For example, \"john+investor&#64;dealmaker.tech\" should be passed as “john%2Binvestor%40dealmaker.tech”. There are two main ways to filter with it. ## Keyword filtering Some keywords allow you to filter investors based on a specific “scope” of the investors, for example using the string “Invited” will filter all investors with the status invited, and the keyword “Has attachments” will filter investors with attachments. Here’s a list of possible keywords and the “scope” each one of the keywords filters by: | Keywords | Scope | Decoded Example | Encoded Example | | ---------------------------------------------- | --------------------------------------------------------------------------- | -------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | Signed on \\(date range\\) | Investors who signed in the provided date range | Signed on (date range) [2020-07-01:2020-07-31] | `Signed%20on%20%28date%20range%29%20%5B2020-07-01%3A2020-07-31%5D` | | Enabled for countersignature on \\(date range\\) | Investors who were enabled for counter signature in the provided date range | Enabled for countersignature on (date range) [2022-05-24:2022-05-25] | `Enabled%20for%20countersignature%20on%20(date%20range)%20%5B2022-05-24%3A2022-05-25%5D` | | Accepted on \\(date range\\) | Investors accepted in the provided date rage | Accepted on (date range) [2022-05-24:2022-05-25] | `Accepted%20on%20(date%20range)%20%5B2022-05-24%3A2022-05-25%5D` | | Offline | Investors added to the deal offline | Offline | `Offline` | | Online | Investors added to the deal online | Online | `Online` | | Signed | Investors who signed their agreement | Signed | `Signed` | | Waiting for countersignature | Investors who have signed and are waiting for counter signature | Waiting for countersignature | `Waiting%20for%20countersignature` | | Invited | Investors on the Invited Status | Invited | `Invited` | | Accepted | Investors in the Accepted Status | Accepted | `Accepted` | | Questionnaire in progress | All Investors who have not finished completing the questionnaire | Questionnaire in progress | `Questionnaire%20in%20progress` | | Has attachments | All Investors with attachments | Has attachments | `Has%20attachments` | | Has notes | All Investors with notes | Has notes | `Has%20notes` | | Waiting for co-signature | Investors who have signed and are waiting for co-signature | Waiting for co-signature | `Waiting%20for%20co-signature` | | Background Check Approved | Investors with approved background check | Background Check Approved | `Background%20Check%20Approved` | | Document Review Pending | Investors with pending review | Document Review Pending | `Document%20Review%20Pending` | | Document Upload Pending | Investors with pending documents to upload | Document Upload Pending | `Document%20Upload%20Pending` | | Required adjudicator review | Investors who are required to be review by the adjudicator | Required adjudicator review | `Required%20adjudicator%20review` | --- **NOTE** Filtering keywords are case sensitive and need to be encoded --- ## Search String Any value for the parameter which does not match one of the keywords listed above, will use fields like `first name`, `last name`, `email`, `tags` to search for the investor. For example, if you search “Robert”, because this does not match one of the keywords listed above, it will then return any investors who have the string “Robert” in their name, email, or tags fields. # Versioning The latest version is v1. The version can be updated on the `Accept` header, just set the version as stated on the following example: ``` Accept:application/vnd.dealmaker-v1+json ``` | Version | Accept Header | | ------- | ----------------------------------- | | `v1` | application/vnd.dealmaker-`v1`+json | # SDK’s For instruction on installing SDKs, please view the following links - [Javascript](https://github.com/DealMakerTech/api/tree/main/v1/clients/javascript) - [Ruby](https://github.com/DealMakerTech/api/tree/main/v1/clients/ruby) # Webhooks Our webhooks functionality allows clients to automatically receive updates on a deal's investor data. Some of the data that the webhooks include: - Investor Name - Date created - Email - Phone - Allocation - Attachments - Accredited investor status - Accredited investor category - State (Draft, Invited, Signed, Accepted, Waiting, Inactive) Via webhooks clients can subscribe to the following events as they happen on Dealmaker: - Investor is created - Investor details are updated (any of the investor details above change or are updated) - Investor has signed their agreement - Invertor fully funded their investment - Investor has been accepted - Investor is deleted A URL supplied by the client will receive all the events with the information as part of the payload. Clients are able to add and update the URL within DealMaker. ## Configuration For a comprehensive guide on how to configure Webhooks please visit our support article: [Configuring Webhooks on DealMaker – DealMaker Support](https://help.dealmaker.tech/configuring-webhooks-on-dealmaker). As a developer user on DealMaker, you are able to configure webhooks by following the steps below: 1. Sign into Dealmaker 2. Go to **“Your profile”** in the top right corner 3. Access an **“Integrations”** configuration via the left menu 4. The developer configures webhooks by including: - The HTTPS URL where the request will be sent - Optionally, a security token that we would use to build a SHA1 hash that would be included in the request headers. The name of the header is `X-DealMaker-Signature`. If the secret is not specified, the hash won’t be included in the headers. - The Deal(s) to include in the webhook subscription - An email address that will be used to notify about errors. 5. The developers can disable webhooks temporarily if needed ## Specification ### Events The initial set of events will be related to the investor. The events are: 1. `investor.created` - Triggers every time a new investor is added to a deal 2. `investor.updated` - Triggers on updates to any of the following fields: - Status - Name - Email - (this is a user field so we trigger event for all investors with webhook subscription) - Allocated Amount - Investment Amount - Accredited investor fields - Adding or removing attachments - Tags - When the investor status is signed, the payload also includes a link to the signed document; the link expires after 30 minutes 3. `investor.signed` - Triggers when the investor signs their subscription agreement (terms and conditions) - When this happens the investor.state becomes `signed` - This event includes the same fields as the `investor.updated` event 4. `investor.funded` - Triggers when the investor becomes fully funded - This happens when the investor.funded_state becomes `funded` - This event includes the same fields as the `investor.updated` event 5. `investor.accepted` - Triggers when the investor is countersigned - When this happens the investor.state becomes `accepted` - This event includes the same fields as the `investor.updated` event 6. `investor.deleted` - Triggers when the investor is removed from the deal - The investor key of the payload only includes investor ID - The deal is not included in the payload. Due to our implementation it’s impossible to retrieve the deal the investor was part of ### Requests - The request is a `POST` - The payload’s `content-type` is `application/json` - Only `2XX` responses are considered successful. In the event of a different response, we consider it failed and queue the event for retry - We retry the request five times, after the initial attempt. Doubling the waiting time between intervals with each try. The first retry happens after 30 seconds, then 60 seconds, 2 mins, 4 minutes, and 8 minutes. This timing scheme gives the receiver about 1 hour if all the requests fail - If an event fails all the attempts to be delivered, we send an email to the address that the user configured ### Payload #### Common Properties There will be some properties that are common to all the events on the system. | Key | Type | Description | | ----------------- | ------ | -------------------------------------------------------------------------------------- | | event | String | The event that triggered the call | | event_id | String | A unique identifier for the event | | deal<sup>\\*</sup> | Object | The deal in which the event occurred. please see below for an example on the deal object<sup>\\*\\*</sup> | <sup>\\*</sup>This field is not included when deleting a resource <sup>\\*\\*</sup> Sample Deal Object in the webhook payload ```json \"deal\": { \"id\": 0, \"title\": \"string\", \"created_at\": \"2022-12-06T18:14:44.000Z\", \"updated_at\": \"2022-12-08T12:46:48.000Z\", \"state\": \"string\", \"currency\": \"string\", \"security_type\": \"string\", \"price_per_security\": 0.00, \"deal_type\": \"string\", \"minimum_investment\": 0, \"maximum_investment\": 0, \"issuer\": { \"id\": 0, \"name\": \"string\" }, \"enterprise\": { \"id\": 0, \"name\": \"string\" } } ``` #### Common Properties (investor scope) By design, we have incorporated on the webhooks payload the same investor-related fields included in the Investor model, for reference on the included fields, their types and values please click [here](https://docs.dealmaker.tech/#tag/investor_model). This will allow you to get all the necessary information you need about a particular investor without having to call the Get Investor by ID endpoint. | #### Investor State Here is a brief description of each investor state: - **Draft:** the investor is added to the platform but hasn't been invited yet and cannot access the portal - **Invited:** the investor was added to the platform but hasn’t completed the questionnaire - **Signed:** the investor signed the document (needs approval from Lawyer or Reviewer before countersignature) - **Waiting:** the investor was approved for countersignature by any of the Lawyers or Reviewers in the deal - **Accepted:** the investor's agreement was countersigned by the Signatory - **Inactive** the investor is no longer eligible to participate in the offering. This may be because their warrant expired, they requested a refund, or they opted out of the offering #### Update Delay Given the high number of updates our platform performs on any investor, we’ve added a cool down period on update events that allows us to “group” updates and trigger only one every minute. In consequence, update events will be delivered 1 minute after the initial request was made and will include the latest version of the investor data at delivery time.
5
+
6
+ The version of the OpenAPI document: 1.75.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.8.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module DealMakerAPI
16
+ class ShwApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Get self hosted website page
23
+ # Get self hosted website page
24
+ # @param id [Integer]
25
+ # @param [Hash] opts the optional parameters
26
+ # @return [V1EntitiesPage]
27
+ def get_shw_page(id, opts = {})
28
+ data, _status_code, _headers = get_shw_page_with_http_info(id, opts)
29
+ data
30
+ end
31
+
32
+ # Get self hosted website page
33
+ # Get self hosted website page
34
+ # @param id [Integer]
35
+ # @param [Hash] opts the optional parameters
36
+ # @return [Array<(V1EntitiesPage, Integer, Hash)>] V1EntitiesPage data, response status code and response headers
37
+ def get_shw_page_with_http_info(id, opts = {})
38
+ if @api_client.config.debugging
39
+ @api_client.config.logger.debug 'Calling API: ShwApi.get_shw_page ...'
40
+ end
41
+ # verify the required parameter 'id' is set
42
+ if @api_client.config.client_side_validation && id.nil?
43
+ fail ArgumentError, "Missing the required parameter 'id' when calling ShwApi.get_shw_page"
44
+ end
45
+ # resource path
46
+ local_var_path = '/shw/{id}/page'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
47
+
48
+ # query parameters
49
+ query_params = opts[:query_params] || {}
50
+
51
+ # header parameters
52
+ header_params = opts[:header_params] || {}
53
+ # HTTP header 'Accept' (if needed)
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
55
+
56
+ # form parameters
57
+ form_params = opts[:form_params] || {}
58
+
59
+ # http body (model)
60
+ post_body = opts[:debug_body]
61
+
62
+ # return_type
63
+ return_type = opts[:debug_return_type] || 'V1EntitiesPage'
64
+
65
+ # auth_names
66
+ auth_names = opts[:debug_auth_names] || []
67
+
68
+ new_options = opts.merge(
69
+ :operation => :"ShwApi.get_shw_page",
70
+ :header_params => header_params,
71
+ :query_params => query_params,
72
+ :form_params => form_params,
73
+ :body => post_body,
74
+ :auth_names => auth_names,
75
+ :return_type => return_type
76
+ )
77
+
78
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
79
+ if @api_client.config.debugging
80
+ @api_client.config.logger.debug "API called: ShwApi#get_shw_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
81
+ end
82
+ return data, status_code, headers
83
+ end
84
+
85
+ # Publish self hosted website page
86
+ # Publish self hosted website page
87
+ # @param id [Integer]
88
+ # @param [Hash] opts the optional parameters
89
+ # @return [V1EntitiesPage]
90
+ def publish_shw_page(id, opts = {})
91
+ data, _status_code, _headers = publish_shw_page_with_http_info(id, opts)
92
+ data
93
+ end
94
+
95
+ # Publish self hosted website page
96
+ # Publish self hosted website page
97
+ # @param id [Integer]
98
+ # @param [Hash] opts the optional parameters
99
+ # @return [Array<(V1EntitiesPage, Integer, Hash)>] V1EntitiesPage data, response status code and response headers
100
+ def publish_shw_page_with_http_info(id, opts = {})
101
+ if @api_client.config.debugging
102
+ @api_client.config.logger.debug 'Calling API: ShwApi.publish_shw_page ...'
103
+ end
104
+ # verify the required parameter 'id' is set
105
+ if @api_client.config.client_side_validation && id.nil?
106
+ fail ArgumentError, "Missing the required parameter 'id' when calling ShwApi.publish_shw_page"
107
+ end
108
+ # resource path
109
+ local_var_path = '/shw/{id}/page/publish'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
110
+
111
+ # query parameters
112
+ query_params = opts[:query_params] || {}
113
+
114
+ # header parameters
115
+ header_params = opts[:header_params] || {}
116
+ # HTTP header 'Accept' (if needed)
117
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
118
+
119
+ # form parameters
120
+ form_params = opts[:form_params] || {}
121
+
122
+ # http body (model)
123
+ post_body = opts[:debug_body]
124
+
125
+ # return_type
126
+ return_type = opts[:debug_return_type] || 'V1EntitiesPage'
127
+
128
+ # auth_names
129
+ auth_names = opts[:debug_auth_names] || []
130
+
131
+ new_options = opts.merge(
132
+ :operation => :"ShwApi.publish_shw_page",
133
+ :header_params => header_params,
134
+ :query_params => query_params,
135
+ :form_params => form_params,
136
+ :body => post_body,
137
+ :auth_names => auth_names,
138
+ :return_type => return_type
139
+ )
140
+
141
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
142
+ if @api_client.config.debugging
143
+ @api_client.config.logger.debug "API called: ShwApi#publish_shw_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
144
+ end
145
+ return data, status_code, headers
146
+ end
147
+ end
148
+ end
@@ -0,0 +1,148 @@
1
+ =begin
2
+ #DealMaker API
3
+
4
+ ## Introduction Welcome to DealMaker’s Web API v1! This API is RESTful, easy to integrate with, and offers support in 2 different languages. This is the technical documentation for our API. There are tutorials and examples of integrations with our API available on our [knowledge centre](https://help.dealmaker.tech/training-centre) as well. # Libraries - Javascript - Ruby # Authentication To authenticate, add an Authorization header to your API request that contains an access token. Before you [generate an access token](#how-to-generate-an-access-token) your must first [create an application](#create-an-application) on your portal and retrieve the your client ID and secret ## Create an Application DealMaker’s Web API v1 supports the use of OAuth applications. Applications can be generated in your [account](https://app.dealmaker.tech/developer/applications). To create an API Application, click on your user name in the top right corner to open a dropdown menu, and select \"Integrations\". Under the API settings tab, click the `Create New Application` button ![Screenshot](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/api-application-1.png) Name your application and assign the level of permissions for this application ![Screenshot](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/api-application-2.png) Once your application is created, save in a secure space your client ID and secret. **WARNING**: The secret key will not be visible after you click the close button ![Screenshot](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/api-application-3.png) From the developer tab, you will be able to view and manage all the available applications ![Screenshot](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/api-application-4.png) Each Application consists of a client id, secret and set of scopes. The scopes define what resources you want to have access to. The client ID and secret are used to generate an access token. You will need to create an application to use API endpoints. ## How to generate an access token After creating an application, you must make a call to obtain a bearer token using the Generate an OAuth token operation. This operation requires the following parameters: `token endpoint` - https://app.dealmaker.tech/oauth/token `grant_type` - must be set to `client_credentials` `client_id` - the Client ID displayed when you created the OAuth application in the previous step `client_secret` - the Client Secret displayed when you created the OAuth application in the previous step `scope` - the scope is established when you created the OAuth application in the previous step Note: The Generate an OAuth token response specifies how long the bearer token is valid for. You should reuse the bearer token until it is expired. When the token is expired, call Generate an OAuth token again to generate a new one. To use the access token, you must set a plain text header named `Authorization` with the contents of the header being “Bearer XXX” where XXX is your generated access token. ### Example #### Postman Here's an example on how to generate the access token with Postman, where `{{CLIENT_ID}}` and `{{CLIENT_SECRET}}` are the values generated after following the steps on [Create an Application](#create-an-application) ![Get access token postman example](https://s3.ca-central-1.amazonaws.com/docs.dealmaker.tech/images/token-postman.png) # Status Codes ## Content-Type Header All responses are returned in JSON format. We specify this by sending the Content-Type header. ## Status Codes Below is a table containing descriptions of the various status codes we currently support against various resources. Sometimes your API call will generate an error. Here you will find additional information about what to expect if you don’t format your request properly, or we fail to properly process your request. | Status Code | Description | | ----------- | ----------- | | `200` | Success | | `403` | Forbidden | | `404` | Not found | # Pagination Pagination is used to divide large responses is smaller portions (pages). By default, all endpoints return a maximum of 25 records per page. You can change the number of records on a per request basis by passing a `per_page` parameter in the request header parameters. The largest supported `per_page` parameter is 100. When the response exceeds the `per_page` parameter, you can paginate through the records by increasing the `offset` parameter. Example: `offset=25` will return 25 records starting from 26th record. You may also paginate using the `page` parameter to indicate the page number you would like to show on the response. Please review the table below for the input parameters ## Inputs | Parameter | Description | | ---------- | ------------------------------------------------------------------------------- | | `per_page` | Amount of records included on each page (Default is 25) | | `page` | Page number | | `offset` | Amount of records offset on the API request where 0 represents the first record | ## Response Headers | Response Header | Description | | --------------- | -------------------------------------------- | | `X-Total` | Total number of records of response | | `X-Total-Pages` | Total number of pages of response | | `X-Per-Page` | Total number of records per page of response | | `X-Page` | Number of current page | | `X-Next-Page` | Number of next page | | `X-Prev-Page` | Number of previous page | | `X-Offset` | Total number of records offset | # Search and Filtering (The q parameter) The q optional parameter accepts a string as input and allows you to filter the request based on that string. Please note that search strings must be encoded according to ASCII. For example, \"john+investor&#64;dealmaker.tech\" should be passed as “john%2Binvestor%40dealmaker.tech”. There are two main ways to filter with it. ## Keyword filtering Some keywords allow you to filter investors based on a specific “scope” of the investors, for example using the string “Invited” will filter all investors with the status invited, and the keyword “Has attachments” will filter investors with attachments. Here’s a list of possible keywords and the “scope” each one of the keywords filters by: | Keywords | Scope | Decoded Example | Encoded Example | | ---------------------------------------------- | --------------------------------------------------------------------------- | -------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | | Signed on \\(date range\\) | Investors who signed in the provided date range | Signed on (date range) [2020-07-01:2020-07-31] | `Signed%20on%20%28date%20range%29%20%5B2020-07-01%3A2020-07-31%5D` | | Enabled for countersignature on \\(date range\\) | Investors who were enabled for counter signature in the provided date range | Enabled for countersignature on (date range) [2022-05-24:2022-05-25] | `Enabled%20for%20countersignature%20on%20(date%20range)%20%5B2022-05-24%3A2022-05-25%5D` | | Accepted on \\(date range\\) | Investors accepted in the provided date rage | Accepted on (date range) [2022-05-24:2022-05-25] | `Accepted%20on%20(date%20range)%20%5B2022-05-24%3A2022-05-25%5D` | | Offline | Investors added to the deal offline | Offline | `Offline` | | Online | Investors added to the deal online | Online | `Online` | | Signed | Investors who signed their agreement | Signed | `Signed` | | Waiting for countersignature | Investors who have signed and are waiting for counter signature | Waiting for countersignature | `Waiting%20for%20countersignature` | | Invited | Investors on the Invited Status | Invited | `Invited` | | Accepted | Investors in the Accepted Status | Accepted | `Accepted` | | Questionnaire in progress | All Investors who have not finished completing the questionnaire | Questionnaire in progress | `Questionnaire%20in%20progress` | | Has attachments | All Investors with attachments | Has attachments | `Has%20attachments` | | Has notes | All Investors with notes | Has notes | `Has%20notes` | | Waiting for co-signature | Investors who have signed and are waiting for co-signature | Waiting for co-signature | `Waiting%20for%20co-signature` | | Background Check Approved | Investors with approved background check | Background Check Approved | `Background%20Check%20Approved` | | Document Review Pending | Investors with pending review | Document Review Pending | `Document%20Review%20Pending` | | Document Upload Pending | Investors with pending documents to upload | Document Upload Pending | `Document%20Upload%20Pending` | | Required adjudicator review | Investors who are required to be review by the adjudicator | Required adjudicator review | `Required%20adjudicator%20review` | --- **NOTE** Filtering keywords are case sensitive and need to be encoded --- ## Search String Any value for the parameter which does not match one of the keywords listed above, will use fields like `first name`, `last name`, `email`, `tags` to search for the investor. For example, if you search “Robert”, because this does not match one of the keywords listed above, it will then return any investors who have the string “Robert” in their name, email, or tags fields. # Versioning The latest version is v1. The version can be updated on the `Accept` header, just set the version as stated on the following example: ``` Accept:application/vnd.dealmaker-v1+json ``` | Version | Accept Header | | ------- | ----------------------------------- | | `v1` | application/vnd.dealmaker-`v1`+json | # SDK’s For instruction on installing SDKs, please view the following links - [Javascript](https://github.com/DealMakerTech/api/tree/main/v1/clients/javascript) - [Ruby](https://github.com/DealMakerTech/api/tree/main/v1/clients/ruby) # Webhooks Our webhooks functionality allows clients to automatically receive updates on a deal's investor data. Some of the data that the webhooks include: - Investor Name - Date created - Email - Phone - Allocation - Attachments - Accredited investor status - Accredited investor category - State (Draft, Invited, Signed, Accepted, Waiting, Inactive) Via webhooks clients can subscribe to the following events as they happen on Dealmaker: - Investor is created - Investor details are updated (any of the investor details above change or are updated) - Investor has signed their agreement - Invertor fully funded their investment - Investor has been accepted - Investor is deleted A URL supplied by the client will receive all the events with the information as part of the payload. Clients are able to add and update the URL within DealMaker. ## Configuration For a comprehensive guide on how to configure Webhooks please visit our support article: [Configuring Webhooks on DealMaker – DealMaker Support](https://help.dealmaker.tech/configuring-webhooks-on-dealmaker). As a developer user on DealMaker, you are able to configure webhooks by following the steps below: 1. Sign into Dealmaker 2. Go to **“Your profile”** in the top right corner 3. Access an **“Integrations”** configuration via the left menu 4. The developer configures webhooks by including: - The HTTPS URL where the request will be sent - Optionally, a security token that we would use to build a SHA1 hash that would be included in the request headers. The name of the header is `X-DealMaker-Signature`. If the secret is not specified, the hash won’t be included in the headers. - The Deal(s) to include in the webhook subscription - An email address that will be used to notify about errors. 5. The developers can disable webhooks temporarily if needed ## Specification ### Events The initial set of events will be related to the investor. The events are: 1. `investor.created` - Triggers every time a new investor is added to a deal 2. `investor.updated` - Triggers on updates to any of the following fields: - Status - Name - Email - (this is a user field so we trigger event for all investors with webhook subscription) - Allocated Amount - Investment Amount - Accredited investor fields - Adding or removing attachments - Tags - When the investor status is signed, the payload also includes a link to the signed document; the link expires after 30 minutes 3. `investor.signed` - Triggers when the investor signs their subscription agreement (terms and conditions) - When this happens the investor.state becomes `signed` - This event includes the same fields as the `investor.updated` event 4. `investor.funded` - Triggers when the investor becomes fully funded - This happens when the investor.funded_state becomes `funded` - This event includes the same fields as the `investor.updated` event 5. `investor.accepted` - Triggers when the investor is countersigned - When this happens the investor.state becomes `accepted` - This event includes the same fields as the `investor.updated` event 6. `investor.deleted` - Triggers when the investor is removed from the deal - The investor key of the payload only includes investor ID - The deal is not included in the payload. Due to our implementation it’s impossible to retrieve the deal the investor was part of ### Requests - The request is a `POST` - The payload’s `content-type` is `application/json` - Only `2XX` responses are considered successful. In the event of a different response, we consider it failed and queue the event for retry - We retry the request five times, after the initial attempt. Doubling the waiting time between intervals with each try. The first retry happens after 30 seconds, then 60 seconds, 2 mins, 4 minutes, and 8 minutes. This timing scheme gives the receiver about 1 hour if all the requests fail - If an event fails all the attempts to be delivered, we send an email to the address that the user configured ### Payload #### Common Properties There will be some properties that are common to all the events on the system. | Key | Type | Description | | ----------------- | ------ | -------------------------------------------------------------------------------------- | | event | String | The event that triggered the call | | event_id | String | A unique identifier for the event | | deal<sup>\\*</sup> | Object | The deal in which the event occurred. please see below for an example on the deal object<sup>\\*\\*</sup> | <sup>\\*</sup>This field is not included when deleting a resource <sup>\\*\\*</sup> Sample Deal Object in the webhook payload ```json \"deal\": { \"id\": 0, \"title\": \"string\", \"created_at\": \"2022-12-06T18:14:44.000Z\", \"updated_at\": \"2022-12-08T12:46:48.000Z\", \"state\": \"string\", \"currency\": \"string\", \"security_type\": \"string\", \"price_per_security\": 0.00, \"deal_type\": \"string\", \"minimum_investment\": 0, \"maximum_investment\": 0, \"issuer\": { \"id\": 0, \"name\": \"string\" }, \"enterprise\": { \"id\": 0, \"name\": \"string\" } } ``` #### Common Properties (investor scope) By design, we have incorporated on the webhooks payload the same investor-related fields included in the Investor model, for reference on the included fields, their types and values please click [here](https://docs.dealmaker.tech/#tag/investor_model). This will allow you to get all the necessary information you need about a particular investor without having to call the Get Investor by ID endpoint. | #### Investor State Here is a brief description of each investor state: - **Draft:** the investor is added to the platform but hasn't been invited yet and cannot access the portal - **Invited:** the investor was added to the platform but hasn’t completed the questionnaire - **Signed:** the investor signed the document (needs approval from Lawyer or Reviewer before countersignature) - **Waiting:** the investor was approved for countersignature by any of the Lawyers or Reviewers in the deal - **Accepted:** the investor's agreement was countersigned by the Signatory - **Inactive** the investor is no longer eligible to participate in the offering. This may be because their warrant expired, they requested a refund, or they opted out of the offering #### Update Delay Given the high number of updates our platform performs on any investor, we’ve added a cool down period on update events that allows us to “group” updates and trigger only one every minute. In consequence, update events will be delivered 1 minute after the initial request was made and will include the latest version of the investor data at delivery time.
5
+
6
+ The version of the OpenAPI document: 1.75.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.8.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module DealMakerAPI
16
+ class TtwCampaignsApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Get ttw campaign page
23
+ # Get ttw campaign page
24
+ # @param id [Integer]
25
+ # @param [Hash] opts the optional parameters
26
+ # @return [V1EntitiesPage]
27
+ def get_ttw_campaign_page(id, opts = {})
28
+ data, _status_code, _headers = get_ttw_campaign_page_with_http_info(id, opts)
29
+ data
30
+ end
31
+
32
+ # Get ttw campaign page
33
+ # Get ttw campaign page
34
+ # @param id [Integer]
35
+ # @param [Hash] opts the optional parameters
36
+ # @return [Array<(V1EntitiesPage, Integer, Hash)>] V1EntitiesPage data, response status code and response headers
37
+ def get_ttw_campaign_page_with_http_info(id, opts = {})
38
+ if @api_client.config.debugging
39
+ @api_client.config.logger.debug 'Calling API: TtwCampaignsApi.get_ttw_campaign_page ...'
40
+ end
41
+ # verify the required parameter 'id' is set
42
+ if @api_client.config.client_side_validation && id.nil?
43
+ fail ArgumentError, "Missing the required parameter 'id' when calling TtwCampaignsApi.get_ttw_campaign_page"
44
+ end
45
+ # resource path
46
+ local_var_path = '/ttw/campaigns/{id}/page'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
47
+
48
+ # query parameters
49
+ query_params = opts[:query_params] || {}
50
+
51
+ # header parameters
52
+ header_params = opts[:header_params] || {}
53
+ # HTTP header 'Accept' (if needed)
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
55
+
56
+ # form parameters
57
+ form_params = opts[:form_params] || {}
58
+
59
+ # http body (model)
60
+ post_body = opts[:debug_body]
61
+
62
+ # return_type
63
+ return_type = opts[:debug_return_type] || 'V1EntitiesPage'
64
+
65
+ # auth_names
66
+ auth_names = opts[:debug_auth_names] || []
67
+
68
+ new_options = opts.merge(
69
+ :operation => :"TtwCampaignsApi.get_ttw_campaign_page",
70
+ :header_params => header_params,
71
+ :query_params => query_params,
72
+ :form_params => form_params,
73
+ :body => post_body,
74
+ :auth_names => auth_names,
75
+ :return_type => return_type
76
+ )
77
+
78
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
79
+ if @api_client.config.debugging
80
+ @api_client.config.logger.debug "API called: TtwCampaignsApi#get_ttw_campaign_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
81
+ end
82
+ return data, status_code, headers
83
+ end
84
+
85
+ # Publish ttw campaign page
86
+ # Publish ttw campaign page
87
+ # @param id [Integer]
88
+ # @param [Hash] opts the optional parameters
89
+ # @return [V1EntitiesPage]
90
+ def publish_ttw_campaign_page(id, opts = {})
91
+ data, _status_code, _headers = publish_ttw_campaign_page_with_http_info(id, opts)
92
+ data
93
+ end
94
+
95
+ # Publish ttw campaign page
96
+ # Publish ttw campaign page
97
+ # @param id [Integer]
98
+ # @param [Hash] opts the optional parameters
99
+ # @return [Array<(V1EntitiesPage, Integer, Hash)>] V1EntitiesPage data, response status code and response headers
100
+ def publish_ttw_campaign_page_with_http_info(id, opts = {})
101
+ if @api_client.config.debugging
102
+ @api_client.config.logger.debug 'Calling API: TtwCampaignsApi.publish_ttw_campaign_page ...'
103
+ end
104
+ # verify the required parameter 'id' is set
105
+ if @api_client.config.client_side_validation && id.nil?
106
+ fail ArgumentError, "Missing the required parameter 'id' when calling TtwCampaignsApi.publish_ttw_campaign_page"
107
+ end
108
+ # resource path
109
+ local_var_path = '/ttw/campaigns/{id}/page/publish'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
110
+
111
+ # query parameters
112
+ query_params = opts[:query_params] || {}
113
+
114
+ # header parameters
115
+ header_params = opts[:header_params] || {}
116
+ # HTTP header 'Accept' (if needed)
117
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
118
+
119
+ # form parameters
120
+ form_params = opts[:form_params] || {}
121
+
122
+ # http body (model)
123
+ post_body = opts[:debug_body]
124
+
125
+ # return_type
126
+ return_type = opts[:debug_return_type] || 'V1EntitiesPage'
127
+
128
+ # auth_names
129
+ auth_names = opts[:debug_auth_names] || []
130
+
131
+ new_options = opts.merge(
132
+ :operation => :"TtwCampaignsApi.publish_ttw_campaign_page",
133
+ :header_params => header_params,
134
+ :query_params => query_params,
135
+ :form_params => form_params,
136
+ :body => post_body,
137
+ :auth_names => auth_names,
138
+ :return_type => return_type
139
+ )
140
+
141
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
142
+ if @api_client.config.debugging
143
+ @api_client.config.logger.debug "API called: TtwCampaignsApi#publish_ttw_campaign_page\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
144
+ end
145
+ return data, status_code, headers
146
+ end
147
+ end
148
+ end
@@ -51,7 +51,7 @@ module DealMakerAPI
51
51
  # header parameters
52
52
  header_params = opts[:header_params] || {}
53
53
  # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
55
55
  # HTTP header 'Content-Type'
56
56
  content_type = @api_client.select_header_content_type(['application/json'])
57
57
  if !content_type.nil?
@@ -51,7 +51,7 @@ module DealMakerAPI
51
51
  # header parameters
52
52
  header_params = opts[:header_params] || {}
53
53
  # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
55
55
 
56
56
  # form parameters
57
57
  form_params = opts[:form_params] || {}
@@ -120,7 +120,7 @@ module DealMakerAPI
120
120
  # header parameters
121
121
  header_params = opts[:header_params] || {}
122
122
  # HTTP header 'Accept' (if needed)
123
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
123
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
124
124
 
125
125
  # form parameters
126
126
  form_params = opts[:form_params] || {}
@@ -244,7 +244,7 @@ module DealMakerAPI
244
244
  # header parameters
245
245
  header_params = opts[:header_params] || {}
246
246
  # HTTP header 'Accept' (if needed)
247
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
247
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
248
248
 
249
249
  # form parameters
250
250
  form_params = opts[:form_params] || {}
@@ -307,7 +307,7 @@ module DealMakerAPI
307
307
  # header parameters
308
308
  header_params = opts[:header_params] || {}
309
309
  # HTTP header 'Accept' (if needed)
310
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
310
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
311
311
 
312
312
  # form parameters
313
313
  form_params = opts[:form_params] || {}
@@ -371,7 +371,7 @@ module DealMakerAPI
371
371
  # header parameters
372
372
  header_params = opts[:header_params] || {}
373
373
  # HTTP header 'Accept' (if needed)
374
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
374
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
375
375
 
376
376
  # form parameters
377
377
  form_params = opts[:form_params] || {}
@@ -434,7 +434,7 @@ module DealMakerAPI
434
434
  # header parameters
435
435
  header_params = opts[:header_params] || {}
436
436
  # HTTP header 'Accept' (if needed)
437
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
437
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
438
438
  # HTTP header 'Content-Type'
439
439
  content_type = @api_client.select_header_content_type(['application/json'])
440
440
  if !content_type.nil?
@@ -580,7 +580,7 @@ module DealMakerAPI
580
580
  # header parameters
581
581
  header_params = opts[:header_params] || {}
582
582
  # HTTP header 'Accept' (if needed)
583
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
583
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
584
584
  # HTTP header 'Content-Type'
585
585
  content_type = @api_client.select_header_content_type(['application/json'])
586
586
  if !content_type.nil?
@@ -654,7 +654,7 @@ module DealMakerAPI
654
654
  # header parameters
655
655
  header_params = opts[:header_params] || {}
656
656
  # HTTP header 'Accept' (if needed)
657
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
657
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
658
658
  # HTTP header 'Content-Type'
659
659
  content_type = @api_client.select_header_content_type(['application/json'])
660
660
  if !content_type.nil?
@@ -728,7 +728,7 @@ module DealMakerAPI
728
728
  # header parameters
729
729
  header_params = opts[:header_params] || {}
730
730
  # HTTP header 'Accept' (if needed)
731
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
731
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
732
732
  # HTTP header 'Content-Type'
733
733
  content_type = @api_client.select_header_content_type(['application/json'])
734
734
  if !content_type.nil?
@@ -51,7 +51,7 @@ module DealMakerAPI
51
51
  # header parameters
52
52
  header_params = opts[:header_params] || {}
53
53
  # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
54
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
55
55
 
56
56
  # form parameters
57
57
  form_params = opts[:form_params] || {}
@@ -124,7 +124,7 @@ module DealMakerAPI
124
124
  # header parameters
125
125
  header_params = opts[:header_params] || {}
126
126
  # HTTP header 'Accept' (if needed)
127
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
127
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
128
128
 
129
129
  # form parameters
130
130
  form_params = opts[:form_params] || {}