@hailer/mcp 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.
Files changed (163) hide show
  1. package/.claude/commands/tool-builder.md +37 -0
  2. package/.claude/commands/ws-pull.md +44 -0
  3. package/.claude/settings.json +8 -0
  4. package/.claude/settings.local.json +49 -0
  5. package/.claude/skills/activity-api/SKILL.md +96 -0
  6. package/.claude/skills/activity-api/references/activity-endpoints.md +845 -0
  7. package/.claude/skills/add-app-member-skill/SKILL.md +977 -0
  8. package/.claude/skills/agent-building/SKILL.md +243 -0
  9. package/.claude/skills/agent-building/references/architecture-patterns.md +446 -0
  10. package/.claude/skills/agent-building/references/code-examples.md +587 -0
  11. package/.claude/skills/agent-building/references/implementation-guide.md +619 -0
  12. package/.claude/skills/app-api/SKILL.md +219 -0
  13. package/.claude/skills/app-api/references/app-endpoints.md +759 -0
  14. package/.claude/skills/building-hailer-apps-skill/SKILL.md +548 -0
  15. package/.claude/skills/create-app-skill/SKILL.md +1101 -0
  16. package/.claude/skills/create-insight-skill/SKILL.md +1317 -0
  17. package/.claude/skills/get-insight-data-skill/SKILL.md +1053 -0
  18. package/.claude/skills/hailer-api/SKILL.md +283 -0
  19. package/.claude/skills/hailer-api/references/activities.md +620 -0
  20. package/.claude/skills/hailer-api/references/authentication.md +216 -0
  21. package/.claude/skills/hailer-api/references/datasets.md +437 -0
  22. package/.claude/skills/hailer-api/references/files.md +301 -0
  23. package/.claude/skills/hailer-api/references/insights.md +469 -0
  24. package/.claude/skills/hailer-api/references/workflows.md +720 -0
  25. package/.claude/skills/hailer-api/references/workspaces-users.md +445 -0
  26. package/.claude/skills/insight-api/SKILL.md +185 -0
  27. package/.claude/skills/insight-api/references/insight-endpoints.md +514 -0
  28. package/.claude/skills/install-workflow-skill/SKILL.md +1056 -0
  29. package/.claude/skills/list-apps-skill/SKILL.md +1010 -0
  30. package/.claude/skills/list-workflows-minimal-skill/SKILL.md +992 -0
  31. package/.claude/skills/local-first-skill/SKILL.md +570 -0
  32. package/.claude/skills/mcp-tools/SKILL.md +419 -0
  33. package/.claude/skills/mcp-tools/references/api-endpoints.md +499 -0
  34. package/.claude/skills/mcp-tools/references/data-structures.md +554 -0
  35. package/.claude/skills/mcp-tools/references/implementation-patterns.md +717 -0
  36. package/.claude/skills/preview-insight-skill/SKILL.md +1290 -0
  37. package/.claude/skills/publish-hailer-app-skill/SKILL.md +453 -0
  38. package/.claude/skills/remove-app-member-skill/SKILL.md +671 -0
  39. package/.claude/skills/remove-app-skill/SKILL.md +985 -0
  40. package/.claude/skills/remove-insight-skill/SKILL.md +1011 -0
  41. package/.claude/skills/remove-workflow-skill/SKILL.md +920 -0
  42. package/.claude/skills/scaffold-hailer-app-skill/SKILL.md +1034 -0
  43. package/.claude/skills/skill-testing/README.md +137 -0
  44. package/.claude/skills/skill-testing/SKILL.md +348 -0
  45. package/.claude/skills/skill-testing/references/test-patterns.md +705 -0
  46. package/.claude/skills/skill-testing/references/testing-guide.md +603 -0
  47. package/.claude/skills/skill-testing/references/validation-checklist.md +537 -0
  48. package/.claude/skills/tool-builder/SKILL.md +328 -0
  49. package/.claude/skills/update-app-skill/SKILL.md +970 -0
  50. package/.claude/skills/update-workflow-field-skill/SKILL.md +1098 -0
  51. package/.env.example +81 -0
  52. package/.mcp.json +13 -0
  53. package/README.md +297 -0
  54. package/dist/app.d.ts +4 -0
  55. package/dist/app.js +74 -0
  56. package/dist/cli.d.ts +3 -0
  57. package/dist/cli.js +5 -0
  58. package/dist/client/adaptive-documentation-bot.d.ts +108 -0
  59. package/dist/client/adaptive-documentation-bot.js +475 -0
  60. package/dist/client/adaptive-documentation-types.d.ts +66 -0
  61. package/dist/client/adaptive-documentation-types.js +9 -0
  62. package/dist/client/agent-activity-bot.d.ts +51 -0
  63. package/dist/client/agent-activity-bot.js +166 -0
  64. package/dist/client/agent-tracker.d.ts +499 -0
  65. package/dist/client/agent-tracker.js +659 -0
  66. package/dist/client/description-updater.d.ts +56 -0
  67. package/dist/client/description-updater.js +259 -0
  68. package/dist/client/log-parser.d.ts +72 -0
  69. package/dist/client/log-parser.js +387 -0
  70. package/dist/client/mcp-client.d.ts +50 -0
  71. package/dist/client/mcp-client.js +532 -0
  72. package/dist/client/message-processor.d.ts +35 -0
  73. package/dist/client/message-processor.js +352 -0
  74. package/dist/client/multi-bot-manager.d.ts +24 -0
  75. package/dist/client/multi-bot-manager.js +74 -0
  76. package/dist/client/providers/anthropic-provider.d.ts +19 -0
  77. package/dist/client/providers/anthropic-provider.js +631 -0
  78. package/dist/client/providers/llm-provider.d.ts +47 -0
  79. package/dist/client/providers/llm-provider.js +367 -0
  80. package/dist/client/providers/openai-provider.d.ts +23 -0
  81. package/dist/client/providers/openai-provider.js +621 -0
  82. package/dist/client/simple-llm-caller.d.ts +19 -0
  83. package/dist/client/simple-llm-caller.js +100 -0
  84. package/dist/client/skill-generator.d.ts +81 -0
  85. package/dist/client/skill-generator.js +386 -0
  86. package/dist/client/test-adaptive-bot.d.ts +9 -0
  87. package/dist/client/test-adaptive-bot.js +82 -0
  88. package/dist/client/token-pricing.d.ts +38 -0
  89. package/dist/client/token-pricing.js +127 -0
  90. package/dist/client/token-tracker.d.ts +232 -0
  91. package/dist/client/token-tracker.js +457 -0
  92. package/dist/client/token-usage-bot.d.ts +53 -0
  93. package/dist/client/token-usage-bot.js +153 -0
  94. package/dist/client/tool-executor.d.ts +69 -0
  95. package/dist/client/tool-executor.js +159 -0
  96. package/dist/client/tool-schema-loader.d.ts +60 -0
  97. package/dist/client/tool-schema-loader.js +178 -0
  98. package/dist/client/types.d.ts +69 -0
  99. package/dist/client/types.js +7 -0
  100. package/dist/config.d.ts +162 -0
  101. package/dist/config.js +296 -0
  102. package/dist/core.d.ts +26 -0
  103. package/dist/core.js +147 -0
  104. package/dist/lib/context-manager.d.ts +111 -0
  105. package/dist/lib/context-manager.js +431 -0
  106. package/dist/lib/logger.d.ts +74 -0
  107. package/dist/lib/logger.js +277 -0
  108. package/dist/lib/materialize.d.ts +3 -0
  109. package/dist/lib/materialize.js +101 -0
  110. package/dist/lib/normalizedName.d.ts +7 -0
  111. package/dist/lib/normalizedName.js +48 -0
  112. package/dist/lib/prompt-length-manager.d.ts +81 -0
  113. package/dist/lib/prompt-length-manager.js +457 -0
  114. package/dist/lib/terminal-prompt.d.ts +9 -0
  115. package/dist/lib/terminal-prompt.js +108 -0
  116. package/dist/mcp/UserContextCache.d.ts +56 -0
  117. package/dist/mcp/UserContextCache.js +163 -0
  118. package/dist/mcp/auth.d.ts +2 -0
  119. package/dist/mcp/auth.js +29 -0
  120. package/dist/mcp/hailer-clients.d.ts +42 -0
  121. package/dist/mcp/hailer-clients.js +246 -0
  122. package/dist/mcp/signal-handler.d.ts +45 -0
  123. package/dist/mcp/signal-handler.js +317 -0
  124. package/dist/mcp/tool-registry.d.ts +100 -0
  125. package/dist/mcp/tool-registry.js +306 -0
  126. package/dist/mcp/tools/activity.d.ts +15 -0
  127. package/dist/mcp/tools/activity.js +955 -0
  128. package/dist/mcp/tools/app.d.ts +20 -0
  129. package/dist/mcp/tools/app.js +1488 -0
  130. package/dist/mcp/tools/discussion.d.ts +19 -0
  131. package/dist/mcp/tools/discussion.js +950 -0
  132. package/dist/mcp/tools/file.d.ts +15 -0
  133. package/dist/mcp/tools/file.js +119 -0
  134. package/dist/mcp/tools/insight.d.ts +17 -0
  135. package/dist/mcp/tools/insight.js +806 -0
  136. package/dist/mcp/tools/skill.d.ts +10 -0
  137. package/dist/mcp/tools/skill.js +279 -0
  138. package/dist/mcp/tools/user.d.ts +10 -0
  139. package/dist/mcp/tools/user.js +108 -0
  140. package/dist/mcp/tools/workflow-template.d.ts +19 -0
  141. package/dist/mcp/tools/workflow-template.js +822 -0
  142. package/dist/mcp/tools/workflow.d.ts +18 -0
  143. package/dist/mcp/tools/workflow.js +1362 -0
  144. package/dist/mcp/utils/api-errors.d.ts +45 -0
  145. package/dist/mcp/utils/api-errors.js +160 -0
  146. package/dist/mcp/utils/data-transformers.d.ts +102 -0
  147. package/dist/mcp/utils/data-transformers.js +194 -0
  148. package/dist/mcp/utils/file-upload.d.ts +33 -0
  149. package/dist/mcp/utils/file-upload.js +148 -0
  150. package/dist/mcp/utils/hailer-api-client.d.ts +120 -0
  151. package/dist/mcp/utils/hailer-api-client.js +323 -0
  152. package/dist/mcp/utils/index.d.ts +13 -0
  153. package/dist/mcp/utils/index.js +39 -0
  154. package/dist/mcp/utils/logger.d.ts +42 -0
  155. package/dist/mcp/utils/logger.js +103 -0
  156. package/dist/mcp/utils/types.d.ts +286 -0
  157. package/dist/mcp/utils/types.js +7 -0
  158. package/dist/mcp/workspace-cache.d.ts +42 -0
  159. package/dist/mcp/workspace-cache.js +97 -0
  160. package/dist/mcp-server.d.ts +42 -0
  161. package/dist/mcp-server.js +280 -0
  162. package/package.json +56 -0
  163. package/tsconfig.json +23 -0
