@clix-so/clix-agent-skills 0.1.2 → 0.1.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/README.md +38 -17
- package/dist/bin/cli.js +26 -6
- package/dist/bin/commands/install.js +77 -5
- package/dist/bin/utils/mcp.js +321 -44
- package/package.json +8 -2
- package/skills/event-tracking/LICENSE.txt +203 -0
- package/skills/event-tracking/SKILL.md +126 -0
- package/skills/event-tracking/references/campaign-mapping.md +29 -0
- package/skills/event-tracking/references/debugging.md +30 -0
- package/skills/event-tracking/references/implementation-patterns.md +45 -0
- package/skills/event-tracking/references/naming-and-schema.md +67 -0
- package/skills/event-tracking/references/trackevent-contract.md +68 -0
- package/skills/event-tracking/scripts/validate-event-plan.sh +115 -0
- package/skills/integration/LICENSE.txt +2 -1
- package/skills/integration/SKILL.md +53 -1
- package/skills/user-management/LICENSE.txt +203 -0
- package/skills/user-management/SKILL.md +114 -0
- package/skills/user-management/references/debugging.md +29 -0
- package/skills/user-management/references/implementation-patterns.md +37 -0
- package/skills/user-management/references/logout-and-switching.md +32 -0
- package/skills/user-management/references/personalization-and-audience.md +34 -0
- package/skills/user-management/references/property-schema.md +65 -0
- package/skills/user-management/references/user-management-contract.md +56 -0
- package/skills/user-management/scripts/validate-user-plan.sh +92 -0
package/README.md
CHANGED
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
# Agent Skills for Clix
|
|
2
2
|
|
|
3
|
+
[](https://www.npmjs.com/package/@clix-so/clix-agent-skills)
|
|
4
|
+
[](https://www.npmjs.com/package/@clix-so/clix-agent-skills)
|
|
5
|
+
|
|
3
6
|
This repository contains a collection of **Agent Skills for Clix**. Each skill
|
|
4
7
|
is a self-contained package that can be loaded and executed by AI clients.
|
|
5
8
|
|
|
6
9
|
## Installing Skills
|
|
7
10
|
|
|
8
|
-
|
|
11
|
+
Agent skills in this repository are built on the
|
|
9
12
|
[open agent skills standard](https://agentskills.io/home). Please refer to the
|
|
10
|
-
[official documentation](https://agentskills.io/
|
|
11
|
-
|
|
12
|
-
skills in different ways.
|
|
13
|
+
[official documentation](https://agentskills.io/home#adoption) for up-to-date
|
|
14
|
+
information on supported AI clients. Depending on the AI client you are using, you
|
|
15
|
+
can install skills in different ways.
|
|
13
16
|
|
|
14
17
|
### Universal CLI (Recommended)
|
|
15
18
|
|
|
@@ -18,9 +21,24 @@ For **Cursor**, **VS Code**, **Claude Desktop**, **OpenCode**, **Goose**,
|
|
|
18
21
|
and configure the Clix MCP Server automatically:
|
|
19
22
|
|
|
20
23
|
```bash
|
|
21
|
-
|
|
24
|
+
# Install a specific skill
|
|
25
|
+
npx @clix-so/clix-agent-skills@latest install <skill-name> --client <your-client>
|
|
26
|
+
# For example, to install a skill on Cursor:
|
|
27
|
+
npx @clix-so/clix-agent-skills@latest install integration --client cursor
|
|
28
|
+
|
|
29
|
+
# Install all available skills at once
|
|
30
|
+
npx @clix-so/clix-agent-skills@latest install --all --client cursor
|
|
31
|
+
# This will install: integration, event-tracking, user-management
|
|
22
32
|
```
|
|
23
33
|
|
|
34
|
+
### Available Skills
|
|
35
|
+
|
|
36
|
+
- **clix-integration**: Integrate Clix Mobile SDK and MCP server setup
|
|
37
|
+
- **clix-event-tracking**: Implement `Clix.trackEvent` with naming/schema best
|
|
38
|
+
practices and campaign-ready validation
|
|
39
|
+
- **clix-user-management**: Implement `Clix.setUserId` + user properties with
|
|
40
|
+
logout best practices, personalization (`user.*`), and audience targeting
|
|
41
|
+
|
|
24
42
|
**Supported Clients:**
|
|
25
43
|
|
|
26
44
|
| Client | Flag | Default Path |
|
|
@@ -45,10 +63,10 @@ following command:
|
|
|
45
63
|
|
|
46
64
|
To install specific skills:
|
|
47
65
|
|
|
48
|
-
1.
|
|
49
|
-
2. Select `
|
|
66
|
+
1. Visit the Marketplace section in `/plugin`
|
|
67
|
+
2. Select `Browse plugins`
|
|
50
68
|
3. Choose the skills you wish to install
|
|
51
|
-
4.
|
|
69
|
+
4. Install skill
|
|
52
70
|
|
|
53
71
|
Alternatively, you can install a single skill directly by running:
|
|
54
72
|
|
|
@@ -56,6 +74,8 @@ Alternatively, you can install a single skill directly by running:
|
|
|
56
74
|
/plugin install <plugin-name>@<marketplace-name>
|
|
57
75
|
# For example
|
|
58
76
|
/plugin install clix-integration@clix-agent-skills
|
|
77
|
+
/plugin install clix-event-tracking@clix-agent-skills
|
|
78
|
+
/plugin install clix-user-management@clix-agent-skills
|
|
59
79
|
```
|
|
60
80
|
|
|
61
81
|
Remember to restart Claude Code after installation to load the new skills.
|
|
@@ -68,7 +88,9 @@ configuration directory:
|
|
|
68
88
|
|
|
69
89
|
Or install a specific skill using the command line:
|
|
70
90
|
|
|
71
|
-
```
|
|
91
|
+
```bash
|
|
92
|
+
$skill-installer install <link-to-skill-folder>
|
|
93
|
+
# For example
|
|
72
94
|
$skill-installer install https://github.com/clix-so/skills/tree/main/skills/integration
|
|
73
95
|
```
|
|
74
96
|
|
|
@@ -76,15 +98,14 @@ Ensure you restart Codex after installation to detect the new skills.
|
|
|
76
98
|
|
|
77
99
|
## Disclaimer
|
|
78
100
|
|
|
79
|
-
Please be aware that
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
checking their output before use. Use them with caution and supervision.
|
|
101
|
+
Please be aware that these skills may occasionally fail or execute incorrectly
|
|
102
|
+
due to the non-deterministic nature of AI. It is critical that you carefully
|
|
103
|
+
review and verify all actions performed by these skills. While they are designed
|
|
104
|
+
to be helpful, you remain responsible for checking their output before use.
|
|
105
|
+
Please use them with caution and supervision.
|
|
85
106
|
|
|
86
107
|
## License
|
|
87
108
|
|
|
88
109
|
Each skill in this repository is governed by its own license. For specific terms
|
|
89
|
-
and conditions, please consult the `LICENSE` file located within each
|
|
90
|
-
individual directory.
|
|
110
|
+
and conditions, please consult the `LICENSE.txt` file located within each
|
|
111
|
+
skill's individual directory.
|
package/dist/bin/cli.js
CHANGED
|
@@ -7,22 +7,42 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
7
7
|
const commander_1 = require("commander");
|
|
8
8
|
const chalk_1 = __importDefault(require("chalk"));
|
|
9
9
|
const install_1 = require("./commands/install");
|
|
10
|
+
const package_json_1 = require("../../package.json");
|
|
11
|
+
/**
|
|
12
|
+
* Extracts error message from unknown error type
|
|
13
|
+
*/
|
|
14
|
+
function getErrorMessage(error) {
|
|
15
|
+
if (error instanceof Error) {
|
|
16
|
+
return error.message;
|
|
17
|
+
}
|
|
18
|
+
return String(error);
|
|
19
|
+
}
|
|
10
20
|
const program = new commander_1.Command();
|
|
11
21
|
program
|
|
12
22
|
.name("clix-agent-skills")
|
|
13
23
|
.description("CLI to manage and install Clix Agent Skills")
|
|
14
|
-
.version(
|
|
24
|
+
.version(package_json_1.version);
|
|
15
25
|
program
|
|
16
|
-
.command("install
|
|
17
|
-
.description("Install
|
|
18
|
-
.option("-c, --client <client>", "Target AI client (cursor, claude, vscode, manual)")
|
|
26
|
+
.command("install [skill]")
|
|
27
|
+
.description("Install agent skill(s)")
|
|
28
|
+
.option("-c, --client <client>", "Target AI client (cursor, claude, vscode, amp, kiro, amazonq, codex, opencode, manual)")
|
|
19
29
|
.option("-p, --path <path>", "Custom installation path (default: .clix/skills)")
|
|
30
|
+
.option("-a, --all", "Install all available skills")
|
|
20
31
|
.action(async (skill, options) => {
|
|
21
32
|
try {
|
|
22
|
-
|
|
33
|
+
if (options.all) {
|
|
34
|
+
await (0, install_1.installAllSkills)(options);
|
|
35
|
+
}
|
|
36
|
+
else if (skill) {
|
|
37
|
+
await (0, install_1.installSkill)(skill, options);
|
|
38
|
+
}
|
|
39
|
+
else {
|
|
40
|
+
console.error(chalk_1.default.red("Error: Please specify a skill name or use --all flag"));
|
|
41
|
+
process.exit(1);
|
|
42
|
+
}
|
|
23
43
|
}
|
|
24
44
|
catch (error) {
|
|
25
|
-
console.error(chalk_1.default.red("Error installing skill:"), error
|
|
45
|
+
console.error(chalk_1.default.red("Error installing skill(s):"), getErrorMessage(error));
|
|
26
46
|
process.exit(1);
|
|
27
47
|
}
|
|
28
48
|
});
|
|
@@ -4,11 +4,21 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.installSkill = installSkill;
|
|
7
|
+
exports.installAllSkills = installAllSkills;
|
|
7
8
|
const path_1 = __importDefault(require("path"));
|
|
8
9
|
const fs_extra_1 = __importDefault(require("fs-extra"));
|
|
9
10
|
const chalk_1 = __importDefault(require("chalk"));
|
|
10
11
|
const ora_1 = __importDefault(require("ora"));
|
|
11
12
|
const mcp_1 = require("../utils/mcp");
|
|
13
|
+
/**
|
|
14
|
+
* Extracts error message from unknown error type
|
|
15
|
+
*/
|
|
16
|
+
function getErrorMessage(error) {
|
|
17
|
+
if (error instanceof Error) {
|
|
18
|
+
return error.message;
|
|
19
|
+
}
|
|
20
|
+
return String(error);
|
|
21
|
+
}
|
|
12
22
|
async function installSkill(skillName, options) {
|
|
13
23
|
const spinner = (0, ora_1.default)(`Installing skill: ${chalk_1.default.bold(skillName)}`).start();
|
|
14
24
|
// 1. Locate Skill in current package
|
|
@@ -80,6 +90,12 @@ async function installSkill(skillName, options) {
|
|
|
80
90
|
case "amp":
|
|
81
91
|
relativeDest = ".amp/skills";
|
|
82
92
|
break;
|
|
93
|
+
case "kiro":
|
|
94
|
+
relativeDest = ".kiro/skills";
|
|
95
|
+
break;
|
|
96
|
+
case "amazonq":
|
|
97
|
+
relativeDest = ".amazonq/skills";
|
|
98
|
+
break;
|
|
83
99
|
default:
|
|
84
100
|
relativeDest = options.client.startsWith(".") ? `${options.client}/skills` : `.clix/skills`;
|
|
85
101
|
}
|
|
@@ -91,18 +107,74 @@ async function installSkill(skillName, options) {
|
|
|
91
107
|
await fs_extra_1.default.copy(skillSourcePath, destPath);
|
|
92
108
|
spinner.succeed(`Skill files installed to ${chalk_1.default.green(relativeDest + "/" + skillName)}`);
|
|
93
109
|
}
|
|
94
|
-
catch (
|
|
95
|
-
spinner.fail(`Failed to copy skill files: ${
|
|
96
|
-
throw
|
|
110
|
+
catch (error) {
|
|
111
|
+
spinner.fail(`Failed to copy skill files: ${getErrorMessage(error)}`);
|
|
112
|
+
throw error;
|
|
97
113
|
}
|
|
98
114
|
// 4. MCP Configuration
|
|
99
115
|
try {
|
|
100
116
|
await (0, mcp_1.configureMCP)(options.client);
|
|
101
117
|
}
|
|
102
|
-
catch (
|
|
103
|
-
console.warn(chalk_1.default.yellow(`MCP Configuration warning: ${
|
|
118
|
+
catch (error) {
|
|
119
|
+
console.warn(chalk_1.default.yellow(`MCP Configuration warning: ${getErrorMessage(error)}`));
|
|
104
120
|
}
|
|
105
121
|
console.log(`\n${chalk_1.default.green("✔")} Skill ${chalk_1.default.bold(skillName)} is ready to use!`);
|
|
106
122
|
console.log(` - Docs: ${path_1.default.join(destPath, "SKILL.md")}`);
|
|
107
123
|
console.log(` - Instruct your agent to read these docs to start working.`);
|
|
108
124
|
}
|
|
125
|
+
/**
|
|
126
|
+
* Find all available skills in the skills directory
|
|
127
|
+
*/
|
|
128
|
+
async function findAllSkills() {
|
|
129
|
+
// Find package root (same logic as installSkill)
|
|
130
|
+
let packageRoot = __dirname;
|
|
131
|
+
while (!fs_extra_1.default.existsSync(path_1.default.join(packageRoot, "package.json"))) {
|
|
132
|
+
const parent = path_1.default.dirname(packageRoot);
|
|
133
|
+
if (parent === packageRoot) {
|
|
134
|
+
packageRoot = process.cwd();
|
|
135
|
+
break;
|
|
136
|
+
}
|
|
137
|
+
packageRoot = parent;
|
|
138
|
+
}
|
|
139
|
+
const skillsDir = path_1.default.join(packageRoot, "skills");
|
|
140
|
+
if (!fs_extra_1.default.existsSync(skillsDir)) {
|
|
141
|
+
return [];
|
|
142
|
+
}
|
|
143
|
+
const entries = await fs_extra_1.default.readdir(skillsDir, { withFileTypes: true });
|
|
144
|
+
return entries
|
|
145
|
+
.filter((entry) => entry.isDirectory())
|
|
146
|
+
.filter((entry) => fs_extra_1.default.existsSync(path_1.default.join(skillsDir, entry.name, "SKILL.md")))
|
|
147
|
+
.map((entry) => entry.name);
|
|
148
|
+
}
|
|
149
|
+
/**
|
|
150
|
+
* Install all available skills
|
|
151
|
+
*/
|
|
152
|
+
async function installAllSkills(options) {
|
|
153
|
+
const spinner = (0, ora_1.default)("Discovering available skills...").start();
|
|
154
|
+
const skills = await findAllSkills();
|
|
155
|
+
if (skills.length === 0) {
|
|
156
|
+
spinner.fail("No skills found to install.");
|
|
157
|
+
return;
|
|
158
|
+
}
|
|
159
|
+
spinner.succeed(`Found ${chalk_1.default.bold(skills.length)} skill(s): ${skills.join(", ")}`);
|
|
160
|
+
console.log();
|
|
161
|
+
let successCount = 0;
|
|
162
|
+
let failCount = 0;
|
|
163
|
+
for (const skillName of skills) {
|
|
164
|
+
try {
|
|
165
|
+
await installSkill(skillName, options);
|
|
166
|
+
successCount++;
|
|
167
|
+
}
|
|
168
|
+
catch (error) {
|
|
169
|
+
console.error(chalk_1.default.red(`\n✗ Failed to install ${chalk_1.default.bold(skillName)}: ${getErrorMessage(error)}`));
|
|
170
|
+
failCount++;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
console.log();
|
|
174
|
+
if (failCount === 0) {
|
|
175
|
+
console.log(chalk_1.default.green(`\n✔ Successfully installed all ${chalk_1.default.bold(successCount)} skill(s)!`));
|
|
176
|
+
}
|
|
177
|
+
else {
|
|
178
|
+
console.log(chalk_1.default.yellow(`\n⚠ Installed ${chalk_1.default.bold(successCount)} skill(s), ${chalk_1.default.bold(failCount)} failed.`));
|
|
179
|
+
}
|
|
180
|
+
}
|