@cachly-dev/mcp-server 0.9.19 โ†’ 0.9.21

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 (39) hide show
  1. package/.github/workflows/publish.yml +42 -0
  2. package/LICENSE +202 -0
  3. package/dist/handlers/advanced.d.ts +6 -0
  4. package/dist/handlers/advanced.js +586 -0
  5. package/dist/handlers/advanced.js.map +1 -0
  6. package/dist/handlers/cache.d.ts +6 -0
  7. package/dist/handlers/cache.js +520 -0
  8. package/dist/handlers/cache.js.map +1 -0
  9. package/dist/handlers/context.d.ts +6 -0
  10. package/dist/handlers/context.js +177 -0
  11. package/dist/handlers/context.js.map +1 -0
  12. package/dist/handlers/fedbrain.d.ts +6 -0
  13. package/dist/handlers/fedbrain.js +1078 -0
  14. package/dist/handlers/fedbrain.js.map +1 -0
  15. package/dist/handlers/instances.d.ts +9 -0
  16. package/dist/handlers/instances.js +153 -0
  17. package/dist/handlers/instances.js.map +1 -0
  18. package/dist/handlers/roadmap.d.ts +6 -0
  19. package/dist/handlers/roadmap.js +165 -0
  20. package/dist/handlers/roadmap.js.map +1 -0
  21. package/dist/handlers/syndicate.d.ts +6 -0
  22. package/dist/handlers/syndicate.js +339 -0
  23. package/dist/handlers/syndicate.js.map +1 -0
  24. package/dist/handlers/team.d.ts +6 -0
  25. package/dist/handlers/team.js +1048 -0
  26. package/dist/handlers/team.js.map +1 -0
  27. package/dist/index.js +38 -4018
  28. package/dist/index.js.map +1 -1
  29. package/glama.json +6 -0
  30. package/package.json +1 -1
  31. package/src/handlers/advanced.ts +637 -0
  32. package/src/handlers/cache.ts +634 -0
  33. package/src/handlers/context.ts +218 -0
  34. package/src/handlers/fedbrain.ts +1143 -0
  35. package/src/handlers/instances.ts +180 -0
  36. package/src/handlers/roadmap.ts +192 -0
  37. package/src/handlers/syndicate.ts +451 -0
  38. package/src/handlers/team.ts +1163 -0
  39. package/src/index.ts +44 -4465
