Skip to main content
Glama
jiocloud_client

jiocloud_client

by Ns81000

非官方 Jio AI Cloud Python SDK、CLI 与 AI 智能体工具

License Python Dependencies GitHub repo GitHub issues Docs Live verified Docs deploy

非官方项目。 与 Reliance Jio Infocomm Ltd. 或其子公司无任何关联、联系、授权、认可或任何形式的官方关系。"Jio" / "Jio AI Cloud" 是其各自所有者的商标,此处仅用于指代性引用。

不稳定目标 — 最后验证:2026-08-25(26/26 项检查通过)。 Jio AI Cloud 没有公共 API。端点随时可能更改并随时可能失效。已于 2026-08-25 针对生产环境验证(26/26 项检查)。功能可能随时停止工作 — 请查看 docs/KNOWN_ISSUES.md 了解当前状态。

一个高性能、零依赖的 Python SDK、CLI 和 AI 智能体工具服务器,用于 Jio AI Cloud 存储 — 协议知识是从所有者自己账户的实时网络流量中逆向工程得出的。严格为 个人数据可移植性、备份您自己的账户、互操作性和教育 而构建 — 使用前请参阅 docs/DISCLAIMER.md 和 docs/LEGAL.md。

文档站点:https://ns81000.github.io/jiocloud_client/


主要功能

区域

功能

目录编目

流式递归文件遍历器(已测试 2200+ 文件)、目录列表(文件/文件夹)、跨名称和备份源路径的全文搜索

下载

带进度回调的分块原子下载,MD5 与服务器哈希校验,多线程批量同步并跳过已存在文件

管理

创建文件夹、重命名、移动、收藏/取消收藏、移至回收站、恢复、版本历史

共享

