schematichq 1.4.2 → 1.4.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.fern/metadata.json +2 -2
- data/README.md +33 -3
- data/WASM_VERSION +1 -1
- data/lib/schematic/accounts/client.rb +44 -0
- data/lib/schematic/accounts/types/count_account_members_params.rb +15 -0
- data/lib/schematic/accounts/types/count_account_members_request.rb +14 -0
- data/lib/schematic/accounts/types/count_account_members_response.rb +12 -0
- data/lib/schematic/billing/client.rb +32 -0
- data/lib/schematic/billing/types/delete_payment_method_by_external_id_response.rb +12 -0
- data/lib/schematic/client.rb +1 -1
- data/lib/schematic/companies/client.rb +6 -2
- data/lib/schematic/companies/types/count_companies_params.rb +1 -0
- data/lib/schematic/companies/types/count_companies_request.rb +1 -0
- data/lib/schematic/companies/types/list_companies_params.rb +1 -0
- data/lib/schematic/companies/types/list_companies_request.rb +1 -0
- data/lib/schematic/credits/client.rb +102 -0
- data/lib/schematic/credits/types/acquire_credit_lease_request_body.rb +14 -0
- data/lib/schematic/credits/types/acquire_credit_lease_response.rb +12 -0
- data/lib/schematic/credits/types/extend_credit_lease_request_body.rb +13 -0
- data/lib/schematic/credits/types/extend_credit_lease_response.rb +12 -0
- data/lib/schematic/credits/types/release_credit_lease_response.rb +12 -0
- data/lib/schematic/datastream/merge.rb +71 -0
- data/lib/schematic/entitlements/types/create_billing_linked_plan_entitlement_request_body.rb +1 -0
- data/lib/schematic/entitlements/types/create_plan_entitlement_request_body.rb +1 -0
- data/lib/schematic/entitlements/types/update_plan_entitlement_request_body.rb +1 -0
- data/lib/schematic/event_buffer.rb +7 -1
- data/lib/schematic/integrationsapi/client.rb +99 -3
- data/lib/schematic/integrationsapi/types/assume_stripe_installed_response.rb +12 -0
- data/lib/schematic/integrationsapi/types/install_integration_response.rb +12 -0
- data/lib/schematic/integrationsapi/types/install_stripe_response.rb +12 -0
- data/lib/schematic/integrationsapi/types/{load_sample_data_set_v_2_response.rb → load_sample_data_set_response.rb} +1 -1
- data/lib/schematic/logger.rb +1 -1
- data/lib/schematic/plangroups/types/create_plan_group_request_body.rb +1 -0
- data/lib/schematic/plangroups/types/update_plan_group_request_body.rb +1 -0
- data/lib/schematic/planmigrations/client.rb +101 -0
- data/lib/schematic/planmigrations/types/create_migration_input.rb +17 -0
- data/lib/schematic/planmigrations/types/create_migration_response.rb +12 -0
- data/lib/schematic/planmigrations/types/retry_company_migration_response.rb +12 -0
- data/lib/schematic/planmigrations/types/retry_migration_request_body.rb +12 -0
- data/lib/schematic/planmigrations/types/retry_migration_response.rb +12 -0
- data/lib/schematic/plans/client.rb +39 -2
- data/lib/schematic/plans/types/count_plans_params.rb +1 -0
- data/lib/schematic/plans/types/count_plans_request.rb +1 -0
- data/lib/schematic/plans/types/list_plans_params.rb +1 -0
- data/lib/schematic/plans/types/list_plans_request.rb +1 -0
- data/lib/schematic/plans/types/mark_custom_plan_billing_paid_response.rb +12 -0
- data/lib/schematic/schematic_client.rb +46 -13
- data/lib/schematic/types/account_member_response_data.rb +2 -0
- data/lib/schematic/types/billing_credit_grant_reason.rb +1 -0
- data/lib/schematic/types/billing_credit_grant_response_data.rb +3 -0
- data/lib/schematic/types/billing_credit_ledger_authority.rb +13 -0
- data/lib/schematic/types/billing_credit_view.rb +1 -0
- data/lib/schematic/types/billing_plan_credit_grant_response_data.rb +1 -0
- data/lib/schematic/types/billing_provider_type.rb +1 -0
- data/lib/schematic/types/change_subscription_internal_request_body.rb +1 -0
- data/lib/schematic/types/change_subscription_request_body.rb +1 -0
- data/lib/schematic/types/checkout_data_response_data.rb +1 -0
- data/lib/schematic/types/checkout_field_input.rb +14 -0
- data/lib/schematic/types/checkout_field_response_data.rb +18 -0
- data/lib/schematic/types/checkout_field_value.rb +10 -0
- data/lib/schematic/types/checkout_field_with_value.rb +15 -0
- data/lib/schematic/types/checkout_subscription.rb +1 -0
- data/lib/schematic/types/company_credit_balance_response_data.rb +2 -0
- data/lib/schematic/types/company_plan_credit_grant_view.rb +1 -0
- data/lib/schematic/types/company_plan_detail_response_data.rb +2 -1
- data/lib/schematic/types/component_hydrate_response_data.rb +1 -0
- data/lib/schematic/types/component_preview_response_data.rb +1 -0
- data/lib/schematic/types/create_billing_plan_credit_grant_request_body.rb +1 -0
- data/lib/schematic/types/create_entitlement_in_bundle_request_body.rb +1 -0
- data/lib/schematic/types/credit_company_grant_view.rb +3 -0
- data/lib/schematic/types/credit_event_ledger_response_data.rb +1 -0
- data/lib/schematic/types/credit_lease_response_data.rb +16 -0
- data/lib/schematic/types/credit_usage_reason.rb +15 -0
- data/lib/schematic/types/custom_plan_billing_response_data.rb +1 -0
- data/lib/schematic/types/event_body_track.rb +1 -0
- data/lib/schematic/types/event_detail_response_data.rb +1 -0
- data/lib/schematic/types/event_response_data.rb +1 -0
- data/lib/schematic/types/feature_view.rb +1 -0
- data/lib/schematic/types/install_integration_request_body.rb +14 -0
- data/lib/schematic/types/integration_config.rb +2 -0
- data/lib/schematic/types/integration_install_config.rb +18 -0
- data/lib/schematic/types/integration_install_response_data.rb +11 -0
- data/lib/schematic/types/integration_type.rb +2 -0
- data/lib/schematic/types/manage_plan_request.rb +1 -0
- data/lib/schematic/types/mark_custom_plan_billing_paid_request_body.rb +23 -0
- data/lib/schematic/types/metronome_integration_config.rb +7 -0
- data/lib/schematic/types/migration_error_code.rb +22 -0
- data/lib/schematic/types/plan_credit_grant_view.rb +1 -0
- data/lib/schematic/types/plan_detail_response_data.rb +1 -0
- data/lib/schematic/types/plan_entitlement_response_data.rb +1 -0
- data/lib/schematic/types/plan_group_detail_response_data.rb +1 -0
- data/lib/schematic/types/plan_group_plan_detail_response_data.rb +2 -1
- data/lib/schematic/types/plan_price_cadence.rb +13 -0
- data/lib/schematic/types/plan_version_company_migration_response_data.rb +1 -0
- data/lib/schematic/types/plan_version_migration_response_data.rb +1 -0
- data/lib/schematic/types/plan_view_public_response_data.rb +2 -1
- data/lib/schematic/types/release_credit_lease_request_body.rb +23 -0
- data/lib/schematic/types/stripe_integration_config.rb +0 -1
- data/lib/schematic/types/update_billing_plan_credit_grant_request_body.rb +1 -0
- data/lib/schematic/types/usage_based_entitlement_request_body.rb +1 -0
- data/lib/schematic/types/usage_based_entitlement_response_data.rb +1 -0
- data/lib/schematic/types/work_os_integration_config.rb +10 -0
- data/lib/schematic/version.rb +1 -1
- data/lib/schematic/wasm/rulesengine.wasm +0 -0
- data/lib/schematic.rb +38 -4
- data/reference.md +906 -73
- metadata +37 -3
|
@@ -5,8 +5,10 @@ module Schematic
|
|
|
5
5
|
class AccountMemberResponseData < Internal::Types::Model
|
|
6
6
|
field :created_at, -> { String }, optional: false, nullable: false
|
|
7
7
|
field :email, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :first_name, -> { String }, optional: true, nullable: false
|
|
8
9
|
field :id, -> { String }, optional: false, nullable: false
|
|
9
10
|
field :image_url, -> { String }, optional: true, nullable: false
|
|
11
|
+
field :last_name, -> { String }, optional: true, nullable: false
|
|
10
12
|
field :name, -> { String }, optional: true, nullable: false
|
|
11
13
|
field :permissions, -> { Internal::Types::Hash[String, Internal::Types::Array[Schematic::Types::AccountMemberPermission]] }, optional: false, nullable: false
|
|
12
14
|
field :role, -> { Schematic::Types::AccountMemberRole }, optional: true, nullable: false
|
|
@@ -21,6 +21,9 @@ module Schematic
|
|
|
21
21
|
field :quantity_used, -> { Integer }, optional: false, nullable: false
|
|
22
22
|
field :renewal_enabled, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
23
23
|
field :renewal_period, -> { Schematic::Types::BillingPlanCreditGrantResetCadence }, optional: true, nullable: false
|
|
24
|
+
field :reserved, -> { Integer }, optional: true, nullable: false
|
|
25
|
+
field :settled, -> { Integer }, optional: true, nullable: false
|
|
26
|
+
field :source_grant_id, -> { String }, optional: true, nullable: false
|
|
24
27
|
field :source_label, -> { String }, optional: false, nullable: false
|
|
25
28
|
field :transfers, -> { Internal::Types::Array[Schematic::Types::CreditTransferResponseData] }, optional: true, nullable: false
|
|
26
29
|
field :updated_at, -> { String }, optional: false, nullable: false
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
module BillingCreditLedgerAuthority
|
|
6
|
+
extend Schematic::Internal::Types::Enum
|
|
7
|
+
|
|
8
|
+
SCHEMATIC_AUTHORITATIVE = "schematic_authoritative"
|
|
9
|
+
EXTERNAL_MIRROR = "external_mirror"
|
|
10
|
+
EXTERNAL_RATED = "external_rated"
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
@@ -15,6 +15,7 @@ module Schematic
|
|
|
15
15
|
field :environment_id, -> { String }, optional: false, nullable: false
|
|
16
16
|
field :icon, -> { String }, optional: true, nullable: false
|
|
17
17
|
field :id, -> { String }, optional: false, nullable: false
|
|
18
|
+
field :ledger_authority, -> { Schematic::Types::BillingCreditLedgerAuthority }, optional: false, nullable: false
|
|
18
19
|
field :name, -> { String }, optional: false, nullable: false
|
|
19
20
|
field :plural_name, -> { String }, optional: true, nullable: false
|
|
20
21
|
field :price, -> { Schematic::Types::BillingPriceView }, optional: true, nullable: false
|
|
@@ -30,6 +30,7 @@ module Schematic
|
|
|
30
30
|
field :reset_cadence, -> { Schematic::Types::BillingPlanCreditGrantResetCadence }, optional: true, nullable: false
|
|
31
31
|
field :reset_start, -> { Schematic::Types::BillingPlanCreditGrantResetStart }, optional: true, nullable: false
|
|
32
32
|
field :reset_type, -> { Schematic::Types::BillingPlanCreditGrantResetType }, optional: true, nullable: false
|
|
33
|
+
field :rollover_percentage, -> { Integer }, optional: false, nullable: false
|
|
33
34
|
field :updated_at, -> { String }, optional: false, nullable: false
|
|
34
35
|
end
|
|
35
36
|
end
|
|
@@ -8,6 +8,7 @@ module Schematic
|
|
|
8
8
|
field :company_id, -> { String }, optional: false, nullable: false
|
|
9
9
|
field :coupon_external_id, -> { String }, optional: true, nullable: false
|
|
10
10
|
field :credit_bundles, -> { Internal::Types::Array[Schematic::Types::UpdateCreditBundleRequestBody] }, optional: false, nullable: false
|
|
11
|
+
field :custom_field_values, -> { Internal::Types::Array[Schematic::Types::CheckoutFieldValue] }, optional: false, nullable: false
|
|
11
12
|
field :new_plan_id, -> { String }, optional: false, nullable: false
|
|
12
13
|
field :new_price_id, -> { String }, optional: false, nullable: false
|
|
13
14
|
field :pay_in_advance, -> { Internal::Types::Array[Schematic::Types::UpdatePayInAdvanceRequestBody] }, optional: false, nullable: false
|
|
@@ -7,6 +7,7 @@ module Schematic
|
|
|
7
7
|
field :auto_topup_overrides, -> { Internal::Types::Array[Schematic::Types::UpdateAutoTopupOverrideRequestBody] }, optional: false, nullable: false
|
|
8
8
|
field :coupon_external_id, -> { String }, optional: true, nullable: false
|
|
9
9
|
field :credit_bundles, -> { Internal::Types::Array[Schematic::Types::UpdateCreditBundleRequestBody] }, optional: false, nullable: false
|
|
10
|
+
field :custom_field_values, -> { Internal::Types::Array[Schematic::Types::CheckoutFieldValue] }, optional: false, nullable: false
|
|
10
11
|
field :new_plan_id, -> { String }, optional: false, nullable: false
|
|
11
12
|
field :new_price_id, -> { String }, optional: false, nullable: false
|
|
12
13
|
field :pay_in_advance, -> { Internal::Types::Array[Schematic::Types::UpdatePayInAdvanceRequestBody] }, optional: false, nullable: false
|
|
@@ -8,6 +8,7 @@ module Schematic
|
|
|
8
8
|
field :active_usage_based_entitlements, -> { Internal::Types::Array[Schematic::Types::UsageBasedEntitlementResponseData] }, optional: false, nullable: false
|
|
9
9
|
field :available_credit_bundles, -> { Internal::Types::Array[Schematic::Types::BillingCreditBundleResponseData] }, optional: false, nullable: false
|
|
10
10
|
field :company, -> { Schematic::Types::CompanyDetailResponseData }, optional: true, nullable: false
|
|
11
|
+
field :custom_checkout_fields, -> { Internal::Types::Array[Schematic::Types::CheckoutFieldWithValue] }, optional: false, nullable: false
|
|
11
12
|
field :feature_usage, -> { Schematic::Types::FeatureUsageDetailResponseData }, optional: true, nullable: false
|
|
12
13
|
field :selected_credit_bundles, -> { Internal::Types::Array[Schematic::Types::CreditBundlePurchaseResponseData] }, optional: false, nullable: false
|
|
13
14
|
field :selected_plan, -> { Schematic::Types::PlanDetailResponseData }, optional: true, nullable: false
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class CheckoutFieldInput < Internal::Types::Model
|
|
6
|
+
field :definition_id, -> { String }, optional: true, nullable: false
|
|
7
|
+
field :helper_text, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :id, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :name, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :required, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
11
|
+
field :stripe_metadata_key, -> { String }, optional: false, nullable: false
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class CheckoutFieldResponseData < Internal::Types::Model
|
|
6
|
+
field :created_at, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :definition_id, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :helper_text, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :name, -> { String }, optional: false, nullable: false
|
|
11
|
+
field :position, -> { Integer }, optional: false, nullable: false
|
|
12
|
+
field :required, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
13
|
+
field :stripe_metadata_key, -> { String }, optional: false, nullable: false
|
|
14
|
+
field :trait_hierarchy, -> { Internal::Types::Array[String] }, optional: false, nullable: false
|
|
15
|
+
field :updated_at, -> { String }, optional: false, nullable: false
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class CheckoutFieldValue < Internal::Types::Model
|
|
6
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :value, -> { String }, optional: false, nullable: false
|
|
8
|
+
end
|
|
9
|
+
end
|
|
10
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class CheckoutFieldWithValue < Internal::Types::Model
|
|
6
|
+
field :definition_id, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :helper_text, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
9
|
+
field :name, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :required, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
11
|
+
field :stripe_metadata_key, -> { String }, optional: false, nullable: false
|
|
12
|
+
field :value, -> { String }, optional: true, nullable: false
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -16,6 +16,7 @@ module Schematic
|
|
|
16
16
|
field :expired_at, -> { String }, optional: true, nullable: false
|
|
17
17
|
field :id, -> { String }, optional: false, nullable: false
|
|
18
18
|
field :interval, -> { String }, optional: false, nullable: false
|
|
19
|
+
field :invoice_id, -> { String }, optional: true, nullable: false
|
|
19
20
|
field :invoice_url, -> { String }, optional: true, nullable: false
|
|
20
21
|
field :metadata, -> { Internal::Types::Hash[String, Object] }, optional: true, nullable: false
|
|
21
22
|
field :period_end, -> { Integer }, optional: false, nullable: false
|
|
@@ -5,6 +5,8 @@ module Schematic
|
|
|
5
5
|
class CompanyCreditBalanceResponseData < Internal::Types::Model
|
|
6
6
|
field :credit_id, -> { String }, optional: false, nullable: false
|
|
7
7
|
field :remaining, -> { Integer }, optional: false, nullable: false
|
|
8
|
+
field :reserved, -> { Integer }, optional: false, nullable: false
|
|
9
|
+
field :settled, -> { Integer }, optional: false, nullable: false
|
|
8
10
|
field :source, -> { Schematic::Types::BillingProviderType }, optional: false, nullable: false
|
|
9
11
|
field :total, -> { Integer }, optional: true, nullable: false
|
|
10
12
|
end
|
|
@@ -33,6 +33,7 @@ module Schematic
|
|
|
33
33
|
field :reset_cadence, -> { Schematic::Types::BillingPlanCreditGrantResetCadence }, optional: true, nullable: false
|
|
34
34
|
field :reset_start, -> { Schematic::Types::BillingPlanCreditGrantResetStart }, optional: true, nullable: false
|
|
35
35
|
field :reset_type, -> { Schematic::Types::BillingPlanCreditGrantResetType }, optional: false, nullable: false
|
|
36
|
+
field :rollover_percentage, -> { Integer }, optional: false, nullable: false
|
|
36
37
|
field :singular_name, -> { String }, optional: true, nullable: false
|
|
37
38
|
field :updated_at, -> { String }, optional: false, nullable: false
|
|
38
39
|
end
|
|
@@ -5,6 +5,7 @@ module Schematic
|
|
|
5
5
|
class CompanyPlanDetailResponseData < Internal::Types::Model
|
|
6
6
|
field :active_version, -> { Schematic::Types::PlanVersionResponseData }, optional: true, nullable: false
|
|
7
7
|
field :audience_type, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :available_periods, -> { Internal::Types::Array[Schematic::Types::PlanPriceCadence] }, optional: false, nullable: false
|
|
8
9
|
field :billing_linked_resource, -> { Schematic::Types::BillingLinkedResourceResponseData }, optional: true, nullable: false
|
|
9
10
|
field :billing_product, -> { Schematic::Types::BillingProductDetailResponseData }, optional: true, nullable: false
|
|
10
11
|
field :billing_strategy, -> { Schematic::Types::BillingStrategy }, optional: false, nullable: false
|
|
@@ -23,7 +24,7 @@ module Schematic
|
|
|
23
24
|
field :custom_plan_config, -> { Schematic::Types::CustomPlanConfig }, optional: true, nullable: false
|
|
24
25
|
field :description, -> { String }, optional: false, nullable: false
|
|
25
26
|
field :draft_version, -> { Schematic::Types::PlanVersionResponseData }, optional: true, nullable: false
|
|
26
|
-
field :entitlements, -> { Internal::Types::Array[Schematic::Types::PlanEntitlementResponseData] }, optional:
|
|
27
|
+
field :entitlements, -> { Internal::Types::Array[Schematic::Types::PlanEntitlementResponseData] }, optional: true, nullable: false
|
|
27
28
|
field :features, -> { Internal::Types::Array[Schematic::Types::FeatureInPlanResponseData] }, optional: false, nullable: false
|
|
28
29
|
field :icon, -> { Schematic::Types::PlanIcon }, optional: false, nullable: false
|
|
29
30
|
field :id, -> { String }, optional: false, nullable: false
|
|
@@ -13,6 +13,7 @@ module Schematic
|
|
|
13
13
|
field :component, -> { Schematic::Types::ComponentResponseData }, optional: true, nullable: false
|
|
14
14
|
field :credit_bundles, -> { Internal::Types::Array[Schematic::Types::BillingCreditBundleView] }, optional: false, nullable: false
|
|
15
15
|
field :credit_grants, -> { Internal::Types::Array[Schematic::Types::CreditCompanyGrantView] }, optional: false, nullable: false
|
|
16
|
+
field :custom_checkout_fields, -> { Internal::Types::Array[Schematic::Types::CheckoutFieldWithValue] }, optional: false, nullable: false
|
|
16
17
|
field :default_plan, -> { Schematic::Types::PlanDetailResponseData }, optional: true, nullable: false
|
|
17
18
|
field :display_settings, -> { Schematic::Types::ComponentDisplaySettings }, optional: false, nullable: false
|
|
18
19
|
field :feature_usage, -> { Schematic::Types::FeatureUsageDetailResponseData }, optional: true, nullable: false
|
|
@@ -13,6 +13,7 @@ module Schematic
|
|
|
13
13
|
field :component, -> { Schematic::Types::ComponentResponseData }, optional: true, nullable: false
|
|
14
14
|
field :credit_bundles, -> { Internal::Types::Array[Schematic::Types::BillingCreditBundleView] }, optional: false, nullable: false
|
|
15
15
|
field :credit_grants, -> { Internal::Types::Array[Schematic::Types::CreditCompanyGrantView] }, optional: false, nullable: false
|
|
16
|
+
field :custom_checkout_fields, -> { Internal::Types::Array[Schematic::Types::CheckoutFieldWithValue] }, optional: false, nullable: false
|
|
16
17
|
field :default_plan, -> { Schematic::Types::PlanDetailResponseData }, optional: true, nullable: false
|
|
17
18
|
field :display_settings, -> { Schematic::Types::ComponentDisplaySettings }, optional: false, nullable: false
|
|
18
19
|
field :feature_usage, -> { Schematic::Types::FeatureUsageDetailResponseData }, optional: true, nullable: false
|
|
@@ -23,6 +23,7 @@ module Schematic
|
|
|
23
23
|
field :reset_cadence, -> { Schematic::Types::BillingPlanCreditGrantResetCadence }, optional: false, nullable: false
|
|
24
24
|
field :reset_start, -> { Schematic::Types::BillingPlanCreditGrantResetStart }, optional: false, nullable: false
|
|
25
25
|
field :reset_type, -> { Schematic::Types::BillingPlanCreditGrantResetType }, optional: true, nullable: false
|
|
26
|
+
field :rollover_percentage, -> { Integer }, optional: true, nullable: false
|
|
26
27
|
end
|
|
27
28
|
end
|
|
28
29
|
end
|
|
@@ -26,6 +26,7 @@ module Schematic
|
|
|
26
26
|
field :quarterly_unit_price_decimal, -> { String }, optional: true, nullable: false
|
|
27
27
|
field :soft_limit, -> { Integer }, optional: true, nullable: false
|
|
28
28
|
field :tier_mode, -> { Schematic::Types::BillingTiersMode }, optional: true, nullable: false
|
|
29
|
+
field :usage_quantity, -> { Integer }, optional: true, nullable: false
|
|
29
30
|
field :value_bool, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
30
31
|
field :value_credit_id, -> { String }, optional: true, nullable: false
|
|
31
32
|
field :value_numeric, -> { Integer }, optional: true, nullable: false
|
|
@@ -28,7 +28,10 @@ module Schematic
|
|
|
28
28
|
field :quantity_used, -> { Integer }, optional: false, nullable: false
|
|
29
29
|
field :renewal_enabled, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
30
30
|
field :renewal_period, -> { Schematic::Types::BillingPlanCreditGrantResetCadence }, optional: true, nullable: false
|
|
31
|
+
field :reserved, -> { Integer }, optional: true, nullable: false
|
|
32
|
+
field :settled, -> { Integer }, optional: true, nullable: false
|
|
31
33
|
field :singular_name, -> { String }, optional: true, nullable: false
|
|
34
|
+
field :source_grant_id, -> { String }, optional: true, nullable: false
|
|
32
35
|
field :source_label, -> { String }, optional: false, nullable: false
|
|
33
36
|
field :transfers, -> { Internal::Types::Array[Schematic::Types::CreditTransferView] }, optional: true, nullable: false
|
|
34
37
|
field :updated_at, -> { String }, optional: false, nullable: false
|
|
@@ -33,6 +33,7 @@ module Schematic
|
|
|
33
33
|
field :source_id, -> { Integer }, optional: false, nullable: false
|
|
34
34
|
field :to_grant_id, -> { String }, optional: true, nullable: false
|
|
35
35
|
field :usage_event_id, -> { String }, optional: true, nullable: false
|
|
36
|
+
field :usage_reason, -> { Schematic::Types::CreditUsageReason }, optional: true, nullable: false
|
|
36
37
|
field :zeroed_out_reason, -> { Schematic::Types::BillingCreditGrantZeroedOutReason }, optional: true, nullable: false
|
|
37
38
|
end
|
|
38
39
|
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class CreditLeaseResponseData < Internal::Types::Model
|
|
6
|
+
field :company_id, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :created_at, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :credit_type_id, -> { String }, optional: false, nullable: false
|
|
9
|
+
field :expires_at, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :granted_amount, -> { Integer }, optional: false, nullable: false
|
|
11
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
12
|
+
field :released_at, -> { String }, optional: true, nullable: false
|
|
13
|
+
field :updated_at, -> { String }, optional: false, nullable: false
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
module CreditUsageReason
|
|
6
|
+
extend Schematic::Internal::Types::Enum
|
|
7
|
+
|
|
8
|
+
LEASE_HOLD = "lease_hold"
|
|
9
|
+
LEASE_RELEASE = "lease_release"
|
|
10
|
+
MANUAL_ADJUSTMENT = "manual_adjustment"
|
|
11
|
+
RECONCILIATION = "reconciliation"
|
|
12
|
+
TRACK = "track"
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -7,6 +7,7 @@ module Schematic
|
|
|
7
7
|
field :company_id, -> { String }, optional: false, nullable: false
|
|
8
8
|
field :created_at, -> { String }, optional: false, nullable: false
|
|
9
9
|
field :days_until_due, -> { Integer }, optional: false, nullable: false
|
|
10
|
+
field :external_invoice_id, -> { String }, optional: true, nullable: false
|
|
10
11
|
field :id, -> { String }, optional: false, nullable: false
|
|
11
12
|
field :paid_at, -> { String }, optional: true, nullable: false
|
|
12
13
|
field :plan_id, -> { String }, optional: false, nullable: false
|
|
@@ -5,6 +5,7 @@ module Schematic
|
|
|
5
5
|
class EventBodyTrack < Internal::Types::Model
|
|
6
6
|
field :company, -> { Internal::Types::Hash[String, String] }, optional: true, nullable: false
|
|
7
7
|
field :event, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :lease_id, -> { String }, optional: true, nullable: false
|
|
8
9
|
field :quantity, -> { Integer }, optional: true, nullable: false
|
|
9
10
|
field :traits, -> { Internal::Types::Hash[String, Object] }, optional: true, nullable: false
|
|
10
11
|
field :user, -> { Internal::Types::Hash[String, String] }, optional: true, nullable: false
|
|
@@ -17,6 +17,7 @@ module Schematic
|
|
|
17
17
|
field :features, -> { Internal::Types::Array[Schematic::Types::PreviewObject] }, optional: false, nullable: false
|
|
18
18
|
field :id, -> { String }, optional: false, nullable: false
|
|
19
19
|
field :idempotency_key, -> { String }, optional: true, nullable: false
|
|
20
|
+
field :lease_id, -> { String }, optional: true, nullable: false
|
|
20
21
|
field :loaded_at, -> { String }, optional: true, nullable: false
|
|
21
22
|
field :processed_at, -> { String }, optional: true, nullable: false
|
|
22
23
|
field :quantity, -> { Integer }, optional: false, nullable: false
|
|
@@ -14,6 +14,7 @@ module Schematic
|
|
|
14
14
|
field :feature_ids, -> { Internal::Types::Array[String] }, optional: false, nullable: false
|
|
15
15
|
field :id, -> { String }, optional: false, nullable: false
|
|
16
16
|
field :idempotency_key, -> { String }, optional: true, nullable: false
|
|
17
|
+
field :lease_id, -> { String }, optional: true, nullable: false
|
|
17
18
|
field :loaded_at, -> { String }, optional: true, nullable: false
|
|
18
19
|
field :processed_at, -> { String }, optional: true, nullable: false
|
|
19
20
|
field :quantity, -> { Integer }, optional: false, nullable: false
|
|
@@ -21,6 +21,7 @@ module Schematic
|
|
|
21
21
|
field :trait, -> { Schematic::Types::EntityTraitDefinitionResponseData }, optional: true, nullable: false
|
|
22
22
|
field :trait_id, -> { String }, optional: true, nullable: false
|
|
23
23
|
field :updated_at, -> { String }, optional: false, nullable: false
|
|
24
|
+
field :usage_limit_trait_id, -> { String }, optional: true, nullable: false
|
|
24
25
|
end
|
|
25
26
|
end
|
|
26
27
|
end
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class InstallIntegrationRequestBody < Internal::Types::Model
|
|
6
|
+
field :company_matching_criteria, -> { Schematic::Types::CompanyMatchingCriteria }, optional: true, nullable: false
|
|
7
|
+
field :company_matching_field, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :config, -> { Internal::Types::Hash[String, Object] }, optional: true, nullable: false
|
|
9
|
+
field :is_sandbox, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
10
|
+
field :live_mode, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
11
|
+
field :type, -> { Schematic::Types::IntegrationType }, optional: false, nullable: false
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
@@ -8,8 +8,10 @@ module Schematic
|
|
|
8
8
|
discriminant :type
|
|
9
9
|
|
|
10
10
|
member -> { Schematic::Types::ClerkIntegrationConfig }, key: "CLERK"
|
|
11
|
+
member -> { Schematic::Types::MetronomeIntegrationConfig }, key: "METRONOME"
|
|
11
12
|
member -> { Schematic::Types::OrbIntegrationConfig }, key: "ORB"
|
|
12
13
|
member -> { Schematic::Types::StripeIntegrationConfig }, key: "STRIPE"
|
|
14
|
+
member -> { Schematic::Types::WorkOsIntegrationConfig }, key: "WORKOS"
|
|
13
15
|
end
|
|
14
16
|
end
|
|
15
17
|
end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class IntegrationInstallConfig < Internal::Types::Model
|
|
6
|
+
field :company_matching_criteria, -> { Schematic::Types::CompanyMatchingCriteria }, optional: true, nullable: false
|
|
7
|
+
field :company_matching_field, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :config, -> { Schematic::Types::IntegrationConfig }, optional: true, nullable: false
|
|
9
|
+
field :created_at, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
11
|
+
field :integration_id, -> { String }, optional: false, nullable: false
|
|
12
|
+
field :is_app_install, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
13
|
+
field :is_connect_install, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
14
|
+
field :live_mode, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
15
|
+
field :updated_at, -> { String }, optional: false, nullable: false
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class IntegrationInstallResponseData < Internal::Types::Model
|
|
6
|
+
field :capabilities, -> { Schematic::Types::IntegrationCapabilities }, optional: false, nullable: false
|
|
7
|
+
field :config, -> { Schematic::Types::IntegrationInstallConfig }, optional: false, nullable: false
|
|
8
|
+
field :integration, -> { Schematic::Types::IntegrationResponseData }, optional: false, nullable: false
|
|
9
|
+
end
|
|
10
|
+
end
|
|
11
|
+
end
|
|
@@ -11,6 +11,7 @@ module Schematic
|
|
|
11
11
|
field :company_id, -> { String }, optional: false, nullable: false
|
|
12
12
|
field :coupon_external_id, -> { String }, optional: true, nullable: false
|
|
13
13
|
field :credit_bundles, -> { Internal::Types::Array[Schematic::Types::UpdateCreditBundleRequestBody] }, optional: false, nullable: false
|
|
14
|
+
field :custom_field_values, -> { Internal::Types::Array[Schematic::Types::CheckoutFieldValue] }, optional: false, nullable: false
|
|
14
15
|
field :pay_in_advance_entitlements, -> { Internal::Types::Array[Schematic::Types::UpdatePayInAdvanceRequestBody] }, optional: false, nullable: false
|
|
15
16
|
field :payment_method_external_id, -> { String }, optional: true, nullable: false
|
|
16
17
|
field :promo_code, -> { String }, optional: true, nullable: false
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
module MarkCustomPlanBillingPaidRequestBody
|
|
6
|
+
# MarkCustomPlanBillingPaidRequestBody is an alias for Hash
|
|
7
|
+
|
|
8
|
+
# @option str [String]
|
|
9
|
+
#
|
|
10
|
+
# @return [untyped]
|
|
11
|
+
def self.load(str)
|
|
12
|
+
::JSON.parse(str)
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
# @option value [untyped]
|
|
16
|
+
#
|
|
17
|
+
# @return [String]
|
|
18
|
+
def self.dump(value)
|
|
19
|
+
::JSON.generate(value)
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
23
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
module MigrationErrorCode
|
|
6
|
+
extend Schematic::Internal::Types::Enum
|
|
7
|
+
|
|
8
|
+
AMBIGUOUS_SUBSCRIPTION_ITEM = "ambiguous_subscription_item"
|
|
9
|
+
MULTIPLE_SUBSCRIPTIONS = "multiple_subscriptions"
|
|
10
|
+
NO_PRICE_FOR_INTERVAL = "no_price_for_interval"
|
|
11
|
+
NOT_ON_ORIGIN_VERSION = "not_on_origin_version"
|
|
12
|
+
OPERATION_ITEM_NOT_FOUND = "operation_item_not_found"
|
|
13
|
+
PERMANENT_CONFIG = "permanent_config"
|
|
14
|
+
PERMANENT_DECLINE = "permanent_decline"
|
|
15
|
+
TRANSIENT_DECLINE = "transient_decline"
|
|
16
|
+
TRANSIENT_INFRA = "transient_infra"
|
|
17
|
+
TRANSIENT_STRIPE = "transient_stripe"
|
|
18
|
+
UNKNOWN = "unknown"
|
|
19
|
+
WOULD_LEAVE_EMPTY_SUBSCRIPTION = "would_leave_empty_subscription"
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -30,6 +30,7 @@ module Schematic
|
|
|
30
30
|
field :reset_cadence, -> { Schematic::Types::BillingPlanCreditGrantResetCadence }, optional: true, nullable: false
|
|
31
31
|
field :reset_start, -> { Schematic::Types::BillingPlanCreditGrantResetStart }, optional: true, nullable: false
|
|
32
32
|
field :reset_type, -> { Schematic::Types::BillingPlanCreditGrantResetType }, optional: false, nullable: false
|
|
33
|
+
field :rollover_percentage, -> { Integer }, optional: false, nullable: false
|
|
33
34
|
field :singular_name, -> { String }, optional: true, nullable: false
|
|
34
35
|
field :updated_at, -> { String }, optional: false, nullable: false
|
|
35
36
|
end
|
|
@@ -18,6 +18,7 @@ module Schematic
|
|
|
18
18
|
field :currency_prices, -> { Internal::Types::Array[Schematic::Types::PlanCurrencyPricesResponseData] }, optional: false, nullable: false
|
|
19
19
|
field :description, -> { String }, optional: false, nullable: false
|
|
20
20
|
field :draft_version, -> { Schematic::Types::PlanVersionResponseData }, optional: true, nullable: false
|
|
21
|
+
field :entitlements, -> { Internal::Types::Array[Schematic::Types::PlanEntitlementResponseData] }, optional: true, nullable: false
|
|
21
22
|
field :features, -> { Internal::Types::Array[Schematic::Types::FeatureInPlanResponseData] }, optional: false, nullable: false
|
|
22
23
|
field :icon, -> { Schematic::Types::PlanIcon }, optional: false, nullable: false
|
|
23
24
|
field :id, -> { String }, optional: false, nullable: false
|
|
@@ -25,6 +25,7 @@ module Schematic
|
|
|
25
25
|
field :soft_limit, -> { Integer }, optional: true, nullable: false
|
|
26
26
|
field :updated_at, -> { String }, optional: false, nullable: false
|
|
27
27
|
field :usage_based_product, -> { Schematic::Types::BillingProductResponseData }, optional: true, nullable: false
|
|
28
|
+
field :usage_quantity, -> { Integer }, optional: true, nullable: false
|
|
28
29
|
field :value_bool, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
29
30
|
field :value_credit, -> { Schematic::Types::BillingCreditResponseData }, optional: true, nullable: false
|
|
30
31
|
field :value_numeric, -> { Integer }, optional: true, nullable: false
|
|
@@ -6,6 +6,7 @@ module Schematic
|
|
|
6
6
|
field :add_ons, -> { Internal::Types::Array[Schematic::Types::PlanGroupPlanDetailResponseData] }, optional: false, nullable: false
|
|
7
7
|
field :checkout_settings, -> { Schematic::Types::CheckoutSettingsResponseData }, optional: false, nullable: false
|
|
8
8
|
field :component_settings, -> { Schematic::Types::ComponentSettingsResponseData }, optional: false, nullable: false
|
|
9
|
+
field :custom_checkout_fields, -> { Internal::Types::Array[Schematic::Types::CheckoutFieldResponseData] }, optional: false, nullable: false
|
|
9
10
|
field :custom_plan_config, -> { Schematic::Types::CustomPlanViewConfigResponseData }, optional: true, nullable: false
|
|
10
11
|
field :custom_plan_id, -> { String }, optional: true, nullable: false
|
|
11
12
|
field :default_plan, -> { Schematic::Types::PlanGroupPlanDetailResponseData }, optional: true, nullable: false
|
|
@@ -5,6 +5,7 @@ module Schematic
|
|
|
5
5
|
class PlanGroupPlanDetailResponseData < Internal::Types::Model
|
|
6
6
|
field :active_version, -> { Schematic::Types::PlanVersionResponseData }, optional: true, nullable: false
|
|
7
7
|
field :audience_type, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :available_periods, -> { Internal::Types::Array[Schematic::Types::PlanPriceCadence] }, optional: false, nullable: false
|
|
8
9
|
field :billing_linked_resource, -> { Schematic::Types::BillingLinkedResourceResponseData }, optional: true, nullable: false
|
|
9
10
|
field :billing_product, -> { Schematic::Types::BillingProductDetailResponseData }, optional: true, nullable: false
|
|
10
11
|
field :billing_strategy, -> { Schematic::Types::BillingStrategy }, optional: false, nullable: false
|
|
@@ -20,7 +21,7 @@ module Schematic
|
|
|
20
21
|
field :custom_plan_config, -> { Schematic::Types::CustomPlanViewConfigResponseData }, optional: true, nullable: false
|
|
21
22
|
field :description, -> { String }, optional: false, nullable: false
|
|
22
23
|
field :draft_version, -> { Schematic::Types::PlanVersionResponseData }, optional: true, nullable: false
|
|
23
|
-
field :entitlements, -> { Internal::Types::Array[Schematic::Types::PlanEntitlementResponseData] }, optional:
|
|
24
|
+
field :entitlements, -> { Internal::Types::Array[Schematic::Types::PlanEntitlementResponseData] }, optional: true, nullable: false
|
|
24
25
|
field :features, -> { Internal::Types::Array[Schematic::Types::FeatureInPlanResponseData] }, optional: false, nullable: false
|
|
25
26
|
field :icon, -> { Schematic::Types::PlanIcon }, optional: false, nullable: false
|
|
26
27
|
field :id, -> { String }, optional: false, nullable: false
|
|
@@ -8,6 +8,7 @@ module Schematic
|
|
|
8
8
|
field :completed_at, -> { String }, optional: true, nullable: false
|
|
9
9
|
field :created_at, -> { String }, optional: false, nullable: false
|
|
10
10
|
field :error, -> { String }, optional: true, nullable: false
|
|
11
|
+
field :error_code, -> { Schematic::Types::MigrationErrorCode }, optional: true, nullable: false
|
|
11
12
|
field :id, -> { String }, optional: false, nullable: false
|
|
12
13
|
field :migration_id, -> { String }, optional: false, nullable: false
|
|
13
14
|
field :plan_version_id_from, -> { String }, optional: true, nullable: false
|
|
@@ -12,6 +12,7 @@ module Schematic
|
|
|
12
12
|
field :plan_id, -> { String }, optional: false, nullable: false
|
|
13
13
|
field :plan_version_id_from, -> { String }, optional: true, nullable: false
|
|
14
14
|
field :plan_version_id_to, -> { String }, optional: false, nullable: false
|
|
15
|
+
field :plan_version_ids_from, -> { Internal::Types::Array[String] }, optional: false, nullable: false
|
|
15
16
|
field :skipped_companies, -> { Integer }, optional: false, nullable: false
|
|
16
17
|
field :started_at, -> { String }, optional: true, nullable: false
|
|
17
18
|
field :status, -> { Schematic::Types::PlanVersionMigrationStatus }, optional: false, nullable: false
|
|
@@ -5,6 +5,7 @@ module Schematic
|
|
|
5
5
|
class PlanViewPublicResponseData < Internal::Types::Model
|
|
6
6
|
field :active_version, -> { Schematic::Types::PlanVersionResponseData }, optional: true, nullable: false
|
|
7
7
|
field :audience_type, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :available_periods, -> { Internal::Types::Array[Schematic::Types::PlanPriceCadence] }, optional: false, nullable: false
|
|
8
9
|
field :billing_linked_resource, -> { Schematic::Types::BillingLinkedResourceResponseData }, optional: true, nullable: false
|
|
9
10
|
field :billing_product, -> { Schematic::Types::BillingProductDetailResponseData }, optional: true, nullable: false
|
|
10
11
|
field :billing_strategy, -> { Schematic::Types::BillingStrategy }, optional: false, nullable: false
|
|
@@ -21,7 +22,7 @@ module Schematic
|
|
|
21
22
|
field :custom_plan_config, -> { Schematic::Types::CustomPlanConfig }, optional: true, nullable: false
|
|
22
23
|
field :description, -> { String }, optional: false, nullable: false
|
|
23
24
|
field :draft_version, -> { Schematic::Types::PlanVersionResponseData }, optional: true, nullable: false
|
|
24
|
-
field :entitlements, -> { Internal::Types::Array[Schematic::Types::PlanEntitlementResponseData] }, optional:
|
|
25
|
+
field :entitlements, -> { Internal::Types::Array[Schematic::Types::PlanEntitlementResponseData] }, optional: true, nullable: false
|
|
25
26
|
field :features, -> { Internal::Types::Array[Schematic::Types::FeatureInPlanResponseData] }, optional: false, nullable: false
|
|
26
27
|
field :icon, -> { Schematic::Types::PlanIcon }, optional: false, nullable: false
|
|
27
28
|
field :id, -> { String }, optional: false, nullable: false
|