From 75bab164df1137425d691fa1429e3a01e7359b5c Mon Sep 17 00:00:00 2001
From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com>
Date: Mon, 20 Apr 2026 14:40:00 +0000
Subject: [PATCH] SDK regeneration
---
.fern/metadata.json | 6 +-
build.gradle | 4 +-
reference.md | 1342 ++++++++++++++++-
.../com/schematic/api/AsyncBaseSchematic.java | 8 +
.../com/schematic/api/core/ClientOptions.java | 4 +-
.../resources/accounts/AccountsClient.java | 28 +
.../accounts/AsyncAccountsClient.java | 29 +
.../accounts/AsyncRawAccountsClient.java | 193 +++
.../resources/accounts/RawAccountsClient.java | 145 ++
.../requests/ListAccountMembersRequest.java | 201 +++
.../types/GetAccountMemberResponse.java | 181 +++
.../types/ListAccountMembersParams.java | 195 +++
.../types/ListAccountMembersResponse.java | 177 +++
.../CreateBillingSubscriptionRequestBody.java | 33 +
.../requests/CreateMeterRequestBody.java | 39 +-
.../companies/AsyncRawCompaniesClient.java | 14 +
.../companies/RawCompaniesClient.java | 14 +
.../requests/CountCompaniesRequest.java | 32 +
.../requests/ListCompaniesRequest.java | 32 +
.../requests/ListPlanChangesRequest.java | 26 +-
.../companies/types/CountCompaniesParams.java | 32 +
.../companies/types/ListCompaniesParams.java | 32 +
.../types/ListPlanChangesParams.java | 26 +-
.../resources/credits/AsyncCreditsClient.java | 13 +
.../credits/AsyncRawCreditsClient.java | 84 ++
.../api/resources/credits/CreditsClient.java | 12 +
.../resources/credits/RawCreditsClient.java | 62 +
...tSingleBillingPlanCreditGrantResponse.java | 184 +++
.../entitlements/AsyncEntitlementsClient.java | 14 +
.../AsyncRawEntitlementsClient.java | 98 ++
.../entitlements/EntitlementsClient.java | 14 +
.../entitlements/RawEntitlementsClient.java | 74 +
...llingLinkedPlanEntitlementRequestBody.java | 1064 +++++++++++++
.../CreatePlanEntitlementRequestBody.java | 33 +
.../UpdatePlanEntitlementRequestBody.java | 33 +
...lanEntitlementRequestBodyMetricPeriod.java | 109 ++
...mentRequestBodyMetricPeriodMonthReset.java | 89 ++
...nEntitlementForBillingProductResponse.java | 182 +++
.../features/AsyncFeaturesClient.java | 14 +
.../features/AsyncRawFeaturesClient.java | 154 +-
.../resources/features/FeaturesClient.java | 14 +
.../resources/features/RawFeaturesClient.java | 129 +-
.../requests/CountFeaturesRequest.java | 170 +--
...CreateBillingLinkedFeatureRequestBody.java | 496 ++++++
.../requests/ListFeaturesRequest.java | 170 +--
...psertFeatureForBillingProductResponse.java | 182 +++
.../AsyncIntegrationsapiClient.java | 36 +
.../AsyncRawIntegrationsapiClient.java | 121 ++
.../IntegrationsapiClient.java | 34 +
.../RawIntegrationsapiClient.java | 93 ++
.../GetIntegrationWebhookUrlResponse.java | 183 +++
.../api/resources/plans/AsyncPlansClient.java | 53 +
.../resources/plans/AsyncRawPlansClient.java | 410 +++++
.../api/resources/plans/PlansClient.java | 52 +
.../api/resources/plans/RawPlansClient.java | 312 ++++
...ntBillingProductMatchCompaniesRequest.java | 263 ++++
.../plans/requests/CountPlansRequest.java | 32 +
.../CreateBillingLinkedPlanRequestBody.java | 260 ++++
.../requests/CreateCustomPlanRequestBody.java | 232 +++
...stBillingProductMatchCompaniesRequest.java | 263 ++++
.../plans/requests/ListPlansRequest.java | 32 +
.../PublishPlanVersionRequestBody.java | 156 +-
...untBillingProductMatchCompaniesParams.java | 204 +++
...tBillingProductMatchCompaniesResponse.java | 156 ++
.../plans/types/CountPlansParams.java | 32 +
.../plans/types/CreateCustomPlanResponse.java | 181 +++
...istBillingProductMatchCompaniesParams.java | 204 +++
...tBillingProductMatchCompaniesResponse.java | 178 +++
.../plans/types/ListPlansParams.java | 32 +
.../UpsertPlanForBillingProductResponse.java | 182 +++
.../api/types/AccountMemberPermission.java | 229 +++
.../api/types/AccountMemberResponseData.java | 345 +++++
...lledByType.java => AccountMemberRole.java} | 38 +-
.../api/types/BillingCreditGrantReason.java | 11 +
.../BillingLinkedResourceResponseData.java | 170 +++
.../BillingPlanCreditGrantResponseData.java | 32 +
.../types/BillingProductPlanResponseData.java | 12 +-
.../api/types/BillingProviderType.java | 10 +
.../api/types/CheckoutSubscription.java | 32 +
.../api/types/CompanyDetailResponseData.java | 45 +
.../types/CompanyPlanDetailResponseData.java | 152 +-
...eateBillingPlanCreditGrantRequestBody.java | 32 +
.../CreateEntitlementInBundleRequestBody.java | 32 +
...dateConditionRequestBodyConditionType.java | 11 +
.../api/types/CreatePlanRequestBody.java | 16 +-
.../api/types/CurrencyPriceRequestBody.java | 318 ++++
.../types/CustomPlanActivationStrategy.java | 86 ++
.../types/CustomPlanBillingResponseData.java | 413 +++++
.../api/types/CustomPlanBillingStatus.java | 104 ++
.../api/types/DatastreamCompanyPlan.java | 43 +-
.../api/types/FeatureDetailResponseData.java | 34 +-
.../com/schematic/api/types/FeatureView.java | 32 +
.../schematic/api/types/IntegrationType.java | 103 ++
.../IntegrationWebhookUrlResponseData.java | 141 ++
.../api/types/PlanCreditGrantView.java | 33 +
.../api/types/PlanDetailResponseData.java | 152 +-
.../types/PlanEntitlementResponseData.java | 34 +-
.../PlanGroupPlanDetailResponseData.java | 152 +-
.../com/schematic/api/types/PlanIcon.java | 312 ++++
.../schematic/api/types/PlanResponseData.java | 86 +-
.../api/types/PlanVersionResponseData.java | 12 +-
.../api/types/PlanViewPublicResponseData.java | 152 +-
.../api/types/RulesEngineSchemaVersion.java | 16 +-
.../com/schematic/api/types/TrialStatus.java | 92 ++
...dateBillingPlanCreditGrantRequestBody.java | 32 +
.../api/types/UpdatePlanRequestBody.java | 16 +-
.../UsageBasedEntitlementRequestBody.java | 26 +
.../com/schematic/api/types/WebhookUrl.java | 140 ++
108 files changed, 13163 insertions(+), 421 deletions(-)
create mode 100644 src/main/java/com/schematic/api/resources/accounts/requests/ListAccountMembersRequest.java
create mode 100644 src/main/java/com/schematic/api/resources/accounts/types/GetAccountMemberResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/accounts/types/ListAccountMembersParams.java
create mode 100644 src/main/java/com/schematic/api/resources/accounts/types/ListAccountMembersResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/credits/types/GetSingleBillingPlanCreditGrantResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/entitlements/requests/CreateBillingLinkedPlanEntitlementRequestBody.java
create mode 100644 src/main/java/com/schematic/api/resources/entitlements/types/CreateBillingLinkedPlanEntitlementRequestBodyMetricPeriod.java
create mode 100644 src/main/java/com/schematic/api/resources/entitlements/types/CreateBillingLinkedPlanEntitlementRequestBodyMetricPeriodMonthReset.java
create mode 100644 src/main/java/com/schematic/api/resources/entitlements/types/UpsertPlanEntitlementForBillingProductResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/features/requests/CreateBillingLinkedFeatureRequestBody.java
create mode 100644 src/main/java/com/schematic/api/resources/features/types/UpsertFeatureForBillingProductResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/integrationsapi/AsyncIntegrationsapiClient.java
create mode 100644 src/main/java/com/schematic/api/resources/integrationsapi/AsyncRawIntegrationsapiClient.java
create mode 100644 src/main/java/com/schematic/api/resources/integrationsapi/IntegrationsapiClient.java
create mode 100644 src/main/java/com/schematic/api/resources/integrationsapi/RawIntegrationsapiClient.java
create mode 100644 src/main/java/com/schematic/api/resources/integrationsapi/types/GetIntegrationWebhookUrlResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/requests/CountBillingProductMatchCompaniesRequest.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/requests/CreateBillingLinkedPlanRequestBody.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/requests/CreateCustomPlanRequestBody.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/requests/ListBillingProductMatchCompaniesRequest.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/types/CountBillingProductMatchCompaniesParams.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/types/CountBillingProductMatchCompaniesResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/types/CreateCustomPlanResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/types/ListBillingProductMatchCompaniesParams.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/types/ListBillingProductMatchCompaniesResponse.java
create mode 100644 src/main/java/com/schematic/api/resources/plans/types/UpsertPlanForBillingProductResponse.java
create mode 100644 src/main/java/com/schematic/api/types/AccountMemberPermission.java
create mode 100644 src/main/java/com/schematic/api/types/AccountMemberResponseData.java
rename src/main/java/com/schematic/api/types/{PlanControlledByType.java => AccountMemberRole.java} (55%)
create mode 100644 src/main/java/com/schematic/api/types/BillingLinkedResourceResponseData.java
create mode 100644 src/main/java/com/schematic/api/types/CurrencyPriceRequestBody.java
create mode 100644 src/main/java/com/schematic/api/types/CustomPlanActivationStrategy.java
create mode 100644 src/main/java/com/schematic/api/types/CustomPlanBillingResponseData.java
create mode 100644 src/main/java/com/schematic/api/types/CustomPlanBillingStatus.java
create mode 100644 src/main/java/com/schematic/api/types/IntegrationType.java
create mode 100644 src/main/java/com/schematic/api/types/IntegrationWebhookUrlResponseData.java
create mode 100644 src/main/java/com/schematic/api/types/PlanIcon.java
create mode 100644 src/main/java/com/schematic/api/types/TrialStatus.java
create mode 100644 src/main/java/com/schematic/api/types/WebhookUrl.java
diff --git a/.fern/metadata.json b/.fern/metadata.json
index 8d2fe62..f2055c4 100644
--- a/.fern/metadata.json
+++ b/.fern/metadata.json
@@ -1,5 +1,5 @@
{
- "cliVersion": "4.43.1",
+ "cliVersion": "4.76.1",
"generatorName": "fernapi/fern-java-sdk",
"generatorVersion": "3.44.6",
"generatorConfig": {
@@ -11,6 +11,6 @@
"testImplementation org.mockito:mockito-junit-jupiter:5.3.1"
]
},
- "originGitCommit": "2717563b79232180e36aa245da14c045650ea31b",
- "sdkVersion": "1.3.1"
+ "originGitCommit": "3984203f8f49616dfdae68590f4b291c18ca1151",
+ "sdkVersion": "1.4.0"
}
\ No newline at end of file
diff --git a/build.gradle b/build.gradle
index 29c05bb..2c63ce4 100644
--- a/build.gradle
+++ b/build.gradle
@@ -49,7 +49,7 @@ java {
group = 'com.schematichq'
-version = '1.3.1'
+version = '1.4.0'
jar {
dependsOn(":generatePomFileForMavenPublication")
@@ -80,7 +80,7 @@ publishing {
maven(MavenPublication) {
groupId = 'com.schematichq'
artifactId = 'schematic-java'
- version = '1.3.1'
+ version = '1.4.0'
from components.java
pom {
name = 'Schematic'
diff --git a/reference.md b/reference.md
index 1c3e10b..2c6f5b4 100644
--- a/reference.md
+++ b/reference.md
@@ -80,6 +80,120 @@ client.deletePlanAudiencesPlanAudienceId("plan_audience_id");
## accounts
+client.accounts.listAccountMembers() -> ListAccountMembersResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.accounts().listAccountMembers(
+ ListAccountMembersRequest
+ .builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .q("q")
+ .limit(1000000L)
+ .offset(1000000L)
+ .build()
+);
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**ids:** `Optional`
+
+
+
+
+
+-
+
+**q:** `Optional` — Search filter
+
+
+
+
+
+-
+
+**limit:** `Optional` — Page limit (default 100)
+
+
+
+
+
+-
+
+**offset:** `Optional` — Page offset (default 0)
+
+
+
+
+
+
+
+
+
+
+
+client.accounts.getAccountMember(accountMemberId) -> GetAccountMemberResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.accounts().getAccountMember("account_member_id");
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**accountMemberId:** `String` — account_member_id
+
+
+
+
+
+
+
+
+
+
+
client.accounts.listApiKeys() -> ListApiKeysResponse
-
@@ -688,6 +802,9 @@ client.accounts().countAuditLogs(
client.accounts().listEnvironments(
ListEnvironmentsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.limit(1000000L)
.offset(1000000L)
.build()
@@ -1284,8 +1401,11 @@ client.billing().upsertBillingCustomer(
client.billing().listCustomersWithSubscriptions(
ListCustomersWithSubscriptionsRequest
.builder()
+ .companyIds(
+ Arrays.asList("company_ids")
+ )
.name("name")
- .providerType(BillingProviderType.SCHEMATIC)
+ .providerType(BillingProviderType.ORB)
.q("q")
.limit(1000000L)
.offset(1000000L)
@@ -1373,8 +1493,11 @@ client.billing().listCustomersWithSubscriptions(
client.billing().countCustomers(
CountCustomersRequest
.builder()
+ .companyIds(
+ Arrays.asList("company_ids")
+ )
.name("name")
- .providerType(BillingProviderType.SCHEMATIC)
+ .providerType(BillingProviderType.ORB)
.q("q")
.limit(1000000L)
.offset(1000000L)
@@ -1799,6 +1922,14 @@ client.billing().upsertBillingMeter(
**externalId:** `String`
+
+
+
+
+-
+
+**providerType:** `Optional`
+
@@ -2032,6 +2163,12 @@ client.billing().upsertPaymentMethod(
client.billing().listBillingPrices(
ListBillingPricesRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .productIds(
+ Arrays.asList("product_ids")
+ )
.currency("currency")
.forInitialPlan(true)
.forTrialExpiryPlan(true)
@@ -2039,7 +2176,7 @@ client.billing().listBillingPrices(
.isActive(true)
.price(1000000L)
.productId("product_id")
- .providerType(BillingProviderType.SCHEMATIC)
+ .providerType(BillingProviderType.ORB)
.q("q")
.tiersMode(BillingTiersMode.GRADUATED)
.usageType(BillingPriceUsageType.LICENSED)
@@ -2423,6 +2560,12 @@ client.billing().deleteBillingProduct("billing_id");
client.billing().listBillingProductPrices(
ListBillingProductPricesRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .productIds(
+ Arrays.asList("product_ids")
+ )
.currency("currency")
.forInitialPlan(true)
.forTrialExpiryPlan(true)
@@ -2430,7 +2573,7 @@ client.billing().listBillingProductPrices(
.isActive(true)
.price(1000000L)
.productId("product_id")
- .providerType(BillingProviderType.SCHEMATIC)
+ .providerType(BillingProviderType.ORB)
.q("q")
.tiersMode(BillingTiersMode.GRADUATED)
.usageType(BillingPriceUsageType.LICENSED)
@@ -2719,10 +2862,13 @@ client.billing().upsertBillingProduct(
client.billing().listBillingProducts(
ListBillingProductsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.isActive(true)
.name("name")
.priceUsageType(BillingPriceUsageType.LICENSED)
- .providerType(BillingProviderType.SCHEMATIC)
+ .providerType(BillingProviderType.ORB)
.q("q")
.withOneTimeCharges(true)
.withPricesOnly(true)
@@ -2862,10 +3008,13 @@ client.billing().listBillingProducts(
client.billing().countBillingProducts(
CountBillingProductsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.isActive(true)
.name("name")
.priceUsageType(BillingPriceUsageType.LICENSED)
- .providerType(BillingProviderType.SCHEMATIC)
+ .providerType(BillingProviderType.ORB)
.q("q")
.withOneTimeCharges(true)
.withPricesOnly(true)
@@ -3164,6 +3313,14 @@ client.billing().upsertBillingSubscription(
-
+**providerType:** `Optional`
+
+
+
+
+
+-
+
**status:** `Optional`
@@ -3225,6 +3382,9 @@ client.billing().upsertBillingSubscription(
client.credits().listBillingCredits(
ListBillingCreditsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.name("name")
.limit(1000000L)
.offset(1000000L)
@@ -3662,6 +3822,9 @@ client.credits().softDeleteBillingCredit("credit_id");
client.credits().listCreditBundles(
ListCreditBundlesRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.creditId("credit_id")
.status(BillingCreditBundleStatus.ACTIVE)
.bundleType("fixed")
@@ -4086,6 +4249,9 @@ client.credits().deleteCreditBundle("bundle_id");
client.credits().countCreditBundles(
CountCreditBundlesRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.creditId("credit_id")
.status(BillingCreditBundleStatus.ACTIVE)
.bundleType("fixed")
@@ -4175,6 +4341,9 @@ client.credits().countCreditBundles(
client.credits().countBillingCredits(
CountBillingCreditsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.name("name")
.limit(1000000L)
.offset(1000000L)
@@ -4302,7 +4471,7 @@ client.credits().grantBillingCreditsToCompany(
.companyId("company_id")
.creditId("credit_id")
.quantity(1000000L)
- .reason(BillingCreditGrantReason.BILLING_CREDIT_AUTO_TOPUP)
+ .reason(BillingCreditGrantReason.ADJUSTMENT)
.build()
);
```
@@ -4597,6 +4766,9 @@ client.credits().listCompanyGrants(
client.credits().countBillingCreditsGrants(
CountBillingCreditsGrantsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.creditId("credit_id")
.limit(1000000L)
.offset(1000000L)
@@ -4668,6 +4840,9 @@ client.credits().countBillingCreditsGrants(
client.credits().listGrantsForCredit(
ListGrantsForCreditRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.creditId("credit_id")
.limit(1000000L)
.offset(1000000L)
@@ -4955,6 +5130,12 @@ client.credits().countCreditLedger(
client.credits().listBillingPlanCreditGrants(
ListBillingPlanCreditGrantsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .planIds(
+ Arrays.asList("plan_ids")
+ )
.creditId("credit_id")
.planId("plan_id")
.planVersionId("plan_version_id")
@@ -5081,6 +5262,46 @@ client.credits().createBillingPlanCreditGrant(
+
+
+
+
+client.credits.getSingleBillingPlanCreditGrant(planGrantId) -> GetSingleBillingPlanCreditGrantResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.credits().getSingleBillingPlanCreditGrant("plan_grant_id");
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**planGrantId:** `String` — plan_grant_id
+
+
+
+
+
+
+
@@ -5210,6 +5431,12 @@ client.credits().deleteBillingPlanCreditGrant(
client.credits().countBillingPlanCreditGrants(
CountBillingPlanCreditGrantsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .planIds(
+ Arrays.asList("plan_ids")
+ )
.creditId("credit_id")
.planId("plan_id")
.planVersionId("plan_version_id")
@@ -5984,6 +6211,22 @@ client.checkout().updateCustomerSubscriptionTrialEnd(
client.companies().listCompanies(
ListCompaniesRequest
.builder()
+ .creditTypeIds(
+ Arrays.asList("credit_type_ids")
+ )
+ .ids(
+ Arrays.asList("ids")
+ )
+ .planIds(
+ Arrays.asList("plan_ids")
+ )
+ .subscriptionStatuses(
+ Arrays.asList(SubscriptionStatus.ACTIVE)
+ )
+ .subscriptionTypes(
+ Arrays.asList(SubscriptionType.FREE)
+ )
+ .hasScheduledDowngrade(true)
.monetizedSubscriptions(true)
.planId("plan_id")
.planVersionId("plan_version_id")
@@ -6021,6 +6264,14 @@ client.companies().listCompanies(
-
+**hasScheduledDowngrade:** `Optional` — Filter companies that have a pending scheduled downgrade
+
+
+
+
+
+-
+
**ids:** `Optional` — Filter companies by multiple company IDs (starts with comp_)
@@ -6329,6 +6580,22 @@ client.companies().deleteCompany(
client.companies().countCompanies(
CountCompaniesRequest
.builder()
+ .creditTypeIds(
+ Arrays.asList("credit_type_ids")
+ )
+ .ids(
+ Arrays.asList("ids")
+ )
+ .planIds(
+ Arrays.asList("plan_ids")
+ )
+ .subscriptionStatuses(
+ Arrays.asList(SubscriptionStatus.ACTIVE)
+ )
+ .subscriptionTypes(
+ Arrays.asList(SubscriptionType.FREE)
+ )
+ .hasScheduledDowngrade(true)
.monetizedSubscriptions(true)
.planId("plan_id")
.planVersionId("plan_version_id")
@@ -6366,6 +6633,14 @@ client.companies().countCompanies(
-
+**hasScheduledDowngrade:** `Optional` — Filter companies that have a pending scheduled downgrade
+
+
+
+
+
+-
+
**ids:** `Optional` — Filter companies by multiple company IDs (starts with comp_)
@@ -6853,6 +7128,9 @@ client.companies().deleteCompanyMembership("company_membership_id");
client.companies().getActiveCompanySubscription(
GetActiveCompanySubscriptionRequest
.builder()
+ .companyIds(
+ Arrays.asList("company_ids")
+ )
.companyId("company_id")
.limit(1000000L)
.offset(1000000L)
@@ -6974,6 +7252,9 @@ client.companies().upsertCompanyTrait(
client.companies().listEntityKeyDefinitions(
ListEntityKeyDefinitionsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.entityType(EntityType.COMPANY)
.q("q")
.limit(1000000L)
@@ -7054,6 +7335,9 @@ client.companies().listEntityKeyDefinitions(
client.companies().countEntityKeyDefinitions(
CountEntityKeyDefinitionsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.entityType(EntityType.COMPANY)
.q("q")
.limit(1000000L)
@@ -7134,6 +7418,12 @@ client.companies().countEntityKeyDefinitions(
client.companies().listEntityTraitDefinitions(
ListEntityTraitDefinitionsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .traitTypes(
+ Arrays.asList(TraitType.BOOLEAN)
+ )
.entityType(EntityType.COMPANY)
.q("q")
.traitType(TraitType.BOOLEAN)
@@ -7406,6 +7696,12 @@ client.companies().updateEntityTraitDefinition(
client.companies().countEntityTraitDefinitions(
CountEntityTraitDefinitionsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .traitTypes(
+ Arrays.asList(TraitType.BOOLEAN)
+ )
.entityType(EntityType.COMPANY)
.q("q")
.traitType(TraitType.BOOLEAN)
@@ -7575,8 +7871,14 @@ client.companies().getEntityTraitValues(
client.companies().listPlanChanges(
ListPlanChangesRequest
.builder()
- .action("action")
- .basePlanAction("base_plan_action")
+ .companyIds(
+ Arrays.asList("company_ids")
+ )
+ .planIds(
+ Arrays.asList("plan_ids")
+ )
+ .action(PlanChangeAction.CHECKOUT)
+ .basePlanAction(PlanChangeBasePlanAction.FALLBACK)
.companyId("company_id")
.limit(1000000L)
.offset(1000000L)
@@ -7596,7 +7898,7 @@ client.companies().listPlanChanges(
-
-**action:** `Optional`
+**action:** `Optional`
@@ -7604,7 +7906,7 @@ client.companies().listPlanChanges(
-
-**basePlanAction:** `Optional`
+**basePlanAction:** `Optional`
@@ -7712,6 +8014,12 @@ client.companies().getPlanChange("plan_change_id");
client.companies().listPlanTraits(
ListPlanTraitsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .traitIds(
+ Arrays.asList("trait_ids")
+ )
.planId("plan_id")
.traitId("trait_id")
.limit(1000000L)
@@ -8077,6 +8385,12 @@ client.companies().updatePlanTraitsBulk(
client.companies().countPlanTraits(
CountPlanTraitsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
+ .traitIds(
+ Arrays.asList("trait_ids")
+ )
.planId("plan_id")
.traitId("trait_id")
.limit(1000000L)
@@ -8215,6 +8529,9 @@ client.companies().upsertUserTrait(
client.companies().listUsers(
ListUsersRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.companyId("company_id")
.planId("plan_id")
.q("q")
@@ -8433,6 +8750,9 @@ client.companies().deleteUser("user_id");
client.companies().countUsers(
CountUsersRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.companyId("company_id")
.planId("plan_id")
.q("q")
@@ -8670,6 +8990,15 @@ client.companies().lookupUser(
client.entitlements().listCompanyOverrides(
ListCompanyOverridesRequest
.builder()
+ .companyIds(
+ Arrays.asList("company_ids")
+ )
+ .featureIds(
+ Arrays.asList("feature_ids")
+ )
+ .ids(
+ Arrays.asList("ids")
+ )
.companyId("company_id")
.featureId("feature_id")
.withoutExpired(true)
@@ -9125,6 +9454,15 @@ client.entitlements().deleteCompanyOverride("company_override_id");
client.entitlements().countCompanyOverrides(
CountCompanyOverridesRequest
.builder()
+ .companyIds(
+ Arrays.asList("company_ids")
+ )
+ .featureIds(
+ Arrays.asList("feature_ids")
+ )
+ .ids(
+ Arrays.asList("ids")
+ )
.companyId("company_id")
.featureId("feature_id")
.withoutExpired(true)
@@ -9383,6 +9721,9 @@ client.entitlements().countFeatureCompanies(
client.entitlements().listFeatureUsage(
ListFeatureUsageRequest
.builder()
+ .featureIds(
+ Arrays.asList("feature_ids")
+ )
.companyId("company_id")
.includeUsageAggregation(true)
.q("q")
@@ -9570,6 +9911,9 @@ client.entitlements().getFeatureUsageTimeSeries(
client.entitlements().countFeatureUsage(
CountFeatureUsageRequest
.builder()
+ .featureIds(
+ Arrays.asList("feature_ids")
+ )
.companyId("company_id")
.includeUsageAggregation(true)
.q("q")
@@ -9820,6 +10164,18 @@ client.entitlements().countFeatureUsers(
client.entitlements().listPlanEntitlements(
ListPlanEntitlementsRequest
.builder()
+ .featureIds(
+ Arrays.asList("feature_ids")
+ )
+ .ids(
+ Arrays.asList("ids")
+ )
+ .planIds(
+ Arrays.asList("plan_ids")
+ )
+ .planVersionIds(
+ Arrays.asList("plan_version_ids")
+ )
.featureId("feature_id")
.planId("plan_id")
.planVersionId("plan_version_id")
@@ -10002,6 +10358,14 @@ client.entitlements().createPlanEntitlement(
-
+**currencyPrices:** `Optional
>`
+
+
+
+
+
+-
+
**featureId:** `String`
@@ -10304,6 +10668,14 @@ client.entitlements().updatePlanEntitlement(
-
+**currencyPrices:** `Optional
>`
+
+
+
+
+
+-
+
**metricPeriod:** `Optional`
@@ -10508,7 +10880,7 @@ client.entitlements().deletePlanEntitlement("plan_entitlement_id");
-client.entitlements.countPlanEntitlements() -> CountPlanEntitlementsResponse
+client.entitlements.upsertPlanEntitlementForBillingProduct(request) -> UpsertPlanEntitlementForBillingProductResponse
-
@@ -10521,16 +10893,14 @@ client.entitlements().deletePlanEntitlement("plan_entitlement_id");
-
```java
-client.entitlements().countPlanEntitlements(
- CountPlanEntitlementsRequest
+client.entitlements().upsertPlanEntitlementForBillingProduct(
+ CreateBillingLinkedPlanEntitlementRequestBody
.builder()
+ .billingProvider(BillingProviderType.ORB)
+ .externalResourceId("external_resource_id")
.featureId("feature_id")
.planId("plan_id")
- .planVersionId("plan_version_id")
- .q("q")
- .withMeteredProducts(true)
- .limit(1000000L)
- .offset(1000000L)
+ .valueType(EntitlementValueType.BOOLEAN)
.build()
);
```
@@ -10547,7 +10917,7 @@ client.entitlements().countPlanEntitlements(
-
-**featureId:** `Optional` — Filter plan entitlements by a single feature ID (starting with feat_)
+**billingProductId:** `Optional`
@@ -10555,7 +10925,7 @@ client.entitlements().countPlanEntitlements(
-
-**featureIds:** `Optional` — Filter plan entitlements by multiple feature IDs (starting with feat_)
+**billingProvider:** `BillingProviderType`
@@ -10563,7 +10933,302 @@ client.entitlements().countPlanEntitlements(
-
-**ids:** `Optional` — Filter plan entitlements by multiple plan entitlement IDs (starting with pltl_)
+**billingThreshold:** `Optional`
+
+
+
+
+
+-
+
+**creditConsumptionRate:** `Optional`
+
+
+
+
+
+-
+
+**currency:** `Optional`
+
+
+
+
+
+-
+
+**currencyPrices:** `Optional
>`
+
+
+
+
+
+-
+
+**externalResourceId:** `String`
+
+
+
+
+
+-
+
+**featureId:** `String`
+
+
+
+
+
+-
+
+**metricPeriod:** `Optional`
+
+
+
+
+
+-
+
+**metricPeriodMonthReset:** `Optional`
+
+
+
+
+
+-
+
+**monthlyMeteredPriceId:** `Optional`
+
+
+
+
+
+-
+
+**monthlyPriceTiers:** `Optional
>`
+
+
+
+
+
+-
+
+**monthlyUnitPrice:** `Optional`
+
+
+
+
+
+-
+
+**monthlyUnitPriceDecimal:** `Optional`
+
+
+
+
+
+-
+
+**overageBillingProductId:** `Optional`
+
+
+
+
+
+-
+
+**planId:** `String`
+
+
+
+
+
+-
+
+**planVersionId:** `Optional`
+
+
+
+
+
+-
+
+**priceBehavior:** `Optional`
+
+
+
+
+
+-
+
+**priceTiers:** `Optional
>` — Use MonthlyPriceTiers or YearlyPriceTiers instead
+
+
+
+
+
+-
+
+**softLimit:** `Optional`
+
+
+
+
+
+-
+
+**tierMode:** `Optional`
+
+
+
+
+
+-
+
+**valueBool:** `Optional`
+
+
+
+
+
+-
+
+**valueCreditId:** `Optional`
+
+
+
+
+
+-
+
+**valueNumeric:** `Optional`
+
+
+
+
+
+-
+
+**valueTraitId:** `Optional`
+
+
+
+
+
+-
+
+**valueType:** `EntitlementValueType`
+
+
+
+
+
+-
+
+**yearlyMeteredPriceId:** `Optional`
+
+
+
+
+
+-
+
+**yearlyPriceTiers:** `Optional
>`
+
+
+
+
+
+-
+
+**yearlyUnitPrice:** `Optional`
+
+
+
+
+
+-
+
+**yearlyUnitPriceDecimal:** `Optional`
+
+
+
+
+
+
+
+
+
+
+
+client.entitlements.countPlanEntitlements() -> CountPlanEntitlementsResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.entitlements().countPlanEntitlements(
+ CountPlanEntitlementsRequest
+ .builder()
+ .featureIds(
+ Arrays.asList("feature_ids")
+ )
+ .ids(
+ Arrays.asList("ids")
+ )
+ .planIds(
+ Arrays.asList("plan_ids")
+ )
+ .planVersionIds(
+ Arrays.asList("plan_version_ids")
+ )
+ .featureId("feature_id")
+ .planId("plan_id")
+ .planVersionId("plan_version_id")
+ .q("q")
+ .withMeteredProducts(true)
+ .limit(1000000L)
+ .offset(1000000L)
+ .build()
+);
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**featureId:** `Optional` — Filter plan entitlements by a single feature ID (starting with feat_)
+
+
+
+
+
+-
+
+**featureIds:** `Optional` — Filter plan entitlements by multiple feature IDs (starting with feat_)
+
+
+
+
+
+-
+
+**ids:** `Optional` — Filter plan entitlements by multiple plan entitlement IDs (starting with pltl_)
@@ -10779,7 +11444,70 @@ client.plans().updateCompanyPlans(
-
-**companyPlanId:** `String` — company_plan_id
+**companyPlanId:** `String` — company_plan_id
+
+
+
+
+
+-
+
+**addOnIds:** `List`
+
+
+
+
+
+-
+
+**basePlanId:** `Optional`
+
+
+
+
+
+
+
+
+
+
+
+client.plans.createCustomPlan(request) -> CreateCustomPlanResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.plans().createCustomPlan(
+ CreateCustomPlanRequestBody
+ .builder()
+ .companyId("company_id")
+ .description("description")
+ .name("name")
+ .build()
+);
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**companyId:** `String`
@@ -10787,7 +11515,7 @@ client.plans().updateCompanyPlans(
-
-**addOnIds:** `List`
+**copiedFromPlanId:** `Optional`
@@ -10795,7 +11523,23 @@ client.plans().updateCompanyPlans(
-
-**basePlanId:** `Optional`
+**description:** `String`
+
+
+
+
+
+-
+
+**icon:** `Optional`
+
+
+
+
+
+-
+
+**name:** `String`
@@ -10823,6 +11567,9 @@ client.plans().updateCompanyPlans(
client.plans().listPlans(
ListPlansRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.companyId("company_id")
.forFallbackPlan(true)
.forInitialPlan(true)
@@ -10831,6 +11578,7 @@ client.plans().listPlans(
.includeDraftVersions(true)
.planType(PlanType.PLAN)
.q("q")
+ .scopedToCompanyId("scoped_to_company_id")
.withoutEntitlementFor("without_entitlement_for")
.withoutPaidProductId(true)
.limit(1000000L)
@@ -10923,6 +11671,14 @@ client.plans().listPlans(
-
+**scopedToCompanyId:** `Optional` — Filter plans scoped to a specific company (custom plans)
+
+
+
+
+
+-
+
**withoutEntitlementFor:** `Optional` — Filter out plans that already have a plan entitlement for the specified feature ID
@@ -11205,6 +11961,239 @@ client.plans().upsertBillingProductPlan(
+
+
+
+
+client.plans.upsertPlanForBillingProduct(request) -> UpsertPlanForBillingProductResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.plans().upsertPlanForBillingProduct(
+ CreateBillingLinkedPlanRequestBody
+ .builder()
+ .billingProvider(BillingProviderType.ORB)
+ .description("description")
+ .externalResourceId("external_resource_id")
+ .name("name")
+ .planType(PlanType.PLAN)
+ .build()
+);
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**billingProvider:** `BillingProviderType`
+
+
+
+
+
+-
+
+**description:** `String`
+
+
+
+
+
+-
+
+**externalResourceId:** `String`
+
+
+
+
+
+-
+
+**icon:** `Optional`
+
+
+
+
+
+-
+
+**name:** `String`
+
+
+
+
+
+-
+
+**planType:** `PlanType`
+
+
+
+
+
+
+
+
+
+
+
+client.plans.listBillingProductMatchCompanies() -> ListBillingProductMatchCompaniesResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.plans().listBillingProductMatchCompanies(
+ ListBillingProductMatchCompaniesRequest
+ .builder()
+ .planId("plan_id")
+ .q("q")
+ .limit(1000000L)
+ .offset(1000000L)
+ .build()
+);
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**planId:** `String` — The plan ID to find billing product match companies for
+
+
+
+
+
+-
+
+**q:** `Optional` — Search for companies by name, keys or string traits
+
+
+
+
+
+-
+
+**limit:** `Optional` — Page limit (default 100)
+
+
+
+
+
+-
+
+**offset:** `Optional` — Page offset (default 0)
+
+
+
+
+
+
+
+
+
+
+
+client.plans.countBillingProductMatchCompanies() -> CountBillingProductMatchCompaniesResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.plans().countBillingProductMatchCompanies(
+ CountBillingProductMatchCompaniesRequest
+ .builder()
+ .planId("plan_id")
+ .q("q")
+ .limit(1000000L)
+ .offset(1000000L)
+ .build()
+);
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**planId:** `String` — The plan ID to find billing product match companies for
+
+
+
+
+
+-
+
+**q:** `Optional` — Search for companies by name, keys or string traits
+
+
+
+
+
+-
+
+**limit:** `Optional` — Page limit (default 100)
+
+
+
+
+
+-
+
+**offset:** `Optional` — Page offset (default 0)
+
+
+
+
+
+
+
@@ -11225,6 +12214,9 @@ client.plans().upsertBillingProductPlan(
client.plans().countPlans(
CountPlansRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.companyId("company_id")
.forFallbackPlan(true)
.forInitialPlan(true)
@@ -11233,6 +12225,7 @@ client.plans().countPlans(
.includeDraftVersions(true)
.planType(PlanType.PLAN)
.q("q")
+ .scopedToCompanyId("scoped_to_company_id")
.withoutEntitlementFor("without_entitlement_for")
.withoutPaidProductId(true)
.limit(1000000L)
@@ -11317,7 +12310,15 @@ client.plans().countPlans(
-
-**q:** `Optional`
+**q:** `Optional`
+
+
+
+
+
+-
+
+**scopedToCompanyId:** `Optional` — Filter plans scoped to a specific company (custom plans)
@@ -11490,6 +12491,15 @@ client.plans().publishPlanVersion(
.excludedCompanyIds(
Arrays.asList("excluded_company_ids")
)
+ .payInAdvance(
+ Arrays.asList(
+ UpdatePayInAdvanceRequestBody
+ .builder()
+ .priceId("price_id")
+ .quantity(1000000L)
+ .build()
+ )
+ )
.build()
);
```
@@ -11514,6 +12524,30 @@ client.plans().publishPlanVersion(
-
+**activationStrategy:** `Optional`
+
+
+
+
+
+-
+
+**customerEmail:** `Optional`
+
+
+
+
+
+-
+
+**daysUntilDue:** `Optional`
+
+
+
+
+
+-
+
**excludedCompanyIds:** `List`
@@ -11524,6 +12558,14 @@ client.plans().publishPlanVersion(
**migrationStrategy:** `PlanVersionMigrationStrategy`
+
+
+
+
+-
+
+**payInAdvance:** `List`
+
@@ -12107,6 +13149,9 @@ client.events().createEventBatch(
client.events().getEventSummaries(
GetEventSummariesRequest
.builder()
+ .eventSubtypes(
+ Arrays.asList("event_subtypes")
+ )
.q("q")
.limit(1000000L)
.offset(1000000L)
@@ -12178,6 +13223,9 @@ client.events().getEventSummaries(
client.events().listEvents(
ListEventsRequest
.builder()
+ .eventTypes(
+ Arrays.asList(EventType.FLAG_CHECK)
+ )
.companyId("company_id")
.eventSubtype("event_subtype")
.flagId("flag_id")
@@ -12387,11 +13435,17 @@ client.events().getSegmentIntegrationStatus();
client.features().listFeatures(
ListFeaturesRequest
.builder()
+ .featureType(
+ Arrays.asList(FeatureType.BOOLEAN)
+ )
+ .ids(
+ Arrays.asList("ids")
+ )
+ .booleanRequireEvent(true)
+ .planVersionId("plan_version_id")
.q("q")
.withoutCompanyOverrideFor("without_company_override_for")
- .planVersionId("plan_version_id")
.withoutPlanEntitlementFor("without_plan_entitlement_for")
- .booleanRequireEvent(true)
.limit(1000000L)
.offset(1000000L)
.build()
@@ -12410,7 +13464,7 @@ client.features().listFeatures(
-
-**ids:** `Optional`
+**booleanRequireEvent:** `Optional` — Only return boolean features if there is an associated event. Automatically includes boolean in the feature types filter.
@@ -12418,7 +13472,7 @@ client.features().listFeatures(
-
-**q:** `Optional` — Search by feature name or ID
+**featureType:** `Optional` — Filter by one or more feature types (boolean, event, trait)
@@ -12426,7 +13480,7 @@ client.features().listFeatures(
-
-**withoutCompanyOverrideFor:** `Optional` — Filter out features that already have a company override for the specified company ID
+**ids:** `Optional`
@@ -12442,7 +13496,7 @@ client.features().listFeatures(
-
-**withoutPlanEntitlementFor:** `Optional` — Filter out features that already have a plan entitlement for the specified plan ID
+**q:** `Optional` — Search by feature name or ID
@@ -12450,7 +13504,7 @@ client.features().listFeatures(
-
-**featureType:** `Optional` — Filter by one or more feature types (boolean, event, trait)
+**withoutCompanyOverrideFor:** `Optional` — Filter out features that already have a company override for the specified company ID
@@ -12458,7 +13512,7 @@ client.features().listFeatures(
-
-**booleanRequireEvent:** `Optional` — Only return boolean features if there is an associated event. Automatically includes boolean in the feature types filter.
+**withoutPlanEntitlementFor:** `Optional` — Filter out features that already have a plan entitlement for the specified plan ID
@@ -12822,6 +13876,151 @@ client.features().deleteFeature("feature_id");
+
+
+
+
+client.features.upsertFeatureForBillingProduct(request) -> UpsertFeatureForBillingProductResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.features().upsertFeatureForBillingProduct(
+ CreateBillingLinkedFeatureRequestBody
+ .builder()
+ .billingProvider(BillingProviderType.ORB)
+ .description("description")
+ .externalResourceId("external_resource_id")
+ .featureType(FeatureType.BOOLEAN)
+ .name("name")
+ .build()
+);
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**billingProvider:** `BillingProviderType`
+
+
+
+
+
+-
+
+**description:** `String`
+
+
+
+
+
+-
+
+**eventSubtype:** `Optional`
+
+
+
+
+
+-
+
+**externalResourceId:** `String`
+
+
+
+
+
+-
+
+**featureType:** `FeatureType`
+
+
+
+
+
+-
+
+**flag:** `Optional`
+
+
+
+
+
+-
+
+**icon:** `Optional`
+
+
+
+
+
+-
+
+**lifecyclePhase:** `Optional`
+
+
+
+
+
+-
+
+**maintainerId:** `Optional`
+
+
+
+
+
+-
+
+**name:** `String`
+
+
+
+
+
+-
+
+**pluralName:** `Optional`
+
+
+
+
+
+-
+
+**singularName:** `Optional`
+
+
+
+
+
+-
+
+**traitId:** `Optional`
+
+
+
+
+
+
+
@@ -12842,11 +14041,17 @@ client.features().deleteFeature("feature_id");
client.features().countFeatures(
CountFeaturesRequest
.builder()
+ .featureType(
+ Arrays.asList(FeatureType.BOOLEAN)
+ )
+ .ids(
+ Arrays.asList("ids")
+ )
+ .booleanRequireEvent(true)
+ .planVersionId("plan_version_id")
.q("q")
.withoutCompanyOverrideFor("without_company_override_for")
- .planVersionId("plan_version_id")
.withoutPlanEntitlementFor("without_plan_entitlement_for")
- .booleanRequireEvent(true)
.limit(1000000L)
.offset(1000000L)
.build()
@@ -12865,7 +14070,7 @@ client.features().countFeatures(
-
-**ids:** `Optional`
+**booleanRequireEvent:** `Optional` — Only return boolean features if there is an associated event. Automatically includes boolean in the feature types filter.
@@ -12873,7 +14078,7 @@ client.features().countFeatures(
-
-**q:** `Optional` — Search by feature name or ID
+**featureType:** `Optional` — Filter by one or more feature types (boolean, event, trait)
@@ -12881,7 +14086,7 @@ client.features().countFeatures(
-
-**withoutCompanyOverrideFor:** `Optional` — Filter out features that already have a company override for the specified company ID
+**ids:** `Optional`
@@ -12897,7 +14102,7 @@ client.features().countFeatures(
-
-**withoutPlanEntitlementFor:** `Optional` — Filter out features that already have a plan entitlement for the specified plan ID
+**q:** `Optional` — Search by feature name or ID
@@ -12905,7 +14110,7 @@ client.features().countFeatures(
-
-**featureType:** `Optional` — Filter by one or more feature types (boolean, event, trait)
+**withoutCompanyOverrideFor:** `Optional` — Filter out features that already have a company override for the specified company ID
@@ -12913,7 +14118,7 @@ client.features().countFeatures(
-
-**booleanRequireEvent:** `Optional` — Only return boolean features if there is an associated event. Automatically includes boolean in the feature types filter.
+**withoutPlanEntitlementFor:** `Optional` — Filter out features that already have a plan entitlement for the specified plan ID
@@ -12957,6 +14162,9 @@ client.features().countFeatures(
client.features().listFlags(
ListFlagsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.featureId("feature_id")
.q("q")
.limit(1000000L)
@@ -13466,6 +14674,9 @@ client.features().checkFlagsBulk(
client.features().countFlags(
CountFlagsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.featureId("feature_id")
.q("q")
.limit(1000000L)
@@ -13526,6 +14737,47 @@ client.features().countFlags(
+
+
+
+
+## integrationsapi
+client.integrationsapi.getIntegrationWebhookUrl(type) -> GetIntegrationWebhookUrlResponse
+
+-
+
+#### 🔌 Usage
+
+
+-
+
+
+-
+
+```java
+client.integrationsapi().getIntegrationWebhookUrl("type");
+```
+
+
+
+
+
+#### ⚙️ Parameters
+
+
+-
+
+
+-
+
+**type:** `String` — type
+
+
+
+
+
+
+
@@ -15132,6 +16384,9 @@ client.accesstokens().issueTemporaryAccessToken(
client.webhooks().listWebhookEvents(
ListWebhookEventsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.q("q")
.webhookId("webhook_id")
.limit(1000000L)
@@ -15252,6 +16507,9 @@ client.webhooks().getWebhookEvent("webhook_event_id");
client.webhooks().countWebhookEvents(
CountWebhookEventsRequest
.builder()
+ .ids(
+ Arrays.asList("ids")
+ )
.q("q")
.webhookId("webhook_id")
.limit(1000000L)
diff --git a/src/main/java/com/schematic/api/AsyncBaseSchematic.java b/src/main/java/com/schematic/api/AsyncBaseSchematic.java
index 77df3d5..96e4c27 100644
--- a/src/main/java/com/schematic/api/AsyncBaseSchematic.java
+++ b/src/main/java/com/schematic/api/AsyncBaseSchematic.java
@@ -18,6 +18,7 @@
import com.schematic.api.resources.entitlements.AsyncEntitlementsClient;
import com.schematic.api.resources.events.AsyncEventsClient;
import com.schematic.api.resources.features.AsyncFeaturesClient;
+import com.schematic.api.resources.integrationsapi.AsyncIntegrationsapiClient;
import com.schematic.api.resources.planbundle.AsyncPlanbundleClient;
import com.schematic.api.resources.plangroups.AsyncPlangroupsClient;
import com.schematic.api.resources.planmigrations.AsyncPlanmigrationsClient;
@@ -54,6 +55,8 @@ public class AsyncBaseSchematic {
protected final Supplier featuresClient;
+ protected final Supplier integrationsapiClient;
+
protected final Supplier planbundleClient;
protected final Supplier plangroupsClient;
@@ -82,6 +85,7 @@ public AsyncBaseSchematic(ClientOptions clientOptions) {
this.dataexportsClient = Suppliers.memoize(() -> new AsyncDataexportsClient(clientOptions));
this.eventsClient = Suppliers.memoize(() -> new AsyncEventsClient(clientOptions));
this.featuresClient = Suppliers.memoize(() -> new AsyncFeaturesClient(clientOptions));
+ this.integrationsapiClient = Suppliers.memoize(() -> new AsyncIntegrationsapiClient(clientOptions));
this.planbundleClient = Suppliers.memoize(() -> new AsyncPlanbundleClient(clientOptions));
this.plangroupsClient = Suppliers.memoize(() -> new AsyncPlangroupsClient(clientOptions));
this.planmigrationsClient = Suppliers.memoize(() -> new AsyncPlanmigrationsClient(clientOptions));
@@ -164,6 +168,10 @@ public AsyncFeaturesClient features() {
return this.featuresClient.get();
}
+ public AsyncIntegrationsapiClient integrationsapi() {
+ return this.integrationsapiClient.get();
+ }
+
public AsyncPlanbundleClient planbundle() {
return this.planbundleClient.get();
}
diff --git a/src/main/java/com/schematic/api/core/ClientOptions.java b/src/main/java/com/schematic/api/core/ClientOptions.java
index efb312f..b5d94b9 100644
--- a/src/main/java/com/schematic/api/core/ClientOptions.java
+++ b/src/main/java/com/schematic/api/core/ClientOptions.java
@@ -38,10 +38,10 @@ private ClientOptions(
this.headers.putAll(headers);
this.headers.putAll(new HashMap() {
{
- put("User-Agent", "com.schematichq:schematic-java/1.3.1");
+ put("User-Agent", "com.schematichq:schematic-java/1.4.0");
put("X-Fern-Language", "JAVA");
put("X-Fern-SDK-Name", "com.schematic.fern:api-sdk");
- put("X-Fern-SDK-Version", "1.3.1");
+ put("X-Fern-SDK-Version", "1.4.0");
}
});
this.headerSuppliers = headerSuppliers;
diff --git a/src/main/java/com/schematic/api/resources/accounts/AccountsClient.java b/src/main/java/com/schematic/api/resources/accounts/AccountsClient.java
index 4ddb1f1..9ecf136 100644
--- a/src/main/java/com/schematic/api/resources/accounts/AccountsClient.java
+++ b/src/main/java/com/schematic/api/resources/accounts/AccountsClient.java
@@ -9,6 +9,7 @@
import com.schematic.api.resources.accounts.requests.CountAuditLogsRequest;
import com.schematic.api.resources.accounts.requests.CreateApiKeyRequestBody;
import com.schematic.api.resources.accounts.requests.CreateEnvironmentRequestBody;
+import com.schematic.api.resources.accounts.requests.ListAccountMembersRequest;
import com.schematic.api.resources.accounts.requests.ListApiKeysRequest;
import com.schematic.api.resources.accounts.requests.ListAuditLogsRequest;
import com.schematic.api.resources.accounts.requests.ListEnvironmentsRequest;
@@ -20,10 +21,12 @@
import com.schematic.api.resources.accounts.types.CreateEnvironmentResponse;
import com.schematic.api.resources.accounts.types.DeleteApiKeyResponse;
import com.schematic.api.resources.accounts.types.DeleteEnvironmentResponse;
+import com.schematic.api.resources.accounts.types.GetAccountMemberResponse;
import com.schematic.api.resources.accounts.types.GetApiKeyResponse;
import com.schematic.api.resources.accounts.types.GetAuditLogResponse;
import com.schematic.api.resources.accounts.types.GetEnvironmentResponse;
import com.schematic.api.resources.accounts.types.GetWhoAmIResponse;
+import com.schematic.api.resources.accounts.types.ListAccountMembersResponse;
import com.schematic.api.resources.accounts.types.ListApiKeysResponse;
import com.schematic.api.resources.accounts.types.ListAuditLogsResponse;
import com.schematic.api.resources.accounts.types.ListEnvironmentsResponse;
@@ -48,6 +51,31 @@ public RawAccountsClient withRawResponse() {
return this.rawClient;
}
+ public ListAccountMembersResponse listAccountMembers() {
+ return this.rawClient.listAccountMembers().body();
+ }
+
+ public ListAccountMembersResponse listAccountMembers(RequestOptions requestOptions) {
+ return this.rawClient.listAccountMembers(requestOptions).body();
+ }
+
+ public ListAccountMembersResponse listAccountMembers(ListAccountMembersRequest request) {
+ return this.rawClient.listAccountMembers(request).body();
+ }
+
+ public ListAccountMembersResponse listAccountMembers(
+ ListAccountMembersRequest request, RequestOptions requestOptions) {
+ return this.rawClient.listAccountMembers(request, requestOptions).body();
+ }
+
+ public GetAccountMemberResponse getAccountMember(String accountMemberId) {
+ return this.rawClient.getAccountMember(accountMemberId).body();
+ }
+
+ public GetAccountMemberResponse getAccountMember(String accountMemberId, RequestOptions requestOptions) {
+ return this.rawClient.getAccountMember(accountMemberId, requestOptions).body();
+ }
+
public ListApiKeysResponse listApiKeys(ListApiKeysRequest request) {
return this.rawClient.listApiKeys(request).body();
}
diff --git a/src/main/java/com/schematic/api/resources/accounts/AsyncAccountsClient.java b/src/main/java/com/schematic/api/resources/accounts/AsyncAccountsClient.java
index 410c177..d37bb0c 100644
--- a/src/main/java/com/schematic/api/resources/accounts/AsyncAccountsClient.java
+++ b/src/main/java/com/schematic/api/resources/accounts/AsyncAccountsClient.java
@@ -9,6 +9,7 @@
import com.schematic.api.resources.accounts.requests.CountAuditLogsRequest;
import com.schematic.api.resources.accounts.requests.CreateApiKeyRequestBody;
import com.schematic.api.resources.accounts.requests.CreateEnvironmentRequestBody;
+import com.schematic.api.resources.accounts.requests.ListAccountMembersRequest;
import com.schematic.api.resources.accounts.requests.ListApiKeysRequest;
import com.schematic.api.resources.accounts.requests.ListAuditLogsRequest;
import com.schematic.api.resources.accounts.requests.ListEnvironmentsRequest;
@@ -20,10 +21,12 @@
import com.schematic.api.resources.accounts.types.CreateEnvironmentResponse;
import com.schematic.api.resources.accounts.types.DeleteApiKeyResponse;
import com.schematic.api.resources.accounts.types.DeleteEnvironmentResponse;
+import com.schematic.api.resources.accounts.types.GetAccountMemberResponse;
import com.schematic.api.resources.accounts.types.GetApiKeyResponse;
import com.schematic.api.resources.accounts.types.GetAuditLogResponse;
import com.schematic.api.resources.accounts.types.GetEnvironmentResponse;
import com.schematic.api.resources.accounts.types.GetWhoAmIResponse;
+import com.schematic.api.resources.accounts.types.ListAccountMembersResponse;
import com.schematic.api.resources.accounts.types.ListApiKeysResponse;
import com.schematic.api.resources.accounts.types.ListAuditLogsResponse;
import com.schematic.api.resources.accounts.types.ListEnvironmentsResponse;
@@ -49,6 +52,32 @@ public AsyncRawAccountsClient withRawResponse() {
return this.rawClient;
}
+ public CompletableFuture listAccountMembers() {
+ return this.rawClient.listAccountMembers().thenApply(response -> response.body());
+ }
+
+ public CompletableFuture listAccountMembers(RequestOptions requestOptions) {
+ return this.rawClient.listAccountMembers(requestOptions).thenApply(response -> response.body());
+ }
+
+ public CompletableFuture listAccountMembers(ListAccountMembersRequest request) {
+ return this.rawClient.listAccountMembers(request).thenApply(response -> response.body());
+ }
+
+ public CompletableFuture listAccountMembers(
+ ListAccountMembersRequest request, RequestOptions requestOptions) {
+ return this.rawClient.listAccountMembers(request, requestOptions).thenApply(response -> response.body());
+ }
+
+ public CompletableFuture getAccountMember(String accountMemberId) {
+ return this.rawClient.getAccountMember(accountMemberId).thenApply(response -> response.body());
+ }
+
+ public CompletableFuture getAccountMember(
+ String accountMemberId, RequestOptions requestOptions) {
+ return this.rawClient.getAccountMember(accountMemberId, requestOptions).thenApply(response -> response.body());
+ }
+
public CompletableFuture listApiKeys(ListApiKeysRequest request) {
return this.rawClient.listApiKeys(request).thenApply(response -> response.body());
}
diff --git a/src/main/java/com/schematic/api/resources/accounts/AsyncRawAccountsClient.java b/src/main/java/com/schematic/api/resources/accounts/AsyncRawAccountsClient.java
index cf062f8..24bbb7c 100644
--- a/src/main/java/com/schematic/api/resources/accounts/AsyncRawAccountsClient.java
+++ b/src/main/java/com/schematic/api/resources/accounts/AsyncRawAccountsClient.java
@@ -21,6 +21,7 @@
import com.schematic.api.resources.accounts.requests.CountAuditLogsRequest;
import com.schematic.api.resources.accounts.requests.CreateApiKeyRequestBody;
import com.schematic.api.resources.accounts.requests.CreateEnvironmentRequestBody;
+import com.schematic.api.resources.accounts.requests.ListAccountMembersRequest;
import com.schematic.api.resources.accounts.requests.ListApiKeysRequest;
import com.schematic.api.resources.accounts.requests.ListAuditLogsRequest;
import com.schematic.api.resources.accounts.requests.ListEnvironmentsRequest;
@@ -32,10 +33,12 @@
import com.schematic.api.resources.accounts.types.CreateEnvironmentResponse;
import com.schematic.api.resources.accounts.types.DeleteApiKeyResponse;
import com.schematic.api.resources.accounts.types.DeleteEnvironmentResponse;
+import com.schematic.api.resources.accounts.types.GetAccountMemberResponse;
import com.schematic.api.resources.accounts.types.GetApiKeyResponse;
import com.schematic.api.resources.accounts.types.GetAuditLogResponse;
import com.schematic.api.resources.accounts.types.GetEnvironmentResponse;
import com.schematic.api.resources.accounts.types.GetWhoAmIResponse;
+import com.schematic.api.resources.accounts.types.ListAccountMembersResponse;
import com.schematic.api.resources.accounts.types.ListApiKeysResponse;
import com.schematic.api.resources.accounts.types.ListAuditLogsResponse;
import com.schematic.api.resources.accounts.types.ListEnvironmentsResponse;
@@ -63,6 +66,196 @@ public AsyncRawAccountsClient(ClientOptions clientOptions) {
this.clientOptions = clientOptions;
}
+ public CompletableFuture> listAccountMembers() {
+ return listAccountMembers(ListAccountMembersRequest.builder().build());
+ }
+
+ public CompletableFuture> listAccountMembers(
+ RequestOptions requestOptions) {
+ return listAccountMembers(ListAccountMembersRequest.builder().build(), requestOptions);
+ }
+
+ public CompletableFuture> listAccountMembers(
+ ListAccountMembersRequest request) {
+ return listAccountMembers(request, null);
+ }
+
+ public CompletableFuture> listAccountMembers(
+ ListAccountMembersRequest request, RequestOptions requestOptions) {
+ HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl())
+ .newBuilder()
+ .addPathSegments("account-members");
+ if (request.getQ().isPresent()) {
+ QueryStringMapper.addQueryParameter(httpUrl, "q", request.getQ().get(), false);
+ }
+ if (request.getLimit().isPresent()) {
+ QueryStringMapper.addQueryParameter(
+ httpUrl, "limit", request.getLimit().get(), false);
+ }
+ if (request.getOffset().isPresent()) {
+ QueryStringMapper.addQueryParameter(
+ httpUrl, "offset", request.getOffset().get(), false);
+ }
+ if (request.getIds().isPresent()) {
+ QueryStringMapper.addQueryParameter(httpUrl, "ids", request.getIds().get(), true);
+ }
+ if (requestOptions != null) {
+ requestOptions.getQueryParameters().forEach((_key, _value) -> {
+ httpUrl.addQueryParameter(_key, _value);
+ });
+ }
+ Request.Builder _requestBuilder = new Request.Builder()
+ .url(httpUrl.build())
+ .method("GET", null)
+ .headers(Headers.of(clientOptions.headers(requestOptions)))
+ .addHeader("Accept", "application/json");
+ Request okhttpRequest = _requestBuilder.build();
+ OkHttpClient client = clientOptions.httpClient();
+ if (requestOptions != null && requestOptions.getTimeout().isPresent()) {
+ client = clientOptions.httpClientWithTimeout(requestOptions);
+ }
+ CompletableFuture> future = new CompletableFuture<>();
+ client.newCall(okhttpRequest).enqueue(new Callback() {
+ @Override
+ public void onResponse(@NotNull Call call, @NotNull Response response) throws IOException {
+ try (ResponseBody responseBody = response.body()) {
+ String responseBodyString = responseBody != null ? responseBody.string() : "{}";
+ if (response.isSuccessful()) {
+ future.complete(new BaseSchematicHttpResponse<>(
+ ObjectMappers.JSON_MAPPER.readValue(
+ responseBodyString, ListAccountMembersResponse.class),
+ response));
+ return;
+ }
+ try {
+ switch (response.code()) {
+ case 400:
+ future.completeExceptionally(new BadRequestError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ case 401:
+ future.completeExceptionally(new UnauthorizedError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ case 403:
+ future.completeExceptionally(new ForbiddenError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ case 404:
+ future.completeExceptionally(new NotFoundError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ case 500:
+ future.completeExceptionally(new InternalServerError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ }
+ } catch (JsonProcessingException ignored) {
+ // unable to map error response, throwing generic error
+ }
+ Object errorBody = ObjectMappers.parseErrorBody(responseBodyString);
+ future.completeExceptionally(new BaseSchematicApiException(
+ "Error with status code " + response.code(), response.code(), errorBody, response));
+ return;
+ } catch (IOException e) {
+ future.completeExceptionally(new BaseSchematicException("Network error executing HTTP request", e));
+ }
+ }
+
+ @Override
+ public void onFailure(@NotNull Call call, @NotNull IOException e) {
+ future.completeExceptionally(new BaseSchematicException("Network error executing HTTP request", e));
+ }
+ });
+ return future;
+ }
+
+ public CompletableFuture> getAccountMember(
+ String accountMemberId) {
+ return getAccountMember(accountMemberId, null);
+ }
+
+ public CompletableFuture> getAccountMember(
+ String accountMemberId, RequestOptions requestOptions) {
+ HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl())
+ .newBuilder()
+ .addPathSegments("account-members")
+ .addPathSegment(accountMemberId);
+ if (requestOptions != null) {
+ requestOptions.getQueryParameters().forEach((_key, _value) -> {
+ httpUrl.addQueryParameter(_key, _value);
+ });
+ }
+ Request okhttpRequest = new Request.Builder()
+ .url(httpUrl.build())
+ .method("GET", null)
+ .headers(Headers.of(clientOptions.headers(requestOptions)))
+ .addHeader("Accept", "application/json")
+ .build();
+ OkHttpClient client = clientOptions.httpClient();
+ if (requestOptions != null && requestOptions.getTimeout().isPresent()) {
+ client = clientOptions.httpClientWithTimeout(requestOptions);
+ }
+ CompletableFuture> future = new CompletableFuture<>();
+ client.newCall(okhttpRequest).enqueue(new Callback() {
+ @Override
+ public void onResponse(@NotNull Call call, @NotNull Response response) throws IOException {
+ try (ResponseBody responseBody = response.body()) {
+ String responseBodyString = responseBody != null ? responseBody.string() : "{}";
+ if (response.isSuccessful()) {
+ future.complete(new BaseSchematicHttpResponse<>(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, GetAccountMemberResponse.class),
+ response));
+ return;
+ }
+ try {
+ switch (response.code()) {
+ case 401:
+ future.completeExceptionally(new UnauthorizedError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ case 403:
+ future.completeExceptionally(new ForbiddenError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ case 404:
+ future.completeExceptionally(new NotFoundError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ case 500:
+ future.completeExceptionally(new InternalServerError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class),
+ response));
+ return;
+ }
+ } catch (JsonProcessingException ignored) {
+ // unable to map error response, throwing generic error
+ }
+ Object errorBody = ObjectMappers.parseErrorBody(responseBodyString);
+ future.completeExceptionally(new BaseSchematicApiException(
+ "Error with status code " + response.code(), response.code(), errorBody, response));
+ return;
+ } catch (IOException e) {
+ future.completeExceptionally(new BaseSchematicException("Network error executing HTTP request", e));
+ }
+ }
+
+ @Override
+ public void onFailure(@NotNull Call call, @NotNull IOException e) {
+ future.completeExceptionally(new BaseSchematicException("Network error executing HTTP request", e));
+ }
+ });
+ return future;
+ }
+
public CompletableFuture> listApiKeys(ListApiKeysRequest request) {
return listApiKeys(request, null);
}
diff --git a/src/main/java/com/schematic/api/resources/accounts/RawAccountsClient.java b/src/main/java/com/schematic/api/resources/accounts/RawAccountsClient.java
index 3a68cc6..0569770 100644
--- a/src/main/java/com/schematic/api/resources/accounts/RawAccountsClient.java
+++ b/src/main/java/com/schematic/api/resources/accounts/RawAccountsClient.java
@@ -21,6 +21,7 @@
import com.schematic.api.resources.accounts.requests.CountAuditLogsRequest;
import com.schematic.api.resources.accounts.requests.CreateApiKeyRequestBody;
import com.schematic.api.resources.accounts.requests.CreateEnvironmentRequestBody;
+import com.schematic.api.resources.accounts.requests.ListAccountMembersRequest;
import com.schematic.api.resources.accounts.requests.ListApiKeysRequest;
import com.schematic.api.resources.accounts.requests.ListAuditLogsRequest;
import com.schematic.api.resources.accounts.requests.ListEnvironmentsRequest;
@@ -32,10 +33,12 @@
import com.schematic.api.resources.accounts.types.CreateEnvironmentResponse;
import com.schematic.api.resources.accounts.types.DeleteApiKeyResponse;
import com.schematic.api.resources.accounts.types.DeleteEnvironmentResponse;
+import com.schematic.api.resources.accounts.types.GetAccountMemberResponse;
import com.schematic.api.resources.accounts.types.GetApiKeyResponse;
import com.schematic.api.resources.accounts.types.GetAuditLogResponse;
import com.schematic.api.resources.accounts.types.GetEnvironmentResponse;
import com.schematic.api.resources.accounts.types.GetWhoAmIResponse;
+import com.schematic.api.resources.accounts.types.ListAccountMembersResponse;
import com.schematic.api.resources.accounts.types.ListApiKeysResponse;
import com.schematic.api.resources.accounts.types.ListAuditLogsResponse;
import com.schematic.api.resources.accounts.types.ListEnvironmentsResponse;
@@ -59,6 +62,148 @@ public RawAccountsClient(ClientOptions clientOptions) {
this.clientOptions = clientOptions;
}
+ public BaseSchematicHttpResponse listAccountMembers() {
+ return listAccountMembers(ListAccountMembersRequest.builder().build());
+ }
+
+ public BaseSchematicHttpResponse listAccountMembers(RequestOptions requestOptions) {
+ return listAccountMembers(ListAccountMembersRequest.builder().build(), requestOptions);
+ }
+
+ public BaseSchematicHttpResponse listAccountMembers(ListAccountMembersRequest request) {
+ return listAccountMembers(request, null);
+ }
+
+ public BaseSchematicHttpResponse listAccountMembers(
+ ListAccountMembersRequest request, RequestOptions requestOptions) {
+ HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl())
+ .newBuilder()
+ .addPathSegments("account-members");
+ if (request.getQ().isPresent()) {
+ QueryStringMapper.addQueryParameter(httpUrl, "q", request.getQ().get(), false);
+ }
+ if (request.getLimit().isPresent()) {
+ QueryStringMapper.addQueryParameter(
+ httpUrl, "limit", request.getLimit().get(), false);
+ }
+ if (request.getOffset().isPresent()) {
+ QueryStringMapper.addQueryParameter(
+ httpUrl, "offset", request.getOffset().get(), false);
+ }
+ if (request.getIds().isPresent()) {
+ QueryStringMapper.addQueryParameter(httpUrl, "ids", request.getIds().get(), true);
+ }
+ if (requestOptions != null) {
+ requestOptions.getQueryParameters().forEach((_key, _value) -> {
+ httpUrl.addQueryParameter(_key, _value);
+ });
+ }
+ Request.Builder _requestBuilder = new Request.Builder()
+ .url(httpUrl.build())
+ .method("GET", null)
+ .headers(Headers.of(clientOptions.headers(requestOptions)))
+ .addHeader("Accept", "application/json");
+ Request okhttpRequest = _requestBuilder.build();
+ OkHttpClient client = clientOptions.httpClient();
+ if (requestOptions != null && requestOptions.getTimeout().isPresent()) {
+ client = clientOptions.httpClientWithTimeout(requestOptions);
+ }
+ try (Response response = client.newCall(okhttpRequest).execute()) {
+ ResponseBody responseBody = response.body();
+ String responseBodyString = responseBody != null ? responseBody.string() : "{}";
+ if (response.isSuccessful()) {
+ return new BaseSchematicHttpResponse<>(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ListAccountMembersResponse.class),
+ response);
+ }
+ try {
+ switch (response.code()) {
+ case 400:
+ throw new BadRequestError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ case 401:
+ throw new UnauthorizedError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ case 403:
+ throw new ForbiddenError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ case 404:
+ throw new NotFoundError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ case 500:
+ throw new InternalServerError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ }
+ } catch (JsonProcessingException ignored) {
+ // unable to map error response, throwing generic error
+ }
+ Object errorBody = ObjectMappers.parseErrorBody(responseBodyString);
+ throw new BaseSchematicApiException(
+ "Error with status code " + response.code(), response.code(), errorBody, response);
+ } catch (IOException e) {
+ throw new BaseSchematicException("Network error executing HTTP request", e);
+ }
+ }
+
+ public BaseSchematicHttpResponse getAccountMember(String accountMemberId) {
+ return getAccountMember(accountMemberId, null);
+ }
+
+ public BaseSchematicHttpResponse getAccountMember(
+ String accountMemberId, RequestOptions requestOptions) {
+ HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl())
+ .newBuilder()
+ .addPathSegments("account-members")
+ .addPathSegment(accountMemberId);
+ if (requestOptions != null) {
+ requestOptions.getQueryParameters().forEach((_key, _value) -> {
+ httpUrl.addQueryParameter(_key, _value);
+ });
+ }
+ Request okhttpRequest = new Request.Builder()
+ .url(httpUrl.build())
+ .method("GET", null)
+ .headers(Headers.of(clientOptions.headers(requestOptions)))
+ .addHeader("Accept", "application/json")
+ .build();
+ OkHttpClient client = clientOptions.httpClient();
+ if (requestOptions != null && requestOptions.getTimeout().isPresent()) {
+ client = clientOptions.httpClientWithTimeout(requestOptions);
+ }
+ try (Response response = client.newCall(okhttpRequest).execute()) {
+ ResponseBody responseBody = response.body();
+ String responseBodyString = responseBody != null ? responseBody.string() : "{}";
+ if (response.isSuccessful()) {
+ return new BaseSchematicHttpResponse<>(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, GetAccountMemberResponse.class),
+ response);
+ }
+ try {
+ switch (response.code()) {
+ case 401:
+ throw new UnauthorizedError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ case 403:
+ throw new ForbiddenError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ case 404:
+ throw new NotFoundError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ case 500:
+ throw new InternalServerError(
+ ObjectMappers.JSON_MAPPER.readValue(responseBodyString, ApiError.class), response);
+ }
+ } catch (JsonProcessingException ignored) {
+ // unable to map error response, throwing generic error
+ }
+ Object errorBody = ObjectMappers.parseErrorBody(responseBodyString);
+ throw new BaseSchematicApiException(
+ "Error with status code " + response.code(), response.code(), errorBody, response);
+ } catch (IOException e) {
+ throw new BaseSchematicException("Network error executing HTTP request", e);
+ }
+ }
+
public BaseSchematicHttpResponse listApiKeys(ListApiKeysRequest request) {
return listApiKeys(request, null);
}
diff --git a/src/main/java/com/schematic/api/resources/accounts/requests/ListAccountMembersRequest.java b/src/main/java/com/schematic/api/resources/accounts/requests/ListAccountMembersRequest.java
new file mode 100644
index 0000000..10a0328
--- /dev/null
+++ b/src/main/java/com/schematic/api/resources/accounts/requests/ListAccountMembersRequest.java
@@ -0,0 +1,201 @@
+/**
+ * This file was auto-generated by Fern from our API Definition.
+ */
+package com.schematic.api.resources.accounts.requests;
+
+import com.fasterxml.jackson.annotation.JsonAnyGetter;
+import com.fasterxml.jackson.annotation.JsonAnySetter;
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonSetter;
+import com.fasterxml.jackson.annotation.Nulls;
+import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
+import com.schematic.api.core.ObjectMappers;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+import java.util.Optional;
+
+@JsonInclude(JsonInclude.Include.NON_ABSENT)
+@JsonDeserialize(builder = ListAccountMembersRequest.Builder.class)
+public final class ListAccountMembersRequest {
+ private final Optional> ids;
+
+ private final Optional q;
+
+ private final Optional limit;
+
+ private final Optional offset;
+
+ private final Map additionalProperties;
+
+ private ListAccountMembersRequest(
+ Optional> ids,
+ Optional q,
+ Optional limit,
+ Optional offset,
+ Map additionalProperties) {
+ this.ids = ids;
+ this.q = q;
+ this.limit = limit;
+ this.offset = offset;
+ this.additionalProperties = additionalProperties;
+ }
+
+ @JsonProperty("ids")
+ public Optional> getIds() {
+ return ids;
+ }
+
+ /**
+ * @return Search filter
+ */
+ @JsonProperty("q")
+ public Optional getQ() {
+ return q;
+ }
+
+ /**
+ * @return Page limit (default 100)
+ */
+ @JsonProperty("limit")
+ public Optional getLimit() {
+ return limit;
+ }
+
+ /**
+ * @return Page offset (default 0)
+ */
+ @JsonProperty("offset")
+ public Optional getOffset() {
+ return offset;
+ }
+
+ @java.lang.Override
+ public boolean equals(Object other) {
+ if (this == other) return true;
+ return other instanceof ListAccountMembersRequest && equalTo((ListAccountMembersRequest) other);
+ }
+
+ @JsonAnyGetter
+ public Map getAdditionalProperties() {
+ return this.additionalProperties;
+ }
+
+ private boolean equalTo(ListAccountMembersRequest other) {
+ return ids.equals(other.ids) && q.equals(other.q) && limit.equals(other.limit) && offset.equals(other.offset);
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ return Objects.hash(this.ids, this.q, this.limit, this.offset);
+ }
+
+ @java.lang.Override
+ public String toString() {
+ return ObjectMappers.stringify(this);
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ @JsonIgnoreProperties(ignoreUnknown = true)
+ public static final class Builder {
+ private Optional> ids = Optional.empty();
+
+ private Optional q = Optional.empty();
+
+ private Optional limit = Optional.empty();
+
+ private Optional offset = Optional.empty();
+
+ @JsonAnySetter
+ private Map additionalProperties = new HashMap<>();
+
+ private Builder() {}
+
+ public Builder from(ListAccountMembersRequest other) {
+ ids(other.getIds());
+ q(other.getQ());
+ limit(other.getLimit());
+ offset(other.getOffset());
+ return this;
+ }
+
+ @JsonSetter(value = "ids", nulls = Nulls.SKIP)
+ public Builder ids(Optional> ids) {
+ this.ids = ids;
+ return this;
+ }
+
+ public Builder ids(List ids) {
+ this.ids = Optional.ofNullable(ids);
+ return this;
+ }
+
+ public Builder ids(String ids) {
+ this.ids = Optional.of(Collections.singletonList(ids));
+ return this;
+ }
+
+ /**
+ * Search filter
+ */
+ @JsonSetter(value = "q", nulls = Nulls.SKIP)
+ public Builder q(Optional q) {
+ this.q = q;
+ return this;
+ }
+
+ public Builder q(String q) {
+ this.q = Optional.ofNullable(q);
+ return this;
+ }
+
+ /**
+ * Page limit (default 100)
+ */
+ @JsonSetter(value = "limit", nulls = Nulls.SKIP)
+ public Builder limit(Optional limit) {
+ this.limit = limit;
+ return this;
+ }
+
+ public Builder limit(Long limit) {
+ this.limit = Optional.ofNullable(limit);
+ return this;
+ }
+
+ /**
+ * Page offset (default 0)
+ */
+ @JsonSetter(value = "offset", nulls = Nulls.SKIP)
+ public Builder offset(Optional offset) {
+ this.offset = offset;
+ return this;
+ }
+
+ public Builder offset(Long offset) {
+ this.offset = Optional.ofNullable(offset);
+ return this;
+ }
+
+ public ListAccountMembersRequest build() {
+ return new ListAccountMembersRequest(ids, q, limit, offset, additionalProperties);
+ }
+
+ public Builder additionalProperty(String key, Object value) {
+ this.additionalProperties.put(key, value);
+ return this;
+ }
+
+ public Builder additionalProperties(Map additionalProperties) {
+ this.additionalProperties.putAll(additionalProperties);
+ return this;
+ }
+ }
+}
diff --git a/src/main/java/com/schematic/api/resources/accounts/types/GetAccountMemberResponse.java b/src/main/java/com/schematic/api/resources/accounts/types/GetAccountMemberResponse.java
new file mode 100644
index 0000000..e20552e
--- /dev/null
+++ b/src/main/java/com/schematic/api/resources/accounts/types/GetAccountMemberResponse.java
@@ -0,0 +1,181 @@
+/**
+ * This file was auto-generated by Fern from our API Definition.
+ */
+package com.schematic.api.resources.accounts.types;
+
+import com.fasterxml.jackson.annotation.JsonAnyGetter;
+import com.fasterxml.jackson.annotation.JsonAnySetter;
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonSetter;
+import com.fasterxml.jackson.annotation.Nulls;
+import com.fasterxml.jackson.databind.JsonNode;
+import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
+import com.schematic.api.core.ObjectMappers;
+import com.schematic.api.types.AccountMemberResponseData;
+import java.util.HashMap;
+import java.util.LinkedHashMap;
+import java.util.Map;
+import java.util.Objects;
+import org.jetbrains.annotations.NotNull;
+
+@JsonInclude(JsonInclude.Include.NON_ABSENT)
+@JsonDeserialize(builder = GetAccountMemberResponse.Builder.class)
+public final class GetAccountMemberResponse {
+ private final AccountMemberResponseData data;
+
+ private final Map params;
+
+ private final Map additionalProperties;
+
+ private GetAccountMemberResponse(
+ AccountMemberResponseData data, Map params, Map additionalProperties) {
+ this.data = data;
+ this.params = params;
+ this.additionalProperties = additionalProperties;
+ }
+
+ @JsonProperty("data")
+ public AccountMemberResponseData getData() {
+ return data;
+ }
+
+ /**
+ * @return Input parameters
+ */
+ @JsonProperty("params")
+ public Map getParams() {
+ return params;
+ }
+
+ @java.lang.Override
+ public boolean equals(Object other) {
+ if (this == other) return true;
+ return other instanceof GetAccountMemberResponse && equalTo((GetAccountMemberResponse) other);
+ }
+
+ @JsonAnyGetter
+ public Map getAdditionalProperties() {
+ return this.additionalProperties;
+ }
+
+ private boolean equalTo(GetAccountMemberResponse other) {
+ return data.equals(other.data) && params.equals(other.params);
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ return Objects.hash(this.data, this.params);
+ }
+
+ @java.lang.Override
+ public String toString() {
+ return ObjectMappers.stringify(this);
+ }
+
+ public static DataStage builder() {
+ return new Builder();
+ }
+
+ public interface DataStage {
+ _FinalStage data(@NotNull AccountMemberResponseData data);
+
+ Builder from(GetAccountMemberResponse other);
+ }
+
+ public interface _FinalStage {
+ GetAccountMemberResponse build();
+
+ _FinalStage additionalProperty(String key, Object value);
+
+ _FinalStage additionalProperties(Map additionalProperties);
+
+ /**
+ * Input parameters
+ */
+ _FinalStage params(Map params);
+
+ _FinalStage putAllParams(Map params);
+
+ _FinalStage params(String key, JsonNode value);
+ }
+
+ @JsonIgnoreProperties(ignoreUnknown = true)
+ public static final class Builder implements DataStage, _FinalStage {
+ private AccountMemberResponseData data;
+
+ private Map params = new LinkedHashMap<>();
+
+ @JsonAnySetter
+ private Map additionalProperties = new HashMap<>();
+
+ private Builder() {}
+
+ @java.lang.Override
+ public Builder from(GetAccountMemberResponse other) {
+ data(other.getData());
+ params(other.getParams());
+ return this;
+ }
+
+ @java.lang.Override
+ @JsonSetter("data")
+ public _FinalStage data(@NotNull AccountMemberResponseData data) {
+ this.data = Objects.requireNonNull(data, "data must not be null");
+ return this;
+ }
+
+ /**
+ * Input parameters
+ * @return Reference to {@code this} so that method calls can be chained together.
+ */
+ @java.lang.Override
+ public _FinalStage params(String key, JsonNode value) {
+ this.params.put(key, value);
+ return this;
+ }
+
+ /**
+ * Input parameters
+ * @return Reference to {@code this} so that method calls can be chained together.
+ */
+ @java.lang.Override
+ public _FinalStage putAllParams(Map params) {
+ if (params != null) {
+ this.params.putAll(params);
+ }
+ return this;
+ }
+
+ /**
+ * Input parameters
+ */
+ @java.lang.Override
+ @JsonSetter(value = "params", nulls = Nulls.SKIP)
+ public _FinalStage params(Map params) {
+ this.params.clear();
+ if (params != null) {
+ this.params.putAll(params);
+ }
+ return this;
+ }
+
+ @java.lang.Override
+ public GetAccountMemberResponse build() {
+ return new GetAccountMemberResponse(data, params, additionalProperties);
+ }
+
+ @java.lang.Override
+ public Builder additionalProperty(String key, Object value) {
+ this.additionalProperties.put(key, value);
+ return this;
+ }
+
+ @java.lang.Override
+ public Builder additionalProperties(Map additionalProperties) {
+ this.additionalProperties.putAll(additionalProperties);
+ return this;
+ }
+ }
+}
diff --git a/src/main/java/com/schematic/api/resources/accounts/types/ListAccountMembersParams.java b/src/main/java/com/schematic/api/resources/accounts/types/ListAccountMembersParams.java
new file mode 100644
index 0000000..42e47f1
--- /dev/null
+++ b/src/main/java/com/schematic/api/resources/accounts/types/ListAccountMembersParams.java
@@ -0,0 +1,195 @@
+/**
+ * This file was auto-generated by Fern from our API Definition.
+ */
+package com.schematic.api.resources.accounts.types;
+
+import com.fasterxml.jackson.annotation.JsonAnyGetter;
+import com.fasterxml.jackson.annotation.JsonAnySetter;
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonSetter;
+import com.fasterxml.jackson.annotation.Nulls;
+import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
+import com.schematic.api.core.ObjectMappers;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+import java.util.Optional;
+
+@JsonInclude(JsonInclude.Include.NON_ABSENT)
+@JsonDeserialize(builder = ListAccountMembersParams.Builder.class)
+public final class ListAccountMembersParams {
+ private final Optional> ids;
+
+ private final Optional limit;
+
+ private final Optional offset;
+
+ private final Optional q;
+
+ private final Map additionalProperties;
+
+ private ListAccountMembersParams(
+ Optional> ids,
+ Optional limit,
+ Optional offset,
+ Optional q,
+ Map additionalProperties) {
+ this.ids = ids;
+ this.limit = limit;
+ this.offset = offset;
+ this.q = q;
+ this.additionalProperties = additionalProperties;
+ }
+
+ @JsonProperty("ids")
+ public Optional> getIds() {
+ return ids;
+ }
+
+ /**
+ * @return Page limit (default 100)
+ */
+ @JsonProperty("limit")
+ public Optional getLimit() {
+ return limit;
+ }
+
+ /**
+ * @return Page offset (default 0)
+ */
+ @JsonProperty("offset")
+ public Optional getOffset() {
+ return offset;
+ }
+
+ /**
+ * @return Search filter
+ */
+ @JsonProperty("q")
+ public Optional getQ() {
+ return q;
+ }
+
+ @java.lang.Override
+ public boolean equals(Object other) {
+ if (this == other) return true;
+ return other instanceof ListAccountMembersParams && equalTo((ListAccountMembersParams) other);
+ }
+
+ @JsonAnyGetter
+ public Map getAdditionalProperties() {
+ return this.additionalProperties;
+ }
+
+ private boolean equalTo(ListAccountMembersParams other) {
+ return ids.equals(other.ids) && limit.equals(other.limit) && offset.equals(other.offset) && q.equals(other.q);
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ return Objects.hash(this.ids, this.limit, this.offset, this.q);
+ }
+
+ @java.lang.Override
+ public String toString() {
+ return ObjectMappers.stringify(this);
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ @JsonIgnoreProperties(ignoreUnknown = true)
+ public static final class Builder {
+ private Optional> ids = Optional.empty();
+
+ private Optional limit = Optional.empty();
+
+ private Optional offset = Optional.empty();
+
+ private Optional q = Optional.empty();
+
+ @JsonAnySetter
+ private Map additionalProperties = new HashMap<>();
+
+ private Builder() {}
+
+ public Builder from(ListAccountMembersParams other) {
+ ids(other.getIds());
+ limit(other.getLimit());
+ offset(other.getOffset());
+ q(other.getQ());
+ return this;
+ }
+
+ @JsonSetter(value = "ids", nulls = Nulls.SKIP)
+ public Builder ids(Optional> ids) {
+ this.ids = ids;
+ return this;
+ }
+
+ public Builder ids(List ids) {
+ this.ids = Optional.ofNullable(ids);
+ return this;
+ }
+
+ /**
+ * Page limit (default 100)
+ */
+ @JsonSetter(value = "limit", nulls = Nulls.SKIP)
+ public Builder limit(Optional limit) {
+ this.limit = limit;
+ return this;
+ }
+
+ public Builder limit(Long limit) {
+ this.limit = Optional.ofNullable(limit);
+ return this;
+ }
+
+ /**
+ * Page offset (default 0)
+ */
+ @JsonSetter(value = "offset", nulls = Nulls.SKIP)
+ public Builder offset(Optional offset) {
+ this.offset = offset;
+ return this;
+ }
+
+ public Builder offset(Long offset) {
+ this.offset = Optional.ofNullable(offset);
+ return this;
+ }
+
+ /**
+ * Search filter
+ */
+ @JsonSetter(value = "q", nulls = Nulls.SKIP)
+ public Builder q(Optional q) {
+ this.q = q;
+ return this;
+ }
+
+ public Builder q(String q) {
+ this.q = Optional.ofNullable(q);
+ return this;
+ }
+
+ public ListAccountMembersParams build() {
+ return new ListAccountMembersParams(ids, limit, offset, q, additionalProperties);
+ }
+
+ public Builder additionalProperty(String key, Object value) {
+ this.additionalProperties.put(key, value);
+ return this;
+ }
+
+ public Builder additionalProperties(Map additionalProperties) {
+ this.additionalProperties.putAll(additionalProperties);
+ return this;
+ }
+ }
+}
diff --git a/src/main/java/com/schematic/api/resources/accounts/types/ListAccountMembersResponse.java b/src/main/java/com/schematic/api/resources/accounts/types/ListAccountMembersResponse.java
new file mode 100644
index 0000000..7b669eb
--- /dev/null
+++ b/src/main/java/com/schematic/api/resources/accounts/types/ListAccountMembersResponse.java
@@ -0,0 +1,177 @@
+/**
+ * This file was auto-generated by Fern from our API Definition.
+ */
+package com.schematic.api.resources.accounts.types;
+
+import com.fasterxml.jackson.annotation.JsonAnyGetter;
+import com.fasterxml.jackson.annotation.JsonAnySetter;
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonSetter;
+import com.fasterxml.jackson.annotation.Nulls;
+import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
+import com.schematic.api.core.ObjectMappers;
+import com.schematic.api.types.AccountMemberResponseData;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+import org.jetbrains.annotations.NotNull;
+
+@JsonInclude(JsonInclude.Include.NON_ABSENT)
+@JsonDeserialize(builder = ListAccountMembersResponse.Builder.class)
+public final class ListAccountMembersResponse {
+ private final List data;
+
+ private final ListAccountMembersParams params;
+
+ private final Map additionalProperties;
+
+ private ListAccountMembersResponse(
+ List data,
+ ListAccountMembersParams params,
+ Map additionalProperties) {
+ this.data = data;
+ this.params = params;
+ this.additionalProperties = additionalProperties;
+ }
+
+ @JsonProperty("data")
+ public List getData() {
+ return data;
+ }
+
+ /**
+ * @return Input parameters
+ */
+ @JsonProperty("params")
+ public ListAccountMembersParams getParams() {
+ return params;
+ }
+
+ @java.lang.Override
+ public boolean equals(Object other) {
+ if (this == other) return true;
+ return other instanceof ListAccountMembersResponse && equalTo((ListAccountMembersResponse) other);
+ }
+
+ @JsonAnyGetter
+ public Map getAdditionalProperties() {
+ return this.additionalProperties;
+ }
+
+ private boolean equalTo(ListAccountMembersResponse other) {
+ return data.equals(other.data) && params.equals(other.params);
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ return Objects.hash(this.data, this.params);
+ }
+
+ @java.lang.Override
+ public String toString() {
+ return ObjectMappers.stringify(this);
+ }
+
+ public static ParamsStage builder() {
+ return new Builder();
+ }
+
+ public interface ParamsStage {
+ /**
+ * Input parameters
+ */
+ _FinalStage params(@NotNull ListAccountMembersParams params);
+
+ Builder from(ListAccountMembersResponse other);
+ }
+
+ public interface _FinalStage {
+ ListAccountMembersResponse build();
+
+ _FinalStage additionalProperty(String key, Object value);
+
+ _FinalStage additionalProperties(Map additionalProperties);
+
+ _FinalStage data(List data);
+
+ _FinalStage addData(AccountMemberResponseData data);
+
+ _FinalStage addAllData(List data);
+ }
+
+ @JsonIgnoreProperties(ignoreUnknown = true)
+ public static final class Builder implements ParamsStage, _FinalStage {
+ private ListAccountMembersParams params;
+
+ private List data = new ArrayList<>();
+
+ @JsonAnySetter
+ private Map additionalProperties = new HashMap<>();
+
+ private Builder() {}
+
+ @java.lang.Override
+ public Builder from(ListAccountMembersResponse other) {
+ data(other.getData());
+ params(other.getParams());
+ return this;
+ }
+
+ /**
+ * Input parameters
+ * Input parameters
+ * @return Reference to {@code this} so that method calls can be chained together.
+ */
+ @java.lang.Override
+ @JsonSetter("params")
+ public _FinalStage params(@NotNull ListAccountMembersParams params) {
+ this.params = Objects.requireNonNull(params, "params must not be null");
+ return this;
+ }
+
+ @java.lang.Override
+ public _FinalStage addAllData(List data) {
+ if (data != null) {
+ this.data.addAll(data);
+ }
+ return this;
+ }
+
+ @java.lang.Override
+ public _FinalStage addData(AccountMemberResponseData data) {
+ this.data.add(data);
+ return this;
+ }
+
+ @java.lang.Override
+ @JsonSetter(value = "data", nulls = Nulls.SKIP)
+ public _FinalStage data(List data) {
+ this.data.clear();
+ if (data != null) {
+ this.data.addAll(data);
+ }
+ return this;
+ }
+
+ @java.lang.Override
+ public ListAccountMembersResponse build() {
+ return new ListAccountMembersResponse(data, params, additionalProperties);
+ }
+
+ @java.lang.Override
+ public Builder additionalProperty(String key, Object value) {
+ this.additionalProperties.put(key, value);
+ return this;
+ }
+
+ @java.lang.Override
+ public Builder additionalProperties(Map additionalProperties) {
+ this.additionalProperties.putAll(additionalProperties);
+ return this;
+ }
+ }
+}
diff --git a/src/main/java/com/schematic/api/resources/billing/requests/CreateBillingSubscriptionRequestBody.java b/src/main/java/com/schematic/api/resources/billing/requests/CreateBillingSubscriptionRequestBody.java
index f4b51ce..3bbd523 100644
--- a/src/main/java/com/schematic/api/resources/billing/requests/CreateBillingSubscriptionRequestBody.java
+++ b/src/main/java/com/schematic/api/resources/billing/requests/CreateBillingSubscriptionRequestBody.java
@@ -14,6 +14,7 @@
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.schematic.api.core.ObjectMappers;
import com.schematic.api.types.BillingProductPricing;
+import com.schematic.api.types.BillingProviderType;
import com.schematic.api.types.BillingSubscriptionDiscount;
import com.schematic.api.types.BillingSubscriptionTrialEndSetting;
import java.time.OffsetDateTime;
@@ -56,6 +57,8 @@ public final class CreateBillingSubscriptionRequestBody {
private final List productExternalIds;
+ private final Optional providerType;
+
private final Optional status;
private final String subscriptionExternalId;
@@ -83,6 +86,7 @@ private CreateBillingSubscriptionRequestBody(
Optional periodEnd,
Optional periodStart,
List productExternalIds,
+ Optional providerType,
Optional status,
String subscriptionExternalId,
long totalPrice,
@@ -103,6 +107,7 @@ private CreateBillingSubscriptionRequestBody(
this.periodEnd = periodEnd;
this.periodStart = periodStart;
this.productExternalIds = productExternalIds;
+ this.providerType = providerType;
this.status = status;
this.subscriptionExternalId = subscriptionExternalId;
this.totalPrice = totalPrice;
@@ -181,6 +186,11 @@ public List getProductExternalIds() {
return productExternalIds;
}
+ @JsonProperty("provider_type")
+ public Optional getProviderType() {
+ return providerType;
+ }
+
@JsonProperty("status")
public Optional getStatus() {
return status;
@@ -233,6 +243,7 @@ private boolean equalTo(CreateBillingSubscriptionRequestBody other) {
&& periodEnd.equals(other.periodEnd)
&& periodStart.equals(other.periodStart)
&& productExternalIds.equals(other.productExternalIds)
+ && providerType.equals(other.providerType)
&& status.equals(other.status)
&& subscriptionExternalId.equals(other.subscriptionExternalId)
&& totalPrice == other.totalPrice
@@ -257,6 +268,7 @@ public int hashCode() {
this.periodEnd,
this.periodStart,
this.productExternalIds,
+ this.providerType,
this.status,
this.subscriptionExternalId,
this.totalPrice,
@@ -350,6 +362,10 @@ public interface _FinalStage {
_FinalStage addAllProductExternalIds(List productExternalIds);
+ _FinalStage providerType(Optional providerType);
+
+ _FinalStage providerType(BillingProviderType providerType);
+
_FinalStage status(Optional status);
_FinalStage status(String status);
@@ -390,6 +406,8 @@ public static final class Builder
private Optional status = Optional.empty();
+ private Optional providerType = Optional.empty();
+
private List productExternalIds = new ArrayList<>();
private Optional periodStart = Optional.empty();
@@ -431,6 +449,7 @@ public Builder from(CreateBillingSubscriptionRequestBody other) {
periodEnd(other.getPeriodEnd());
periodStart(other.getPeriodStart());
productExternalIds(other.getProductExternalIds());
+ providerType(other.getProviderType());
status(other.getStatus());
subscriptionExternalId(other.getSubscriptionExternalId());
totalPrice(other.getTotalPrice());
@@ -521,6 +540,19 @@ public _FinalStage status(Optional status) {
return this;
}
+ @java.lang.Override
+ public _FinalStage providerType(BillingProviderType providerType) {
+ this.providerType = Optional.ofNullable(providerType);
+ return this;
+ }
+
+ @java.lang.Override
+ @JsonSetter(value = "provider_type", nulls = Nulls.SKIP)
+ public _FinalStage providerType(Optional providerType) {
+ this.providerType = providerType;
+ return this;
+ }
+
@java.lang.Override
public _FinalStage addAllProductExternalIds(List productExternalIds) {
if (productExternalIds != null) {
@@ -690,6 +722,7 @@ public CreateBillingSubscriptionRequestBody build() {
periodEnd,
periodStart,
productExternalIds,
+ providerType,
status,
subscriptionExternalId,
totalPrice,
diff --git a/src/main/java/com/schematic/api/resources/billing/requests/CreateMeterRequestBody.java b/src/main/java/com/schematic/api/resources/billing/requests/CreateMeterRequestBody.java
index bbfd54e..a2db149 100644
--- a/src/main/java/com/schematic/api/resources/billing/requests/CreateMeterRequestBody.java
+++ b/src/main/java/com/schematic/api/resources/billing/requests/CreateMeterRequestBody.java
@@ -9,11 +9,14 @@
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonSetter;
+import com.fasterxml.jackson.annotation.Nulls;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.schematic.api.core.ObjectMappers;
+import com.schematic.api.types.BillingProviderType;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
+import java.util.Optional;
import org.jetbrains.annotations.NotNull;
@JsonInclude(JsonInclude.Include.NON_ABSENT)
@@ -27,6 +30,8 @@ public final class CreateMeterRequestBody {
private final String externalId;
+ private final Optional providerType;
+
private final Map additionalProperties;
private CreateMeterRequestBody(
@@ -34,11 +39,13 @@ private CreateMeterRequestBody(
String eventName,
String eventPayloadKey,
String externalId,
+ Optional providerType,
Map additionalProperties) {
this.displayName = displayName;
this.eventName = eventName;
this.eventPayloadKey = eventPayloadKey;
this.externalId = externalId;
+ this.providerType = providerType;
this.additionalProperties = additionalProperties;
}
@@ -62,6 +69,11 @@ public String getExternalId() {
return externalId;
}
+ @JsonProperty("provider_type")
+ public Optional getProviderType() {
+ return providerType;
+ }
+
@java.lang.Override
public boolean equals(Object other) {
if (this == other) return true;
@@ -77,12 +89,13 @@ private boolean equalTo(CreateMeterRequestBody other) {
return displayName.equals(other.displayName)
&& eventName.equals(other.eventName)
&& eventPayloadKey.equals(other.eventPayloadKey)
- && externalId.equals(other.externalId);
+ && externalId.equals(other.externalId)
+ && providerType.equals(other.providerType);
}
@java.lang.Override
public int hashCode() {
- return Objects.hash(this.displayName, this.eventName, this.eventPayloadKey, this.externalId);
+ return Objects.hash(this.displayName, this.eventName, this.eventPayloadKey, this.externalId, this.providerType);
}
@java.lang.Override
@@ -118,6 +131,10 @@ public interface _FinalStage {
_FinalStage additionalProperty(String key, Object value);
_FinalStage additionalProperties(Map additionalProperties);
+
+ _FinalStage providerType(Optional providerType);
+
+ _FinalStage providerType(BillingProviderType providerType);
}
@JsonIgnoreProperties(ignoreUnknown = true)
@@ -131,6 +148,8 @@ public static final class Builder
private String externalId;
+ private Optional providerType = Optional.empty();
+
@JsonAnySetter
private Map additionalProperties = new HashMap<>();
@@ -142,6 +161,7 @@ public Builder from(CreateMeterRequestBody other) {
eventName(other.getEventName());
eventPayloadKey(other.getEventPayloadKey());
externalId(other.getExternalId());
+ providerType(other.getProviderType());
return this;
}
@@ -173,10 +193,23 @@ public _FinalStage externalId(@NotNull String externalId) {
return this;
}
+ @java.lang.Override
+ public _FinalStage providerType(BillingProviderType providerType) {
+ this.providerType = Optional.ofNullable(providerType);
+ return this;
+ }
+
+ @java.lang.Override
+ @JsonSetter(value = "provider_type", nulls = Nulls.SKIP)
+ public _FinalStage providerType(Optional providerType) {
+ this.providerType = providerType;
+ return this;
+ }
+
@java.lang.Override
public CreateMeterRequestBody build() {
return new CreateMeterRequestBody(
- displayName, eventName, eventPayloadKey, externalId, additionalProperties);
+ displayName, eventName, eventPayloadKey, externalId, providerType, additionalProperties);
}
@java.lang.Override
diff --git a/src/main/java/com/schematic/api/resources/companies/AsyncRawCompaniesClient.java b/src/main/java/com/schematic/api/resources/companies/AsyncRawCompaniesClient.java
index e9ca280..6527128 100644
--- a/src/main/java/com/schematic/api/resources/companies/AsyncRawCompaniesClient.java
+++ b/src/main/java/com/schematic/api/resources/companies/AsyncRawCompaniesClient.java
@@ -123,6 +123,13 @@ public CompletableFuture> listC
HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl())
.newBuilder()
.addPathSegments("companies");
+ if (request.getHasScheduledDowngrade().isPresent()) {
+ QueryStringMapper.addQueryParameter(
+ httpUrl,
+ "has_scheduled_downgrade",
+ request.getHasScheduledDowngrade().get(),
+ false);
+ }
if (request.getMonetizedSubscriptions().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl,
@@ -587,6 +594,13 @@ public CompletableFuture> coun
HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl())
.newBuilder()
.addPathSegments("companies/count");
+ if (request.getHasScheduledDowngrade().isPresent()) {
+ QueryStringMapper.addQueryParameter(
+ httpUrl,
+ "has_scheduled_downgrade",
+ request.getHasScheduledDowngrade().get(),
+ false);
+ }
if (request.getMonetizedSubscriptions().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl,
diff --git a/src/main/java/com/schematic/api/resources/companies/RawCompaniesClient.java b/src/main/java/com/schematic/api/resources/companies/RawCompaniesClient.java
index a373c48..25f5745 100644
--- a/src/main/java/com/schematic/api/resources/companies/RawCompaniesClient.java
+++ b/src/main/java/com/schematic/api/resources/companies/RawCompaniesClient.java
@@ -117,6 +117,13 @@ public BaseSchematicHttpResponse listCompanies(
HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl())
.newBuilder()
.addPathSegments("companies");
+ if (request.getHasScheduledDowngrade().isPresent()) {
+ QueryStringMapper.addQueryParameter(
+ httpUrl,
+ "has_scheduled_downgrade",
+ request.getHasScheduledDowngrade().get(),
+ false);
+ }
if (request.getMonetizedSubscriptions().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl,
@@ -483,6 +490,13 @@ public BaseSchematicHttpResponse countCompanies(
HttpUrl.Builder httpUrl = HttpUrl.parse(this.clientOptions.environment().getUrl())
.newBuilder()
.addPathSegments("companies/count");
+ if (request.getHasScheduledDowngrade().isPresent()) {
+ QueryStringMapper.addQueryParameter(
+ httpUrl,
+ "has_scheduled_downgrade",
+ request.getHasScheduledDowngrade().get(),
+ false);
+ }
if (request.getMonetizedSubscriptions().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl,
diff --git a/src/main/java/com/schematic/api/resources/companies/requests/CountCompaniesRequest.java b/src/main/java/com/schematic/api/resources/companies/requests/CountCompaniesRequest.java
index 3c6ca03..fb2b7bc 100644
--- a/src/main/java/com/schematic/api/resources/companies/requests/CountCompaniesRequest.java
+++ b/src/main/java/com/schematic/api/resources/companies/requests/CountCompaniesRequest.java
@@ -35,6 +35,8 @@ public final class CountCompaniesRequest {
private final Optional> subscriptionTypes;
+ private final Optional hasScheduledDowngrade;
+
private final Optional monetizedSubscriptions;
private final Optional planId;
@@ -69,6 +71,7 @@ private CountCompaniesRequest(
Optional> planIds,
Optional> subscriptionStatuses,
Optional> subscriptionTypes,
+ Optional hasScheduledDowngrade,
Optional monetizedSubscriptions,
Optional planId,
Optional planVersionId,
@@ -88,6 +91,7 @@ private CountCompaniesRequest(
this.planIds = planIds;
this.subscriptionStatuses = subscriptionStatuses;
this.subscriptionTypes = subscriptionTypes;
+ this.hasScheduledDowngrade = hasScheduledDowngrade;
this.monetizedSubscriptions = monetizedSubscriptions;
this.planId = planId;
this.planVersionId = planVersionId;
@@ -144,6 +148,14 @@ public Optional> getSubscriptionTypes() {
return subscriptionTypes;
}
+ /**
+ * @return Filter companies that have a pending scheduled downgrade
+ */
+ @JsonProperty("has_scheduled_downgrade")
+ public Optional getHasScheduledDowngrade() {
+ return hasScheduledDowngrade;
+ }
+
/**
* @return Filter companies that have monetized subscriptions
*/
@@ -265,6 +277,7 @@ private boolean equalTo(CountCompaniesRequest other) {
&& planIds.equals(other.planIds)
&& subscriptionStatuses.equals(other.subscriptionStatuses)
&& subscriptionTypes.equals(other.subscriptionTypes)
+ && hasScheduledDowngrade.equals(other.hasScheduledDowngrade)
&& monetizedSubscriptions.equals(other.monetizedSubscriptions)
&& planId.equals(other.planId)
&& planVersionId.equals(other.planVersionId)
@@ -288,6 +301,7 @@ public int hashCode() {
this.planIds,
this.subscriptionStatuses,
this.subscriptionTypes,
+ this.hasScheduledDowngrade,
this.monetizedSubscriptions,
this.planId,
this.planVersionId,
@@ -324,6 +338,8 @@ public static final class Builder {
private Optional> subscriptionTypes = Optional.empty();
+ private Optional hasScheduledDowngrade = Optional.empty();
+
private Optional monetizedSubscriptions = Optional.empty();
private Optional planId = Optional.empty();
@@ -361,6 +377,7 @@ public Builder from(CountCompaniesRequest other) {
planIds(other.getPlanIds());
subscriptionStatuses(other.getSubscriptionStatuses());
subscriptionTypes(other.getSubscriptionTypes());
+ hasScheduledDowngrade(other.getHasScheduledDowngrade());
monetizedSubscriptions(other.getMonetizedSubscriptions());
planId(other.getPlanId());
planVersionId(other.getPlanVersionId());
@@ -472,6 +489,20 @@ public Builder subscriptionTypes(SubscriptionType subscriptionTypes) {
return this;
}
+ /**
+ * Filter companies that have a pending scheduled downgrade
+ */
+ @JsonSetter(value = "has_scheduled_downgrade", nulls = Nulls.SKIP)
+ public Builder hasScheduledDowngrade(Optional hasScheduledDowngrade) {
+ this.hasScheduledDowngrade = hasScheduledDowngrade;
+ return this;
+ }
+
+ public Builder hasScheduledDowngrade(Boolean hasScheduledDowngrade) {
+ this.hasScheduledDowngrade = Optional.ofNullable(hasScheduledDowngrade);
+ return this;
+ }
+
/**
* Filter companies that have monetized subscriptions
*/
@@ -661,6 +692,7 @@ public CountCompaniesRequest build() {
planIds,
subscriptionStatuses,
subscriptionTypes,
+ hasScheduledDowngrade,
monetizedSubscriptions,
planId,
planVersionId,
diff --git a/src/main/java/com/schematic/api/resources/companies/requests/ListCompaniesRequest.java b/src/main/java/com/schematic/api/resources/companies/requests/ListCompaniesRequest.java
index 5708dc3..28ee241 100644
--- a/src/main/java/com/schematic/api/resources/companies/requests/ListCompaniesRequest.java
+++ b/src/main/java/com/schematic/api/resources/companies/requests/ListCompaniesRequest.java
@@ -35,6 +35,8 @@ public final class ListCompaniesRequest {
private final Optional> subscriptionTypes;
+ private final Optional hasScheduledDowngrade;
+
private final Optional monetizedSubscriptions;
private final Optional planId;
@@ -69,6 +71,7 @@ private ListCompaniesRequest(
Optional> planIds,
Optional> subscriptionStatuses,
Optional> subscriptionTypes,
+ Optional hasScheduledDowngrade,
Optional monetizedSubscriptions,
Optional planId,
Optional planVersionId,
@@ -88,6 +91,7 @@ private ListCompaniesRequest(
this.planIds = planIds;
this.subscriptionStatuses = subscriptionStatuses;
this.subscriptionTypes = subscriptionTypes;
+ this.hasScheduledDowngrade = hasScheduledDowngrade;
this.monetizedSubscriptions = monetizedSubscriptions;
this.planId = planId;
this.planVersionId = planVersionId;
@@ -144,6 +148,14 @@ public Optional> getSubscriptionTypes() {
return subscriptionTypes;
}
+ /**
+ * @return Filter companies that have a pending scheduled downgrade
+ */
+ @JsonProperty("has_scheduled_downgrade")
+ public Optional getHasScheduledDowngrade() {
+ return hasScheduledDowngrade;
+ }
+
/**
* @return Filter companies that have monetized subscriptions
*/
@@ -265,6 +277,7 @@ private boolean equalTo(ListCompaniesRequest other) {
&& planIds.equals(other.planIds)
&& subscriptionStatuses.equals(other.subscriptionStatuses)
&& subscriptionTypes.equals(other.subscriptionTypes)
+ && hasScheduledDowngrade.equals(other.hasScheduledDowngrade)
&& monetizedSubscriptions.equals(other.monetizedSubscriptions)
&& planId.equals(other.planId)
&& planVersionId.equals(other.planVersionId)
@@ -288,6 +301,7 @@ public int hashCode() {
this.planIds,
this.subscriptionStatuses,
this.subscriptionTypes,
+ this.hasScheduledDowngrade,
this.monetizedSubscriptions,
this.planId,
this.planVersionId,
@@ -324,6 +338,8 @@ public static final class Builder {
private Optional> subscriptionTypes = Optional.empty();
+ private Optional hasScheduledDowngrade = Optional.empty();
+
private Optional monetizedSubscriptions = Optional.empty();
private Optional planId = Optional.empty();
@@ -361,6 +377,7 @@ public Builder from(ListCompaniesRequest other) {
planIds(other.getPlanIds());
subscriptionStatuses(other.getSubscriptionStatuses());
subscriptionTypes(other.getSubscriptionTypes());
+ hasScheduledDowngrade(other.getHasScheduledDowngrade());
monetizedSubscriptions(other.getMonetizedSubscriptions());
planId(other.getPlanId());
planVersionId(other.getPlanVersionId());
@@ -472,6 +489,20 @@ public Builder subscriptionTypes(SubscriptionType subscriptionTypes) {
return this;
}
+ /**
+ * Filter companies that have a pending scheduled downgrade
+ */
+ @JsonSetter(value = "has_scheduled_downgrade", nulls = Nulls.SKIP)
+ public Builder hasScheduledDowngrade(Optional hasScheduledDowngrade) {
+ this.hasScheduledDowngrade = hasScheduledDowngrade;
+ return this;
+ }
+
+ public Builder hasScheduledDowngrade(Boolean hasScheduledDowngrade) {
+ this.hasScheduledDowngrade = Optional.ofNullable(hasScheduledDowngrade);
+ return this;
+ }
+
/**
* Filter companies that have monetized subscriptions
*/
@@ -661,6 +692,7 @@ public ListCompaniesRequest build() {
planIds,
subscriptionStatuses,
subscriptionTypes,
+ hasScheduledDowngrade,
monetizedSubscriptions,
planId,
planVersionId,
diff --git a/src/main/java/com/schematic/api/resources/companies/requests/ListPlanChangesRequest.java b/src/main/java/com/schematic/api/resources/companies/requests/ListPlanChangesRequest.java
index e004aea..aa3452c 100644
--- a/src/main/java/com/schematic/api/resources/companies/requests/ListPlanChangesRequest.java
+++ b/src/main/java/com/schematic/api/resources/companies/requests/ListPlanChangesRequest.java
@@ -12,6 +12,8 @@
import com.fasterxml.jackson.annotation.Nulls;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.schematic.api.core.ObjectMappers;
+import com.schematic.api.types.PlanChangeAction;
+import com.schematic.api.types.PlanChangeBasePlanAction;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
@@ -26,9 +28,9 @@ public final class ListPlanChangesRequest {
private final Optional> planIds;
- private final Optional action;
+ private final Optional action;
- private final Optional basePlanAction;
+ private final Optional basePlanAction;
private final Optional companyId;
@@ -41,8 +43,8 @@ public final class ListPlanChangesRequest {
private ListPlanChangesRequest(
Optional> companyIds,
Optional> planIds,
- Optional action,
- Optional basePlanAction,
+ Optional action,
+ Optional basePlanAction,
Optional companyId,
Optional limit,
Optional offset,
@@ -68,12 +70,12 @@ public Optional> getPlanIds() {
}
@JsonProperty("action")
- public Optional getAction() {
+ public Optional getAction() {
return action;
}
@JsonProperty("base_plan_action")
- public Optional getBasePlanAction() {
+ public Optional getBasePlanAction() {
return basePlanAction;
}
@@ -146,9 +148,9 @@ public static final class Builder {
private Optional> planIds = Optional.empty();
- private Optional action = Optional.empty();
+ private Optional action = Optional.empty();
- private Optional basePlanAction = Optional.empty();
+ private Optional basePlanAction = Optional.empty();
private Optional companyId = Optional.empty();
@@ -205,23 +207,23 @@ public Builder planIds(String planIds) {
}
@JsonSetter(value = "action", nulls = Nulls.SKIP)
- public Builder action(Optional action) {
+ public Builder action(Optional action) {
this.action = action;
return this;
}
- public Builder action(String action) {
+ public Builder action(PlanChangeAction action) {
this.action = Optional.ofNullable(action);
return this;
}
@JsonSetter(value = "base_plan_action", nulls = Nulls.SKIP)
- public Builder basePlanAction(Optional basePlanAction) {
+ public Builder basePlanAction(Optional basePlanAction) {
this.basePlanAction = basePlanAction;
return this;
}
- public Builder basePlanAction(String basePlanAction) {
+ public Builder basePlanAction(PlanChangeBasePlanAction basePlanAction) {
this.basePlanAction = Optional.ofNullable(basePlanAction);
return this;
}
diff --git a/src/main/java/com/schematic/api/resources/companies/types/CountCompaniesParams.java b/src/main/java/com/schematic/api/resources/companies/types/CountCompaniesParams.java
index 8fb4650..3b58715 100644
--- a/src/main/java/com/schematic/api/resources/companies/types/CountCompaniesParams.java
+++ b/src/main/java/com/schematic/api/resources/companies/types/CountCompaniesParams.java
@@ -26,6 +26,8 @@
public final class CountCompaniesParams {
private final Optional> creditTypeIds;
+ private final Optional hasScheduledDowngrade;
+
private final Optional> ids;
private final Optional limit;
@@ -64,6 +66,7 @@ public final class CountCompaniesParams {
private CountCompaniesParams(
Optional> creditTypeIds,
+ Optional hasScheduledDowngrade,
Optional> ids,
Optional limit,
Optional monetizedSubscriptions,
@@ -83,6 +86,7 @@ private CountCompaniesParams(
Optional withoutSubscription,
Map additionalProperties) {
this.creditTypeIds = creditTypeIds;
+ this.hasScheduledDowngrade = hasScheduledDowngrade;
this.ids = ids;
this.limit = limit;
this.monetizedSubscriptions = monetizedSubscriptions;
@@ -111,6 +115,14 @@ public Optional> getCreditTypeIds() {
return creditTypeIds;
}
+ /**
+ * @return Filter companies that have a pending scheduled downgrade
+ */
+ @JsonProperty("has_scheduled_downgrade")
+ public Optional getHasScheduledDowngrade() {
+ return hasScheduledDowngrade;
+ }
+
/**
* @return Filter companies by multiple company IDs (starts with comp_)
*/
@@ -260,6 +272,7 @@ public Map getAdditionalProperties() {
private boolean equalTo(CountCompaniesParams other) {
return creditTypeIds.equals(other.creditTypeIds)
+ && hasScheduledDowngrade.equals(other.hasScheduledDowngrade)
&& ids.equals(other.ids)
&& limit.equals(other.limit)
&& monetizedSubscriptions.equals(other.monetizedSubscriptions)
@@ -283,6 +296,7 @@ private boolean equalTo(CountCompaniesParams other) {
public int hashCode() {
return Objects.hash(
this.creditTypeIds,
+ this.hasScheduledDowngrade,
this.ids,
this.limit,
this.monetizedSubscriptions,
@@ -315,6 +329,8 @@ public static Builder builder() {
public static final class Builder {
private Optional> creditTypeIds = Optional.empty();
+ private Optional hasScheduledDowngrade = Optional.empty();
+
private Optional> ids = Optional.empty();
private Optional limit = Optional.empty();
@@ -356,6 +372,7 @@ private Builder() {}
public Builder from(CountCompaniesParams other) {
creditTypeIds(other.getCreditTypeIds());
+ hasScheduledDowngrade(other.getHasScheduledDowngrade());
ids(other.getIds());
limit(other.getLimit());
monetizedSubscriptions(other.getMonetizedSubscriptions());
@@ -390,6 +407,20 @@ public Builder creditTypeIds(List creditTypeIds) {
return this;
}
+ /**
+ * Filter companies that have a pending scheduled downgrade
+ */
+ @JsonSetter(value = "has_scheduled_downgrade", nulls = Nulls.SKIP)
+ public Builder hasScheduledDowngrade(Optional hasScheduledDowngrade) {
+ this.hasScheduledDowngrade = hasScheduledDowngrade;
+ return this;
+ }
+
+ public Builder hasScheduledDowngrade(Boolean hasScheduledDowngrade) {
+ this.hasScheduledDowngrade = Optional.ofNullable(hasScheduledDowngrade);
+ return this;
+ }
+
/**
* Filter companies by multiple company IDs (starts with comp_)
*/
@@ -631,6 +662,7 @@ public Builder withoutSubscription(Boolean withoutSubscription) {
public CountCompaniesParams build() {
return new CountCompaniesParams(
creditTypeIds,
+ hasScheduledDowngrade,
ids,
limit,
monetizedSubscriptions,
diff --git a/src/main/java/com/schematic/api/resources/companies/types/ListCompaniesParams.java b/src/main/java/com/schematic/api/resources/companies/types/ListCompaniesParams.java
index e891234..c6ae112 100644
--- a/src/main/java/com/schematic/api/resources/companies/types/ListCompaniesParams.java
+++ b/src/main/java/com/schematic/api/resources/companies/types/ListCompaniesParams.java
@@ -26,6 +26,8 @@
public final class ListCompaniesParams {
private final Optional> creditTypeIds;
+ private final Optional hasScheduledDowngrade;
+
private final Optional> ids;
private final Optional limit;
@@ -64,6 +66,7 @@ public final class ListCompaniesParams {
private ListCompaniesParams(
Optional> creditTypeIds,
+ Optional hasScheduledDowngrade,
Optional> ids,
Optional limit,
Optional monetizedSubscriptions,
@@ -83,6 +86,7 @@ private ListCompaniesParams(
Optional withoutSubscription,
Map additionalProperties) {
this.creditTypeIds = creditTypeIds;
+ this.hasScheduledDowngrade = hasScheduledDowngrade;
this.ids = ids;
this.limit = limit;
this.monetizedSubscriptions = monetizedSubscriptions;
@@ -111,6 +115,14 @@ public Optional> getCreditTypeIds() {
return creditTypeIds;
}
+ /**
+ * @return Filter companies that have a pending scheduled downgrade
+ */
+ @JsonProperty("has_scheduled_downgrade")
+ public Optional getHasScheduledDowngrade() {
+ return hasScheduledDowngrade;
+ }
+
/**
* @return Filter companies by multiple company IDs (starts with comp_)
*/
@@ -260,6 +272,7 @@ public Map getAdditionalProperties() {
private boolean equalTo(ListCompaniesParams other) {
return creditTypeIds.equals(other.creditTypeIds)
+ && hasScheduledDowngrade.equals(other.hasScheduledDowngrade)
&& ids.equals(other.ids)
&& limit.equals(other.limit)
&& monetizedSubscriptions.equals(other.monetizedSubscriptions)
@@ -283,6 +296,7 @@ private boolean equalTo(ListCompaniesParams other) {
public int hashCode() {
return Objects.hash(
this.creditTypeIds,
+ this.hasScheduledDowngrade,
this.ids,
this.limit,
this.monetizedSubscriptions,
@@ -315,6 +329,8 @@ public static Builder builder() {
public static final class Builder {
private Optional> creditTypeIds = Optional.empty();
+ private Optional hasScheduledDowngrade = Optional.empty();
+
private Optional> ids = Optional.empty();
private Optional limit = Optional.empty();
@@ -356,6 +372,7 @@ private Builder() {}
public Builder from(ListCompaniesParams other) {
creditTypeIds(other.getCreditTypeIds());
+ hasScheduledDowngrade(other.getHasScheduledDowngrade());
ids(other.getIds());
limit(other.getLimit());
monetizedSubscriptions(other.getMonetizedSubscriptions());
@@ -390,6 +407,20 @@ public Builder creditTypeIds(List creditTypeIds) {
return this;
}
+ /**
+ * Filter companies that have a pending scheduled downgrade
+ */
+ @JsonSetter(value = "has_scheduled_downgrade", nulls = Nulls.SKIP)
+ public Builder hasScheduledDowngrade(Optional hasScheduledDowngrade) {
+ this.hasScheduledDowngrade = hasScheduledDowngrade;
+ return this;
+ }
+
+ public Builder hasScheduledDowngrade(Boolean hasScheduledDowngrade) {
+ this.hasScheduledDowngrade = Optional.ofNullable(hasScheduledDowngrade);
+ return this;
+ }
+
/**
* Filter companies by multiple company IDs (starts with comp_)
*/
@@ -631,6 +662,7 @@ public Builder withoutSubscription(Boolean withoutSubscription) {
public ListCompaniesParams build() {
return new ListCompaniesParams(
creditTypeIds,
+ hasScheduledDowngrade,
ids,
limit,
monetizedSubscriptions,
diff --git a/src/main/java/com/schematic/api/resources/companies/types/ListPlanChangesParams.java b/src/main/java/com/schematic/api/resources/companies/types/ListPlanChangesParams.java
index 4132ac5..b694f5e 100644
--- a/src/main/java/com/schematic/api/resources/companies/types/ListPlanChangesParams.java
+++ b/src/main/java/com/schematic/api/resources/companies/types/ListPlanChangesParams.java
@@ -12,6 +12,8 @@
import com.fasterxml.jackson.annotation.Nulls;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.schematic.api.core.ObjectMappers;
+import com.schematic.api.types.PlanChangeAction;
+import com.schematic.api.types.PlanChangeBasePlanAction;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@@ -21,9 +23,9 @@
@JsonInclude(JsonInclude.Include.NON_ABSENT)
@JsonDeserialize(builder = ListPlanChangesParams.Builder.class)
public final class ListPlanChangesParams {
- private final Optional action;
+ private final Optional action;
- private final Optional basePlanAction;
+ private final Optional basePlanAction;
private final Optional