dt-setup-ios
БесплатноЗапускает вложенные скриптыНе проверенSet up the Dynatrace iOS SDK (OneAgent) in an iOS project using Swift Package Manager. Automates adding the SPM dependency, creating a Dynatrace.plist…
от Dynatrace★ 190 звёзд на GitHubОб этом скилле
Dynatrace iOS SDK Setup
This skill sets up the Dynatrace iOS SDK (OneAgent) in the user's iOS project — from zero to first event. It follows the official setup flow from the Dynatrace documentation.
When to use this skill
- The user wants to add Dynatrace monitoring to their iOS app
- The user asks to integrate, install, or set up the Dynatrace iOS SDK
- The user wants to instrument their iOS app with Dynatrace
- The user pastes a setup prompt copied from the Experience Vitals wizard
Pre-filled values
When invoked from the Experience Vitals wizard, the user's message will contain
pre-filled configuration values in a fenced block labeled
dynatrace-ios-setup-config. Example:
```dynatrace-ios-setup-config
DTXApplicationID: ABC-123
DTXBeaconURL: https://example.dynatrace.com/mbeacon
Product: DynatraceSessionReplay
DTXUserOptIn: true
```
When these values are present:
- Skip step 2 (Collect application identification keys) — use the provided
DTXApplicationIDandDTXBeaconURL. - Skip the product question in step 3 — use the provided
Productvalue (DynatraceorDynatraceSessionReplay). - Use
DTXUserOptInto determine whether to add the privacy opt-in code in step 5. Iftrue, add the opt-in code. Iffalse, skip step 5.
All other steps (prerequisites, SPM dependency, plist creation, import, build, verify) proceed as normal.
Procedure
1. Check prerequisites
Actively verify each prerequisite before proceeding. If any check fails, inform the user and stop.
a) Xcode MCP server is available
This is a hard requirement. The skill uses the Xcode MCP server to interact with the Xcode project (adding SPM dependencies, building, etc.). Verify that Xcode MCP tools are accessible (e.g., mcp_xcode_XcodeListWindows). If not available, tell the user to install and enable the Xcode MCP server before proceeding.
b) iOS deployment target >= 12.0
The .pbxproj file is not accessible through the Xcode MCP server (it's project metadata, not a navigator file). Use grep in the terminal instead:
grep 'IPHONEOS_DEPLOYMENT_TARGET' <path/to/project.pbxproj>
Check that all deployment target values are >= 12.0. If any are below 12.0, tell the user to update them.
c) Xcode version >= 16.0
Run xcodebuild -version in the terminal to verify. If below 16.0, tell the user to update Xcode.
d) Ruby + xcodeproj gem
Needed by scripts/add_spm_dependency.rb in step 3. Check:
ruby -e 'require "xcodeproj"; puts Xcodeproj::VERSION'
If it fails, run gem install xcodeproj and retry.
2. Collect application identification keys
If the user's message contains a dynatrace-ios-setup-config block (see
Pre-filled values), extract DTXApplicationID and
DTXBeaconURL from there and skip to step 3.
Otherwise, ask the user for the two required values:
- DTXApplicationID — the application's unique identifier
- DTXBeaconURL — the beacon endpoint URL (e.g.,
https://{environment}.dynatrace.com/mbeacon)
If the user already provided these values in their message, skip asking.
If the user doesn't have these values or doesn't know how to get them, refer them to the official setup documentation: https://docs.dynatrace.com/docs/observe/digital-experience/new-rum-experience/mobile-frontends/ios/id-01-initial-setup
3. Add OneAgent to the project (SPM dependency)
Add the Dynatrace Swift Mobile SDK via Swift Package Manager.
If the user's message contains a dynatrace-ios-setup-config block with a
Product value, use that directly. Otherwise, ask the user which product they
want:
- Dynatrace — OneAgent for automatic mobile app instrumentation
- DynatraceSessionReplay — OneAgent + Session Replay module (replay on crash)
SPM package URL: https://github.com/Dynatrace/swift-mobile-sdk.git
Run the bundled Ruby script scripts/add_spm_dependency.rb. It uses the xcodeproj gem to add the package reference, product dependency, and frameworks build-file entry correctly — no string manipulation of .pbxproj.
ruby ./scripts/add_spm_dependency.rb \
<ProjectPath> \
https://github.com/Dynatrace/swift-mobile-sdk.git \
8.0.0 \
<Product> \
[TargetName]
ProjectPath— e.g../MyApp.xcodeproj<Product>—DynatraceorDynatraceSessionReplay(from step 3 choice)TargetName— optional; defaults to the first application target in the project
The script is idempotent — running it twice is a no-op. Prints OK: project saved on success.
If the script fails for any reason (unusual project layout, Ruby unavailable), fall back to guiding the user through Xcode manually:
- Open the project in Xcode
- File > Add Package Dependencies...
- Enter URL: `https://github.com/Dy
Установить dt-setup-ios в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл dt-setup-ios?
Set up the Dynatrace iOS SDK (OneAgent) in an iOS project using Swift Package Manager. Automates adding the SPM dependency, creating a Dynatrace.plist configuration file, adding the import statement, adding privacy opt-in code, and building the project. Use this skill when the user wants to integrate, install, add, or set up Dynatrace monitoring in their iOS app. Keywords: Dynatrace, iOS, SDK, OneAgent, setup, install, integrate, SPM, Swift Package Manager, Info.plist, DTXApplicationID, DTXBeaconURL, mobile monitoring, RUM.
Как установить скилл dt-setup-ios?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл dt-setup-ios запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic