@shotik/mcp 0.0.0-stage → 0.1.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 (39) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +40 -2
  3. package/README.ru.md +40 -0
  4. package/data/PROTOCOL.md +386 -0
  5. package/data/flutter/INTEGRATION.md +197 -0
  6. package/data/flutter/README.md +112 -0
  7. package/data/flutter/README.ru.md +165 -0
  8. package/data/flutter/guide.json +190 -0
  9. package/data/flutter/recipe.json +364 -0
  10. package/data/react-native/README.md +194 -0
  11. package/data/react-native/README.ru.md +192 -0
  12. package/data/react-native/guide.json +136 -0
  13. package/data/react-native/recipe.json +263 -0
  14. package/data/react-native/src/analytics/README.md +32 -0
  15. package/data/react-native/src/analytics/recipe.json +263 -0
  16. package/data/storecheck/packs/ai.json +1 -0
  17. package/data/storecheck/packs/dating.json +1 -0
  18. package/data/storecheck/packs/education.json +1 -0
  19. package/data/storecheck/packs/finance.json +1 -0
  20. package/data/storecheck/packs/fitness.json +1 -0
  21. package/data/storecheck/packs/health.json +1 -0
  22. package/data/storecheck/packs/kids.json +1 -0
  23. package/data/storecheck/packs/language.json +1 -0
  24. package/data/storecheck/packs/mindfulness.json +1 -0
  25. package/data/storecheck/packs/music.json +1 -0
  26. package/data/storecheck/packs/nutrition.json +1 -0
  27. package/data/storecheck/packs/photo-video.json +1 -0
  28. package/data/storecheck/packs/productivity.json +1 -0
  29. package/data/storecheck/packs/spirituality.json +1 -0
  30. package/data/storecheck/packs/taxonomy.json +1 -0
  31. package/data/storecheck/packs/utilities.json +1 -0
  32. package/data/storecheck/storecheck.browser.js +314 -0
  33. package/data/swift/README.md +327 -0
  34. package/data/swift/README.ru.md +333 -0
  35. package/data/swift/guide.json +189 -0
  36. package/data/swift/recipe.json +506 -0
  37. package/package.json +42 -4
  38. package/server.mjs +144 -0
  39. package/sources.json +86 -0
