Skip to main content

I-Search Agent RPA Python SDK,封装 OCR、验证码、DocAgent、VNC 等客户端能力

Project description

isa-rpa

I-Search Agent RPA Python SDK,封装 OCR、验证码、DocAgent、VNC、凭据等客户端能力。

该包可从官方 PyPI 安装,但其中部分能力依赖 I-Search 内部运行环境、内部网关或平台侧注入的环境变量。公开安装不等于脱离这些运行条件即可直接使用。

安装

如果使用方没有修改 uv 的默认索引,可以直接从官方 PyPI 安装:

uv add isa-rpa

作为 CLI 工具安装:

uv tool install isa-rpa

也可以使用 pip

pip install isa-rpa

打包与发布

本模块位于 monorepo rpa-code-agent/sdk/isa-rpa/

uv build --no-sources
uv publish

构建产物位于 dist/ 目录:

dist/isa_rpa-0.1.2-py3-none-any.whl
dist/isa_rpa-0.1.2.tar.gz

CLI

查看帮助:

isa-rpa --help

VNC 模式切换:

isa-rpa vnc switch --mode local
isa-rpa vnc switch --mode server

如果在魔术师环境中运行,通常需要由运行时注入 ISA_RUNTIME=magicianCLIENT_ID 以及网关相关环境变量。

Python SDK

VNC

from isa_rpa import VNCClient

client = VNCClient()
ws_url = client.get_cdp_url()

凭据管理

from isa_rpa import CredentialClient

client = CredentialClient()
items = client.list()
detail = client.query(name="测试凭据")

# 排查非魔术师环境下的 token / header / 请求体 / 响应内容时可打开调试输出
debug_client = CredentialClient(debug=True)
debug_client.query(name="测试凭据")

CLI 下也可以通过环境变量开启同样的调试打印:

ISA_RPA_CREDENTIAL_DEBUG=1 isa-rpa credential query --name 测试凭据

DocAgent

from isa_rpa import DocAgentClient

client = DocAgentClient(token="your-token")
files = client.list_files(project_code="PRJ001")
bills = client.list_bills(project_code="PRJ001")

验证码识别

from isa_rpa import CaptchaClient

client = CaptchaClient(
    api_key="your-api-key",
    secret_key="your-secret-key",
)

适用范围

  • OCR、验证码识别等能力可按各自接口配置独立使用。
  • VNC、凭据、DocAgent、统一 token 获取等能力通常依赖 I-Search 平台环境。
  • 若你的运行环境不提供对应的网关、认证或共享组件,这些能力可能无法直接工作。

开发

uv sync
uv run pytest
uv run ruff check src/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

isa_rpa-0.1.2-py3-none-any.whl (38.0 kB view details)

Uploaded Python 3

File details

Details for the file isa_rpa-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: isa_rpa-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 38.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.12 {"installer":{"name":"uv","version":"0.10.12","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}

File hashes

Hashes for isa_rpa-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6c387791c919a3c68cec86417165c25a50c71a18effd6cd458b89be0681ad828
MD5 d823bb10e975573b70f6a6a3ff159b1d
BLAKE2b-256 b0e170cdfe4ff2b7c75a68cc71442d2c659e6fd74562719b86c3609e162cc758

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page