From 0f92a7da8d20abd660560e6835cace0eca1c3592 Mon Sep 17 00:00:00 2001 From: "Jakob (Koby) Shimony" Date: Thu, 19 Dec 2019 16:04:06 +0100 Subject: [PATCH] v3.5.0 --- README.md | 19 +- build.gradle | 2 +- build.sbt | 2 +- docs/AccountAnalytics.md | 1 + docs/AccountLimits.md | 1 + docs/Application.md | 1 + docs/AttributesMandatory.md | 11 + docs/AttributesSettings.md | 10 + docs/BaseSamlConnection.md | 17 + docs/CampaignAnalytics.md | 12 +- docs/CampaignCopy.md | 4 + docs/Change.md | 4 +- docs/CustomerInventory.md | 11 + docs/InlineResponse20020.md | 2 +- docs/InlineResponse20021.md | 2 +- docs/InlineResponse20022.md | 2 +- docs/InlineResponse20023.md | 2 +- docs/InlineResponse20024.md | 2 +- docs/InlineResponse20025.md | 5 +- docs/InlineResponse20026.md | 5 +- docs/InlineResponse20027.md | 2 +- docs/InlineResponse20028.md | 2 +- docs/InlineResponse20029.md | 11 + docs/IntegrationApi.md | 66 ++ docs/ManagementApi.md | 285 +++++--- docs/NewApplication.md | 1 + docs/NewSamlConnection.md | 5 +- docs/SamlConnection.md | 9 +- docs/SamlConnectionMetadata.md | 13 + docs/UpdateApplication.md | 1 + pom.xml | 2 +- src/main/java/one/talon/ApiClient.java | 2 +- .../java/one/talon/api/IntegrationApi.java | 139 ++++ .../java/one/talon/api/ManagementApi.java | 670 +++++++++++------- .../one/talon/model/AccountAnalytics.java | 28 +- .../java/one/talon/model/AccountLimits.java | 26 +- .../java/one/talon/model/Application.java | 27 +- .../one/talon/model/AttributesMandatory.java | 138 ++++ .../one/talon/model/AttributesSettings.java | 97 +++ .../one/talon/model/BaseSamlConnection.java | 263 +++++++ .../one/talon/model/CampaignAnalytics.java | 158 ++++- .../java/one/talon/model/CampaignCopy.java | 109 ++- src/main/java/one/talon/model/Change.java | 8 +- .../one/talon/model/CustomerInventory.java | 131 ++++ .../one/talon/model/InlineResponse20020.java | 12 +- .../one/talon/model/InlineResponse20021.java | 12 +- .../one/talon/model/InlineResponse20022.java | 12 +- .../one/talon/model/InlineResponse20023.java | 12 +- .../one/talon/model/InlineResponse20024.java | 12 +- .../one/talon/model/InlineResponse20025.java | 40 +- .../one/talon/model/InlineResponse20026.java | 40 +- .../one/talon/model/InlineResponse20027.java | 12 +- .../one/talon/model/InlineResponse20028.java | 12 +- .../one/talon/model/InlineResponse20029.java | 127 ++++ .../java/one/talon/model/NewApplication.java | 27 +- .../one/talon/model/NewSamlConnection.java | 106 +-- .../java/one/talon/model/SamlConnection.java | 160 ++--- .../talon/model/SamlConnectionMetadata.java | 168 +++++ .../one/talon/model/UpdateApplication.java | 29 +- .../one/talon/api/IntegrationApiTest.java | 19 + .../java/one/talon/api/ManagementApiTest.java | 89 ++- 61 files changed, 2517 insertions(+), 680 deletions(-) create mode 100644 docs/AttributesMandatory.md create mode 100644 docs/AttributesSettings.md create mode 100644 docs/BaseSamlConnection.md create mode 100644 docs/CustomerInventory.md create mode 100644 docs/InlineResponse20029.md create mode 100644 docs/SamlConnectionMetadata.md create mode 100644 src/main/java/one/talon/model/AttributesMandatory.java create mode 100644 src/main/java/one/talon/model/AttributesSettings.java create mode 100644 src/main/java/one/talon/model/BaseSamlConnection.java create mode 100644 src/main/java/one/talon/model/CustomerInventory.java create mode 100644 src/main/java/one/talon/model/InlineResponse20029.java create mode 100644 src/main/java/one/talon/model/SamlConnectionMetadata.java diff --git a/README.md b/README.md index 630f0c2c..0d6b7696 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ Add this dependency to your project's POM: one.talon talon-one-client - 3.4.0 + 3.5.0 compile ``` @@ -49,7 +49,7 @@ Add this dependency to your project's POM: Add this dependency to your project's build file: ```groovy -compile "one.talon:talon-one-client:3.4.0" +compile "one.talon:talon-one-client:3.5.0" ``` ### Others @@ -62,7 +62,7 @@ mvn clean package Then manually install the following JARs: -* `target/talon-one-client-3.4.0.jar` +* `target/talon-one-client-3.5.0.jar` * `target/lib/*.jar` ## Getting Started @@ -146,6 +146,7 @@ public class TalonApiTest { } ``` + ## Documentation for API Endpoints All URIs are relative to *http://localhost* @@ -156,6 +157,7 @@ Class | Method | HTTP request | Description *IntegrationApi* | [**createReferral**](docs/IntegrationApi.md#createReferral) | **POST** /v1/referrals | Create a referral code for an advocate *IntegrationApi* | [**deleteCouponReservation**](docs/IntegrationApi.md#deleteCouponReservation) | **DELETE** /v1/coupon_reservations/{couponValue} | Delete coupon reservations *IntegrationApi* | [**deleteCustomerData**](docs/IntegrationApi.md#deleteCustomerData) | **DELETE** /v1/customer_data/{integrationId} | Delete the personal data of a customer. +*IntegrationApi* | [**getCustomerInventory**](docs/IntegrationApi.md#getCustomerInventory) | **GET** /v1/customer_profiles/{integrationId}/inventory | Get an inventory of all data associated with a specific customer profile. *IntegrationApi* | [**getReservedCoupons**](docs/IntegrationApi.md#getReservedCoupons) | **GET** /v1/coupon_reservations/coupons/{integrationId} | Get all valid reserved coupons *IntegrationApi* | [**getReservedCustomers**](docs/IntegrationApi.md#getReservedCustomers) | **GET** /v1/coupon_reservations/customerprofiles/{couponValue} | Get the users that have this coupon reserved *IntegrationApi* | [**trackEvent**](docs/IntegrationApi.md#trackEvent) | **POST** /v1/events | Track an Event @@ -163,6 +165,7 @@ Class | Method | HTTP request | Description *IntegrationApi* | [**updateCustomerSession**](docs/IntegrationApi.md#updateCustomerSession) | **PUT** /v1/customer_sessions/{customerSessionId} | Update a Customer Session *ManagementApi* | [**addLoyaltyPoints**](docs/ManagementApi.md#addLoyaltyPoints) | **PUT** /v1/loyalty_programs/{programID}/profile/{integrationID}/add_points | Add points in a certain loyalty program for the specified customer *ManagementApi* | [**copyCampaignToApplications**](docs/ManagementApi.md#copyCampaignToApplications) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/copy | Copy the campaign into every specified application +*ManagementApi* | [**createAttribute**](docs/ManagementApi.md#createAttribute) | **POST** /v1/attributes | Define a new custom attribute *ManagementApi* | [**createCampaign**](docs/ManagementApi.md#createCampaign) | **POST** /v1/applications/{applicationId}/campaigns | Create a Campaign *ManagementApi* | [**createCoupons**](docs/ManagementApi.md#createCoupons) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/coupons | Create Coupons *ManagementApi* | [**createPasswordRecoveryEmail**](docs/ManagementApi.md#createPasswordRecoveryEmail) | **POST** /v1/password_recovery_emails | Request a password reset @@ -177,7 +180,6 @@ Class | Method | HTTP request | Description *ManagementApi* | [**getAccessLogsWithoutTotalCount**](docs/ManagementApi.md#getAccessLogsWithoutTotalCount) | **GET** /v1/applications/{applicationId}/access_logs/no_total | Get access logs for application *ManagementApi* | [**getAccount**](docs/ManagementApi.md#getAccount) | **GET** /v1/accounts/{accountId} | Get Account Details *ManagementApi* | [**getAccountAnalytics**](docs/ManagementApi.md#getAccountAnalytics) | **GET** /v1/accounts/{accountId}/analytics | Get Account Analytics -*ManagementApi* | [**getAccountLimits**](docs/ManagementApi.md#getAccountLimits) | **GET** /v1/accounts/{accountId}/limits | Get Account Limits *ManagementApi* | [**getAllAccessLogs**](docs/ManagementApi.md#getAllAccessLogs) | **GET** /v1/access_logs | Get all access logs *ManagementApi* | [**getAllRoles**](docs/ManagementApi.md#getAllRoles) | **GET** /v1/roles | Get all roles. *ManagementApi* | [**getApplication**](docs/ManagementApi.md#getApplication) | **GET** /v1/applications/{applicationId} | Get Application @@ -192,6 +194,7 @@ Class | Method | HTTP request | Description *ManagementApi* | [**getApplicationSessions**](docs/ManagementApi.md#getApplicationSessions) | **GET** /v1/applications/{applicationId}/sessions | List Application Sessions *ManagementApi* | [**getApplications**](docs/ManagementApi.md#getApplications) | **GET** /v1/applications | List Applications *ManagementApi* | [**getAttribute**](docs/ManagementApi.md#getAttribute) | **GET** /v1/attributes/{attributeId} | Get a custom attribute +*ManagementApi* | [**getAttributes**](docs/ManagementApi.md#getAttributes) | **GET** /v1/attributes | List custom attributes *ManagementApi* | [**getCampaign**](docs/ManagementApi.md#getCampaign) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId} | Get a Campaign *ManagementApi* | [**getCampaignAnalytics**](docs/ManagementApi.md#getCampaignAnalytics) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/analytics | Get analytics of campaigns *ManagementApi* | [**getCampaignByAttributes**](docs/ManagementApi.md#getCampaignByAttributes) | **POST** /v1/applications/{applicationId}/campaigns_search | Get a list of all campaigns that match the given attributes @@ -233,7 +236,7 @@ Class | Method | HTTP request | Description *ManagementApi* | [**searchCouponsAdvancedApplicationWide**](docs/ManagementApi.md#searchCouponsAdvancedApplicationWide) | **POST** /v1/applications/{applicationId}/coupons_search_advanced | Get a list of the coupons that match the given attributes in all active campaigns of an application *ManagementApi* | [**searchCouponsAdvancedApplicationWideWithoutTotalCount**](docs/ManagementApi.md#searchCouponsAdvancedApplicationWideWithoutTotalCount) | **POST** /v1/applications/{applicationId}/coupons_search_advanced/no_total | Get a list of the coupons that match the given attributes in all active campaigns of an application *ManagementApi* | [**searchCouponsAdvancedWithoutTotalCount**](docs/ManagementApi.md#searchCouponsAdvancedWithoutTotalCount) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/coupons_search_advanced/no_total | Get a list of the coupons that match the given attributes -*ManagementApi* | [**setAccountLimits**](docs/ManagementApi.md#setAccountLimits) | **PUT** /v1/accounts/{accountId}/limits | Set account limits +*ManagementApi* | [**updateAttribute**](docs/ManagementApi.md#updateAttribute) | **PUT** /v1/attributes/{attributeId} | Update a custom attribute *ManagementApi* | [**updateCampaign**](docs/ManagementApi.md#updateCampaign) | **PUT** /v1/applications/{applicationId}/campaigns/{campaignId} | Update a Campaign *ManagementApi* | [**updateCampaignSet**](docs/ManagementApi.md#updateCampaignSet) | **PUT** /v1/applications/{applicationId}/campaign_set | Update a Campaign Set *ManagementApi* | [**updateCoupon**](docs/ManagementApi.md#updateCoupon) | **PUT** /v1/applications/{applicationId}/campaigns/{campaignId}/coupons/{couponId} | Update a Coupon @@ -261,6 +264,9 @@ Class | Method | HTTP request | Description - [ApplicationSessionEntity](docs/ApplicationSessionEntity.md) - [Attribute](docs/Attribute.md) - [AttributeQuery](docs/AttributeQuery.md) + - [AttributesMandatory](docs/AttributesMandatory.md) + - [AttributesSettings](docs/AttributesSettings.md) + - [BaseSamlConnection](docs/BaseSamlConnection.md) - [Binding](docs/Binding.md) - [Campaign](docs/Campaign.md) - [CampaignAnalytics](docs/CampaignAnalytics.md) @@ -284,6 +290,7 @@ Class | Method | HTTP request | Description - [CreateApplicationAPIKey](docs/CreateApplicationAPIKey.md) - [CustomerActivityReport](docs/CustomerActivityReport.md) - [CustomerAnalytics](docs/CustomerAnalytics.md) + - [CustomerInventory](docs/CustomerInventory.md) - [CustomerProfile](docs/CustomerProfile.md) - [CustomerProfileSearchQuery](docs/CustomerProfileSearchQuery.md) - [CustomerSession](docs/CustomerSession.md) @@ -323,6 +330,7 @@ Class | Method | HTTP request | Description - [InlineResponse20026](docs/InlineResponse20026.md) - [InlineResponse20027](docs/InlineResponse20027.md) - [InlineResponse20028](docs/InlineResponse20028.md) + - [InlineResponse20029](docs/InlineResponse20029.md) - [InlineResponse2003](docs/InlineResponse2003.md) - [InlineResponse2004](docs/InlineResponse2004.md) - [InlineResponse2005](docs/InlineResponse2005.md) @@ -388,6 +396,7 @@ Class | Method | HTTP request | Description - [Rule](docs/Rule.md) - [Ruleset](docs/Ruleset.md) - [SamlConnection](docs/SamlConnection.md) + - [SamlConnectionMetadata](docs/SamlConnectionMetadata.md) - [Session](docs/Session.md) - [SlotDef](docs/SlotDef.md) - [TemplateArgDef](docs/TemplateArgDef.md) diff --git a/build.gradle b/build.gradle index bdd5c470..6fdf2b6d 100644 --- a/build.gradle +++ b/build.gradle @@ -2,7 +2,7 @@ apply plugin: 'idea' apply plugin: 'eclipse' group = 'one.talon' -version = '3.4.0' +version = '3.5.0' buildscript { repositories { diff --git a/build.sbt b/build.sbt index 8dd1f9e8..c8a910a1 100644 --- a/build.sbt +++ b/build.sbt @@ -2,7 +2,7 @@ lazy val root = (project in file(".")). settings( organization := "one.talon", name := "talon-one-client", - version := "3.4.0", + version := "3.5.0", scalaVersion := "2.11.4", scalacOptions ++= Seq("-feature"), javacOptions in compile ++= Seq("-Xlint:deprecation"), diff --git a/docs/AccountAnalytics.md b/docs/AccountAnalytics.md index 701fb5d7..641eb754 100644 --- a/docs/AccountAnalytics.md +++ b/docs/AccountAnalytics.md @@ -18,6 +18,7 @@ Name | Type | Description | Notes **roles** | **Integer** | Total Number of roles inside the account | **webhooks** | **Integer** | Total Number of webhooks inside the account | **loyaltyPrograms** | **Integer** | Total Number of loyalty programs inside the account | +**activeRules** | **Integer** | Total Number of active rules in the account | diff --git a/docs/AccountLimits.md b/docs/AccountLimits.md index b639c60b..c4b65ff3 100644 --- a/docs/AccountLimits.md +++ b/docs/AccountLimits.md @@ -14,6 +14,7 @@ Name | Type | Description | Notes **webhooks** | **Integer** | Total Number of allowed webhooks in the account | **users** | **Integer** | Total Number of allowed users in the account | **apiVolume** | **Integer** | Total allowed api volume | +**activeRules** | **Integer** | Total allowed active rulesets | [optional] **promotionTypes** | **List<String>** | array of rulesets where webhook is used | diff --git a/docs/Application.md b/docs/Application.md index cfd6fca3..539203d3 100644 --- a/docs/Application.md +++ b/docs/Application.md @@ -15,6 +15,7 @@ Name | Type | Description | Notes **caseSensitivity** | [**CaseSensitivityEnum**](#CaseSensitivityEnum) | A string indicating how should campaigns in this application deal with case sensitivity on coupon codes. | [optional] **attributes** | [**Object**](.md) | Arbitrary properties associated with this campaign | [optional] **limits** | [**List<LimitConfig>**](LimitConfig.md) | Default limits for campaigns created in this application | [optional] +**attributesSettings** | [**AttributesSettings**](AttributesSettings.md) | | [optional] **key** | **String** | Hex key for HMAC-signing API calls as coming from this application (16 hex digits) | **loyaltyPrograms** | [**List<LoyaltyProgram>**](LoyaltyProgram.md) | An array containing all the loyalty programs to which this application is subscribed | diff --git a/docs/AttributesMandatory.md b/docs/AttributesMandatory.md new file mode 100644 index 00000000..c2b0ac9d --- /dev/null +++ b/docs/AttributesMandatory.md @@ -0,0 +1,11 @@ + +# AttributesMandatory + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**campaigns** | **List<String>** | List of mandatory attributes for campaigns. | [optional] +**coupons** | **List<String>** | List of mandatory attributes for campaigns. | [optional] + + + diff --git a/docs/AttributesSettings.md b/docs/AttributesSettings.md new file mode 100644 index 00000000..cf5dc7b7 --- /dev/null +++ b/docs/AttributesSettings.md @@ -0,0 +1,10 @@ + +# AttributesSettings + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**mandatory** | [**AttributesMandatory**](AttributesMandatory.md) | | [optional] + + + diff --git a/docs/BaseSamlConnection.md b/docs/BaseSamlConnection.md new file mode 100644 index 00000000..c3af23e7 --- /dev/null +++ b/docs/BaseSamlConnection.md @@ -0,0 +1,17 @@ + +# BaseSamlConnection + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**accountId** | **Integer** | The ID of the account that owns this entity. | +**name** | **String** | ID of the SAML service. | +**enabled** | **Boolean** | Determines if this SAML connection active. | +**issuer** | **String** | Identity Provider Entity ID. | +**signOnURL** | **String** | Single Sign-On URL. | +**signOutURL** | **String** | Single Sign-Out URL. | [optional] +**metadataURL** | **String** | Metadata URL. | [optional] +**audienceURI** | **String** | The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. | [optional] + + + diff --git a/docs/CampaignAnalytics.md b/docs/CampaignAnalytics.md index bd44c3bf..03b0160e 100644 --- a/docs/CampaignAnalytics.md +++ b/docs/CampaignAnalytics.md @@ -5,14 +5,20 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **date** | [**OffsetDateTime**](OffsetDateTime.md) | | -**campaignRevenue** | [**BigDecimal**](BigDecimal.md) | Amount of revenue in this campaign. | -**totalCampaignRevenue** | [**BigDecimal**](BigDecimal.md) | Amount of revenue in this campaign since it began. | +**campaignRevenue** | [**BigDecimal**](BigDecimal.md) | Amount of revenue in this campaign (for coupon or discount sessions). | +**totalCampaignRevenue** | [**BigDecimal**](BigDecimal.md) | Amount of revenue in this campaign since it began (for coupon or discount sessions). | +**campaignRefund** | [**BigDecimal**](BigDecimal.md) | Amount of refunds in this campaign (for coupon or discount sessions). | +**totalCampaignRefund** | [**BigDecimal**](BigDecimal.md) | Amount of refunds in this campaign since it began (for coupon or discount sessions). | **campaignDiscountCosts** | [**BigDecimal**](BigDecimal.md) | Amount of cost caused by discounts given in the campaign. | **totalCampaignDiscountCosts** | [**BigDecimal**](BigDecimal.md) | Amount of cost caused by discounts given in the campaign since it began. | +**campaignRefundedDiscounts** | [**BigDecimal**](BigDecimal.md) | Amount of discounts rolledback due to refund in the campaign. | +**totalCampaignRefundedDiscounts** | [**BigDecimal**](BigDecimal.md) | Amount of discounts rolledback due to refund in the campaign since it began. | **campaignFreeItems** | **Integer** | Amount of free items given in the campaign. | **totalCampaignFreeItems** | **Integer** | Amount of free items given in the campaign since it began. | -**couponRedemptions** | **Integer** | Number of coupon redemptions in the campaign (only accepted referrals on sessions that were closed are considered). | +**couponRedemptions** | **Integer** | Number of coupon redemptions in the campaign. | **totalCouponRedemptions** | **Integer** | Number of coupon redemptions in the campaign since it began. | +**couponRolledbackRedemptions** | **Integer** | Number of coupon redemptions that have been rolled back (due to canceling closed session) in the campaign. | +**totalCouponRolledbackRedemptions** | **Integer** | Number of coupon redemptions that have been rolled back (due to canceling closed session) in the campaign since it began. | **referralRedemptions** | **Integer** | Number of referral redemptions in the campaign. | **totalReferralRedemptions** | **Integer** | Number of referral redemptions in the campaign since it began. | **couponsCreated** | **Integer** | Number of coupons created in the campaign by the rule engine. | diff --git a/docs/CampaignCopy.md b/docs/CampaignCopy.md index fed9c428..0c4b803d 100644 --- a/docs/CampaignCopy.md +++ b/docs/CampaignCopy.md @@ -6,6 +6,10 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **name** | **String** | Name of the copied campaign (Defaults to \"Copy of original campaign name\") | [optional] **applicationIds** | **List<String>** | Application IDs of the applications to which a campaign should be copied to | +**description** | **String** | A detailed description of the campaign. | [optional] +**startTime** | [**OffsetDateTime**](OffsetDateTime.md) | Datetime when the campaign will become active. | [optional] +**endTime** | [**OffsetDateTime**](OffsetDateTime.md) | Datetime when the campaign will become in-active. | [optional] +**tags** | **List<String>** | A list of tags for the campaign. | [optional] diff --git a/docs/Change.md b/docs/Change.md index b1fa92df..ff81ae4a 100644 --- a/docs/Change.md +++ b/docs/Change.md @@ -8,8 +8,8 @@ Name | Type | Description | Notes **created** | [**OffsetDateTime**](OffsetDateTime.md) | The exact moment this entity was created. | **userId** | **Integer** | The ID of the account that owns this entity. | **entity** | **String** | API endpoint on which the change was initiated. | -**old** | [**Object**](.md) | Resource before the change occured. | [optional] -**_new** | [**Object**](.md) | Resource after the change occured. | [optional] +**old** | [**Object**](.md) | Resource before the change occurred. | [optional] +**_new** | [**Object**](.md) | Resource after the change occurred. | [optional] diff --git a/docs/CustomerInventory.md b/docs/CustomerInventory.md new file mode 100644 index 00000000..e1c560ec --- /dev/null +++ b/docs/CustomerInventory.md @@ -0,0 +1,11 @@ + +# CustomerInventory + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**profile** | [**CustomerProfile**](CustomerProfile.md) | | [optional] +**referrals** | [**List<Referral>**](Referral.md) | | [optional] + + + diff --git a/docs/InlineResponse20020.md b/docs/InlineResponse20020.md index 261a93b0..fbd63804 100644 --- a/docs/InlineResponse20020.md +++ b/docs/InlineResponse20020.md @@ -4,7 +4,7 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<Webhook>**](Webhook.md) | | +**data** | [**List<Attribute>**](Attribute.md) | | **totalResultSize** | **Integer** | | diff --git a/docs/InlineResponse20021.md b/docs/InlineResponse20021.md index 1366da55..63d323e0 100644 --- a/docs/InlineResponse20021.md +++ b/docs/InlineResponse20021.md @@ -4,7 +4,7 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<WebhookActivationLogEntry>**](WebhookActivationLogEntry.md) | | +**data** | [**List<Webhook>**](Webhook.md) | | **totalResultSize** | **Integer** | | diff --git a/docs/InlineResponse20022.md b/docs/InlineResponse20022.md index 9b64d68d..fd64f73e 100644 --- a/docs/InlineResponse20022.md +++ b/docs/InlineResponse20022.md @@ -4,7 +4,7 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<WebhookLogEntry>**](WebhookLogEntry.md) | | +**data** | [**List<WebhookActivationLogEntry>**](WebhookActivationLogEntry.md) | | **totalResultSize** | **Integer** | | diff --git a/docs/InlineResponse20023.md b/docs/InlineResponse20023.md index 2f0e8324..074366af 100644 --- a/docs/InlineResponse20023.md +++ b/docs/InlineResponse20023.md @@ -4,7 +4,7 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<EventType>**](EventType.md) | | +**data** | [**List<WebhookLogEntry>**](WebhookLogEntry.md) | | **totalResultSize** | **Integer** | | diff --git a/docs/InlineResponse20024.md b/docs/InlineResponse20024.md index c9d1fec2..df6e0c4c 100644 --- a/docs/InlineResponse20024.md +++ b/docs/InlineResponse20024.md @@ -4,7 +4,7 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<User>**](User.md) | | +**data** | [**List<EventType>**](EventType.md) | | **totalResultSize** | **Integer** | | diff --git a/docs/InlineResponse20025.md b/docs/InlineResponse20025.md index ca1d073c..b6f5b04c 100644 --- a/docs/InlineResponse20025.md +++ b/docs/InlineResponse20025.md @@ -4,9 +4,8 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<Change>**](Change.md) | | -**hasMore** | **Boolean** | | [optional] -**totalResultSize** | **Integer** | | [optional] +**data** | [**List<User>**](User.md) | | +**totalResultSize** | **Integer** | | diff --git a/docs/InlineResponse20026.md b/docs/InlineResponse20026.md index 7a10f0bf..f6277899 100644 --- a/docs/InlineResponse20026.md +++ b/docs/InlineResponse20026.md @@ -4,8 +4,9 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<Export>**](Export.md) | | -**totalResultSize** | **Integer** | | +**data** | [**List<Change>**](Change.md) | | +**hasMore** | **Boolean** | | [optional] +**totalResultSize** | **Integer** | | [optional] diff --git a/docs/InlineResponse20027.md b/docs/InlineResponse20027.md index 080c5b1f..a8194b1e 100644 --- a/docs/InlineResponse20027.md +++ b/docs/InlineResponse20027.md @@ -4,7 +4,7 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<ModelImport>**](ModelImport.md) | | +**data** | [**List<Export>**](Export.md) | | **totalResultSize** | **Integer** | | diff --git a/docs/InlineResponse20028.md b/docs/InlineResponse20028.md index f1eb5491..da16d7c9 100644 --- a/docs/InlineResponse20028.md +++ b/docs/InlineResponse20028.md @@ -4,7 +4,7 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**data** | [**List<Role>**](Role.md) | | +**data** | [**List<ModelImport>**](ModelImport.md) | | **totalResultSize** | **Integer** | | diff --git a/docs/InlineResponse20029.md b/docs/InlineResponse20029.md new file mode 100644 index 00000000..b1e6cc5d --- /dev/null +++ b/docs/InlineResponse20029.md @@ -0,0 +1,11 @@ + +# InlineResponse20029 + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**List<Role>**](Role.md) | | +**totalResultSize** | **Integer** | | + + + diff --git a/docs/IntegrationApi.md b/docs/IntegrationApi.md index b3ad0504..f53e9afc 100644 --- a/docs/IntegrationApi.md +++ b/docs/IntegrationApi.md @@ -8,6 +8,7 @@ Method | HTTP request | Description [**createReferral**](IntegrationApi.md#createReferral) | **POST** /v1/referrals | Create a referral code for an advocate [**deleteCouponReservation**](IntegrationApi.md#deleteCouponReservation) | **DELETE** /v1/coupon_reservations/{couponValue} | Delete coupon reservations [**deleteCustomerData**](IntegrationApi.md#deleteCustomerData) | **DELETE** /v1/customer_data/{integrationId} | Delete the personal data of a customer. +[**getCustomerInventory**](IntegrationApi.md#getCustomerInventory) | **GET** /v1/customer_profiles/{integrationId}/inventory | Get an inventory of all data associated with a specific customer profile. [**getReservedCoupons**](IntegrationApi.md#getReservedCoupons) | **GET** /v1/coupon_reservations/coupons/{integrationId} | Get all valid reserved coupons [**getReservedCustomers**](IntegrationApi.md#getReservedCustomers) | **GET** /v1/coupon_reservations/customerprofiles/{couponValue} | Get the users that have this coupon reserved [**trackEvent**](IntegrationApi.md#trackEvent) | **POST** /v1/events | Track an Event @@ -261,6 +262,71 @@ null (empty response body) - **Content-Type**: Not defined - **Accept**: Not defined + +# **getCustomerInventory** +> CustomerInventory getCustomerInventory(integrationId, profile, referrals) + +Get an inventory of all data associated with a specific customer profile. + +Get information regarding entities referencing this customer profile's integrationId. Currently we support customer profile information and referral codes. In the future, this will be expanded with coupon codes and loyalty points. + +### Example +```java +// Import classes: +//import one.talon.ApiClient; +//import one.talon.ApiException; +//import one.talon.Configuration; +//import one.talon.auth.*; +//import one.talon.api.IntegrationApi; + +ApiClient defaultClient = Configuration.getDefaultApiClient(); + +// Configure API key authorization: api_key_v1 +ApiKeyAuth api_key_v1 = (ApiKeyAuth) defaultClient.getAuthentication("api_key_v1"); +api_key_v1.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//api_key_v1.setApiKeyPrefix("Token"); + +// Configure API key authorization: integration_auth +ApiKeyAuth integration_auth = (ApiKeyAuth) defaultClient.getAuthentication("integration_auth"); +integration_auth.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//integration_auth.setApiKeyPrefix("Token"); + +IntegrationApi apiInstance = new IntegrationApi(); +String integrationId = "integrationId_example"; // String | The custom identifier for this profile, must be unique within the account. +Object profile = null; // Object | optional flag to decide if you would like customer profile information in the response +Object referrals = null; // Object | optional flag to decide if you would like referral information in the response +try { + CustomerInventory result = apiInstance.getCustomerInventory(integrationId, profile, referrals); + System.out.println(result); +} catch (ApiException e) { + System.err.println("Exception when calling IntegrationApi#getCustomerInventory"); + e.printStackTrace(); +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **integrationId** | **String**| The custom identifier for this profile, must be unique within the account. | + **profile** | [**Object**](.md)| optional flag to decide if you would like customer profile information in the response | [optional] [default to null] + **referrals** | [**Object**](.md)| optional flag to decide if you would like referral information in the response | [optional] [default to null] + +### Return type + +[**CustomerInventory**](CustomerInventory.md) + +### Authorization + +[api_key_v1](../README.md#api_key_v1), [integration_auth](../README.md#integration_auth) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + # **getReservedCoupons** > InlineResponse2001 getReservedCoupons(integrationId) diff --git a/docs/ManagementApi.md b/docs/ManagementApi.md index f0cabf09..2c8aabc4 100644 --- a/docs/ManagementApi.md +++ b/docs/ManagementApi.md @@ -6,6 +6,7 @@ Method | HTTP request | Description ------------- | ------------- | ------------- [**addLoyaltyPoints**](ManagementApi.md#addLoyaltyPoints) | **PUT** /v1/loyalty_programs/{programID}/profile/{integrationID}/add_points | Add points in a certain loyalty program for the specified customer [**copyCampaignToApplications**](ManagementApi.md#copyCampaignToApplications) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/copy | Copy the campaign into every specified application +[**createAttribute**](ManagementApi.md#createAttribute) | **POST** /v1/attributes | Define a new custom attribute [**createCampaign**](ManagementApi.md#createCampaign) | **POST** /v1/applications/{applicationId}/campaigns | Create a Campaign [**createCoupons**](ManagementApi.md#createCoupons) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/coupons | Create Coupons [**createPasswordRecoveryEmail**](ManagementApi.md#createPasswordRecoveryEmail) | **POST** /v1/password_recovery_emails | Request a password reset @@ -20,7 +21,6 @@ Method | HTTP request | Description [**getAccessLogsWithoutTotalCount**](ManagementApi.md#getAccessLogsWithoutTotalCount) | **GET** /v1/applications/{applicationId}/access_logs/no_total | Get access logs for application [**getAccount**](ManagementApi.md#getAccount) | **GET** /v1/accounts/{accountId} | Get Account Details [**getAccountAnalytics**](ManagementApi.md#getAccountAnalytics) | **GET** /v1/accounts/{accountId}/analytics | Get Account Analytics -[**getAccountLimits**](ManagementApi.md#getAccountLimits) | **GET** /v1/accounts/{accountId}/limits | Get Account Limits [**getAllAccessLogs**](ManagementApi.md#getAllAccessLogs) | **GET** /v1/access_logs | Get all access logs [**getAllRoles**](ManagementApi.md#getAllRoles) | **GET** /v1/roles | Get all roles. [**getApplication**](ManagementApi.md#getApplication) | **GET** /v1/applications/{applicationId} | Get Application @@ -35,6 +35,7 @@ Method | HTTP request | Description [**getApplicationSessions**](ManagementApi.md#getApplicationSessions) | **GET** /v1/applications/{applicationId}/sessions | List Application Sessions [**getApplications**](ManagementApi.md#getApplications) | **GET** /v1/applications | List Applications [**getAttribute**](ManagementApi.md#getAttribute) | **GET** /v1/attributes/{attributeId} | Get a custom attribute +[**getAttributes**](ManagementApi.md#getAttributes) | **GET** /v1/attributes | List custom attributes [**getCampaign**](ManagementApi.md#getCampaign) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId} | Get a Campaign [**getCampaignAnalytics**](ManagementApi.md#getCampaignAnalytics) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/analytics | Get analytics of campaigns [**getCampaignByAttributes**](ManagementApi.md#getCampaignByAttributes) | **POST** /v1/applications/{applicationId}/campaigns_search | Get a list of all campaigns that match the given attributes @@ -76,7 +77,7 @@ Method | HTTP request | Description [**searchCouponsAdvancedApplicationWide**](ManagementApi.md#searchCouponsAdvancedApplicationWide) | **POST** /v1/applications/{applicationId}/coupons_search_advanced | Get a list of the coupons that match the given attributes in all active campaigns of an application [**searchCouponsAdvancedApplicationWideWithoutTotalCount**](ManagementApi.md#searchCouponsAdvancedApplicationWideWithoutTotalCount) | **POST** /v1/applications/{applicationId}/coupons_search_advanced/no_total | Get a list of the coupons that match the given attributes in all active campaigns of an application [**searchCouponsAdvancedWithoutTotalCount**](ManagementApi.md#searchCouponsAdvancedWithoutTotalCount) | **POST** /v1/applications/{applicationId}/campaigns/{campaignId}/coupons_search_advanced/no_total | Get a list of the coupons that match the given attributes -[**setAccountLimits**](ManagementApi.md#setAccountLimits) | **PUT** /v1/accounts/{accountId}/limits | Set account limits +[**updateAttribute**](ManagementApi.md#updateAttribute) | **PUT** /v1/attributes/{attributeId} | Update a custom attribute [**updateCampaign**](ManagementApi.md#updateCampaign) | **PUT** /v1/applications/{applicationId}/campaigns/{campaignId} | Update a Campaign [**updateCampaignSet**](ManagementApi.md#updateCampaignSet) | **PUT** /v1/applications/{applicationId}/campaign_set | Update a Campaign Set [**updateCoupon**](ManagementApi.md#updateCoupon) | **PUT** /v1/applications/{applicationId}/campaigns/{campaignId}/coupons/{couponId} | Update a Coupon @@ -194,6 +195,61 @@ Name | Type | Description | Notes [manager_auth](../README.md#manager_auth) +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + + +# **createAttribute** +> Attribute createAttribute(newAttribute) + +Define a new custom attribute + +Defines a new _custom attribute_ in this account. Custom attributes allow you to attach new fields to Talon.One domain objects like campaigns, coupons, customers and so on. These attributes can then be given values when creating / updating these objects, and these values can be used in your campaign rules. For example, you could define a `zipCode` field for customer sessions, and add a rule to your campaign that only allows certain ZIP codes. These attributes are shared across all applications in your account, and are never required. + +### Example +```java +// Import classes: +//import one.talon.ApiClient; +//import one.talon.ApiException; +//import one.talon.Configuration; +//import one.talon.auth.*; +//import one.talon.api.ManagementApi; + +ApiClient defaultClient = Configuration.getDefaultApiClient(); + +// Configure API key authorization: manager_auth +ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); +manager_auth.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//manager_auth.setApiKeyPrefix("Token"); + +ManagementApi apiInstance = new ManagementApi(); +NewAttribute newAttribute = new NewAttribute(); // NewAttribute | +try { + Attribute result = apiInstance.createAttribute(newAttribute); + System.out.println(result); +} catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#createAttribute"); + e.printStackTrace(); +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **newAttribute** | [**NewAttribute**](NewAttribute.md)| | + +### Return type + +[**Attribute**](Attribute.md) + +### Authorization + +[manager_auth](../README.md#manager_auth) + ### HTTP request headers - **Content-Type**: application/json @@ -260,7 +316,7 @@ Name | Type | Description | Notes Create Coupons -Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupns can be created. +Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupons can be created. ### Example ```java @@ -809,8 +865,8 @@ ManagementApi apiInstance = new ManagementApi(); Integer applicationId = 56; // Integer | OffsetDateTime rangeStart = new OffsetDateTime(); // OffsetDateTime | Only return results from after this timestamp, must be an RFC3339 timestamp string OffsetDateTime rangeEnd = new OffsetDateTime(); // OffsetDateTime | Only return results from before this timestamp, must be an RFC3339 timestamp string -String path = "path_example"; // String | Only return results where the request path matches the given regular expresssion. -String method = "method_example"; // String | Only return results where the request method matches the given regular expresssion. +String path = "path_example"; // String | Only return results where the request path matches the given regular expression. +String method = "method_example"; // String | Only return results where the request method matches the given regular expression. String status = "status_example"; // String | Filter results by HTTP status codes. Integer pageSize = 56; // Integer | The number of items to include in this response. When omitted, the maximum value of 1000 will be used. Integer skip = 56; // Integer | Skips the given number of items when paging through large result sets. @@ -831,8 +887,8 @@ Name | Type | Description | Notes **applicationId** | **Integer**| | **rangeStart** | **OffsetDateTime**| Only return results from after this timestamp, must be an RFC3339 timestamp string | **rangeEnd** | **OffsetDateTime**| Only return results from before this timestamp, must be an RFC3339 timestamp string | - **path** | **String**| Only return results where the request path matches the given regular expresssion. | [optional] - **method** | **String**| Only return results where the request method matches the given regular expresssion. | [optional] [enum: get, put, post, delete, patch] + **path** | **String**| Only return results where the request path matches the given regular expression. | [optional] + **method** | **String**| Only return results where the request method matches the given regular expression. | [optional] [enum: get, put, post, delete, patch] **status** | **String**| Filter results by HTTP status codes. | [optional] [enum: success, error] **pageSize** | **Integer**| The number of items to include in this response. When omitted, the maximum value of 1000 will be used. | [optional] **skip** | **Integer**| Skips the given number of items when paging through large result sets. | [optional] @@ -878,8 +934,8 @@ ManagementApi apiInstance = new ManagementApi(); Integer applicationId = 56; // Integer | OffsetDateTime rangeStart = new OffsetDateTime(); // OffsetDateTime | Only return results from after this timestamp, must be an RFC3339 timestamp string OffsetDateTime rangeEnd = new OffsetDateTime(); // OffsetDateTime | Only return results from before this timestamp, must be an RFC3339 timestamp string -String path = "path_example"; // String | Only return results where the request path matches the given regular expresssion. -String method = "method_example"; // String | Only return results where the request method matches the given regular expresssion. +String path = "path_example"; // String | Only return results where the request path matches the given regular expression. +String method = "method_example"; // String | Only return results where the request method matches the given regular expression. String status = "status_example"; // String | Filter results by HTTP status codes. Integer pageSize = 56; // Integer | The number of items to include in this response. When omitted, the maximum value of 1000 will be used. Integer skip = 56; // Integer | Skips the given number of items when paging through large result sets. @@ -900,8 +956,8 @@ Name | Type | Description | Notes **applicationId** | **Integer**| | **rangeStart** | **OffsetDateTime**| Only return results from after this timestamp, must be an RFC3339 timestamp string | **rangeEnd** | **OffsetDateTime**| Only return results from before this timestamp, must be an RFC3339 timestamp string | - **path** | **String**| Only return results where the request path matches the given regular expresssion. | [optional] - **method** | **String**| Only return results where the request method matches the given regular expresssion. | [optional] [enum: get, put, post, delete, patch] + **path** | **String**| Only return results where the request path matches the given regular expression. | [optional] + **method** | **String**| Only return results where the request method matches the given regular expression. | [optional] [enum: get, put, post, delete, patch] **status** | **String**| Filter results by HTTP status codes. | [optional] [enum: success, error] **pageSize** | **Integer**| The number of items to include in this response. When omitted, the maximum value of 1000 will be used. | [optional] **skip** | **Integer**| Skips the given number of items when paging through large result sets. | [optional] @@ -1025,61 +1081,6 @@ Name | Type | Description | Notes [manager_auth](../README.md#manager_auth) -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json - - -# **getAccountLimits** -> AccountLimits getAccountLimits(accountId) - -Get Account Limits - -Returns a list of all account limits set - -### Example -```java -// Import classes: -//import one.talon.ApiClient; -//import one.talon.ApiException; -//import one.talon.Configuration; -//import one.talon.auth.*; -//import one.talon.api.ManagementApi; - -ApiClient defaultClient = Configuration.getDefaultApiClient(); - -// Configure API key authorization: manager_auth -ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); -manager_auth.setApiKey("YOUR API KEY"); -// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) -//manager_auth.setApiKeyPrefix("Token"); - -ManagementApi apiInstance = new ManagementApi(); -Integer accountId = 56; // Integer | -try { - AccountLimits result = apiInstance.getAccountLimits(accountId); - System.out.println(result); -} catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#getAccountLimits"); - e.printStackTrace(); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **accountId** | **Integer**| | - -### Return type - -[**AccountLimits**](AccountLimits.md) - -### Authorization - -[manager_auth](../README.md#manager_auth) - ### HTTP request headers - **Content-Type**: Not defined @@ -1113,8 +1114,8 @@ manager_auth.setApiKey("YOUR API KEY"); ManagementApi apiInstance = new ManagementApi(); OffsetDateTime rangeStart = new OffsetDateTime(); // OffsetDateTime | Only return results from after this timestamp, must be an RFC3339 timestamp string OffsetDateTime rangeEnd = new OffsetDateTime(); // OffsetDateTime | Only return results from before this timestamp, must be an RFC3339 timestamp string -String path = "path_example"; // String | Only return results where the request path matches the given regular expresssion. -String method = "method_example"; // String | Only return results where the request method matches the given regular expresssion. +String path = "path_example"; // String | Only return results where the request path matches the given regular expression. +String method = "method_example"; // String | Only return results where the request method matches the given regular expression. String status = "status_example"; // String | Filter results by HTTP status codes. Integer pageSize = 56; // Integer | The number of items to include in this response. When omitted, the maximum value of 1000 will be used. Integer skip = 56; // Integer | Skips the given number of items when paging through large result sets. @@ -1134,8 +1135,8 @@ Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **rangeStart** | **OffsetDateTime**| Only return results from after this timestamp, must be an RFC3339 timestamp string | **rangeEnd** | **OffsetDateTime**| Only return results from before this timestamp, must be an RFC3339 timestamp string | - **path** | **String**| Only return results where the request path matches the given regular expresssion. | [optional] - **method** | **String**| Only return results where the request method matches the given regular expresssion. | [optional] [enum: get, put, post, delete, patch] + **path** | **String**| Only return results where the request path matches the given regular expression. | [optional] + **method** | **String**| Only return results where the request method matches the given regular expression. | [optional] [enum: get, put, post, delete, patch] **status** | **String**| Filter results by HTTP status codes. | [optional] [enum: success, error] **pageSize** | **Integer**| The number of items to include in this response. When omitted, the maximum value of 1000 will be used. | [optional] **skip** | **Integer**| Skips the given number of items when paging through large result sets. | [optional] @@ -1156,7 +1157,7 @@ Name | Type | Description | Notes # **getAllRoles** -> InlineResponse20028 getAllRoles() +> InlineResponse20029 getAllRoles() Get all roles. @@ -1179,7 +1180,7 @@ manager_auth.setApiKey("YOUR API KEY"); ManagementApi apiInstance = new ManagementApi(); try { - InlineResponse20028 result = apiInstance.getAllRoles(); + InlineResponse20029 result = apiInstance.getAllRoles(); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getAllRoles"); @@ -1192,7 +1193,7 @@ This endpoint does not need any parameter. ### Return type -[**InlineResponse20028**](InlineResponse20028.md) +[**InlineResponse20029**](InlineResponse20029.md) ### Authorization @@ -1425,7 +1426,7 @@ Name | Type | Description | Notes Get a list of the customer profiles that match the given attributes -Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile +Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile ### Example ```java @@ -1930,6 +1931,65 @@ Name | Type | Description | Notes [manager_auth](../README.md#manager_auth) +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + + +# **getAttributes** +> InlineResponse20020 getAttributes(pageSize, skip, sort) + +List custom attributes + +Returns all the defined custom attributes for the account. + +### Example +```java +// Import classes: +//import one.talon.ApiClient; +//import one.talon.ApiException; +//import one.talon.Configuration; +//import one.talon.auth.*; +//import one.talon.api.ManagementApi; + +ApiClient defaultClient = Configuration.getDefaultApiClient(); + +// Configure API key authorization: manager_auth +ApiKeyAuth manager_auth = (ApiKeyAuth) defaultClient.getAuthentication("manager_auth"); +manager_auth.setApiKey("YOUR API KEY"); +// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null) +//manager_auth.setApiKeyPrefix("Token"); + +ManagementApi apiInstance = new ManagementApi(); +Integer pageSize = 56; // Integer | The number of items to include in this response. When omitted, the maximum value of 1000 will be used. +Integer skip = 56; // Integer | Skips the given number of items when paging through large result sets. +String sort = "sort_example"; // String | The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. +try { + InlineResponse20020 result = apiInstance.getAttributes(pageSize, skip, sort); + System.out.println(result); +} catch (ApiException e) { + System.err.println("Exception when calling ManagementApi#getAttributes"); + e.printStackTrace(); +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **pageSize** | **Integer**| The number of items to include in this response. When omitted, the maximum value of 1000 will be used. | [optional] + **skip** | **Integer**| Skips the given number of items when paging through large result sets. | [optional] + **sort** | **String**| The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. | [optional] + +### Return type + +[**InlineResponse20020**](InlineResponse20020.md) + +### Authorization + +[manager_auth](../README.md#manager_auth) + ### HTTP request headers - **Content-Type**: Not defined @@ -2240,7 +2300,7 @@ Name | Type | Description | Notes # **getChanges** -> InlineResponse20025 getChanges(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld) +> InlineResponse20026 getChanges(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld) Get audit log for an account @@ -2273,7 +2333,7 @@ OffsetDateTime createdAfter = new OffsetDateTime(); // OffsetDateTime | Filter r Boolean withTotalResultSize = true; // Boolean | When this flag is set, the result will include the total size of the result, across all pages. This might decrease performance on large data sets. With this flag set to true, hasMore will be be true whenever there is a next page. totalResultSize will always be zero. With this flag set to false, hasMore will always be set to false. totalResultSize will contain the total number of results for this query. Boolean includeOld = true; // Boolean | When this flag is set to false, the state without the change will not be returned. The default value is true. try { - InlineResponse20025 result = apiInstance.getChanges(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld); + InlineResponse20026 result = apiInstance.getChanges(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getChanges"); @@ -2296,7 +2356,7 @@ Name | Type | Description | Notes ### Return type -[**InlineResponse20025**](InlineResponse20025.md) +[**InlineResponse20026**](InlineResponse20026.md) ### Authorization @@ -3029,7 +3089,7 @@ Name | Type | Description | Notes Get a list of the customer profiles that match the given attributes -Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile +Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile ### Example ```java @@ -3084,7 +3144,7 @@ Name | Type | Description | Notes # **getEventTypes** -> InlineResponse20023 getEventTypes(applicationIds, name, includeOldVersions, pageSize, skip, sort) +> InlineResponse20024 getEventTypes(applicationIds, name, includeOldVersions, pageSize, skip, sort) List Event Types @@ -3115,7 +3175,7 @@ Integer pageSize = 56; // Integer | The number of items to include in this respo Integer skip = 56; // Integer | Skips the given number of items when paging through large result sets. String sort = "sort_example"; // String | The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. try { - InlineResponse20023 result = apiInstance.getEventTypes(applicationIds, name, includeOldVersions, pageSize, skip, sort); + InlineResponse20024 result = apiInstance.getEventTypes(applicationIds, name, includeOldVersions, pageSize, skip, sort); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getEventTypes"); @@ -3136,7 +3196,7 @@ Name | Type | Description | Notes ### Return type -[**InlineResponse20023**](InlineResponse20023.md) +[**InlineResponse20024**](InlineResponse20024.md) ### Authorization @@ -3149,7 +3209,7 @@ Name | Type | Description | Notes # **getExports** -> InlineResponse20026 getExports(pageSize, skip, applicationId, campaignId, entity) +> InlineResponse20027 getExports(pageSize, skip, applicationId, campaignId, entity) Get Exports @@ -3179,7 +3239,7 @@ Integer applicationId = 56; // Integer | Integer campaignId = 56; // Integer | String entity = "entity_example"; // String | The name of the entity type that was exported. try { - InlineResponse20026 result = apiInstance.getExports(pageSize, skip, applicationId, campaignId, entity); + InlineResponse20027 result = apiInstance.getExports(pageSize, skip, applicationId, campaignId, entity); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getExports"); @@ -3199,7 +3259,7 @@ Name | Type | Description | Notes ### Return type -[**InlineResponse20026**](InlineResponse20026.md) +[**InlineResponse20027**](InlineResponse20027.md) ### Authorization @@ -3212,7 +3272,7 @@ Name | Type | Description | Notes # **getImports** -> InlineResponse20027 getImports(pageSize, skip) +> InlineResponse20028 getImports(pageSize, skip) Get Imports @@ -3239,7 +3299,7 @@ ManagementApi apiInstance = new ManagementApi(); Integer pageSize = 56; // Integer | The number of items to include in this response. When omitted, the maximum value of 1000 will be used. Integer skip = 56; // Integer | Skips the given number of items when paging through large result sets. try { - InlineResponse20027 result = apiInstance.getImports(pageSize, skip); + InlineResponse20028 result = apiInstance.getImports(pageSize, skip); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getImports"); @@ -3256,7 +3316,7 @@ Name | Type | Description | Notes ### Return type -[**InlineResponse20027**](InlineResponse20027.md) +[**InlineResponse20028**](InlineResponse20028.md) ### Authorization @@ -3800,7 +3860,7 @@ Name | Type | Description | Notes # **getUsers** -> InlineResponse20024 getUsers(pageSize, skip, sort) +> InlineResponse20025 getUsers(pageSize, skip, sort) List Users in your account @@ -3828,7 +3888,7 @@ Integer pageSize = 56; // Integer | The number of items to include in this respo Integer skip = 56; // Integer | Skips the given number of items when paging through large result sets. String sort = "sort_example"; // String | The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. try { - InlineResponse20024 result = apiInstance.getUsers(pageSize, skip, sort); + InlineResponse20025 result = apiInstance.getUsers(pageSize, skip, sort); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getUsers"); @@ -3846,7 +3906,7 @@ Name | Type | Description | Notes ### Return type -[**InlineResponse20024**](InlineResponse20024.md) +[**InlineResponse20025**](InlineResponse20025.md) ### Authorization @@ -3914,7 +3974,7 @@ Name | Type | Description | Notes # **getWebhookActivationLogs** -> InlineResponse20021 getWebhookActivationLogs(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter) +> InlineResponse20022 getWebhookActivationLogs(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter) List Webhook activation Log Entries @@ -3948,7 +4008,7 @@ BigDecimal campaignId = new BigDecimal(); // BigDecimal | Filter results by camp OffsetDateTime createdBefore = new OffsetDateTime(); // OffsetDateTime | Only return events created before this date. OffsetDateTime createdAfter = new OffsetDateTime(); // OffsetDateTime | Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. try { - InlineResponse20021 result = apiInstance.getWebhookActivationLogs(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter); + InlineResponse20022 result = apiInstance.getWebhookActivationLogs(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getWebhookActivationLogs"); @@ -3972,7 +4032,7 @@ Name | Type | Description | Notes ### Return type -[**InlineResponse20021**](InlineResponse20021.md) +[**InlineResponse20022**](InlineResponse20022.md) ### Authorization @@ -3985,7 +4045,7 @@ Name | Type | Description | Notes # **getWebhookLogs** -> InlineResponse20022 getWebhookLogs(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter) +> InlineResponse20023 getWebhookLogs(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter) List Webhook Log Entries @@ -4018,7 +4078,7 @@ String requestUuid = "requestUuid_example"; // String | Filter results by reques OffsetDateTime createdBefore = new OffsetDateTime(); // OffsetDateTime | Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. OffsetDateTime createdAfter = new OffsetDateTime(); // OffsetDateTime | Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. try { - InlineResponse20022 result = apiInstance.getWebhookLogs(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter); + InlineResponse20023 result = apiInstance.getWebhookLogs(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getWebhookLogs"); @@ -4043,7 +4103,7 @@ Name | Type | Description | Notes ### Return type -[**InlineResponse20022**](InlineResponse20022.md) +[**InlineResponse20023**](InlineResponse20023.md) ### Authorization @@ -4056,7 +4116,7 @@ Name | Type | Description | Notes # **getWebhooks** -> InlineResponse20020 getWebhooks(applicationIds, sort, pageSize, skip) +> InlineResponse20021 getWebhooks(applicationIds, sort, pageSize, skip) List Webhooks @@ -4083,7 +4143,7 @@ String sort = "sort_example"; // String | The field by which results should be s Integer pageSize = 56; // Integer | The number of items to include in this response. When omitted, the maximum value of 1000 will be used. Integer skip = 56; // Integer | Skips the given number of items when paging through large result sets. try { - InlineResponse20020 result = apiInstance.getWebhooks(applicationIds, sort, pageSize, skip); + InlineResponse20021 result = apiInstance.getWebhooks(applicationIds, sort, pageSize, skip); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling ManagementApi#getWebhooks"); @@ -4102,7 +4162,7 @@ Name | Type | Description | Notes ### Return type -[**InlineResponse20020**](InlineResponse20020.md) +[**InlineResponse20021**](InlineResponse20021.md) ### Authorization @@ -4606,13 +4666,13 @@ Name | Type | Description | Notes - **Content-Type**: application/json - **Accept**: application/json - -# **setAccountLimits** -> setAccountLimits(accountId, accountLimits) + +# **updateAttribute** +> Attribute updateAttribute(attributeId, newAttribute) -Set account limits +Update a custom attribute -sets account limits +Updates an existing custom attribute. Once created, the only property of a custom attribute that can be changed is the title (human readable description). This restriction is in place to prevent accidentally breaking live integrations. E.g. if you have a customer profile attribute with the name `region`, and your integration is sending `attributes.region` with customer profile updates, changing the name to `locale` would cause the integration requests to begin failing. If you **really** need to change the `type` or `name` property of a custom attribute, create a new attribute and update any relevant integrations and rules to use the new attribute. Then delete the old attribute when you are confident you have migrated any needed data from the old attribute to the new one. ### Example ```java @@ -4632,12 +4692,13 @@ manager_auth.setApiKey("YOUR API KEY"); //manager_auth.setApiKeyPrefix("Token"); ManagementApi apiInstance = new ManagementApi(); -Integer accountId = 56; // Integer | -AccountLimits accountLimits = new AccountLimits(); // AccountLimits | +Integer attributeId = 56; // Integer | +NewAttribute newAttribute = new NewAttribute(); // NewAttribute | try { - apiInstance.setAccountLimits(accountId, accountLimits); + Attribute result = apiInstance.updateAttribute(attributeId, newAttribute); + System.out.println(result); } catch (ApiException e) { - System.err.println("Exception when calling ManagementApi#setAccountLimits"); + System.err.println("Exception when calling ManagementApi#updateAttribute"); e.printStackTrace(); } ``` @@ -4646,12 +4707,12 @@ try { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **accountId** | **Integer**| | - **accountLimits** | [**AccountLimits**](AccountLimits.md)| | + **attributeId** | **Integer**| | + **newAttribute** | [**NewAttribute**](NewAttribute.md)| | ### Return type -null (empty response body) +[**Attribute**](Attribute.md) ### Authorization @@ -4660,7 +4721,7 @@ null (empty response body) ### HTTP request headers - **Content-Type**: application/json - - **Accept**: Not defined + - **Accept**: application/json # **updateCampaign** diff --git a/docs/NewApplication.md b/docs/NewApplication.md index 32e70d4a..668bf41f 100644 --- a/docs/NewApplication.md +++ b/docs/NewApplication.md @@ -11,6 +11,7 @@ Name | Type | Description | Notes **caseSensitivity** | [**CaseSensitivityEnum**](#CaseSensitivityEnum) | A string indicating how should campaigns in this application deal with case sensitivity on coupon codes. | [optional] **attributes** | [**Object**](.md) | Arbitrary properties associated with this campaign | [optional] **limits** | [**List<LimitConfig>**](LimitConfig.md) | Default limits for campaigns created in this application | [optional] +**attributesSettings** | [**AttributesSettings**](AttributesSettings.md) | | [optional] **key** | **String** | Hex key for HMAC-signing API calls as coming from this application (16 hex digits) | [optional] diff --git a/docs/NewSamlConnection.md b/docs/NewSamlConnection.md index 90f93232..5d230d9d 100644 --- a/docs/NewSamlConnection.md +++ b/docs/NewSamlConnection.md @@ -4,14 +4,15 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**x509certificate** | **String** | X.509 Certificate. | +**accountId** | **Integer** | The ID of the account that owns this entity. | **name** | **String** | ID of the SAML service. | **enabled** | **Boolean** | Determines if this SAML connection active. | **issuer** | **String** | Identity Provider Entity ID. | **signOnURL** | **String** | Single Sign-On URL. | **signOutURL** | **String** | Single Sign-Out URL. | [optional] **metadataURL** | **String** | Metadata URL. | [optional] -**x509certificate** | **String** | X.509 Certificate. | -**audience** | **String** | The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. | [optional] +**audienceURI** | **String** | The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. | [optional] diff --git a/docs/SamlConnection.md b/docs/SamlConnection.md index ffbce238..a736c372 100644 --- a/docs/SamlConnection.md +++ b/docs/SamlConnection.md @@ -4,18 +4,17 @@ ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**id** | **Integer** | | -**created** | [**OffsetDateTime**](OffsetDateTime.md) | Unix timestamp indicating when the session was first created. | -**accountId** | **Integer** | The ID of the account that owns this SAML Service. | **assertionConsumerServiceURL** | **String** | The location where the SAML assertion is sent with a HTTP POST. | +**accountId** | **Integer** | The ID of the account that owns this entity. | **name** | **String** | ID of the SAML service. | **enabled** | **Boolean** | Determines if this SAML connection active. | **issuer** | **String** | Identity Provider Entity ID. | **signOnURL** | **String** | Single Sign-On URL. | **signOutURL** | **String** | Single Sign-Out URL. | [optional] **metadataURL** | **String** | Metadata URL. | [optional] -**x509certificate** | **String** | X.509 Certificate. | -**audience** | **String** | The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. | +**audienceURI** | **String** | The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. | +**id** | **Integer** | Unique ID for this entity. | +**created** | [**OffsetDateTime**](OffsetDateTime.md) | The exact moment this entity was created. | diff --git a/docs/SamlConnectionMetadata.md b/docs/SamlConnectionMetadata.md new file mode 100644 index 00000000..27251a14 --- /dev/null +++ b/docs/SamlConnectionMetadata.md @@ -0,0 +1,13 @@ + +# SamlConnectionMetadata + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | ID of the SAML service. | +**enabled** | **Boolean** | Determines if this SAML connection active. | +**accountId** | [**BigDecimal**](BigDecimal.md) | | +**metadataDocument** | **String** | Identity Provider metadata XML document. | + + + diff --git a/docs/UpdateApplication.md b/docs/UpdateApplication.md index fcb3599c..0f230e31 100644 --- a/docs/UpdateApplication.md +++ b/docs/UpdateApplication.md @@ -11,6 +11,7 @@ Name | Type | Description | Notes **caseSensitivity** | [**CaseSensitivityEnum**](#CaseSensitivityEnum) | A string indicating how should campaigns in this application deal with case sensitivity on coupon codes. | [optional] **attributes** | [**Object**](.md) | Arbitrary properties associated with this campaign | [optional] **limits** | [**List<LimitConfig>**](LimitConfig.md) | Default limits for campaigns created in this application | [optional] +**attributesSettings** | [**AttributesSettings**](AttributesSettings.md) | | [optional] diff --git a/pom.xml b/pom.xml index fd094206..381af749 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ talon-one-client jar talon-one-client - 3.4.0 + 3.5.0 https://github.com/talon-one/maven-artefacts Talon.One unified JAVA SDK. It allows for programatic access to the integration and management API with their respective authentication strategies diff --git a/src/main/java/one/talon/ApiClient.java b/src/main/java/one/talon/ApiClient.java index 764b45aa..fa78a730 100644 --- a/src/main/java/one/talon/ApiClient.java +++ b/src/main/java/one/talon/ApiClient.java @@ -137,7 +137,7 @@ private void init() { json = new JSON(); // Set default User-Agent. - setUserAgent("OpenAPI-Generator/3.4.0/java"); + setUserAgent("OpenAPI-Generator/3.5.0/java"); authentications = new HashMap(); } diff --git a/src/main/java/one/talon/api/IntegrationApi.java b/src/main/java/one/talon/api/IntegrationApi.java index ff6b28a4..f1b161d5 100644 --- a/src/main/java/one/talon/api/IntegrationApi.java +++ b/src/main/java/one/talon/api/IntegrationApi.java @@ -29,6 +29,7 @@ import one.talon.model.Coupon; import one.talon.model.CouponReservations; +import one.talon.model.CustomerInventory; import one.talon.model.InlineResponse200; import one.talon.model.InlineResponse2001; import one.talon.model.IntegrationState; @@ -560,6 +561,144 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don apiClient.executeAsync(call, callback); return call; } + /** + * Build call for getCustomerInventory + * @param integrationId The custom identifier for this profile, must be unique within the account. (required) + * @param profile optional flag to decide if you would like customer profile information in the response (optional, default to null) + * @param referrals optional flag to decide if you would like referral information in the response (optional, default to null) + * @param progressListener Progress listener + * @param progressRequestListener Progress request listener + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + */ + public com.squareup.okhttp.Call getCustomerInventoryCall(String integrationId, Object profile, Object referrals, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = new Object(); + + // create path and map variables + String localVarPath = "/v1/customer_profiles/{integrationId}/inventory" + .replaceAll("\\{" + "integrationId" + "\\}", apiClient.escapeString(integrationId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + if (profile != null) { + localVarQueryParams.addAll(apiClient.parameterToPair("profile", profile)); + } + + if (referrals != null) { + localVarQueryParams.addAll(apiClient.parameterToPair("referrals", referrals)); + } + + Map localVarHeaderParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + if (progressListener != null) { + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { + @Override + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); + return originalResponse.newBuilder() + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) + .build(); + } + }); + } + + String[] localVarAuthNames = new String[] { "api_key_v1", "integration_auth" }; + return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); + } + + @SuppressWarnings("rawtypes") + private com.squareup.okhttp.Call getCustomerInventoryValidateBeforeCall(String integrationId, Object profile, Object referrals, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + + // verify the required parameter 'integrationId' is set + if (integrationId == null) { + throw new ApiException("Missing the required parameter 'integrationId' when calling getCustomerInventory(Async)"); + } + + + com.squareup.okhttp.Call call = getCustomerInventoryCall(integrationId, profile, referrals, progressListener, progressRequestListener); + return call; + + } + + /** + * Get an inventory of all data associated with a specific customer profile. + * Get information regarding entities referencing this customer profile's integrationId. Currently we support customer profile information and referral codes. In the future, this will be expanded with coupon codes and loyalty points. + * @param integrationId The custom identifier for this profile, must be unique within the account. (required) + * @param profile optional flag to decide if you would like customer profile information in the response (optional, default to null) + * @param referrals optional flag to decide if you would like referral information in the response (optional, default to null) + * @return CustomerInventory + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public CustomerInventory getCustomerInventory(String integrationId, Object profile, Object referrals) throws ApiException { + ApiResponse resp = getCustomerInventoryWithHttpInfo(integrationId, profile, referrals); + return resp.getData(); + } + + /** + * Get an inventory of all data associated with a specific customer profile. + * Get information regarding entities referencing this customer profile's integrationId. Currently we support customer profile information and referral codes. In the future, this will be expanded with coupon codes and loyalty points. + * @param integrationId The custom identifier for this profile, must be unique within the account. (required) + * @param profile optional flag to decide if you would like customer profile information in the response (optional, default to null) + * @param referrals optional flag to decide if you would like referral information in the response (optional, default to null) + * @return ApiResponse<CustomerInventory> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public ApiResponse getCustomerInventoryWithHttpInfo(String integrationId, Object profile, Object referrals) throws ApiException { + com.squareup.okhttp.Call call = getCustomerInventoryValidateBeforeCall(integrationId, profile, referrals, null, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return apiClient.execute(call, localVarReturnType); + } + + /** + * Get an inventory of all data associated with a specific customer profile. (asynchronously) + * Get information regarding entities referencing this customer profile's integrationId. Currently we support customer profile information and referral codes. In the future, this will be expanded with coupon codes and loyalty points. + * @param integrationId The custom identifier for this profile, must be unique within the account. (required) + * @param profile optional flag to decide if you would like customer profile information in the response (optional, default to null) + * @param referrals optional flag to decide if you would like referral information in the response (optional, default to null) + * @param callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + */ + public com.squareup.okhttp.Call getCustomerInventoryAsync(String integrationId, Object profile, Object referrals, final ApiCallback callback) throws ApiException { + + ProgressResponseBody.ProgressListener progressListener = null; + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; + + if (callback != null) { + progressListener = new ProgressResponseBody.ProgressListener() { + @Override + public void update(long bytesRead, long contentLength, boolean done) { + callback.onDownloadProgress(bytesRead, contentLength, done); + } + }; + + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { + @Override + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { + callback.onUploadProgress(bytesWritten, contentLength, done); + } + }; + } + + com.squareup.okhttp.Call call = getCustomerInventoryValidateBeforeCall(integrationId, profile, referrals, progressListener, progressRequestListener); + Type localVarReturnType = new TypeToken(){}.getType(); + apiClient.executeAsync(call, localVarReturnType, callback); + return call; + } /** * Build call for getReservedCoupons * @param integrationId The custom identifier for this profile, must be unique within the account. (required) diff --git a/src/main/java/one/talon/api/ManagementApi.java b/src/main/java/one/talon/api/ManagementApi.java index a517d010..ff14ea35 100644 --- a/src/main/java/one/talon/api/ManagementApi.java +++ b/src/main/java/one/talon/api/ManagementApi.java @@ -29,7 +29,6 @@ import one.talon.model.Account; import one.talon.model.AccountAnalytics; -import one.talon.model.AccountLimits; import one.talon.model.Application; import one.talon.model.ApplicationApiHealth; import one.talon.model.ApplicationCustomer; @@ -67,6 +66,7 @@ import one.talon.model.InlineResponse20026; import one.talon.model.InlineResponse20027; import one.talon.model.InlineResponse20028; +import one.talon.model.InlineResponse20029; import one.talon.model.InlineResponse2003; import one.talon.model.InlineResponse2004; import one.talon.model.InlineResponse2005; @@ -78,6 +78,7 @@ import one.talon.model.LoyaltyLedger; import one.talon.model.LoyaltyPoints; import one.talon.model.LoyaltyProgram; +import one.talon.model.NewAttribute; import one.talon.model.NewCampaign; import one.talon.model.NewCampaignSet; import one.talon.model.NewCoupons; @@ -397,6 +398,127 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don apiClient.executeAsync(call, localVarReturnType, callback); return call; } + /** + * Build call for createAttribute + * @param newAttribute (required) + * @param progressListener Progress listener + * @param progressRequestListener Progress request listener + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + */ + public com.squareup.okhttp.Call createAttributeCall(NewAttribute newAttribute, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = newAttribute; + + // create path and map variables + String localVarPath = "/v1/attributes"; + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + "application/json" + }; + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + if (progressListener != null) { + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { + @Override + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); + return originalResponse.newBuilder() + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) + .build(); + } + }); + } + + String[] localVarAuthNames = new String[] { "manager_auth" }; + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); + } + + @SuppressWarnings("rawtypes") + private com.squareup.okhttp.Call createAttributeValidateBeforeCall(NewAttribute newAttribute, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + + // verify the required parameter 'newAttribute' is set + if (newAttribute == null) { + throw new ApiException("Missing the required parameter 'newAttribute' when calling createAttribute(Async)"); + } + + + com.squareup.okhttp.Call call = createAttributeCall(newAttribute, progressListener, progressRequestListener); + return call; + + } + + /** + * Define a new custom attribute + * Defines a new _custom attribute_ in this account. Custom attributes allow you to attach new fields to Talon.One domain objects like campaigns, coupons, customers and so on. These attributes can then be given values when creating / updating these objects, and these values can be used in your campaign rules. For example, you could define a `zipCode` field for customer sessions, and add a rule to your campaign that only allows certain ZIP codes. These attributes are shared across all applications in your account, and are never required. + * @param newAttribute (required) + * @return Attribute + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public Attribute createAttribute(NewAttribute newAttribute) throws ApiException { + ApiResponse resp = createAttributeWithHttpInfo(newAttribute); + return resp.getData(); + } + + /** + * Define a new custom attribute + * Defines a new _custom attribute_ in this account. Custom attributes allow you to attach new fields to Talon.One domain objects like campaigns, coupons, customers and so on. These attributes can then be given values when creating / updating these objects, and these values can be used in your campaign rules. For example, you could define a `zipCode` field for customer sessions, and add a rule to your campaign that only allows certain ZIP codes. These attributes are shared across all applications in your account, and are never required. + * @param newAttribute (required) + * @return ApiResponse<Attribute> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public ApiResponse createAttributeWithHttpInfo(NewAttribute newAttribute) throws ApiException { + com.squareup.okhttp.Call call = createAttributeValidateBeforeCall(newAttribute, null, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return apiClient.execute(call, localVarReturnType); + } + + /** + * Define a new custom attribute (asynchronously) + * Defines a new _custom attribute_ in this account. Custom attributes allow you to attach new fields to Talon.One domain objects like campaigns, coupons, customers and so on. These attributes can then be given values when creating / updating these objects, and these values can be used in your campaign rules. For example, you could define a `zipCode` field for customer sessions, and add a rule to your campaign that only allows certain ZIP codes. These attributes are shared across all applications in your account, and are never required. + * @param newAttribute (required) + * @param callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + */ + public com.squareup.okhttp.Call createAttributeAsync(NewAttribute newAttribute, final ApiCallback callback) throws ApiException { + + ProgressResponseBody.ProgressListener progressListener = null; + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; + + if (callback != null) { + progressListener = new ProgressResponseBody.ProgressListener() { + @Override + public void update(long bytesRead, long contentLength, boolean done) { + callback.onDownloadProgress(bytesRead, contentLength, done); + } + }; + + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { + @Override + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { + callback.onUploadProgress(bytesWritten, contentLength, done); + } + }; + } + + com.squareup.okhttp.Call call = createAttributeValidateBeforeCall(newAttribute, progressListener, progressRequestListener); + Type localVarReturnType = new TypeToken(){}.getType(); + apiClient.executeAsync(call, localVarReturnType, callback); + return call; + } /** * Build call for createCampaign * @param applicationId (required) @@ -611,7 +733,7 @@ private com.squareup.okhttp.Call createCouponsValidateBeforeCall(Integer applica /** * Create Coupons - * Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupns can be created. + * Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupons can be created. * @param applicationId (required) * @param campaignId (required) * @param newCoupons (required) @@ -626,7 +748,7 @@ public InlineResponse2001 createCoupons(Integer applicationId, Integer campaignI /** * Create Coupons - * Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupns can be created. + * Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupons can be created. * @param applicationId (required) * @param campaignId (required) * @param newCoupons (required) @@ -642,7 +764,7 @@ public ApiResponse createCouponsWithHttpInfo(Integer applica /** * Create Coupons (asynchronously) - * Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupns can be created. + * Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupons can be created. * @param applicationId (required) * @param campaignId (required) * @param newCoupons (required) @@ -1839,8 +1961,8 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don * @param applicationId (required) * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -1953,8 +2075,8 @@ private com.squareup.okhttp.Call getAccessLogsValidateBeforeCall(Integer applica * @param applicationId (required) * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -1973,8 +2095,8 @@ public InlineResponse2009 getAccessLogs(Integer applicationId, OffsetDateTime ra * @param applicationId (required) * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -1994,8 +2116,8 @@ public ApiResponse getAccessLogsWithHttpInfo(Integer applica * @param applicationId (required) * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2035,8 +2157,8 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don * @param applicationId (required) * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2149,8 +2271,8 @@ private com.squareup.okhttp.Call getAccessLogsWithoutTotalCountValidateBeforeCal * @param applicationId (required) * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2169,8 +2291,8 @@ public InlineResponse20010 getAccessLogsWithoutTotalCount(Integer applicationId, * @param applicationId (required) * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2190,8 +2312,8 @@ public ApiResponse getAccessLogsWithoutTotalCountWithHttpIn * @param applicationId (required) * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2470,134 +2592,12 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don apiClient.executeAsync(call, localVarReturnType, callback); return call; } - /** - * Build call for getAccountLimits - * @param accountId (required) - * @param progressListener Progress listener - * @param progressRequestListener Progress request listener - * @return Call to execute - * @throws ApiException If fail to serialize the request body object - */ - public com.squareup.okhttp.Call getAccountLimitsCall(Integer accountId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = new Object(); - - // create path and map variables - String localVarPath = "/v1/accounts/{accountId}/limits" - .replaceAll("\\{" + "accountId" + "\\}", apiClient.escapeString(accountId.toString())); - - List localVarQueryParams = new ArrayList(); - List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarFormParams = new HashMap(); - final String[] localVarAccepts = { - "application/json" - }; - final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); - if (localVarAccept != null) { - localVarHeaderParams.put("Accept", localVarAccept); - } - - final String[] localVarContentTypes = { - - }; - final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); - localVarHeaderParams.put("Content-Type", localVarContentType); - - if (progressListener != null) { - apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { - @Override - public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { - com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); - return originalResponse.newBuilder() - .body(new ProgressResponseBody(originalResponse.body(), progressListener)) - .build(); - } - }); - } - - String[] localVarAuthNames = new String[] { "manager_auth" }; - return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); - } - - @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call getAccountLimitsValidateBeforeCall(Integer accountId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - - // verify the required parameter 'accountId' is set - if (accountId == null) { - throw new ApiException("Missing the required parameter 'accountId' when calling getAccountLimits(Async)"); - } - - - com.squareup.okhttp.Call call = getAccountLimitsCall(accountId, progressListener, progressRequestListener); - return call; - - } - - /** - * Get Account Limits - * Returns a list of all account limits set - * @param accountId (required) - * @return AccountLimits - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public AccountLimits getAccountLimits(Integer accountId) throws ApiException { - ApiResponse resp = getAccountLimitsWithHttpInfo(accountId); - return resp.getData(); - } - - /** - * Get Account Limits - * Returns a list of all account limits set - * @param accountId (required) - * @return ApiResponse<AccountLimits> - * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body - */ - public ApiResponse getAccountLimitsWithHttpInfo(Integer accountId) throws ApiException { - com.squareup.okhttp.Call call = getAccountLimitsValidateBeforeCall(accountId, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); - return apiClient.execute(call, localVarReturnType); - } - - /** - * Get Account Limits (asynchronously) - * Returns a list of all account limits set - * @param accountId (required) - * @param callback The callback to be executed when the API call finishes - * @return The request call - * @throws ApiException If fail to process the API call, e.g. serializing the request body object - */ - public com.squareup.okhttp.Call getAccountLimitsAsync(Integer accountId, final ApiCallback callback) throws ApiException { - - ProgressResponseBody.ProgressListener progressListener = null; - ProgressRequestBody.ProgressRequestListener progressRequestListener = null; - - if (callback != null) { - progressListener = new ProgressResponseBody.ProgressListener() { - @Override - public void update(long bytesRead, long contentLength, boolean done) { - callback.onDownloadProgress(bytesRead, contentLength, done); - } - }; - - progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { - @Override - public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { - callback.onUploadProgress(bytesWritten, contentLength, done); - } - }; - } - - com.squareup.okhttp.Call call = getAccountLimitsValidateBeforeCall(accountId, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); - apiClient.executeAsync(call, localVarReturnType, callback); - return call; - } /** * Build call for getAllAccessLogs * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2703,8 +2703,8 @@ private com.squareup.okhttp.Call getAllAccessLogsValidateBeforeCall(OffsetDateTi * Fetches the access logs for the entire account. Sensitive requests (logins) are _always_ filtered from the logs. * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2722,8 +2722,8 @@ public InlineResponse2009 getAllAccessLogs(OffsetDateTime rangeStart, OffsetDate * Fetches the access logs for the entire account. Sensitive requests (logins) are _always_ filtered from the logs. * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2742,8 +2742,8 @@ public ApiResponse getAllAccessLogsWithHttpInfo(OffsetDateTi * Fetches the access logs for the entire account. Sensitive requests (logins) are _always_ filtered from the logs. * @param rangeStart Only return results from after this timestamp, must be an RFC3339 timestamp string (required) * @param rangeEnd Only return results from before this timestamp, must be an RFC3339 timestamp string (required) - * @param path Only return results where the request path matches the given regular expresssion. (optional) - * @param method Only return results where the request method matches the given regular expresssion. (optional) + * @param path Only return results where the request path matches the given regular expression. (optional) + * @param method Only return results where the request method matches the given regular expression. (optional) * @param status Filter results by HTTP status codes. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -2837,23 +2837,23 @@ private com.squareup.okhttp.Call getAllRolesValidateBeforeCall(final ProgressRes /** * Get all roles. * - * @return InlineResponse20028 + * @return InlineResponse20029 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20028 getAllRoles() throws ApiException { - ApiResponse resp = getAllRolesWithHttpInfo(); + public InlineResponse20029 getAllRoles() throws ApiException { + ApiResponse resp = getAllRolesWithHttpInfo(); return resp.getData(); } /** * Get all roles. * - * @return ApiResponse<InlineResponse20028> + * @return ApiResponse<InlineResponse20029> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getAllRolesWithHttpInfo() throws ApiException { + public ApiResponse getAllRolesWithHttpInfo() throws ApiException { com.squareup.okhttp.Call call = getAllRolesValidateBeforeCall(null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -2864,7 +2864,7 @@ public ApiResponse getAllRolesWithHttpInfo() throws ApiExce * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getAllRolesAsync(final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getAllRolesAsync(final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -2886,7 +2886,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getAllRolesValidateBeforeCall(progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -3455,7 +3455,7 @@ private com.squareup.okhttp.Call getApplicationCustomersByAttributesValidateBefo /** * Get a list of the customer profiles that match the given attributes - * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile + * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile * @param applicationCustomerSearch (required) * @return InlineResponse20013 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body @@ -3469,7 +3469,7 @@ public InlineResponse20013 getApplicationCustomersByAttributes(ApplicationCustom /** * Get a list of the customer profiles that match the given attributes - * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile + * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile * @param applicationCustomerSearch (required) * @return ApiResponse<InlineResponse20013> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body @@ -3484,7 +3484,7 @@ public ApiResponse getApplicationCustomersByAttributesWithH /** * Get a list of the customer profiles that match the given attributes (asynchronously) - * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile + * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile * @param applicationCustomerSearch (required) * @param callback The callback to be executed when the API call finishes * @return The request call @@ -4692,6 +4692,142 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don apiClient.executeAsync(call, localVarReturnType, callback); return call; } + /** + * Build call for getAttributes + * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) + * @param skip Skips the given number of items when paging through large result sets. (optional) + * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) + * @param progressListener Progress listener + * @param progressRequestListener Progress request listener + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + */ + public com.squareup.okhttp.Call getAttributesCall(Integer pageSize, Integer skip, String sort, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = new Object(); + + // create path and map variables + String localVarPath = "/v1/attributes"; + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + if (pageSize != null) { + localVarQueryParams.addAll(apiClient.parameterToPair("pageSize", pageSize)); + } + + if (skip != null) { + localVarQueryParams.addAll(apiClient.parameterToPair("skip", skip)); + } + + if (sort != null) { + localVarQueryParams.addAll(apiClient.parameterToPair("sort", sort)); + } + + Map localVarHeaderParams = new HashMap(); + Map localVarFormParams = new HashMap(); + final String[] localVarAccepts = { + "application/json" + }; + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = { + + }; + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); + localVarHeaderParams.put("Content-Type", localVarContentType); + + if (progressListener != null) { + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { + @Override + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); + return originalResponse.newBuilder() + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) + .build(); + } + }); + } + + String[] localVarAuthNames = new String[] { "manager_auth" }; + return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); + } + + @SuppressWarnings("rawtypes") + private com.squareup.okhttp.Call getAttributesValidateBeforeCall(Integer pageSize, Integer skip, String sort, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + + + com.squareup.okhttp.Call call = getAttributesCall(pageSize, skip, sort, progressListener, progressRequestListener); + return call; + + } + + /** + * List custom attributes + * Returns all the defined custom attributes for the account. + * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) + * @param skip Skips the given number of items when paging through large result sets. (optional) + * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) + * @return InlineResponse20020 + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public InlineResponse20020 getAttributes(Integer pageSize, Integer skip, String sort) throws ApiException { + ApiResponse resp = getAttributesWithHttpInfo(pageSize, skip, sort); + return resp.getData(); + } + + /** + * List custom attributes + * Returns all the defined custom attributes for the account. + * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) + * @param skip Skips the given number of items when paging through large result sets. (optional) + * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) + * @return ApiResponse<InlineResponse20020> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body + */ + public ApiResponse getAttributesWithHttpInfo(Integer pageSize, Integer skip, String sort) throws ApiException { + com.squareup.okhttp.Call call = getAttributesValidateBeforeCall(pageSize, skip, sort, null, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return apiClient.execute(call, localVarReturnType); + } + + /** + * List custom attributes (asynchronously) + * Returns all the defined custom attributes for the account. + * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) + * @param skip Skips the given number of items when paging through large result sets. (optional) + * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) + * @param callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body object + */ + public com.squareup.okhttp.Call getAttributesAsync(Integer pageSize, Integer skip, String sort, final ApiCallback callback) throws ApiException { + + ProgressResponseBody.ProgressListener progressListener = null; + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; + + if (callback != null) { + progressListener = new ProgressResponseBody.ProgressListener() { + @Override + public void update(long bytesRead, long contentLength, boolean done) { + callback.onDownloadProgress(bytesRead, contentLength, done); + } + }; + + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { + @Override + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { + callback.onUploadProgress(bytesWritten, contentLength, done); + } + }; + } + + com.squareup.okhttp.Call call = getAttributesValidateBeforeCall(pageSize, skip, sort, progressListener, progressRequestListener); + Type localVarReturnType = new TypeToken(){}.getType(); + apiClient.executeAsync(call, localVarReturnType, callback); + return call; + } /** * Build call for getCampaign * @param applicationId (required) @@ -5568,11 +5704,11 @@ private com.squareup.okhttp.Call getChangesValidateBeforeCall(Integer pageSize, * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the change creation timestamp. (optional) * @param withTotalResultSize When this flag is set, the result will include the total size of the result, across all pages. This might decrease performance on large data sets. With this flag set to true, hasMore will be be true whenever there is a next page. totalResultSize will always be zero. With this flag set to false, hasMore will always be set to false. totalResultSize will contain the total number of results for this query. (optional) * @param includeOld When this flag is set to false, the state without the change will not be returned. The default value is true. (optional) - * @return InlineResponse20025 + * @return InlineResponse20026 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20025 getChanges(Integer pageSize, Integer skip, String sort, Integer applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Boolean includeOld) throws ApiException { - ApiResponse resp = getChangesWithHttpInfo(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld); + public InlineResponse20026 getChanges(Integer pageSize, Integer skip, String sort, Integer applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Boolean includeOld) throws ApiException { + ApiResponse resp = getChangesWithHttpInfo(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld); return resp.getData(); } @@ -5587,12 +5723,12 @@ public InlineResponse20025 getChanges(Integer pageSize, Integer skip, String sor * @param createdAfter Filter results comparing the parameter value, expected to be an RFC3339 timestamp string, to the change creation timestamp. (optional) * @param withTotalResultSize When this flag is set, the result will include the total size of the result, across all pages. This might decrease performance on large data sets. With this flag set to true, hasMore will be be true whenever there is a next page. totalResultSize will always be zero. With this flag set to false, hasMore will always be set to false. totalResultSize will contain the total number of results for this query. (optional) * @param includeOld When this flag is set to false, the state without the change will not be returned. The default value is true. (optional) - * @return ApiResponse<InlineResponse20025> + * @return ApiResponse<InlineResponse20026> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getChangesWithHttpInfo(Integer pageSize, Integer skip, String sort, Integer applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Boolean includeOld) throws ApiException { + public ApiResponse getChangesWithHttpInfo(Integer pageSize, Integer skip, String sort, Integer applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Boolean includeOld) throws ApiException { com.squareup.okhttp.Call call = getChangesValidateBeforeCall(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -5611,7 +5747,7 @@ public ApiResponse getChangesWithHttpInfo(Integer pageSize, * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getChangesAsync(Integer pageSize, Integer skip, String sort, Integer applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Boolean includeOld, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getChangesAsync(Integer pageSize, Integer skip, String sort, Integer applicationId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, Boolean withTotalResultSize, Boolean includeOld, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -5633,7 +5769,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getChangesValidateBeforeCall(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -7669,7 +7805,7 @@ private com.squareup.okhttp.Call getCustomersByAttributesValidateBeforeCall(Appl /** * Get a list of the customer profiles that match the given attributes - * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile + * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile * @param applicationCustomerSearch (required) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -7683,7 +7819,7 @@ public InlineResponse20013 getCustomersByAttributes(ApplicationCustomerSearch ap /** * Get a list of the customer profiles that match the given attributes - * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile + * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile * @param applicationCustomerSearch (required) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -7698,7 +7834,7 @@ public ApiResponse getCustomersByAttributesWithHttpInfo(App /** * Get a list of the customer profiles that match the given attributes (asynchronously) - * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile + * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile * @param applicationCustomerSearch (required) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) @@ -7827,11 +7963,11 @@ private com.squareup.okhttp.Call getEventTypesValidateBeforeCall(String applicat * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) - * @return InlineResponse20023 + * @return InlineResponse20024 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20023 getEventTypes(String applicationIds, String name, Boolean includeOldVersions, Integer pageSize, Integer skip, String sort) throws ApiException { - ApiResponse resp = getEventTypesWithHttpInfo(applicationIds, name, includeOldVersions, pageSize, skip, sort); + public InlineResponse20024 getEventTypes(String applicationIds, String name, Boolean includeOldVersions, Integer pageSize, Integer skip, String sort) throws ApiException { + ApiResponse resp = getEventTypesWithHttpInfo(applicationIds, name, includeOldVersions, pageSize, skip, sort); return resp.getData(); } @@ -7844,12 +7980,12 @@ public InlineResponse20023 getEventTypes(String applicationIds, String name, Boo * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) - * @return ApiResponse<InlineResponse20023> + * @return ApiResponse<InlineResponse20024> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getEventTypesWithHttpInfo(String applicationIds, String name, Boolean includeOldVersions, Integer pageSize, Integer skip, String sort) throws ApiException { + public ApiResponse getEventTypesWithHttpInfo(String applicationIds, String name, Boolean includeOldVersions, Integer pageSize, Integer skip, String sort) throws ApiException { com.squareup.okhttp.Call call = getEventTypesValidateBeforeCall(applicationIds, name, includeOldVersions, pageSize, skip, sort, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -7866,7 +8002,7 @@ public ApiResponse getEventTypesWithHttpInfo(String applica * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getEventTypesAsync(String applicationIds, String name, Boolean includeOldVersions, Integer pageSize, Integer skip, String sort, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getEventTypesAsync(String applicationIds, String name, Boolean includeOldVersions, Integer pageSize, Integer skip, String sort, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -7888,7 +8024,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getEventTypesValidateBeforeCall(applicationIds, name, includeOldVersions, pageSize, skip, sort, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -7981,11 +8117,11 @@ private com.squareup.okhttp.Call getExportsValidateBeforeCall(Integer pageSize, * @param applicationId (optional) * @param campaignId (optional) * @param entity The name of the entity type that was exported. (optional) - * @return InlineResponse20026 + * @return InlineResponse20027 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20026 getExports(Integer pageSize, Integer skip, Integer applicationId, Integer campaignId, String entity) throws ApiException { - ApiResponse resp = getExportsWithHttpInfo(pageSize, skip, applicationId, campaignId, entity); + public InlineResponse20027 getExports(Integer pageSize, Integer skip, Integer applicationId, Integer campaignId, String entity) throws ApiException { + ApiResponse resp = getExportsWithHttpInfo(pageSize, skip, applicationId, campaignId, entity); return resp.getData(); } @@ -7997,12 +8133,12 @@ public InlineResponse20026 getExports(Integer pageSize, Integer skip, Integer ap * @param applicationId (optional) * @param campaignId (optional) * @param entity The name of the entity type that was exported. (optional) - * @return ApiResponse<InlineResponse20026> + * @return ApiResponse<InlineResponse20027> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getExportsWithHttpInfo(Integer pageSize, Integer skip, Integer applicationId, Integer campaignId, String entity) throws ApiException { + public ApiResponse getExportsWithHttpInfo(Integer pageSize, Integer skip, Integer applicationId, Integer campaignId, String entity) throws ApiException { com.squareup.okhttp.Call call = getExportsValidateBeforeCall(pageSize, skip, applicationId, campaignId, entity, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -8018,7 +8154,7 @@ public ApiResponse getExportsWithHttpInfo(Integer pageSize, * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getExportsAsync(Integer pageSize, Integer skip, Integer applicationId, Integer campaignId, String entity, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getExportsAsync(Integer pageSize, Integer skip, Integer applicationId, Integer campaignId, String entity, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -8040,7 +8176,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getExportsValidateBeforeCall(pageSize, skip, applicationId, campaignId, entity, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -8115,11 +8251,11 @@ private com.squareup.okhttp.Call getImportsValidateBeforeCall(Integer pageSize, * Get a list of all past imports * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) - * @return InlineResponse20027 + * @return InlineResponse20028 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20027 getImports(Integer pageSize, Integer skip) throws ApiException { - ApiResponse resp = getImportsWithHttpInfo(pageSize, skip); + public InlineResponse20028 getImports(Integer pageSize, Integer skip) throws ApiException { + ApiResponse resp = getImportsWithHttpInfo(pageSize, skip); return resp.getData(); } @@ -8128,12 +8264,12 @@ public InlineResponse20027 getImports(Integer pageSize, Integer skip) throws Api * Get a list of all past imports * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) - * @return ApiResponse<InlineResponse20027> + * @return ApiResponse<InlineResponse20028> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getImportsWithHttpInfo(Integer pageSize, Integer skip) throws ApiException { + public ApiResponse getImportsWithHttpInfo(Integer pageSize, Integer skip) throws ApiException { com.squareup.okhttp.Call call = getImportsValidateBeforeCall(pageSize, skip, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -8146,7 +8282,7 @@ public ApiResponse getImportsWithHttpInfo(Integer pageSize, * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getImportsAsync(Integer pageSize, Integer skip, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getImportsAsync(Integer pageSize, Integer skip, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -8168,7 +8304,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getImportsValidateBeforeCall(pageSize, skip, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -9565,11 +9701,11 @@ private com.squareup.okhttp.Call getUsersValidateBeforeCall(Integer pageSize, In * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) - * @return InlineResponse20024 + * @return InlineResponse20025 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20024 getUsers(Integer pageSize, Integer skip, String sort) throws ApiException { - ApiResponse resp = getUsersWithHttpInfo(pageSize, skip, sort); + public InlineResponse20025 getUsers(Integer pageSize, Integer skip, String sort) throws ApiException { + ApiResponse resp = getUsersWithHttpInfo(pageSize, skip, sort); return resp.getData(); } @@ -9579,12 +9715,12 @@ public InlineResponse20024 getUsers(Integer pageSize, Integer skip, String sort) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) - * @return ApiResponse<InlineResponse20024> + * @return ApiResponse<InlineResponse20025> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getUsersWithHttpInfo(Integer pageSize, Integer skip, String sort) throws ApiException { + public ApiResponse getUsersWithHttpInfo(Integer pageSize, Integer skip, String sort) throws ApiException { com.squareup.okhttp.Call call = getUsersValidateBeforeCall(pageSize, skip, sort, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -9598,7 +9734,7 @@ public ApiResponse getUsersWithHttpInfo(Integer pageSize, I * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getUsersAsync(Integer pageSize, Integer skip, String sort, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getUsersAsync(Integer pageSize, Integer skip, String sort, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -9620,7 +9756,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getUsersValidateBeforeCall(pageSize, skip, sort, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -9859,11 +9995,11 @@ private com.squareup.okhttp.Call getWebhookActivationLogsValidateBeforeCall(Inte * @param campaignId Filter results by campaign. (optional) * @param createdBefore Only return events created before this date. (optional) * @param createdAfter Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. (optional) - * @return InlineResponse20021 + * @return InlineResponse20022 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20021 getWebhookActivationLogs(Integer pageSize, Integer skip, String sort, String integrationRequestUuid, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, OffsetDateTime createdBefore, OffsetDateTime createdAfter) throws ApiException { - ApiResponse resp = getWebhookActivationLogsWithHttpInfo(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter); + public InlineResponse20022 getWebhookActivationLogs(Integer pageSize, Integer skip, String sort, String integrationRequestUuid, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, OffsetDateTime createdBefore, OffsetDateTime createdAfter) throws ApiException { + ApiResponse resp = getWebhookActivationLogsWithHttpInfo(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter); return resp.getData(); } @@ -9879,12 +10015,12 @@ public InlineResponse20021 getWebhookActivationLogs(Integer pageSize, Integer sk * @param campaignId Filter results by campaign. (optional) * @param createdBefore Only return events created before this date. (optional) * @param createdAfter Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. (optional) - * @return ApiResponse<InlineResponse20021> + * @return ApiResponse<InlineResponse20022> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getWebhookActivationLogsWithHttpInfo(Integer pageSize, Integer skip, String sort, String integrationRequestUuid, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, OffsetDateTime createdBefore, OffsetDateTime createdAfter) throws ApiException { + public ApiResponse getWebhookActivationLogsWithHttpInfo(Integer pageSize, Integer skip, String sort, String integrationRequestUuid, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, OffsetDateTime createdBefore, OffsetDateTime createdAfter) throws ApiException { com.squareup.okhttp.Call call = getWebhookActivationLogsValidateBeforeCall(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -9904,7 +10040,7 @@ public ApiResponse getWebhookActivationLogsWithHttpInfo(Int * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getWebhookActivationLogsAsync(Integer pageSize, Integer skip, String sort, String integrationRequestUuid, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getWebhookActivationLogsAsync(Integer pageSize, Integer skip, String sort, String integrationRequestUuid, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, OffsetDateTime createdBefore, OffsetDateTime createdAfter, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -9926,7 +10062,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getWebhookActivationLogsValidateBeforeCall(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -10049,11 +10185,11 @@ private com.squareup.okhttp.Call getWebhookLogsValidateBeforeCall(Integer pageSi * @param requestUuid Filter results by request UUID. (optional) * @param createdBefore Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. (optional) * @param createdAfter Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. (optional) - * @return InlineResponse20022 + * @return InlineResponse20023 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20022 getWebhookLogs(Integer pageSize, Integer skip, String sort, String status, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, String requestUuid, OffsetDateTime createdBefore, OffsetDateTime createdAfter) throws ApiException { - ApiResponse resp = getWebhookLogsWithHttpInfo(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter); + public InlineResponse20023 getWebhookLogs(Integer pageSize, Integer skip, String sort, String status, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, String requestUuid, OffsetDateTime createdBefore, OffsetDateTime createdAfter) throws ApiException { + ApiResponse resp = getWebhookLogsWithHttpInfo(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter); return resp.getData(); } @@ -10070,12 +10206,12 @@ public InlineResponse20022 getWebhookLogs(Integer pageSize, Integer skip, String * @param requestUuid Filter results by request UUID. (optional) * @param createdBefore Filter results where request and response times to return entries before parameter value, expected to be an RFC3339 timestamp string. (optional) * @param createdAfter Filter results where request and response times to return entries after parameter value, expected to be an RFC3339 timestamp string. (optional) - * @return ApiResponse<InlineResponse20022> + * @return ApiResponse<InlineResponse20023> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getWebhookLogsWithHttpInfo(Integer pageSize, Integer skip, String sort, String status, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, String requestUuid, OffsetDateTime createdBefore, OffsetDateTime createdAfter) throws ApiException { + public ApiResponse getWebhookLogsWithHttpInfo(Integer pageSize, Integer skip, String sort, String status, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, String requestUuid, OffsetDateTime createdBefore, OffsetDateTime createdAfter) throws ApiException { com.squareup.okhttp.Call call = getWebhookLogsValidateBeforeCall(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -10096,7 +10232,7 @@ public ApiResponse getWebhookLogsWithHttpInfo(Integer pageS * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getWebhookLogsAsync(Integer pageSize, Integer skip, String sort, String status, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, String requestUuid, OffsetDateTime createdBefore, OffsetDateTime createdAfter, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getWebhookLogsAsync(Integer pageSize, Integer skip, String sort, String status, BigDecimal webhookId, BigDecimal applicationId, BigDecimal campaignId, String requestUuid, OffsetDateTime createdBefore, OffsetDateTime createdAfter, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -10118,7 +10254,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getWebhookLogsValidateBeforeCall(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -10205,11 +10341,11 @@ private com.squareup.okhttp.Call getWebhooksValidateBeforeCall(String applicatio * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) - * @return InlineResponse20020 + * @return InlineResponse20021 * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public InlineResponse20020 getWebhooks(String applicationIds, String sort, Integer pageSize, Integer skip) throws ApiException { - ApiResponse resp = getWebhooksWithHttpInfo(applicationIds, sort, pageSize, skip); + public InlineResponse20021 getWebhooks(String applicationIds, String sort, Integer pageSize, Integer skip) throws ApiException { + ApiResponse resp = getWebhooksWithHttpInfo(applicationIds, sort, pageSize, skip); return resp.getData(); } @@ -10220,12 +10356,12 @@ public InlineResponse20020 getWebhooks(String applicationIds, String sort, Integ * @param sort The field by which results should be sorted. Sorting defaults to ascending order, prefix the field name with `-` to sort in descending order. (optional) * @param pageSize The number of items to include in this response. When omitted, the maximum value of 1000 will be used. (optional) * @param skip Skips the given number of items when paging through large result sets. (optional) - * @return ApiResponse<InlineResponse20020> + * @return ApiResponse<InlineResponse20021> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse getWebhooksWithHttpInfo(String applicationIds, String sort, Integer pageSize, Integer skip) throws ApiException { + public ApiResponse getWebhooksWithHttpInfo(String applicationIds, String sort, Integer pageSize, Integer skip) throws ApiException { com.squareup.okhttp.Call call = getWebhooksValidateBeforeCall(applicationIds, sort, pageSize, skip, null, null); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); return apiClient.execute(call, localVarReturnType); } @@ -10240,7 +10376,7 @@ public ApiResponse getWebhooksWithHttpInfo(String applicati * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call getWebhooksAsync(String applicationIds, String sort, Integer pageSize, Integer skip, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call getWebhooksAsync(String applicationIds, String sort, Integer pageSize, Integer skip, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -10262,7 +10398,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don } com.squareup.okhttp.Call call = getWebhooksValidateBeforeCall(applicationIds, sort, pageSize, skip, progressListener, progressRequestListener); - Type localVarReturnType = new TypeToken(){}.getType(); + Type localVarReturnType = new TypeToken(){}.getType(); apiClient.executeAsync(call, localVarReturnType, callback); return call; } @@ -11577,27 +11713,27 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don return call; } /** - * Build call for setAccountLimits - * @param accountId (required) - * @param accountLimits (required) + * Build call for updateAttribute + * @param attributeId (required) + * @param newAttribute (required) * @param progressListener Progress listener * @param progressRequestListener Progress request listener * @return Call to execute * @throws ApiException If fail to serialize the request body object */ - public com.squareup.okhttp.Call setAccountLimitsCall(Integer accountId, AccountLimits accountLimits, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - Object localVarPostBody = accountLimits; + public com.squareup.okhttp.Call updateAttributeCall(Integer attributeId, NewAttribute newAttribute, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + Object localVarPostBody = newAttribute; // create path and map variables - String localVarPath = "/v1/accounts/{accountId}/limits" - .replaceAll("\\{" + "accountId" + "\\}", apiClient.escapeString(accountId.toString())); + String localVarPath = "/v1/attributes/{attributeId}" + .replaceAll("\\{" + "attributeId" + "\\}", apiClient.escapeString(attributeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); Map localVarHeaderParams = new HashMap(); Map localVarFormParams = new HashMap(); final String[] localVarAccepts = { - + "application/json" }; final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -11627,58 +11763,61 @@ public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Ch } @SuppressWarnings("rawtypes") - private com.squareup.okhttp.Call setAccountLimitsValidateBeforeCall(Integer accountId, AccountLimits accountLimits, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { + private com.squareup.okhttp.Call updateAttributeValidateBeforeCall(Integer attributeId, NewAttribute newAttribute, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { - // verify the required parameter 'accountId' is set - if (accountId == null) { - throw new ApiException("Missing the required parameter 'accountId' when calling setAccountLimits(Async)"); + // verify the required parameter 'attributeId' is set + if (attributeId == null) { + throw new ApiException("Missing the required parameter 'attributeId' when calling updateAttribute(Async)"); } - // verify the required parameter 'accountLimits' is set - if (accountLimits == null) { - throw new ApiException("Missing the required parameter 'accountLimits' when calling setAccountLimits(Async)"); + // verify the required parameter 'newAttribute' is set + if (newAttribute == null) { + throw new ApiException("Missing the required parameter 'newAttribute' when calling updateAttribute(Async)"); } - com.squareup.okhttp.Call call = setAccountLimitsCall(accountId, accountLimits, progressListener, progressRequestListener); + com.squareup.okhttp.Call call = updateAttributeCall(attributeId, newAttribute, progressListener, progressRequestListener); return call; } /** - * Set account limits - * sets account limits - * @param accountId (required) - * @param accountLimits (required) + * Update a custom attribute + * Updates an existing custom attribute. Once created, the only property of a custom attribute that can be changed is the title (human readable description). This restriction is in place to prevent accidentally breaking live integrations. E.g. if you have a customer profile attribute with the name `region`, and your integration is sending `attributes.region` with customer profile updates, changing the name to `locale` would cause the integration requests to begin failing. If you **really** need to change the `type` or `name` property of a custom attribute, create a new attribute and update any relevant integrations and rules to use the new attribute. Then delete the old attribute when you are confident you have migrated any needed data from the old attribute to the new one. + * @param attributeId (required) + * @param newAttribute (required) + * @return Attribute * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public void setAccountLimits(Integer accountId, AccountLimits accountLimits) throws ApiException { - setAccountLimitsWithHttpInfo(accountId, accountLimits); + public Attribute updateAttribute(Integer attributeId, NewAttribute newAttribute) throws ApiException { + ApiResponse resp = updateAttributeWithHttpInfo(attributeId, newAttribute); + return resp.getData(); } /** - * Set account limits - * sets account limits - * @param accountId (required) - * @param accountLimits (required) - * @return ApiResponse<Void> + * Update a custom attribute + * Updates an existing custom attribute. Once created, the only property of a custom attribute that can be changed is the title (human readable description). This restriction is in place to prevent accidentally breaking live integrations. E.g. if you have a customer profile attribute with the name `region`, and your integration is sending `attributes.region` with customer profile updates, changing the name to `locale` would cause the integration requests to begin failing. If you **really** need to change the `type` or `name` property of a custom attribute, create a new attribute and update any relevant integrations and rules to use the new attribute. Then delete the old attribute when you are confident you have migrated any needed data from the old attribute to the new one. + * @param attributeId (required) + * @param newAttribute (required) + * @return ApiResponse<Attribute> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body */ - public ApiResponse setAccountLimitsWithHttpInfo(Integer accountId, AccountLimits accountLimits) throws ApiException { - com.squareup.okhttp.Call call = setAccountLimitsValidateBeforeCall(accountId, accountLimits, null, null); - return apiClient.execute(call); + public ApiResponse updateAttributeWithHttpInfo(Integer attributeId, NewAttribute newAttribute) throws ApiException { + com.squareup.okhttp.Call call = updateAttributeValidateBeforeCall(attributeId, newAttribute, null, null); + Type localVarReturnType = new TypeToken(){}.getType(); + return apiClient.execute(call, localVarReturnType); } /** - * Set account limits (asynchronously) - * sets account limits - * @param accountId (required) - * @param accountLimits (required) + * Update a custom attribute (asynchronously) + * Updates an existing custom attribute. Once created, the only property of a custom attribute that can be changed is the title (human readable description). This restriction is in place to prevent accidentally breaking live integrations. E.g. if you have a customer profile attribute with the name `region`, and your integration is sending `attributes.region` with customer profile updates, changing the name to `locale` would cause the integration requests to begin failing. If you **really** need to change the `type` or `name` property of a custom attribute, create a new attribute and update any relevant integrations and rules to use the new attribute. Then delete the old attribute when you are confident you have migrated any needed data from the old attribute to the new one. + * @param attributeId (required) + * @param newAttribute (required) * @param callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body object */ - public com.squareup.okhttp.Call setAccountLimitsAsync(Integer accountId, AccountLimits accountLimits, final ApiCallback callback) throws ApiException { + public com.squareup.okhttp.Call updateAttributeAsync(Integer attributeId, NewAttribute newAttribute, final ApiCallback callback) throws ApiException { ProgressResponseBody.ProgressListener progressListener = null; ProgressRequestBody.ProgressRequestListener progressRequestListener = null; @@ -11699,8 +11838,9 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don }; } - com.squareup.okhttp.Call call = setAccountLimitsValidateBeforeCall(accountId, accountLimits, progressListener, progressRequestListener); - apiClient.executeAsync(call, callback); + com.squareup.okhttp.Call call = updateAttributeValidateBeforeCall(attributeId, newAttribute, progressListener, progressRequestListener); + Type localVarReturnType = new TypeToken(){}.getType(); + apiClient.executeAsync(call, localVarReturnType, callback); return call; } /** diff --git a/src/main/java/one/talon/model/AccountAnalytics.java b/src/main/java/one/talon/model/AccountAnalytics.java index 659a5ddf..e68354ef 100644 --- a/src/main/java/one/talon/model/AccountAnalytics.java +++ b/src/main/java/one/talon/model/AccountAnalytics.java @@ -85,6 +85,10 @@ public class AccountAnalytics { @SerializedName(SERIALIZED_NAME_LOYALTY_PROGRAMS) private Integer loyaltyPrograms; + public static final String SERIALIZED_NAME_ACTIVE_RULES = "activeRules"; + @SerializedName(SERIALIZED_NAME_ACTIVE_RULES) + private Integer activeRules; + public AccountAnalytics applications(Integer applications) { this.applications = applications; return this; @@ -337,6 +341,24 @@ public void setLoyaltyPrograms(Integer loyaltyPrograms) { this.loyaltyPrograms = loyaltyPrograms; } + public AccountAnalytics activeRules(Integer activeRules) { + this.activeRules = activeRules; + return this; + } + + /** + * Total Number of active rules in the account + * @return activeRules + **/ + @ApiModelProperty(required = true, value = "Total Number of active rules in the account") + public Integer getActiveRules() { + return activeRules; + } + + public void setActiveRules(Integer activeRules) { + this.activeRules = activeRules; + } + @Override public boolean equals(java.lang.Object o) { @@ -360,12 +382,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.users, accountAnalytics.users) && Objects.equals(this.roles, accountAnalytics.roles) && Objects.equals(this.webhooks, accountAnalytics.webhooks) && - Objects.equals(this.loyaltyPrograms, accountAnalytics.loyaltyPrograms); + Objects.equals(this.loyaltyPrograms, accountAnalytics.loyaltyPrograms) && + Objects.equals(this.activeRules, accountAnalytics.activeRules); } @Override public int hashCode() { - return Objects.hash(applications, activeCampaigns, campaigns, coupons, activeCoupons, expiredCoupons, customAttributes, referralCodes, activeReferralCodes, expiredReferralCodes, users, roles, webhooks, loyaltyPrograms); + return Objects.hash(applications, activeCampaigns, campaigns, coupons, activeCoupons, expiredCoupons, customAttributes, referralCodes, activeReferralCodes, expiredReferralCodes, users, roles, webhooks, loyaltyPrograms, activeRules); } @@ -388,6 +411,7 @@ public String toString() { sb.append(" roles: ").append(toIndentedString(roles)).append("\n"); sb.append(" webhooks: ").append(toIndentedString(webhooks)).append("\n"); sb.append(" loyaltyPrograms: ").append(toIndentedString(loyaltyPrograms)).append("\n"); + sb.append(" activeRules: ").append(toIndentedString(activeRules)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/AccountLimits.java b/src/main/java/one/talon/model/AccountLimits.java index 0d4aacb6..ec6dbc08 100644 --- a/src/main/java/one/talon/model/AccountLimits.java +++ b/src/main/java/one/talon/model/AccountLimits.java @@ -71,6 +71,10 @@ public class AccountLimits { @SerializedName(SERIALIZED_NAME_API_VOLUME) private Integer apiVolume; + public static final String SERIALIZED_NAME_ACTIVE_RULES = "activeRules"; + @SerializedName(SERIALIZED_NAME_ACTIVE_RULES) + private Integer activeRules; + public static final String SERIALIZED_NAME_PROMOTION_TYPES = "promotionTypes"; @SerializedName(SERIALIZED_NAME_PROMOTION_TYPES) private List promotionTypes = new ArrayList(); @@ -255,6 +259,24 @@ public void setApiVolume(Integer apiVolume) { this.apiVolume = apiVolume; } + public AccountLimits activeRules(Integer activeRules) { + this.activeRules = activeRules; + return this; + } + + /** + * Total allowed active rulesets + * @return activeRules + **/ + @ApiModelProperty(value = "Total allowed active rulesets") + public Integer getActiveRules() { + return activeRules; + } + + public void setActiveRules(Integer activeRules) { + this.activeRules = activeRules; + } + public AccountLimits promotionTypes(List promotionTypes) { this.promotionTypes = promotionTypes; return this; @@ -298,12 +320,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.webhooks, accountLimits.webhooks) && Objects.equals(this.users, accountLimits.users) && Objects.equals(this.apiVolume, accountLimits.apiVolume) && + Objects.equals(this.activeRules, accountLimits.activeRules) && Objects.equals(this.promotionTypes, accountLimits.promotionTypes); } @Override public int hashCode() { - return Objects.hash(liveApplications, sandboxApplications, activeCampaigns, coupons, referralCodes, liveLoyaltyPrograms, sandboxLoyaltyPrograms, webhooks, users, apiVolume, promotionTypes); + return Objects.hash(liveApplications, sandboxApplications, activeCampaigns, coupons, referralCodes, liveLoyaltyPrograms, sandboxLoyaltyPrograms, webhooks, users, apiVolume, activeRules, promotionTypes); } @@ -322,6 +345,7 @@ public String toString() { sb.append(" webhooks: ").append(toIndentedString(webhooks)).append("\n"); sb.append(" users: ").append(toIndentedString(users)).append("\n"); sb.append(" apiVolume: ").append(toIndentedString(apiVolume)).append("\n"); + sb.append(" activeRules: ").append(toIndentedString(activeRules)).append("\n"); sb.append(" promotionTypes: ").append(toIndentedString(promotionTypes)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/Application.java b/src/main/java/one/talon/model/Application.java index 8a0da153..c1405bbb 100644 --- a/src/main/java/one/talon/model/Application.java +++ b/src/main/java/one/talon/model/Application.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.AttributesSettings; import one.talon.model.LimitConfig; import one.talon.model.LoyaltyProgram; import org.threeten.bp.OffsetDateTime; @@ -128,6 +129,10 @@ public CaseSensitivityEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_LIMITS) private List limits = null; + public static final String SERIALIZED_NAME_ATTRIBUTES_SETTINGS = "attributesSettings"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES_SETTINGS) + private AttributesSettings attributesSettings = null; + public static final String SERIALIZED_NAME_KEY = "key"; @SerializedName(SERIALIZED_NAME_KEY) private String key; @@ -342,6 +347,24 @@ public void setLimits(List limits) { this.limits = limits; } + public Application attributesSettings(AttributesSettings attributesSettings) { + this.attributesSettings = attributesSettings; + return this; + } + + /** + * Get attributesSettings + * @return attributesSettings + **/ + @ApiModelProperty(value = "") + public AttributesSettings getAttributesSettings() { + return attributesSettings; + } + + public void setAttributesSettings(AttributesSettings attributesSettings) { + this.attributesSettings = attributesSettings; + } + public Application key(String key) { this.key = key; return this; @@ -404,13 +427,14 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.caseSensitivity, application.caseSensitivity) && Objects.equals(this.attributes, application.attributes) && Objects.equals(this.limits, application.limits) && + Objects.equals(this.attributesSettings, application.attributesSettings) && Objects.equals(this.key, application.key) && Objects.equals(this.loyaltyPrograms, application.loyaltyPrograms); } @Override public int hashCode() { - return Objects.hash(id, created, modified, accountId, name, description, timezone, currency, caseSensitivity, attributes, limits, key, loyaltyPrograms); + return Objects.hash(id, created, modified, accountId, name, description, timezone, currency, caseSensitivity, attributes, limits, attributesSettings, key, loyaltyPrograms); } @@ -430,6 +454,7 @@ public String toString() { sb.append(" caseSensitivity: ").append(toIndentedString(caseSensitivity)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); sb.append(" limits: ").append(toIndentedString(limits)).append("\n"); + sb.append(" attributesSettings: ").append(toIndentedString(attributesSettings)).append("\n"); sb.append(" key: ").append(toIndentedString(key)).append("\n"); sb.append(" loyaltyPrograms: ").append(toIndentedString(loyaltyPrograms)).append("\n"); sb.append("}"); diff --git a/src/main/java/one/talon/model/AttributesMandatory.java b/src/main/java/one/talon/model/AttributesMandatory.java new file mode 100644 index 00000000..2746b08a --- /dev/null +++ b/src/main/java/one/talon/model/AttributesMandatory.java @@ -0,0 +1,138 @@ +/* + * Talon.One API + * The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns. ### Where is the API? The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id` [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +/** + * Arbitrary settings associated with attributes. + */ +@ApiModel(description = "Arbitrary settings associated with attributes.") + +public class AttributesMandatory { + public static final String SERIALIZED_NAME_CAMPAIGNS = "campaigns"; + @SerializedName(SERIALIZED_NAME_CAMPAIGNS) + private List campaigns = null; + + public static final String SERIALIZED_NAME_COUPONS = "coupons"; + @SerializedName(SERIALIZED_NAME_COUPONS) + private List coupons = null; + + public AttributesMandatory campaigns(List campaigns) { + this.campaigns = campaigns; + return this; + } + + public AttributesMandatory addCampaignsItem(String campaignsItem) { + if (this.campaigns == null) { + this.campaigns = new ArrayList(); + } + this.campaigns.add(campaignsItem); + return this; + } + + /** + * List of mandatory attributes for campaigns. + * @return campaigns + **/ + @ApiModelProperty(value = "List of mandatory attributes for campaigns.") + public List getCampaigns() { + return campaigns; + } + + public void setCampaigns(List campaigns) { + this.campaigns = campaigns; + } + + public AttributesMandatory coupons(List coupons) { + this.coupons = coupons; + return this; + } + + public AttributesMandatory addCouponsItem(String couponsItem) { + if (this.coupons == null) { + this.coupons = new ArrayList(); + } + this.coupons.add(couponsItem); + return this; + } + + /** + * List of mandatory attributes for campaigns. + * @return coupons + **/ + @ApiModelProperty(value = "List of mandatory attributes for campaigns.") + public List getCoupons() { + return coupons; + } + + public void setCoupons(List coupons) { + this.coupons = coupons; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AttributesMandatory attributesMandatory = (AttributesMandatory) o; + return Objects.equals(this.campaigns, attributesMandatory.campaigns) && + Objects.equals(this.coupons, attributesMandatory.coupons); + } + + @Override + public int hashCode() { + return Objects.hash(campaigns, coupons); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AttributesMandatory {\n"); + + sb.append(" campaigns: ").append(toIndentedString(campaigns)).append("\n"); + sb.append(" coupons: ").append(toIndentedString(coupons)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/AttributesSettings.java b/src/main/java/one/talon/model/AttributesSettings.java new file mode 100644 index 00000000..32c883cb --- /dev/null +++ b/src/main/java/one/talon/model/AttributesSettings.java @@ -0,0 +1,97 @@ +/* + * Talon.One API + * The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns. ### Where is the API? The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id` [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import one.talon.model.AttributesMandatory; + +/** + * Arbitrary settings associated with attributes. + */ +@ApiModel(description = "Arbitrary settings associated with attributes.") + +public class AttributesSettings { + public static final String SERIALIZED_NAME_MANDATORY = "mandatory"; + @SerializedName(SERIALIZED_NAME_MANDATORY) + private AttributesMandatory mandatory = null; + + public AttributesSettings mandatory(AttributesMandatory mandatory) { + this.mandatory = mandatory; + return this; + } + + /** + * Get mandatory + * @return mandatory + **/ + @ApiModelProperty(value = "") + public AttributesMandatory getMandatory() { + return mandatory; + } + + public void setMandatory(AttributesMandatory mandatory) { + this.mandatory = mandatory; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AttributesSettings attributesSettings = (AttributesSettings) o; + return Objects.equals(this.mandatory, attributesSettings.mandatory); + } + + @Override + public int hashCode() { + return Objects.hash(mandatory); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AttributesSettings {\n"); + + sb.append(" mandatory: ").append(toIndentedString(mandatory)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/BaseSamlConnection.java b/src/main/java/one/talon/model/BaseSamlConnection.java new file mode 100644 index 00000000..fe26bddc --- /dev/null +++ b/src/main/java/one/talon/model/BaseSamlConnection.java @@ -0,0 +1,263 @@ +/* + * Talon.One API + * The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns. ### Where is the API? The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id` [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; + +/** + * BaseSamlConnection + */ + +public class BaseSamlConnection { + public static final String SERIALIZED_NAME_ACCOUNT_ID = "accountId"; + @SerializedName(SERIALIZED_NAME_ACCOUNT_ID) + private Integer accountId; + + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_ENABLED = "enabled"; + @SerializedName(SERIALIZED_NAME_ENABLED) + private Boolean enabled; + + public static final String SERIALIZED_NAME_ISSUER = "issuer"; + @SerializedName(SERIALIZED_NAME_ISSUER) + private String issuer; + + public static final String SERIALIZED_NAME_SIGN_ON_U_R_L = "signOnURL"; + @SerializedName(SERIALIZED_NAME_SIGN_ON_U_R_L) + private String signOnURL; + + public static final String SERIALIZED_NAME_SIGN_OUT_U_R_L = "signOutURL"; + @SerializedName(SERIALIZED_NAME_SIGN_OUT_U_R_L) + private String signOutURL; + + public static final String SERIALIZED_NAME_METADATA_U_R_L = "metadataURL"; + @SerializedName(SERIALIZED_NAME_METADATA_U_R_L) + private String metadataURL; + + public static final String SERIALIZED_NAME_AUDIENCE_U_R_I = "audienceURI"; + @SerializedName(SERIALIZED_NAME_AUDIENCE_U_R_I) + private String audienceURI; + + public BaseSamlConnection accountId(Integer accountId) { + this.accountId = accountId; + return this; + } + + /** + * The ID of the account that owns this entity. + * @return accountId + **/ + @ApiModelProperty(required = true, value = "The ID of the account that owns this entity.") + public Integer getAccountId() { + return accountId; + } + + public void setAccountId(Integer accountId) { + this.accountId = accountId; + } + + public BaseSamlConnection name(String name) { + this.name = name; + return this; + } + + /** + * ID of the SAML service. + * @return name + **/ + @ApiModelProperty(required = true, value = "ID of the SAML service.") + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public BaseSamlConnection enabled(Boolean enabled) { + this.enabled = enabled; + return this; + } + + /** + * Determines if this SAML connection active. + * @return enabled + **/ + @ApiModelProperty(required = true, value = "Determines if this SAML connection active.") + public Boolean getEnabled() { + return enabled; + } + + public void setEnabled(Boolean enabled) { + this.enabled = enabled; + } + + public BaseSamlConnection issuer(String issuer) { + this.issuer = issuer; + return this; + } + + /** + * Identity Provider Entity ID. + * @return issuer + **/ + @ApiModelProperty(required = true, value = "Identity Provider Entity ID.") + public String getIssuer() { + return issuer; + } + + public void setIssuer(String issuer) { + this.issuer = issuer; + } + + public BaseSamlConnection signOnURL(String signOnURL) { + this.signOnURL = signOnURL; + return this; + } + + /** + * Single Sign-On URL. + * @return signOnURL + **/ + @ApiModelProperty(required = true, value = "Single Sign-On URL.") + public String getSignOnURL() { + return signOnURL; + } + + public void setSignOnURL(String signOnURL) { + this.signOnURL = signOnURL; + } + + public BaseSamlConnection signOutURL(String signOutURL) { + this.signOutURL = signOutURL; + return this; + } + + /** + * Single Sign-Out URL. + * @return signOutURL + **/ + @ApiModelProperty(value = "Single Sign-Out URL.") + public String getSignOutURL() { + return signOutURL; + } + + public void setSignOutURL(String signOutURL) { + this.signOutURL = signOutURL; + } + + public BaseSamlConnection metadataURL(String metadataURL) { + this.metadataURL = metadataURL; + return this; + } + + /** + * Metadata URL. + * @return metadataURL + **/ + @ApiModelProperty(value = "Metadata URL.") + public String getMetadataURL() { + return metadataURL; + } + + public void setMetadataURL(String metadataURL) { + this.metadataURL = metadataURL; + } + + public BaseSamlConnection audienceURI(String audienceURI) { + this.audienceURI = audienceURI; + return this; + } + + /** + * The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. + * @return audienceURI + **/ + @ApiModelProperty(value = "The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. ") + public String getAudienceURI() { + return audienceURI; + } + + public void setAudienceURI(String audienceURI) { + this.audienceURI = audienceURI; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + BaseSamlConnection baseSamlConnection = (BaseSamlConnection) o; + return Objects.equals(this.accountId, baseSamlConnection.accountId) && + Objects.equals(this.name, baseSamlConnection.name) && + Objects.equals(this.enabled, baseSamlConnection.enabled) && + Objects.equals(this.issuer, baseSamlConnection.issuer) && + Objects.equals(this.signOnURL, baseSamlConnection.signOnURL) && + Objects.equals(this.signOutURL, baseSamlConnection.signOutURL) && + Objects.equals(this.metadataURL, baseSamlConnection.metadataURL) && + Objects.equals(this.audienceURI, baseSamlConnection.audienceURI); + } + + @Override + public int hashCode() { + return Objects.hash(accountId, name, enabled, issuer, signOnURL, signOutURL, metadataURL, audienceURI); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class BaseSamlConnection {\n"); + + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); + sb.append(" issuer: ").append(toIndentedString(issuer)).append("\n"); + sb.append(" signOnURL: ").append(toIndentedString(signOnURL)).append("\n"); + sb.append(" signOutURL: ").append(toIndentedString(signOutURL)).append("\n"); + sb.append(" metadataURL: ").append(toIndentedString(metadataURL)).append("\n"); + sb.append(" audienceURI: ").append(toIndentedString(audienceURI)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/CampaignAnalytics.java b/src/main/java/one/talon/model/CampaignAnalytics.java index 4d24a7c6..00eb3d51 100644 --- a/src/main/java/one/talon/model/CampaignAnalytics.java +++ b/src/main/java/one/talon/model/CampaignAnalytics.java @@ -44,6 +44,14 @@ public class CampaignAnalytics { @SerializedName(SERIALIZED_NAME_TOTAL_CAMPAIGN_REVENUE) private BigDecimal totalCampaignRevenue; + public static final String SERIALIZED_NAME_CAMPAIGN_REFUND = "campaignRefund"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_REFUND) + private BigDecimal campaignRefund; + + public static final String SERIALIZED_NAME_TOTAL_CAMPAIGN_REFUND = "totalCampaignRefund"; + @SerializedName(SERIALIZED_NAME_TOTAL_CAMPAIGN_REFUND) + private BigDecimal totalCampaignRefund; + public static final String SERIALIZED_NAME_CAMPAIGN_DISCOUNT_COSTS = "campaignDiscountCosts"; @SerializedName(SERIALIZED_NAME_CAMPAIGN_DISCOUNT_COSTS) private BigDecimal campaignDiscountCosts; @@ -52,6 +60,14 @@ public class CampaignAnalytics { @SerializedName(SERIALIZED_NAME_TOTAL_CAMPAIGN_DISCOUNT_COSTS) private BigDecimal totalCampaignDiscountCosts; + public static final String SERIALIZED_NAME_CAMPAIGN_REFUNDED_DISCOUNTS = "campaignRefundedDiscounts"; + @SerializedName(SERIALIZED_NAME_CAMPAIGN_REFUNDED_DISCOUNTS) + private BigDecimal campaignRefundedDiscounts; + + public static final String SERIALIZED_NAME_TOTAL_CAMPAIGN_REFUNDED_DISCOUNTS = "totalCampaignRefundedDiscounts"; + @SerializedName(SERIALIZED_NAME_TOTAL_CAMPAIGN_REFUNDED_DISCOUNTS) + private BigDecimal totalCampaignRefundedDiscounts; + public static final String SERIALIZED_NAME_CAMPAIGN_FREE_ITEMS = "campaignFreeItems"; @SerializedName(SERIALIZED_NAME_CAMPAIGN_FREE_ITEMS) private Integer campaignFreeItems; @@ -68,6 +84,14 @@ public class CampaignAnalytics { @SerializedName(SERIALIZED_NAME_TOTAL_COUPON_REDEMPTIONS) private Integer totalCouponRedemptions; + public static final String SERIALIZED_NAME_COUPON_ROLLEDBACK_REDEMPTIONS = "couponRolledbackRedemptions"; + @SerializedName(SERIALIZED_NAME_COUPON_ROLLEDBACK_REDEMPTIONS) + private Integer couponRolledbackRedemptions; + + public static final String SERIALIZED_NAME_TOTAL_COUPON_ROLLEDBACK_REDEMPTIONS = "totalCouponRolledbackRedemptions"; + @SerializedName(SERIALIZED_NAME_TOTAL_COUPON_ROLLEDBACK_REDEMPTIONS) + private Integer totalCouponRolledbackRedemptions; + public static final String SERIALIZED_NAME_REFERRAL_REDEMPTIONS = "referralRedemptions"; @SerializedName(SERIALIZED_NAME_REFERRAL_REDEMPTIONS) private Integer referralRedemptions; @@ -116,10 +140,10 @@ public CampaignAnalytics campaignRevenue(BigDecimal campaignRevenue) { } /** - * Amount of revenue in this campaign. + * Amount of revenue in this campaign (for coupon or discount sessions). * @return campaignRevenue **/ - @ApiModelProperty(required = true, value = "Amount of revenue in this campaign.") + @ApiModelProperty(required = true, value = "Amount of revenue in this campaign (for coupon or discount sessions).") public BigDecimal getCampaignRevenue() { return campaignRevenue; } @@ -134,10 +158,10 @@ public CampaignAnalytics totalCampaignRevenue(BigDecimal totalCampaignRevenue) { } /** - * Amount of revenue in this campaign since it began. + * Amount of revenue in this campaign since it began (for coupon or discount sessions). * @return totalCampaignRevenue **/ - @ApiModelProperty(required = true, value = "Amount of revenue in this campaign since it began.") + @ApiModelProperty(required = true, value = "Amount of revenue in this campaign since it began (for coupon or discount sessions).") public BigDecimal getTotalCampaignRevenue() { return totalCampaignRevenue; } @@ -146,6 +170,42 @@ public void setTotalCampaignRevenue(BigDecimal totalCampaignRevenue) { this.totalCampaignRevenue = totalCampaignRevenue; } + public CampaignAnalytics campaignRefund(BigDecimal campaignRefund) { + this.campaignRefund = campaignRefund; + return this; + } + + /** + * Amount of refunds in this campaign (for coupon or discount sessions). + * @return campaignRefund + **/ + @ApiModelProperty(required = true, value = "Amount of refunds in this campaign (for coupon or discount sessions).") + public BigDecimal getCampaignRefund() { + return campaignRefund; + } + + public void setCampaignRefund(BigDecimal campaignRefund) { + this.campaignRefund = campaignRefund; + } + + public CampaignAnalytics totalCampaignRefund(BigDecimal totalCampaignRefund) { + this.totalCampaignRefund = totalCampaignRefund; + return this; + } + + /** + * Amount of refunds in this campaign since it began (for coupon or discount sessions). + * @return totalCampaignRefund + **/ + @ApiModelProperty(required = true, value = "Amount of refunds in this campaign since it began (for coupon or discount sessions).") + public BigDecimal getTotalCampaignRefund() { + return totalCampaignRefund; + } + + public void setTotalCampaignRefund(BigDecimal totalCampaignRefund) { + this.totalCampaignRefund = totalCampaignRefund; + } + public CampaignAnalytics campaignDiscountCosts(BigDecimal campaignDiscountCosts) { this.campaignDiscountCosts = campaignDiscountCosts; return this; @@ -182,6 +242,42 @@ public void setTotalCampaignDiscountCosts(BigDecimal totalCampaignDiscountCosts) this.totalCampaignDiscountCosts = totalCampaignDiscountCosts; } + public CampaignAnalytics campaignRefundedDiscounts(BigDecimal campaignRefundedDiscounts) { + this.campaignRefundedDiscounts = campaignRefundedDiscounts; + return this; + } + + /** + * Amount of discounts rolledback due to refund in the campaign. + * @return campaignRefundedDiscounts + **/ + @ApiModelProperty(required = true, value = "Amount of discounts rolledback due to refund in the campaign.") + public BigDecimal getCampaignRefundedDiscounts() { + return campaignRefundedDiscounts; + } + + public void setCampaignRefundedDiscounts(BigDecimal campaignRefundedDiscounts) { + this.campaignRefundedDiscounts = campaignRefundedDiscounts; + } + + public CampaignAnalytics totalCampaignRefundedDiscounts(BigDecimal totalCampaignRefundedDiscounts) { + this.totalCampaignRefundedDiscounts = totalCampaignRefundedDiscounts; + return this; + } + + /** + * Amount of discounts rolledback due to refund in the campaign since it began. + * @return totalCampaignRefundedDiscounts + **/ + @ApiModelProperty(required = true, value = "Amount of discounts rolledback due to refund in the campaign since it began.") + public BigDecimal getTotalCampaignRefundedDiscounts() { + return totalCampaignRefundedDiscounts; + } + + public void setTotalCampaignRefundedDiscounts(BigDecimal totalCampaignRefundedDiscounts) { + this.totalCampaignRefundedDiscounts = totalCampaignRefundedDiscounts; + } + public CampaignAnalytics campaignFreeItems(Integer campaignFreeItems) { this.campaignFreeItems = campaignFreeItems; return this; @@ -224,10 +320,10 @@ public CampaignAnalytics couponRedemptions(Integer couponRedemptions) { } /** - * Number of coupon redemptions in the campaign (only accepted referrals on sessions that were closed are considered). + * Number of coupon redemptions in the campaign. * @return couponRedemptions **/ - @ApiModelProperty(required = true, value = "Number of coupon redemptions in the campaign (only accepted referrals on sessions that were closed are considered).") + @ApiModelProperty(required = true, value = "Number of coupon redemptions in the campaign.") public Integer getCouponRedemptions() { return couponRedemptions; } @@ -254,6 +350,42 @@ public void setTotalCouponRedemptions(Integer totalCouponRedemptions) { this.totalCouponRedemptions = totalCouponRedemptions; } + public CampaignAnalytics couponRolledbackRedemptions(Integer couponRolledbackRedemptions) { + this.couponRolledbackRedemptions = couponRolledbackRedemptions; + return this; + } + + /** + * Number of coupon redemptions that have been rolled back (due to canceling closed session) in the campaign. + * @return couponRolledbackRedemptions + **/ + @ApiModelProperty(required = true, value = "Number of coupon redemptions that have been rolled back (due to canceling closed session) in the campaign.") + public Integer getCouponRolledbackRedemptions() { + return couponRolledbackRedemptions; + } + + public void setCouponRolledbackRedemptions(Integer couponRolledbackRedemptions) { + this.couponRolledbackRedemptions = couponRolledbackRedemptions; + } + + public CampaignAnalytics totalCouponRolledbackRedemptions(Integer totalCouponRolledbackRedemptions) { + this.totalCouponRolledbackRedemptions = totalCouponRolledbackRedemptions; + return this; + } + + /** + * Number of coupon redemptions that have been rolled back (due to canceling closed session) in the campaign since it began. + * @return totalCouponRolledbackRedemptions + **/ + @ApiModelProperty(required = true, value = "Number of coupon redemptions that have been rolled back (due to canceling closed session) in the campaign since it began.") + public Integer getTotalCouponRolledbackRedemptions() { + return totalCouponRolledbackRedemptions; + } + + public void setTotalCouponRolledbackRedemptions(Integer totalCouponRolledbackRedemptions) { + this.totalCouponRolledbackRedemptions = totalCouponRolledbackRedemptions; + } + public CampaignAnalytics referralRedemptions(Integer referralRedemptions) { this.referralRedemptions = referralRedemptions; return this; @@ -375,12 +507,18 @@ public boolean equals(java.lang.Object o) { return Objects.equals(this.date, campaignAnalytics.date) && Objects.equals(this.campaignRevenue, campaignAnalytics.campaignRevenue) && Objects.equals(this.totalCampaignRevenue, campaignAnalytics.totalCampaignRevenue) && + Objects.equals(this.campaignRefund, campaignAnalytics.campaignRefund) && + Objects.equals(this.totalCampaignRefund, campaignAnalytics.totalCampaignRefund) && Objects.equals(this.campaignDiscountCosts, campaignAnalytics.campaignDiscountCosts) && Objects.equals(this.totalCampaignDiscountCosts, campaignAnalytics.totalCampaignDiscountCosts) && + Objects.equals(this.campaignRefundedDiscounts, campaignAnalytics.campaignRefundedDiscounts) && + Objects.equals(this.totalCampaignRefundedDiscounts, campaignAnalytics.totalCampaignRefundedDiscounts) && Objects.equals(this.campaignFreeItems, campaignAnalytics.campaignFreeItems) && Objects.equals(this.totalCampaignFreeItems, campaignAnalytics.totalCampaignFreeItems) && Objects.equals(this.couponRedemptions, campaignAnalytics.couponRedemptions) && Objects.equals(this.totalCouponRedemptions, campaignAnalytics.totalCouponRedemptions) && + Objects.equals(this.couponRolledbackRedemptions, campaignAnalytics.couponRolledbackRedemptions) && + Objects.equals(this.totalCouponRolledbackRedemptions, campaignAnalytics.totalCouponRolledbackRedemptions) && Objects.equals(this.referralRedemptions, campaignAnalytics.referralRedemptions) && Objects.equals(this.totalReferralRedemptions, campaignAnalytics.totalReferralRedemptions) && Objects.equals(this.couponsCreated, campaignAnalytics.couponsCreated) && @@ -391,7 +529,7 @@ public boolean equals(java.lang.Object o) { @Override public int hashCode() { - return Objects.hash(date, campaignRevenue, totalCampaignRevenue, campaignDiscountCosts, totalCampaignDiscountCosts, campaignFreeItems, totalCampaignFreeItems, couponRedemptions, totalCouponRedemptions, referralRedemptions, totalReferralRedemptions, couponsCreated, totalCouponsCreated, referralsCreated, totalReferralsCreated); + return Objects.hash(date, campaignRevenue, totalCampaignRevenue, campaignRefund, totalCampaignRefund, campaignDiscountCosts, totalCampaignDiscountCosts, campaignRefundedDiscounts, totalCampaignRefundedDiscounts, campaignFreeItems, totalCampaignFreeItems, couponRedemptions, totalCouponRedemptions, couponRolledbackRedemptions, totalCouponRolledbackRedemptions, referralRedemptions, totalReferralRedemptions, couponsCreated, totalCouponsCreated, referralsCreated, totalReferralsCreated); } @@ -403,12 +541,18 @@ public String toString() { sb.append(" date: ").append(toIndentedString(date)).append("\n"); sb.append(" campaignRevenue: ").append(toIndentedString(campaignRevenue)).append("\n"); sb.append(" totalCampaignRevenue: ").append(toIndentedString(totalCampaignRevenue)).append("\n"); + sb.append(" campaignRefund: ").append(toIndentedString(campaignRefund)).append("\n"); + sb.append(" totalCampaignRefund: ").append(toIndentedString(totalCampaignRefund)).append("\n"); sb.append(" campaignDiscountCosts: ").append(toIndentedString(campaignDiscountCosts)).append("\n"); sb.append(" totalCampaignDiscountCosts: ").append(toIndentedString(totalCampaignDiscountCosts)).append("\n"); + sb.append(" campaignRefundedDiscounts: ").append(toIndentedString(campaignRefundedDiscounts)).append("\n"); + sb.append(" totalCampaignRefundedDiscounts: ").append(toIndentedString(totalCampaignRefundedDiscounts)).append("\n"); sb.append(" campaignFreeItems: ").append(toIndentedString(campaignFreeItems)).append("\n"); sb.append(" totalCampaignFreeItems: ").append(toIndentedString(totalCampaignFreeItems)).append("\n"); sb.append(" couponRedemptions: ").append(toIndentedString(couponRedemptions)).append("\n"); sb.append(" totalCouponRedemptions: ").append(toIndentedString(totalCouponRedemptions)).append("\n"); + sb.append(" couponRolledbackRedemptions: ").append(toIndentedString(couponRolledbackRedemptions)).append("\n"); + sb.append(" totalCouponRolledbackRedemptions: ").append(toIndentedString(totalCouponRolledbackRedemptions)).append("\n"); sb.append(" referralRedemptions: ").append(toIndentedString(referralRedemptions)).append("\n"); sb.append(" totalReferralRedemptions: ").append(toIndentedString(totalReferralRedemptions)).append("\n"); sb.append(" couponsCreated: ").append(toIndentedString(couponsCreated)).append("\n"); diff --git a/src/main/java/one/talon/model/CampaignCopy.java b/src/main/java/one/talon/model/CampaignCopy.java index 5f62be34..b8521b8e 100644 --- a/src/main/java/one/talon/model/CampaignCopy.java +++ b/src/main/java/one/talon/model/CampaignCopy.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import org.threeten.bp.OffsetDateTime; /** * CampaignCopy @@ -39,6 +40,22 @@ public class CampaignCopy { @SerializedName(SERIALIZED_NAME_APPLICATION_IDS) private List applicationIds = new ArrayList(); + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + private String description; + + public static final String SERIALIZED_NAME_START_TIME = "startTime"; + @SerializedName(SERIALIZED_NAME_START_TIME) + private OffsetDateTime startTime; + + public static final String SERIALIZED_NAME_END_TIME = "endTime"; + @SerializedName(SERIALIZED_NAME_END_TIME) + private OffsetDateTime endTime; + + public static final String SERIALIZED_NAME_TAGS = "tags"; + @SerializedName(SERIALIZED_NAME_TAGS) + private List tags = null; + public CampaignCopy name(String name) { this.name = name; return this; @@ -80,6 +97,86 @@ public void setApplicationIds(List applicationIds) { this.applicationIds = applicationIds; } + public CampaignCopy description(String description) { + this.description = description; + return this; + } + + /** + * A detailed description of the campaign. + * @return description + **/ + @ApiModelProperty(value = "A detailed description of the campaign.") + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public CampaignCopy startTime(OffsetDateTime startTime) { + this.startTime = startTime; + return this; + } + + /** + * Datetime when the campaign will become active. + * @return startTime + **/ + @ApiModelProperty(value = "Datetime when the campaign will become active.") + public OffsetDateTime getStartTime() { + return startTime; + } + + public void setStartTime(OffsetDateTime startTime) { + this.startTime = startTime; + } + + public CampaignCopy endTime(OffsetDateTime endTime) { + this.endTime = endTime; + return this; + } + + /** + * Datetime when the campaign will become in-active. + * @return endTime + **/ + @ApiModelProperty(value = "Datetime when the campaign will become in-active.") + public OffsetDateTime getEndTime() { + return endTime; + } + + public void setEndTime(OffsetDateTime endTime) { + this.endTime = endTime; + } + + public CampaignCopy tags(List tags) { + this.tags = tags; + return this; + } + + public CampaignCopy addTagsItem(String tagsItem) { + if (this.tags == null) { + this.tags = new ArrayList(); + } + this.tags.add(tagsItem); + return this; + } + + /** + * A list of tags for the campaign. + * @return tags + **/ + @ApiModelProperty(value = "A list of tags for the campaign.") + public List getTags() { + return tags; + } + + public void setTags(List tags) { + this.tags = tags; + } + @Override public boolean equals(java.lang.Object o) { @@ -91,12 +188,16 @@ public boolean equals(java.lang.Object o) { } CampaignCopy campaignCopy = (CampaignCopy) o; return Objects.equals(this.name, campaignCopy.name) && - Objects.equals(this.applicationIds, campaignCopy.applicationIds); + Objects.equals(this.applicationIds, campaignCopy.applicationIds) && + Objects.equals(this.description, campaignCopy.description) && + Objects.equals(this.startTime, campaignCopy.startTime) && + Objects.equals(this.endTime, campaignCopy.endTime) && + Objects.equals(this.tags, campaignCopy.tags); } @Override public int hashCode() { - return Objects.hash(name, applicationIds); + return Objects.hash(name, applicationIds, description, startTime, endTime, tags); } @@ -107,6 +208,10 @@ public String toString() { sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" applicationIds: ").append(toIndentedString(applicationIds)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" startTime: ").append(toIndentedString(startTime)).append("\n"); + sb.append(" endTime: ").append(toIndentedString(endTime)).append("\n"); + sb.append(" tags: ").append(toIndentedString(tags)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/Change.java b/src/main/java/one/talon/model/Change.java index 6dff391d..0ff85283 100644 --- a/src/main/java/one/talon/model/Change.java +++ b/src/main/java/one/talon/model/Change.java @@ -133,10 +133,10 @@ public Change old(Object old) { } /** - * Resource before the change occured. + * Resource before the change occurred. * @return old **/ - @ApiModelProperty(value = "Resource before the change occured.") + @ApiModelProperty(value = "Resource before the change occurred.") public Object getOld() { return old; } @@ -151,10 +151,10 @@ public Change _new(Object _new) { } /** - * Resource after the change occured. + * Resource after the change occurred. * @return _new **/ - @ApiModelProperty(value = "Resource after the change occured.") + @ApiModelProperty(value = "Resource after the change occurred.") public Object getNew() { return _new; } diff --git a/src/main/java/one/talon/model/CustomerInventory.java b/src/main/java/one/talon/model/CustomerInventory.java new file mode 100644 index 00000000..132e2b7a --- /dev/null +++ b/src/main/java/one/talon/model/CustomerInventory.java @@ -0,0 +1,131 @@ +/* + * Talon.One API + * The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns. ### Where is the API? The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id` [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.CustomerProfile; +import one.talon.model.Referral; + +/** + * CustomerInventory + */ + +public class CustomerInventory { + public static final String SERIALIZED_NAME_PROFILE = "profile"; + @SerializedName(SERIALIZED_NAME_PROFILE) + private CustomerProfile profile = null; + + public static final String SERIALIZED_NAME_REFERRALS = "referrals"; + @SerializedName(SERIALIZED_NAME_REFERRALS) + private List referrals = null; + + public CustomerInventory profile(CustomerProfile profile) { + this.profile = profile; + return this; + } + + /** + * Get profile + * @return profile + **/ + @ApiModelProperty(value = "") + public CustomerProfile getProfile() { + return profile; + } + + public void setProfile(CustomerProfile profile) { + this.profile = profile; + } + + public CustomerInventory referrals(List referrals) { + this.referrals = referrals; + return this; + } + + public CustomerInventory addReferralsItem(Referral referralsItem) { + if (this.referrals == null) { + this.referrals = new ArrayList(); + } + this.referrals.add(referralsItem); + return this; + } + + /** + * Get referrals + * @return referrals + **/ + @ApiModelProperty(value = "") + public List getReferrals() { + return referrals; + } + + public void setReferrals(List referrals) { + this.referrals = referrals; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CustomerInventory customerInventory = (CustomerInventory) o; + return Objects.equals(this.profile, customerInventory.profile) && + Objects.equals(this.referrals, customerInventory.referrals); + } + + @Override + public int hashCode() { + return Objects.hash(profile, referrals); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CustomerInventory {\n"); + + sb.append(" profile: ").append(toIndentedString(profile)).append("\n"); + sb.append(" referrals: ").append(toIndentedString(referrals)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/InlineResponse20020.java b/src/main/java/one/talon/model/InlineResponse20020.java index d1f44eb0..1c14e7c3 100644 --- a/src/main/java/one/talon/model/InlineResponse20020.java +++ b/src/main/java/one/talon/model/InlineResponse20020.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Webhook; +import one.talon.model.Attribute; /** * InlineResponse20020 @@ -34,18 +34,18 @@ public class InlineResponse20020 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20020 data(List data) { + public InlineResponse20020 data(List data) { this.data = data; return this; } - public InlineResponse20020 addDataItem(Webhook dataItem) { + public InlineResponse20020 addDataItem(Attribute dataItem) { this.data.add(dataItem); return this; } @@ -55,11 +55,11 @@ public InlineResponse20020 addDataItem(Webhook dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20021.java b/src/main/java/one/talon/model/InlineResponse20021.java index 424f80ef..783de737 100644 --- a/src/main/java/one/talon/model/InlineResponse20021.java +++ b/src/main/java/one/talon/model/InlineResponse20021.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.WebhookActivationLogEntry; +import one.talon.model.Webhook; /** * InlineResponse20021 @@ -34,18 +34,18 @@ public class InlineResponse20021 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20021 data(List data) { + public InlineResponse20021 data(List data) { this.data = data; return this; } - public InlineResponse20021 addDataItem(WebhookActivationLogEntry dataItem) { + public InlineResponse20021 addDataItem(Webhook dataItem) { this.data.add(dataItem); return this; } @@ -55,11 +55,11 @@ public InlineResponse20021 addDataItem(WebhookActivationLogEntry dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20022.java b/src/main/java/one/talon/model/InlineResponse20022.java index b4a1567c..51310c9f 100644 --- a/src/main/java/one/talon/model/InlineResponse20022.java +++ b/src/main/java/one/talon/model/InlineResponse20022.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.WebhookLogEntry; +import one.talon.model.WebhookActivationLogEntry; /** * InlineResponse20022 @@ -34,18 +34,18 @@ public class InlineResponse20022 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20022 data(List data) { + public InlineResponse20022 data(List data) { this.data = data; return this; } - public InlineResponse20022 addDataItem(WebhookLogEntry dataItem) { + public InlineResponse20022 addDataItem(WebhookActivationLogEntry dataItem) { this.data.add(dataItem); return this; } @@ -55,11 +55,11 @@ public InlineResponse20022 addDataItem(WebhookLogEntry dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20023.java b/src/main/java/one/talon/model/InlineResponse20023.java index 9dd06612..c0beacdf 100644 --- a/src/main/java/one/talon/model/InlineResponse20023.java +++ b/src/main/java/one/talon/model/InlineResponse20023.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.EventType; +import one.talon.model.WebhookLogEntry; /** * InlineResponse20023 @@ -34,18 +34,18 @@ public class InlineResponse20023 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20023 data(List data) { + public InlineResponse20023 data(List data) { this.data = data; return this; } - public InlineResponse20023 addDataItem(EventType dataItem) { + public InlineResponse20023 addDataItem(WebhookLogEntry dataItem) { this.data.add(dataItem); return this; } @@ -55,11 +55,11 @@ public InlineResponse20023 addDataItem(EventType dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20024.java b/src/main/java/one/talon/model/InlineResponse20024.java index 5f4e6be8..5307ef8a 100644 --- a/src/main/java/one/talon/model/InlineResponse20024.java +++ b/src/main/java/one/talon/model/InlineResponse20024.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.User; +import one.talon.model.EventType; /** * InlineResponse20024 @@ -34,18 +34,18 @@ public class InlineResponse20024 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20024 data(List data) { + public InlineResponse20024 data(List data) { this.data = data; return this; } - public InlineResponse20024 addDataItem(User dataItem) { + public InlineResponse20024 addDataItem(EventType dataItem) { this.data.add(dataItem); return this; } @@ -55,11 +55,11 @@ public InlineResponse20024 addDataItem(User dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20025.java b/src/main/java/one/talon/model/InlineResponse20025.java index 208e7d9e..431c919a 100644 --- a/src/main/java/one/talon/model/InlineResponse20025.java +++ b/src/main/java/one/talon/model/InlineResponse20025.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Change; +import one.talon.model.User; /** * InlineResponse20025 @@ -34,22 +34,18 @@ public class InlineResponse20025 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); - - public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; - @SerializedName(SERIALIZED_NAME_HAS_MORE) - private Boolean hasMore; + private List data = new ArrayList(); public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20025 data(List data) { + public InlineResponse20025 data(List data) { this.data = data; return this; } - public InlineResponse20025 addDataItem(Change dataItem) { + public InlineResponse20025 addDataItem(User dataItem) { this.data.add(dataItem); return this; } @@ -59,32 +55,14 @@ public InlineResponse20025 addDataItem(Change dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } - public InlineResponse20025 hasMore(Boolean hasMore) { - this.hasMore = hasMore; - return this; - } - - /** - * Get hasMore - * @return hasMore - **/ - @ApiModelProperty(value = "") - public Boolean getHasMore() { - return hasMore; - } - - public void setHasMore(Boolean hasMore) { - this.hasMore = hasMore; - } - public InlineResponse20025 totalResultSize(Integer totalResultSize) { this.totalResultSize = totalResultSize; return this; @@ -94,7 +72,7 @@ public InlineResponse20025 totalResultSize(Integer totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @ApiModelProperty(value = "") + @ApiModelProperty(required = true, value = "") public Integer getTotalResultSize() { return totalResultSize; } @@ -114,13 +92,12 @@ public boolean equals(java.lang.Object o) { } InlineResponse20025 inlineResponse20025 = (InlineResponse20025) o; return Objects.equals(this.data, inlineResponse20025.data) && - Objects.equals(this.hasMore, inlineResponse20025.hasMore) && Objects.equals(this.totalResultSize, inlineResponse20025.totalResultSize); } @Override public int hashCode() { - return Objects.hash(data, hasMore, totalResultSize); + return Objects.hash(data, totalResultSize); } @@ -130,7 +107,6 @@ public String toString() { sb.append("class InlineResponse20025 {\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); - sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20026.java b/src/main/java/one/talon/model/InlineResponse20026.java index 863005e3..657504da 100644 --- a/src/main/java/one/talon/model/InlineResponse20026.java +++ b/src/main/java/one/talon/model/InlineResponse20026.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Export; +import one.talon.model.Change; /** * InlineResponse20026 @@ -34,18 +34,22 @@ public class InlineResponse20026 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); + + public static final String SERIALIZED_NAME_HAS_MORE = "hasMore"; + @SerializedName(SERIALIZED_NAME_HAS_MORE) + private Boolean hasMore; public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20026 data(List data) { + public InlineResponse20026 data(List data) { this.data = data; return this; } - public InlineResponse20026 addDataItem(Export dataItem) { + public InlineResponse20026 addDataItem(Change dataItem) { this.data.add(dataItem); return this; } @@ -55,14 +59,32 @@ public InlineResponse20026 addDataItem(Export dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } + public InlineResponse20026 hasMore(Boolean hasMore) { + this.hasMore = hasMore; + return this; + } + + /** + * Get hasMore + * @return hasMore + **/ + @ApiModelProperty(value = "") + public Boolean getHasMore() { + return hasMore; + } + + public void setHasMore(Boolean hasMore) { + this.hasMore = hasMore; + } + public InlineResponse20026 totalResultSize(Integer totalResultSize) { this.totalResultSize = totalResultSize; return this; @@ -72,7 +94,7 @@ public InlineResponse20026 totalResultSize(Integer totalResultSize) { * Get totalResultSize * @return totalResultSize **/ - @ApiModelProperty(required = true, value = "") + @ApiModelProperty(value = "") public Integer getTotalResultSize() { return totalResultSize; } @@ -92,12 +114,13 @@ public boolean equals(java.lang.Object o) { } InlineResponse20026 inlineResponse20026 = (InlineResponse20026) o; return Objects.equals(this.data, inlineResponse20026.data) && + Objects.equals(this.hasMore, inlineResponse20026.hasMore) && Objects.equals(this.totalResultSize, inlineResponse20026.totalResultSize); } @Override public int hashCode() { - return Objects.hash(data, totalResultSize); + return Objects.hash(data, hasMore, totalResultSize); } @@ -107,6 +130,7 @@ public String toString() { sb.append("class InlineResponse20026 {\n"); sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append(" hasMore: ").append(toIndentedString(hasMore)).append("\n"); sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/InlineResponse20027.java b/src/main/java/one/talon/model/InlineResponse20027.java index d676f6bf..085f6995 100644 --- a/src/main/java/one/talon/model/InlineResponse20027.java +++ b/src/main/java/one/talon/model/InlineResponse20027.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.ModelImport; +import one.talon.model.Export; /** * InlineResponse20027 @@ -34,18 +34,18 @@ public class InlineResponse20027 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20027 data(List data) { + public InlineResponse20027 data(List data) { this.data = data; return this; } - public InlineResponse20027 addDataItem(ModelImport dataItem) { + public InlineResponse20027 addDataItem(Export dataItem) { this.data.add(dataItem); return this; } @@ -55,11 +55,11 @@ public InlineResponse20027 addDataItem(ModelImport dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20028.java b/src/main/java/one/talon/model/InlineResponse20028.java index 87e94e04..19d215ca 100644 --- a/src/main/java/one/talon/model/InlineResponse20028.java +++ b/src/main/java/one/talon/model/InlineResponse20028.java @@ -25,7 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; -import one.talon.model.Role; +import one.talon.model.ModelImport; /** * InlineResponse20028 @@ -34,18 +34,18 @@ public class InlineResponse20028 { public static final String SERIALIZED_NAME_DATA = "data"; @SerializedName(SERIALIZED_NAME_DATA) - private List data = new ArrayList(); + private List data = new ArrayList(); public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) private Integer totalResultSize; - public InlineResponse20028 data(List data) { + public InlineResponse20028 data(List data) { this.data = data; return this; } - public InlineResponse20028 addDataItem(Role dataItem) { + public InlineResponse20028 addDataItem(ModelImport dataItem) { this.data.add(dataItem); return this; } @@ -55,11 +55,11 @@ public InlineResponse20028 addDataItem(Role dataItem) { * @return data **/ @ApiModelProperty(required = true, value = "") - public List getData() { + public List getData() { return data; } - public void setData(List data) { + public void setData(List data) { this.data = data; } diff --git a/src/main/java/one/talon/model/InlineResponse20029.java b/src/main/java/one/talon/model/InlineResponse20029.java new file mode 100644 index 00000000..2d1a0dff --- /dev/null +++ b/src/main/java/one/talon/model/InlineResponse20029.java @@ -0,0 +1,127 @@ +/* + * Talon.One API + * The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns. ### Where is the API? The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id` [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import one.talon.model.Role; + +/** + * InlineResponse20029 + */ + +public class InlineResponse20029 { + public static final String SERIALIZED_NAME_DATA = "data"; + @SerializedName(SERIALIZED_NAME_DATA) + private List data = new ArrayList(); + + public static final String SERIALIZED_NAME_TOTAL_RESULT_SIZE = "totalResultSize"; + @SerializedName(SERIALIZED_NAME_TOTAL_RESULT_SIZE) + private Integer totalResultSize; + + public InlineResponse20029 data(List data) { + this.data = data; + return this; + } + + public InlineResponse20029 addDataItem(Role dataItem) { + this.data.add(dataItem); + return this; + } + + /** + * Get data + * @return data + **/ + @ApiModelProperty(required = true, value = "") + public List getData() { + return data; + } + + public void setData(List data) { + this.data = data; + } + + public InlineResponse20029 totalResultSize(Integer totalResultSize) { + this.totalResultSize = totalResultSize; + return this; + } + + /** + * Get totalResultSize + * @return totalResultSize + **/ + @ApiModelProperty(required = true, value = "") + public Integer getTotalResultSize() { + return totalResultSize; + } + + public void setTotalResultSize(Integer totalResultSize) { + this.totalResultSize = totalResultSize; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + InlineResponse20029 inlineResponse20029 = (InlineResponse20029) o; + return Objects.equals(this.data, inlineResponse20029.data) && + Objects.equals(this.totalResultSize, inlineResponse20029.totalResultSize); + } + + @Override + public int hashCode() { + return Objects.hash(data, totalResultSize); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class InlineResponse20029 {\n"); + + sb.append(" data: ").append(toIndentedString(data)).append("\n"); + sb.append(" totalResultSize: ").append(toIndentedString(totalResultSize)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/NewApplication.java b/src/main/java/one/talon/model/NewApplication.java index 3fb0cab4..d7e653ce 100644 --- a/src/main/java/one/talon/model/NewApplication.java +++ b/src/main/java/one/talon/model/NewApplication.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.AttributesSettings; import one.talon.model.LimitConfig; /** @@ -110,6 +111,10 @@ public CaseSensitivityEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_LIMITS) private List limits = null; + public static final String SERIALIZED_NAME_ATTRIBUTES_SETTINGS = "attributesSettings"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES_SETTINGS) + private AttributesSettings attributesSettings = null; + public static final String SERIALIZED_NAME_KEY = "key"; @SerializedName(SERIALIZED_NAME_KEY) private String key; @@ -248,6 +253,24 @@ public void setLimits(List limits) { this.limits = limits; } + public NewApplication attributesSettings(AttributesSettings attributesSettings) { + this.attributesSettings = attributesSettings; + return this; + } + + /** + * Get attributesSettings + * @return attributesSettings + **/ + @ApiModelProperty(value = "") + public AttributesSettings getAttributesSettings() { + return attributesSettings; + } + + public void setAttributesSettings(AttributesSettings attributesSettings) { + this.attributesSettings = attributesSettings; + } + public NewApplication key(String key) { this.key = key; return this; @@ -283,12 +306,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.caseSensitivity, newApplication.caseSensitivity) && Objects.equals(this.attributes, newApplication.attributes) && Objects.equals(this.limits, newApplication.limits) && + Objects.equals(this.attributesSettings, newApplication.attributesSettings) && Objects.equals(this.key, newApplication.key); } @Override public int hashCode() { - return Objects.hash(name, description, timezone, currency, caseSensitivity, attributes, limits, key); + return Objects.hash(name, description, timezone, currency, caseSensitivity, attributes, limits, attributesSettings, key); } @@ -304,6 +328,7 @@ public String toString() { sb.append(" caseSensitivity: ").append(toIndentedString(caseSensitivity)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); sb.append(" limits: ").append(toIndentedString(limits)).append("\n"); + sb.append(" attributesSettings: ").append(toIndentedString(attributesSettings)).append("\n"); sb.append(" key: ").append(toIndentedString(key)).append("\n"); sb.append("}"); return sb.toString(); diff --git a/src/main/java/one/talon/model/NewSamlConnection.java b/src/main/java/one/talon/model/NewSamlConnection.java index 09e71aa8..ef2bfe2e 100644 --- a/src/main/java/one/talon/model/NewSamlConnection.java +++ b/src/main/java/one/talon/model/NewSamlConnection.java @@ -25,11 +25,19 @@ import java.io.IOException; /** - * A new SAML 2.0 connection. + * */ -@ApiModel(description = "A new SAML 2.0 connection.") +@ApiModel(description = "") public class NewSamlConnection { + public static final String SERIALIZED_NAME_X509CERTIFICATE = "x509certificate"; + @SerializedName(SERIALIZED_NAME_X509CERTIFICATE) + private String x509certificate; + + public static final String SERIALIZED_NAME_ACCOUNT_ID = "accountId"; + @SerializedName(SERIALIZED_NAME_ACCOUNT_ID) + private Integer accountId; + public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) private String name; @@ -54,13 +62,45 @@ public class NewSamlConnection { @SerializedName(SERIALIZED_NAME_METADATA_U_R_L) private String metadataURL; - public static final String SERIALIZED_NAME_X509CERTIFICATE = "x509certificate"; - @SerializedName(SERIALIZED_NAME_X509CERTIFICATE) - private String x509certificate; + public static final String SERIALIZED_NAME_AUDIENCE_U_R_I = "audienceURI"; + @SerializedName(SERIALIZED_NAME_AUDIENCE_U_R_I) + private String audienceURI; + + public NewSamlConnection x509certificate(String x509certificate) { + this.x509certificate = x509certificate; + return this; + } - public static final String SERIALIZED_NAME_AUDIENCE = "audience"; - @SerializedName(SERIALIZED_NAME_AUDIENCE) - private String audience; + /** + * X.509 Certificate. + * @return x509certificate + **/ + @ApiModelProperty(required = true, value = "X.509 Certificate.") + public String getX509certificate() { + return x509certificate; + } + + public void setX509certificate(String x509certificate) { + this.x509certificate = x509certificate; + } + + public NewSamlConnection accountId(Integer accountId) { + this.accountId = accountId; + return this; + } + + /** + * The ID of the account that owns this entity. + * @return accountId + **/ + @ApiModelProperty(required = true, value = "The ID of the account that owns this entity.") + public Integer getAccountId() { + return accountId; + } + + public void setAccountId(Integer accountId) { + this.accountId = accountId; + } public NewSamlConnection name(String name) { this.name = name; @@ -170,40 +210,22 @@ public void setMetadataURL(String metadataURL) { this.metadataURL = metadataURL; } - public NewSamlConnection x509certificate(String x509certificate) { - this.x509certificate = x509certificate; + public NewSamlConnection audienceURI(String audienceURI) { + this.audienceURI = audienceURI; return this; } /** - * X.509 Certificate. - * @return x509certificate + * The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. + * @return audienceURI **/ - @ApiModelProperty(required = true, value = "X.509 Certificate.") - public String getX509certificate() { - return x509certificate; + @ApiModelProperty(value = "The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. ") + public String getAudienceURI() { + return audienceURI; } - public void setX509certificate(String x509certificate) { - this.x509certificate = x509certificate; - } - - public NewSamlConnection audience(String audience) { - this.audience = audience; - return this; - } - - /** - * The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. - * @return audience - **/ - @ApiModelProperty(value = "The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. ") - public String getAudience() { - return audience; - } - - public void setAudience(String audience) { - this.audience = audience; + public void setAudienceURI(String audienceURI) { + this.audienceURI = audienceURI; } @@ -216,19 +238,20 @@ public boolean equals(java.lang.Object o) { return false; } NewSamlConnection newSamlConnection = (NewSamlConnection) o; - return Objects.equals(this.name, newSamlConnection.name) && + return Objects.equals(this.x509certificate, newSamlConnection.x509certificate) && + Objects.equals(this.accountId, newSamlConnection.accountId) && + Objects.equals(this.name, newSamlConnection.name) && Objects.equals(this.enabled, newSamlConnection.enabled) && Objects.equals(this.issuer, newSamlConnection.issuer) && Objects.equals(this.signOnURL, newSamlConnection.signOnURL) && Objects.equals(this.signOutURL, newSamlConnection.signOutURL) && Objects.equals(this.metadataURL, newSamlConnection.metadataURL) && - Objects.equals(this.x509certificate, newSamlConnection.x509certificate) && - Objects.equals(this.audience, newSamlConnection.audience); + Objects.equals(this.audienceURI, newSamlConnection.audienceURI); } @Override public int hashCode() { - return Objects.hash(name, enabled, issuer, signOnURL, signOutURL, metadataURL, x509certificate, audience); + return Objects.hash(x509certificate, accountId, name, enabled, issuer, signOnURL, signOutURL, metadataURL, audienceURI); } @@ -237,14 +260,15 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class NewSamlConnection {\n"); + sb.append(" x509certificate: ").append(toIndentedString(x509certificate)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); sb.append(" issuer: ").append(toIndentedString(issuer)).append("\n"); sb.append(" signOnURL: ").append(toIndentedString(signOnURL)).append("\n"); sb.append(" signOutURL: ").append(toIndentedString(signOutURL)).append("\n"); sb.append(" metadataURL: ").append(toIndentedString(metadataURL)).append("\n"); - sb.append(" x509certificate: ").append(toIndentedString(x509certificate)).append("\n"); - sb.append(" audience: ").append(toIndentedString(audience)).append("\n"); + sb.append(" audienceURI: ").append(toIndentedString(audienceURI)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/SamlConnection.java b/src/main/java/one/talon/model/SamlConnection.java index 724d1c21..43223197 100644 --- a/src/main/java/one/talon/model/SamlConnection.java +++ b/src/main/java/one/talon/model/SamlConnection.java @@ -31,22 +31,14 @@ @ApiModel(description = "") public class SamlConnection { - public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_ID) - private Integer id; - - public static final String SERIALIZED_NAME_CREATED = "created"; - @SerializedName(SERIALIZED_NAME_CREATED) - private OffsetDateTime created; + public static final String SERIALIZED_NAME_ASSERTION_CONSUMER_SERVICE_U_R_L = "assertionConsumerServiceURL"; + @SerializedName(SERIALIZED_NAME_ASSERTION_CONSUMER_SERVICE_U_R_L) + private String assertionConsumerServiceURL; public static final String SERIALIZED_NAME_ACCOUNT_ID = "accountId"; @SerializedName(SERIALIZED_NAME_ACCOUNT_ID) private Integer accountId; - public static final String SERIALIZED_NAME_ASSERTION_CONSUMER_SERVICE_U_R_L = "assertionConsumerServiceURL"; - @SerializedName(SERIALIZED_NAME_ASSERTION_CONSUMER_SERVICE_U_R_L) - private String assertionConsumerServiceURL; - public static final String SERIALIZED_NAME_NAME = "name"; @SerializedName(SERIALIZED_NAME_NAME) private String name; @@ -71,48 +63,34 @@ public class SamlConnection { @SerializedName(SERIALIZED_NAME_METADATA_U_R_L) private String metadataURL; - public static final String SERIALIZED_NAME_X509CERTIFICATE = "x509certificate"; - @SerializedName(SERIALIZED_NAME_X509CERTIFICATE) - private String x509certificate; - - public static final String SERIALIZED_NAME_AUDIENCE = "audience"; - @SerializedName(SERIALIZED_NAME_AUDIENCE) - private String audience; - - public SamlConnection id(Integer id) { - this.id = id; - return this; - } + public static final String SERIALIZED_NAME_AUDIENCE_U_R_I = "audienceURI"; + @SerializedName(SERIALIZED_NAME_AUDIENCE_U_R_I) + private String audienceURI; - /** - * Get id - * @return id - **/ - @ApiModelProperty(required = true, value = "") - public Integer getId() { - return id; - } + public static final String SERIALIZED_NAME_ID = "id"; + @SerializedName(SERIALIZED_NAME_ID) + private Integer id; - public void setId(Integer id) { - this.id = id; - } + public static final String SERIALIZED_NAME_CREATED = "created"; + @SerializedName(SERIALIZED_NAME_CREATED) + private OffsetDateTime created; - public SamlConnection created(OffsetDateTime created) { - this.created = created; + public SamlConnection assertionConsumerServiceURL(String assertionConsumerServiceURL) { + this.assertionConsumerServiceURL = assertionConsumerServiceURL; return this; } /** - * Unix timestamp indicating when the session was first created. - * @return created + * The location where the SAML assertion is sent with a HTTP POST. + * @return assertionConsumerServiceURL **/ - @ApiModelProperty(required = true, value = "Unix timestamp indicating when the session was first created.") - public OffsetDateTime getCreated() { - return created; + @ApiModelProperty(required = true, value = "The location where the SAML assertion is sent with a HTTP POST.") + public String getAssertionConsumerServiceURL() { + return assertionConsumerServiceURL; } - public void setCreated(OffsetDateTime created) { - this.created = created; + public void setAssertionConsumerServiceURL(String assertionConsumerServiceURL) { + this.assertionConsumerServiceURL = assertionConsumerServiceURL; } public SamlConnection accountId(Integer accountId) { @@ -121,10 +99,10 @@ public SamlConnection accountId(Integer accountId) { } /** - * The ID of the account that owns this SAML Service. + * The ID of the account that owns this entity. * @return accountId **/ - @ApiModelProperty(required = true, value = "The ID of the account that owns this SAML Service.") + @ApiModelProperty(required = true, value = "The ID of the account that owns this entity.") public Integer getAccountId() { return accountId; } @@ -133,24 +111,6 @@ public void setAccountId(Integer accountId) { this.accountId = accountId; } - public SamlConnection assertionConsumerServiceURL(String assertionConsumerServiceURL) { - this.assertionConsumerServiceURL = assertionConsumerServiceURL; - return this; - } - - /** - * The location where the SAML assertion is sent with a HTTP POST. - * @return assertionConsumerServiceURL - **/ - @ApiModelProperty(required = true, value = "The location where the SAML assertion is sent with a HTTP POST.") - public String getAssertionConsumerServiceURL() { - return assertionConsumerServiceURL; - } - - public void setAssertionConsumerServiceURL(String assertionConsumerServiceURL) { - this.assertionConsumerServiceURL = assertionConsumerServiceURL; - } - public SamlConnection name(String name) { this.name = name; return this; @@ -259,40 +219,58 @@ public void setMetadataURL(String metadataURL) { this.metadataURL = metadataURL; } - public SamlConnection x509certificate(String x509certificate) { - this.x509certificate = x509certificate; + public SamlConnection audienceURI(String audienceURI) { + this.audienceURI = audienceURI; return this; } /** - * X.509 Certificate. - * @return x509certificate + * The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. + * @return audienceURI **/ - @ApiModelProperty(required = true, value = "X.509 Certificate.") - public String getX509certificate() { - return x509certificate; + @ApiModelProperty(required = true, value = "The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. ") + public String getAudienceURI() { + return audienceURI; } - public void setX509certificate(String x509certificate) { - this.x509certificate = x509certificate; + public void setAudienceURI(String audienceURI) { + this.audienceURI = audienceURI; } - public SamlConnection audience(String audience) { - this.audience = audience; + public SamlConnection id(Integer id) { + this.id = id; return this; } /** - * The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. - * @return audience + * Unique ID for this entity. + * @return id **/ - @ApiModelProperty(required = true, value = "The application-defined unique identifier that is the intended audience of the SAML assertion. This is most often the SP Entity ID of your application. When not specified, the ACS URL will be used. ") - public String getAudience() { - return audience; + @ApiModelProperty(required = true, value = "Unique ID for this entity.") + public Integer getId() { + return id; } - public void setAudience(String audience) { - this.audience = audience; + public void setId(Integer id) { + this.id = id; + } + + public SamlConnection created(OffsetDateTime created) { + this.created = created; + return this; + } + + /** + * The exact moment this entity was created. + * @return created + **/ + @ApiModelProperty(required = true, value = "The exact moment this entity was created.") + public OffsetDateTime getCreated() { + return created; + } + + public void setCreated(OffsetDateTime created) { + this.created = created; } @@ -305,23 +283,22 @@ public boolean equals(java.lang.Object o) { return false; } SamlConnection samlConnection = (SamlConnection) o; - return Objects.equals(this.id, samlConnection.id) && - Objects.equals(this.created, samlConnection.created) && + return Objects.equals(this.assertionConsumerServiceURL, samlConnection.assertionConsumerServiceURL) && Objects.equals(this.accountId, samlConnection.accountId) && - Objects.equals(this.assertionConsumerServiceURL, samlConnection.assertionConsumerServiceURL) && Objects.equals(this.name, samlConnection.name) && Objects.equals(this.enabled, samlConnection.enabled) && Objects.equals(this.issuer, samlConnection.issuer) && Objects.equals(this.signOnURL, samlConnection.signOnURL) && Objects.equals(this.signOutURL, samlConnection.signOutURL) && Objects.equals(this.metadataURL, samlConnection.metadataURL) && - Objects.equals(this.x509certificate, samlConnection.x509certificate) && - Objects.equals(this.audience, samlConnection.audience); + Objects.equals(this.audienceURI, samlConnection.audienceURI) && + Objects.equals(this.id, samlConnection.id) && + Objects.equals(this.created, samlConnection.created); } @Override public int hashCode() { - return Objects.hash(id, created, accountId, assertionConsumerServiceURL, name, enabled, issuer, signOnURL, signOutURL, metadataURL, x509certificate, audience); + return Objects.hash(assertionConsumerServiceURL, accountId, name, enabled, issuer, signOnURL, signOutURL, metadataURL, audienceURI, id, created); } @@ -330,18 +307,17 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class SamlConnection {\n"); - sb.append(" id: ").append(toIndentedString(id)).append("\n"); - sb.append(" created: ").append(toIndentedString(created)).append("\n"); - sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); sb.append(" assertionConsumerServiceURL: ").append(toIndentedString(assertionConsumerServiceURL)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); sb.append(" issuer: ").append(toIndentedString(issuer)).append("\n"); sb.append(" signOnURL: ").append(toIndentedString(signOnURL)).append("\n"); sb.append(" signOutURL: ").append(toIndentedString(signOutURL)).append("\n"); sb.append(" metadataURL: ").append(toIndentedString(metadataURL)).append("\n"); - sb.append(" x509certificate: ").append(toIndentedString(x509certificate)).append("\n"); - sb.append(" audience: ").append(toIndentedString(audience)).append("\n"); + sb.append(" audienceURI: ").append(toIndentedString(audienceURI)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" created: ").append(toIndentedString(created)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/main/java/one/talon/model/SamlConnectionMetadata.java b/src/main/java/one/talon/model/SamlConnectionMetadata.java new file mode 100644 index 00000000..52b6f2be --- /dev/null +++ b/src/main/java/one/talon/model/SamlConnectionMetadata.java @@ -0,0 +1,168 @@ +/* + * Talon.One API + * The Talon.One API is used to manage applications and campaigns, as well as to integrate with your application. The operations in the _Integration API_ section are used to integrate with our platform, while the other operations are used to manage applications and campaigns. ### Where is the API? The API is available at the same hostname as these docs. For example, if you are reading this page at `https://mycompany.talon.one/docs/api/`, the URL for the [updateCustomerProfile][] operation is `https://mycompany.talon.one/v1/customer_profiles/id` [updateCustomerProfile]: #operation--v1-customer_profiles--integrationId--put + * + * OpenAPI spec version: 1.0.0 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +package one.talon.model; + +import java.util.Objects; +import java.util.Arrays; +import com.google.gson.TypeAdapter; +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import java.io.IOException; +import java.math.BigDecimal; + +/** + * SamlConnectionMetadata + */ + +public class SamlConnectionMetadata { + public static final String SERIALIZED_NAME_NAME = "name"; + @SerializedName(SERIALIZED_NAME_NAME) + private String name; + + public static final String SERIALIZED_NAME_ENABLED = "enabled"; + @SerializedName(SERIALIZED_NAME_ENABLED) + private Boolean enabled; + + public static final String SERIALIZED_NAME_ACCOUNT_ID = "accountId"; + @SerializedName(SERIALIZED_NAME_ACCOUNT_ID) + private BigDecimal accountId; + + public static final String SERIALIZED_NAME_METADATA_DOCUMENT = "metadataDocument"; + @SerializedName(SERIALIZED_NAME_METADATA_DOCUMENT) + private String metadataDocument; + + public SamlConnectionMetadata name(String name) { + this.name = name; + return this; + } + + /** + * ID of the SAML service. + * @return name + **/ + @ApiModelProperty(required = true, value = "ID of the SAML service.") + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public SamlConnectionMetadata enabled(Boolean enabled) { + this.enabled = enabled; + return this; + } + + /** + * Determines if this SAML connection active. + * @return enabled + **/ + @ApiModelProperty(required = true, value = "Determines if this SAML connection active.") + public Boolean getEnabled() { + return enabled; + } + + public void setEnabled(Boolean enabled) { + this.enabled = enabled; + } + + public SamlConnectionMetadata accountId(BigDecimal accountId) { + this.accountId = accountId; + return this; + } + + /** + * Get accountId + * @return accountId + **/ + @ApiModelProperty(required = true, value = "") + public BigDecimal getAccountId() { + return accountId; + } + + public void setAccountId(BigDecimal accountId) { + this.accountId = accountId; + } + + public SamlConnectionMetadata metadataDocument(String metadataDocument) { + this.metadataDocument = metadataDocument; + return this; + } + + /** + * Identity Provider metadata XML document. + * @return metadataDocument + **/ + @ApiModelProperty(required = true, value = "Identity Provider metadata XML document.") + public String getMetadataDocument() { + return metadataDocument; + } + + public void setMetadataDocument(String metadataDocument) { + this.metadataDocument = metadataDocument; + } + + + @Override + public boolean equals(java.lang.Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + SamlConnectionMetadata samlConnectionMetadata = (SamlConnectionMetadata) o; + return Objects.equals(this.name, samlConnectionMetadata.name) && + Objects.equals(this.enabled, samlConnectionMetadata.enabled) && + Objects.equals(this.accountId, samlConnectionMetadata.accountId) && + Objects.equals(this.metadataDocument, samlConnectionMetadata.metadataDocument); + } + + @Override + public int hashCode() { + return Objects.hash(name, enabled, accountId, metadataDocument); + } + + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class SamlConnectionMetadata {\n"); + + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n"); + sb.append(" accountId: ").append(toIndentedString(accountId)).append("\n"); + sb.append(" metadataDocument: ").append(toIndentedString(metadataDocument)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces + * (except the first line). + */ + private String toIndentedString(java.lang.Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + +} + diff --git a/src/main/java/one/talon/model/UpdateApplication.java b/src/main/java/one/talon/model/UpdateApplication.java index d471c1fa..19c19787 100644 --- a/src/main/java/one/talon/model/UpdateApplication.java +++ b/src/main/java/one/talon/model/UpdateApplication.java @@ -25,6 +25,7 @@ import java.io.IOException; import java.util.ArrayList; import java.util.List; +import one.talon.model.AttributesSettings; import one.talon.model.LimitConfig; /** @@ -109,6 +110,10 @@ public CaseSensitivityEnum read(final JsonReader jsonReader) throws IOException @SerializedName(SERIALIZED_NAME_LIMITS) private List limits = null; + public static final String SERIALIZED_NAME_ATTRIBUTES_SETTINGS = "attributesSettings"; + @SerializedName(SERIALIZED_NAME_ATTRIBUTES_SETTINGS) + private AttributesSettings attributesSettings = null; + public UpdateApplication name(String name) { this.name = name; return this; @@ -243,6 +248,24 @@ public void setLimits(List limits) { this.limits = limits; } + public UpdateApplication attributesSettings(AttributesSettings attributesSettings) { + this.attributesSettings = attributesSettings; + return this; + } + + /** + * Get attributesSettings + * @return attributesSettings + **/ + @ApiModelProperty(value = "") + public AttributesSettings getAttributesSettings() { + return attributesSettings; + } + + public void setAttributesSettings(AttributesSettings attributesSettings) { + this.attributesSettings = attributesSettings; + } + @Override public boolean equals(java.lang.Object o) { @@ -259,12 +282,13 @@ public boolean equals(java.lang.Object o) { Objects.equals(this.currency, updateApplication.currency) && Objects.equals(this.caseSensitivity, updateApplication.caseSensitivity) && Objects.equals(this.attributes, updateApplication.attributes) && - Objects.equals(this.limits, updateApplication.limits); + Objects.equals(this.limits, updateApplication.limits) && + Objects.equals(this.attributesSettings, updateApplication.attributesSettings); } @Override public int hashCode() { - return Objects.hash(name, description, timezone, currency, caseSensitivity, attributes, limits); + return Objects.hash(name, description, timezone, currency, caseSensitivity, attributes, limits, attributesSettings); } @@ -280,6 +304,7 @@ public String toString() { sb.append(" caseSensitivity: ").append(toIndentedString(caseSensitivity)).append("\n"); sb.append(" attributes: ").append(toIndentedString(attributes)).append("\n"); sb.append(" limits: ").append(toIndentedString(limits)).append("\n"); + sb.append(" attributesSettings: ").append(toIndentedString(attributesSettings)).append("\n"); sb.append("}"); return sb.toString(); } diff --git a/src/test/java/one/talon/api/IntegrationApiTest.java b/src/test/java/one/talon/api/IntegrationApiTest.java index 51118980..3e7e0c13 100644 --- a/src/test/java/one/talon/api/IntegrationApiTest.java +++ b/src/test/java/one/talon/api/IntegrationApiTest.java @@ -16,6 +16,7 @@ import one.talon.ApiException; import one.talon.model.Coupon; import one.talon.model.CouponReservations; +import one.talon.model.CustomerInventory; import one.talon.model.InlineResponse200; import one.talon.model.InlineResponse2001; import one.talon.model.IntegrationState; @@ -107,6 +108,24 @@ public void deleteCustomerDataTest() throws ApiException { // TODO: test validations } + /** + * Get an inventory of all data associated with a specific customer profile. + * + * Get information regarding entities referencing this customer profile's integrationId. Currently we support customer profile information and referral codes. In the future, this will be expanded with coupon codes and loyalty points. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getCustomerInventoryTest() throws ApiException { + String integrationId = null; + Object profile = null; + Object referrals = null; + CustomerInventory response = api.getCustomerInventory(integrationId, profile, referrals); + + // TODO: test validations + } + /** * Get all valid reserved coupons * diff --git a/src/test/java/one/talon/api/ManagementApiTest.java b/src/test/java/one/talon/api/ManagementApiTest.java index ebf7486a..7b8b3084 100644 --- a/src/test/java/one/talon/api/ManagementApiTest.java +++ b/src/test/java/one/talon/api/ManagementApiTest.java @@ -16,7 +16,6 @@ import one.talon.ApiException; import one.talon.model.Account; import one.talon.model.AccountAnalytics; -import one.talon.model.AccountLimits; import one.talon.model.Application; import one.talon.model.ApplicationApiHealth; import one.talon.model.ApplicationCustomer; @@ -54,6 +53,7 @@ import one.talon.model.InlineResponse20026; import one.talon.model.InlineResponse20027; import one.talon.model.InlineResponse20028; +import one.talon.model.InlineResponse20029; import one.talon.model.InlineResponse2003; import one.talon.model.InlineResponse2004; import one.talon.model.InlineResponse2005; @@ -65,6 +65,7 @@ import one.talon.model.LoyaltyLedger; import one.talon.model.LoyaltyPoints; import one.talon.model.LoyaltyProgram; +import one.talon.model.NewAttribute; import one.talon.model.NewCampaign; import one.talon.model.NewCampaignSet; import one.talon.model.NewCoupons; @@ -133,6 +134,22 @@ public void copyCampaignToApplicationsTest() throws ApiException { // TODO: test validations } + /** + * Define a new custom attribute + * + * Defines a new _custom attribute_ in this account. Custom attributes allow you to attach new fields to Talon.One domain objects like campaigns, coupons, customers and so on. These attributes can then be given values when creating / updating these objects, and these values can be used in your campaign rules. For example, you could define a `zipCode` field for customer sessions, and add a rule to your campaign that only allows certain ZIP codes. These attributes are shared across all applications in your account, and are never required. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void createAttributeTest() throws ApiException { + NewAttribute newAttribute = null; + Attribute response = api.createAttribute(newAttribute); + + // TODO: test validations + } + /** * Create a Campaign * @@ -153,7 +170,7 @@ public void createCampaignTest() throws ApiException { /** * Create Coupons * - * Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupns can be created. + * Create coupons according to some pattern. Up to 20.000 coupons can be created without a unique prefix. When a unique prefix is provided, up to 200.000 coupons can be created. * * @throws ApiException * if the Api call fails @@ -400,22 +417,6 @@ public void getAccountAnalyticsTest() throws ApiException { // TODO: test validations } - /** - * Get Account Limits - * - * Returns a list of all account limits set - * - * @throws ApiException - * if the Api call fails - */ - @Test - public void getAccountLimitsTest() throws ApiException { - Integer accountId = null; - AccountLimits response = api.getAccountLimits(accountId); - - // TODO: test validations - } - /** * Get all access logs * @@ -449,7 +450,7 @@ public void getAllAccessLogsTest() throws ApiException { */ @Test public void getAllRolesTest() throws ApiException { - InlineResponse20028 response = api.getAllRoles(); + InlineResponse20029 response = api.getAllRoles(); // TODO: test validations } @@ -522,7 +523,7 @@ public void getApplicationCustomersTest() throws ApiException { /** * Get a list of the customer profiles that match the given attributes * - * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile + * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile * * @throws ApiException * if the Api call fails @@ -687,6 +688,24 @@ public void getAttributeTest() throws ApiException { // TODO: test validations } + /** + * List custom attributes + * + * Returns all the defined custom attributes for the account. + * + * @throws ApiException + * if the Api call fails + */ + @Test + public void getAttributesTest() throws ApiException { + Integer pageSize = null; + Integer skip = null; + String sort = null; + InlineResponse20020 response = api.getAttributes(pageSize, skip, sort); + + // TODO: test validations + } + /** * Get a Campaign * @@ -803,7 +822,7 @@ public void getChangesTest() throws ApiException { OffsetDateTime createdAfter = null; Boolean withTotalResultSize = null; Boolean includeOld = null; - InlineResponse20025 response = api.getChanges(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld); + InlineResponse20026 response = api.getChanges(pageSize, skip, sort, applicationId, createdBefore, createdAfter, withTotalResultSize, includeOld); // TODO: test validations } @@ -1058,7 +1077,7 @@ public void getCustomerProfilesTest() throws ApiException { /** * Get a list of the customer profiles that match the given attributes * - * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: http://help.talon.one/customer/en/portal/articles/2525263-data-model?b_id=14115#customer-profile + * Gets a list of all the customer profiles for the account that exactly match a set of attributes. The match is successful if all the attributes of the request are found in a profile, even if the profile has more attributes that are not present on the request. [Customer Profile]: https://help.talon.one/hc/en-us/articles/360005130739-Data-Model#CustomerProfile * * @throws ApiException * if the Api call fails @@ -1089,7 +1108,7 @@ public void getEventTypesTest() throws ApiException { Integer pageSize = null; Integer skip = null; String sort = null; - InlineResponse20023 response = api.getEventTypes(applicationIds, name, includeOldVersions, pageSize, skip, sort); + InlineResponse20024 response = api.getEventTypes(applicationIds, name, includeOldVersions, pageSize, skip, sort); // TODO: test validations } @@ -1109,7 +1128,7 @@ public void getExportsTest() throws ApiException { Integer applicationId = null; Integer campaignId = null; String entity = null; - InlineResponse20026 response = api.getExports(pageSize, skip, applicationId, campaignId, entity); + InlineResponse20027 response = api.getExports(pageSize, skip, applicationId, campaignId, entity); // TODO: test validations } @@ -1126,7 +1145,7 @@ public void getExportsTest() throws ApiException { public void getImportsTest() throws ApiException { Integer pageSize = null; Integer skip = null; - InlineResponse20027 response = api.getImports(pageSize, skip); + InlineResponse20028 response = api.getImports(pageSize, skip); // TODO: test validations } @@ -1314,7 +1333,7 @@ public void getUsersTest() throws ApiException { Integer pageSize = null; Integer skip = null; String sort = null; - InlineResponse20024 response = api.getUsers(pageSize, skip, sort); + InlineResponse20025 response = api.getUsers(pageSize, skip, sort); // TODO: test validations } @@ -1354,7 +1373,7 @@ public void getWebhookActivationLogsTest() throws ApiException { BigDecimal campaignId = null; OffsetDateTime createdBefore = null; OffsetDateTime createdAfter = null; - InlineResponse20021 response = api.getWebhookActivationLogs(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter); + InlineResponse20022 response = api.getWebhookActivationLogs(pageSize, skip, sort, integrationRequestUuid, webhookId, applicationId, campaignId, createdBefore, createdAfter); // TODO: test validations } @@ -1379,7 +1398,7 @@ public void getWebhookLogsTest() throws ApiException { String requestUuid = null; OffsetDateTime createdBefore = null; OffsetDateTime createdAfter = null; - InlineResponse20022 response = api.getWebhookLogs(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter); + InlineResponse20023 response = api.getWebhookLogs(pageSize, skip, sort, status, webhookId, applicationId, campaignId, requestUuid, createdBefore, createdAfter); // TODO: test validations } @@ -1398,7 +1417,7 @@ public void getWebhooksTest() throws ApiException { String sort = null; Integer pageSize = null; Integer skip = null; - InlineResponse20020 response = api.getWebhooks(applicationIds, sort, pageSize, skip); + InlineResponse20021 response = api.getWebhooks(applicationIds, sort, pageSize, skip); // TODO: test validations } @@ -1573,18 +1592,18 @@ public void searchCouponsAdvancedWithoutTotalCountTest() throws ApiException { } /** - * Set account limits + * Update a custom attribute * - * sets account limits + * Updates an existing custom attribute. Once created, the only property of a custom attribute that can be changed is the title (human readable description). This restriction is in place to prevent accidentally breaking live integrations. E.g. if you have a customer profile attribute with the name `region`, and your integration is sending `attributes.region` with customer profile updates, changing the name to `locale` would cause the integration requests to begin failing. If you **really** need to change the `type` or `name` property of a custom attribute, create a new attribute and update any relevant integrations and rules to use the new attribute. Then delete the old attribute when you are confident you have migrated any needed data from the old attribute to the new one. * * @throws ApiException * if the Api call fails */ @Test - public void setAccountLimitsTest() throws ApiException { - Integer accountId = null; - AccountLimits accountLimits = null; - api.setAccountLimits(accountId, accountLimits); + public void updateAttributeTest() throws ApiException { + Integer attributeId = null; + NewAttribute newAttribute = null; + Attribute response = api.updateAttribute(attributeId, newAttribute); // TODO: test validations }