@@ -0,0 +1,506 @@
1
+ {
2
+ "schema": "shotik.recipe/1",
3
+ "id": "support-swift",
4
+ "title": "Shotik SDK (Support + Analytics) in a Swift iOS app",
5
+ "package": "https://github.com/rahimwws/shotik-app",
6
+ "products": [
7
+ "ShotikCore",
8
+ "ShotikSupport",
9
+ "ShotikSupportUI",
10
+ "ShotikAnalytics"
11
+ ],
12
+ "rules": [
13
+ "Follow the repo's own conventions (AGENTS.md, CLAUDE.md, SwiftLint, file layout, naming) when placing code.",
14
+ "Edit only the files a step names or detects. Never change signing, bundle ids, deployment targets or other build settings beyond what a step says.",
15
+ "Replace {{VARS}} before writing. Keep edits minimal and idempotent: skip a step whose `done` check already passes.",
16
+ "The SDK has zero dependencies; never add other packages for it. Never add NSAllowsArbitraryLoads.",
17
+ "Generated projects (XcodeGen project.yml, Tuist Project.swift) are edited at the source, never in the generated .xcodeproj.",
18
+ "In Shotik, run add-swift-package and plist-* edits through the ios_project tool (it edits project.pbxproj and plists the way Xcode does, idempotently). Without that tool, or when it returns an error, make the edit by hand as the step's how describes."
19
+ ],
20
+ "variables": {
21
+ "APP_KEY": {
22
+ "required": true,
23
+ "desc": "Public SDK key from Shotik (Support → SDK), spk_…; safe to ship in the app"
24
+ },
25
+ "SERVER_URL": {
26
+ "required": true,
27
+ "desc": "Shotik server URL the device can reach (simulator: http://127.0.0.1:4590; device: the Mac's LAN address or your deployment)"
28
+ },
29
+ "PRODUCTS": {
30
+ "required": false,
31
+ "default": "ShotikSupportUI,ShotikAnalytics",
32
+ "desc": "Libraries to link: ShotikAnalytics alone for analytics only, ShotikSupport without UI for a custom chat screen"
33
+ }
34
+ },
35
+ "detect": [
36
+ {
37
+ "id": "legacy",
38
+ "how": "a local package reference to Vendor/ShotikSDK (project.pbxproj relativePath, project.yml path, Project.swift .local, Package.swift .package(path:)) → true",
39
+ "result": "true | false"
40
+ },
41
+ {
42
+ "id": "project",
43
+ "how": "project.yml → xcodegen; Project.swift with `import ProjectDescription` → tuist; else a *.xcodeproj next to the sources (the one with the app target) → xcodeproj; only a Package.swift with an executable/app target → swiftpm"
44
+ },
45
+ {
46
+ "id": "appTarget",
47
+ "how": "The iOS application target (productType com.apple.product-type.application) that ships to users; ignore extensions, widgets and test targets"
48
+ },
49
+ {
50
+ "id": "scheme",
51
+ "how": "The shared scheme that builds appTarget (xcshareddata/xcschemes/*.xcscheme), else the target name"
52
+ },
53
+ {
54
+ "id": "entry",
55
+ "how": "The type marked @main: `struct X: App` → swiftui; `class X: UIResponder, UIApplicationDelegate` → uikit",
56
+ "result": "swiftui | uikit"
57
+ },
58
+ {
59
+ "id": "entryFile",
60
+ "how": "File declaring the @main type"
61
+ },
62
+ {
63
+ "id": "sceneDelegate",
64
+ "when": "entry == uikit",
65
+ "how": "Class conforming to UIWindowSceneDelegate (scene(_:willConnectTo:options:)), else the app delegate's window setup",
66
+ "optional": true
67
+ },
68
+ {
69
+ "id": "rootView",
70
+ "when": "entry == swiftui",
71
+ "how": "The view expression inside the first WindowGroup of entryFile's body (follow it if it is a router/coordinator view)"
72
+ },
73
+ {
74
+ "id": "appDelegate",
75
+ "how": "@UIApplicationDelegateAdaptor type in a SwiftUI app, or the UIApplicationDelegate class; none when absent",
76
+ "optional": true
77
+ },
78
+ {
79
+ "id": "urlScheme",
80
+ "how": "CFBundleURLSchemes in the app target's Info.plist (or project.yml info.properties / INFOPLIST_KEY build settings); the first scheme that is not a third-party callback (fb…, com.googleusercontent…)",
81
+ "optional": true
82
+ },
83
+ {
84
+ "id": "openURL",
85
+ "how": "Existing .onOpenURL { } / scene(_:openURLContexts:) / application(_:open:options:) handlers",
86
+ "optional": true
87
+ },
88
+ {
89
+ "id": "auth",
90
+ "how": "Where the app learns the signed-in user (auth state listener, session store, sign-in success handler) and its sign-out path",
91
+ "optional": true
92
+ },
93
+ {
94
+ "id": "push",
95
+ "how": "application(_:didRegisterForRemoteNotificationsWithDeviceToken:) or a provider's token callback (Messaging.messaging().token, OneSignal)",
96
+ "optional": true
97
+ },
98
+ {
99
+ "id": "helpEntry",
100
+ "how": "Every existing contact row on settings/profile screens (grep mailto:, \"Contact\", \"Write to us\", \"Help\", \"Support\", MFMailComposeViewController), else the list a new row belongs in"
101
+ },
102
+ {
103
+ "id": "storeKit",
104
+ "how": "Calls to `product.purchase(` (StoreKit 2), SKPaymentQueue (StoreKit 1) or `Purchases.shared.purchase` (RevenueCat)",
105
+ "result": "storekit2 | storekit1 | revenuecat | none"
106
+ },
107
+ {
108
+ "id": "sensitiveViews",
109
+ "how": "Views that show balances, card or account numbers, health data, messages or other personal content",
110
+ "optional": true
111
+ },
112
+ {
113
+ "id": "brand",
114
+ "how": "The app's accent color (AccentColor asset, theme constants), base corner radius and custom font names; omit what you cannot find",
115
+ "optional": true
116
+ },
117
+ {
118
+ "id": "i18n",
119
+ "how": "The app's languages (Localizable.strings / .xcstrings); the widget ships en and ru and follows the device locale",
120
+ "optional": true
121
+ },
122
+ {
123
+ "id": "build",
124
+ "how": "xcodebuild -scheme {{detect.scheme}} -destination 'generic/platform=iOS Simulator' CODE_SIGNING_ALLOWED=NO build (add -project/-workspace when several exist; a .xcworkspace from CocoaPods wins)"
125
+ }
126
+ ],
127
+ "steps": [
128
+ {
129
+ "id": "dependency",
130
+ "title": "Add the package",
131
+ "edits": [
132
+ {
133
+ "op": "add-swift-package",
134
+ "when": "project == xcodeproj",
135
+ "file": "the .xcodeproj/project.pbxproj of appTarget",
136
+ "url": "https://github.com/rahimwws/shotik-app",
137
+ "from": "0.1.0",
138
+ "products": "{{PRODUCTS}}",
139
+ "target": "{{detect.appTarget}}",
140
+ "how": "XCRemoteSwiftPackageReference (repositoryURL = https://github.com/rahimwws/shotik-app, requirement { kind = upToNextMajorVersion; minimumVersion = 0.1.0; }) in the project's packageReferences, one XCSwiftPackageProductDependency per product (package = that reference) in the target's packageProductDependencies, and a PBXBuildFile with productRef in its Frameworks build phase. Same as Xcode's File → Add Package Dependencies… with the URL pasted in the search field.",
141
+ "tool": {
142
+ "name": "ios_project",
143
+ "args": {
144
+ "action": "add_swift_package",
145
+ "project": "<the .xcodeproj of detect.appTarget>",
146
+ "url": "https://github.com/rahimwws/shotik-app",
147
+ "minimumVersion": "0.1.0",
148
+ "products": "{{PRODUCTS}} split on commas",
149
+ "target": "{{detect.appTarget}}",
150
+ "replaceLocal": "when detect.legacy: [the Vendor/ShotikSDK path relative to the project]"
151
+ }
152
+ }
153
+ },
154
+ {
155
+ "op": "yaml-set",
156
+ "when": "project == xcodegen",
157
+ "file": "project.yml",
158
+ "path": [
159
+ "packages",
160
+ "Shotik"
161
+ ],
162
+ "value": {
163
+ "url": "https://github.com/rahimwws/shotik-app",
164
+ "from": "0.1.0"
165
+ },
166
+ "then": "add `- package: Shotik\\n product: <each of PRODUCTS>` under targets.{{detect.appTarget}}.dependencies and run xcodegen"
167
+ },
168
+ {
169
+ "op": "insert-after",
170
+ "when": "project == tuist",
171
+ "file": "Project.swift",
172
+ "anchor": "packages: [",
173
+ "code": ".remote(url: \"https://github.com/rahimwws/shotik-app\", requirement: .upToNextMajor(from: \"0.1.0\")),",
174
+ "then": "add .package(product: \"<each of PRODUCTS>\") to the app target's dependencies"
175
+ },
176
+ {
177
+ "op": "insert-after",
178
+ "when": "project == swiftpm",
179
+ "file": "Package.swift",
180
+ "anchor": "dependencies: [",
181
+ "code": ".package(url: \"https://github.com/rahimwws/shotik-app\", from: \"0.1.0\"),",
182
+ "then": "add .product(name: \"<each of PRODUCTS>\", package: \"shotik-app\") to the app target"
183
+ }
184
+ ],
185
+ "done": "grep -rqE 'rahimwws/shotik-app' --include=project.pbxproj --include=project.yml --include=Project.swift --include=Package.swift .",
186
+ "note": "SwiftPM resolves the tagged 0.1.0 release from GitHub; commit Package.resolved so CI builds the same SDK.",
187
+ "migrate": "When detect.legacy is true: remove the local Vendor/ShotikSDK reference (and its product dependencies) first, delete the Vendor/ShotikSDK folder, then add the remote package. Product names and imports stay the same."
188
+ },
189
+ {
190
+ "id": "configure",
191
+ "title": "Configure at launch",
192
+ "file": "{{detect.entryFile}}",
193
+ "edits": [
194
+ {
195
+ "op": "add-import",
196
+ "code": "import ShotikCore"
197
+ },
198
+ {
199
+ "op": "insert-after",
200
+ "when": "entry == swiftui",
201
+ "anchor": "the start of the App struct's init() (create `init() {}` if there is none)",
202
+ "code": "Shotik.configure(appKey: \"{{APP_KEY}}\", serverUrl: \"{{SERVER_URL}}\")"
203
+ },
204
+ {
205
+ "op": "insert-after",
206
+ "when": "entry == uikit",
207
+ "anchor": "the first line of application(_:didFinishLaunchingWithOptions:)",
208
+ "code": "Shotik.configure(appKey: \"{{APP_KEY}}\", serverUrl: \"{{SERVER_URL}}\")"
209
+ }
210
+ ],
211
+ "done": "grep -rq 'Shotik.configure(' --include=*.swift --exclude-dir=Vendor .",
212
+ "note": "When the app reads config per environment (xcconfig, a Config/Environment enum), put the key and URL there and pass them in. Calls made before configure are held, so order against the app's other setup does not matter."
213
+ },
214
+ {
215
+ "id": "widget",
216
+ "title": "Present the Support widget",
217
+ "when": "PRODUCTS contains ShotikSupportUI",
218
+ "edits": [
219
+ {
220
+ "op": "add-import",
221
+ "when": "entry == swiftui",
222
+ "file": "{{detect.entryFile}}",
223
+ "code": "import ShotikSupportUI"
224
+ },
225
+ {
226
+ "op": "append-modifier",
227
+ "when": "entry == swiftui",
228
+ "file": "{{detect.entryFile}}",
229
+ "target": "{{detect.rootView}} inside the first WindowGroup",
230
+ "code": ".shotikSupportSheet({{widgetOptions}})"
231
+ },
232
+ {
233
+ "op": "add-import",
234
+ "when": "entry == uikit",
235
+ "file": "{{detect.sceneDelegate}}",
236
+ "code": "import ShotikSupportUI"
237
+ },
238
+ {
239
+ "op": "insert-after",
240
+ "when": "entry == uikit",
241
+ "file": "{{detect.sceneDelegate}}",
242
+ "anchor": "window?.makeKeyAndVisible() (or the end of scene(_:willConnectTo:options:))",
243
+ "code": "ShotikSupportWidget.install({{widgetOptions}})"
244
+ }
245
+ ],
246
+ "done": "grep -rqE 'shotikSupportSheet|ShotikSupportWidget.install' --include=*.swift --exclude-dir=Vendor .",
247
+ "note": "widgetOptions: SupportWidgetOptions(title: \"<app name>\", theme: SupportTheme(accent: \"<detect.brand color hex>\", radius: <detect.brand radius>, font: \"<font>\")) with only the values found; omit the argument when nothing was found. Add .shotikSupportLauncher() only if the app has no Help/Contact row. Never pass locale unless the app forces a language in-app."
248
+ },
249
+ {
250
+ "id": "urlScheme",
251
+ "title": "Deep link <scheme>://support",
252
+ "when": "PRODUCTS contains ShotikSupportUI",
253
+ "edits": [
254
+ {
255
+ "op": "plist-add",
256
+ "when": "detect.urlScheme not found",
257
+ "file": "the app target's Info.plist (or project.yml info.properties)",
258
+ "path": [
259
+ "CFBundleURLTypes"
260
+ ],
261
+ "value": [
262
+ {
263
+ "CFBundleURLName": "<bundle id>",
264
+ "CFBundleURLSchemes": [
265
+ "<lowercased app name, letters only>"
266
+ ]
267
+ }
268
+ ],
269
+ "tool": {
270
+ "name": "ios_project",
271
+ "args": {
272
+ "action": "plist",
273
+ "file": "the app target's Info.plist (or project.yml info.properties)",
274
+ "path": [
275
+ "CFBundleURLTypes"
276
+ ],
277
+ "value": "each entry of value",
278
+ "mode": "append"
279
+ }
280
+ }
281
+ },
282
+ {
283
+ "op": "insert-before",
284
+ "when": "detect.openURL found",
285
+ "file": "{{detect.openURL}}",
286
+ "anchor": "the first line inside the app's own URL handler",
287
+ "code": "if ShotikSupport.handle(url: url) { return }",
288
+ "also": "pass handleLinks: false to .shotikSupportSheet so the link is handled once; add `import ShotikSupport`"
289
+ },
290
+ {
291
+ "op": "insert-after",
292
+ "when": "entry == uikit and detect.openURL not found",
293
+ "file": "{{detect.sceneDelegate}}",
294
+ "anchor": "class body",
295
+ "code": "func scene(_ scene: UIScene, openURLContexts URLContexts: Set<UIOpenURLContext>) {\n for c in URLContexts { ShotikSupport.handle(url: c.url) }\n}"
296
+ }
297
+ ],
298
+ "done": "grep -rq 'CFBundleURLSchemes' --include=*.plist --include=project.yml --exclude-dir=Vendor --exclude-dir=Sample .",
299
+ "note": "SwiftUI apps without their own onOpenURL need no code: .shotikSupportSheet() handles <scheme>://support."
300
+ },
301
+ {
302
+ "id": "help",
303
+ "title": "Help entry opens the chat",
304
+ "when": "PRODUCTS contains ShotikSupport or ShotikSupportUI",
305
+ "file": "{{detect.helpEntry}}",
306
+ "edits": [
307
+ {
308
+ "op": "add-import",
309
+ "code": "import ShotikSupport"
310
+ },
311
+ {
312
+ "op": "set-handler",
313
+ "target": "Each contact row's action (replace the mailto / MFMailComposeViewController / web form), else a new row labelled Help built with the screen's own row component and the app's localization",
314
+ "code": "ShotikSupport.open()"
315
+ }
316
+ ],
317
+ "done": "grep -rq 'ShotikSupport.open(' --include=*.swift --exclude-dir=Vendor .",
318
+ "note": "For an unread badge on the row: @StateObject private var badge = ShotikSupportBadge() and show badge.unread when > 0."
319
+ },
320
+ {
321
+ "id": "identify",
322
+ "title": "Identify after the app's own sign-in",
323
+ "when": "detect.auth found",
324
+ "file": "{{detect.auth}}",
325
+ "edits": [
326
+ {
327
+ "op": "add-import",
328
+ "code": "import ShotikCore"
329
+ },
330
+ {
331
+ "op": "add-import",
332
+ "when": "PRODUCTS contains ShotikSupport or ShotikSupportUI",
333
+ "code": "import ShotikSupport"
334
+ },
335
+ {
336
+ "op": "add-import",
337
+ "when": "PRODUCTS contains ShotikAnalytics",
338
+ "code": "import ShotikAnalytics"
339
+ },
340
+ {
341
+ "op": "insert-after",
342
+ "anchor": "the point where a signed-in user (id, email, name) is known",
343
+ "code": "ShotikSupport.identify(userId: user.id, name: user.name, email: user.email)\nShotikAnalytics.identify(user.id)",
344
+ "note": "keep only the lines for linked products; map the app's own user fields"
345
+ },
346
+ {
347
+ "op": "insert-after",
348
+ "anchor": "the sign-out path",
349
+ "code": "Shotik.reset()"
350
+ }
351
+ ],
352
+ "done": "grep -rqE 'ShotikSupport.identify\\(|ShotikAnalytics.identify\\(' --include=*.swift --exclude-dir=Vendor .",
353
+ "note": "Safe before configure: calls are held. Anonymous users are identified automatically and keep their chats after sign-in. Never send passwords or tokens as attributes or traits."
354
+ },
355
+ {
356
+ "id": "push",
357
+ "title": "Forward the push token",
358
+ "when": "detect.push found and PRODUCTS contains ShotikSupport or ShotikSupportUI",
359
+ "file": "{{detect.push}}",
360
+ "edits": [
361
+ {
362
+ "op": "add-import",
363
+ "code": "import ShotikSupport"
364
+ },
365
+ {
366
+ "op": "insert-after",
367
+ "anchor": "the start of didRegisterForRemoteNotificationsWithDeviceToken (or the line that obtains the provider's token)",
368
+ "code": "ShotikSupport.setPushToken(deviceToken: deviceToken)",
369
+ "otherwise": "ShotikSupport.setPushToken(token, platform: \"ios\") for a provider's string token"
370
+ }
371
+ ],
372
+ "done": "grep -rq 'ShotikSupport.setPushToken(' --include=*.swift --exclude-dir=Vendor ."
373
+ },
374
+ {
375
+ "id": "purchases",
376
+ "title": "Record purchase start and cancel",
377
+ "when": "PRODUCTS contains ShotikAnalytics and detect.storeKit != none",
378
+ "edits": [
379
+ {
380
+ "op": "wrap-call",
381
+ "when": "storeKit == storekit2",
382
+ "target": "each `try await product.purchase(...)`",
383
+ "code": "try await ShotikAnalytics.purchase(product: product) { try await product.purchase(...) }",
384
+ "also": "add `import ShotikAnalytics`"
385
+ },
386
+ {
387
+ "op": "insert-after",
388
+ "when": "storeKit == revenuecat",
389
+ "anchor": "the purchase result handler",
390
+ "code": "ShotikAnalytics.purchase(product: product.productIdentifier, status: cancelled ? .cancel : .done, price: NSDecimalNumber(decimal: product.price).doubleValue, currency: product.currencyCode)"
391
+ }
392
+ ],
393
+ "note": "StoreKit 2 transactions are recorded automatically; the wrapper adds start and cancel. StoreKit 1 apps: nothing to edit, but tell the founder only done purchases from StoreKit 2's history are seen."
394
+ },
395
+ {
396
+ "id": "masking",
397
+ "title": "Mask sensitive views",
398
+ "when": "PRODUCTS contains ShotikAnalytics and detect.sensitiveViews found",
399
+ "edits": [
400
+ {
401
+ "op": "append-modifier",
402
+ "target": "each SwiftUI view in detect.sensitiveViews",
403
+ "code": ".shotikMask()"
404
+ },
405
+ {
406
+ "op": "insert-after",
407
+ "target": "each UIKit view in detect.sensitiveViews, after it is created",
408
+ "code": "<view>.shotikMasked = true"
409
+ }
410
+ ],
411
+ "note": "Text fields and secure fields are always treated as inputs (no value, no label); do not mask them separately."
412
+ },
413
+ {
414
+ "id": "tags",
415
+ "title": "Tag SwiftUI tap targets",
416
+ "when": "PRODUCTS contains ShotikAnalytics and entry == swiftui",
417
+ "edits": [
418
+ {
419
+ "op": "append-modifier",
420
+ "target": "Each CTA the founder's funnels depend on: paywall plan buttons and the purchase/trial button, onboarding continue/next/get-started, the sign-in button, the Help row (detect.helpEntry), and other primary buttons on those screens",
421
+ "code": ".shotikTag(\"<kebab-case id>\", label: \"<the button's English title>\")",
422
+ "note": "Ids are stable kebab-case names of the action (start-trial, continue, help), never the localized title; reuse an existing accessibilityIdentifier value when the view has one. Skip views that show personal data."
423
+ }
424
+ ],
425
+ "done": "grep -rq '\\.shotikTag(' --include=*.swift --exclude-dir=Vendor .",
426
+ "note": "SwiftUI vends no accessibility elements without an assistive technology, so untagged SwiftUI taps arrive as el \"View\" with no id. UIKit apps need no tags: accessibilityIdentifier is read directly."
427
+ },
428
+ {
429
+ "id": "screens",
430
+ "title": "Name the key screens",
431
+ "when": "PRODUCTS contains ShotikAnalytics and entry == swiftui",
432
+ "edits": [
433
+ {
434
+ "op": "append-modifier",
435
+ "target": "the top-level view of each onboarding, paywall, home and settings screen that has no .navigationTitle",
436
+ "code": ".shotikScreen(\"<ScreenName>\")"
437
+ }
438
+ ],
439
+ "optional": true,
440
+ "note": "Without it SwiftUI screens are named by navigation title or hosting controller class. Use stable English names (they group analytics)."
441
+ },
442
+ {
443
+ "id": "localHttp",
444
+ "title": "Allow the local server in development",
445
+ "when": "SERVER_URL starts with http:// and is not 127.0.0.1/localhost",
446
+ "edits": [
447
+ {
448
+ "op": "plist-set",
449
+ "file": "the app target's Info.plist",
450
+ "path": [
451
+ "NSAppTransportSecurity",
452
+ "NSAllowsLocalNetworking"
453
+ ],
454
+ "value": true,
455
+ "tool": {
456
+ "name": "ios_project",
457
+ "args": {
458
+ "action": "plist",
459
+ "file": "the app target's Info.plist",
460
+ "path": [
461
+ "NSAppTransportSecurity",
462
+ "NSAllowsLocalNetworking"
463
+ ],
464
+ "value": true,
465
+ "mode": "set"
466
+ }
467
+ }
468
+ }
469
+ ],
470
+ "note": "Only for LAN or .local addresses; production uses HTTPS. Never add NSAllowsArbitraryLoads."
471
+ }
472
+ ],
473
+ "verify": [
474
+ {
475
+ "id": "wired",
476
+ "run": "grep -rlE 'Shotik.configure\\(|shotikSupportSheet|ShotikSupportWidget.install|ShotikSupport\\.(open|identify|setPushToken)' --include=*.swift --exclude-dir=Vendor .",
477
+ "expect": "lists the entry file and the help entry"
478
+ },
479
+ {
480
+ "id": "build",
481
+ "run": "{{detect.build}}",
482
+ "expect": "** BUILD SUCCEEDED **, no new warnings in the files this recipe touched"
483
+ },
484
+ {
485
+ "id": "privacy",
486
+ "run": "find ~/Library/Developer/Xcode/DerivedData -path '*{{detect.appTarget}}.app/*ShotikCore*/PrivacyInfo.xcprivacy' -newer Vendor/ShotikSDK/Package.swift | head -1",
487
+ "expect": "one path: the SDK's privacy manifest ships inside the app"
488
+ },
489
+ {
490
+ "id": "server",
491
+ "run": "curl -sf {{SERVER_URL}}/health",
492
+ "expect": "\"ok\":true"
493
+ },
494
+ {
495
+ "id": "key",
496
+ "run": "curl -s -o /dev/null -w '%{http_code}' -X POST -H 'x-shotik-key: {{APP_KEY}}' -H 'content-type: application/json' -d '{}' {{SERVER_URL}}/support/v1/identify",
497
+ "expect": "400 (key known, empty body refused); 401 means a wrong key"
498
+ },
499
+ {
500
+ "id": "device",
501
+ "run": "xcrun simctl openurl booted '{{detect.urlScheme}}://support'",
502
+ "expect": "The Support sheet opens; a sent message shows in Shotik → Support, and screens and taps show in Shotik → Analytics within 10 s",
503
+ "manual": true
504
+ }
505
+ ]
506
+ }
package/package.json CHANGED
@@ -1,6 +1,44 @@
1
1
  {
2
2
  "name": "@shotik/mcp",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.1.1",
4
+ "description": "MCP server with Shotik's SDK install recipes, guides and protocol, so coding agents add Shotik Support and Analytics to an app themselves.",
5
+ "keywords": [
6
+ "mcp",
7
+ "model-context-protocol",
8
+ "shotik",
9
+ "sdk",
10
+ "react-native",
11
+ "flutter",
12
+ "swift"
13
+ ],
14
+ "homepage": "https://github.com/rahimwws/shotik-app/tree/main/sdk/mcp#readme",
15
+ "bugs": "https://github.com/rahimwws/shotik-app/issues",
16
+ "repository": {
17
+ "type": "git",
18
+ "url": "git+https://github.com/rahimwws/shotik-app.git",
19
+ "directory": "sdk/mcp"
20
+ },
21
+ "license": "MIT",
22
+ "type": "module",
23
+ "bin": {
24
+ "shotik-mcp": "server.mjs"
25
+ },
26
+ "files": [
27
+ "server.mjs",
28
+ "sources.json",
29
+ "data",
30
+ "README.md",
31
+ "README.ru.md",
32
+ "LICENSE"
33
+ ],
34
+ "engines": {
35
+ "node": ">=18"
36
+ },
37
+ "scripts": {
38
+ "prepack": "node scripts/bundle.mjs",
39
+ "test": "node --test test.mjs"
40
+ },
41
+ "publishConfig": {
42
+ "access": "public"
43
+ }
44
+ }