schematichq 1.4.0
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 +7 -0
- data/.claude/settings.json +16 -0
- data/.claude/skills/pr-review/SKILL.md +129 -0
- data/.fern/metadata.json +18 -0
- data/.fernignore +21 -0
- data/.rubocop.yml +69 -0
- data/CLAUDE.md +45 -0
- data/LICENSE +21 -0
- data/README.md +639 -0
- data/Rakefile +20 -0
- data/WASM_VERSION +1 -0
- data/custom.gemspec.rb +10 -0
- data/lib/schematic/accesstokens/client.rb +46 -0
- data/lib/schematic/accesstokens/types/issue_temporary_access_token_request_body.rb +12 -0
- data/lib/schematic/accesstokens/types/issue_temporary_access_token_response.rb +12 -0
- data/lib/schematic/accounts/client.rb +604 -0
- data/lib/schematic/accounts/types/count_api_keys_params.rb +15 -0
- data/lib/schematic/accounts/types/count_api_keys_request.rb +14 -0
- data/lib/schematic/accounts/types/count_api_keys_response.rb +12 -0
- data/lib/schematic/accounts/types/count_audit_logs_params.rb +18 -0
- data/lib/schematic/accounts/types/count_audit_logs_request.rb +17 -0
- data/lib/schematic/accounts/types/count_audit_logs_response.rb +12 -0
- data/lib/schematic/accounts/types/create_api_key_request_body.rb +14 -0
- data/lib/schematic/accounts/types/create_api_key_response.rb +12 -0
- data/lib/schematic/accounts/types/create_environment_request_body.rb +12 -0
- data/lib/schematic/accounts/types/create_environment_response.rb +12 -0
- data/lib/schematic/accounts/types/delete_api_key_response.rb +12 -0
- data/lib/schematic/accounts/types/delete_environment_response.rb +12 -0
- data/lib/schematic/accounts/types/get_api_key_response.rb +12 -0
- data/lib/schematic/accounts/types/get_audit_log_response.rb +12 -0
- data/lib/schematic/accounts/types/get_environment_response.rb +12 -0
- data/lib/schematic/accounts/types/get_who_am_i_response.rb +12 -0
- data/lib/schematic/accounts/types/list_api_keys_params.rb +15 -0
- data/lib/schematic/accounts/types/list_api_keys_request.rb +14 -0
- data/lib/schematic/accounts/types/list_api_keys_response.rb +12 -0
- data/lib/schematic/accounts/types/list_audit_logs_params.rb +18 -0
- data/lib/schematic/accounts/types/list_audit_logs_request.rb +17 -0
- data/lib/schematic/accounts/types/list_audit_logs_response.rb +12 -0
- data/lib/schematic/accounts/types/list_environments_params.rb +14 -0
- data/lib/schematic/accounts/types/list_environments_request.rb +13 -0
- data/lib/schematic/accounts/types/list_environments_response.rb +12 -0
- data/lib/schematic/accounts/types/quickstart_response.rb +12 -0
- data/lib/schematic/accounts/types/update_api_key_request_body.rb +13 -0
- data/lib/schematic/accounts/types/update_api_key_response.rb +12 -0
- data/lib/schematic/accounts/types/update_environment_request_body.rb +13 -0
- data/lib/schematic/accounts/types/update_environment_response.rb +12 -0
- data/lib/schematic/billing/client.rb +862 -0
- data/lib/schematic/billing/types/count_billing_products_params.rb +23 -0
- data/lib/schematic/billing/types/count_billing_products_request.rb +22 -0
- data/lib/schematic/billing/types/count_billing_products_response.rb +12 -0
- data/lib/schematic/billing/types/count_customers_params.rb +17 -0
- data/lib/schematic/billing/types/count_customers_request.rb +16 -0
- data/lib/schematic/billing/types/count_customers_response.rb +12 -0
- data/lib/schematic/billing/types/create_billing_customer_request_body.rb +17 -0
- data/lib/schematic/billing/types/create_billing_price_request_body.rb +25 -0
- data/lib/schematic/billing/types/create_billing_product_request_body.rb +15 -0
- data/lib/schematic/billing/types/create_billing_subscription_request_body.rb +29 -0
- data/lib/schematic/billing/types/create_coupon_request_body.rb +19 -0
- data/lib/schematic/billing/types/create_invoice_request_body.rb +23 -0
- data/lib/schematic/billing/types/create_meter_request_body.rb +14 -0
- data/lib/schematic/billing/types/create_payment_method_request_body.rb +22 -0
- data/lib/schematic/billing/types/delete_billing_product_response.rb +12 -0
- data/lib/schematic/billing/types/delete_product_price_response.rb +12 -0
- data/lib/schematic/billing/types/list_billing_prices_params.rb +27 -0
- data/lib/schematic/billing/types/list_billing_prices_request.rb +26 -0
- data/lib/schematic/billing/types/list_billing_prices_response.rb +12 -0
- data/lib/schematic/billing/types/list_billing_product_prices_params.rb +27 -0
- data/lib/schematic/billing/types/list_billing_product_prices_request.rb +26 -0
- data/lib/schematic/billing/types/list_billing_product_prices_response.rb +12 -0
- data/lib/schematic/billing/types/list_billing_products_params.rb +23 -0
- data/lib/schematic/billing/types/list_billing_products_request.rb +22 -0
- data/lib/schematic/billing/types/list_billing_products_response.rb +12 -0
- data/lib/schematic/billing/types/list_coupons_params.rb +15 -0
- data/lib/schematic/billing/types/list_coupons_request.rb +14 -0
- data/lib/schematic/billing/types/list_coupons_response.rb +12 -0
- data/lib/schematic/billing/types/list_customers_with_subscriptions_params.rb +17 -0
- data/lib/schematic/billing/types/list_customers_with_subscriptions_request.rb +16 -0
- data/lib/schematic/billing/types/list_customers_with_subscriptions_response.rb +12 -0
- data/lib/schematic/billing/types/list_invoices_params.rb +16 -0
- data/lib/schematic/billing/types/list_invoices_request.rb +15 -0
- data/lib/schematic/billing/types/list_invoices_response.rb +12 -0
- data/lib/schematic/billing/types/list_meters_params.rb +14 -0
- data/lib/schematic/billing/types/list_meters_request.rb +13 -0
- data/lib/schematic/billing/types/list_meters_response.rb +12 -0
- data/lib/schematic/billing/types/list_payment_methods_params.rb +15 -0
- data/lib/schematic/billing/types/list_payment_methods_request.rb +14 -0
- data/lib/schematic/billing/types/list_payment_methods_response.rb +12 -0
- data/lib/schematic/billing/types/upsert_billing_coupon_response.rb +12 -0
- data/lib/schematic/billing/types/upsert_billing_customer_response.rb +12 -0
- data/lib/schematic/billing/types/upsert_billing_meter_response.rb +12 -0
- data/lib/schematic/billing/types/upsert_billing_price_response.rb +12 -0
- data/lib/schematic/billing/types/upsert_billing_product_response.rb +12 -0
- data/lib/schematic/billing/types/upsert_billing_subscription_response.rb +12 -0
- data/lib/schematic/billing/types/upsert_invoice_response.rb +12 -0
- data/lib/schematic/billing/types/upsert_payment_method_response.rb +12 -0
- data/lib/schematic/cache.rb +133 -0
- data/lib/schematic/checkout/client.rb +243 -0
- data/lib/schematic/checkout/types/cancel_subscription_request.rb +13 -0
- data/lib/schematic/checkout/types/cancel_subscription_response.rb +12 -0
- data/lib/schematic/checkout/types/checkout_data_request_body.rb +12 -0
- data/lib/schematic/checkout/types/checkout_internal_response.rb +12 -0
- data/lib/schematic/checkout/types/get_checkout_data_response.rb +12 -0
- data/lib/schematic/checkout/types/manage_plan_response.rb +12 -0
- data/lib/schematic/checkout/types/preview_checkout_internal_response.rb +12 -0
- data/lib/schematic/checkout/types/preview_manage_plan_response.rb +12 -0
- data/lib/schematic/checkout/types/update_customer_subscription_trial_end_response.rb +12 -0
- data/lib/schematic/checkout/types/update_trial_end_request_body.rb +12 -0
- data/lib/schematic/client.rb +110 -0
- data/lib/schematic/companies/client.rb +1561 -0
- data/lib/schematic/companies/types/count_companies_params.rb +29 -0
- data/lib/schematic/companies/types/count_companies_request.rb +28 -0
- data/lib/schematic/companies/types/count_companies_response.rb +12 -0
- data/lib/schematic/companies/types/count_entity_key_definitions_params.rb +16 -0
- data/lib/schematic/companies/types/count_entity_key_definitions_request.rb +15 -0
- data/lib/schematic/companies/types/count_entity_key_definitions_response.rb +12 -0
- data/lib/schematic/companies/types/count_entity_trait_definitions_params.rb +18 -0
- data/lib/schematic/companies/types/count_entity_trait_definitions_request.rb +17 -0
- data/lib/schematic/companies/types/count_entity_trait_definitions_response.rb +12 -0
- data/lib/schematic/companies/types/count_plan_traits_params.rb +17 -0
- data/lib/schematic/companies/types/count_plan_traits_request.rb +16 -0
- data/lib/schematic/companies/types/count_plan_traits_response.rb +12 -0
- data/lib/schematic/companies/types/count_users_params.rb +17 -0
- data/lib/schematic/companies/types/count_users_request.rb +16 -0
- data/lib/schematic/companies/types/count_users_response.rb +12 -0
- data/lib/schematic/companies/types/create_company_response.rb +12 -0
- data/lib/schematic/companies/types/create_entity_trait_definition_request_body.rb +14 -0
- data/lib/schematic/companies/types/create_plan_trait_request_body.rb +13 -0
- data/lib/schematic/companies/types/create_plan_trait_response.rb +12 -0
- data/lib/schematic/companies/types/create_user_response.rb +12 -0
- data/lib/schematic/companies/types/delete_company_by_keys_response.rb +12 -0
- data/lib/schematic/companies/types/delete_company_membership_response.rb +12 -0
- data/lib/schematic/companies/types/delete_company_params.rb +13 -0
- data/lib/schematic/companies/types/delete_company_request.rb +13 -0
- data/lib/schematic/companies/types/delete_company_response.rb +12 -0
- data/lib/schematic/companies/types/delete_plan_trait_response.rb +12 -0
- data/lib/schematic/companies/types/delete_user_by_keys_response.rb +12 -0
- data/lib/schematic/companies/types/delete_user_response.rb +12 -0
- data/lib/schematic/companies/types/get_active_company_subscription_params.rb +15 -0
- data/lib/schematic/companies/types/get_active_company_subscription_request.rb +14 -0
- data/lib/schematic/companies/types/get_active_company_subscription_response.rb +12 -0
- data/lib/schematic/companies/types/get_company_response.rb +12 -0
- data/lib/schematic/companies/types/get_entity_trait_definition_response.rb +12 -0
- data/lib/schematic/companies/types/get_entity_trait_values_params.rb +15 -0
- data/lib/schematic/companies/types/get_entity_trait_values_request.rb +14 -0
- data/lib/schematic/companies/types/get_entity_trait_values_response.rb +12 -0
- data/lib/schematic/companies/types/get_or_create_company_membership_request_body.rb +12 -0
- data/lib/schematic/companies/types/get_or_create_company_membership_response.rb +12 -0
- data/lib/schematic/companies/types/get_or_create_entity_trait_definition_response.rb +12 -0
- data/lib/schematic/companies/types/get_plan_change_response.rb +12 -0
- data/lib/schematic/companies/types/get_plan_trait_response.rb +12 -0
- data/lib/schematic/companies/types/get_user_response.rb +12 -0
- data/lib/schematic/companies/types/list_companies_params.rb +29 -0
- data/lib/schematic/companies/types/list_companies_request.rb +28 -0
- data/lib/schematic/companies/types/list_companies_response.rb +12 -0
- data/lib/schematic/companies/types/list_company_memberships_params.rb +15 -0
- data/lib/schematic/companies/types/list_company_memberships_request.rb +14 -0
- data/lib/schematic/companies/types/list_company_memberships_response.rb +12 -0
- data/lib/schematic/companies/types/list_entity_key_definitions_params.rb +16 -0
- data/lib/schematic/companies/types/list_entity_key_definitions_request.rb +15 -0
- data/lib/schematic/companies/types/list_entity_key_definitions_response.rb +12 -0
- data/lib/schematic/companies/types/list_entity_trait_definitions_params.rb +18 -0
- data/lib/schematic/companies/types/list_entity_trait_definitions_request.rb +17 -0
- data/lib/schematic/companies/types/list_entity_trait_definitions_response.rb +12 -0
- data/lib/schematic/companies/types/list_plan_changes_params.rb +18 -0
- data/lib/schematic/companies/types/list_plan_changes_request.rb +17 -0
- data/lib/schematic/companies/types/list_plan_changes_response.rb +12 -0
- data/lib/schematic/companies/types/list_plan_traits_params.rb +17 -0
- data/lib/schematic/companies/types/list_plan_traits_request.rb +16 -0
- data/lib/schematic/companies/types/list_plan_traits_response.rb +12 -0
- data/lib/schematic/companies/types/list_users_params.rb +17 -0
- data/lib/schematic/companies/types/list_users_request.rb +16 -0
- data/lib/schematic/companies/types/list_users_response.rb +12 -0
- data/lib/schematic/companies/types/lookup_company_params.rb +12 -0
- data/lib/schematic/companies/types/lookup_company_request.rb +11 -0
- data/lib/schematic/companies/types/lookup_company_response.rb +12 -0
- data/lib/schematic/companies/types/lookup_user_params.rb +12 -0
- data/lib/schematic/companies/types/lookup_user_request.rb +11 -0
- data/lib/schematic/companies/types/lookup_user_response.rb +12 -0
- data/lib/schematic/companies/types/update_entity_trait_definition_request_body.rb +13 -0
- data/lib/schematic/companies/types/update_entity_trait_definition_response.rb +12 -0
- data/lib/schematic/companies/types/update_plan_trait_bulk_request_body.rb +13 -0
- data/lib/schematic/companies/types/update_plan_trait_request_body.rb +13 -0
- data/lib/schematic/companies/types/update_plan_trait_response.rb +12 -0
- data/lib/schematic/companies/types/update_plan_traits_bulk_response.rb +12 -0
- data/lib/schematic/companies/types/upsert_company_response.rb +12 -0
- data/lib/schematic/companies/types/upsert_company_trait_response.rb +12 -0
- data/lib/schematic/companies/types/upsert_user_response.rb +12 -0
- data/lib/schematic/companies/types/upsert_user_trait_response.rb +12 -0
- data/lib/schematic/components/client.rb +271 -0
- data/lib/schematic/components/types/count_components_params.rb +14 -0
- data/lib/schematic/components/types/count_components_request.rb +13 -0
- data/lib/schematic/components/types/count_components_response.rb +12 -0
- data/lib/schematic/components/types/create_component_request_body.rb +13 -0
- data/lib/schematic/components/types/create_component_response.rb +12 -0
- data/lib/schematic/components/types/delete_component_response.rb +12 -0
- data/lib/schematic/components/types/get_component_response.rb +12 -0
- data/lib/schematic/components/types/list_components_params.rb +14 -0
- data/lib/schematic/components/types/list_components_request.rb +13 -0
- data/lib/schematic/components/types/list_components_response.rb +12 -0
- data/lib/schematic/components/types/preview_component_data_params.rb +13 -0
- data/lib/schematic/components/types/preview_component_data_request.rb +12 -0
- data/lib/schematic/components/types/preview_component_data_response.rb +12 -0
- data/lib/schematic/components/types/update_component_request_body.rb +15 -0
- data/lib/schematic/components/types/update_component_response.rb +12 -0
- data/lib/schematic/componentspublic/client.rb +45 -0
- data/lib/schematic/componentspublic/types/get_public_plans_response.rb +12 -0
- data/lib/schematic/credits/client.rb +1157 -0
- data/lib/schematic/credits/types/count_billing_credits_grants_params.rb +15 -0
- data/lib/schematic/credits/types/count_billing_credits_grants_request.rb +14 -0
- data/lib/schematic/credits/types/count_billing_credits_grants_response.rb +12 -0
- data/lib/schematic/credits/types/count_billing_credits_params.rb +15 -0
- data/lib/schematic/credits/types/count_billing_credits_request.rb +14 -0
- data/lib/schematic/credits/types/count_billing_credits_response.rb +12 -0
- data/lib/schematic/credits/types/count_billing_plan_credit_grants_params.rb +18 -0
- data/lib/schematic/credits/types/count_billing_plan_credit_grants_request.rb +17 -0
- data/lib/schematic/credits/types/count_billing_plan_credit_grants_response.rb +12 -0
- data/lib/schematic/credits/types/count_company_grants_params.rb +16 -0
- data/lib/schematic/credits/types/count_company_grants_request.rb +15 -0
- data/lib/schematic/credits/types/count_company_grants_response.rb +12 -0
- data/lib/schematic/credits/types/count_credit_bundles_params.rb +17 -0
- data/lib/schematic/credits/types/count_credit_bundles_request.rb +16 -0
- data/lib/schematic/credits/types/count_credit_bundles_response.rb +12 -0
- data/lib/schematic/credits/types/count_credit_event_ledger_params.rb +19 -0
- data/lib/schematic/credits/types/count_credit_event_ledger_request.rb +18 -0
- data/lib/schematic/credits/types/count_credit_event_ledger_response.rb +12 -0
- data/lib/schematic/credits/types/count_credit_ledger_params.rb +19 -0
- data/lib/schematic/credits/types/count_credit_ledger_request.rb +18 -0
- data/lib/schematic/credits/types/count_credit_ledger_response.rb +12 -0
- data/lib/schematic/credits/types/create_billing_credit_request_body.rb +23 -0
- data/lib/schematic/credits/types/create_billing_credit_response.rb +12 -0
- data/lib/schematic/credits/types/create_billing_plan_credit_grant_response.rb +12 -0
- data/lib/schematic/credits/types/create_company_credit_grant.rb +22 -0
- data/lib/schematic/credits/types/create_credit_bundle_request_body.rb +22 -0
- data/lib/schematic/credits/types/create_credit_bundle_response.rb +12 -0
- data/lib/schematic/credits/types/delete_billing_plan_credit_grant_params.rb +12 -0
- data/lib/schematic/credits/types/delete_billing_plan_credit_grant_request.rb +12 -0
- data/lib/schematic/credits/types/delete_billing_plan_credit_grant_response.rb +12 -0
- data/lib/schematic/credits/types/delete_credit_bundle_response.rb +12 -0
- data/lib/schematic/credits/types/get_credit_bundle_response.rb +12 -0
- data/lib/schematic/credits/types/get_enriched_credit_ledger_params.rb +19 -0
- data/lib/schematic/credits/types/get_enriched_credit_ledger_request.rb +18 -0
- data/lib/schematic/credits/types/get_enriched_credit_ledger_response.rb +12 -0
- data/lib/schematic/credits/types/get_single_billing_credit_response.rb +12 -0
- data/lib/schematic/credits/types/get_single_billing_plan_credit_grant_response.rb +12 -0
- data/lib/schematic/credits/types/grant_billing_credits_to_company_response.rb +12 -0
- data/lib/schematic/credits/types/list_billing_credits_params.rb +15 -0
- data/lib/schematic/credits/types/list_billing_credits_request.rb +14 -0
- data/lib/schematic/credits/types/list_billing_credits_response.rb +12 -0
- data/lib/schematic/credits/types/list_billing_plan_credit_grants_params.rb +18 -0
- data/lib/schematic/credits/types/list_billing_plan_credit_grants_request.rb +17 -0
- data/lib/schematic/credits/types/list_billing_plan_credit_grants_response.rb +12 -0
- data/lib/schematic/credits/types/list_company_grants_params.rb +16 -0
- data/lib/schematic/credits/types/list_company_grants_request.rb +15 -0
- data/lib/schematic/credits/types/list_company_grants_response.rb +12 -0
- data/lib/schematic/credits/types/list_credit_bundles_params.rb +17 -0
- data/lib/schematic/credits/types/list_credit_bundles_request.rb +16 -0
- data/lib/schematic/credits/types/list_credit_bundles_response.rb +12 -0
- data/lib/schematic/credits/types/list_credit_event_ledger_params.rb +19 -0
- data/lib/schematic/credits/types/list_credit_event_ledger_request.rb +18 -0
- data/lib/schematic/credits/types/list_credit_event_ledger_response.rb +12 -0
- data/lib/schematic/credits/types/list_grants_for_credit_params.rb +15 -0
- data/lib/schematic/credits/types/list_grants_for_credit_request.rb +14 -0
- data/lib/schematic/credits/types/list_grants_for_credit_response.rb +12 -0
- data/lib/schematic/credits/types/soft_delete_billing_credit_response.rb +12 -0
- data/lib/schematic/credits/types/update_billing_credit_request_body.rb +23 -0
- data/lib/schematic/credits/types/update_billing_credit_response.rb +12 -0
- data/lib/schematic/credits/types/update_billing_plan_credit_grant_response.rb +12 -0
- data/lib/schematic/credits/types/update_credit_bundle_details_request_body.rb +20 -0
- data/lib/schematic/credits/types/update_credit_bundle_details_response.rb +12 -0
- data/lib/schematic/credits/types/zero_out_grant_request_body.rb +12 -0
- data/lib/schematic/credits/types/zero_out_grant_response.rb +12 -0
- data/lib/schematic/dataexports/client.rb +76 -0
- data/lib/schematic/dataexports/types/create_data_export_request_body.rb +13 -0
- data/lib/schematic/dataexports/types/create_data_export_response.rb +12 -0
- data/lib/schematic/datastream/client.rb +508 -0
- data/lib/schematic/datastream/merge.rb +95 -0
- data/lib/schematic/datastream/resource_cache.rb +76 -0
- data/lib/schematic/datastream/websocket_client.rb +315 -0
- data/lib/schematic/entitlements/client.rb +900 -0
- data/lib/schematic/entitlements/types/count_company_overrides_params.rb +20 -0
- data/lib/schematic/entitlements/types/count_company_overrides_request.rb +19 -0
- data/lib/schematic/entitlements/types/count_company_overrides_response.rb +12 -0
- data/lib/schematic/entitlements/types/count_feature_companies_params.rb +15 -0
- data/lib/schematic/entitlements/types/count_feature_companies_request.rb +14 -0
- data/lib/schematic/entitlements/types/count_feature_companies_response.rb +12 -0
- data/lib/schematic/entitlements/types/count_feature_usage_params.rb +19 -0
- data/lib/schematic/entitlements/types/count_feature_usage_request.rb +18 -0
- data/lib/schematic/entitlements/types/count_feature_usage_response.rb +12 -0
- data/lib/schematic/entitlements/types/count_feature_users_params.rb +15 -0
- data/lib/schematic/entitlements/types/count_feature_users_request.rb +14 -0
- data/lib/schematic/entitlements/types/count_feature_users_response.rb +12 -0
- data/lib/schematic/entitlements/types/count_plan_entitlements_params.rb +22 -0
- data/lib/schematic/entitlements/types/count_plan_entitlements_request.rb +21 -0
- data/lib/schematic/entitlements/types/count_plan_entitlements_response.rb +12 -0
- data/lib/schematic/entitlements/types/create_company_override_request_body.rb +22 -0
- data/lib/schematic/entitlements/types/create_company_override_request_body_metric_period.rb +16 -0
- data/lib/schematic/entitlements/types/create_company_override_request_body_metric_period_month_reset.rb +14 -0
- data/lib/schematic/entitlements/types/create_company_override_response.rb +12 -0
- data/lib/schematic/entitlements/types/create_plan_entitlement_request_body.rb +38 -0
- data/lib/schematic/entitlements/types/create_plan_entitlement_request_body_metric_period.rb +16 -0
- data/lib/schematic/entitlements/types/create_plan_entitlement_request_body_metric_period_month_reset.rb +14 -0
- data/lib/schematic/entitlements/types/create_plan_entitlement_response.rb +12 -0
- data/lib/schematic/entitlements/types/delete_company_override_response.rb +12 -0
- data/lib/schematic/entitlements/types/delete_plan_entitlement_response.rb +12 -0
- data/lib/schematic/entitlements/types/duplicate_plan_entitlements_request_body.rb +12 -0
- data/lib/schematic/entitlements/types/duplicate_plan_entitlements_response.rb +12 -0
- data/lib/schematic/entitlements/types/get_company_override_response.rb +12 -0
- data/lib/schematic/entitlements/types/get_feature_usage_by_company_params.rb +12 -0
- data/lib/schematic/entitlements/types/get_feature_usage_by_company_request.rb +11 -0
- data/lib/schematic/entitlements/types/get_feature_usage_by_company_response.rb +12 -0
- data/lib/schematic/entitlements/types/get_feature_usage_time_series_params.rb +16 -0
- data/lib/schematic/entitlements/types/get_feature_usage_time_series_request.rb +15 -0
- data/lib/schematic/entitlements/types/get_feature_usage_time_series_response.rb +12 -0
- data/lib/schematic/entitlements/types/get_plan_entitlement_response.rb +12 -0
- data/lib/schematic/entitlements/types/list_company_overrides_params.rb +20 -0
- data/lib/schematic/entitlements/types/list_company_overrides_request.rb +19 -0
- data/lib/schematic/entitlements/types/list_company_overrides_response.rb +12 -0
- data/lib/schematic/entitlements/types/list_feature_companies_params.rb +15 -0
- data/lib/schematic/entitlements/types/list_feature_companies_request.rb +14 -0
- data/lib/schematic/entitlements/types/list_feature_companies_response.rb +12 -0
- data/lib/schematic/entitlements/types/list_feature_usage_params.rb +19 -0
- data/lib/schematic/entitlements/types/list_feature_usage_request.rb +18 -0
- data/lib/schematic/entitlements/types/list_feature_usage_response.rb +12 -0
- data/lib/schematic/entitlements/types/list_feature_users_params.rb +15 -0
- data/lib/schematic/entitlements/types/list_feature_users_request.rb +14 -0
- data/lib/schematic/entitlements/types/list_feature_users_response.rb +12 -0
- data/lib/schematic/entitlements/types/list_plan_entitlements_params.rb +22 -0
- data/lib/schematic/entitlements/types/list_plan_entitlements_request.rb +21 -0
- data/lib/schematic/entitlements/types/list_plan_entitlements_response.rb +12 -0
- data/lib/schematic/entitlements/types/update_company_override_request_body.rb +21 -0
- data/lib/schematic/entitlements/types/update_company_override_request_body_metric_period.rb +16 -0
- data/lib/schematic/entitlements/types/update_company_override_request_body_metric_period_month_reset.rb +14 -0
- data/lib/schematic/entitlements/types/update_company_override_response.rb +12 -0
- data/lib/schematic/entitlements/types/update_plan_entitlement_request_body.rb +36 -0
- data/lib/schematic/entitlements/types/update_plan_entitlement_request_body_metric_period.rb +16 -0
- data/lib/schematic/entitlements/types/update_plan_entitlement_request_body_metric_period_month_reset.rb +14 -0
- data/lib/schematic/entitlements/types/update_plan_entitlement_response.rb +12 -0
- data/lib/schematic/environment.rb +7 -0
- data/lib/schematic/errors/api_error.rb +8 -0
- data/lib/schematic/errors/client_error.rb +17 -0
- data/lib/schematic/errors/redirect_error.rb +8 -0
- data/lib/schematic/errors/response_error.rb +42 -0
- data/lib/schematic/errors/server_error.rb +11 -0
- data/lib/schematic/errors/timeout_error.rb +8 -0
- data/lib/schematic/event_buffer.rb +180 -0
- data/lib/schematic/events/client.rb +235 -0
- data/lib/schematic/events/types/create_event_batch_request_body.rb +11 -0
- data/lib/schematic/events/types/create_event_batch_response.rb +12 -0
- data/lib/schematic/events/types/create_event_response.rb +12 -0
- data/lib/schematic/events/types/get_event_response.rb +12 -0
- data/lib/schematic/events/types/get_event_summaries_params.rb +15 -0
- data/lib/schematic/events/types/get_event_summaries_request.rb +14 -0
- data/lib/schematic/events/types/get_event_summaries_response.rb +12 -0
- data/lib/schematic/events/types/get_segment_integration_status_response.rb +12 -0
- data/lib/schematic/events/types/list_events_params.rb +18 -0
- data/lib/schematic/events/types/list_events_request.rb +17 -0
- data/lib/schematic/events/types/list_events_response.rb +12 -0
- data/lib/schematic/features/client.rb +610 -0
- data/lib/schematic/features/types/check_flag_response.rb +12 -0
- data/lib/schematic/features/types/check_flags_bulk_request_body.rb +11 -0
- data/lib/schematic/features/types/check_flags_bulk_response.rb +12 -0
- data/lib/schematic/features/types/check_flags_response.rb +12 -0
- data/lib/schematic/features/types/count_features_params.rb +20 -0
- data/lib/schematic/features/types/count_features_request.rb +19 -0
- data/lib/schematic/features/types/count_features_response.rb +12 -0
- data/lib/schematic/features/types/count_flags_params.rb +16 -0
- data/lib/schematic/features/types/count_flags_request.rb +15 -0
- data/lib/schematic/features/types/count_flags_response.rb +12 -0
- data/lib/schematic/features/types/create_feature_request_body.rb +21 -0
- data/lib/schematic/features/types/create_feature_response.rb +12 -0
- data/lib/schematic/features/types/create_flag_response.rb +12 -0
- data/lib/schematic/features/types/delete_feature_response.rb +12 -0
- data/lib/schematic/features/types/delete_flag_response.rb +12 -0
- data/lib/schematic/features/types/get_feature_response.rb +12 -0
- data/lib/schematic/features/types/get_flag_response.rb +12 -0
- data/lib/schematic/features/types/list_features_params.rb +20 -0
- data/lib/schematic/features/types/list_features_request.rb +19 -0
- data/lib/schematic/features/types/list_features_response.rb +12 -0
- data/lib/schematic/features/types/list_flags_params.rb +16 -0
- data/lib/schematic/features/types/list_flags_request.rb +15 -0
- data/lib/schematic/features/types/list_flags_response.rb +12 -0
- data/lib/schematic/features/types/update_feature_request_body.rb +22 -0
- data/lib/schematic/features/types/update_feature_response.rb +12 -0
- data/lib/schematic/features/types/update_flag_response.rb +12 -0
- data/lib/schematic/features/types/update_flag_rules_request_body.rb +12 -0
- data/lib/schematic/features/types/update_flag_rules_response.rb +12 -0
- data/lib/schematic/internal/errors/constraint_error.rb +10 -0
- data/lib/schematic/internal/errors/type_error.rb +10 -0
- data/lib/schematic/internal/http/base_request.rb +51 -0
- data/lib/schematic/internal/http/raw_client.rb +214 -0
- data/lib/schematic/internal/iterators/cursor_item_iterator.rb +28 -0
- data/lib/schematic/internal/iterators/cursor_page_iterator.rb +51 -0
- data/lib/schematic/internal/iterators/item_iterator.rb +59 -0
- data/lib/schematic/internal/iterators/offset_item_iterator.rb +30 -0
- data/lib/schematic/internal/iterators/offset_page_iterator.rb +83 -0
- data/lib/schematic/internal/json/request.rb +41 -0
- data/lib/schematic/internal/json/serializable.rb +25 -0
- data/lib/schematic/internal/multipart/multipart_encoder.rb +141 -0
- data/lib/schematic/internal/multipart/multipart_form_data.rb +78 -0
- data/lib/schematic/internal/multipart/multipart_form_data_part.rb +51 -0
- data/lib/schematic/internal/multipart/multipart_request.rb +40 -0
- data/lib/schematic/internal/types/array.rb +47 -0
- data/lib/schematic/internal/types/boolean.rb +34 -0
- data/lib/schematic/internal/types/enum.rb +56 -0
- data/lib/schematic/internal/types/hash.rb +36 -0
- data/lib/schematic/internal/types/model/field.rb +38 -0
- data/lib/schematic/internal/types/model.rb +208 -0
- data/lib/schematic/internal/types/type.rb +35 -0
- data/lib/schematic/internal/types/union.rb +161 -0
- data/lib/schematic/internal/types/unknown.rb +15 -0
- data/lib/schematic/internal/types/utils.rb +116 -0
- data/lib/schematic/logger.rb +62 -0
- data/lib/schematic/planbundle/client.rb +83 -0
- data/lib/schematic/planbundle/types/create_plan_bundle_request_body.rb +15 -0
- data/lib/schematic/planbundle/types/create_plan_bundle_response.rb +12 -0
- data/lib/schematic/planbundle/types/update_plan_bundle_request_body.rb +17 -0
- data/lib/schematic/planbundle/types/update_plan_bundle_response.rb +12 -0
- data/lib/schematic/plangroups/client.rb +121 -0
- data/lib/schematic/plangroups/types/create_plan_group_request_body.rb +42 -0
- data/lib/schematic/plangroups/types/create_plan_group_response.rb +12 -0
- data/lib/schematic/plangroups/types/get_plan_group_params.rb +12 -0
- data/lib/schematic/plangroups/types/get_plan_group_request.rb +11 -0
- data/lib/schematic/plangroups/types/get_plan_group_response.rb +12 -0
- data/lib/schematic/plangroups/types/update_plan_group_request_body.rb +43 -0
- data/lib/schematic/plangroups/types/update_plan_group_response.rb +12 -0
- data/lib/schematic/planmigrations/client.rb +226 -0
- data/lib/schematic/planmigrations/types/count_company_migrations_params.rb +16 -0
- data/lib/schematic/planmigrations/types/count_company_migrations_request.rb +15 -0
- data/lib/schematic/planmigrations/types/count_company_migrations_response.rb +12 -0
- data/lib/schematic/planmigrations/types/count_migrations_params.rb +15 -0
- data/lib/schematic/planmigrations/types/count_migrations_request.rb +14 -0
- data/lib/schematic/planmigrations/types/count_migrations_response.rb +12 -0
- data/lib/schematic/planmigrations/types/get_migration_response.rb +12 -0
- data/lib/schematic/planmigrations/types/list_company_migrations_params.rb +16 -0
- data/lib/schematic/planmigrations/types/list_company_migrations_request.rb +15 -0
- data/lib/schematic/planmigrations/types/list_company_migrations_response.rb +12 -0
- data/lib/schematic/planmigrations/types/list_migrations_params.rb +15 -0
- data/lib/schematic/planmigrations/types/list_migrations_request.rb +14 -0
- data/lib/schematic/planmigrations/types/list_migrations_response.rb +12 -0
- data/lib/schematic/plans/client.rb +460 -0
- data/lib/schematic/plans/types/count_plans_params.rb +24 -0
- data/lib/schematic/plans/types/count_plans_request.rb +23 -0
- data/lib/schematic/plans/types/count_plans_response.rb +12 -0
- data/lib/schematic/plans/types/create_plan_response.rb +12 -0
- data/lib/schematic/plans/types/delete_plan_response.rb +12 -0
- data/lib/schematic/plans/types/delete_plan_version_params.rb +12 -0
- data/lib/schematic/plans/types/delete_plan_version_request.rb +12 -0
- data/lib/schematic/plans/types/delete_plan_version_response.rb +12 -0
- data/lib/schematic/plans/types/get_plan_params.rb +12 -0
- data/lib/schematic/plans/types/get_plan_request.rb +12 -0
- data/lib/schematic/plans/types/get_plan_response.rb +12 -0
- data/lib/schematic/plans/types/list_plan_issues_params.rb +13 -0
- data/lib/schematic/plans/types/list_plan_issues_request.rb +12 -0
- data/lib/schematic/plans/types/list_plan_issues_response.rb +12 -0
- data/lib/schematic/plans/types/list_plans_params.rb +24 -0
- data/lib/schematic/plans/types/list_plans_request.rb +23 -0
- data/lib/schematic/plans/types/list_plans_response.rb +12 -0
- data/lib/schematic/plans/types/publish_plan_version_request_body.rb +13 -0
- data/lib/schematic/plans/types/publish_plan_version_response.rb +12 -0
- data/lib/schematic/plans/types/update_company_plans_request_body.rb +13 -0
- data/lib/schematic/plans/types/update_company_plans_response.rb +12 -0
- data/lib/schematic/plans/types/update_plan_response.rb +12 -0
- data/lib/schematic/plans/types/upsert_billing_product_plan_response.rb +12 -0
- data/lib/schematic/redis_cache.rb +94 -0
- data/lib/schematic/rules_engine.rb +145 -0
- data/lib/schematic/scheduledcheckout/client.rb +159 -0
- data/lib/schematic/scheduledcheckout/types/create_scheduled_checkout_request.rb +14 -0
- data/lib/schematic/scheduledcheckout/types/create_scheduled_checkout_response.rb +12 -0
- data/lib/schematic/scheduledcheckout/types/get_scheduled_checkout_response.rb +12 -0
- data/lib/schematic/scheduledcheckout/types/list_scheduled_checkouts_params.rb +15 -0
- data/lib/schematic/scheduledcheckout/types/list_scheduled_checkouts_request.rb +14 -0
- data/lib/schematic/scheduledcheckout/types/list_scheduled_checkouts_response.rb +12 -0
- data/lib/schematic/scheduledcheckout/types/update_scheduled_checkout_request.rb +13 -0
- data/lib/schematic/scheduledcheckout/types/update_scheduled_checkout_response.rb +12 -0
- data/lib/schematic/schematic_client.rb +552 -0
- data/lib/schematic/types/actor_type.rb +15 -0
- data/lib/schematic/types/api_error.rb +9 -0
- data/lib/schematic/types/api_key_create_response_data.rb +18 -0
- data/lib/schematic/types/api_key_response_data.rb +17 -0
- data/lib/schematic/types/api_key_scope.rb +14 -0
- data/lib/schematic/types/audit_log_list_response_data.rb +23 -0
- data/lib/schematic/types/audit_log_response_data.rb +26 -0
- data/lib/schematic/types/billing_coupon_response_data.rb +25 -0
- data/lib/schematic/types/billing_credit_bundle_response_data.rb +29 -0
- data/lib/schematic/types/billing_credit_bundle_status.rb +12 -0
- data/lib/schematic/types/billing_credit_bundle_type.rb +23 -0
- data/lib/schematic/types/billing_credit_bundle_view.rb +28 -0
- data/lib/schematic/types/billing_credit_burn_strategy.rb +14 -0
- data/lib/schematic/types/billing_credit_expiry_type.rb +15 -0
- data/lib/schematic/types/billing_credit_expiry_unit.rb +12 -0
- data/lib/schematic/types/billing_credit_grant_reason.rb +15 -0
- data/lib/schematic/types/billing_credit_grant_response_data.rb +32 -0
- data/lib/schematic/types/billing_credit_grant_zeroed_out_reason.rb +14 -0
- data/lib/schematic/types/billing_credit_ledger_response_data.rb +14 -0
- data/lib/schematic/types/billing_credit_response_data.rb +24 -0
- data/lib/schematic/types/billing_credit_rollover_policy.rb +13 -0
- data/lib/schematic/types/billing_credit_view.rb +27 -0
- data/lib/schematic/types/billing_customer_response_data.rb +16 -0
- data/lib/schematic/types/billing_customer_subscription.rb +14 -0
- data/lib/schematic/types/billing_customer_with_subscriptions_response_data.rb +17 -0
- data/lib/schematic/types/billing_meter_response_data.rb +14 -0
- data/lib/schematic/types/billing_plan_credit_grant_reset_cadence.rb +14 -0
- data/lib/schematic/types/billing_plan_credit_grant_reset_start.rb +12 -0
- data/lib/schematic/types/billing_plan_credit_grant_reset_type.rb +12 -0
- data/lib/schematic/types/billing_plan_credit_grant_response_data.rb +34 -0
- data/lib/schematic/types/billing_price_response_data.rb +16 -0
- data/lib/schematic/types/billing_price_scheme.rb +12 -0
- data/lib/schematic/types/billing_price_usage_type.rb +12 -0
- data/lib/schematic/types/billing_price_view.rb +30 -0
- data/lib/schematic/types/billing_product_detail_response_data.rb +23 -0
- data/lib/schematic/types/billing_product_for_subscription_response_data.rb +30 -0
- data/lib/schematic/types/billing_product_plan_response_data.rb +19 -0
- data/lib/schematic/types/billing_product_price_interval.rb +14 -0
- data/lib/schematic/types/billing_product_price_response_data.rb +24 -0
- data/lib/schematic/types/billing_product_price_tier_response_data.rb +12 -0
- data/lib/schematic/types/billing_product_pricing.rb +20 -0
- data/lib/schematic/types/billing_product_response_data.rb +21 -0
- data/lib/schematic/types/billing_provider_type.rb +12 -0
- data/lib/schematic/types/billing_subscription_discount.rb +15 -0
- data/lib/schematic/types/billing_subscription_discount_view.rb +22 -0
- data/lib/schematic/types/billing_subscription_response_data.rb +28 -0
- data/lib/schematic/types/billing_subscription_trial_end_setting.rb +12 -0
- data/lib/schematic/types/billing_subscription_view.rb +32 -0
- data/lib/schematic/types/billing_tiers_mode.rb +12 -0
- data/lib/schematic/types/capture_raw_event.rb +13 -0
- data/lib/schematic/types/capture_raw_event_batch.rb +9 -0
- data/lib/schematic/types/change_subscription_internal_request_body.rb +18 -0
- data/lib/schematic/types/change_subscription_request_body.rb +17 -0
- data/lib/schematic/types/charge_type.rb +13 -0
- data/lib/schematic/types/check_flag_request_body.rb +10 -0
- data/lib/schematic/types/check_flag_response_data.rb +23 -0
- data/lib/schematic/types/check_flags_bulk_response_data.rb +9 -0
- data/lib/schematic/types/check_flags_response_data.rb +10 -0
- data/lib/schematic/types/checkout_data_response_data.rb +18 -0
- data/lib/schematic/types/checkout_settings_response_data.rb +11 -0
- data/lib/schematic/types/checkout_subscription.rb +30 -0
- data/lib/schematic/types/company_detail_response_data.rb +31 -0
- data/lib/schematic/types/company_event_period_metrics_response_data.rb +19 -0
- data/lib/schematic/types/company_ledger_response_data.rb +11 -0
- data/lib/schematic/types/company_membership_detail_response_data.rb +14 -0
- data/lib/schematic/types/company_membership_response_data.rb +13 -0
- data/lib/schematic/types/company_override_note_response_data.rb +14 -0
- data/lib/schematic/types/company_override_response_data.rb +28 -0
- data/lib/schematic/types/company_plan_detail_response_data.rb +43 -0
- data/lib/schematic/types/company_plan_invalid_reason.rb +12 -0
- data/lib/schematic/types/company_plan_with_billing_sub_view.rb +19 -0
- data/lib/schematic/types/company_response_data.rb +15 -0
- data/lib/schematic/types/company_subscription_response_data.rb +22 -0
- data/lib/schematic/types/compatible_plans.rb +10 -0
- data/lib/schematic/types/compatible_plans_response_data.rb +10 -0
- data/lib/schematic/types/component_capabilities.rb +10 -0
- data/lib/schematic/types/component_checkout_settings.rb +12 -0
- data/lib/schematic/types/component_display_settings.rb +14 -0
- data/lib/schematic/types/component_entity_type.rb +12 -0
- data/lib/schematic/types/component_hydrate_response_data.rb +34 -0
- data/lib/schematic/types/component_preview_response_data.rb +35 -0
- data/lib/schematic/types/component_response_data.rb +15 -0
- data/lib/schematic/types/component_settings_response_data.rb +14 -0
- data/lib/schematic/types/component_state.rb +12 -0
- data/lib/schematic/types/condition.rb +23 -0
- data/lib/schematic/types/condition_condition_type.rb +19 -0
- data/lib/schematic/types/condition_group.rb +9 -0
- data/lib/schematic/types/condition_group_response_data.rb +15 -0
- data/lib/schematic/types/condition_group_view.rb +16 -0
- data/lib/schematic/types/condition_metric_period.rb +14 -0
- data/lib/schematic/types/condition_metric_period_month_reset.rb +12 -0
- data/lib/schematic/types/condition_operator.rb +18 -0
- data/lib/schematic/types/condition_response_data.rb +32 -0
- data/lib/schematic/types/condition_view.rb +39 -0
- data/lib/schematic/types/count_response.rb +9 -0
- data/lib/schematic/types/coupon_request_body.rb +16 -0
- data/lib/schematic/types/create_billing_plan_credit_grant_request_body.rb +26 -0
- data/lib/schematic/types/create_billing_price_tier_request_body.rb +14 -0
- data/lib/schematic/types/create_entitlement_in_bundle_request_body.rb +36 -0
- data/lib/schematic/types/create_entitlement_in_bundle_request_body_metric_period.rb +14 -0
- data/lib/schematic/types/create_entitlement_in_bundle_request_body_metric_period_month_reset.rb +12 -0
- data/lib/schematic/types/create_entitlement_req_common.rb +17 -0
- data/lib/schematic/types/create_entitlement_req_common_metric_period.rb +14 -0
- data/lib/schematic/types/create_entitlement_req_common_metric_period_month_reset.rb +12 -0
- data/lib/schematic/types/create_event_request_body.rb +11 -0
- data/lib/schematic/types/create_flag_request_body.rb +15 -0
- data/lib/schematic/types/create_or_update_condition_group_request_body.rb +11 -0
- data/lib/schematic/types/create_or_update_condition_request_body.rb +21 -0
- data/lib/schematic/types/create_or_update_condition_request_body_condition_type.rb +17 -0
- data/lib/schematic/types/create_or_update_condition_request_body_metric_period.rb +14 -0
- data/lib/schematic/types/create_or_update_condition_request_body_metric_period_month_reset.rb +12 -0
- data/lib/schematic/types/create_or_update_condition_request_body_operator.rb +18 -0
- data/lib/schematic/types/create_or_update_flag_request_body.rb +16 -0
- data/lib/schematic/types/create_or_update_rule_request_body.rb +15 -0
- data/lib/schematic/types/create_or_update_rule_request_body_rule_type.rb +15 -0
- data/lib/schematic/types/create_plan_request_body.rb +12 -0
- data/lib/schematic/types/create_price_tier_request_body.rb +12 -0
- data/lib/schematic/types/credit_auto_topup_amount_type.rb +23 -0
- data/lib/schematic/types/credit_bundle_currency_price.rb +10 -0
- data/lib/schematic/types/credit_bundle_currency_price_request_body.rb +11 -0
- data/lib/schematic/types/credit_bundle_currency_price_response_data.rb +10 -0
- data/lib/schematic/types/credit_bundle_purchase_response_data.rb +11 -0
- data/lib/schematic/types/credit_company_grant_view.rb +40 -0
- data/lib/schematic/types/credit_currency_price_request_body.rb +11 -0
- data/lib/schematic/types/credit_currency_price_response_data.rb +10 -0
- data/lib/schematic/types/credit_event_ledger_response_data.rb +39 -0
- data/lib/schematic/types/credit_event_type.rb +14 -0
- data/lib/schematic/types/credit_grant_detail.rb +12 -0
- data/lib/schematic/types/credit_grant_expiry_request_body.rb +14 -0
- data/lib/schematic/types/credit_grant_sort_order.rb +14 -0
- data/lib/schematic/types/credit_ledger_enriched_entry_response_data.rb +30 -0
- data/lib/schematic/types/credit_ledger_period.rb +14 -0
- data/lib/schematic/types/credit_transfer_response_data.rb +14 -0
- data/lib/schematic/types/credit_transfer_view.rb +14 -0
- data/lib/schematic/types/credit_trigger_config.rb +9 -0
- data/lib/schematic/types/credit_usage.rb +17 -0
- data/lib/schematic/types/credit_usage_aggregation.rb +12 -0
- data/lib/schematic/types/credits_auto_topup_company_summary.rb +10 -0
- data/lib/schematic/types/credits_auto_topup_credit_summary.rb +10 -0
- data/lib/schematic/types/credits_auto_topup_hard_failure.rb +12 -0
- data/lib/schematic/types/credits_auto_topup_retry_failure.rb +13 -0
- data/lib/schematic/types/currency_price_request_body.rb +15 -0
- data/lib/schematic/types/custom_plan_config.rb +11 -0
- data/lib/schematic/types/custom_plan_view_config_response_data.rb +11 -0
- data/lib/schematic/types/data_event_payload.rb +12 -0
- data/lib/schematic/types/data_export_output_file_type.rb +23 -0
- data/lib/schematic/types/data_export_response_data.rb +17 -0
- data/lib/schematic/types/data_export_status.rb +13 -0
- data/lib/schematic/types/data_export_type.rb +23 -0
- data/lib/schematic/types/datastream_company_plan.rb +11 -0
- data/lib/schematic/types/delete_billing_plan_credit_grant_request_body.rb +9 -0
- data/lib/schematic/types/delete_response.rb +9 -0
- data/lib/schematic/types/duplicate_plan_entitlements_response_response_data.rb +10 -0
- data/lib/schematic/types/entitlement_currency_prices_response_data.rb +11 -0
- data/lib/schematic/types/entitlement_price_behavior.rb +15 -0
- data/lib/schematic/types/entitlement_trigger_config.rb +9 -0
- data/lib/schematic/types/entitlement_type.rb +13 -0
- data/lib/schematic/types/entitlement_value_type.rb +16 -0
- data/lib/schematic/types/entitlements_in_plan.rb +10 -0
- data/lib/schematic/types/entity_key_definition_response_data.rb +13 -0
- data/lib/schematic/types/entity_key_detail_response_data.rb +18 -0
- data/lib/schematic/types/entity_key_response_data.rb +17 -0
- data/lib/schematic/types/entity_trait_definition_response_data.rb +15 -0
- data/lib/schematic/types/entity_trait_detail_response_data.rb +15 -0
- data/lib/schematic/types/entity_trait_response_data.rb +14 -0
- data/lib/schematic/types/entity_trait_value.rb +10 -0
- data/lib/schematic/types/entity_type.rb +12 -0
- data/lib/schematic/types/environment_detail_response_data.rb +14 -0
- data/lib/schematic/types/environment_response_data.rb +13 -0
- data/lib/schematic/types/environment_type.rb +13 -0
- data/lib/schematic/types/event_body.rb +13 -0
- data/lib/schematic/types/event_body_flag_check.rb +18 -0
- data/lib/schematic/types/event_body_identify.rb +12 -0
- data/lib/schematic/types/event_body_identify_company.rb +12 -0
- data/lib/schematic/types/event_body_track.rb +13 -0
- data/lib/schematic/types/event_detail_response_data.rb +30 -0
- data/lib/schematic/types/event_response_data.rb +27 -0
- data/lib/schematic/types/event_status.rb +15 -0
- data/lib/schematic/types/event_summary_response_data.rb +14 -0
- data/lib/schematic/types/event_type.rb +13 -0
- data/lib/schematic/types/feature_company_response_data.rb +44 -0
- data/lib/schematic/types/feature_company_user_response_data.rb +21 -0
- data/lib/schematic/types/feature_detail_response_data.rb +25 -0
- data/lib/schematic/types/feature_entitlement.rb +22 -0
- data/lib/schematic/types/feature_entitlement_metric_period.rb +14 -0
- data/lib/schematic/types/feature_entitlement_month_reset.rb +12 -0
- data/lib/schematic/types/feature_ledger_response_data.rb +12 -0
- data/lib/schematic/types/feature_lifecycle_phase.rb +19 -0
- data/lib/schematic/types/feature_response_data.rb +21 -0
- data/lib/schematic/types/feature_type.rb +13 -0
- data/lib/schematic/types/feature_usage_detail_response_data.rb +9 -0
- data/lib/schematic/types/feature_usage_legacy_response_data.rb +14 -0
- data/lib/schematic/types/feature_usage_response_data.rb +42 -0
- data/lib/schematic/types/feature_usage_time_series_response_data.rb +13 -0
- data/lib/schematic/types/feature_view.rb +26 -0
- data/lib/schematic/types/flag_detail_response_data.rb +21 -0
- data/lib/schematic/types/flag_response_data.rb +18 -0
- data/lib/schematic/types/flag_type.rb +23 -0
- data/lib/schematic/types/flag_view.rb +22 -0
- data/lib/schematic/types/generic_preview_object.rb +12 -0
- data/lib/schematic/types/invoice_request_body.rb +20 -0
- data/lib/schematic/types/invoice_response_data.rb +27 -0
- data/lib/schematic/types/invoice_status.rb +15 -0
- data/lib/schematic/types/issue_temporary_access_token_response_data.rb +16 -0
- data/lib/schematic/types/keys_request_body.rb +9 -0
- data/lib/schematic/types/limit_time_series_point_response_data.rb +14 -0
- data/lib/schematic/types/manage_plan_preview_response_response_data.rb +9 -0
- data/lib/schematic/types/manage_plan_request.rb +21 -0
- data/lib/schematic/types/manage_plan_response_response_data.rb +10 -0
- data/lib/schematic/types/meter_request_body.rb +11 -0
- data/lib/schematic/types/ordered_plans_in_group.rb +10 -0
- data/lib/schematic/types/payment_method_request_body.rb +19 -0
- data/lib/schematic/types/payment_method_response_data.rb +26 -0
- data/lib/schematic/types/plan_bundle_action.rb +13 -0
- data/lib/schematic/types/plan_bundle_credit_grant_request_body.rb +13 -0
- data/lib/schematic/types/plan_bundle_entitlement_request_body.rb +11 -0
- data/lib/schematic/types/plan_bundle_response_data.rb +13 -0
- data/lib/schematic/types/plan_change_action.rb +21 -0
- data/lib/schematic/types/plan_change_base_plan_action.rb +14 -0
- data/lib/schematic/types/plan_change_response_data.rb +30 -0
- data/lib/schematic/types/plan_change_subscription_action.rb +17 -0
- data/lib/schematic/types/plan_controlled_by_type.rb +12 -0
- data/lib/schematic/types/plan_credit_grant_view.rb +35 -0
- data/lib/schematic/types/plan_currency_price_request_body.rb +12 -0
- data/lib/schematic/types/plan_currency_prices_response_data.rb +12 -0
- data/lib/schematic/types/plan_detail_response_data.rb +33 -0
- data/lib/schematic/types/plan_entitlement_response_data.rb +34 -0
- data/lib/schematic/types/plan_entitlements_order.rb +10 -0
- data/lib/schematic/types/plan_group_bundle_order.rb +9 -0
- data/lib/schematic/types/plan_group_detail_response_data.rb +45 -0
- data/lib/schematic/types/plan_group_plan_detail_response_data.rb +37 -0
- data/lib/schematic/types/plan_group_plan_entitlements_order.rb +10 -0
- data/lib/schematic/types/plan_group_response_data.rb +36 -0
- data/lib/schematic/types/plan_issue_response_data.rb +12 -0
- data/lib/schematic/types/plan_response_data.rb +16 -0
- data/lib/schematic/types/plan_selection.rb +11 -0
- data/lib/schematic/types/plan_snapshot_view.rb +13 -0
- data/lib/schematic/types/plan_trait_response_data.rb +17 -0
- data/lib/schematic/types/plan_type.rb +12 -0
- data/lib/schematic/types/plan_version_company_migration_response_data.rb +19 -0
- data/lib/schematic/types/plan_version_company_migration_status.rb +15 -0
- data/lib/schematic/types/plan_version_migration_response_data.rb +23 -0
- data/lib/schematic/types/plan_version_migration_status.rb +14 -0
- data/lib/schematic/types/plan_version_migration_strategy.rb +12 -0
- data/lib/schematic/types/plan_version_response_data.rb +19 -0
- data/lib/schematic/types/plan_version_snapshot_view.rb +11 -0
- data/lib/schematic/types/plan_version_status.rb +13 -0
- data/lib/schematic/types/plan_view_public_response_data.rb +38 -0
- data/lib/schematic/types/preview_object.rb +12 -0
- data/lib/schematic/types/preview_object_response_data.rb +12 -0
- data/lib/schematic/types/preview_subscription_change_response_data.rb +21 -0
- data/lib/schematic/types/preview_subscription_finance_response_data.rb +21 -0
- data/lib/schematic/types/preview_subscription_upcoming_invoice_line_items.rb +13 -0
- data/lib/schematic/types/proration_behavior.rb +12 -0
- data/lib/schematic/types/public_plans_response_data.rb +17 -0
- data/lib/schematic/types/quickstart_resp.rb +9 -0
- data/lib/schematic/types/raw_event_batch_response_data.rb +9 -0
- data/lib/schematic/types/raw_event_response_data.rb +13 -0
- data/lib/schematic/types/rule.rb +18 -0
- data/lib/schematic/types/rule_condition_detail_response_data.rb +29 -0
- data/lib/schematic/types/rule_condition_group_detail_response_data.rb +15 -0
- data/lib/schematic/types/rule_condition_group_response_data.rb +14 -0
- data/lib/schematic/types/rule_condition_response_data.rb +26 -0
- data/lib/schematic/types/rule_detail_response_data.rb +19 -0
- data/lib/schematic/types/rule_response_data.rb +17 -0
- data/lib/schematic/types/rule_rule_type.rb +17 -0
- data/lib/schematic/types/rule_view.rb +20 -0
- data/lib/schematic/types/rules_detail_response_data.rb +10 -0
- data/lib/schematic/types/rules_engine_schema_version.rb +12 -0
- data/lib/schematic/types/rulesengine_check_flag_result.rb +23 -0
- data/lib/schematic/types/rulesengine_check_flag_result_feature_usage_period.rb +14 -0
- data/lib/schematic/types/rulesengine_check_flag_result_rule_type.rb +17 -0
- data/lib/schematic/types/rulesengine_company.rb +22 -0
- data/lib/schematic/types/rulesengine_company_metric.rb +17 -0
- data/lib/schematic/types/rulesengine_company_metric_month_reset.rb +12 -0
- data/lib/schematic/types/rulesengine_company_metric_period.rb +14 -0
- data/lib/schematic/types/rulesengine_condition.rb +23 -0
- data/lib/schematic/types/rulesengine_condition_condition_type.rb +19 -0
- data/lib/schematic/types/rulesengine_condition_group.rb +9 -0
- data/lib/schematic/types/rulesengine_condition_metric_period.rb +14 -0
- data/lib/schematic/types/rulesengine_condition_metric_period_month_reset.rb +12 -0
- data/lib/schematic/types/rulesengine_condition_operator.rb +18 -0
- data/lib/schematic/types/rulesengine_entitlement_value_type.rb +16 -0
- data/lib/schematic/types/rulesengine_entity_type.rb +12 -0
- data/lib/schematic/types/rulesengine_feature_entitlement.rb +22 -0
- data/lib/schematic/types/rulesengine_feature_entitlement_metric_period.rb +14 -0
- data/lib/schematic/types/rulesengine_feature_entitlement_month_reset.rb +12 -0
- data/lib/schematic/types/rulesengine_flag.rb +14 -0
- data/lib/schematic/types/rulesengine_rule.rb +18 -0
- data/lib/schematic/types/rulesengine_rule_rule_type.rb +17 -0
- data/lib/schematic/types/rulesengine_subscription.rb +11 -0
- data/lib/schematic/types/rulesengine_trait.rb +10 -0
- data/lib/schematic/types/rulesengine_trait_definition.rb +11 -0
- data/lib/schematic/types/rulesengine_trait_definition_comparable_type.rb +14 -0
- data/lib/schematic/types/rulesengine_user.rb +14 -0
- data/lib/schematic/types/scheduled_checkout_response_data.rb +22 -0
- data/lib/schematic/types/scheduled_checkout_status.rb +15 -0
- data/lib/schematic/types/scheduled_downgrade_config_behavior.rb +12 -0
- data/lib/schematic/types/scheduled_downgrade_response_data.rb +19 -0
- data/lib/schematic/types/segment_status_resp.rb +11 -0
- data/lib/schematic/types/skipped_entitlement_error_response_data.rb +9 -0
- data/lib/schematic/types/skipped_entitlement_response_data.rb +12 -0
- data/lib/schematic/types/sort_direction.rb +12 -0
- data/lib/schematic/types/stripe_embed_info.rb +12 -0
- data/lib/schematic/types/subscription_status.rb +19 -0
- data/lib/schematic/types/subscription_trait_update.rb +15 -0
- data/lib/schematic/types/subscription_type.rb +14 -0
- data/lib/schematic/types/temporary_access_token_resource_type.rb +23 -0
- data/lib/schematic/types/temporary_access_token_response_data.rb +15 -0
- data/lib/schematic/types/time_series_granularity.rb +14 -0
- data/lib/schematic/types/trait_definition.rb +11 -0
- data/lib/schematic/types/trait_definition_comparable_type.rb +14 -0
- data/lib/schematic/types/trait_type.rb +16 -0
- data/lib/schematic/types/update_add_on_request_body.rb +10 -0
- data/lib/schematic/types/update_billing_plan_credit_grant_request_body.rb +23 -0
- data/lib/schematic/types/update_credit_bundle_request_body.rb +10 -0
- data/lib/schematic/types/update_entitlement_req_common.rb +16 -0
- data/lib/schematic/types/update_entitlement_req_common_metric_period.rb +14 -0
- data/lib/schematic/types/update_entitlement_req_common_metric_period_month_reset.rb +12 -0
- data/lib/schematic/types/update_pay_in_advance_request_body.rb +10 -0
- data/lib/schematic/types/update_plan_request_body.rb +11 -0
- data/lib/schematic/types/update_plan_trait_trait_request_body.rb +10 -0
- data/lib/schematic/types/update_rule_request_body.rb +13 -0
- data/lib/schematic/types/upsert_billing_product_request_body.rb +20 -0
- data/lib/schematic/types/upsert_company_request_body.rb +15 -0
- data/lib/schematic/types/upsert_trait_request_body.rb +13 -0
- data/lib/schematic/types/upsert_user_request_body.rb +18 -0
- data/lib/schematic/types/upsert_user_sub_request_body.rb +16 -0
- data/lib/schematic/types/usage_based_entitlement_request_body.rb +25 -0
- data/lib/schematic/types/usage_based_entitlement_response_data.rb +20 -0
- data/lib/schematic/types/usage_time_series_point_response_data.rb +12 -0
- data/lib/schematic/types/user_detail_response_data.rb +18 -0
- data/lib/schematic/types/user_response_data.rb +14 -0
- data/lib/schematic/types/web_feature_usage_webhook_output.rb +15 -0
- data/lib/schematic/types/web_scheduled_downgrade_webhook_output.rb +15 -0
- data/lib/schematic/types/webhook_event_detail_response_data.rb +18 -0
- data/lib/schematic/types/webhook_event_response_data.rb +17 -0
- data/lib/schematic/types/webhook_event_status.rb +13 -0
- data/lib/schematic/types/webhook_request_type.rb +49 -0
- data/lib/schematic/types/webhook_response_data.rb +18 -0
- data/lib/schematic/types/webhook_status.rb +12 -0
- data/lib/schematic/types/who_am_i_response_data.rb +17 -0
- data/lib/schematic/version.rb +5 -0
- data/lib/schematic/wasm/rulesengine.wasm +0 -0
- data/lib/schematic/webhook_verification.rb +83 -0
- data/lib/schematic/webhooks/client.rb +355 -0
- data/lib/schematic/webhooks/types/count_webhook_events_params.rb +16 -0
- data/lib/schematic/webhooks/types/count_webhook_events_request.rb +15 -0
- data/lib/schematic/webhooks/types/count_webhook_events_response.rb +12 -0
- data/lib/schematic/webhooks/types/count_webhooks_params.rb +14 -0
- data/lib/schematic/webhooks/types/count_webhooks_request.rb +13 -0
- data/lib/schematic/webhooks/types/count_webhooks_response.rb +12 -0
- data/lib/schematic/webhooks/types/create_webhook_request_body.rb +15 -0
- data/lib/schematic/webhooks/types/create_webhook_response.rb +12 -0
- data/lib/schematic/webhooks/types/delete_webhook_response.rb +12 -0
- data/lib/schematic/webhooks/types/get_webhook_event_response.rb +12 -0
- data/lib/schematic/webhooks/types/get_webhook_response.rb +12 -0
- data/lib/schematic/webhooks/types/list_webhook_events_params.rb +16 -0
- data/lib/schematic/webhooks/types/list_webhook_events_request.rb +15 -0
- data/lib/schematic/webhooks/types/list_webhook_events_response.rb +12 -0
- data/lib/schematic/webhooks/types/list_webhooks_params.rb +14 -0
- data/lib/schematic/webhooks/types/list_webhooks_request.rb +13 -0
- data/lib/schematic/webhooks/types/list_webhooks_response.rb +12 -0
- data/lib/schematic/webhooks/types/update_webhook_request_body.rb +17 -0
- data/lib/schematic/webhooks/types/update_webhook_response.rb +12 -0
- data/lib/schematic.rb +821 -0
- data/lib/schematichq.rb +17 -0
- data/reference.md +16668 -0
- data/scripts/download-wasm.sh +82 -0
- data/scripts/webhook_test_server.rb +55 -0
- data/testapp/Gemfile +6 -0
- data/testapp/app.rb +307 -0
- metadata +917 -0
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
module UpdateEntitlementReqCommonMetricPeriod
|
|
6
|
+
extend Schematic::Internal::Types::Enum
|
|
7
|
+
|
|
8
|
+
ALL_TIME = "all_time"
|
|
9
|
+
CURRENT_MONTH = "current_month"
|
|
10
|
+
CURRENT_WEEK = "current_week"
|
|
11
|
+
CURRENT_DAY = "current_day"
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
module UpdateEntitlementReqCommonMetricPeriodMonthReset
|
|
6
|
+
extend Schematic::Internal::Types::Enum
|
|
7
|
+
|
|
8
|
+
FIRST_OF_MONTH = "first_of_month"
|
|
9
|
+
BILLING_CYCLE = "billing_cycle"
|
|
10
|
+
end
|
|
11
|
+
end
|
|
12
|
+
end
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpdatePayInAdvanceRequestBody < Internal::Types::Model
|
|
6
|
+
field :price_id, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :quantity, -> { Integer }, optional: false, nullable: false
|
|
8
|
+
end
|
|
9
|
+
end
|
|
10
|
+
end
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpdatePlanRequestBody < Internal::Types::Model
|
|
6
|
+
field :description, -> { String }, optional: true, nullable: false
|
|
7
|
+
field :icon, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :name, -> { String }, optional: false, nullable: false
|
|
9
|
+
end
|
|
10
|
+
end
|
|
11
|
+
end
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpdatePlanTraitTraitRequestBody < Internal::Types::Model
|
|
6
|
+
field :trait_id, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :trait_value, -> { String }, optional: false, nullable: false
|
|
8
|
+
end
|
|
9
|
+
end
|
|
10
|
+
end
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpdateRuleRequestBody < Internal::Types::Model
|
|
6
|
+
field :condition_groups, -> { Internal::Types::Array[Schematic::Types::CreateOrUpdateConditionGroupRequestBody] }, optional: false, nullable: false
|
|
7
|
+
field :conditions, -> { Internal::Types::Array[Schematic::Types::CreateOrUpdateConditionRequestBody] }, optional: false, nullable: false
|
|
8
|
+
field :name, -> { String }, optional: false, nullable: false
|
|
9
|
+
field :priority, -> { Integer }, optional: false, nullable: false
|
|
10
|
+
field :value, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpsertBillingProductRequestBody < Internal::Types::Model
|
|
6
|
+
field :billing_product_id, -> { String }, optional: true, nullable: false
|
|
7
|
+
field :charge_type, -> { Schematic::Types::ChargeType }, optional: false, nullable: false
|
|
8
|
+
field :currency, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :currency_prices, -> { Internal::Types::Array[Schematic::Types::PlanCurrencyPriceRequestBody] }, optional: true, nullable: false
|
|
10
|
+
field :is_trialable, -> { Internal::Types::Boolean }, optional: false, nullable: false
|
|
11
|
+
field :monthly_price, -> { Integer }, optional: true, nullable: false
|
|
12
|
+
field :monthly_price_id, -> { String }, optional: true, nullable: false
|
|
13
|
+
field :one_time_price, -> { Integer }, optional: true, nullable: false
|
|
14
|
+
field :one_time_price_id, -> { String }, optional: true, nullable: false
|
|
15
|
+
field :trial_days, -> { Integer }, optional: true, nullable: false
|
|
16
|
+
field :yearly_price, -> { Integer }, optional: true, nullable: false
|
|
17
|
+
field :yearly_price_id, -> { String }, optional: true, nullable: false
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpsertCompanyRequestBody < Internal::Types::Model
|
|
6
|
+
field :id, -> { String }, optional: true, nullable: false
|
|
7
|
+
field :keys, -> { Internal::Types::Hash[String, String] }, optional: false, nullable: false
|
|
8
|
+
field :last_seen_at, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :name, -> { String }, optional: true, nullable: false
|
|
10
|
+
field :prevent_key_remap, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
11
|
+
field :traits, -> { Internal::Types::Hash[String, Object] }, optional: true, nullable: false
|
|
12
|
+
field :update_only, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpsertTraitRequestBody < Internal::Types::Model
|
|
6
|
+
field :incr, -> { Integer }, optional: true, nullable: false
|
|
7
|
+
field :keys, -> { Internal::Types::Hash[String, String] }, optional: false, nullable: false
|
|
8
|
+
field :set, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :trait, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :update_only, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpsertUserRequestBody < Internal::Types::Model
|
|
6
|
+
field :companies, -> { Internal::Types::Array[Internal::Types::Hash[String, String]] }, optional: true, nullable: false
|
|
7
|
+
field :company, -> { Internal::Types::Hash[String, String] }, optional: true, nullable: false
|
|
8
|
+
field :company_id, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :company_ids, -> { Internal::Types::Array[String] }, optional: true, nullable: false
|
|
10
|
+
field :id, -> { String }, optional: true, nullable: false
|
|
11
|
+
field :keys, -> { Internal::Types::Hash[String, String] }, optional: false, nullable: false
|
|
12
|
+
field :last_seen_at, -> { String }, optional: true, nullable: false
|
|
13
|
+
field :name, -> { String }, optional: true, nullable: false
|
|
14
|
+
field :traits, -> { Internal::Types::Hash[String, Object] }, optional: true, nullable: false
|
|
15
|
+
field :update_only, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UpsertUserSubRequestBody < Internal::Types::Model
|
|
6
|
+
field :company_id, -> { String }, optional: true, nullable: false
|
|
7
|
+
field :company_ids, -> { Internal::Types::Array[String] }, optional: true, nullable: false
|
|
8
|
+
field :id, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :keys, -> { Internal::Types::Hash[String, String] }, optional: false, nullable: false
|
|
10
|
+
field :last_seen_at, -> { String }, optional: true, nullable: false
|
|
11
|
+
field :name, -> { String }, optional: true, nullable: false
|
|
12
|
+
field :traits, -> { Internal::Types::Hash[String, Object] }, optional: true, nullable: false
|
|
13
|
+
field :update_only, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UsageBasedEntitlementRequestBody < Internal::Types::Model
|
|
6
|
+
field :billing_product_id, -> { String }, optional: true, nullable: false
|
|
7
|
+
field :billing_threshold, -> { Integer }, optional: true, nullable: false
|
|
8
|
+
field :currency, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :currency_prices, -> { Internal::Types::Array[Schematic::Types::CurrencyPriceRequestBody] }, optional: true, nullable: false
|
|
10
|
+
field :monthly_metered_price_id, -> { String }, optional: true, nullable: false
|
|
11
|
+
field :monthly_price_tiers, -> { Internal::Types::Array[Schematic::Types::CreatePriceTierRequestBody] }, optional: true, nullable: false
|
|
12
|
+
field :monthly_unit_price, -> { Integer }, optional: true, nullable: false
|
|
13
|
+
field :monthly_unit_price_decimal, -> { String }, optional: true, nullable: false
|
|
14
|
+
field :overage_billing_product_id, -> { String }, optional: true, nullable: false
|
|
15
|
+
field :price_behavior, -> { Schematic::Types::EntitlementPriceBehavior }, optional: true, nullable: false
|
|
16
|
+
field :price_tiers, -> { Internal::Types::Array[Schematic::Types::CreatePriceTierRequestBody] }, optional: true, nullable: false
|
|
17
|
+
field :soft_limit, -> { Integer }, optional: true, nullable: false
|
|
18
|
+
field :tier_mode, -> { Schematic::Types::BillingTiersMode }, optional: true, nullable: false
|
|
19
|
+
field :yearly_metered_price_id, -> { String }, optional: true, nullable: false
|
|
20
|
+
field :yearly_price_tiers, -> { Internal::Types::Array[Schematic::Types::CreatePriceTierRequestBody] }, optional: true, nullable: false
|
|
21
|
+
field :yearly_unit_price, -> { Integer }, optional: true, nullable: false
|
|
22
|
+
field :yearly_unit_price_decimal, -> { String }, optional: true, nullable: false
|
|
23
|
+
end
|
|
24
|
+
end
|
|
25
|
+
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UsageBasedEntitlementResponseData < Internal::Types::Model
|
|
6
|
+
field :billing_threshold, -> { Integer }, optional: true, nullable: false
|
|
7
|
+
field :consumption_rate, -> { Integer }, optional: true, nullable: false
|
|
8
|
+
field :feature_id, -> { String }, optional: false, nullable: false
|
|
9
|
+
field :metered_price, -> { Schematic::Types::BillingPriceView }, optional: true, nullable: false
|
|
10
|
+
field :metric_period, -> { String }, optional: true, nullable: false
|
|
11
|
+
field :metric_period_month_reset, -> { String }, optional: true, nullable: false
|
|
12
|
+
field :monthly_usage_based_price, -> { Schematic::Types::BillingPriceView }, optional: true, nullable: false
|
|
13
|
+
field :price_behavior, -> { Schematic::Types::EntitlementPriceBehavior }, optional: true, nullable: false
|
|
14
|
+
field :value_bool, -> { Internal::Types::Boolean }, optional: true, nullable: false
|
|
15
|
+
field :value_numeric, -> { Integer }, optional: true, nullable: false
|
|
16
|
+
field :value_type, -> { Schematic::Types::EntitlementValueType }, optional: false, nullable: false
|
|
17
|
+
field :yearly_usage_based_price, -> { Schematic::Types::BillingPriceView }, optional: true, nullable: false
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UsageTimeSeriesPointResponseData < Internal::Types::Model
|
|
6
|
+
field :period_end, -> { String }, optional: true, nullable: false
|
|
7
|
+
field :period_start, -> { String }, optional: true, nullable: false
|
|
8
|
+
field :timestamp, -> { String }, optional: false, nullable: false
|
|
9
|
+
field :usage, -> { Integer }, optional: false, nullable: false
|
|
10
|
+
end
|
|
11
|
+
end
|
|
12
|
+
end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UserDetailResponseData < Internal::Types::Model
|
|
6
|
+
field :company_memberships, -> { Internal::Types::Array[Schematic::Types::CompanyMembershipDetailResponseData] }, optional: false, nullable: false
|
|
7
|
+
field :created_at, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :entity_traits, -> { Internal::Types::Array[Schematic::Types::EntityTraitDetailResponseData] }, optional: false, nullable: false
|
|
9
|
+
field :environment_id, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
11
|
+
field :keys, -> { Internal::Types::Array[Schematic::Types::EntityKeyDetailResponseData] }, optional: false, nullable: false
|
|
12
|
+
field :last_seen_at, -> { String }, optional: true, nullable: false
|
|
13
|
+
field :name, -> { String }, optional: false, nullable: false
|
|
14
|
+
field :traits, -> { Internal::Types::Hash[String, Object] }, optional: true, nullable: false
|
|
15
|
+
field :updated_at, -> { String }, optional: false, nullable: false
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class UserResponseData < Internal::Types::Model
|
|
6
|
+
field :created_at, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :environment_id, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
9
|
+
field :last_seen_at, -> { String }, optional: true, nullable: false
|
|
10
|
+
field :name, -> { String }, optional: false, nullable: false
|
|
11
|
+
field :updated_at, -> { String }, optional: false, nullable: false
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class WebFeatureUsageWebhookOutput < Internal::Types::Model
|
|
6
|
+
field :allocation, -> { Integer }, optional: true, nullable: false, api_name: "Allocation"
|
|
7
|
+
field :credit_usage, -> { Schematic::Types::CreditUsage }, optional: true, nullable: false, api_name: "CreditUsage"
|
|
8
|
+
field :entitlement, -> { String }, optional: false, nullable: false, api_name: "Entitlement"
|
|
9
|
+
field :feature, -> { Schematic::Types::FeatureView }, optional: true, nullable: false, api_name: "Feature"
|
|
10
|
+
field :metric_reset_at, -> { String }, optional: true, nullable: false, api_name: "MetricResetAt"
|
|
11
|
+
field :usage, -> { Integer }, optional: true, nullable: false, api_name: "Usage"
|
|
12
|
+
field :company, -> { Schematic::Types::CompanyDetailResponseData }, optional: true, nullable: false
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class WebScheduledDowngradeWebhookOutput < Internal::Types::Model
|
|
6
|
+
field :company, -> { Schematic::Types::CompanyResponseData }, optional: true, nullable: false
|
|
7
|
+
field :execute_after, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :from_plan, -> { Schematic::Types::PlanSnapshotView }, optional: true, nullable: false
|
|
9
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :scheduled_interval, -> { String }, optional: true, nullable: false
|
|
11
|
+
field :scheduled_price, -> { Integer }, optional: true, nullable: false
|
|
12
|
+
field :to_plan, -> { Schematic::Types::PlanSnapshotView }, optional: true, nullable: false
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class WebhookEventDetailResponseData < Internal::Types::Model
|
|
6
|
+
field :created_at, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :payload, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :request_type, -> { Schematic::Types::WebhookRequestType }, optional: false, nullable: false
|
|
10
|
+
field :response_code, -> { Integer }, optional: true, nullable: false
|
|
11
|
+
field :sent_at, -> { String }, optional: true, nullable: false
|
|
12
|
+
field :status, -> { Schematic::Types::WebhookEventStatus }, optional: false, nullable: false
|
|
13
|
+
field :updated_at, -> { String }, optional: false, nullable: false
|
|
14
|
+
field :webhook, -> { Schematic::Types::WebhookResponseData }, optional: true, nullable: false
|
|
15
|
+
field :webhook_id, -> { String }, optional: false, nullable: false
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class WebhookEventResponseData < Internal::Types::Model
|
|
6
|
+
field :created_at, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :payload, -> { String }, optional: true, nullable: false
|
|
9
|
+
field :request_type, -> { Schematic::Types::WebhookRequestType }, optional: false, nullable: false
|
|
10
|
+
field :response_code, -> { Integer }, optional: true, nullable: false
|
|
11
|
+
field :sent_at, -> { String }, optional: true, nullable: false
|
|
12
|
+
field :status, -> { Schematic::Types::WebhookEventStatus }, optional: false, nullable: false
|
|
13
|
+
field :updated_at, -> { String }, optional: false, nullable: false
|
|
14
|
+
field :webhook_id, -> { String }, optional: false, nullable: false
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
module WebhookRequestType
|
|
6
|
+
extend Schematic::Internal::Types::Enum
|
|
7
|
+
|
|
8
|
+
SUBSCRIPTION_TRIAL_ENDED = "subscription.trial.ended"
|
|
9
|
+
COMPANY_CREATED = "company.created"
|
|
10
|
+
COMPANY_DELETED = "company.deleted"
|
|
11
|
+
COMPANY_OVERRIDE_CREATED = "company.override.created"
|
|
12
|
+
COMPANY_OVERRIDE_DELETED = "company.override.deleted"
|
|
13
|
+
COMPANY_OVERRIDE_EXPIRED = "company.override.expired"
|
|
14
|
+
COMPANY_OVERRIDE_UPDATED = "company.override.updated"
|
|
15
|
+
COMPANY_PLAN_CHANGED = "company.plan_changed"
|
|
16
|
+
COMPANY_SCHEDULED_DOWNGRADE = "company.scheduled_downgrade"
|
|
17
|
+
COMPANY_UPDATED = "company.updated"
|
|
18
|
+
CREDIT_LIMIT_REACHED = "credit.limit.reached"
|
|
19
|
+
CREDIT_LIMIT_WARNING = "credit.limit.warning"
|
|
20
|
+
ENTITLEMENT_LIMIT_REACHED = "entitlement.limit.reached"
|
|
21
|
+
ENTITLEMENT_LIMIT_WARNING = "entitlement.limit.warning"
|
|
22
|
+
ENTITLEMENT_SOFT_LIMIT_REACHED = "entitlement.soft_limit.reached"
|
|
23
|
+
ENTITLEMENT_SOFT_LIMIT_WARNING = "entitlement.soft_limit.warning"
|
|
24
|
+
ENTITLEMENT_TIER_LIMIT_REACHED = "entitlement.tier_limit.reached"
|
|
25
|
+
ENTITLEMENT_TIER_LIMIT_WARNING = "entitlement.tier_limit.warning"
|
|
26
|
+
FEATURE_CREATED = "feature.created"
|
|
27
|
+
FEATURE_DELETED = "feature.deleted"
|
|
28
|
+
FEATURE_UPDATED = "feature.updated"
|
|
29
|
+
FLAG_CREATED = "flag.created"
|
|
30
|
+
FLAG_DELETED = "flag.deleted"
|
|
31
|
+
FLAG_RULES_UPDATED = "flag_rules.updated"
|
|
32
|
+
FLAG_UPDATED = "flag.updated"
|
|
33
|
+
PLAN_CREATED = "plan.created"
|
|
34
|
+
PLAN_DELETED = "plan.deleted"
|
|
35
|
+
PLAN_ENTITLEMENT_CREATED = "plan.entitlement.created"
|
|
36
|
+
PLAN_ENTITLEMENT_DELETED = "plan.entitlement.deleted"
|
|
37
|
+
PLAN_ENTITLEMENT_UPDATED = "plan.entitlement.updated"
|
|
38
|
+
PLAN_UPDATED = "plan.updated"
|
|
39
|
+
PLAN_VERSION_DELETED = "plan_version.deleted"
|
|
40
|
+
RULE_DELETED = "rule.deleted"
|
|
41
|
+
TEST_SEND = "test.send"
|
|
42
|
+
USER_CREATED = "user.created"
|
|
43
|
+
USER_DELETED = "user.deleted"
|
|
44
|
+
USER_UPDATED = "user.updated"
|
|
45
|
+
AUTO_TOPUP_HARD_FAILURE = "auto.topup.hard.failure"
|
|
46
|
+
AUTO_TOPUP_RETRY_EXCEEDED = "auto.topup.retry.exceeded"
|
|
47
|
+
end
|
|
48
|
+
end
|
|
49
|
+
end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class WebhookResponseData < Internal::Types::Model
|
|
6
|
+
field :created_at, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :credit_trigger_configs, -> { Internal::Types::Array[Schematic::Types::CreditTriggerConfig] }, optional: true, nullable: false
|
|
8
|
+
field :entitlement_trigger_configs, -> { Internal::Types::Array[Schematic::Types::EntitlementTriggerConfig] }, optional: true, nullable: false
|
|
9
|
+
field :id, -> { String }, optional: false, nullable: false
|
|
10
|
+
field :name, -> { String }, optional: false, nullable: false
|
|
11
|
+
field :request_types, -> { Internal::Types::Array[Schematic::Types::WebhookRequestType] }, optional: false, nullable: false
|
|
12
|
+
field :secret, -> { String }, optional: false, nullable: false
|
|
13
|
+
field :status, -> { Schematic::Types::WebhookStatus }, optional: false, nullable: false
|
|
14
|
+
field :updated_at, -> { String }, optional: false, nullable: false
|
|
15
|
+
field :url, -> { String }, optional: false, nullable: false
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Schematic
|
|
4
|
+
module Types
|
|
5
|
+
class WhoAmIResponseData < Internal::Types::Model
|
|
6
|
+
field :account_id, -> { String }, optional: false, nullable: false
|
|
7
|
+
field :account_name, -> { String }, optional: false, nullable: false
|
|
8
|
+
field :actor_type, -> { Schematic::Types::ActorType }, optional: false, nullable: false
|
|
9
|
+
field :api_key_id, -> { String }, optional: true, nullable: false
|
|
10
|
+
field :environment_id, -> { String }, optional: true, nullable: false
|
|
11
|
+
field :environments, -> { Internal::Types::Array[Schematic::Types::EnvironmentResponseData] }, optional: false, nullable: false
|
|
12
|
+
field :stripe_user_id, -> { String }, optional: true, nullable: false
|
|
13
|
+
field :user_id, -> { String }, optional: true, nullable: false
|
|
14
|
+
field :user_name, -> { String }, optional: true, nullable: false
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
Binary file
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "openssl"
|
|
4
|
+
|
|
5
|
+
module Schematic
|
|
6
|
+
module Webhooks
|
|
7
|
+
SIGNATURE_HEADER = "X-Schematic-Webhook-Signature"
|
|
8
|
+
TIMESTAMP_HEADER = "X-Schematic-Webhook-Timestamp"
|
|
9
|
+
|
|
10
|
+
class WebhookSignatureError < StandardError; end
|
|
11
|
+
class MissingSignatureError < WebhookSignatureError; end
|
|
12
|
+
class MissingTimestampError < WebhookSignatureError; end
|
|
13
|
+
class InvalidSignatureError < WebhookSignatureError; end
|
|
14
|
+
|
|
15
|
+
module_function
|
|
16
|
+
|
|
17
|
+
def compute_signature(body, timestamp, secret)
|
|
18
|
+
body_str = body.is_a?(String) ? body : body.to_s
|
|
19
|
+
message = "#{body_str}+#{timestamp}"
|
|
20
|
+
OpenSSL::HMAC.digest("SHA256", secret, message)
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
def compute_hex_signature(body, timestamp, secret)
|
|
24
|
+
compute_signature(body, timestamp, secret).unpack1("H*")
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
def verify_signature(payload, signature, timestamp, secret) # rubocop:disable Naming/PredicateMethod
|
|
28
|
+
raise MissingSignatureError, "missing webhook signature" if signature.nil? || signature.empty?
|
|
29
|
+
raise MissingTimestampError, "missing webhook timestamp" if timestamp.nil? || timestamp.empty?
|
|
30
|
+
|
|
31
|
+
expected_sig = compute_signature(payload, timestamp, secret)
|
|
32
|
+
provided_sig = [signature].pack("H*")
|
|
33
|
+
|
|
34
|
+
raise InvalidSignatureError, "invalid webhook signature" unless secure_compare(expected_sig, provided_sig)
|
|
35
|
+
|
|
36
|
+
true
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
def verify_webhook_request(request, secret)
|
|
40
|
+
signature = extract_header(request, SIGNATURE_HEADER)
|
|
41
|
+
timestamp = extract_header(request, TIMESTAMP_HEADER)
|
|
42
|
+
body = extract_body(request)
|
|
43
|
+
|
|
44
|
+
verify_signature(body, signature, timestamp, secret)
|
|
45
|
+
end
|
|
46
|
+
|
|
47
|
+
def secure_compare(expected, actual)
|
|
48
|
+
return false unless expected.bytesize == actual.bytesize
|
|
49
|
+
|
|
50
|
+
OpenSSL.fixed_length_secure_compare(expected, actual)
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
def extract_header(request, header_name)
|
|
54
|
+
if request.respond_to?(:get_header)
|
|
55
|
+
# Rack-style request
|
|
56
|
+
request.get_header("HTTP_#{header_name.upcase.tr("-", "_")}") ||
|
|
57
|
+
request.get_header(header_name)
|
|
58
|
+
elsif request.respond_to?(:[])
|
|
59
|
+
# Hash-like headers
|
|
60
|
+
request[header_name] ||
|
|
61
|
+
request[header_name.downcase] ||
|
|
62
|
+
request[header_name.upcase.tr("-", "_")]
|
|
63
|
+
end
|
|
64
|
+
end
|
|
65
|
+
|
|
66
|
+
def extract_body(request)
|
|
67
|
+
if request.respond_to?(:raw_post)
|
|
68
|
+
request.raw_post
|
|
69
|
+
elsif request.respond_to?(:body)
|
|
70
|
+
body = request.body
|
|
71
|
+
if body.respond_to?(:read)
|
|
72
|
+
content = body.read
|
|
73
|
+
body.rewind if body.respond_to?(:rewind)
|
|
74
|
+
content
|
|
75
|
+
else
|
|
76
|
+
body.to_s
|
|
77
|
+
end
|
|
78
|
+
else
|
|
79
|
+
request.to_s
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
end
|
|
83
|
+
end
|