@lukeguo12210/canvas-cli 0.0.1

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.
@@ -0,0 +1,46 @@
1
+ # Canvas Output Reference
2
+
3
+ Default output is JSON.
4
+
5
+ All command results should use this shape:
6
+
7
+ ```json
8
+ {
9
+ "ok": true,
10
+ "data": {},
11
+ "meta": {
12
+ "request": {
13
+ "method": "GET",
14
+ "path": "/api/v1/courses"
15
+ }
16
+ }
17
+ }
18
+ ```
19
+
20
+ Errors use:
21
+
22
+ ```json
23
+ {
24
+ "ok": false,
25
+ "error": {
26
+ "code": "NO_AUTH_CONFIG",
27
+ "message": "No Canvas auth config found. Run canvas auth login.",
28
+ "retryable": false
29
+ }
30
+ }
31
+ ```
32
+
33
+ ## Formats
34
+
35
+ ```bash
36
+ --format json # default, best for agents
37
+ --format pretty # compact human display
38
+ --format table # simple list display
39
+ --format ndjson # batch/streaming workflows
40
+ ```
41
+
42
+ Use JSON for reasoning and tool chaining. Use pretty only when the user wants a readable summary.
43
+
44
+ ## Redaction
45
+
46
+ The CLI redacts token-like values from output. Agents must still avoid asking users to paste tokens into chat.
@@ -0,0 +1,24 @@
1
+ # Canvas Pagination Reference
2
+
3
+ Canvas list endpoints can be paginated.
4
+
5
+ Use:
6
+
7
+ ```bash
8
+ canvas courses list --active --page-all --format json
9
+ ```
10
+
11
+ General flags:
12
+
13
+ ```bash
14
+ --page-all
15
+ --page-limit <n>
16
+ --page-size <n>
17
+ --page-delay <ms>
18
+ ```
19
+
20
+ Important rule:
21
+
22
+ Canvas pagination follows HTTP `Link` headers. Do not synthesize next-page URLs manually.
23
+
24
+ When completeness matters, use `--page-all`. For quick exploratory commands, one page may be enough.