raxe 0.4.6__py3-none-any.whl
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.
- raxe/__init__.py +101 -0
- raxe/application/__init__.py +48 -0
- raxe/application/ab_testing.py +170 -0
- raxe/application/analytics/__init__.py +30 -0
- raxe/application/analytics/achievement_service.py +444 -0
- raxe/application/analytics/repositories.py +172 -0
- raxe/application/analytics/retention_service.py +267 -0
- raxe/application/analytics/statistics_service.py +419 -0
- raxe/application/analytics/streak_service.py +283 -0
- raxe/application/apply_policy.py +291 -0
- raxe/application/eager_l2.py +503 -0
- raxe/application/preloader.py +353 -0
- raxe/application/scan_merger.py +321 -0
- raxe/application/scan_pipeline.py +1059 -0
- raxe/application/scan_pipeline_async.py +403 -0
- raxe/application/session_tracker.py +458 -0
- raxe/application/telemetry_manager.py +357 -0
- raxe/application/telemetry_orchestrator.py +1210 -0
- raxe/async_sdk/__init__.py +34 -0
- raxe/async_sdk/cache.py +286 -0
- raxe/async_sdk/client.py +556 -0
- raxe/async_sdk/wrappers/__init__.py +23 -0
- raxe/async_sdk/wrappers/openai.py +238 -0
- raxe/cli/__init__.py +21 -0
- raxe/cli/auth.py +1047 -0
- raxe/cli/branding.py +235 -0
- raxe/cli/config.py +334 -0
- raxe/cli/custom_rules.py +458 -0
- raxe/cli/doctor.py +686 -0
- raxe/cli/error_handler.py +665 -0
- raxe/cli/event.py +648 -0
- raxe/cli/exit_codes.py +57 -0
- raxe/cli/expiry_warning.py +302 -0
- raxe/cli/export.py +183 -0
- raxe/cli/history.py +247 -0
- raxe/cli/l2_formatter.py +872 -0
- raxe/cli/main.py +1137 -0
- raxe/cli/models.py +590 -0
- raxe/cli/output.py +403 -0
- raxe/cli/privacy.py +84 -0
- raxe/cli/profiler.py +262 -0
- raxe/cli/progress.py +379 -0
- raxe/cli/progress_context.py +101 -0
- raxe/cli/repl.py +394 -0
- raxe/cli/rules.py +542 -0
- raxe/cli/setup_wizard.py +721 -0
- raxe/cli/stats.py +292 -0
- raxe/cli/suppress.py +501 -0
- raxe/cli/telemetry.py +1384 -0
- raxe/cli/test.py +130 -0
- raxe/cli/tune.py +315 -0
- raxe/cli/validate.py +218 -0
- raxe/domain/__init__.py +30 -0
- raxe/domain/analytics/__init__.py +97 -0
- raxe/domain/analytics/achievements.py +306 -0
- raxe/domain/analytics/models.py +120 -0
- raxe/domain/analytics/retention.py +168 -0
- raxe/domain/analytics/statistics.py +207 -0
- raxe/domain/analytics/streaks.py +173 -0
- raxe/domain/engine/__init__.py +15 -0
- raxe/domain/engine/executor.py +396 -0
- raxe/domain/engine/matcher.py +212 -0
- raxe/domain/inline_suppression.py +176 -0
- raxe/domain/ml/__init__.py +133 -0
- raxe/domain/ml/embedding_cache.py +309 -0
- raxe/domain/ml/gemma_detector.py +921 -0
- raxe/domain/ml/gemma_models.py +346 -0
- raxe/domain/ml/l2_config.py +428 -0
- raxe/domain/ml/l2_output_schema.py +443 -0
- raxe/domain/ml/manifest_loader.py +309 -0
- raxe/domain/ml/manifest_schema.py +345 -0
- raxe/domain/ml/model_metadata.py +263 -0
- raxe/domain/ml/model_registry.py +786 -0
- raxe/domain/ml/protocol.py +282 -0
- raxe/domain/ml/scoring_models.py +419 -0
- raxe/domain/ml/stub_detector.py +397 -0
- raxe/domain/ml/threat_scorer.py +757 -0
- raxe/domain/ml/tokenizer_registry.py +372 -0
- raxe/domain/ml/voting/__init__.py +89 -0
- raxe/domain/ml/voting/config.py +595 -0
- raxe/domain/ml/voting/engine.py +465 -0
- raxe/domain/ml/voting/head_voters.py +378 -0
- raxe/domain/ml/voting/models.py +222 -0
- raxe/domain/models.py +82 -0
- raxe/domain/packs/__init__.py +17 -0
- raxe/domain/packs/models.py +304 -0
- raxe/domain/policies/__init__.py +20 -0
- raxe/domain/policies/evaluator.py +212 -0
- raxe/domain/policies/models.py +223 -0
- raxe/domain/rules/__init__.py +32 -0
- raxe/domain/rules/custom.py +286 -0
- raxe/domain/rules/models.py +273 -0
- raxe/domain/rules/schema.py +166 -0
- raxe/domain/rules/validator.py +556 -0
- raxe/domain/suppression.py +801 -0
- raxe/domain/suppression_factory.py +174 -0
- raxe/domain/telemetry/__init__.py +116 -0
- raxe/domain/telemetry/backpressure.py +424 -0
- raxe/domain/telemetry/event_creator.py +362 -0
- raxe/domain/telemetry/events.py +1282 -0
- raxe/domain/telemetry/priority.py +263 -0
- raxe/domain/telemetry/scan_telemetry_builder.py +670 -0
- raxe/infrastructure/__init__.py +25 -0
- raxe/infrastructure/analytics/__init__.py +18 -0
- raxe/infrastructure/analytics/aggregator.py +484 -0
- raxe/infrastructure/analytics/aggregator_optimized.py +184 -0
- raxe/infrastructure/analytics/engine.py +748 -0
- raxe/infrastructure/analytics/repository.py +409 -0
- raxe/infrastructure/analytics/streaks.py +467 -0
- raxe/infrastructure/analytics/views.py +178 -0
- raxe/infrastructure/cloud/__init__.py +9 -0
- raxe/infrastructure/config/__init__.py +56 -0
- raxe/infrastructure/config/endpoints.py +641 -0
- raxe/infrastructure/config/scan_config.py +352 -0
- raxe/infrastructure/config/yaml_config.py +459 -0
- raxe/infrastructure/database/__init__.py +10 -0
- raxe/infrastructure/database/connection.py +200 -0
- raxe/infrastructure/database/models.py +325 -0
- raxe/infrastructure/database/scan_history.py +764 -0
- raxe/infrastructure/ml/__init__.py +0 -0
- raxe/infrastructure/ml/download_progress.py +438 -0
- raxe/infrastructure/ml/model_downloader.py +457 -0
- raxe/infrastructure/models/__init__.py +16 -0
- raxe/infrastructure/models/discovery.py +461 -0
- raxe/infrastructure/packs/__init__.py +13 -0
- raxe/infrastructure/packs/loader.py +407 -0
- raxe/infrastructure/packs/registry.py +381 -0
- raxe/infrastructure/policies/__init__.py +16 -0
- raxe/infrastructure/policies/api_client.py +256 -0
- raxe/infrastructure/policies/validator.py +227 -0
- raxe/infrastructure/policies/yaml_loader.py +250 -0
- raxe/infrastructure/rules/__init__.py +18 -0
- raxe/infrastructure/rules/custom_loader.py +224 -0
- raxe/infrastructure/rules/versioning.py +222 -0
- raxe/infrastructure/rules/yaml_loader.py +286 -0
- raxe/infrastructure/security/__init__.py +31 -0
- raxe/infrastructure/security/auth.py +145 -0
- raxe/infrastructure/security/policy_validator.py +124 -0
- raxe/infrastructure/security/signatures.py +171 -0
- raxe/infrastructure/suppression/__init__.py +36 -0
- raxe/infrastructure/suppression/composite_repository.py +154 -0
- raxe/infrastructure/suppression/sqlite_repository.py +231 -0
- raxe/infrastructure/suppression/yaml_composite_repository.py +156 -0
- raxe/infrastructure/suppression/yaml_repository.py +510 -0
- raxe/infrastructure/telemetry/__init__.py +79 -0
- raxe/infrastructure/telemetry/acquisition.py +179 -0
- raxe/infrastructure/telemetry/config.py +254 -0
- raxe/infrastructure/telemetry/credential_store.py +947 -0
- raxe/infrastructure/telemetry/dual_queue.py +1123 -0
- raxe/infrastructure/telemetry/flush_helper.py +343 -0
- raxe/infrastructure/telemetry/flush_scheduler.py +776 -0
- raxe/infrastructure/telemetry/health_client.py +394 -0
- raxe/infrastructure/telemetry/hook.py +347 -0
- raxe/infrastructure/telemetry/queue.py +520 -0
- raxe/infrastructure/telemetry/sender.py +476 -0
- raxe/infrastructure/tracking/__init__.py +13 -0
- raxe/infrastructure/tracking/usage.py +389 -0
- raxe/integrations/__init__.py +55 -0
- raxe/integrations/availability.py +143 -0
- raxe/integrations/registry.py +122 -0
- raxe/integrations/utils.py +135 -0
- raxe/mcp/__init__.py +62 -0
- raxe/mcp/cli.py +97 -0
- raxe/mcp/server.py +409 -0
- raxe/monitoring/__init__.py +51 -0
- raxe/monitoring/metrics.py +372 -0
- raxe/monitoring/profiler.py +388 -0
- raxe/monitoring/server.py +136 -0
- raxe/packs/core/v1.0.0/pack.yaml +1394 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-001@1.0.0.yaml +49 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-006@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-014@1.0.0.yaml +54 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-017@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-022@1.0.0.yaml +67 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-023@1.0.0.yaml +91 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-024@1.0.0.yaml +80 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-025@1.0.0.yaml +81 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-026@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-027@1.0.0.yaml +77 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-028@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-029@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-030@1.0.0.yaml +55 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-033@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-034@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-035@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-046@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-047@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-048@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-049@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-050@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-068@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-078@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-2001@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-2004@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-201@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-202@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-203@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3007@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3016@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3026@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3027@1.0.0.yaml +64 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3028@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3029@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3030@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3031@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3032@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3033@1.0.0.yaml +56 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-3034@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-79@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-80@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-81@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-82@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-83@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-84@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-85@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-86@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-87@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-88@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-89@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-90@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-91@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-92@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-93@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-94@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-95@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-96@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-97@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/PI/pi-98@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-001@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-007@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-015@1.0.0.yaml +56 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-016@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-017@1.0.0.yaml +57 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-021@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-022@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-023@1.0.0.yaml +78 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-024@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-025@1.0.0.yaml +93 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-026@1.0.0.yaml +81 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-027@1.0.0.yaml +82 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-028@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-033@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-036@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-037@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-052@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-054@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-056@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-065@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-075@1.0.0.yaml +45 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-079@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-1080@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-1090@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-1104@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-1105@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-1112@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-201@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-202@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-203@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-204@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-205@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-206@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-207@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-208@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-209@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-210@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-211@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-212@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-213@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-214@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-215@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-216@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-217@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-218@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-219@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-220@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-221@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-222@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-223@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-224@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-225@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-226@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-227@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-228@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-229@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-230@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-231@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-232@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-233@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-234@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-235@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-236@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-237@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/cmd/cmd-238@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-001@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-013@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-019@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-020@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-024@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-029@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-038@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-044@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-067@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-069@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-100@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-101@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-102@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-103@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-104@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-105@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-106@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-107@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-108@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-109@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-110@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-111@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-112@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-113@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-114@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-115@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-116@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-117@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-118@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-119@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-120@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-201@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-202@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-203@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-3004@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-3006@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-3011@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-5016@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-6001@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-6002@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-70@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-71@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-72@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-73@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-74@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-75@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-76@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-77@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-78@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-79@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-80@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-81@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-82@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-83@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-84@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-85@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-86@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-87@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-88@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-89@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-90@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-91@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-92@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-93@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-94@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-95@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-96@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-97@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-98@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/enc/enc-99@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-001@1.0.0.yaml +73 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-002@1.0.0.yaml +71 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-003@1.0.0.yaml +65 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-004@1.0.0.yaml +73 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-101@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-102@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-103@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-104@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-105@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-106@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-107@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-108@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-109@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-110@1.0.0.yaml +56 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-111@1.0.0.yaml +49 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-112@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-113@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-114@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-115@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-116@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-117@1.0.0.yaml +54 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-118@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-119@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-120@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-121@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-122@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-123@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-124@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-125@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-126@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-127@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-128@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-129@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-130@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-131@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-132@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-133@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-134@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-135@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-136@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-137@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-138@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-139@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-140@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-141@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-142@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-143@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-144@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-145@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-146@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-147@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-148@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-149@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-150@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-151@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-152@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-153@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-154@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-155@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-156@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-157@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-158@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-159@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-160@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/hc/hc-161@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-001@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-009@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-020@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-021@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-022@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-028@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-033@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-034@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-036@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-039@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-056@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-066@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-076@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-098@1.0.0.yaml +46 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-103@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-104@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-105@1.0.0.yaml +56 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-110@1.0.0.yaml +56 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-111@1.0.0.yaml +57 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-112@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-113@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-114@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-115@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-116@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-117@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-118@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-119@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-120@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-121@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-122@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-123@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-124@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-125@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-126@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-127@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-128@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-129@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-130@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-131@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-132@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-133@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-134@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-135@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-136@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-137@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-138@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-139@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-140@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-141@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-142@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-143@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-144@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-145@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-146@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-147@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-148@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-149@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-150@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-151@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-152@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-153@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-154@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-155@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-156@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-157@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-158@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-159@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-160@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-161@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-162@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-201@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-202@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-203@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-204@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-205@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-206@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/jb/jb-207@1.0.0.yaml +49 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-001@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-009@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-012@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-017@1.0.0.yaml +48 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-022@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-025@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-027@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-028@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-034@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-037@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-040@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-041@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-044@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-050@1.0.0.yaml +57 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-051@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-052@1.0.0.yaml +52 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-053@1.0.0.yaml +56 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-054@1.0.0.yaml +53 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-055@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-056@1.0.0.yaml +51 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-058@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-2015@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-2025@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-2026@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-2035@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-2037@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-2042@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3001@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3002@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3003@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3004@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3005@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3006@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3007@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3008@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3009@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3010@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3011@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3012@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3013@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3014@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3015@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3016@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3017@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3018@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3019@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3020@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3021@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3022@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3023@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3024@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3025@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3026@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3027@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3028@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3029@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3030@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3031@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3032@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3033@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3034@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3035@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3036@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3037@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3038@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3039@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3040@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3041@1.0.0.yaml +39 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3042@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3043@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3044@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3045@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3046@1.0.0.yaml +37 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3047@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3048@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3049@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3050@1.0.0.yaml +44 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3051@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3052@1.0.0.yaml +36 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3053@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3054@1.0.0.yaml +35 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3055@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3056@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3057@1.0.0.yaml +40 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3058@1.0.0.yaml +43 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3059@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3060@1.0.0.yaml +42 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3061@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3062@1.0.0.yaml +50 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3063@1.0.0.yaml +54 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3064@1.0.0.yaml +78 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3065@1.0.0.yaml +84 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3066@1.0.0.yaml +84 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3067@1.0.0.yaml +88 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3068@1.0.0.yaml +94 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3069@1.0.0.yaml +90 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3070@1.0.0.yaml +99 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3071@1.0.0.yaml +91 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3072@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3073@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3074@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3075@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3076@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3077@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3078@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3079@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3080@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3081@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3082@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3083@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3084@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/pii/pii-3085@1.0.0.yaml +38 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-016@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-028@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-042@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-044@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-045@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-050@1.0.0.yaml +47 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-201@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-202@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-3001@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-3006@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-3009@1.0.0.yaml +41 -0
- raxe/packs/core/v1.0.0/rules/rag/rag-3012@1.0.0.yaml +41 -0
- raxe/plugins/__init__.py +98 -0
- raxe/plugins/custom_rules.py +380 -0
- raxe/plugins/loader.py +389 -0
- raxe/plugins/manager.py +538 -0
- raxe/plugins/protocol.py +428 -0
- raxe/py.typed +0 -0
- raxe/sdk/__init__.py +77 -0
- raxe/sdk/agent_scanner.py +1918 -0
- raxe/sdk/client.py +1603 -0
- raxe/sdk/decorator.py +175 -0
- raxe/sdk/exceptions.py +859 -0
- raxe/sdk/integrations/__init__.py +277 -0
- raxe/sdk/integrations/agent_scanner.py +71 -0
- raxe/sdk/integrations/autogen.py +872 -0
- raxe/sdk/integrations/crewai.py +1368 -0
- raxe/sdk/integrations/dspy.py +845 -0
- raxe/sdk/integrations/extractors.py +363 -0
- raxe/sdk/integrations/huggingface.py +395 -0
- raxe/sdk/integrations/langchain.py +948 -0
- raxe/sdk/integrations/litellm.py +484 -0
- raxe/sdk/integrations/llamaindex.py +1049 -0
- raxe/sdk/integrations/portkey.py +831 -0
- raxe/sdk/suppression_context.py +215 -0
- raxe/sdk/wrappers/__init__.py +163 -0
- raxe/sdk/wrappers/anthropic.py +310 -0
- raxe/sdk/wrappers/openai.py +221 -0
- raxe/sdk/wrappers/vertexai.py +484 -0
- raxe/utils/__init__.py +12 -0
- raxe/utils/error_sanitizer.py +135 -0
- raxe/utils/logging.py +241 -0
- raxe/utils/performance.py +414 -0
- raxe/utils/profiler.py +339 -0
- raxe/utils/validators.py +170 -0
- raxe-0.4.6.dist-info/METADATA +471 -0
- raxe-0.4.6.dist-info/RECORD +668 -0
- raxe-0.4.6.dist-info/WHEEL +5 -0
- raxe-0.4.6.dist-info/entry_points.txt +2 -0
- raxe-0.4.6.dist-info/licenses/LICENSE +56 -0
- raxe-0.4.6.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,641 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Centralized endpoint configuration for RAXE CLI.
|
|
3
|
+
|
|
4
|
+
This module provides a single source of truth for all API endpoints used by the CLI.
|
|
5
|
+
It supports multiple environments (dev, staging, prod) and provides easy override
|
|
6
|
+
mechanisms for developers and enterprise deployments.
|
|
7
|
+
|
|
8
|
+
Configuration Priority (highest to lowest):
|
|
9
|
+
1. Explicit override via set_endpoint() at runtime
|
|
10
|
+
2. Environment variables (RAXE_API_BASE, RAXE_TELEMETRY_ENDPOINT, etc.)
|
|
11
|
+
3. Config file (~/.raxe/config.yaml or ~/.raxe/endpoints.yaml)
|
|
12
|
+
4. Environment detection (based on existing API key prefix)
|
|
13
|
+
5. Default values (production endpoints)
|
|
14
|
+
|
|
15
|
+
Usage:
|
|
16
|
+
from raxe.infrastructure.config.endpoints import get_endpoint, Endpoint, Environment
|
|
17
|
+
|
|
18
|
+
# Get telemetry endpoint for current environment
|
|
19
|
+
url = get_endpoint(Endpoint.TELEMETRY)
|
|
20
|
+
|
|
21
|
+
# Get endpoint for specific environment
|
|
22
|
+
url = get_endpoint(Endpoint.TELEMETRY, environment=Environment.DEVELOPMENT)
|
|
23
|
+
|
|
24
|
+
# Override endpoint at runtime
|
|
25
|
+
set_endpoint(Endpoint.TELEMETRY, "https://custom.api.example.com/v1/telemetry")
|
|
26
|
+
|
|
27
|
+
# Test connectivity
|
|
28
|
+
status = test_endpoint(Endpoint.TELEMETRY)
|
|
29
|
+
"""
|
|
30
|
+
|
|
31
|
+
import logging
|
|
32
|
+
import os
|
|
33
|
+
import socket
|
|
34
|
+
from dataclasses import dataclass
|
|
35
|
+
from enum import Enum
|
|
36
|
+
from pathlib import Path
|
|
37
|
+
from typing import Any
|
|
38
|
+
from urllib.parse import urlparse
|
|
39
|
+
|
|
40
|
+
logger = logging.getLogger(__name__)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
class Environment(Enum):
|
|
44
|
+
"""RAXE deployment environments."""
|
|
45
|
+
PRODUCTION = "production"
|
|
46
|
+
STAGING = "staging"
|
|
47
|
+
DEVELOPMENT = "development"
|
|
48
|
+
TEST = "test" # For unit testing (local mocks)
|
|
49
|
+
LOCAL = "local" # For local development server
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
class Endpoint(Enum):
|
|
53
|
+
"""Available API endpoints."""
|
|
54
|
+
API_BASE = "api_base"
|
|
55
|
+
TELEMETRY = "telemetry"
|
|
56
|
+
HEALTH = "health"
|
|
57
|
+
POLICIES = "policies"
|
|
58
|
+
CONSOLE = "console"
|
|
59
|
+
CLI_SESSION = "cli_session"
|
|
60
|
+
CLI_LINK = "cli_link"
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
# ============================================================================
|
|
64
|
+
# Environment-Specific Endpoint Defaults
|
|
65
|
+
# ============================================================================
|
|
66
|
+
|
|
67
|
+
_ENDPOINT_DEFAULTS: dict[Environment, dict[Endpoint, str]] = {
|
|
68
|
+
Environment.PRODUCTION: {
|
|
69
|
+
Endpoint.API_BASE: "https://api.beta.raxe.ai",
|
|
70
|
+
Endpoint.TELEMETRY: "https://api.beta.raxe.ai/v1/telemetry",
|
|
71
|
+
Endpoint.HEALTH: "https://api.beta.raxe.ai/v1/health",
|
|
72
|
+
Endpoint.POLICIES: "https://api.beta.raxe.ai/v1/policies",
|
|
73
|
+
Endpoint.CONSOLE: "https://console.beta.raxe.ai",
|
|
74
|
+
Endpoint.CLI_SESSION: "https://console.beta.raxe.ai/api/cli/session",
|
|
75
|
+
Endpoint.CLI_LINK: "https://console.beta.raxe.ai/api/cli/link",
|
|
76
|
+
},
|
|
77
|
+
Environment.DEVELOPMENT: {
|
|
78
|
+
Endpoint.API_BASE: "https://api.beta.raxe.ai",
|
|
79
|
+
Endpoint.TELEMETRY: "https://api.beta.raxe.ai/v1/telemetry",
|
|
80
|
+
Endpoint.HEALTH: "https://api.beta.raxe.ai/v1/health",
|
|
81
|
+
Endpoint.POLICIES: "https://api.beta.raxe.ai/v1/policies",
|
|
82
|
+
Endpoint.CONSOLE: "http://localhost:3000",
|
|
83
|
+
Endpoint.CLI_SESSION: "http://localhost:3000/api/cli/session",
|
|
84
|
+
Endpoint.CLI_LINK: "http://localhost:3000/api/cli/link",
|
|
85
|
+
},
|
|
86
|
+
Environment.LOCAL: {
|
|
87
|
+
Endpoint.API_BASE: "http://localhost:8080",
|
|
88
|
+
Endpoint.TELEMETRY: "http://localhost:8080/v1/telemetry",
|
|
89
|
+
Endpoint.HEALTH: "http://localhost:8080/v1/health",
|
|
90
|
+
Endpoint.POLICIES: "http://localhost:8080/v1/policies",
|
|
91
|
+
Endpoint.CONSOLE: "http://localhost:3000",
|
|
92
|
+
Endpoint.CLI_SESSION: "http://localhost:3000/api/cli/session",
|
|
93
|
+
Endpoint.CLI_LINK: "http://localhost:3000/api/cli/link",
|
|
94
|
+
},
|
|
95
|
+
Environment.TEST: {
|
|
96
|
+
Endpoint.API_BASE: "http://localhost:8080",
|
|
97
|
+
Endpoint.TELEMETRY: "http://localhost:8080/v1/telemetry",
|
|
98
|
+
Endpoint.HEALTH: "http://localhost:8080/v1/health",
|
|
99
|
+
Endpoint.POLICIES: "http://localhost:8080/v1/policies",
|
|
100
|
+
Endpoint.CONSOLE: "http://localhost:3000",
|
|
101
|
+
Endpoint.CLI_SESSION: "http://localhost:3000/api/cli/session",
|
|
102
|
+
Endpoint.CLI_LINK: "http://localhost:3000/api/cli/link",
|
|
103
|
+
},
|
|
104
|
+
Environment.STAGING: {
|
|
105
|
+
Endpoint.API_BASE: "https://api.beta.raxe.ai",
|
|
106
|
+
Endpoint.TELEMETRY: "https://api.beta.raxe.ai/v1/telemetry",
|
|
107
|
+
Endpoint.HEALTH: "https://api.beta.raxe.ai/v1/health",
|
|
108
|
+
Endpoint.POLICIES: "https://api.beta.raxe.ai/v1/policies",
|
|
109
|
+
Endpoint.CONSOLE: "https://console.beta.raxe.ai",
|
|
110
|
+
Endpoint.CLI_SESSION: "https://console.beta.raxe.ai/api/cli/session",
|
|
111
|
+
Endpoint.CLI_LINK: "https://console.beta.raxe.ai/api/cli/link",
|
|
112
|
+
},
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
# Environment variable names for endpoint overrides
|
|
116
|
+
_ENV_VAR_MAPPING: dict[Endpoint, str] = {
|
|
117
|
+
Endpoint.API_BASE: "RAXE_API_BASE",
|
|
118
|
+
Endpoint.TELEMETRY: "RAXE_TELEMETRY_ENDPOINT",
|
|
119
|
+
Endpoint.HEALTH: "RAXE_HEALTH_ENDPOINT",
|
|
120
|
+
Endpoint.POLICIES: "RAXE_POLICIES_ENDPOINT",
|
|
121
|
+
Endpoint.CONSOLE: "RAXE_CONSOLE_URL",
|
|
122
|
+
Endpoint.CLI_SESSION: "RAXE_CLI_SESSION_ENDPOINT",
|
|
123
|
+
Endpoint.CLI_LINK: "RAXE_CLI_LINK_ENDPOINT",
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
# ============================================================================
|
|
128
|
+
# Runtime State
|
|
129
|
+
# ============================================================================
|
|
130
|
+
|
|
131
|
+
@dataclass
|
|
132
|
+
class _EndpointState:
|
|
133
|
+
"""Internal state for endpoint configuration."""
|
|
134
|
+
overrides: dict[Endpoint, str]
|
|
135
|
+
detected_environment: Environment | None
|
|
136
|
+
config_file_path: Path | None
|
|
137
|
+
|
|
138
|
+
def __init__(self) -> None:
|
|
139
|
+
self.overrides = {}
|
|
140
|
+
self.detected_environment = None
|
|
141
|
+
self.config_file_path = None
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
_state = _EndpointState()
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+
# ============================================================================
|
|
148
|
+
# Environment Detection
|
|
149
|
+
# ============================================================================
|
|
150
|
+
|
|
151
|
+
def detect_environment() -> Environment:
|
|
152
|
+
"""
|
|
153
|
+
Detect the current environment based on available signals.
|
|
154
|
+
|
|
155
|
+
Detection priority:
|
|
156
|
+
1. RAXE_ENV environment variable
|
|
157
|
+
2. Config file (~/.raxe/config.yaml core.environment)
|
|
158
|
+
3. API key prefix (raxe_test_ -> TEST, etc.)
|
|
159
|
+
4. Default to DEVELOPMENT
|
|
160
|
+
|
|
161
|
+
Returns:
|
|
162
|
+
Detected Environment
|
|
163
|
+
"""
|
|
164
|
+
# Check cached value
|
|
165
|
+
if _state.detected_environment is not None:
|
|
166
|
+
return _state.detected_environment
|
|
167
|
+
|
|
168
|
+
env_map = {
|
|
169
|
+
"production": Environment.PRODUCTION,
|
|
170
|
+
"prod": Environment.PRODUCTION,
|
|
171
|
+
"staging": Environment.STAGING,
|
|
172
|
+
"stage": Environment.STAGING,
|
|
173
|
+
"development": Environment.DEVELOPMENT,
|
|
174
|
+
"dev": Environment.DEVELOPMENT,
|
|
175
|
+
"test": Environment.TEST,
|
|
176
|
+
"testing": Environment.TEST,
|
|
177
|
+
"local": Environment.LOCAL,
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
# 1. Check RAXE_ENV environment variable
|
|
181
|
+
env_str = os.environ.get("RAXE_ENV", "").lower()
|
|
182
|
+
if env_str and env_str in env_map:
|
|
183
|
+
_state.detected_environment = env_map[env_str]
|
|
184
|
+
logger.debug(f"Environment detected from RAXE_ENV: {_state.detected_environment.value}")
|
|
185
|
+
return _state.detected_environment
|
|
186
|
+
|
|
187
|
+
# 2. Check config file
|
|
188
|
+
config_path = Path.home() / ".raxe" / "config.yaml"
|
|
189
|
+
if config_path.exists():
|
|
190
|
+
try:
|
|
191
|
+
import yaml
|
|
192
|
+
with open(config_path) as f:
|
|
193
|
+
config = yaml.safe_load(f) or {}
|
|
194
|
+
config_env = config.get("core", {}).get("environment", "").lower()
|
|
195
|
+
if config_env and config_env in env_map:
|
|
196
|
+
_state.detected_environment = env_map[config_env]
|
|
197
|
+
logger.debug(f"Environment detected from config file: {_state.detected_environment.value}")
|
|
198
|
+
return _state.detected_environment
|
|
199
|
+
except Exception:
|
|
200
|
+
pass
|
|
201
|
+
|
|
202
|
+
# 3. Check API key prefix
|
|
203
|
+
api_key = os.environ.get("RAXE_API_KEY", "")
|
|
204
|
+
if not api_key:
|
|
205
|
+
# Try to read from credentials file
|
|
206
|
+
creds_path = Path.home() / ".raxe" / "credentials.json"
|
|
207
|
+
if creds_path.exists():
|
|
208
|
+
try:
|
|
209
|
+
import json
|
|
210
|
+
with open(creds_path) as f:
|
|
211
|
+
creds = json.load(f)
|
|
212
|
+
api_key = creds.get("api_key", "")
|
|
213
|
+
except Exception:
|
|
214
|
+
pass
|
|
215
|
+
|
|
216
|
+
if api_key.startswith("raxe_test_"):
|
|
217
|
+
_state.detected_environment = Environment.TEST
|
|
218
|
+
elif api_key.startswith("raxe_temp_"):
|
|
219
|
+
# Temp keys (fresh installs) default to production
|
|
220
|
+
_state.detected_environment = Environment.PRODUCTION
|
|
221
|
+
elif api_key.startswith("raxe_live_"):
|
|
222
|
+
_state.detected_environment = Environment.PRODUCTION
|
|
223
|
+
else:
|
|
224
|
+
# Default to production for real users
|
|
225
|
+
_state.detected_environment = Environment.PRODUCTION
|
|
226
|
+
|
|
227
|
+
logger.debug(f"Environment detected: {_state.detected_environment.value}")
|
|
228
|
+
return _state.detected_environment
|
|
229
|
+
|
|
230
|
+
|
|
231
|
+
def set_environment(environment: Environment | None) -> None:
|
|
232
|
+
"""
|
|
233
|
+
Explicitly set the environment (in-memory only).
|
|
234
|
+
|
|
235
|
+
Args:
|
|
236
|
+
environment: The environment to use, or None to clear the override
|
|
237
|
+
"""
|
|
238
|
+
_state.detected_environment = environment
|
|
239
|
+
if environment is not None:
|
|
240
|
+
logger.info(f"Environment set to: {environment.value}")
|
|
241
|
+
else:
|
|
242
|
+
logger.info("Environment override cleared")
|
|
243
|
+
|
|
244
|
+
|
|
245
|
+
def save_environment(environment: Environment) -> None:
|
|
246
|
+
"""
|
|
247
|
+
Persist environment setting to config file (~/.raxe/config.yaml).
|
|
248
|
+
|
|
249
|
+
This ensures the environment persists across CLI invocations.
|
|
250
|
+
|
|
251
|
+
Args:
|
|
252
|
+
environment: The environment to persist
|
|
253
|
+
"""
|
|
254
|
+
import yaml
|
|
255
|
+
|
|
256
|
+
config_path = Path.home() / ".raxe" / "config.yaml"
|
|
257
|
+
|
|
258
|
+
# Load existing config or create empty
|
|
259
|
+
config: dict = {}
|
|
260
|
+
if config_path.exists():
|
|
261
|
+
try:
|
|
262
|
+
with open(config_path) as f:
|
|
263
|
+
config = yaml.safe_load(f) or {}
|
|
264
|
+
except Exception:
|
|
265
|
+
config = {}
|
|
266
|
+
|
|
267
|
+
# Update environment in core section
|
|
268
|
+
if "core" not in config:
|
|
269
|
+
config["core"] = {}
|
|
270
|
+
config["core"]["environment"] = environment.value
|
|
271
|
+
|
|
272
|
+
# Ensure directory exists
|
|
273
|
+
config_path.parent.mkdir(parents=True, exist_ok=True)
|
|
274
|
+
|
|
275
|
+
# Write back
|
|
276
|
+
with open(config_path, "w") as f:
|
|
277
|
+
yaml.dump(config, f, default_flow_style=False, sort_keys=False)
|
|
278
|
+
|
|
279
|
+
# Also update in-memory state
|
|
280
|
+
_state.detected_environment = environment
|
|
281
|
+
logger.info(f"Environment saved to config: {environment.value}")
|
|
282
|
+
|
|
283
|
+
|
|
284
|
+
def get_environment() -> Environment:
|
|
285
|
+
"""
|
|
286
|
+
Get the current environment.
|
|
287
|
+
|
|
288
|
+
Returns:
|
|
289
|
+
Current Environment
|
|
290
|
+
"""
|
|
291
|
+
return detect_environment()
|
|
292
|
+
|
|
293
|
+
|
|
294
|
+
# ============================================================================
|
|
295
|
+
# Endpoint Resolution
|
|
296
|
+
# ============================================================================
|
|
297
|
+
|
|
298
|
+
def get_endpoint(
|
|
299
|
+
endpoint: Endpoint,
|
|
300
|
+
environment: Environment | None = None,
|
|
301
|
+
use_overrides: bool = True,
|
|
302
|
+
) -> str:
|
|
303
|
+
"""
|
|
304
|
+
Get the URL for a specific endpoint.
|
|
305
|
+
|
|
306
|
+
Resolution priority:
|
|
307
|
+
1. Runtime override (if use_overrides=True and set via set_endpoint)
|
|
308
|
+
2. Environment variable
|
|
309
|
+
3. Config file
|
|
310
|
+
4. Environment-specific default
|
|
311
|
+
|
|
312
|
+
Args:
|
|
313
|
+
endpoint: The endpoint type to resolve
|
|
314
|
+
environment: Optional environment override (defaults to detected)
|
|
315
|
+
use_overrides: Whether to check runtime overrides (default True)
|
|
316
|
+
|
|
317
|
+
Returns:
|
|
318
|
+
The resolved endpoint URL
|
|
319
|
+
"""
|
|
320
|
+
# 1. Check runtime override
|
|
321
|
+
if use_overrides and endpoint in _state.overrides:
|
|
322
|
+
return _state.overrides[endpoint]
|
|
323
|
+
|
|
324
|
+
# 2. Check environment variable
|
|
325
|
+
env_var = _ENV_VAR_MAPPING.get(endpoint)
|
|
326
|
+
if env_var:
|
|
327
|
+
env_value = os.environ.get(env_var)
|
|
328
|
+
if env_value:
|
|
329
|
+
return env_value
|
|
330
|
+
|
|
331
|
+
# Special case: RAXE_CLOUD_ENDPOINT is a legacy alias for API_BASE
|
|
332
|
+
if endpoint == Endpoint.API_BASE:
|
|
333
|
+
legacy_value = os.environ.get("RAXE_CLOUD_ENDPOINT")
|
|
334
|
+
if legacy_value:
|
|
335
|
+
return legacy_value
|
|
336
|
+
|
|
337
|
+
# 3. Check config file (TODO: implement config file loading)
|
|
338
|
+
# This would load from ~/.raxe/config.yaml or ~/.raxe/endpoints.yaml
|
|
339
|
+
|
|
340
|
+
# 4. Return environment-specific default
|
|
341
|
+
env = environment or detect_environment()
|
|
342
|
+
return _ENDPOINT_DEFAULTS[env][endpoint]
|
|
343
|
+
|
|
344
|
+
|
|
345
|
+
def set_endpoint(endpoint: Endpoint, url: str) -> None:
|
|
346
|
+
"""
|
|
347
|
+
Override an endpoint URL at runtime.
|
|
348
|
+
|
|
349
|
+
Args:
|
|
350
|
+
endpoint: The endpoint to override
|
|
351
|
+
url: The new URL to use
|
|
352
|
+
|
|
353
|
+
Raises:
|
|
354
|
+
ValueError: If the URL is invalid
|
|
355
|
+
"""
|
|
356
|
+
# Validate URL
|
|
357
|
+
parsed = urlparse(url)
|
|
358
|
+
if not parsed.scheme or not parsed.netloc:
|
|
359
|
+
raise ValueError(f"Invalid URL: {url}. Must include scheme (http/https) and host.")
|
|
360
|
+
|
|
361
|
+
_state.overrides[endpoint] = url
|
|
362
|
+
logger.info(f"Endpoint {endpoint.value} overridden to: {url}")
|
|
363
|
+
|
|
364
|
+
|
|
365
|
+
def reset_endpoint(endpoint: Endpoint | None = None) -> None:
|
|
366
|
+
"""
|
|
367
|
+
Reset endpoint override(s) to use default resolution.
|
|
368
|
+
|
|
369
|
+
Args:
|
|
370
|
+
endpoint: Specific endpoint to reset, or None to reset all
|
|
371
|
+
"""
|
|
372
|
+
if endpoint is None:
|
|
373
|
+
_state.overrides.clear()
|
|
374
|
+
logger.info("All endpoint overrides cleared")
|
|
375
|
+
elif endpoint in _state.overrides:
|
|
376
|
+
del _state.overrides[endpoint]
|
|
377
|
+
logger.info(f"Endpoint {endpoint.value} override cleared")
|
|
378
|
+
|
|
379
|
+
|
|
380
|
+
def reset_all() -> None:
|
|
381
|
+
"""Reset all state including environment detection cache."""
|
|
382
|
+
_state.overrides.clear()
|
|
383
|
+
_state.detected_environment = None
|
|
384
|
+
_state.config_file_path = None
|
|
385
|
+
|
|
386
|
+
|
|
387
|
+
# ============================================================================
|
|
388
|
+
# Convenience Functions
|
|
389
|
+
# ============================================================================
|
|
390
|
+
|
|
391
|
+
def get_api_base(environment: Environment | None = None) -> str:
|
|
392
|
+
"""Get the API base URL."""
|
|
393
|
+
return get_endpoint(Endpoint.API_BASE, environment)
|
|
394
|
+
|
|
395
|
+
|
|
396
|
+
def get_telemetry_endpoint(environment: Environment | None = None) -> str:
|
|
397
|
+
"""Get the telemetry endpoint URL."""
|
|
398
|
+
return get_endpoint(Endpoint.TELEMETRY, environment)
|
|
399
|
+
|
|
400
|
+
|
|
401
|
+
def get_health_endpoint(environment: Environment | None = None) -> str:
|
|
402
|
+
"""Get the health check endpoint URL."""
|
|
403
|
+
return get_endpoint(Endpoint.HEALTH, environment)
|
|
404
|
+
|
|
405
|
+
|
|
406
|
+
def get_console_url(environment: Environment | None = None) -> str:
|
|
407
|
+
"""Get the console base URL."""
|
|
408
|
+
return get_endpoint(Endpoint.CONSOLE, environment)
|
|
409
|
+
|
|
410
|
+
|
|
411
|
+
def get_cli_session_endpoint(environment: Environment | None = None) -> str:
|
|
412
|
+
"""Get the CLI session endpoint URL."""
|
|
413
|
+
return get_endpoint(Endpoint.CLI_SESSION, environment)
|
|
414
|
+
|
|
415
|
+
|
|
416
|
+
# ============================================================================
|
|
417
|
+
# Endpoint Testing
|
|
418
|
+
# ============================================================================
|
|
419
|
+
|
|
420
|
+
@dataclass
|
|
421
|
+
class EndpointStatus:
|
|
422
|
+
"""Status of an endpoint connectivity test."""
|
|
423
|
+
endpoint: Endpoint
|
|
424
|
+
url: str
|
|
425
|
+
reachable: bool
|
|
426
|
+
dns_resolved: bool
|
|
427
|
+
response_time_ms: float | None
|
|
428
|
+
error: str | None
|
|
429
|
+
http_status: int | None = None
|
|
430
|
+
|
|
431
|
+
|
|
432
|
+
def test_endpoint(
|
|
433
|
+
endpoint: Endpoint,
|
|
434
|
+
timeout_seconds: float = 5.0,
|
|
435
|
+
) -> EndpointStatus:
|
|
436
|
+
"""
|
|
437
|
+
Test connectivity to an endpoint.
|
|
438
|
+
|
|
439
|
+
Args:
|
|
440
|
+
endpoint: The endpoint to test
|
|
441
|
+
timeout_seconds: Request timeout
|
|
442
|
+
|
|
443
|
+
Returns:
|
|
444
|
+
EndpointStatus with connectivity details
|
|
445
|
+
"""
|
|
446
|
+
import time
|
|
447
|
+
|
|
448
|
+
url = get_endpoint(endpoint)
|
|
449
|
+
parsed = urlparse(url)
|
|
450
|
+
|
|
451
|
+
# Test DNS resolution
|
|
452
|
+
dns_resolved = False
|
|
453
|
+
try:
|
|
454
|
+
socket.gethostbyname(parsed.hostname or "")
|
|
455
|
+
dns_resolved = True
|
|
456
|
+
except socket.gaierror:
|
|
457
|
+
return EndpointStatus(
|
|
458
|
+
endpoint=endpoint,
|
|
459
|
+
url=url,
|
|
460
|
+
reachable=False,
|
|
461
|
+
dns_resolved=False,
|
|
462
|
+
response_time_ms=None,
|
|
463
|
+
error=f"DNS resolution failed for {parsed.hostname}",
|
|
464
|
+
)
|
|
465
|
+
|
|
466
|
+
# Test HTTP connectivity
|
|
467
|
+
try:
|
|
468
|
+
import urllib.request
|
|
469
|
+
|
|
470
|
+
# Use health endpoint for API base
|
|
471
|
+
test_url = url
|
|
472
|
+
if endpoint == Endpoint.API_BASE:
|
|
473
|
+
test_url = f"{url}/v1/health"
|
|
474
|
+
elif endpoint == Endpoint.CONSOLE:
|
|
475
|
+
# Console might not have a simple health endpoint
|
|
476
|
+
pass
|
|
477
|
+
|
|
478
|
+
start = time.time()
|
|
479
|
+
req = urllib.request.Request(test_url, method="GET")
|
|
480
|
+
req.add_header("User-Agent", "raxe-cli/endpoint-test")
|
|
481
|
+
|
|
482
|
+
with urllib.request.urlopen(req, timeout=timeout_seconds) as response:
|
|
483
|
+
response_time_ms = (time.time() - start) * 1000
|
|
484
|
+
return EndpointStatus(
|
|
485
|
+
endpoint=endpoint,
|
|
486
|
+
url=url,
|
|
487
|
+
reachable=True,
|
|
488
|
+
dns_resolved=True,
|
|
489
|
+
response_time_ms=response_time_ms,
|
|
490
|
+
error=None,
|
|
491
|
+
http_status=response.status,
|
|
492
|
+
)
|
|
493
|
+
except urllib.error.HTTPError as e:
|
|
494
|
+
response_time_ms = (time.time() - start) * 1000
|
|
495
|
+
# HTTP errors still mean the endpoint is reachable
|
|
496
|
+
return EndpointStatus(
|
|
497
|
+
endpoint=endpoint,
|
|
498
|
+
url=url,
|
|
499
|
+
reachable=True,
|
|
500
|
+
dns_resolved=True,
|
|
501
|
+
response_time_ms=response_time_ms,
|
|
502
|
+
error=f"HTTP {e.code}: {e.reason}",
|
|
503
|
+
http_status=e.code,
|
|
504
|
+
)
|
|
505
|
+
except urllib.error.URLError as e:
|
|
506
|
+
return EndpointStatus(
|
|
507
|
+
endpoint=endpoint,
|
|
508
|
+
url=url,
|
|
509
|
+
reachable=False,
|
|
510
|
+
dns_resolved=dns_resolved,
|
|
511
|
+
response_time_ms=None,
|
|
512
|
+
error=str(e.reason),
|
|
513
|
+
)
|
|
514
|
+
except Exception as e:
|
|
515
|
+
return EndpointStatus(
|
|
516
|
+
endpoint=endpoint,
|
|
517
|
+
url=url,
|
|
518
|
+
reachable=False,
|
|
519
|
+
dns_resolved=dns_resolved,
|
|
520
|
+
response_time_ms=None,
|
|
521
|
+
error=str(e),
|
|
522
|
+
)
|
|
523
|
+
|
|
524
|
+
|
|
525
|
+
def test_all_endpoints(
|
|
526
|
+
environment: Environment | None = None,
|
|
527
|
+
timeout_seconds: float = 5.0,
|
|
528
|
+
) -> dict[Endpoint, EndpointStatus]:
|
|
529
|
+
"""
|
|
530
|
+
Test connectivity to all endpoints.
|
|
531
|
+
|
|
532
|
+
Args:
|
|
533
|
+
environment: Environment to test (defaults to detected)
|
|
534
|
+
timeout_seconds: Request timeout per endpoint
|
|
535
|
+
|
|
536
|
+
Returns:
|
|
537
|
+
Dictionary of endpoint to status
|
|
538
|
+
"""
|
|
539
|
+
results = {}
|
|
540
|
+
for endpoint in Endpoint:
|
|
541
|
+
results[endpoint] = test_endpoint(endpoint, timeout_seconds)
|
|
542
|
+
return results
|
|
543
|
+
|
|
544
|
+
|
|
545
|
+
# ============================================================================
|
|
546
|
+
# Configuration Display
|
|
547
|
+
# ============================================================================
|
|
548
|
+
|
|
549
|
+
def get_all_endpoints(environment: Environment | None = None) -> dict[str, str]:
|
|
550
|
+
"""
|
|
551
|
+
Get all endpoint URLs for display purposes.
|
|
552
|
+
|
|
553
|
+
Args:
|
|
554
|
+
environment: Environment to get endpoints for (defaults to detected)
|
|
555
|
+
|
|
556
|
+
Returns:
|
|
557
|
+
Dictionary of endpoint name to URL
|
|
558
|
+
"""
|
|
559
|
+
env = environment or detect_environment()
|
|
560
|
+
return {
|
|
561
|
+
endpoint.value: get_endpoint(endpoint, env)
|
|
562
|
+
for endpoint in Endpoint
|
|
563
|
+
}
|
|
564
|
+
|
|
565
|
+
|
|
566
|
+
def get_endpoint_info() -> dict[str, Any]:
|
|
567
|
+
"""
|
|
568
|
+
Get comprehensive endpoint configuration info for display.
|
|
569
|
+
|
|
570
|
+
Returns:
|
|
571
|
+
Dictionary with environment, endpoints, overrides, etc.
|
|
572
|
+
"""
|
|
573
|
+
env = detect_environment()
|
|
574
|
+
return {
|
|
575
|
+
"environment": env.value,
|
|
576
|
+
"environment_source": _get_environment_source(),
|
|
577
|
+
"endpoints": get_all_endpoints(env),
|
|
578
|
+
"overrides": {
|
|
579
|
+
ep.value: url
|
|
580
|
+
for ep, url in _state.overrides.items()
|
|
581
|
+
},
|
|
582
|
+
"env_vars": {
|
|
583
|
+
ep.value: os.environ.get(env_var, "")
|
|
584
|
+
for ep, env_var in _ENV_VAR_MAPPING.items()
|
|
585
|
+
if os.environ.get(env_var)
|
|
586
|
+
},
|
|
587
|
+
}
|
|
588
|
+
|
|
589
|
+
|
|
590
|
+
def _get_environment_source() -> str:
|
|
591
|
+
"""Get the source of environment detection."""
|
|
592
|
+
# Must match detection priority in detect_environment()
|
|
593
|
+
if os.environ.get("RAXE_ENV"):
|
|
594
|
+
return f"RAXE_ENV={os.environ['RAXE_ENV']}"
|
|
595
|
+
|
|
596
|
+
# Check config file
|
|
597
|
+
config_path = Path.home() / ".raxe" / "config.yaml"
|
|
598
|
+
if config_path.exists():
|
|
599
|
+
try:
|
|
600
|
+
import yaml
|
|
601
|
+
with open(config_path) as f:
|
|
602
|
+
config = yaml.safe_load(f) or {}
|
|
603
|
+
config_env = config.get("core", {}).get("environment", "")
|
|
604
|
+
if config_env:
|
|
605
|
+
return f"~/.raxe/config.yaml (core.environment={config_env})"
|
|
606
|
+
except Exception:
|
|
607
|
+
pass
|
|
608
|
+
|
|
609
|
+
api_key = os.environ.get("RAXE_API_KEY", "")
|
|
610
|
+
if api_key:
|
|
611
|
+
return f"API key prefix ({api_key[:15]}...)"
|
|
612
|
+
|
|
613
|
+
creds_path = Path.home() / ".raxe" / "credentials.json"
|
|
614
|
+
if creds_path.exists():
|
|
615
|
+
return "credentials.json"
|
|
616
|
+
|
|
617
|
+
return "default"
|
|
618
|
+
|
|
619
|
+
|
|
620
|
+
# ============================================================================
|
|
621
|
+
# Environment Presets
|
|
622
|
+
# ============================================================================
|
|
623
|
+
|
|
624
|
+
def use_production() -> None:
|
|
625
|
+
"""Switch to production endpoints."""
|
|
626
|
+
set_environment(Environment.PRODUCTION)
|
|
627
|
+
|
|
628
|
+
|
|
629
|
+
def use_staging() -> None:
|
|
630
|
+
"""Switch to staging endpoints."""
|
|
631
|
+
set_environment(Environment.STAGING)
|
|
632
|
+
|
|
633
|
+
|
|
634
|
+
def use_development() -> None:
|
|
635
|
+
"""Switch to development endpoints."""
|
|
636
|
+
set_environment(Environment.DEVELOPMENT)
|
|
637
|
+
|
|
638
|
+
|
|
639
|
+
def use_local() -> None:
|
|
640
|
+
"""Switch to local console with Cloud Run API (for console development)."""
|
|
641
|
+
set_environment(Environment.LOCAL)
|