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
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: 4a37f9b78f97beda5bfbe730f7f2379af6ebc839d78effba80bb721937c4c543
|
|
4
|
+
data.tar.gz: 5023b82060064243de4b6e1819d4f8b3d7c28d5a04c120d76d1625208ce2767b
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: f794285eeef51f342e46facd95319bb2a9dac39d862f062889076f11bab49fa2dc10626363135e12058c2380db85ab6bf3b6b60a77c6387961596d7e59f1f580
|
|
7
|
+
data.tar.gz: a2f5fe984d629ac16dc9886c7419bb65790707f263936e0674d506dda69b57df1bae5c472a9e2823dfd5dd0a6c8e850beff8d3e529ca93d91063a7c36adc7910
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: pr-review
|
|
3
|
+
description: Review code changes on the current branch for quality, bugs, performance, and security
|
|
4
|
+
disable-model-invocation: true
|
|
5
|
+
argument-hint: "[optional: LINEAR-TICKET-ID]"
|
|
6
|
+
allowed-tools: Read, Grep, Glob, Bash(git diff:*), Bash(git log:*), Bash(git show:*), Bash(git branch:*), Bash(gh pr:*), Bash(gh api:*), Bash(~/.claude/scripts/fetch-github-pr.sh:*), Bash(~/.claude/scripts/fetch-sentry-data.sh:*), Bash(~/.claude/scripts/fetch-slack-thread.sh:*)
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
# Code Review
|
|
10
|
+
|
|
11
|
+
You are reviewing code changes on the current branch. Your review must be based on the **current state of the code right now**, not on anything you've seen earlier in this conversation.
|
|
12
|
+
|
|
13
|
+
## CRITICAL: Always Use Fresh Data
|
|
14
|
+
|
|
15
|
+
**IGNORE any file contents, diffs, or line numbers you may have seen earlier in this conversation.** They may be stale. You MUST re-fetch everything from scratch using the commands below.
|
|
16
|
+
|
|
17
|
+
## Step 1: Get the Current Diff and PR Context
|
|
18
|
+
|
|
19
|
+
Run ALL of these commands to get a fresh view:
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
# The authoritative diff -- only review what's in HERE
|
|
23
|
+
git diff main...HEAD
|
|
24
|
+
|
|
25
|
+
# Recent commits on this branch
|
|
26
|
+
git log --oneline main..HEAD
|
|
27
|
+
|
|
28
|
+
# PR description and comments
|
|
29
|
+
gh pr view --json number,title,body,comments,reviews,reviewRequests
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
Also fetch PR review comments (inline code comments):
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
# Get the PR number
|
|
36
|
+
PR_NUMBER=$(gh pr view --json number -q '.number')
|
|
37
|
+
|
|
38
|
+
# Fetch all review comments (inline comments on specific lines)
|
|
39
|
+
gh api repos/{owner}/{repo}/pulls/$PR_NUMBER/comments --jq '.[] | {path: .path, line: .line, body: .body, user: .user.login, created_at: .created_at}'
|
|
40
|
+
|
|
41
|
+
# Fetch review-level comments (general review comments)
|
|
42
|
+
gh api repos/{owner}/{repo}/pulls/$PR_NUMBER/reviews --jq '.[] | {state: .state, body: .body, user: .user.login}'
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
## Step 2: Understand Context from PR Comments
|
|
46
|
+
|
|
47
|
+
Before reviewing, read through the PR comments and review comments. Note **who** said what (by username).
|
|
48
|
+
|
|
49
|
+
- **Already-addressed feedback**: If a reviewer pointed out an issue and the author has already fixed it (the fix is visible in the current diff), do NOT re-raise it.
|
|
50
|
+
- **Ongoing discussions**: Note any unresolved threads -- your review should take these into account.
|
|
51
|
+
- **Previous approvals/requests for changes**: Understand what reviewers have already looked at.
|
|
52
|
+
|
|
53
|
+
**IMPORTANT**: Your review is YOUR independent review. Do not take credit for or reference other reviewers' findings as if they were yours. If another reviewer already flagged something, you can note "as [reviewer] pointed out" but do not present their feedback as your own prior review. Your verdict should be based solely on your own analysis of the current code.
|
|
54
|
+
|
|
55
|
+
## Step 3: Get Requirements Context
|
|
56
|
+
|
|
57
|
+
Check if a Linear ticket ID was provided as an argument ($ARGUMENTS). If not, try to extract it from the branch name (pattern: `{username}/{linear-ticket}-{title}`).
|
|
58
|
+
|
|
59
|
+
If a Linear ticket is found:
|
|
60
|
+
- Use Linear MCP tools (`get_issue`) to get the issue details and comments
|
|
61
|
+
- **Check for a parent ticket**: If the issue has a parent issue, fetch the parent too. Our pattern is to have a parent ticket with project-wide requirements and sub-tickets for specific tasks (often one per repo/PR). The parent ticket will contain the full scope of the project, while the sub-ticket scopes what this specific PR should cover. Use both to assess completeness — the PR should fulfill the sub-ticket's scope, and that scope should be a reasonable subset of the parent's backend-related requirements.
|
|
62
|
+
- Look for Sentry links in the description/comments; if found, use Sentry MCP tools to get error details
|
|
63
|
+
- Assess whether the changes fulfill the ticket requirements
|
|
64
|
+
|
|
65
|
+
If no ticket is found, check the PR description for context on what the changes are meant to accomplish.
|
|
66
|
+
|
|
67
|
+
## Step 4: Review the Code
|
|
68
|
+
|
|
69
|
+
Review ONLY the changed lines (from `git diff main...HEAD`). Do not comment on unchanged code.
|
|
70
|
+
|
|
71
|
+
**When referencing code, always use the file path and quote the actual code snippet** rather than citing line numbers, since line numbers shift as the branch evolves.
|
|
72
|
+
|
|
73
|
+
### Code Quality
|
|
74
|
+
- Is the code well-structured and maintainable?
|
|
75
|
+
- Does it follow CLAUDE.md conventions? (import grouping, error handling with lib/errors, naming, alphabetization, etc.)
|
|
76
|
+
- Any AI-generated slop? (excessive comments, unnecessary abstractions, over-engineering)
|
|
77
|
+
|
|
78
|
+
### Performance
|
|
79
|
+
- N+1 queries, inefficient loops, missing indexes for new queries
|
|
80
|
+
- Unbuffered writes in hot paths (especially ClickHouse)
|
|
81
|
+
- Missing LIMIT clauses on potentially large result sets
|
|
82
|
+
|
|
83
|
+
### Bugs
|
|
84
|
+
- Nil pointer risks (especially on struct pointer params and optional relations)
|
|
85
|
+
- Functions returning `nil, nil` (violates convention)
|
|
86
|
+
- Missing error handling
|
|
87
|
+
- Race conditions in concurrent code paths
|
|
88
|
+
|
|
89
|
+
### Security
|
|
90
|
+
- Hardcoded secrets or sensitive data exposure
|
|
91
|
+
- Missing input validation on service request structs
|
|
92
|
+
|
|
93
|
+
### Tests
|
|
94
|
+
- Are there tests for the new/changed code?
|
|
95
|
+
- Do the tests cover edge cases and error paths?
|
|
96
|
+
- Are test assertions specific (not just "no error")?
|
|
97
|
+
|
|
98
|
+
## Step 5: Present the Review
|
|
99
|
+
|
|
100
|
+
Structure your review as:
|
|
101
|
+
|
|
102
|
+
```
|
|
103
|
+
## Summary
|
|
104
|
+
[1-2 sentences: what this PR does and overall assessment]
|
|
105
|
+
|
|
106
|
+
## Requirements Check
|
|
107
|
+
[Does the PR fulfill the Linear ticket / PR description requirements? Any gaps?]
|
|
108
|
+
|
|
109
|
+
## Issues
|
|
110
|
+
### Critical (must fix before merge)
|
|
111
|
+
- [blocking issues]
|
|
112
|
+
|
|
113
|
+
### Suggestions (nice to have)
|
|
114
|
+
- [non-blocking improvements]
|
|
115
|
+
|
|
116
|
+
## Prior Review Activity
|
|
117
|
+
[Summarize what other reviewers have flagged, attributed by name. Note which of their concerns have been addressed in the current code and which remain open.]
|
|
118
|
+
|
|
119
|
+
## Verdict
|
|
120
|
+
[LGTM / Needs changes / Needs discussion -- based on YOUR analysis, not other reviewers' findings]
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
## Guidelines
|
|
124
|
+
|
|
125
|
+
- Be concise. Don't pad with praise or filler.
|
|
126
|
+
- Only raise issues that matter. Don't nitpick formatting (that's what linters are for).
|
|
127
|
+
- Quote code snippets rather than referencing line numbers.
|
|
128
|
+
- If PR comments show a discussion was already resolved, don't reopen it.
|
|
129
|
+
- If you're unsure about something, flag it as a question rather than a definitive issue.
|
data/.fern/metadata.json
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
{
|
|
2
|
+
"cliVersion": "4.43.1",
|
|
3
|
+
"generatorName": "fernapi/fern-ruby-sdk",
|
|
4
|
+
"generatorVersion": "1.1.11",
|
|
5
|
+
"generatorConfig": {
|
|
6
|
+
"module": "SchematicHQ",
|
|
7
|
+
"rubocopVariableNumberStyle": "disabled",
|
|
8
|
+
"extraDependencies": {
|
|
9
|
+
"wasmtime": ">= 19.0",
|
|
10
|
+
"websocket": ">= 1.2"
|
|
11
|
+
},
|
|
12
|
+
"extraDevDependencies": {
|
|
13
|
+
"webrick": ">= 1.0"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"originGitCommit": "42e108eda47d554722530a9d404ee80ba2da1b28",
|
|
17
|
+
"sdkVersion": "1.4.0"
|
|
18
|
+
}
|
data/.fernignore
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
.claude/
|
|
2
|
+
.github/
|
|
3
|
+
.gitignore
|
|
4
|
+
CLAUDE.md
|
|
5
|
+
LICENSE
|
|
6
|
+
README.md
|
|
7
|
+
WASM_VERSION
|
|
8
|
+
custom.gemspec.rb
|
|
9
|
+
lib/schematic/cache.rb
|
|
10
|
+
lib/schematic/datastream/
|
|
11
|
+
lib/schematic/event_buffer.rb
|
|
12
|
+
lib/schematic/logger.rb
|
|
13
|
+
lib/schematic/redis_cache.rb
|
|
14
|
+
lib/schematic/rules_engine.rb
|
|
15
|
+
lib/schematic/schematic_client.rb
|
|
16
|
+
lib/schematic/wasm/
|
|
17
|
+
lib/schematic/webhook_verification.rb
|
|
18
|
+
lib/schematichq.rb
|
|
19
|
+
scripts/
|
|
20
|
+
test/custom.test.rb
|
|
21
|
+
testapp/
|
data/.rubocop.yml
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
plugins:
|
|
2
|
+
- rubocop-minitest
|
|
3
|
+
|
|
4
|
+
AllCops:
|
|
5
|
+
TargetRubyVersion: 3.3
|
|
6
|
+
NewCops: enable
|
|
7
|
+
|
|
8
|
+
Style/StringLiterals:
|
|
9
|
+
EnforcedStyle: double_quotes
|
|
10
|
+
|
|
11
|
+
Style/StringLiteralsInInterpolation:
|
|
12
|
+
EnforcedStyle: double_quotes
|
|
13
|
+
|
|
14
|
+
Style/AccessModifierDeclarations:
|
|
15
|
+
Enabled: false
|
|
16
|
+
|
|
17
|
+
Lint/ConstantDefinitionInBlock:
|
|
18
|
+
Enabled: false
|
|
19
|
+
|
|
20
|
+
Metrics/AbcSize:
|
|
21
|
+
Enabled: false
|
|
22
|
+
|
|
23
|
+
Metrics/BlockLength:
|
|
24
|
+
Enabled: false
|
|
25
|
+
|
|
26
|
+
Metrics/ClassLength:
|
|
27
|
+
Enabled: false
|
|
28
|
+
|
|
29
|
+
Metrics/MethodLength:
|
|
30
|
+
Enabled: false
|
|
31
|
+
|
|
32
|
+
Metrics/ParameterLists:
|
|
33
|
+
Enabled: false
|
|
34
|
+
|
|
35
|
+
Metrics/PerceivedComplexity:
|
|
36
|
+
Enabled: false
|
|
37
|
+
|
|
38
|
+
Metrics/CyclomaticComplexity:
|
|
39
|
+
Enabled: false
|
|
40
|
+
|
|
41
|
+
Metrics/ModuleLength:
|
|
42
|
+
Enabled: false
|
|
43
|
+
|
|
44
|
+
Layout/LineLength:
|
|
45
|
+
Enabled: false
|
|
46
|
+
|
|
47
|
+
Naming/VariableNumber:
|
|
48
|
+
Enabled: false
|
|
49
|
+
|
|
50
|
+
Style/Documentation:
|
|
51
|
+
Enabled: false
|
|
52
|
+
|
|
53
|
+
Style/Lambda:
|
|
54
|
+
EnforcedStyle: literal
|
|
55
|
+
|
|
56
|
+
Minitest/MultipleAssertions:
|
|
57
|
+
Enabled: false
|
|
58
|
+
|
|
59
|
+
Minitest/UselessAssertion:
|
|
60
|
+
Enabled: false
|
|
61
|
+
|
|
62
|
+
# Dynamic snippets are code samples for documentation, not standalone Ruby files.
|
|
63
|
+
Style/FrozenStringLiteralComment:
|
|
64
|
+
Exclude:
|
|
65
|
+
- "dynamic-snippets/**/*"
|
|
66
|
+
|
|
67
|
+
Layout/FirstHashElementIndentation:
|
|
68
|
+
Exclude:
|
|
69
|
+
- "dynamic-snippets/**/*"
|
data/CLAUDE.md
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# Schematic Ruby SDK
|
|
2
|
+
|
|
3
|
+
## Architecture
|
|
4
|
+
|
|
5
|
+
Two-layer SDK:
|
|
6
|
+
1. **Fern-generated layer** (`lib/schematic/`) - Auto-generated API client bindings. Do NOT modify directly.
|
|
7
|
+
2. **Custom layer** (protected via `.fernignore`) - Hand-written wrapper providing higher-level functionality.
|
|
8
|
+
|
|
9
|
+
## Key Commands
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
# Run all tests (requires Ruby 3.3+)
|
|
13
|
+
/opt/homebrew/opt/ruby/bin/ruby -I lib -I test test/custom.test.rb
|
|
14
|
+
|
|
15
|
+
# Run linter
|
|
16
|
+
/opt/homebrew/opt/ruby/bin/bundle exec rubocop
|
|
17
|
+
|
|
18
|
+
# Run test app
|
|
19
|
+
ruby testapp/app.rb
|
|
20
|
+
|
|
21
|
+
# Download/update WASM binary
|
|
22
|
+
./scripts/download-wasm.sh
|
|
23
|
+
|
|
24
|
+
# Start webhook test server
|
|
25
|
+
ruby scripts/webhook_test_server.rb <webhook_secret>
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Fern Code Generation
|
|
29
|
+
|
|
30
|
+
The Fern-generated layer is configured in `schematic-fern-config/fern/generators.yml` (sibling repo). The Ruby SDK uses the `fernapi/fern-ruby-sdk` generator.
|
|
31
|
+
|
|
32
|
+
Some changes should be configured in the generator config rather than directly as custom code. The most common example of this is dependencies. Refer to the Fern Ruby SDK generator documentation: https://buildwithfern.com/learn/sdks/generators/ruby/configuration
|
|
33
|
+
|
|
34
|
+
### Custom Files
|
|
35
|
+
|
|
36
|
+
All custom files MUST be listed in `.fernignore` to survive Fern regeneration.
|
|
37
|
+
|
|
38
|
+
## WASM Rules Engine
|
|
39
|
+
|
|
40
|
+
- Binary: `lib/schematic/wasm/rulesengine.wasm` (gitignored; downloaded at build time)
|
|
41
|
+
- Runtime: `wasmtime` gem (required dependency)
|
|
42
|
+
- Version pin: `WASM_VERSION` file at repo root
|
|
43
|
+
- Download: `./scripts/download-wasm.sh` fetches from internal WASM binary registry
|
|
44
|
+
- C ABI exports: `alloc`, `dealloc`, `checkFlagCombined`, `getResultJson`, `getResultJsonLength`, `get_version_key_wasm`
|
|
45
|
+
- Input: JSON envelope `{"flag": {...}, "company": {...}, "user": {...}}`
|
data/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2023-2026 Schematic, Inc.
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|