anchi-kit 1.2.0 → 1.2.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.
Files changed (80) hide show
  1. package/.antigravity/skills/article-extractor/SKILL.md +52 -0
  2. package/.antigravity/skills/artifacts-builder/SKILL.md +63 -0
  3. package/.antigravity/skills/aws-deployment/SKILL.md +85 -0
  4. package/.antigravity/skills/brainstorming/SKILL.md +73 -0
  5. package/.antigravity/skills/canvas-design/SKILL.md +62 -0
  6. package/.antigravity/skills/changelog-generator/SKILL.md +149 -0
  7. package/.antigravity/skills/changelog-generator/assets/changelog-template.md +60 -0
  8. package/.antigravity/skills/changelog-generator/scripts/generate-changelog.js +181 -0
  9. package/.antigravity/skills/claude-code/references/advanced-features.md +399 -0
  10. package/.antigravity/skills/claude-code/references/agent-skills.md +399 -0
  11. package/.antigravity/skills/claude-code/references/api-reference.md +498 -0
  12. package/.antigravity/skills/claude-code/references/best-practices.md +447 -0
  13. package/.antigravity/skills/claude-code/references/cicd-integration.md +428 -0
  14. package/.antigravity/skills/claude-code/references/common-workflows.md +119 -0
  15. package/.antigravity/skills/claude-code/references/configuration.md +480 -0
  16. package/.antigravity/skills/claude-code/references/enterprise-features.md +472 -0
  17. package/.antigravity/skills/claude-code/references/getting-started.md +252 -0
  18. package/.antigravity/skills/claude-code/references/hooks-and-plugins.md +444 -0
  19. package/.antigravity/skills/claude-code/references/hooks-comprehensive.md +622 -0
  20. package/.antigravity/skills/claude-code/references/ide-integration.md +316 -0
  21. package/.antigravity/skills/claude-code/references/mcp-integration.md +386 -0
  22. package/.antigravity/skills/claude-code/references/slash-commands.md +489 -0
  23. package/.antigravity/skills/claude-code/references/troubleshooting.md +456 -0
  24. package/.antigravity/skills/claude-code/skill.md +60 -0
  25. package/.antigravity/skills/code-quality/SKILL.md +273 -0
  26. package/.antigravity/skills/comprehensive-review/complexity.md +11 -0
  27. package/.antigravity/skills/comprehensive-review/index.yaml +19 -0
  28. package/.antigravity/skills/comprehensive-review/maintainability.md +12 -0
  29. package/.antigravity/skills/comprehensive-review/readability.md +12 -0
  30. package/.antigravity/skills/content-research-writer/SKILL.md +65 -0
  31. package/.antigravity/skills/csv-data-analyzer/SKILL.md +91 -0
  32. package/.antigravity/skills/d3-visualization/SKILL.md +65 -0
  33. package/.antigravity/skills/debugging/references/root-cause-analysis-methods.md +140 -0
  34. package/.antigravity/skills/engineering-discipline/incremental-change.md +15 -0
  35. package/.antigravity/skills/engineering-discipline/index.yaml +30 -0
  36. package/.antigravity/skills/engineering-discipline/planning-first.md +18 -0
  37. package/.antigravity/skills/engineering-discipline/reasoning-clarity.md +19 -0
  38. package/.antigravity/skills/engineering-discipline/verify-before-commit.md +17 -0
  39. package/.antigravity/skills/file-organizer/SKILL.md +64 -0
  40. package/.antigravity/skills/git-automation/SKILL.md +68 -0
  41. package/.antigravity/skills/git-automation/references/branch-finishing.md +64 -0
  42. package/.antigravity/skills/impact-scoring/SKILL.md +219 -0
  43. package/.antigravity/skills/kaizen/SKILL.md +94 -0
  44. package/.antigravity/skills/performance-patterns/SKILL.md +209 -0
  45. package/.antigravity/skills/playwright-testing/SKILL.md +115 -0
  46. package/.antigravity/skills/playwright-testing/references/playwright-patterns.md +122 -0
  47. package/.antigravity/skills/prompt-engineering/SKILL.md +126 -0
  48. package/.antigravity/skills/prompt-engineering/references/anthropic-best-practices.md +160 -0
  49. package/.antigravity/skills/pypict-testing/SKILL.md +79 -0
  50. package/.antigravity/skills/review-implementing/SKILL.md +287 -0
  51. package/.antigravity/skills/security-audit/SKILL.md +263 -0
  52. package/.antigravity/skills/software-architecture/SKILL.md +91 -0
  53. package/.antigravity/skills/software-architecture/references/solid-principles.md +293 -0
  54. package/.antigravity/skills/subagent-driven-development/SKILL.md +237 -0
  55. package/.antigravity/skills/test-driven-development/SKILL.md +130 -0
  56. package/.antigravity/skills/test-driven-development/references/tdd-patterns.md +124 -0
  57. package/.antigravity/skills/test-driven-development/references/testing-strategies.md +131 -0
  58. package/.antigravity/skills/test-fixing/SKILL.md +256 -0
  59. package/.antigravity/skills/theme-factory/SKILL.md +63 -0
  60. package/.antigravity/workflows/clean.md +333 -0
  61. package/.antigravity/workflows/health.md +228 -0
  62. package/.cursor/skills/_packs/common/pack-architecture.md +40 -0
  63. package/.cursor/skills/_packs/common/pack-devops.md +43 -0
  64. package/.cursor/skills/_packs/common/pack-productivity.md +37 -0
  65. package/.cursor/skills/_packs/common/pack-quality.md +41 -0
  66. package/.cursor/skills/_packs/data/pack-ai.md +41 -0
  67. package/.cursor/skills/_packs/data/pack-data-science.md +36 -0
  68. package/.cursor/skills/_packs/mobile/pack-mobile.md +40 -0
  69. package/.cursor/skills/_packs/web/pack-backend.md +61 -0
  70. package/.cursor/skills/_packs/web/pack-frontend.md +66 -0
  71. package/.cursor/skills/_packs/web3/pack-blockchain.md +37 -0
  72. package/.cursor/skills/advanced-coding/references/getting-started.md +93 -0
  73. package/.cursor/skills/advanced-coding/skill.md +34 -0
  74. package/.cursor/skills/template-skill/SKILL.md +6 -0
  75. package/README.md +1 -1
  76. package/docs/reference/SECURITY.md +1 -1
  77. package/package.json +2 -2
  78. package/src/cli.js +5 -5
  79. package/src/commands/dashboard.js +3 -3
  80. package/src/commands/init.js +15 -3
