@mo7yw4ng/openape-win32-x64 2.0.2 → 2.0.4
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.
- package/LICENSE +21 -0
- package/README.md +137 -0
- package/bin/mod.ts +1 -0
- package/bin/openape.exe +0 -0
- package/bin/skills/openape/SKILL.md +6 -0
- package/package.json +4 -2
- package/bin/mod.js +0 -1
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 MO7YW4NG
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
<h1 align="center">
|
|
2
|
+
<img src="assets/logo.svg" width="150" /><br/>
|
|
3
|
+
OpenApe CLI (Unofficial)<br/>
|
|
4
|
+
<a href="https://www.npmjs.com/package/@mo7yw4ng/openape"><img src="https://img.shields.io/npm/v/@mo7yw4ng/openape" alt="npm version" /></a>
|
|
5
|
+
<a href="https://www.npmjs.com/package/@mo7yw4ng/openape"><img src="https://img.shields.io/npm/dm/@mo7yw4ng/openape" alt="npm downloads" /></a>
|
|
6
|
+
</h1>
|
|
7
|
+
|
|
8
|
+
中原大學 [i-Learning](https://ilearning.cycu.edu.tw/) (Moodle) 平台自動化命令列工具 (CLI),幫助你快速查詢課程、觀看影片、下載教材。
|
|
9
|
+
|
|
10
|
+
## 功能特色
|
|
11
|
+
- 📚 **課程資訊**:列出修課清單、成績、課程大綱與進度。
|
|
12
|
+
- 📺 **影片輔助**:列出/下載影片,甚至自動標記為已觀看。
|
|
13
|
+
- 📝 **測驗與教材**:快速進行測驗、下載教材。
|
|
14
|
+
- 💬 **討論區與公告**:閱讀公告、討論區、發表回覆。
|
|
15
|
+
- 📅 **行事曆**:內建行事曆事件查詢與匯出。
|
|
16
|
+
- ✅ **作業繳交**:查詢作業、檢查繳交狀態、上傳檔案並繳交。
|
|
17
|
+
- 🤖 **Agent Skills**:提供 Claude Code 等 Skills 工作流支援。
|
|
18
|
+
|
|
19
|
+
## 安裝
|
|
20
|
+
|
|
21
|
+
透過 npm 安裝為全域指令(推薦,[Node.js](https://nodejs.org/) v18+):
|
|
22
|
+
```bash
|
|
23
|
+
npm install -g @mo7yw4ng/openape
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
或用 npx 單次執行(不需安裝):
|
|
27
|
+
```bash
|
|
28
|
+
npx @mo7yw4ng/openape --help
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## 核心指令
|
|
32
|
+
|
|
33
|
+
### 登入與驗證 (Authentication)
|
|
34
|
+
第一次使用需要登入,會開啟瀏覽器讓你手動完成登入,隨後會快取 Session 供未來使用。
|
|
35
|
+
```bash
|
|
36
|
+
openape login # 登入並儲存 session (開啟瀏覽器)
|
|
37
|
+
openape status # 檢查當前登入狀態
|
|
38
|
+
openape logout # 登出並清除 session
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### 課程 (Courses)
|
|
42
|
+
```bash
|
|
43
|
+
openape courses list # 列出所有課程 (支援 --incomplete-only, --level)
|
|
44
|
+
openape courses info <id> # 顯示特定課程的詳細資訊
|
|
45
|
+
openape courses progress <id> # 顯示特定課程的進度
|
|
46
|
+
openape courses syllabus <id> # 顯示課程大綱
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### 影片 (Videos)
|
|
50
|
+
```bash
|
|
51
|
+
openape videos list <course-id> # 列出課程中的影片
|
|
52
|
+
openape videos complete <id> # 標記特定影片為已觀看
|
|
53
|
+
openape videos complete-all # 影片批次完成
|
|
54
|
+
openape videos download <id> # 下載影片 (支援 --output-dir)
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### 測驗與教材 (Quizzes & Materials)
|
|
58
|
+
```bash
|
|
59
|
+
openape quizzes list <course-id> # 列出特定課程測驗
|
|
60
|
+
openape quizzes list-all # 列出所有課程測驗
|
|
61
|
+
openape quizzes start <quiz-id> # 開始測驗
|
|
62
|
+
openape quizzes info <attempt-id> # 查看測驗題目
|
|
63
|
+
openape quizzes save <attempt-id> '<answers>' # 儲存測驗答案
|
|
64
|
+
openape materials list-all # 列出所有可下載教材
|
|
65
|
+
openape materials download <id> # 下載指定教材 (支援 --output-dir)
|
|
66
|
+
openape materials download-all # 批次下載教材 (支援 --output-dir, --level)
|
|
67
|
+
openape materials complete <id> # 標記教材為已完成
|
|
68
|
+
openape materials complete-all # 批次標記教材為已完成
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
### 成績與其他查詢 (Grades, Forums, Calendar)
|
|
72
|
+
```bash
|
|
73
|
+
openape grades summary # 顯示學期成績總覽
|
|
74
|
+
openape grades course <id> # 顯示特定課程成績
|
|
75
|
+
openape forums list # 列出進行中課程的討論區
|
|
76
|
+
openape forums list-all # 列出所有討論區
|
|
77
|
+
openape forums discussions <forum-id> # 列出討論區中的討論串
|
|
78
|
+
openape forums posts <discussion-id> # 列出討論串中的貼文
|
|
79
|
+
openape forums reply <post-id> <subject> <message> # 回覆貼文 (支援 --attachment-id)
|
|
80
|
+
openape forums post <forum-id> <subject> <message> # 發起新討論
|
|
81
|
+
openape forums delete <post-id> # 刪除討論貼文
|
|
82
|
+
openape announcements list-all # 列出所有公告
|
|
83
|
+
openape announcements read <id> # 閱讀特定公告
|
|
84
|
+
openape calendar events # 查詢行事曆事件 (支援 --upcoming, --days, --course)
|
|
85
|
+
openape calendar export # 匯出事件 (支援 --output, --days)
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
### 作業與檔案上傳 (Assignments & Upload)
|
|
89
|
+
```bash
|
|
90
|
+
# 作業查詢與繳交
|
|
91
|
+
openape assignments list <course-id> # 列出課程作業
|
|
92
|
+
openape assignments list-all # 列出所有作業 (支援 --level all)
|
|
93
|
+
openape assignments status <assignment-id> # 檢查作業繳交狀態
|
|
94
|
+
openape assignments submit <assignment-id> # 繳交作業
|
|
95
|
+
--text "內容" # 線上文字繳交
|
|
96
|
+
--file-id <draft-id> # 使用已上傳的檔案 ID
|
|
97
|
+
--file <path> # 直接上傳檔案並繳交
|
|
98
|
+
|
|
99
|
+
# 檔案上傳至草稿區
|
|
100
|
+
openape upload file <path> # 上傳檔案取得 draft ID
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
### 頁面 (Pages)
|
|
104
|
+
```bash
|
|
105
|
+
openape pages list <course-id> # 列出課程頁面 (內容預覽前 150 字)
|
|
106
|
+
openape pages list-all # 列出所有課程頁面 (支援 --level)
|
|
107
|
+
openape pages show <cmid> # 顯示頁面完整內容
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
### Skills
|
|
111
|
+
讓你的 AI Agent 也可以控制 OpenApe。只需一個指令即可安裝:
|
|
112
|
+
```bash
|
|
113
|
+
openape skills install claude # 為 Claude Code 安裝技能 (支援 claude, codex, opencode)
|
|
114
|
+
openape skills install --all # 自動偵測環境並安裝給所有支援的 Agent
|
|
115
|
+
```
|
|
116
|
+
也可以透過 `npx skills` 安裝:
|
|
117
|
+
```bash
|
|
118
|
+
npx skills add mo7yw4ng/openape
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
## 開發
|
|
122
|
+
|
|
123
|
+
```bash
|
|
124
|
+
git clone https://github.com/mo7yw4ng/openape && cd openape
|
|
125
|
+
|
|
126
|
+
# 建置 (需安裝 Playwright 瀏覽器支援: Edge/Chrome/Brave)
|
|
127
|
+
cargo build
|
|
128
|
+
|
|
129
|
+
# 執行
|
|
130
|
+
cargo run -- --help
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
## 版權與授權
|
|
134
|
+
|
|
135
|
+
此專案之版權規範採用 **MIT License** - 至 [LICENSE](LICENSE) 查看更多相關聲明
|
|
136
|
+
|
|
137
|
+
> **免責聲明**:本工具為非官方開放原始碼專案,與中原大學官方無關。請斟酌使用腳本輔助功能,避免不當操作(如短時間發送大量請求修改系統狀態)而違反學術倫理或導致帳號遭封鎖。
|
package/bin/mod.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const version: string = "2.0.4";
|
package/bin/openape.exe
CHANGED
|
Binary file
|
|
@@ -93,6 +93,12 @@ openape <command> [subcommand] [args] [flags]
|
|
|
93
93
|
|
|
94
94
|
- `file <file-path>` — Upload a file to Moodle draft area
|
|
95
95
|
|
|
96
|
+
### pages — Page operations
|
|
97
|
+
|
|
98
|
+
- `list <course-id>` — List pages in a course (content preview, first 150 chars)
|
|
99
|
+
- `list-all` — List all pages across courses. Flags: `--level in_progress|all`
|
|
100
|
+
- `show <cmid>` — Show full content of a specific page
|
|
101
|
+
|
|
96
102
|
### skills — Skill management
|
|
97
103
|
|
|
98
104
|
- `install [platform]` — Install OpenApe skill to an agent platform (claude, codex, opencode)
|
package/package.json
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mo7yw4ng/openape-win32-x64",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.4",
|
|
4
4
|
"description": "openape binary for win32 x64",
|
|
5
5
|
"os": ["win32"],
|
|
6
6
|
"cpu": ["x64"],
|
|
7
7
|
"files": [
|
|
8
|
-
"bin/"
|
|
8
|
+
"bin/",
|
|
9
|
+
"README.md",
|
|
10
|
+
"LICENSE"
|
|
9
11
|
],
|
|
10
12
|
"repository": {
|
|
11
13
|
"type": "git",
|
package/bin/mod.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export const version = "2.0.2";
|