From ba8dc417b6024229bc94aeae5616e7e0002dca56 Mon Sep 17 00:00:00 2001 From: skt Date: Sat, 29 Aug 2026 15:50:09 +0800 Subject: [PATCH 1/2] docs(drivers): add SJTU Netdisk docs --- pages/guide/drivers/sjtu_netdisk.md | 102 ++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 pages/guide/drivers/sjtu_netdisk.md diff --git a/pages/guide/drivers/sjtu_netdisk.md b/pages/guide/drivers/sjtu_netdisk.md new file mode 100644 index 000000000..dd7465ef2 --- /dev/null +++ b/pages/guide/drivers/sjtu_netdisk.md @@ -0,0 +1,102 @@ +--- +title: + en: SJTU Netdisk + zh-CN: 交大云盘 +icon: iconfont icon-state +# This control sidebar order +top: 687 +# A page can have multiple categories +categories: + - guide + - drivers +# A page can have multiple tags +tag: + - Storage + - Guide + - '302' +# this page is sticky in article list +sticky: true +# this page will appear in starred articles +star: true +--- + +**https://pan.sjtu.edu.cn** + +:::tip + +- 交大云盘默认使用 `302` 重定向方式下载。 +- 登录凭证可能会过期,建议开启 `Keep alive` 保持会话有效。 + +::: + +
+ +## **User token(用户令牌)** + +在浏览器中打开开发者调试工具(F12),切换到 **Network(网络)** 标签页并勾选 **Disable cache(禁用缓存)**。登录交大云盘后,找到携带认证信息的请求。可以搜索以下get请求: +``` +https://pan.sjtu.edu.cn/user/v1/user/1/?user_token=&with_belonging_teams... +``` +其中 `user_token` 便为需要的user_token。 + + +
+ +## **Keep alive(保持活动状态)** + +开启后,Openlist 会开启user_token保活。在上一节的请求中找到响应头 `Set-Cookie` + +``` +keepalive='; path=/; Httponly +``` + +复制其中的 `keep_alive` 的值并填入。注意不要复制整个,只复制尖括号内值代表的内容 + + +
+ +## **User id(用户ID)** + +在上方user token章节的请求中,找到get url中的``部分。 + +
+ +## **Order by(排序)** + +选择文件和文件夹的排序依据: + +- `名称` — 按文件/文件夹名称排序 +- `修改时间` — 按最后修改时间排序 +- `大小` — 按文件大小排序 + +
+ +## **Order by type(按类型排序)** + +选择排序方向: + +- `升序` — 升序 +- `降序` — 降序 + +
+ +### **默认使用的下载方式** + +```mermaid +--- +title: 默认使用哪种下载方式? +--- +flowchart TB + style a1 fill:#bbf,stroke:#f66,stroke-width:2px,color:#fff + style a2 fill:#ff7575,stroke:#333,stroke-width:4px + subgraph ide1 [ ] + a1 + end + a1[302]:::someclass====|默认|a2[用户设备] + classDef someclass fill:#f96 + c1[本地代理]-.备选.->a2[用户设备] + b1[下载代理 URL]-.备选.->a2[用户设备] + click a1 "../drivers/common.html#webdav-policy" + click b1 "../drivers/common.html#webdav-policy" + click c1 "../drivers/common.html#webdav-policy" +``` \ No newline at end of file From a2726eac96b4a5e4978f1c66663479c327373954 Mon Sep 17 00:00:00 2001 From: skt Date: Tue, 1 Sep 2026 12:54:58 +0800 Subject: [PATCH 2/2] docs(sjtu_netdisk): enhance documentation with format changes and i18n --- pages/guide/drivers/sjtu_netdisk.md | 141 ++++++++++++++++++++++------ 1 file changed, 110 insertions(+), 31 deletions(-) diff --git a/pages/guide/drivers/sjtu_netdisk.md b/pages/guide/drivers/sjtu_netdisk.md index dd7465ef2..b7cd064fc 100644 --- a/pages/guide/drivers/sjtu_netdisk.md +++ b/pages/guide/drivers/sjtu_netdisk.md @@ -20,71 +20,126 @@ sticky: true star: true --- -**https://pan.sjtu.edu.cn** +[https://pan.sjtu.edu.cn](https://pan.sjtu.edu.cn) -:::tip +::: en +::: tip + +- SJTU Netdisk uses `302` redirects for downloads by default. +- Login credentials may expire. Enable `Keep alive` to keep the session active. + +::: + +::: zh-CN +::: tip - 交大云盘默认使用 `302` 重定向方式下载。 - 登录凭证可能会过期,建议开启 `Keep alive` 保持会话有效。 ::: -
+## User Token { lang="en" } + +## 用户令牌 { lang="zh-CN" } -## **User token(用户令牌)** +::: en +Open your browser's developer tools (`F12`), select the **Network** tab, and enable **Disable cache**. After signing in to SJTU Netdisk, locate a request that contains authentication information. You can search for a `GET` request with a URL similar to: -在浏览器中打开开发者调试工具(F12),切换到 **Network(网络)** 标签页并勾选 **Disable cache(禁用缓存)**。登录交大云盘后,找到携带认证信息的请求。可以搜索以下get请求: +```text +https://pan.sjtu.edu.cn/user/v1/user/1/?user_token=&with_belonging_teams... ``` + +The value of the `user_token` query parameter is the value to enter in this field. +::: +::: zh-CN +在浏览器中打开开发者工具(`F12`),切换到 **Network(网络)** 标签页并勾选 **Disable cache(禁用缓存)**。登录交大云盘后,找到携带认证信息的请求。可以搜索类似以下 URL 的 `GET` 请求: + +```text https://pan.sjtu.edu.cn/user/v1/user/1/?user_token=&with_belonging_teams... ``` -其中 `user_token` 便为需要的user_token。 +其中 `user_token` 查询参数的值即为此字段需要填写的内容。 +::: -
+## Keep alive { lang="en" } -## **Keep alive(保持活动状态)** +## 保持活动状态 { lang="zh-CN" } -开启后,Openlist 会开启user_token保活。在上一节的请求中找到响应头 `Set-Cookie` +::: en +When enabled, OpenList keeps the `user_token` active. In the response headers of the request from the previous section, find `Set-Cookie`: +```text +keepalive='; path=/; Httponly ``` + +Copy only the value represented by `` and enter it in this field. Do not copy the entire cookie. +::: +::: zh-CN +开启后,OpenList 会保持 `user_token` 有效。在上一节请求的响应头中找到 `Set-Cookie`: + +```text keepalive='; path=/; Httponly ``` -复制其中的 `keep_alive` 的值并填入。注意不要复制整个,只复制尖括号内值代表的内容 +只复制 `` 所代表的值并填入此字段,不要复制整个 Cookie。 +::: +## User ID { lang="en" } + +## 用户 ID { lang="zh-CN" } + +::: en +In the request URL from the [User Token](#user-token) section, use the value represented by ``. +::: +::: zh-CN +在 [用户令牌](#用户令牌) 一节中的请求 URL 里,找到 `` 所代表的部分并填入。 +::: -
+## Order by { lang="en" } -## **User id(用户ID)** +## 排序依据 { lang="zh-CN" } -在上方user token章节的请求中,找到get url中的``部分。 +::: en +Choose the field used to sort files and folders: -
+- `Name`: Sort by file or folder name. +- `Modification time`: Sort by last modified time. +- `Size`: Sort by file size. + ::: + ::: zh-CN + 选择文件和文件夹的排序依据: -## **Order by(排序)** +- `名称`:按文件或文件夹名称排序。 +- `修改时间`:按最后修改时间排序。 +- `大小`:按文件大小排序。 + ::: -选择文件和文件夹的排序依据: +## Order by type { lang="en" } -- `名称` — 按文件/文件夹名称排序 -- `修改时间` — 按最后修改时间排序 -- `大小` — 按文件大小排序 +## 排序方向 { lang="zh-CN" } -
+::: en +Choose the sort direction: -## **Order by type(按类型排序)** +- `Ascending`: Ascending order. +- `Descending`: Descending order. + ::: + ::: zh-CN + 选择排序方向: -选择排序方向: +- `升序`:升序排列。 +- `降序`:降序排列。 + ::: -- `升序` — 升序 -- `降序` — 降序 +## The default download method used { lang="en" } -
+## 默认使用的下载方式 { lang="zh-CN" } -### **默认使用的下载方式** +::: en ```mermaid --- -title: 默认使用哪种下载方式? +title: Which download method is used by default? --- flowchart TB style a1 fill:#bbf,stroke:#f66,stroke-width:2px,color:#fff @@ -92,11 +147,35 @@ flowchart TB subgraph ide1 [ ] a1 end - a1[302]:::someclass====|默认|a2[用户设备] + a1[302]:::someclass====|default|a2[user equipment] classDef someclass fill:#f96 - c1[本地代理]-.备选.->a2[用户设备] - b1[下载代理 URL]-.备选.->a2[用户设备] + c1[local proxy]-.alternative.->a2[user equipment] + b1[Download proxy URL]-.alternative.->a2[user equipment] click a1 "../drivers/common.html#webdav-policy" click b1 "../drivers/common.html#webdav-policy" click c1 "../drivers/common.html#webdav-policy" -``` \ No newline at end of file +``` + +::: +::: zh-CN + +```mermaid +--- +title: 默认使用的哪种下载方式? +--- +flowchart TB + style a1 fill:#bbf,stroke:#f66,stroke-width:2px,color:#fff + style a2 fill:#ff7575,stroke:#333,stroke-width:4px + subgraph ide1 [ ] + a1 + end + a1[302]:::someclass====|默认|a2[用户设备] + classDef someclass fill:#f96 + c1[本机代理]-.备选.->a2[用户设备] + b1[代理 URL]-.备选.->a2[用户设备] + click a1 "../drivers/common.html#webdav-策略" + click b1 "../drivers/common.html#webdav-策略" + click c1 "../drivers/common.html#webdav-策略" +``` + +:::