一个或多个对象的公共通用链接(https://www.jioaicloud.com/l/?u=...)

板块/相册

列出、创建、查看成员、获取板块详情、离开板块

账户

个人资料、配额细分(文档/照片/视频/音频)、设备、促销、应用设置

动态

最近活动动态、焦点内容、我共享的内容、DigiLocker 关联应用对象、手动标签

AI 智能体

16 工具 JSON 模式(兼容 OpenAI/Anthropic 函数调用)、严格 JSON 信封分发器、破坏性操作确认保护、MCP 风格 stdio 服务器

健壮性

对 429/5xx/网络故障进行指数退避重试,类型化异常分类,从批量 unprocessed[] 中暴露每个对象的错误

依赖

无 — 纯 Python 3.8+ 标准库

每个已实现的端点都已在生产环境中测试;有关过程中发现的服务器怪癖,请参阅 docs/KNOWN_ISSUES.md;有关可复现的 26 项检查验证矩阵(截至 2026-08-25 全部通过),请参阅 tests/live_verify.py。


Related MCP server: MCP Filesystem Server

服务架构

graph TD
    Client[Python SDK / CLI / Agent] -->|Auth, profile, quota| API[api.jioaicloud.com]
    Client -->|Metadata, folders, trash, share| JAWS[jaws-api.jioaicloud.com]
    Client -->|Direct binary streaming| CDN[jaws-dl.jioaicloud.com]
    Client -->|Shared albums & boards| Boards[boards.jioaicloud.com]
    Client -->|Address book| Contacts[jaws-contacts.jioaicloud.com]
    Client -->|Promo banners| Msg[jaws-msg.jioaicloud.com]

目录结构

jiocloud_client/
├── README.md                  # This file
├── LICENSE                    # MIT + trademark/non-affiliation notice
├── CHANGELOG.md               # Release history with verification stamps
├── CONTRIBUTING.md            # Broken-endpoint reports, capture-based fixes
├── cli.py                     # Command-line interface (20 commands)
├── config.example.json        # Credential template (placeholders only)
├── mkdocs.yml                 # Documentation site config (GitHub Pages)
├── llms.txt / llms-full.txt   # LLM-oriented documentation indexes
├── jiocloud/                  # Core SDK package
│   ├── client.py              # JioCloudClient — 30+ methods, retry engine
│   ├── auth.py                # JioCloudAuth — header construction
│   ├── agent_tools.py         # AI-agent schema, bridge, MCP stdio loop
│   ├── models.py              # Typed dataclasses
│   └── exceptions.py          # Typed error taxonomy
├── docs/                      # Also rendered at ns81000.github.io/jiocloud_client
│   ├── API_REFERENCE.md       # Every verified endpoint + payloads
│   ├── AUTHENTICATION.md      # Headers, token extraction, safety
│   ├── GET_CREDENTIALS.md     # Credential walkthrough (console one-paste)
│   ├── DATA_MODELS.md         # JSON schemas
│   ├── ERROR_CODES.md         # Server error codes seen in production
│   ├── KNOWN_ISSUES.md        # Verified server behaviors & gaps (contribute!)
│   ├── DISCLAIMER.md          # Full legal disclaimers
│   └── LEGAL.md               # Compliance summary
├── ai/                        # AI integration assets
│   ├── skills/jio-cloud-manager/SKILL.md
│   ├── tools/openai-function-schema.json
│   ├── tools/anthropic-tools.json
│   ├── prompts/system-prompt.txt
│   └── examples/agent-conversation.md
├── examples/                  # 01_quickstart ... 08_inventory_export (+ setup_credentials.py)
└── tests/
    ├── test_models.py         # Offline unit tests
    ├── test_client.py         # Live integration tests
    └── live_verify.py         # 26-check live verification matrix

快速开始

1. 配置

最简单的路径:从浏览器的 Network 标签页复制一个请求为 cURL(过滤:domain:api.jioaicloud.com security/users -method:OPTIONS),然后运行:

python examples/setup_credentials.py --from-curl

它会从剪贴板读取 cURL,实时验证会话,并写入 config.json。完整教程(包括一键粘贴的浏览器控制台提取器):docs/GET_CREDENTIALS.md。

手动替代方案:将 config.example.json 复制为 config.json 并填写您自己的会话凭据:

{
  "auth_token": "Basic YOUR_BASE64_SESSION_TOKEN_HERE",
  "user_id": "YOUR_32_CHAR_USER_ID_HEX",
  "device_key": "YOUR_DEVICE_KEY_UUID",
  "api_key": "c153b48e-d8a1-48a0-a40d-293f1dc5be0e",
  "app_secret": "ODc0MDE2M2EtNGY0MC00YmU2LTgwZDUtYjNlZjIxZGRkZjlj",
  "client_details": "clientType:WEB; appVersion:86.0.1",
  "device_type": "W",
  "accept_language": "en-US,en;q=0.9"
}

api_key / app_secret 是公共 Web 应用常量,不是机密。切勿提交或共享 config.json。环境变量(JIOCLOUD_AUTH_TOKEN、JIOCLOUD_USER_ID、JIOCLOUD_DEVICE_KEY)同样有效。

2. Python SDK

from jiocloud import JioCloudClient, format_bytes

client = JioCloudClient.from_config("config.json")

profile = client.get_user_profile()
q = profile.quota
print(f"{profile.name}: {q.total_used_gb:.1f}/{q.total_allocated_gb:.0f} GB")

# Stream every file in the account
for f in client.stream_all_files():
    print(f.object_name, f.human_size)

# Search everywhere, then download matches
for hit in client.search_files("invoice", filter_extension="pdf")[:5]:
    client.download_file(hit.object_key, f"./{hit.object_name}")

3. CLI

python cli.py info                 # account overview + usage bar
python cli.py list --limit 20      # list root files
python cli.py tree                 # recursive tree view
python cli.py search resume --ext pdf
python cli.py download <key> -d ./out/
python cli.py sync --dest ./backup --workers 6
python cli.py mkdir Reports
python cli.py rename <key> "new name.pdf"
python cli.py move <key> <folder-key>
python cli.py favorite <key>
python cli.py share <key>          # public link
python cli.py versions <key>       # version history
python cli.py recent               # recent activity feed
python cli.py boards list|create|members
python cli.py contacts             # address book summary
python cli.py promotions           # storage promos
python cli.py trash <key> / restore <key> / trash-list

4. AI 智能体集成

# Dump the 16-tool JSON schema into any LLM's tools parameter
python cli.py agent schema

# One-shot structured call (strict JSON envelope)
python cli.py agent call '{"tool":"search_files","arguments":{"query":"tax","extension":"pdf"}}'

# MCP-style stdio server loop for agent hosts
python cli.py agent serve

信封契约:

// request
{"tool": "<name>", "arguments": {...}}
// response — success
{"ok": true, "result": ...}
// response — failure (never a raw traceback)
{"ok": false, "error": {"type": "...", "message": "..."}}
// destructive tools (download_file, download_all, move_to_trash,
// restore_from_trash, share_link) REQUIRE arguments.confirm === true

参见 examples/06_agent_integration.py 和 ai/examples/agent-conversation.md。

5. 安装 AI 资产

助手操作此 SDK 所需的一切都已预构建在 ai/ 中:

资产

安装到

ai/skills/jio-cloud-manager/SKILL.md

Claude(作为技能/项目知识),或任何接受 Markdown 指令文档的助手

ai/tools/openai-function-schema.json

ChatGPT / 任何兼容 OpenAI 的主机:在 API 请求中传递 tools 数组

ai/tools/anthropic-tools.json

Claude API:作为 tools 数组传递

ai/prompts/system-prompt.txt

任何 LLM:将系统提示与工具模式一起粘贴

llms-full.txt

任何从 URL 获取上下文的智能体 — 完整文档在一个文件中

对于本地智能体,将 SDK 暴露为工具服务器:

python cli.py agent serve

然后将您的 MCP 风格主机配置为每次调用发送一行 JSON:{"tool": "...", "arguments": {...}},并读取一个严格的 JSON 信封作为响应。


验证

# Offline unit tests
python -m unittest discover -s tests

# FULL live matrix against production (requires config.json).
# Exercises every read endpoint plus a complete create→rename→favorite→
# trash→restore→trash cycle and a real small-file download.
python tests/live_verify.py

最新运行:26/26 通过,针对生产环境(2026-08-25)。


文档

站点:https://ns81000.github.io/jiocloud_client/


法律

  • LICENSE — MIT + 商标/非关联声明

  • DISCLAIMER.md — 按现状保修、责任限制、个人备份条款、隐私声明

  • LEGAL.md — 合规摘要与下架联系

摘要:独立的非官方工具 · 仅用于个人数据可移植性和教育 · 无保修 · 您有责任遵守 Jio 对您账户的条款 · 凭据绝不会离开您的机器,除非通过 TLS 发送到官方 *.jioaicloud.com 端点 · 零遥测。

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Provides file system operations (list, read, write, search) via MCP, enabling an AI agent to manage files through natural language.
    1,958 npm
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    A lightweight, stdio-based MCP server enabling AI assistants to perform local file system operations like reading, writing, searching, and executing commands.
    6,054 npm
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Stdio MCP server for sandboxed file access — read files, search content, safely edit with checksums, and manage file structure.
    68 npm
    ISC