@@ -0,0 +1,498 @@
1
+ # API Reference
2
+
3
+ API endpoints and programmatic access to Cursor functionality.
4
+
5
+ ## Admin API
6
+
7
+ ### Usage Reports
8
+
9
+ **Get Cursor Usage Report:**
10
+ ```bash
11
+ GET /v1/admin/claude-code/usage
12
+ ```
13
+
14
+ **Query parameters:**
15
+ - `start_date`: Start date (YYYY-MM-DD)
16
+ - `end_date`: End date (YYYY-MM-DD)
17
+ - `user_id`: Filter by user
18
+ - `workspace_id`: Filter by workspace
19
+
20
+ **Response:**
21
+ ```json
22
+ {
23
+ "usage": [
24
+ {
25
+ "date": "2025-11-06",
26
+ "user_id": "user-123",
27
+ "requests": 150,
28
+ "tokens": 45000,
29
+ "cost": 12.50
30
+ }
31
+ ]
32
+ }
33
+ ```
34
+
35
+ **Example:**
36
+ ```bash
37
+ curl https://api.anthropic.com/v1/admin/claude-code/usage \
38
+ -H "x-api-key: $ANTHROPIC_API_KEY" \
39
+ -H "anthropic-version: 2023-06-01" \
40
+ -d start_date=2025-11-01 \
41
+ -d end_date=2025-11-06
42
+ ```
43
+
44
+ ### Cost Reports
45
+
46
+ **Get Cost Report:**
47
+ ```bash
48
+ GET /v1/admin/usage/cost
49
+ ```
50
+
51
+ **Query parameters:**
52
+ - `start_date`: Start date
53
+ - `end_date`: End date
54
+ - `group_by`: `user` | `project` | `model`
55
+
56
+ **Response:**
57
+ ```json
58
+ {
59
+ "costs": [
60
+ {
61
+ "group": "user-123",
62
+ "input_tokens": 100000,
63
+ "output_tokens": 50000,
64
+ "cost": 25.00
65
+ }
66
+ ],
67
+ "total": 250.00
68
+ }
69
+ ```
70
+
71
+ ### User Management
72
+
73
+ **List Users:**
74
+ ```bash
75
+ GET /v1/admin/users
76
+ ```
77
+
78
+ **Get User:**
79
+ ```bash
80
+ GET /v1/admin/users/{user_id}
81
+ ```
82
+
83
+ **Update User:**
84
+ ```bash
85
+ PATCH /v1/admin/users/{user_id}
86
+ ```
87
+
88
+ **Remove User:**
89
+ ```bash
90
+ DELETE /v1/admin/users/{user_id}
91
+ ```
92
+
93
+ ## Messages API
94
+
95
+ ### Create Message
96
+
97
+ **Endpoint:**
98
+ ```bash
99
+ POST /v1/messages
100
+ ```
101
+
102
+ **Request:**
103
+ ```json
104
+ {
105
+ "model": "claude-sonnet-4-5-20250929",
106
+ "max_tokens": 4096,
107
+ "messages": [
108
+ {
109
+ "role": "user",
110
+ "content": "Explain this code"
111
+ }
112
+ ]
113
+ }
114
+ ```
115
+
116
+ **With Skills:**
117
+ ```json
118
+ {
119
+ "model": "claude-sonnet-4-5-20250929",
120
+ "max_tokens": 4096,
121
+ "skills": [
122
+ {
123
+ "type": "custom",
124
+ "custom": {
125
+ "name": "code-reviewer",
126
+ "description": "Reviews code quality",
127
+ "instructions": "Check for bugs, security issues..."
128
+ }
129
+ }
130
+ ],
131
+ "messages": [...]
132
+ }
133
+ ```
134
+
135
+ **Response:**
136
+ ```json
137
+ {
138
+ "id": "msg_123",
139
+ "type": "message",
140
+ "role": "assistant",
141
+ "content": [
142
+ {
143
+ "type": "text",
144
+ "text": "This code implements..."
145
+ }
146
+ ],
147
+ "usage": {
148
+ "input_tokens": 100,
149
+ "output_tokens": 200
150
+ }
151
+ }
152
+ ```
153
+
154
+ ### Stream Messages
155
+
156
+ **Streaming response:**
157
+ ```json
158
+ {
159
+ "model": "claude-sonnet-4-5-20250929",
160
+ "max_tokens": 4096,
161
+ "stream": true,
162
+ "messages": [...]
163
+ }
164
+ ```
165
+
166
+ **Server-sent events:**
167
+ ```
168
+ event: message_start
169
+ data: {"type":"message_start","message":{...}}
170
+
171
+ event: content_block_delta
172
+ data: {"type":"content_block_delta","delta":{"text":"Hello"}}
173
+
174
+ event: message_stop
175
+ data: {"type":"message_stop"}
176
+ ```
177
+
178
+ ### Count Tokens
179
+
180
+ **Endpoint:**
181
+ ```bash
182
+ POST /v1/messages/count_tokens
183
+ ```
184
+
185
+ **Request:**
186
+ ```json
187
+ {
188
+ "model": "claude-sonnet-4-5-20250929",
189
+ "messages": [
190
+ {
191
+ "role": "user",
192
+ "content": "Count these tokens"
193
+ }
194
+ ]
195
+ }
196
+ ```
197
+
198
+ **Response:**
199
+ ```json
200
+ {
201
+ "input_tokens": 15
202
+ }
203
+ ```
204
+
205
+ ## Files API
206
+
207
+ ### Upload File
208
+
209
+ **Endpoint:**
210
+ ```bash
211
+ POST /v1/files
212
+ ```
213
+
214
+ **Request (multipart/form-data):**
215
+ ```bash
216
+ curl https://api.anthropic.com/v1/files \
217
+ -H "x-api-key: $ANTHROPIC_API_KEY" \
218
+ -F file=@document.pdf \
219
+ -F purpose=user_upload
220
+ ```
221
+
222
+ **Response:**
223
+ ```json
224
+ {
225
+ "id": "file-123",
226
+ "object": "file",
227
+ "bytes": 12345,
228
+ "created_at": 1699564800,
229
+ "filename": "document.pdf",
230
+ "purpose": "user_upload"
231
+ }
232
+ ```
233
+
234
+ ### List Files
235
+
236
+ **Endpoint:**
237
+ ```bash
238
+ GET /v1/files
239
+ ```
240
+
241
+ **Response:**
242
+ ```json
243
+ {
244
+ "data": [
245
+ {
246
+ "id": "file-123",
247
+ "filename": "document.pdf",
248
+ "bytes": 12345
249
+ }
250
+ ]
251
+ }
252
+ ```
253
+
254
+ ### Download File
255
+
256
+ **Endpoint:**
257
+ ```bash
258
+ GET /v1/files/{file_id}/content
259
+ ```
260
+
261
+ ### Delete File
262
+
263
+ **Endpoint:**
264
+ ```bash
265
+ DELETE /v1/files/{file_id}
266
+ ```
267
+
268
+ ## Models API
269
+
270
+ ### List Models
271
+
272
+ **Endpoint:**
273
+ ```bash
274
+ GET /v1/models
275
+ ```
276
+
277
+ **Response:**
278
+ ```json
279
+ {
280
+ "data": [
281
+ {
282
+ "id": "claude-sonnet-4-5-20250929",
283
+ "type": "model",
284
+ "display_name": "Claude Sonnet 4.5"
285
+ }
286
+ ]
287
+ }
288
+ ```
289
+
290
+ ### Get Model
291
+
292
+ **Endpoint:**
293
+ ```bash
294
+ GET /v1/models/{model_id}
295
+ ```
296
+
297
+ **Response:**
298
+ ```json
299
+ {
300
+ "id": "claude-sonnet-4-5-20250929",
301
+ "type": "model",
302
+ "display_name": "Claude Sonnet 4.5",
303
+ "created_at": 1699564800
304
+ }
305
+ ```
306
+
307
+ ## Skills API
308
+
309
+ ### Create Skill
310
+
311
+ **Endpoint:**
312
+ ```bash
313
+ POST /v1/skills
314
+ ```
315
+
316
+ **Request:**
317
+ ```json
318
+ {
319
+ "name": "my-skill",
320
+ "description": "Skill description",
321
+ "instructions": "Detailed instructions...",
322
+ "version": "1.0.0"
323
+ }
324
+ ```
325
+
326
+ ### List Skills
327
+
328
+ **Endpoint:**
329
+ ```bash
330
+ GET /v1/skills
331
+ ```
332
+
333
+ **Response:**
334
+ ```json
335
+ {
336
+ "data": [
337
+ {
338
+ "id": "skill-123",
339
+ "name": "my-skill",
340
+ "description": "Skill description"
341
+ }
342
+ ]
343
+ }
344
+ ```
345
+
346
+ ### Update Skill
347
+
348
+ **Endpoint:**
349
+ ```bash
350
+ PATCH /v1/skills/{skill_id}
351
+ ```
352
+
353
+ **Request:**
354
+ ```json
355
+ {
356
+ "description": "Updated description",
357
+ "instructions": "Updated instructions..."
358
+ }
359
+ ```
360
+
361
+ ### Delete Skill
362
+
363
+ **Endpoint:**
364
+ ```bash
365
+ DELETE /v1/skills/{skill_id}
366
+ ```
367
+
368
+ ## Client SDKs
369
+
370
+ ### TypeScript/JavaScript
371
+
372
+ ```typescript
373
+ import Anthropic from '@anthropic-ai/sdk';
374
+
375
+ const client = new Anthropic({
376
+ apiKey: process.env.ANTHROPIC_API_KEY
377
+ });
378
+
379
+ const message = await client.messages.create({
380
+ model: 'claude-sonnet-4-5-20250929',
381
+ max_tokens: 1024,
382
+ messages: [
383
+ { role: 'user', content: 'Hello, Claude!' }
384
+ ]
385
+ });
386
+
387
+ console.log(message.content);
388
+ ```
389
+
390
+ ### Python
391
+
392
+ ```python
393
+ import anthropic
394
+
395
+ client = anthropic.Anthropic(
396
+ api_key=os.environ.get("ANTHROPIC_API_KEY")
397
+ )
398
+
399
+ message = client.messages.create(
400
+ model="claude-sonnet-4-5-20250929",
401
+ max_tokens=1024,
402
+ messages=[
403
+ {"role": "user", "content": "Hello, Claude!"}
404
+ ]
405
+ )
406
+
407
+ print(message.content)
408
+ ```
409
+
410
+ ## Error Handling
411
+
412
+ ### Error Response Format
413
+
414
+ ```json
415
+ {
416
+ "type": "error",
417
+ "error": {
418
+ "type": "invalid_request_error",
419
+ "message": "Invalid API key"
420
+ }
421
+ }
422
+ ```
423
+
424
+ ### Error Types
425
+
426
+ **invalid_request_error**: Invalid request parameters
427
+ **authentication_error**: Invalid API key
428
+ **permission_error**: Insufficient permissions
429
+ **not_found_error**: Resource not found
430
+ **rate_limit_error**: Rate limit exceeded
431
+ **api_error**: Internal API error
432
+ **overloaded_error**: Server overloaded
433
+
434
+ ### Retry Logic
435
+
436
+ ```typescript
437
+ async function withRetry(fn: () => Promise<any>, maxRetries = 3) {
438
+ for (let i = 0; i < maxRetries; i++) {
439
+ try {
440
+ return await fn();
441
+ } catch (error) {
442
+ if (error.status === 529 && i < maxRetries - 1) {
443
+ await new Promise(r => setTimeout(r, 1000 * (i + 1)));
444
+ continue;
445
+ }
446
+ throw error;
447
+ }
448
+ }
449
+ }
450
+ ```
451
+
452
+ ## Rate Limits
453
+
454
+ ### Headers
455
+
456
+ Response headers include rate limit info:
457
+ ```
458
+ anthropic-ratelimit-requests-limit: 1000
459
+ anthropic-ratelimit-requests-remaining: 999
460
+ anthropic-ratelimit-requests-reset: 2025-11-06T12:00:00Z
461
+ anthropic-ratelimit-tokens-limit: 100000
462
+ anthropic-ratelimit-tokens-remaining: 99500
463
+ anthropic-ratelimit-tokens-reset: 2025-11-06T12:00:00Z
464
+ ```
465
+
466
+ ### Best Practices
467
+
468
+ - Monitor rate limit headers
469
+ - Implement exponential backoff
470
+ - Batch requests when possible
471
+ - Use caching to reduce requests
472
+
473
+ ## Authentication
474
+
475
+ ### API Key
476
+
477
+ Include API key in requests:
478
+ ```bash
479
+ curl https://api.anthropic.com/v1/messages \
480
+ -H "x-api-key: $ANTHROPIC_API_KEY" \
481
+ -H "anthropic-version: 2023-06-01"
482
+ ```
483
+
484
+ ### Workspace Keys
485
+
486
+ For organization workspaces:
487
+ ```bash
488
+ curl https://api.anthropic.com/v1/messages \
489
+ -H "x-api-key: $WORKSPACE_API_KEY" \
490
+ -H "anthropic-version: 2023-06-01"
491
+ ```
492
+
493
+ ## See Also
494
+
495
+ - API documentation: https://docs.anthropic.com/api
496
+ - Client SDKs: https://docs.anthropic.com/api/client-sdks
497
+ - Rate limits: https://docs.anthropic.com/api/rate-limits
498
+ - Error handling: https://docs.anthropic.com/api/errors