tripl 0.3.1__tar.gz → 0.3.2__tar.gz
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.
- {tripl-0.3.1 → tripl-0.3.2}/PKG-INFO +90 -47
- {tripl-0.3.1 → tripl-0.3.2}/README.md +88 -45
- {tripl-0.3.1 → tripl-0.3.2}/pyproject.toml +6 -9
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/chart_annotations.py +2 -2
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/docs.py +21 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/event_types.py +1 -10
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/plan_validation.py +1 -7
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/request.py +1 -1
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/variables.py +8 -3
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/client.py +31 -4
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/generate.py +0 -4
- tripl-0.3.2/src/tripl_cli/commands/_check_config.py +60 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/_write.py +39 -8
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/annotate.py +2 -19
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/check.py +10 -42
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/codegen.py +7 -45
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/docs.py +11 -20
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/drifts.py +4 -13
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/export.py +3 -5
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/install.py +79 -11
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/scans.py +5 -25
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/upgrade.py +3 -24
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/config.py +4 -3
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/diagnostics/checks.py +2 -1
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/errors.py +1 -1
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/files/compose.yaml +65 -6
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/files.py +31 -5
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/plan.py +29 -2
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/render.py +25 -10
- {tripl-0.3.1 → tripl-0.3.2}/tests/conftest.py +1 -1
- tripl-0.3.2/tests/test_check_config_flags.py +48 -0
- tripl-0.3.2/tests/test_client_redirects.py +155 -0
- tripl-0.3.2/tests/test_compose_env.py +127 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_contract.py +20 -0
- tripl-0.3.2/tests/test_docs_audience.py +31 -0
- tripl-0.3.2/tests/test_docs_cover_the_parser.py +135 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_install_cmd.py +30 -3
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_install_files.py +10 -5
- tripl-0.3.2/tests/test_install_version_recovery.py +239 -0
- {tripl-0.3.1 → tripl-0.3.2}/uv.lock +1 -1
- {tripl-0.3.1 → tripl-0.3.2}/.gitignore +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/LICENSE +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/__main__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/auth.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/branches.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/data_sources.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/endpoints.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/events.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/monitoring.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/plan_export.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/projects.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/scans.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/api/search.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/calls.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/config.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/lexer.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/model.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/payloads.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/presets.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/render.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/scan.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/symbols.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/validate.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/values.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/check/yamlish.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/cli.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/calls.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/context.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/context_named.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/context_plan.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/files.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/languages.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/model.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/naming.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/template.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/named.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/named.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/named.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/screen_view.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/screen_view.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/screen_view.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/self_describing.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/self_describing.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/self_describing.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/structured.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/structured.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/structured.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/transport.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/transport.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/templates/transport.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/codegen/value_types.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/_docs_files.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/_plan.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/_resolve.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/doctor.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/events.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/plan.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/status.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/watch.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/commands/whoami.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/diagnostics/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/diagnostics/collect.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/diagnostics/endpoints.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/diagnostics/scan_checks.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/docker.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/files/rabbitmq.conf +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/health.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/secrets.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/install/shell.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/model.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/py.typed +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/render.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/report.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/runner.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/watch/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/watch/collect.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/watch/diff.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/watch/loop.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/watch/model.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/src/tripl_cli/watch/render.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/__init__.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/check.yml +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/check.yml +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/kotlin/AcmeAction.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/kotlin/AcmeAppConstants.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/kotlin/AcmeCategory.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/kotlin/AcmeLabel.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/kotlin/AcmeProperty.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/kotlin/AcmeScreens.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/kotlin/AcmeStructured.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/kotlin/TriplTransport.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/swift/AcmeAppConstants.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/swift/AcmePlanned.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/swift/AcmeScreens.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/swift/AcmeStructured.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/swift/TriplTransport.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/ts/acmeAction.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/ts/acmeAppConstants.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/ts/acmeCategory.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/ts/acmeLabel.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/ts/acmeProperty.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/ts/acmeScreens.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/ts/acmeStructured.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/golden/ts/triplTransport.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/model.json +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/holder.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/holder.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/named.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/named.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/named.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/planned.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/screen.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/screen.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/screen.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/structured.kotlin.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/structured.swift.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/custom/templates/structured.ts.mustache +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/kotlin/AppEvents.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/kotlin/LegacyTracking.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/kotlin/ScreenTracking.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/kotlin/SdTracking.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/kotlin/TriplTransport.kt +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/swift/AppEvents.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/swift/LegacyTracking.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/swift/ScreenTracking.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/swift/SdTracking.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/swift/TriplTransport.swift +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/ts/appEvents.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/ts/legacyTracking.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/ts/screenTracking.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/ts/sdTracking.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/golden/ts/triplTransport.ts +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/codegen/model.json +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_annotate_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_api_requests.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_check_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_check_scan.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_checks.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_cli.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_client.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_codegen_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_codegen_custom.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_codegen_generate.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_codegen_naming.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_codegen_template.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_config.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_docker_detect.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_docs_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_doctor.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_drifts_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_events_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_output_samples.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_plan_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_runner.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_scans_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_status.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_upgrade_cmd.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_watch.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_watch_diff.py +0 -0
- {tripl-0.3.1 → tripl-0.3.2}/tests/test_whoami_cmd.py +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: tripl
|
|
3
|
-
Version: 0.3.
|
|
4
|
-
Summary:
|
|
3
|
+
Version: 0.3.2
|
|
4
|
+
Summary: Command-line client for tripl: instance diagnostics and live monitoring, tracking-plan reads, code checks and codegen against the plan, team notes, and self-hosted install and upgrade
|
|
5
5
|
Project-URL: Homepage, https://docs.tripl.io/
|
|
6
6
|
Project-URL: Documentation, https://docs.tripl.io/run/cli
|
|
7
7
|
Project-URL: Repository, https://github.com/tripl-io/tripl
|
|
@@ -28,10 +28,22 @@ Description-Content-Type: text/markdown
|
|
|
28
28
|
|
|
29
29
|
# tripl (CLI)
|
|
30
30
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
31
|
+
Command-line client for [tripl](https://docs.tripl.io), the tracking-plan
|
|
32
|
+
service. With it you can:
|
|
33
|
+
|
|
34
|
+
- check and follow a **running instance** (`doctor`, `status`, `watch`, `whoami`);
|
|
35
|
+
- read its tracking plan (`events`, `plan`);
|
|
36
|
+
- run and cancel scans, and triage schema drifts (`scans`, `drifts`);
|
|
37
|
+
- put a deploy marker on the monitoring charts (`annotate`);
|
|
38
|
+
- check the tracking calls in your code against the plan, and generate typed
|
|
39
|
+
tracking code or JSON Schemas from it (`check`, `codegen`, `export`);
|
|
40
|
+
- pull and push the team's notes (`docs`);
|
|
41
|
+
- install and upgrade a self-hosted stack on a Docker host (`install`, `upgrade`).
|
|
42
|
+
|
|
43
|
+
Like [`tripl-mcp`](https://docs.tripl.io/integrate/mcp-server), it is a pure
|
|
44
|
+
HTTP client of the tripl REST API (`/api/v1`): it imports no backend code and
|
|
45
|
+
never touches the database. `install` and `upgrade` are the exception: they act
|
|
46
|
+
on a directory and the local Docker daemon, not on an instance.
|
|
35
47
|
|
|
36
48
|
The distribution is **`tripl`**, the console script is **`tripl`**, and the
|
|
37
49
|
import package is **`tripl_cli`**. The last one is deliberate: the service's own
|
|
@@ -57,7 +69,6 @@ From PyPI — `tripl` is published, so this is the ordinary path:
|
|
|
57
69
|
|
|
58
70
|
```bash
|
|
59
71
|
uvx tripl --version
|
|
60
|
-
# tripl 0.1.0
|
|
61
72
|
|
|
62
73
|
pip install tripl
|
|
63
74
|
```
|
|
@@ -78,17 +89,20 @@ uvx --from "git+https://github.com/tripl-io/tripl.git#subdirectory=cli" tripl --
|
|
|
78
89
|
## Commands
|
|
79
90
|
|
|
80
91
|
A command acting on the instance as a whole is one word; a command acting on a
|
|
81
|
-
class of objects is `<plural-noun> <verb>`. Every
|
|
82
|
-
|
|
83
|
-
`--project SLUG` (repeatable) and
|
|
84
|
-
|
|
85
|
-
`
|
|
92
|
+
class of objects is `<plural-noun> <verb>`. Every command takes `--json`, and
|
|
93
|
+
every command that talks to an instance takes `--timeout SECONDS`. The ones that
|
|
94
|
+
report on many projects also take `--project SLUG` (repeatable) and
|
|
95
|
+
`--include-demo`. The ones that name a single object, and every `events`,
|
|
96
|
+
`plan` and `docs` verb, require `--project` **exactly once**. A bare group
|
|
97
|
+
(`tripl scans`, `tripl drifts`, `tripl events`, `tripl plan`, `tripl docs`)
|
|
98
|
+
prints that group's help on stderr and exits 2.
|
|
86
99
|
|
|
87
100
|
```bash
|
|
88
101
|
tripl doctor # check the instance and report what is broken
|
|
89
102
|
tripl doctor --json # one JSON document on stdout, human lines on stderr
|
|
90
103
|
tripl doctor --strict # exit 3 on warnings too (never on skipped checks)
|
|
91
104
|
tripl status # projects, events, scans, signals, coverage
|
|
105
|
+
tripl whoami # the account, organization and scope the API key acts as
|
|
92
106
|
tripl watch # follow jobs, signals and delivery failures live
|
|
93
107
|
tripl watch --json # JSON Lines on stdout, one object per event
|
|
94
108
|
tripl scans list # scan configs, their schedule, and whether they dispatch
|
|
@@ -98,6 +112,13 @@ tripl scans cancel <scan> <job-id> --project SLUG # cancel an active job (WRIT
|
|
|
98
112
|
tripl drifts list # schema drifts; untriaged by default
|
|
99
113
|
tripl drifts dismiss <drift-id> --project SLUG # false_positive or snooze (WRITE)
|
|
100
114
|
tripl drifts reopen <drift-id> --project SLUG # back to open; drops the note (WRITE)
|
|
115
|
+
tripl events list --project SLUG # the event catalog, with the API's own filters
|
|
116
|
+
tripl events show <event-id> --project SLUG # one event, field values by field name
|
|
117
|
+
tripl plan types --project SLUG # event types, with a field count each
|
|
118
|
+
tripl plan fields <event-type> --project SLUG # one event type's field definitions
|
|
119
|
+
tripl plan properties --project SLUG # properties, and how many events use each
|
|
120
|
+
tripl plan branches --project SLUG # plan branches and how far ahead each is
|
|
121
|
+
tripl plan search <query> --project SLUG # search the whole plan, ids to read next
|
|
101
122
|
tripl annotate "Deployed web 2026.09.25" --project SLUG --url URL # deploy marker on monitoring charts (WRITE)
|
|
102
123
|
tripl check # validate the tracking calls in this checkout against the plan
|
|
103
124
|
tripl check --payloads events.ndjson # validate captured events; a missing required field fails
|
|
@@ -105,29 +126,40 @@ tripl check --format sarif > tripl.sarif # SARIF 2.1.0 for code scanning
|
|
|
105
126
|
tripl codegen # typed tracking code (Swift, Kotlin, TypeScript) from the plan
|
|
106
127
|
tripl codegen --check # CI: exit 1 when the committed generated files are out of date
|
|
107
128
|
tripl export --out plan-schemas # one JSON Schema (2020-12) per event, plus the bundle
|
|
108
|
-
tripl
|
|
129
|
+
tripl docs ls --project SLUG # the team's notes, in both scopes
|
|
130
|
+
tripl docs cat <path> --project SLUG # print one note exactly as stored
|
|
131
|
+
tripl docs pull <dir> --project SLUG # write one scope's notes into a folder
|
|
132
|
+
tripl docs push <dir> --project SLUG # upload a folder of notes in one import (WRITE)
|
|
133
|
+
tripl install --app-url https://tripl.example.com --version X.Y.Z # provision a stack and start it (HOST)
|
|
109
134
|
tripl install --app-url https://tripl.example.com --dry-run # print the plan, write nothing
|
|
110
|
-
tripl upgrade --to
|
|
135
|
+
tripl upgrade --to X.Y.Z # move an installed stack to a new image tag (HOST)
|
|
111
136
|
```
|
|
112
137
|
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
`
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
138
|
+
`X.Y.Z` stands for a released version, listed at
|
|
139
|
+
<https://github.com/tripl-io/tripl/releases>. The image, this CLI and `tripl-mcp`
|
|
140
|
+
are released together under one version, so `tripl --version` names a tag that
|
|
141
|
+
exists. `--version` defaults to `latest`; pin a released tag in production so a
|
|
142
|
+
re-run cannot move you onto an image you have not read the notes for. The command
|
|
143
|
+
says so on stderr when you leave it at the default.
|
|
144
|
+
|
|
145
|
+
Every command that talks to an instance and is not marked WRITE is
|
|
146
|
+
**read-only**, and a `tk_r_` key is enough for it. `check` sends a `POST`, but
|
|
147
|
+
only to carry the calls it found to the validator; it changes nothing.
|
|
148
|
+
`codegen`, `export` and `docs pull` write local files only. The commands marked
|
|
149
|
+
WRITE need a `tk_w_` key backed by an editor or owner, and the CLI does not
|
|
150
|
+
pre-judge that: the key prefix is derived from the scope's first letter
|
|
151
|
+
server-side and says nothing about the user's role, so the request is sent and
|
|
152
|
+
the API's own 403 is printed.
|
|
153
|
+
|
|
154
|
+
`scans cancel`, `drifts dismiss`, `drifts reopen` and `docs push` prompt on a
|
|
155
|
+
terminal and take `--yes` (`docs push` first sends a dry-run import and shows
|
|
156
|
+
what would be created, updated and deleted); when stdin is **not** a terminal and
|
|
157
|
+
`--yes` was not given they refuse with exit 2 rather than hanging a cron job or
|
|
158
|
+
proceeding silently. `scans run` and `annotate` do not prompt and have no `--yes`
|
|
159
|
+
at all — passing one is exit 2, because a no-op flag here is a flag a script
|
|
160
|
+
author will assume works on the next command too. Every write takes `--dry-run`,
|
|
161
|
+
which resolves everything, prints the exact request (method, path, params, body —
|
|
162
|
+
never a credential) and sends nothing.
|
|
131
163
|
|
|
132
164
|
`annotate` posts a chart marker with source `api`, for a deploy step in CI. On
|
|
133
165
|
this one command `--url` is the release link the marker opens, not the instance:
|
|
@@ -159,7 +191,7 @@ event_types:
|
|
|
159
191
|
Presets: `segment_track`, `amplitude_log_event`, `snowplow_structured`,
|
|
160
192
|
`snowplow_screen_view`, `snowplow_self_describing`. Swift, Objective-C, Kotlin,
|
|
161
193
|
Java and TypeScript/JavaScript are read; enum shorthand (`.home`) and qualified
|
|
162
|
-
cases resolve through the enum files, interpolated names become plan
|
|
194
|
+
cases resolve through the enum files, interpolated names become plan properties
|
|
163
195
|
(`"promo_sheet_\(id)_shown"` is `promo_sheet_${id}_shown`), Kotlin/Java
|
|
164
196
|
`.name` / `name()` and Swift `.description` read an enum case's own name, and a
|
|
165
197
|
value only known at runtime is sent as unknown, never as an error (`--strict`
|
|
@@ -178,7 +210,7 @@ It never imports an SDK.
|
|
|
178
210
|
|
|
179
211
|
| `style` | What is generated |
|
|
180
212
|
|---------|-------------------|
|
|
181
|
-
| `structured` | an enum per plan field (its cases are the plan's values; a
|
|
213
|
+
| `structured` | an enum per plan field (its cases are the plan's values; a property-backed value contributes its allowed values; free text stays `String`), your wrapper's call with its argument types narrowed — `log(category: Category, action: Action, label: String, properties:)` — and a compiler-checked `knownEvents` list |
|
|
182
214
|
| `screen_view` | the same, with `ScreenType` / `ScreenId` enums |
|
|
183
215
|
| `named` | one generic `track(event)`: Swift `enum LegacyEvent { case homeScreenView(HomeScreenView) … }` with `name` and `properties`; Kotlin a sealed interface of data classes/objects; TypeScript `track<K extends LegacyEventName>(name: K, props: LegacyEventProps[K])` |
|
|
184
216
|
| `self_describing` | one data class per schema with its fields, sharing one `track` |
|
|
@@ -212,7 +244,7 @@ literal with `object_arg`. `type_names` renames `namespace`, `event` (the named
|
|
|
212
244
|
|
|
213
245
|
An event's parameters are the fields it does not fix plus one per `${token}` in
|
|
214
246
|
its name (`promo_sheet_${sheet_id}_shown` takes `sheetId`, typed by the
|
|
215
|
-
|
|
247
|
+
property's allowed values). Plan strings become identifiers by splitting on
|
|
216
248
|
anything that is not a letter or digit and on camelCase: `Home Screen View` ->
|
|
217
249
|
`homeScreenView` (`HOME_SCREEN_VIEW` for Kotlin enum entries), `checkout:start`
|
|
218
250
|
-> `checkoutStart`; a leading digit gets `_` (`_1stRun`), a reserved word a
|
|
@@ -263,11 +295,22 @@ entirely). Note that the health poll targets the **public** `--app-url`, so on a
|
|
|
263
295
|
host whose TLS terminator is not up yet, use `--wait 0` and curl
|
|
264
296
|
`http://127.0.0.1:8000/health` from the box.
|
|
265
297
|
|
|
298
|
+
`.env` is written before `docker compose pull`, because compose cannot read
|
|
299
|
+
`compose.yaml` without it. When that pull fails on a run that created `.env` —
|
|
300
|
+
a `--version` that was never published is the usual cause — nothing has
|
|
301
|
+
started and nothing has read the generated secrets, so `install` removes that
|
|
302
|
+
`.env` again and says so: run it again with a corrected `--version` and it
|
|
303
|
+
starts clean. A `.env` that was already there is never removed, and once
|
|
304
|
+
`up -d` has run the file stays whatever happens.
|
|
305
|
+
|
|
266
306
|
`upgrade --to` is required and a **downgrade is refused outright** with no
|
|
267
|
-
override flag
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
307
|
+
override flag. An unorderable pair (`latest`, `sha-abc1234`, `1.4`) has no
|
|
308
|
+
ordering to check, so it says so and demands `--allow-unordered-tag` — not
|
|
309
|
+
`--yes`, which only answers the backup prompt and which every non-interactive
|
|
310
|
+
run passes anyway. The first upgrade of an install left at `latest` is such a
|
|
311
|
+
pair; `--dry-run` previews the refusal. `upgrade` pulls, *then* moves the
|
|
312
|
+
`TRIPL_VERSION` pin in `.env` keeping a 0600 `.env.bak.<UTC>` copy, *then*
|
|
313
|
+
restarts — the pull is first so a bad tag leaves `.env` untouched. The `pg_dump` backup command is printed for
|
|
271
314
|
**you** to run and always prompts: a dump this tool invoked and then called
|
|
272
315
|
"your backup" would be a promise it cannot keep, not least because the dump does
|
|
273
316
|
not contain `ENCRYPTION_KEY`. Your database lives in the named volume
|
|
@@ -355,24 +398,24 @@ not moved).
|
|
|
355
398
|
|
|
356
399
|
| Exit | Meaning |
|
|
357
400
|
|------|---------|
|
|
358
|
-
| 0 | Every check passed, or only warned and `--strict` was not given. `status`, whenever
|
|
359
|
-
| 1 | The tool itself broke (doctor turns every API failure into a finding), or any other command could not complete a request — unreachable, or the API refused it. For `watch` this includes a key revoked mid-run. For `scans list` / `drifts list` it includes **any** failed read in the fan-out; for `scans run`, a job returned already `failed`; for `scans cancel` / `drifts dismiss` / `drifts reopen`, a declined prompt. |
|
|
360
|
-
| 2 | Usage or configuration error. For `doctor` and `status` that is resolved before any socket opens; `watch` also refuses after reading the listings, when `--scan` matches nothing or more than 24 scan configs are selected. The
|
|
401
|
+
| 0 | Every check passed, or only warned and `--strict` was not given. `status` and `whoami`, whenever they completed. `watch`, whenever the run completed — a failed job or a new signal is still 0. The `scans`, `drifts`, `events`, `plan` and `docs` verbs and `annotate`, whenever every read arrived or the write was accepted (`--dry-run` included, and a de-duplicated `annotate` too). |
|
|
402
|
+
| 1 | The tool itself broke (doctor turns every API failure into a finding), or any other command could not complete a request — unreachable, or the API refused it. For `watch` this includes a key revoked mid-run. For `scans list` / `drifts list` it includes **any** failed read in the fan-out; for `scans run`, a job returned already `failed`; for `scans cancel` / `drifts dismiss` / `drifts reopen` / `docs push`, a declined prompt. For `install` and `upgrade`, a `docker compose` command that failed or a `/health` that did not answer in time. |
|
|
403
|
+
| 2 | Usage or configuration error. For `doctor` and `status` that is resolved before any socket opens; `watch` also refuses after reading the listings, when `--scan` matches nothing or more than 24 scan configs are selected. The object verbs add a bare group, a missing or repeated `--project`, an unresolved or ambiguous selector, and a prompting write on a non-TTY without `--yes`; `annotate` adds a `--url` that is not http(s), an `--at` that is not RFC 3339, and half a scope; `upgrade` adds a refused downgrade and an unorderable pair without `--allow-unordered-tag`. Either way **no JSON is emitted** and no write is sent. |
|
|
361
404
|
| 3 | `doctor` only: at least one check failed, or `--strict` and at least one warning. Nothing else ever exits 3. |
|
|
405
|
+
| 130 | Interrupted (SIGINT). For `watch` this is the **normal** ending — a run without `--duration` has no other way to stop. |
|
|
362
406
|
|
|
363
407
|
`check` uses 0, 1 and 2: 1 when any call site or event has an error (or, with
|
|
364
408
|
`--strict`, a warning), and 2 for a bad check config or payload file.
|
|
365
409
|
`codegen` uses them too: 1 for drift under `--check` (or a plan without a
|
|
366
410
|
configured event type), 2 for a bad check config or template.
|
|
367
|
-
| 130 | Interrupted (SIGINT). For `watch` this is the **normal** ending — a run without `--duration` has no other way to stop. |
|
|
368
411
|
|
|
369
412
|
An unreachable instance therefore exits **3** out of `doctor`, not 1 — it
|
|
370
413
|
becomes a finding like everything else doctor reads, which is what makes an exit
|
|
371
414
|
1 out of `doctor` a meaningful bug signal. **Every other command exits 1** on an
|
|
372
415
|
unreachable instance, because none of them turns a failed read into a verdict.
|
|
373
416
|
|
|
374
|
-
`doctor` and `status` put exactly one JSON document on stdout, and so
|
|
375
|
-
|
|
417
|
+
`doctor` and `status` put exactly one JSON document on stdout, and so does every
|
|
418
|
+
other command except `watch` — but only when the command completes: a write the API
|
|
376
419
|
refused, a read that failed outright and a declined prompt all leave stdout
|
|
377
420
|
**empty** and put the reason on stderr, so a consumer checks the exit code
|
|
378
421
|
before it parses. `watch --json`
|
|
@@ -387,7 +430,7 @@ Full reference — every check, every finding code with its `evidence` keys, eve
|
|
|
387
430
|
`watch` event token and the JSON Lines envelope, and what an operator should
|
|
388
431
|
actually do about each one:
|
|
389
432
|
<https://docs.tripl.io/run/cli> (source:
|
|
390
|
-
[`website/docs/run/cli.md`](
|
|
433
|
+
[`website/docs/run/cli.md`](https://github.com/tripl-io/tripl/blob/main/website/docs/run/cli.md)).
|
|
391
434
|
|
|
392
435
|
## Configuration
|
|
393
436
|
|
|
@@ -402,7 +445,7 @@ from the config file works.
|
|
|
402
445
|
|
|
403
446
|
| Variable | Meaning |
|
|
404
447
|
|----------|---------|
|
|
405
|
-
| `TRIPL_BASE_URL` | Base URL of the tripl instance (the same variable `tripl-mcp` reads) |
|
|
448
|
+
| `TRIPL_BASE_URL` | Base URL of the tripl instance (the same variable `tripl-mcp` reads). Use the final address, usually `https://`: a write that gets a redirect fails rather than being re-sent as a GET |
|
|
406
449
|
| `TRIPL_API_KEY` | API key — `tk_r_` for read-only, `tk_w_` for write |
|
|
407
450
|
| `XDG_CONFIG_HOME` | Overrides the config file location on every platform |
|
|
408
451
|
|
|
@@ -1,9 +1,21 @@
|
|
|
1
1
|
# tripl (CLI)
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
Command-line client for [tripl](https://docs.tripl.io), the tracking-plan
|
|
4
|
+
service. With it you can:
|
|
5
|
+
|
|
6
|
+
- check and follow a **running instance** (`doctor`, `status`, `watch`, `whoami`);
|
|
7
|
+
- read its tracking plan (`events`, `plan`);
|
|
8
|
+
- run and cancel scans, and triage schema drifts (`scans`, `drifts`);
|
|
9
|
+
- put a deploy marker on the monitoring charts (`annotate`);
|
|
10
|
+
- check the tracking calls in your code against the plan, and generate typed
|
|
11
|
+
tracking code or JSON Schemas from it (`check`, `codegen`, `export`);
|
|
12
|
+
- pull and push the team's notes (`docs`);
|
|
13
|
+
- install and upgrade a self-hosted stack on a Docker host (`install`, `upgrade`).
|
|
14
|
+
|
|
15
|
+
Like [`tripl-mcp`](https://docs.tripl.io/integrate/mcp-server), it is a pure
|
|
16
|
+
HTTP client of the tripl REST API (`/api/v1`): it imports no backend code and
|
|
17
|
+
never touches the database. `install` and `upgrade` are the exception: they act
|
|
18
|
+
on a directory and the local Docker daemon, not on an instance.
|
|
7
19
|
|
|
8
20
|
The distribution is **`tripl`**, the console script is **`tripl`**, and the
|
|
9
21
|
import package is **`tripl_cli`**. The last one is deliberate: the service's own
|
|
@@ -29,7 +41,6 @@ From PyPI — `tripl` is published, so this is the ordinary path:
|
|
|
29
41
|
|
|
30
42
|
```bash
|
|
31
43
|
uvx tripl --version
|
|
32
|
-
# tripl 0.1.0
|
|
33
44
|
|
|
34
45
|
pip install tripl
|
|
35
46
|
```
|
|
@@ -50,17 +61,20 @@ uvx --from "git+https://github.com/tripl-io/tripl.git#subdirectory=cli" tripl --
|
|
|
50
61
|
## Commands
|
|
51
62
|
|
|
52
63
|
A command acting on the instance as a whole is one word; a command acting on a
|
|
53
|
-
class of objects is `<plural-noun> <verb>`. Every
|
|
54
|
-
|
|
55
|
-
`--project SLUG` (repeatable) and
|
|
56
|
-
|
|
57
|
-
`
|
|
64
|
+
class of objects is `<plural-noun> <verb>`. Every command takes `--json`, and
|
|
65
|
+
every command that talks to an instance takes `--timeout SECONDS`. The ones that
|
|
66
|
+
report on many projects also take `--project SLUG` (repeatable) and
|
|
67
|
+
`--include-demo`. The ones that name a single object, and every `events`,
|
|
68
|
+
`plan` and `docs` verb, require `--project` **exactly once**. A bare group
|
|
69
|
+
(`tripl scans`, `tripl drifts`, `tripl events`, `tripl plan`, `tripl docs`)
|
|
70
|
+
prints that group's help on stderr and exits 2.
|
|
58
71
|
|
|
59
72
|
```bash
|
|
60
73
|
tripl doctor # check the instance and report what is broken
|
|
61
74
|
tripl doctor --json # one JSON document on stdout, human lines on stderr
|
|
62
75
|
tripl doctor --strict # exit 3 on warnings too (never on skipped checks)
|
|
63
76
|
tripl status # projects, events, scans, signals, coverage
|
|
77
|
+
tripl whoami # the account, organization and scope the API key acts as
|
|
64
78
|
tripl watch # follow jobs, signals and delivery failures live
|
|
65
79
|
tripl watch --json # JSON Lines on stdout, one object per event
|
|
66
80
|
tripl scans list # scan configs, their schedule, and whether they dispatch
|
|
@@ -70,6 +84,13 @@ tripl scans cancel <scan> <job-id> --project SLUG # cancel an active job (WRIT
|
|
|
70
84
|
tripl drifts list # schema drifts; untriaged by default
|
|
71
85
|
tripl drifts dismiss <drift-id> --project SLUG # false_positive or snooze (WRITE)
|
|
72
86
|
tripl drifts reopen <drift-id> --project SLUG # back to open; drops the note (WRITE)
|
|
87
|
+
tripl events list --project SLUG # the event catalog, with the API's own filters
|
|
88
|
+
tripl events show <event-id> --project SLUG # one event, field values by field name
|
|
89
|
+
tripl plan types --project SLUG # event types, with a field count each
|
|
90
|
+
tripl plan fields <event-type> --project SLUG # one event type's field definitions
|
|
91
|
+
tripl plan properties --project SLUG # properties, and how many events use each
|
|
92
|
+
tripl plan branches --project SLUG # plan branches and how far ahead each is
|
|
93
|
+
tripl plan search <query> --project SLUG # search the whole plan, ids to read next
|
|
73
94
|
tripl annotate "Deployed web 2026.09.25" --project SLUG --url URL # deploy marker on monitoring charts (WRITE)
|
|
74
95
|
tripl check # validate the tracking calls in this checkout against the plan
|
|
75
96
|
tripl check --payloads events.ndjson # validate captured events; a missing required field fails
|
|
@@ -77,29 +98,40 @@ tripl check --format sarif > tripl.sarif # SARIF 2.1.0 for code scanning
|
|
|
77
98
|
tripl codegen # typed tracking code (Swift, Kotlin, TypeScript) from the plan
|
|
78
99
|
tripl codegen --check # CI: exit 1 when the committed generated files are out of date
|
|
79
100
|
tripl export --out plan-schemas # one JSON Schema (2020-12) per event, plus the bundle
|
|
80
|
-
tripl
|
|
101
|
+
tripl docs ls --project SLUG # the team's notes, in both scopes
|
|
102
|
+
tripl docs cat <path> --project SLUG # print one note exactly as stored
|
|
103
|
+
tripl docs pull <dir> --project SLUG # write one scope's notes into a folder
|
|
104
|
+
tripl docs push <dir> --project SLUG # upload a folder of notes in one import (WRITE)
|
|
105
|
+
tripl install --app-url https://tripl.example.com --version X.Y.Z # provision a stack and start it (HOST)
|
|
81
106
|
tripl install --app-url https://tripl.example.com --dry-run # print the plan, write nothing
|
|
82
|
-
tripl upgrade --to
|
|
107
|
+
tripl upgrade --to X.Y.Z # move an installed stack to a new image tag (HOST)
|
|
83
108
|
```
|
|
84
109
|
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
`
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
110
|
+
`X.Y.Z` stands for a released version, listed at
|
|
111
|
+
<https://github.com/tripl-io/tripl/releases>. The image, this CLI and `tripl-mcp`
|
|
112
|
+
are released together under one version, so `tripl --version` names a tag that
|
|
113
|
+
exists. `--version` defaults to `latest`; pin a released tag in production so a
|
|
114
|
+
re-run cannot move you onto an image you have not read the notes for. The command
|
|
115
|
+
says so on stderr when you leave it at the default.
|
|
116
|
+
|
|
117
|
+
Every command that talks to an instance and is not marked WRITE is
|
|
118
|
+
**read-only**, and a `tk_r_` key is enough for it. `check` sends a `POST`, but
|
|
119
|
+
only to carry the calls it found to the validator; it changes nothing.
|
|
120
|
+
`codegen`, `export` and `docs pull` write local files only. The commands marked
|
|
121
|
+
WRITE need a `tk_w_` key backed by an editor or owner, and the CLI does not
|
|
122
|
+
pre-judge that: the key prefix is derived from the scope's first letter
|
|
123
|
+
server-side and says nothing about the user's role, so the request is sent and
|
|
124
|
+
the API's own 403 is printed.
|
|
125
|
+
|
|
126
|
+
`scans cancel`, `drifts dismiss`, `drifts reopen` and `docs push` prompt on a
|
|
127
|
+
terminal and take `--yes` (`docs push` first sends a dry-run import and shows
|
|
128
|
+
what would be created, updated and deleted); when stdin is **not** a terminal and
|
|
129
|
+
`--yes` was not given they refuse with exit 2 rather than hanging a cron job or
|
|
130
|
+
proceeding silently. `scans run` and `annotate` do not prompt and have no `--yes`
|
|
131
|
+
at all — passing one is exit 2, because a no-op flag here is a flag a script
|
|
132
|
+
author will assume works on the next command too. Every write takes `--dry-run`,
|
|
133
|
+
which resolves everything, prints the exact request (method, path, params, body —
|
|
134
|
+
never a credential) and sends nothing.
|
|
103
135
|
|
|
104
136
|
`annotate` posts a chart marker with source `api`, for a deploy step in CI. On
|
|
105
137
|
this one command `--url` is the release link the marker opens, not the instance:
|
|
@@ -131,7 +163,7 @@ event_types:
|
|
|
131
163
|
Presets: `segment_track`, `amplitude_log_event`, `snowplow_structured`,
|
|
132
164
|
`snowplow_screen_view`, `snowplow_self_describing`. Swift, Objective-C, Kotlin,
|
|
133
165
|
Java and TypeScript/JavaScript are read; enum shorthand (`.home`) and qualified
|
|
134
|
-
cases resolve through the enum files, interpolated names become plan
|
|
166
|
+
cases resolve through the enum files, interpolated names become plan properties
|
|
135
167
|
(`"promo_sheet_\(id)_shown"` is `promo_sheet_${id}_shown`), Kotlin/Java
|
|
136
168
|
`.name` / `name()` and Swift `.description` read an enum case's own name, and a
|
|
137
169
|
value only known at runtime is sent as unknown, never as an error (`--strict`
|
|
@@ -150,7 +182,7 @@ It never imports an SDK.
|
|
|
150
182
|
|
|
151
183
|
| `style` | What is generated |
|
|
152
184
|
|---------|-------------------|
|
|
153
|
-
| `structured` | an enum per plan field (its cases are the plan's values; a
|
|
185
|
+
| `structured` | an enum per plan field (its cases are the plan's values; a property-backed value contributes its allowed values; free text stays `String`), your wrapper's call with its argument types narrowed — `log(category: Category, action: Action, label: String, properties:)` — and a compiler-checked `knownEvents` list |
|
|
154
186
|
| `screen_view` | the same, with `ScreenType` / `ScreenId` enums |
|
|
155
187
|
| `named` | one generic `track(event)`: Swift `enum LegacyEvent { case homeScreenView(HomeScreenView) … }` with `name` and `properties`; Kotlin a sealed interface of data classes/objects; TypeScript `track<K extends LegacyEventName>(name: K, props: LegacyEventProps[K])` |
|
|
156
188
|
| `self_describing` | one data class per schema with its fields, sharing one `track` |
|
|
@@ -184,7 +216,7 @@ literal with `object_arg`. `type_names` renames `namespace`, `event` (the named
|
|
|
184
216
|
|
|
185
217
|
An event's parameters are the fields it does not fix plus one per `${token}` in
|
|
186
218
|
its name (`promo_sheet_${sheet_id}_shown` takes `sheetId`, typed by the
|
|
187
|
-
|
|
219
|
+
property's allowed values). Plan strings become identifiers by splitting on
|
|
188
220
|
anything that is not a letter or digit and on camelCase: `Home Screen View` ->
|
|
189
221
|
`homeScreenView` (`HOME_SCREEN_VIEW` for Kotlin enum entries), `checkout:start`
|
|
190
222
|
-> `checkoutStart`; a leading digit gets `_` (`_1stRun`), a reserved word a
|
|
@@ -235,11 +267,22 @@ entirely). Note that the health poll targets the **public** `--app-url`, so on a
|
|
|
235
267
|
host whose TLS terminator is not up yet, use `--wait 0` and curl
|
|
236
268
|
`http://127.0.0.1:8000/health` from the box.
|
|
237
269
|
|
|
270
|
+
`.env` is written before `docker compose pull`, because compose cannot read
|
|
271
|
+
`compose.yaml` without it. When that pull fails on a run that created `.env` —
|
|
272
|
+
a `--version` that was never published is the usual cause — nothing has
|
|
273
|
+
started and nothing has read the generated secrets, so `install` removes that
|
|
274
|
+
`.env` again and says so: run it again with a corrected `--version` and it
|
|
275
|
+
starts clean. A `.env` that was already there is never removed, and once
|
|
276
|
+
`up -d` has run the file stays whatever happens.
|
|
277
|
+
|
|
238
278
|
`upgrade --to` is required and a **downgrade is refused outright** with no
|
|
239
|
-
override flag
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
279
|
+
override flag. An unorderable pair (`latest`, `sha-abc1234`, `1.4`) has no
|
|
280
|
+
ordering to check, so it says so and demands `--allow-unordered-tag` — not
|
|
281
|
+
`--yes`, which only answers the backup prompt and which every non-interactive
|
|
282
|
+
run passes anyway. The first upgrade of an install left at `latest` is such a
|
|
283
|
+
pair; `--dry-run` previews the refusal. `upgrade` pulls, *then* moves the
|
|
284
|
+
`TRIPL_VERSION` pin in `.env` keeping a 0600 `.env.bak.<UTC>` copy, *then*
|
|
285
|
+
restarts — the pull is first so a bad tag leaves `.env` untouched. The `pg_dump` backup command is printed for
|
|
243
286
|
**you** to run and always prompts: a dump this tool invoked and then called
|
|
244
287
|
"your backup" would be a promise it cannot keep, not least because the dump does
|
|
245
288
|
not contain `ENCRYPTION_KEY`. Your database lives in the named volume
|
|
@@ -327,24 +370,24 @@ not moved).
|
|
|
327
370
|
|
|
328
371
|
| Exit | Meaning |
|
|
329
372
|
|------|---------|
|
|
330
|
-
| 0 | Every check passed, or only warned and `--strict` was not given. `status`, whenever
|
|
331
|
-
| 1 | The tool itself broke (doctor turns every API failure into a finding), or any other command could not complete a request — unreachable, or the API refused it. For `watch` this includes a key revoked mid-run. For `scans list` / `drifts list` it includes **any** failed read in the fan-out; for `scans run`, a job returned already `failed`; for `scans cancel` / `drifts dismiss` / `drifts reopen`, a declined prompt. |
|
|
332
|
-
| 2 | Usage or configuration error. For `doctor` and `status` that is resolved before any socket opens; `watch` also refuses after reading the listings, when `--scan` matches nothing or more than 24 scan configs are selected. The
|
|
373
|
+
| 0 | Every check passed, or only warned and `--strict` was not given. `status` and `whoami`, whenever they completed. `watch`, whenever the run completed — a failed job or a new signal is still 0. The `scans`, `drifts`, `events`, `plan` and `docs` verbs and `annotate`, whenever every read arrived or the write was accepted (`--dry-run` included, and a de-duplicated `annotate` too). |
|
|
374
|
+
| 1 | The tool itself broke (doctor turns every API failure into a finding), or any other command could not complete a request — unreachable, or the API refused it. For `watch` this includes a key revoked mid-run. For `scans list` / `drifts list` it includes **any** failed read in the fan-out; for `scans run`, a job returned already `failed`; for `scans cancel` / `drifts dismiss` / `drifts reopen` / `docs push`, a declined prompt. For `install` and `upgrade`, a `docker compose` command that failed or a `/health` that did not answer in time. |
|
|
375
|
+
| 2 | Usage or configuration error. For `doctor` and `status` that is resolved before any socket opens; `watch` also refuses after reading the listings, when `--scan` matches nothing or more than 24 scan configs are selected. The object verbs add a bare group, a missing or repeated `--project`, an unresolved or ambiguous selector, and a prompting write on a non-TTY without `--yes`; `annotate` adds a `--url` that is not http(s), an `--at` that is not RFC 3339, and half a scope; `upgrade` adds a refused downgrade and an unorderable pair without `--allow-unordered-tag`. Either way **no JSON is emitted** and no write is sent. |
|
|
333
376
|
| 3 | `doctor` only: at least one check failed, or `--strict` and at least one warning. Nothing else ever exits 3. |
|
|
377
|
+
| 130 | Interrupted (SIGINT). For `watch` this is the **normal** ending — a run without `--duration` has no other way to stop. |
|
|
334
378
|
|
|
335
379
|
`check` uses 0, 1 and 2: 1 when any call site or event has an error (or, with
|
|
336
380
|
`--strict`, a warning), and 2 for a bad check config or payload file.
|
|
337
381
|
`codegen` uses them too: 1 for drift under `--check` (or a plan without a
|
|
338
382
|
configured event type), 2 for a bad check config or template.
|
|
339
|
-
| 130 | Interrupted (SIGINT). For `watch` this is the **normal** ending — a run without `--duration` has no other way to stop. |
|
|
340
383
|
|
|
341
384
|
An unreachable instance therefore exits **3** out of `doctor`, not 1 — it
|
|
342
385
|
becomes a finding like everything else doctor reads, which is what makes an exit
|
|
343
386
|
1 out of `doctor` a meaningful bug signal. **Every other command exits 1** on an
|
|
344
387
|
unreachable instance, because none of them turns a failed read into a verdict.
|
|
345
388
|
|
|
346
|
-
`doctor` and `status` put exactly one JSON document on stdout, and so
|
|
347
|
-
|
|
389
|
+
`doctor` and `status` put exactly one JSON document on stdout, and so does every
|
|
390
|
+
other command except `watch` — but only when the command completes: a write the API
|
|
348
391
|
refused, a read that failed outright and a declined prompt all leave stdout
|
|
349
392
|
**empty** and put the reason on stderr, so a consumer checks the exit code
|
|
350
393
|
before it parses. `watch --json`
|
|
@@ -359,7 +402,7 @@ Full reference — every check, every finding code with its `evidence` keys, eve
|
|
|
359
402
|
`watch` event token and the JSON Lines envelope, and what an operator should
|
|
360
403
|
actually do about each one:
|
|
361
404
|
<https://docs.tripl.io/run/cli> (source:
|
|
362
|
-
[`website/docs/run/cli.md`](
|
|
405
|
+
[`website/docs/run/cli.md`](https://github.com/tripl-io/tripl/blob/main/website/docs/run/cli.md)).
|
|
363
406
|
|
|
364
407
|
## Configuration
|
|
365
408
|
|
|
@@ -374,7 +417,7 @@ from the config file works.
|
|
|
374
417
|
|
|
375
418
|
| Variable | Meaning |
|
|
376
419
|
|----------|---------|
|
|
377
|
-
| `TRIPL_BASE_URL` | Base URL of the tripl instance (the same variable `tripl-mcp` reads) |
|
|
420
|
+
| `TRIPL_BASE_URL` | Base URL of the tripl instance (the same variable `tripl-mcp` reads). Use the final address, usually `https://`: a write that gets a redirect fails rather than being re-sent as a GET |
|
|
378
421
|
| `TRIPL_API_KEY` | API key — `tk_r_` for read-only, `tk_w_` for write |
|
|
379
422
|
| `XDG_CONFIG_HOME` | Overrides the config file location on every platform |
|
|
380
423
|
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "tripl"
|
|
3
|
-
#
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
version = "0.3.1"
|
|
7
|
-
description = "Operator CLI for a tripl tracking-plan instance: diagnostics, health and live monitoring"
|
|
3
|
+
# One version for the service, this CLI and tripl-mcp; bin/release.sh writes it.
|
|
4
|
+
version = "0.3.2"
|
|
5
|
+
description = "Command-line client for tripl: instance diagnostics and live monitoring, tracking-plan reads, code checks and codegen against the plan, team notes, and self-hosted install and upgrade"
|
|
8
6
|
readme = "README.md"
|
|
9
7
|
requires-python = ">=3.12"
|
|
10
8
|
# Apache-2.0 while the SERVICE is AGPL-3.0-or-later, for the same reason
|
|
@@ -49,10 +47,9 @@ dependencies = [
|
|
|
49
47
|
|
|
50
48
|
[project.urls]
|
|
51
49
|
Homepage = "https://docs.tripl.io/"
|
|
52
|
-
# The docs site
|
|
53
|
-
# website/docs/run/cli.md is
|
|
54
|
-
# segment.
|
|
55
|
-
# corrected now, so check this shape when adding a third package.
|
|
50
|
+
# The docs site serves website/docs at the root (`baseUrl: '/'`,
|
|
51
|
+
# `routeBasePath: '/'`), so website/docs/run/cli.md is /run/cli: there is no
|
|
52
|
+
# /docs/ segment. Check this shape when adding a package.
|
|
56
53
|
Documentation = "https://docs.tripl.io/run/cli"
|
|
57
54
|
Repository = "https://github.com/tripl-io/tripl"
|
|
58
55
|
Issues = "https://github.com/tripl-io/tripl/issues"
|
|
@@ -40,8 +40,8 @@ DESCRIPTION_MAX_LENGTH = 2000
|
|
|
40
40
|
SCOPE_REF_MAX_LENGTH = 120
|
|
41
41
|
URL_MAX_LENGTH = 500
|
|
42
42
|
|
|
43
|
-
#
|
|
44
|
-
|
|
43
|
+
# The create route answers 200 when it de-duplicated the label and handed back
|
|
44
|
+
# the annotation that already existed; a new one is a 201.
|
|
45
45
|
STATUS_DEDUPLICATED = 200
|
|
46
46
|
|
|
47
47
|
|
|
@@ -50,6 +50,15 @@ ENDPOINTS: tuple[tuple[str, str], ...] = (
|
|
|
50
50
|
SCOPES: tuple[str, ...] = ("project", "organization")
|
|
51
51
|
# `DocAudience`, verbatim: who a note is written for, from its frontmatter.
|
|
52
52
|
AUDIENCES: tuple[str, ...] = ("human", "agent", "both")
|
|
53
|
+
# What an audience filter keeps. A note marked `both` is written for either
|
|
54
|
+
# reader, so it matches `human` and `agent`; `both` itself keeps only those
|
|
55
|
+
# notes. The tree route takes no audience, so this rule lives on the client side
|
|
56
|
+
# and is applied by `filter_by_audience` alone.
|
|
57
|
+
AUDIENCE_MATCHES: dict[str, tuple[str, ...]] = {
|
|
58
|
+
"human": ("human", "both"),
|
|
59
|
+
"agent": ("agent", "both"),
|
|
60
|
+
"both": ("both",),
|
|
61
|
+
}
|
|
53
62
|
# The import route's `mode`. "mirror" also DELETES every note of the scope that
|
|
54
63
|
# the bundle does not carry.
|
|
55
64
|
IMPORT_MODES: tuple[str, ...] = ("merge", "mirror")
|
|
@@ -186,6 +195,18 @@ def tree_docs(payload: Any, scope: str | None = None) -> JsonList:
|
|
|
186
195
|
return rows
|
|
187
196
|
|
|
188
197
|
|
|
198
|
+
def filter_by_audience(rows: JsonList, audience: str | None) -> JsonList:
|
|
199
|
+
"""The rows written for ``audience``, or all of them when it is ``None``.
|
|
200
|
+
|
|
201
|
+
The second half of ``tree_docs`` for both surfaces: ``tripl docs ls
|
|
202
|
+
--audience`` and the MCP's ``list_docs`` narrow the same rows the same way.
|
|
203
|
+
"""
|
|
204
|
+
if audience is None:
|
|
205
|
+
return rows
|
|
206
|
+
wanted = AUDIENCE_MATCHES[audience]
|
|
207
|
+
return [row for row in rows if row.get("audience") in wanted]
|
|
208
|
+
|
|
209
|
+
|
|
189
210
|
def bundle_files(payload: Any) -> JsonList:
|
|
190
211
|
"""The ``files`` of a ``DocBundle``, dropping anything that is not an object."""
|
|
191
212
|
return as_list(as_dict(payload).get("files"))
|
|
@@ -57,17 +57,8 @@ REOPEN_ACTION = "reopen"
|
|
|
57
57
|
# stays in the tripl UI.
|
|
58
58
|
CLI_ALLOWED_DRIFT_ACTIONS: tuple[str, ...] = (*DISMISS_ACTIONS, REOPEN_ACTION)
|
|
59
59
|
|
|
60
|
-
# SchemaDriftStatus
|
|
60
|
+
# SchemaDriftStatus, verbatim from the OpenAPI document.
|
|
61
61
|
DRIFT_STATUSES: tuple[str, ...] = ("open", "accepted", "snoozed", "false_positive")
|
|
62
|
-
DRIFT_TYPES: tuple[str, ...] = (
|
|
63
|
-
"new_field",
|
|
64
|
-
"missing_field",
|
|
65
|
-
"type_changed",
|
|
66
|
-
"enum_violation",
|
|
67
|
-
"required_null_violation",
|
|
68
|
-
"regex_violation",
|
|
69
|
-
"range_violation",
|
|
70
|
-
)
|
|
71
62
|
|
|
72
63
|
|
|
73
64
|
def list_event_types(slug: str, *, branch: str | None = None) -> ApiRequest:
|
|
@@ -14,7 +14,7 @@ from collections.abc import Mapping, Sequence
|
|
|
14
14
|
from typing import Any
|
|
15
15
|
|
|
16
16
|
from tripl_cli.api.request import ApiRequest
|
|
17
|
-
from tripl_cli.model import JsonDict, JsonList,
|
|
17
|
+
from tripl_cli.model import JsonDict, JsonList, page_items
|
|
18
18
|
|
|
19
19
|
VALIDATE = "/projects/{slug}/plan/validate"
|
|
20
20
|
|
|
@@ -70,9 +70,3 @@ def batches[T](items: Sequence[T], size: int = MAX_ITEMS) -> list[Sequence[T]]:
|
|
|
70
70
|
def verdicts(payload: Any) -> JsonList:
|
|
71
71
|
"""The per-item verdicts of one response, in the order the route answered them."""
|
|
72
72
|
return page_items(payload)
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
def summary_counts(payload: Any) -> JsonDict:
|
|
76
|
-
"""``{ok, warnings, errors}`` of one response, as ints (0 when absent)."""
|
|
77
|
-
summary = as_dict(as_dict(payload).get("summary"))
|
|
78
|
-
return {key: int_of(summary, key) for key in ("ok", "warnings", "errors")}
|