@@ -0,0 +1,180 @@
1
+ import type { Redis } from 'ioredis';
2
+ import type { Instance } from './brain.js';
3
+
4
+ interface CreateResponse {
5
+ instance_id: string;
6
+ checkout_url?: string;
7
+ status: string;
8
+ }
9
+
10
+ type GetConnection = (instanceId: string) => Promise<Redis>;
11
+ type ApiFetch = <T>(path: string, options?: RequestInit) => Promise<T>;
12
+
13
+ export const INSTANCE_TOOL_NAMES = new Set([
14
+ 'list_instances', 'create_instance', 'get_instance', 'get_connection_string', 'delete_instance',
15
+ 'list_orgs', 'create_org', 'invite_member', 'get_org_plan',
16
+ ]);
17
+
18
+ function formatInstance(inst: Instance): string {
19
+ const badge = inst.status === 'running' ? '๐ŸŸข' : inst.status === 'provisioning' ? '๐ŸŸก' : '๐Ÿ”ด';
20
+ const mb = inst.memory_mb >= 1024 ? `${inst.memory_mb / 1024}GB` : `${inst.memory_mb}MB`;
21
+ return `${badge} **${inst.name}** (\`${inst.id}\`) ยท ${inst.tier} ยท ${mb} ยท ${inst.region}`;
22
+ }
23
+
24
+ function buildConnectionString(inst: Instance): string {
25
+ if (!inst.host) return 'โŒ Instance not ready yet.';
26
+ const proto = inst.tls_enabled ? 'rediss' : 'redis';
27
+ const auth = inst.password ? `:${inst.password}@` : '';
28
+ return `${proto}://${auth}${inst.host}:${inst.port ?? 6379}`;
29
+ }
30
+
31
+ export async function handleInstanceTool(
32
+ name: string,
33
+ args: Record<string, unknown>,
34
+ getConnection: GetConnection,
35
+ apiFetch: ApiFetch,
36
+ ): Promise<string | null> {
37
+ switch (name) {
38
+ case 'list_instances': {
39
+ const res = await apiFetch<{ data: Instance[] }>('/api/v1/instances');
40
+ const instances = res.data ?? [];
41
+ if (instances.length === 0)
42
+ return 'You have no cache instances yet. Use `create_instance` to create one.';
43
+ return [`Found ${instances.length} instance(s):\n`, ...instances.map(formatInstance)].join('\n');
44
+ }
45
+
46
+ case 'create_instance': {
47
+ const { name: instName, tier } = args as { name: string; tier: string };
48
+ const res = await apiFetch<CreateResponse>('/api/v1/instances', {
49
+ method: 'POST',
50
+ body: JSON.stringify({ name: instName, tier, created_via: 'api' }),
51
+ });
52
+ if (res.checkout_url) {
53
+ return [
54
+ `โœ… Instance **${instName}** (${tier}) created! ID: \`${res.instance_id}\``,
55
+ ``,
56
+ `๐Ÿ’ณ This is a paid tier. Complete payment to activate:`,
57
+ ` ${res.checkout_url}`,
58
+ ``,
59
+ `After payment, provisioning starts automatically (~30 seconds).`,
60
+ ].join('\n');
61
+ }
62
+ return [
63
+ `โœ… Instance **${instName}** (${tier}) created and provisioning started!`,
64
+ ` ID: \`${res.instance_id}\``,
65
+ ` Status: ${res.status}`,
66
+ ``,
67
+ `Use \`get_instance\` or \`get_connection_string\` to get your connection details.`,
68
+ ].join('\n');
69
+ }
70
+
71
+ case 'get_instance': {
72
+ const inst = await apiFetch<Instance>(`/api/v1/instances/${(args as { instance_id: string }).instance_id}`);
73
+ return formatInstance(inst);
74
+ }
75
+
76
+ case 'get_connection_string': {
77
+ const inst = await apiFetch<Instance>(`/api/v1/instances/${(args as { instance_id: string }).instance_id}`);
78
+ if (inst.status !== 'running') {
79
+ return `Instance is not running yet (status: ${inst.status}). Provisioning takes ~30 seconds after payment.`;
80
+ }
81
+ const connStr = buildConnectionString(inst);
82
+ return [
83
+ `**Connection string for ${inst.name}:**`,
84
+ `\`\`\``,
85
+ connStr,
86
+ `\`\`\``,
87
+ ``,
88
+ `**Environment variable:**`,
89
+ `\`\`\`bash`,
90
+ `REDIS_URL="${connStr}"`,
91
+ `CACHLY_URL="${connStr}"`,
92
+ `\`\`\``,
93
+ ``,
94
+ `**Quick test:**`,
95
+ `\`\`\`bash`,
96
+ `redis-cli -u "${connStr}" PING`,
97
+ `\`\`\``,
98
+ ].join('\n');
99
+ }
100
+
101
+ case 'delete_instance': {
102
+ const { instance_id, confirm } = args as { instance_id: string; confirm: boolean };
103
+ if (!confirm) return 'Deletion cancelled. Set `confirm: true` to proceed.';
104
+ // Clean up cached connection (best-effort; connection times out otherwise)
105
+ try { (getConnection as unknown as { _pool?: Map<string, unknown> })._pool?.delete?.(instance_id); } catch { /* ignore */ }
106
+ await apiFetch(`/api/v1/instances/${instance_id}`, { method: 'DELETE' });
107
+ return `โœ… Instance \`${instance_id}\` has been deleted and all data removed.`;
108
+ }
109
+
110
+ // โ”€โ”€ Org / Team management โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
111
+ case 'list_orgs': {
112
+ const res = await apiFetch<{ orgs: Array<{ id: string; name: string; slug: string; plan: string; max_members: number; member_count?: number }> }>('/api/v1/orgs');
113
+ const orgs = res.orgs ?? [];
114
+ if (orgs.length === 0) return `๐Ÿ“ญ No organizations yet.\n\nCreate one with \`create_org(name="My Team")\`.\nOrg plans: Team โ‚ฌ99/mo (10 seats), Business โ‚ฌ299/mo (50 seats), Enterprise custom.`;
115
+ return [
116
+ `๐Ÿข **Your organizations (${orgs.length})**\n`,
117
+ ...orgs.map(o => `โ€ข **${o.name}** (\`${o.slug}\`) โ€” plan: ${o.plan} ยท seats: ${o.member_count ?? '?'}/${o.max_members}\n ID: \`${o.id}\``),
118
+ `\n_Manage: \`get_org_plan\`, \`invite_member\`, dashboard โ†’ /team_`,
119
+ ].join('\n');
120
+ }
121
+
122
+ case 'create_org': {
123
+ const { name: orgName, slug } = args as { name: string; slug?: string };
124
+ const body: Record<string, string> = { name: orgName };
125
+ if (slug) body.slug = slug;
126
+ const res = await apiFetch<{ id: string; name: string; slug: string; plan: string }>('/api/v1/orgs', {
127
+ method: 'POST',
128
+ body: JSON.stringify(body),
129
+ });
130
+ return [
131
+ `โœ… **Organization created:** ${res.name}`,
132
+ ` ID: \`${res.id}\` ยท Slug: \`${res.slug}\` ยท Plan: ${res.plan}`,
133
+ ``,
134
+ `**Next steps:**`,
135
+ `1. Invite team members: \`invite_member(org_id="${res.id}", email="dev@example.com")\``,
136
+ `2. Upgrade plan: open billing portal via dashboard โ†’ /team`,
137
+ ` Team: โ‚ฌ99/mo (10 seats) ยท Business: โ‚ฌ299/mo (50 seats)`,
138
+ ].join('\n');
139
+ }
140
+
141
+ case 'invite_member': {
142
+ const { org_id, email, role = 'member' } = args as { org_id: string; email: string; role?: string };
143
+ await apiFetch(`/api/v1/orgs/${org_id}/members`, {
144
+ method: 'POST',
145
+ body: JSON.stringify({ email, role }),
146
+ });
147
+ return `โœ… Invite sent to **${email}** as \`${role}\` in org \`${org_id}\`.\n\nThey will receive an email to join the organization.`;
148
+ }
149
+
150
+ case 'get_org_plan': {
151
+ const { org_id } = args as { org_id: string };
152
+ const org = await apiFetch<{
153
+ id: string; name: string; plan: string; max_members: number;
154
+ members: Array<{ role: string; invite_email: string; accepted_at?: string }>;
155
+ stripe_customer_id?: string;
156
+ }>(`/api/v1/orgs/${org_id}`);
157
+ const accepted = (org.members ?? []).filter(m => m.accepted_at).length;
158
+ const pending = (org.members ?? []).filter(m => !m.accepted_at).length;
159
+ const planPrice: Record<string, string> = { free: 'โ‚ฌ0', team: 'โ‚ฌ99/mo', business: 'โ‚ฌ299/mo', enterprise: 'custom' };
160
+ return [
161
+ `๐Ÿข **${org.name}** โ€” Plan: **${org.plan}** (${planPrice[org.plan] ?? org.plan})`,
162
+ ` Seats: ${accepted} active + ${pending} pending / ${org.max_members} max`,
163
+ ``,
164
+ `**Members:**`,
165
+ ...(org.members ?? []).map(m => ` โ€ข ${m.invite_email} (${m.role})${m.accepted_at ? '' : ' โ€” pending'}`),
166
+ ``,
167
+ org.stripe_customer_id
168
+ ? `๐Ÿ’ณ Billing: managed via Stripe. Upgrade/cancel: dashboard โ†’ /billing`
169
+ : `๐Ÿ’ณ No payment method yet. Upgrade: dashboard โ†’ /billing โ†’ Team Plans`,
170
+ ].join('\n');
171
+ }
172
+
173
+ // โ”€โ”€ Live cache operations โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
174
+
175
+ default:
176
+ return null;
177
+ }
178
+ }
179
+
180
+ export { formatInstance, buildConnectionString };
@@ -0,0 +1,192 @@
1
+ import type { Redis } from 'ioredis';
2
+
3
+ type GetConnection = (instanceId: string) => Promise<Redis>;
4
+ type ApiFetch = <T>(path: string, options?: RequestInit) => Promise<T>;
5
+
6
+ export const ROADMAP_TOOL_NAMES = new Set([
7
+ 'roadmap_add', 'roadmap_update', 'roadmap_list', 'roadmap_next',
8
+ ]);
9
+
10
+ export async function handleRoadmapTool(
11
+ name: string,
12
+ args: Record<string, unknown>,
13
+ getConnection: GetConnection,
14
+ apiFetch: ApiFetch,
15
+ ): Promise<string | null> {
16
+ switch (name) {
17
+ case 'roadmap_add': {
18
+ const {
19
+ instance_id: rid,
20
+ title,
21
+ description: desc = '',
22
+ priority = 'medium',
23
+ tags: rtags = [],
24
+ milestone = '',
25
+ } = args as {
26
+ instance_id: string; title: string; description?: string;
27
+ priority?: string; tags?: string[]; milestone?: string;
28
+ };
29
+ const redis = await getConnection(rid);
30
+ const id = `rm_${Date.now().toString(36)}_${Math.random().toString(36).slice(2, 6)}`;
31
+ const item = {
32
+ id, title, description: desc, priority, tags: rtags, milestone,
33
+ status: 'planned',
34
+ created: new Date().toISOString(),
35
+ updated: new Date().toISOString(),
36
+ notes: '',
37
+ };
38
+ await redis.hset(`cachly:roadmap:${rid}`, id, JSON.stringify(item));
39
+ const PRIORITY_ICON: Record<string, string> = { critical: '๐Ÿ”ด', high: '๐ŸŸ ', medium: '๐ŸŸก', low: '๐Ÿ”ต' };
40
+ return [
41
+ `๐Ÿ“‹ **Roadmap item added**`,
42
+ ``,
43
+ ` ID: \`${id}\``,
44
+ ` Title: ${title}`,
45
+ ` Priority: ${PRIORITY_ICON[priority] ?? 'โšช'} ${priority}`,
46
+ ` Status: planned`,
47
+ milestone ? ` Milestone: ${milestone}` : '',
48
+ rtags.length ? ` Tags: ${rtags.join(', ')}` : '',
49
+ ``,
50
+ `๐Ÿ’ก Use \`roadmap_update(id: "${id}", status: "in-progress")\` when you start working on it.`,
51
+ ].filter(Boolean).join('\n');
52
+ }
53
+
54
+ case 'roadmap_update': {
55
+ const {
56
+ instance_id: rid,
57
+ id: itemId,
58
+ status: newStatus,
59
+ priority: newPriority,
60
+ notes: newNotes,
61
+ title: newTitle,
62
+ description: newDesc,
63
+ } = args as {
64
+ instance_id: string; id: string; status?: string; priority?: string;
65
+ notes?: string; title?: string; description?: string;
66
+ };
67
+ const redis = await getConnection(rid);
68
+ const raw = await redis.hget(`cachly:roadmap:${rid}`, itemId);
69
+ if (!raw) return `โš ๏ธ **roadmap_update** โ€“ Item \`${itemId}\` not found. Use \`roadmap_list\` to see all items.`;
70
+ const item = JSON.parse(raw) as Record<string, unknown>;
71
+ const oldStatus = item.status as string;
72
+ if (newStatus) item.status = newStatus;
73
+ if (newPriority) item.priority = newPriority;
74
+ if (newTitle) item.title = newTitle;
75
+ if (newDesc) item.description = newDesc;
76
+ if (newNotes) item.notes = item.notes ? `${item.notes}\n[${new Date().toISOString().slice(0, 10)}] ${newNotes}` : `[${new Date().toISOString().slice(0, 10)}] ${newNotes}`;
77
+ item.updated = new Date().toISOString();
78
+ await redis.hset(`cachly:roadmap:${rid}`, itemId, JSON.stringify(item));
79
+ const statusEmoji: Record<string, string> = { planned: '๐Ÿ“‹', 'in-progress': 'โšก', done: 'โœ…', blocked: '๐Ÿšซ', cancelled: '๐Ÿ—‘๏ธ' };
80
+ return [
81
+ `${statusEmoji[newStatus ?? oldStatus] ?? '๐Ÿ“‹'} **Roadmap updated** \`${itemId}\``,
82
+ ``,
83
+ ` Title: ${item.title}`,
84
+ oldStatus !== newStatus ? ` Status: ${oldStatus} โ†’ ${newStatus}` : ` Status: ${item.status}`,
85
+ newNotes ? ` Notes: ${newNotes}` : '',
86
+ ].filter(Boolean).join('\n');
87
+ }
88
+
89
+ case 'roadmap_list': {
90
+ const {
91
+ instance_id: rid,
92
+ status: filterStatus = 'open',
93
+ tag: filterTag,
94
+ milestone: filterMilestone,
95
+ priority: filterPriority,
96
+ } = args as {
97
+ instance_id: string; status?: string; tag?: string;
98
+ milestone?: string; priority?: string;
99
+ };
100
+ const redis = await getConnection(rid);
101
+ const all = await redis.hgetall(`cachly:roadmap:${rid}`);
102
+ if (!all || Object.keys(all).length === 0) {
103
+ return '๐Ÿ“‹ **Roadmap is empty.**\n\nUse `roadmap_add` to create your first item.';
104
+ }
105
+ const PRIORITY_ORDER: Record<string, number> = { critical: 0, high: 1, medium: 2, low: 3 };
106
+ const PRIORITY_ICON: Record<string, string> = { critical: '๐Ÿ”ด', high: '๐ŸŸ ', medium: '๐ŸŸก', low: '๐Ÿ”ต' };
107
+ const STATUS_ICON: Record<string, string> = { planned: '๐Ÿ“‹', 'in-progress': 'โšก', done: 'โœ…', blocked: '๐Ÿšซ', cancelled: '๐Ÿ—‘๏ธ' };
108
+ const openStatuses = new Set(['planned', 'in-progress', 'blocked']);
109
+ let items = Object.values(all).map(v => JSON.parse(v as string) as Record<string, string | string[]>);
110
+ // Filter
111
+ if (filterStatus === 'open') items = items.filter(i => openStatuses.has(i.status as string));
112
+ else if (filterStatus) items = items.filter(i => i.status === filterStatus);
113
+ if (filterTag) items = items.filter(i => (i.tags as string[]).includes(filterTag));
114
+ if (filterMilestone) items = items.filter(i => i.milestone === filterMilestone);
115
+ if (filterPriority) items = items.filter(i => (PRIORITY_ORDER[i.priority as string] ?? 99) <= (PRIORITY_ORDER[filterPriority] ?? 99));
116
+ // Sort: priority asc, then created asc
117
+ items.sort((a, b) => {
118
+ const pa = PRIORITY_ORDER[a.priority as string] ?? 99;
119
+ const pb = PRIORITY_ORDER[b.priority as string] ?? 99;
120
+ return pa !== pb ? pa - pb : (a.created as string).localeCompare(b.created as string);
121
+ });
122
+ if (items.length === 0) return `๐Ÿ“‹ **No roadmap items** match the current filter (status: ${filterStatus}).`;
123
+ const grouped: Record<string, typeof items> = {};
124
+ for (const it of items) {
125
+ const st = it.status as string;
126
+ if (!grouped[st]) grouped[st] = [];
127
+ grouped[st].push(it);
128
+ }
129
+ const lines: string[] = [`๐Ÿ“‹ **Roadmap** (${items.length} item${items.length !== 1 ? 's' : ''})`, ''];
130
+ for (const [st, grp] of Object.entries(grouped)) {
131
+ lines.push(`**${STATUS_ICON[st] ?? 'โ€ข'} ${st.toUpperCase()}** (${grp.length})`);
132
+ for (const it of grp) {
133
+ const tags = (it.tags as string[]).length ? ` [${(it.tags as string[]).join(', ')}]` : '';
134
+ const milestone = it.milestone ? ` ยท ${it.milestone}` : '';
135
+ lines.push(` ${PRIORITY_ICON[it.priority as string] ?? 'โšช'} \`${it.id}\` **${it.title}**${tags}${milestone}`);
136
+ if (it.description) lines.push(` ${(it.description as string).slice(0, 120)}`);
137
+ if (it.notes) lines.push(` ๐Ÿ“ ${(it.notes as string).split('\n').pop()?.slice(0, 100)}`);
138
+ }
139
+ lines.push('');
140
+ }
141
+ lines.push(`๐Ÿ’ก \`roadmap_update(id, status: "in-progress")\` to start ยท \`roadmap_next\` for top priority item`);
142
+ return lines.join('\n');
143
+ }
144
+
145
+ case 'roadmap_next': {
146
+ const { instance_id: rid, tag: filterTag } = args as { instance_id: string; tag?: string };
147
+ const redis = await getConnection(rid);
148
+ const all = await redis.hgetall(`cachly:roadmap:${rid}`);
149
+ if (!all || Object.keys(all).length === 0) {
150
+ return '๐Ÿ“‹ **Roadmap is empty.** Use `roadmap_add` to plan your first task.';
151
+ }
152
+ const PRIORITY_ORDER: Record<string, number> = { critical: 0, high: 1, medium: 2, low: 3 };
153
+ const PRIORITY_ICON: Record<string, string> = { critical: '๐Ÿ”ด', high: '๐ŸŸ ', medium: '๐ŸŸก', low: '๐Ÿ”ต' };
154
+ let items = Object.values(all)
155
+ .map(v => JSON.parse(v as string) as Record<string, unknown>)
156
+ .filter(i => i.status === 'in-progress' || i.status === 'planned')
157
+ .filter(i => !filterTag || (i.tags as string[]).includes(filterTag));
158
+ if (items.length === 0) return '๐ŸŽ‰ **No open roadmap items!** All tasks are done (or use `roadmap_list` to check).';
159
+ // in-progress first, then by priority
160
+ items.sort((a, b) => {
161
+ if (a.status === 'in-progress' && b.status !== 'in-progress') return -1;
162
+ if (b.status === 'in-progress' && a.status !== 'in-progress') return 1;
163
+ return (PRIORITY_ORDER[a.priority as string] ?? 99) - (PRIORITY_ORDER[b.priority as string] ?? 99);
164
+ });
165
+ const next = items[0];
166
+ const remaining = items.length - 1;
167
+ const tags = (next.tags as string[]).length ? `\nTags: ${(next.tags as string[]).join(', ')}` : '';
168
+ const milestone = next.milestone ? `\nMilestone: ${next.milestone}` : '';
169
+ const notes = next.notes ? `\nNotes: ${(next.notes as string).split('\n').pop()?.slice(0, 120)}` : '';
170
+ return [
171
+ `${next.status === 'in-progress' ? 'โšก' : '๐Ÿ“‹'} **Next up: ${next.title}**`,
172
+ ``,
173
+ `ID: \`${next.id}\``,
174
+ `Priority: ${PRIORITY_ICON[next.priority as string] ?? 'โšช'} ${next.priority}`,
175
+ `Status: ${next.status}`,
176
+ next.description ? `\nWhat to do:\n${next.description}` : '',
177
+ tags, milestone, notes,
178
+ ``,
179
+ remaining > 0 ? `(+${remaining} more open item${remaining !== 1 ? 's' : ''} in roadmap)` : '(last open item)',
180
+ ``,
181
+ next.status === 'planned'
182
+ ? `๐Ÿ’ก Start with: \`roadmap_update(id: "${next.id}", status: "in-progress")\``
183
+ : `๐Ÿ’ก Finish with: \`roadmap_update(id: "${next.id}", status: "done", notes: "...")\``,
184
+ ].filter(s => s !== undefined).join('\n');
185
+ }
186
+
187
+ // โ”€โ”€ v0.6 Cognitive Cache: memory_consolidate โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
188
+
189
+ default:
190
+ return null;
191
+ }
192
+ }