Skip to main content

zt-archery-cli

Archery SQL 审核平台命令行工具,用于登录并查询实例、库、表结构与 SQL 结果。

环境要求

  • Python >=3.10
  • 可用浏览器(首次登录会自动打开)

安装

开发安装(源码)

pip install -e .

打包发布

python -m pip install --upgrade build twine
python -m build
twine upload dist/*

快速开始

首次运行会打开浏览器,请完成登录。成功后会缓存 Cookie 到本地。

zt-archery-cli login

2) 查看可读实例

zt-archery-cli sql instances

3) 查询实例下数据库

zt-archery-cli sql databases -i your_instance

4) 查询数据库下表

zt-archery-cli sql tables -i your_instance -d your_database

5) 查看表结构

zt-archery-cli sql describe -i your_instance -d your_database -t your_table

6) 执行 SQL

zt-archery-cli sql query \
  -i your_instance \
  -d your_database \
  -t your_table \
  --sql "select * from your_table limit 10"

全局参数

  • -o, --output:输出格式,支持:
    • json(默认)
    • human(表格)

示例:

zt-archery-cli -o human sql instances

配置说明

默认配置目录:~/.zt-archery-cli

  • Cookie 缓存:~/.zt-archery-cli/cookies.json
  • 配置文件:~/.zt-archery-cli/config.yaml

可选配置项示例:

browser_channel: chromium

环境变量(可选)

支持通过环境变量自动填充登录页账号密码(如 SSO 页面字段可用):

  • ZT_SSO_USERNAME
  • ZT_SSO_PASSWORD

未设置时可在浏览器中手动完成登录。

Metadata

Release files for zt-archery-cli 0.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for zt-archery-cli 0.3.1
File Size Uploaded Provenance Actions
zt_archery_cli-0.3.1.tar.gz 13.6 kB Without provenance Details for zt_archery_cli-0.3.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for zt-archery-cli 0.3.1
File Interpreter ABI Platform Actions
zt_archery_cli-0.3.1-py3-none-any.whl Python 3 none any Details for zt_archery_cli-0.3.1-py3-none-any.whl

Total release size: 25.1 kB

Release files / zt_archery_cli-0.3.1.tar.gz

Download URL zt_archery_cli-0.3.1.tar.gz
Size 13.6 kB
Tags Source
SHA-256 checksum
How to use checksums
7b248086bed911e4c8adfac5953978022f347e5e79b146f12b444eaa328d892b
BLAKE2b-256 checksum
How to use checksums
ff7eca82d8c9d8d3f4992e0dbec02951a577cca6448e7602b5eb850b95e0ea41
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / zt_archery_cli-0.3.1-py3-none-any.whl

Download URL zt_archery_cli-0.3.1-py3-none-any.whl
Size 11.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
26d483a3e2d1ee6881517ec3fac0836bb1cd0e2a1c1ad572a284baa1b2146a7a
BLAKE2b-256 checksum
How to use checksums
a5bb2683a6fe37aec3a92cd52741739d95b006969d6435e57e6e7e57bd336aa0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Security for zt-archery-cli 0.3.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page