@@ -0,0 +1,671 @@
1
+ ---
2
+ name: remove-app-member-skill
3
+ description: Complete guide to using the remove_app_member tool to revoke Hailer app access from users, teams, or workspaces
4
+ ---
5
+
6
+ # Remove App Member Skill
7
+
8
+ Complete guide to using the `remove_app_member` tool to revoke Hailer app access from workspace members, teams, or individual users.
9
+
10
+ ## Table of Contents
11
+ - [Quick Reference](#quick-reference)
12
+ - [Overview](#overview)
13
+ - [Core Concepts](#core-concepts)
14
+ - [Basic Usage](#basic-usage)
15
+ - [Common Scenarios](#common-scenarios)
16
+ - [Best Practices](#best-practices)
17
+ - [Troubleshooting](#troubleshooting)
18
+ - [Integration with Other Tools](#integration-with-other-tools)
19
+ - [Additional Resources](#additional-resources)
20
+
21
+ ## Quick Reference
22
+
23
+ ### Remove workspace access (revoke for all members)
24
+ ```javascript
25
+ remove_app_member({
26
+ appId: '<app-id>',
27
+ member: 'network_68446c045b30685f67c6fc8c'
28
+ })
29
+ ```
30
+
31
+ ### Remove team access
32
+ ```javascript
33
+ remove_app_member({
34
+ appId: '<app-id>',
35
+ member: 'team_<team-id>'
36
+ })
37
+ ```
38
+
39
+ ### Remove individual user access
40
+ ```javascript
41
+ remove_app_member({
42
+ appId: '<app-id>',
43
+ member: 'user_<user-id>'
44
+ })
45
+ ```
46
+
47
+ ## Overview
48
+
49
+ The `remove_app_member` tool revokes permission for users, teams, or entire workspaces to access a Hailer app. This is the inverse operation of `add_app_member` and is essential for managing app distribution, restricting access during development, or implementing role-based access control.
50
+
51
+ **Key capabilities:**
52
+ - Revoke workspace-wide access
53
+ - Remove team-based access
54
+ - Revoke individual user access
55
+ - Maintain creator/admin access (cannot be revoked)
56
+ - Clean permission management
57
+
58
+ **Requirements:**
59
+ - User must be app creator or workspace admin
60
+ - App must exist
61
+ - Member ID must have correct prefix (network_, team_, user_, group_)
62
+
63
+ **Important notes:**
64
+ - Creator and admins always retain access (cannot be removed)
65
+ - Removing workspace access revokes access from ALL members (except creator/admins)
66
+ - Member format is same as `add_app_member` tool
67
+
68
+ ## Core Concepts
69
+
70
+ ### Member Types and Prefixes
71
+
72
+ Member identifiers **must** include specific prefixes to indicate the type of access being revoked:
73
+
74
+ | Member Type | ID Format | Example | Effect |
75
+ |------------|-----------|---------|--------|
76
+ | **Workspace** | `network_<workspace-id>` | `network_68446c045b30685f67c6fc8c` | Revokes access for entire workspace (all members) |
77
+ | **Team** | `team_<team-id>` | `team_507f1f77bcf86cd799439011` | Revokes access for specific team |
78
+ | **User** | `user_<user-id>` | `user_507f191e810c19729de860ea` | Revokes access for individual user |
79
+ | **Group** | `group_<group-id>` | `group_507f191e810c19729de860eb` | Revokes access for group |
80
+
81
+ ### Permission Hierarchy
82
+
83
+ Understanding who can be removed:
84
+ 1. **Cannot remove:** App creator and workspace admins (always retain access)
85
+ 2. **Can remove:** Regular members, teams, or workspace-wide grants
86
+ 3. **Cascading effect:** Removing workspace access affects all non-admin members
87
+
88
+ ### Access Control
89
+
90
+ Who can remove members:
91
+ - App creator
92
+ - Workspace administrators
93
+ - Cannot be delegated to regular users
94
+
95
+ ## Basic Usage
96
+
97
+ ### Step 1: Identify the app
98
+
99
+ Use `list_apps` to find your app ID:
100
+
101
+ ```javascript
102
+ list_apps()
103
+ ```
104
+
105
+ Look for the app you want to modify:
106
+ ```
107
+ App ID: abc123
108
+ Name: Task Manager
109
+ Members: network_68446c045b30685f67c6fc8c, team_507f1f77bcf86cd799439011
110
+ ```
111
+
112
+ ### Step 2: Identify member to remove
113
+
114
+ From the members list, identify which access grant to revoke:
115
+ - Workspace access: `network_68446c045b30685f67c6fc8c`
116
+ - Team access: `team_507f1f77bcf86cd799439011`
117
+
118
+ ### Step 3: Remove the member
119
+
120
+ ```javascript
121
+ remove_app_member({
122
+ appId: 'abc123',
123
+ member: 'team_507f1f77bcf86cd799439011'
124
+ })
125
+ ```
126
+
127
+ ### Step 4: Verify removal
128
+
129
+ Check the app's member list again:
130
+
131
+ ```javascript
132
+ list_apps()
133
+ ```
134
+
135
+ The removed member should no longer appear in the members array.
136
+
137
+ ## Common Scenarios
138
+
139
+ ### Scenario 1: Restrict Beta App to Specific Team
140
+
141
+ You have a beta app shared workspace-wide, but want to restrict it to just the development team:
142
+
143
+ ```javascript
144
+ // 1. Remove workspace access
145
+ remove_app_member({
146
+ appId: 'beta-app-id',
147
+ member: 'network_68446c045b30685f67c6fc8c'
148
+ })
149
+
150
+ // 2. Add specific team access
151
+ add_app_member({
152
+ appId: 'beta-app-id',
153
+ member: 'team_dev-team-id'
154
+ })
155
+ ```
156
+
157
+ **Result:** Only development team members (plus creator/admins) can access the app.
158
+
159
+ ### Scenario 2: Revoke Individual Tester Access
160
+
161
+ Remove access for specific users after beta testing completes:
162
+
163
+ ```javascript
164
+ // Remove multiple testers
165
+ remove_app_member({
166
+ appId: 'beta-app-id',
167
+ member: 'user_tester1-id'
168
+ })
169
+
170
+ remove_app_member({
171
+ appId: 'beta-app-id',
172
+ member: 'user_tester2-id'
173
+ })
174
+
175
+ remove_app_member({
176
+ appId: 'beta-app-id',
177
+ member: 'user_tester3-id'
178
+ })
179
+ ```
180
+
181
+ ### Scenario 3: Migrate from Workspace to Team Access
182
+
183
+ Narrow access from everyone to specific teams:
184
+
185
+ ```javascript
186
+ // 1. Get current app details
187
+ const apps = list_apps()
188
+ const myApp = apps.find(app => app.id === 'my-app-id')
189
+
190
+ // 2. Remove workspace access
191
+ remove_app_member({
192
+ appId: 'my-app-id',
193
+ member: 'network_68446c045b30685f67c6fc8c'
194
+ })
195
+
196
+ // 3. Add specific teams
197
+ add_app_member({
198
+ appId: 'my-app-id',
199
+ member: 'team_sales-id'
200
+ })
201
+
202
+ add_app_member({
203
+ appId: 'my-app-id',
204
+ member: 'team_marketing-id'
205
+ })
206
+ ```
207
+
208
+ ### Scenario 4: Remove All External Access
209
+
210
+ Remove all sharing and keep app private (creator/admins only):
211
+
212
+ ```javascript
213
+ // 1. List current members
214
+ list_apps()
215
+
216
+ // 2. Remove each member grant
217
+ remove_app_member({
218
+ appId: 'private-app-id',
219
+ member: 'network_68446c045b30685f67c6fc8c' // If workspace shared
220
+ })
221
+
222
+ // App is now private - only creator and admins have access
223
+ ```
224
+
225
+ ### Scenario 5: Clean Up Old Access Grants
226
+
227
+ Remove deprecated team or user access:
228
+
229
+ ```javascript
230
+ // Remove old team that no longer exists
231
+ remove_app_member({
232
+ appId: 'app-id',
233
+ member: 'team_old-team-id'
234
+ })
235
+
236
+ // Remove former employees
237
+ remove_app_member({
238
+ appId: 'app-id',
239
+ member: 'user_former-employee-id'
240
+ })
241
+ ```
242
+
243
+ ## Best Practices
244
+
245
+ ### 1. Verify Before Removal
246
+
247
+ Always check current members before removing:
248
+
249
+ ```javascript
250
+ // Check current access
251
+ list_apps()
252
+
253
+ // Then remove specific member
254
+ remove_app_member({
255
+ appId: 'app-id',
256
+ member: 'team_old-team-id'
257
+ })
258
+ ```
259
+
260
+ ### 2. Use Least Privilege Principle
261
+
262
+ Remove broad access and add specific access:
263
+
264
+ ```javascript
265
+ // ❌ Bad: Leave workspace access + add exceptions
266
+ // Everyone can access, hard to manage
267
+
268
+ // ✅ Good: Remove workspace, add specific teams
269
+ remove_app_member({
270
+ appId: 'app-id',
271
+ member: 'network_workspace-id'
272
+ })
273
+
274
+ add_app_member({
275
+ appId: 'app-id',
276
+ member: 'team_authorized-team-id'
277
+ })
278
+ ```
279
+
280
+ ### 3. Document Access Changes
281
+
282
+ Keep track of why access was removed:
283
+
284
+ ```javascript
285
+ // Update app name or config to reflect access level
286
+ update_app({
287
+ appId: 'app-id',
288
+ name: 'Internal Tool (Sales & Marketing Only)',
289
+ config: {
290
+ ...app.config,
291
+ accessLevel: 'team-specific',
292
+ authorizedTeams: ['sales', 'marketing']
293
+ }
294
+ })
295
+ ```
296
+
297
+ ### 4. Communicate Changes
298
+
299
+ Before removing access from teams or workspace:
300
+ - Notify affected users
301
+ - Explain why access is being restricted
302
+ - Provide timeline for changes
303
+
304
+ ### 5. Test with Minimal Access First
305
+
306
+ When deploying to production:
307
+
308
+ ```javascript
309
+ // 1. Start private (no sharing)
310
+ create_app({
311
+ name: 'New App',
312
+ url: 'https://app-url.com'
313
+ })
314
+
315
+ // 2. Add small test team
316
+ add_app_member({
317
+ appId: 'new-app-id',
318
+ member: 'team_test-team-id'
319
+ })
320
+
321
+ // 3. After validation, expand to other teams
322
+ // (Don't go straight to workspace-wide)
323
+
324
+ // 4. If issues found, easily restrict again
325
+ remove_app_member({
326
+ appId: 'new-app-id',
327
+ member: 'team_test-team-id'
328
+ })
329
+ ```
330
+
331
+ ### 6. Handle Cascading Effects
332
+
333
+ Understand impact of removing workspace access:
334
+
335
+ ```javascript
336
+ // Removing workspace access affects ALL members
337
+ // (except creator and admins)
338
+
339
+ remove_app_member({
340
+ appId: 'app-id',
341
+ member: 'network_workspace-id'
342
+ })
343
+
344
+ // This is equivalent to removing access from:
345
+ // - All teams
346
+ // - All individual users
347
+ // - Any future workspace members
348
+
349
+ // Creator and admins still retain access
350
+ ```
351
+
352
+ ## Troubleshooting
353
+
354
+ ### Error: "Permission Denied"
355
+
356
+ **Problem:** Can't remove app member.
357
+
358
+ **Causes:**
359
+ 1. You're not the app creator or workspace admin
360
+ 2. Trying to remove creator or admin (not allowed)
361
+
362
+ **Solutions:**
363
+ ```javascript
364
+ // Check who you are
365
+ list_apps()
366
+
367
+ // Look for "You are: creator" or "You are: admin"
368
+
369
+ // If you're not creator/admin, ask them to remove the member
370
+ // Creators and admins cannot be removed - they always have access
371
+ ```
372
+
373
+ ### Error: "App not found"
374
+
375
+ **Problem:** Invalid app ID.
376
+
377
+ **Solution:**
378
+ ```javascript
379
+ // List all apps to get correct ID
380
+ list_apps()
381
+
382
+ // Use exact app ID from the list
383
+ remove_app_member({
384
+ appId: 'correct-app-id',
385
+ member: 'team_team-id'
386
+ })
387
+ ```
388
+
389
+ ### Error: "Member format invalid"
390
+
391
+ **Problem:** Member ID doesn't have required prefix.
392
+
393
+ **Solution:**
394
+ ```javascript
395
+ // ❌ Wrong: No prefix
396
+ remove_app_member({
397
+ appId: 'app-id',
398
+ member: '68446c045b30685f67c6fc8c'
399
+ })
400
+
401
+ // ✅ Correct: With prefix
402
+ remove_app_member({
403
+ appId: 'app-id',
404
+ member: 'network_68446c045b30685f67c6fc8c'
405
+ })
406
+ ```
407
+
408
+ ### Member Still Has Access After Removal
409
+
410
+ **Problem:** User can still access app after removing their team.
411
+
412
+ **Possible causes:**
413
+ 1. User is app creator or admin (always has access)
414
+ 2. User has access through another grant (e.g., workspace or different team)
415
+ 3. User has individual user grant
416
+
417
+ **Solution:**
418
+ ```javascript
419
+ // 1. Check all current members
420
+ list_apps()
421
+
422
+ // Look at the members array:
423
+ // members: [
424
+ // 'network_workspace-id', // Workspace access
425
+ // 'team_team-id', // Team access
426
+ // 'user_specific-user-id' // Individual access
427
+ // ]
428
+
429
+ // 2. Remove ALL relevant grants
430
+ remove_app_member({
431
+ appId: 'app-id',
432
+ member: 'network_workspace-id'
433
+ })
434
+
435
+ remove_app_member({
436
+ appId: 'app-id',
437
+ member: 'user_specific-user-id'
438
+ })
439
+ ```
440
+
441
+ ### Accidentally Removed Wrong Member
442
+
443
+ **Problem:** Removed the wrong team or user.
444
+
445
+ **Solution:**
446
+ ```javascript
447
+ // Simply add them back
448
+ add_app_member({
449
+ appId: 'app-id',
450
+ member: 'team_correct-team-id'
451
+ })
452
+
453
+ // Or re-add workspace access if you removed it by mistake
454
+ add_app_member({
455
+ appId: 'app-id',
456
+ member: 'network_workspace-id'
457
+ })
458
+ ```
459
+
460
+ ### Want to Remove Creator Access
461
+
462
+ **Problem:** Creator wants to transfer ownership or remove their access.
463
+
464
+ **Solution:**
465
+ This is not possible. The app creator always retains access. Workspace admins also always retain access.
466
+
467
+ **Workarounds:**
468
+ 1. Delete the app entirely using `remove_app`
469
+ 2. Create a new app with a different creator
470
+ 3. Keep the app but remove all other members
471
+
472
+ ## Integration with Other Tools
473
+
474
+ ### With `add_app_member`
475
+
476
+ Manage access by adding and removing members:
477
+
478
+ ```javascript
479
+ // Migration pattern: Replace team access
480
+ remove_app_member({
481
+ appId: 'app-id',
482
+ member: 'team_old-team-id'
483
+ })
484
+
485
+ add_app_member({
486
+ appId: 'app-id',
487
+ member: 'team_new-team-id'
488
+ })
489
+ ```
490
+
491
+ ### With `list_apps`
492
+
493
+ Always check current members before removing:
494
+
495
+ ```javascript
496
+ // 1. Check current state
497
+ const apps = list_apps()
498
+ const myApp = apps.find(app => app.name === 'My App')
499
+
500
+ console.log('Current members:', myApp.members)
501
+
502
+ // 2. Remove specific member
503
+ remove_app_member({
504
+ appId: myApp.id,
505
+ member: 'team_unwanted-team-id'
506
+ })
507
+
508
+ // 3. Verify removal
509
+ const updatedApps = list_apps()
510
+ const updatedApp = updatedApps.find(app => app.id === myApp.id)
511
+ console.log('Updated members:', updatedApp.members)
512
+ ```
513
+
514
+ ### With `update_app`
515
+
516
+ Update app metadata to reflect access changes:
517
+
518
+ ```javascript
519
+ // Remove workspace access
520
+ remove_app_member({
521
+ appId: 'app-id',
522
+ member: 'network_workspace-id'
523
+ })
524
+
525
+ // Update app name to reflect restricted access
526
+ update_app({
527
+ appId: 'app-id',
528
+ name: 'Beta Tool (Dev Team Only)',
529
+ config: {
530
+ ...app.config,
531
+ accessLevel: 'restricted'
532
+ }
533
+ })
534
+ ```
535
+
536
+ ### With `create_app`
537
+
538
+ Start with restricted access during development:
539
+
540
+ ```javascript
541
+ // 1. Create app (private by default)
542
+ const result = create_app({
543
+ name: 'New Feature (Dev)',
544
+ url: 'http://localhost:3000'
545
+ })
546
+
547
+ // 2. Add only dev team during development
548
+ add_app_member({
549
+ appId: result.appId,
550
+ member: 'team_dev-team-id'
551
+ })
552
+
553
+ // 3. After testing, remove dev team and add production teams
554
+ remove_app_member({
555
+ appId: result.appId,
556
+ member: 'team_dev-team-id'
557
+ })
558
+
559
+ add_app_member({
560
+ appId: result.appId,
561
+ member: 'network_workspace-id'
562
+ })
563
+ ```
564
+
565
+ ### With `publish_hailer_app`
566
+
567
+ Manage access during publishing workflow:
568
+
569
+ ```javascript
570
+ // 1. Start private during development
571
+ create_app({
572
+ name: 'My App (Dev)',
573
+ url: 'http://localhost:3000'
574
+ })
575
+
576
+ // 2. Build and publish
577
+ publish_hailer_app({
578
+ manifestPath: './manifest.json',
579
+ buildDir: './dist',
580
+ appId: 'app-id'
581
+ })
582
+
583
+ // 3. Test with small team first
584
+ add_app_member({
585
+ appId: 'app-id',
586
+ member: 'team_qa-team-id'
587
+ })
588
+
589
+ // 4. If issues found, restrict again
590
+ remove_app_member({
591
+ appId: 'app-id',
592
+ member: 'team_qa-team-id'
593
+ })
594
+
595
+ // 5. After validation, share workspace-wide
596
+ add_app_member({
597
+ appId: 'app-id',
598
+ member: 'network_workspace-id'
599
+ })
600
+ ```
601
+
602
+ ### With `remove_app`
603
+
604
+ Clean up before deleting:
605
+
606
+ ```javascript
607
+ // 1. Remove all members first (optional, for cleanliness)
608
+ remove_app_member({
609
+ appId: 'old-app-id',
610
+ member: 'network_workspace-id'
611
+ })
612
+
613
+ // 2. Then delete the app
614
+ remove_app({
615
+ appId: 'old-app-id'
616
+ })
617
+ ```
618
+
619
+ ## Additional Resources
620
+
621
+ ### Related Skills
622
+ - **add-app-member-skill** - Share apps with users, teams, or workspace
623
+ - **list-apps-skill** - View and manage workspace apps
624
+ - **create-app-skill** - Create new Hailer app entries
625
+ - **update-app-skill** - Modify app properties
626
+ - **remove-app-skill** - Delete app entries
627
+ - **publish-hailer-app-skill** - Deploy and publish apps
628
+
629
+ ### Related Tools
630
+ - `add_app_member` - Grant app access
631
+ - `list_apps` - View all apps and their members
632
+ - `update_app` - Modify app configuration
633
+ - `create_app` - Create new app entries
634
+
635
+ ### Key Concepts
636
+ - Member ID prefixes (network_, team_, user_, group_)
637
+ - Permission hierarchy (creator/admin always retain access)
638
+ - Cascading effects (removing workspace affects all members)
639
+ - Access control patterns (least privilege)
640
+
641
+ ### Access Patterns
642
+
643
+ | Pattern | Use Case | Implementation |
644
+ |---------|----------|----------------|
645
+ | **Private** | Development only | Don't add any members |
646
+ | **Team Specific** | Department tools | Remove workspace, add specific teams |
647
+ | **Graduated Rollout** | Phased deployment | Start with one team, expand gradually |
648
+ | **Workspace Wide** | Company tools | Add network_workspace-id |
649
+ | **Restricted Beta** | Testing | Remove workspace, add test users individually |
650
+
651
+ ### Common Workflows
652
+
653
+ 1. **Lock down during development:**
654
+ ```javascript
655
+ remove_app_member({ appId, member: 'network_...' })
656
+ ```
657
+
658
+ 2. **Gradual expansion:**
659
+ ```javascript
660
+ add_app_member({ appId, member: 'team_pilot-team' })
661
+ // test...
662
+ remove_app_member({ appId, member: 'team_pilot-team' })
663
+ add_app_member({ appId, member: 'network_...' })
664
+ ```
665
+
666
+ 3. **Access cleanup:**
667
+ ```javascript
668
+ // Remove all, re-add only authorized
669
+ remove_app_member({ appId, member: 'network_...' })
670
+ add_app_member({ appId, member: 'team_authorized-team' })
671
+ ```