Agent skill

Push Notifications

by rshankras in rshankras/claude-code-apple-skills

Generate push notification infrastructure with APNs registration, handling, and rich notifications.

MITAuto-check: notesMobile

Install Push Notifications

skills CLI
$ npx skills add rshankras/claude-code-apple-skills --skill push-notifications -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install rshankras/claude-code-apple-skills push-notifications --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/rshankras/claude-code-apple-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/generators/push-notifications .claude/skills/push-notifications && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
push-notifications
GitHub stars
783
Token cost
~2.3k tokens
SKILL.md length
427 words
Files
6
Skills in repo
41
Repo updated
First seen
Licence
MIT

At a glance

Generate push notification infrastructure with APNs registration, handling, and rich notifications.

  • Works in 6 steps: Notification Types → Notification Actions → Silent Notifications → …
  • Adding push notifications
  • SKILL.md covers When This Skill Activates, Pre-Generation Checks, Configuration Questions and Generated Files, plus 6 more sections
  • Runs Swift scripts from its folder; calls curl; reaches api.sandbox.push.apple.com; needs JWT_TOKEN and DEVICE_TOKEN

What it does

Push Notifications is an agent skill from rshankras/claude-code-apple-skills. Generate push notification infrastructure with APNs registration, handling, and rich notifications. Use when adding push notifications, configuring APNs, notification categories/actions, or rich notifications with images and custom UI.

Its SKILL.md is about 2.3k tokens, which your agent loads only when the skill is triggered. The skill folder holds 6 other files (for example `push-notification-patterns.md`).

It sits in Mobile, covering iOS development. The repository describes itself as: Claude Code skills for Apple platform development (iOS, macOS, iPadOS) — product validation, code generation, App Store optimization, and more. The licence is MIT.

When your agent uses it

  • Adding push notifications
  • Configuring APNs
  • Notification categories/actions
  • Rich notifications with images and custom UI

Example prompts

  • “/push-notifications”

Requirements

  • A credential in JWT_TOKEN
  • A credential in DEVICE_TOKEN
  • Pre-approved tools (allowed-tools): Read, Write, Edit, Glob, Grep, Bash, AskUserQuestion

Workflow steps

6 steps, taken from the step headings in SKILL.md.

  1. Notification Types
  2. Notification Actions
  3. Silent Notifications
  4. SwiftUI App
  5. Request Permission (at appropriate time)
  6. Server-Side Setup

What it can do on your machine

Read from SKILL.md and the folder at commit 9ffb831. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read
    • Write
    • Edit
    • Glob
    • Grep
    • Bash
    • AskUserQuestion

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships script files (Swift), which the agent can run.

    Shell commands in SKILL.md call:

    • curl

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • api.sandbox.push.apple.com

    Also links to:

    • developer.apple.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • JWT_TOKEN
    • DEVICE_TOKEN

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Push Notifications loads about 2.3k tokens when it runs. Until then it costs about 64 tokens; SKILL.md has 427 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~64
When it runs · the whole SKILL.md, loaded when a task matches
~2.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NotePre-approves every shell command (allowed-tools: Bash)SKILL.md
    allowed-tools: Read, Write, Edit, Glob, Grep, Bash, AskUserQuestion

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from rshankras/claude-code-apple-skills at commit 9ffb831, republished under its MIT licence (© rshankras). 427 words, ~2,254 tokens.

Download SKILL.mdSave it as .claude/skills/push-notifications/SKILL.md (or your agent's skills folder). This skill also uses 5 other files; get the full folder from GitHub.
name
push-notifications
description
Generate push notification infrastructure with APNs registration, handling, and rich notifications. Use when adding push notifications, configuring APNs, notification categories/actions, or rich notifications with images and custom UI.
allowed-tools
Read, Write, Edit, Glob, Grep, Bash, AskUserQuestion
last_verified
2026-07-16
review_by
2027-06-22
os_version
iOS 27 / macOS 27

Push Notifications Generator

Generate push notification infrastructure with APNs registration, handling, and rich notifications.

When This Skill Activates

  • User wants to add push notifications to their app
  • User mentions APNs (Apple Push Notification service)
  • User asks about notification categories or actions
  • User wants rich notifications with images or custom UI

Pre-Generation Checks

Before generating, verify:

  1. Existing Notification Code

    bash
    # Check for existing notification handling
    grep -r "UNUserNotificationCenter\|registerForRemoteNotifications" --include="*.swift" | head -5
  2. Entitlements

    bash
    # Check for push notification entitlement
    find . -name "*.entitlements" -exec grep -l "aps-environment" {} \;
  3. App Delegate or SwiftUI App

    bash
    # Determine app structure
    grep -r "@main\|UIApplicationDelegate" --include="*.swift" | head -5

Configuration Questions

1. Notification Types
  • Basic - Simple alerts with title/body
  • Rich - Include images, custom UI (requires Notification Service Extension)
  • Both - Full notification support
2. Notification Actions
  • None - Just display notifications
  • Simple Actions - Quick action buttons
  • Custom Categories - Multiple action categories
3. Silent Notifications
  • Yes - Background data updates
  • No - User-visible only

Generated Files

Core Infrastructure
Sources/Notifications/
├── NotificationManager.swift      # Central notification management
├── NotificationDelegate.swift     # UNUserNotificationCenterDelegate
├── NotificationCategories.swift   # Action categories definition
└── NotificationPayload.swift      # Type-safe payload parsing
Rich Notifications (Optional)
NotificationServiceExtension/
├── NotificationService.swift      # Modify notifications before display
└── Info.plist                     # Extension configuration
Content Extension (Optional)
NotificationContentExtension/
├── NotificationViewController.swift  # Custom notification UI
├── MainInterface.storyboard
└── Info.plist

Key Features

Registration Flow
swift
@MainActor
final class NotificationManager {
    static let shared = NotificationManager()

    func requestAuthorization() async throws -> Bool {
        let center = UNUserNotificationCenter.current()
        let options: UNAuthorizationOptions = [.alert, .badge, .sound]
        return try await center.requestAuthorization(options: options)
    }

    func registerForRemoteNotifications() {
        UIApplication.shared.registerForRemoteNotifications()
    }
}
Handling Notifications
swift
// Foreground notification
func userNotificationCenter(
    _ center: UNUserNotificationCenter,
    willPresent notification: UNNotification
) async -> UNNotificationPresentationOptions {
    return [.banner, .sound, .badge]
}

// Notification tap/action
func userNotificationCenter(
    _ center: UNUserNotificationCenter,
    didReceive response: UNNotificationResponse
) async {
    let userInfo = response.notification.request.content.userInfo
    await handleNotificationAction(response.actionIdentifier, userInfo: userInfo)
}
Action Categories
swift
enum NotificationCategory: String {
    case message = "MESSAGE_CATEGORY"
    case reminder = "REMINDER_CATEGORY"

    var actions: [UNNotificationAction] {
        switch self {
        case .message:
            return [
                UNNotificationAction(identifier: "REPLY", title: "Reply", options: []),
                UNNotificationAction(identifier: "MARK_READ", title: "Mark as Read", options: [])
            ]
        case .reminder:
            return [
                UNNotificationAction(identifier: "COMPLETE", title: "Complete", options: []),
                UNNotificationAction(identifier: "SNOOZE", title: "Snooze", options: [])
            ]
        }
    }
}

Notification Design (WWDC18)

"Interrupting people is a real privilege… a trust relationship." Design the strategy before the infrastructure:

DecisionRule
AuthorizationUse provisional authorization (add .provisional to the options — delivered quietly to Notification Center, no prompt) for passive content like likes and comments; reserve the explicit prompt for time-critical content
When to promptNever at first launch. Explain the value first, then ask at a contextually meaningful moment — right after the order is placed, not before the user has ordered
Content barEvery notification carries a specific message or a completable task — never an empty "open the app" nudge
TimingDeliver at relevant times; use time- and location-based delivery where it fits
SettingsOffer granular per-topic toggles in-app, and add .providesAppNotificationSettings so "Manage" in system settings deep-links to your page
GroupingApp-level grouping is the default; set threadIdentifier only for meaningfully different streams (conversations, distinct sources) — over-threading recreates the clutter grouping was meant to fix
Rich contentA rich notification is a self-contained package: image/video plus actions that complete the task without launching the app
FatiguePause notification types a user repeatedly ignores (the Duolingo pattern) — silence beats an uninstall
Show full SKILL.md (102 more words)Show less

Required Capabilities

In Xcode
  1. Select project target
  2. Signing & Capabilities tab
  3. Add "Push Notifications" capability
  4. Add "Background Modes" > "Remote notifications" (for silent notifications)
Entitlements
xml
<key>aps-environment</key>
<string>development</string>  <!-- or "production" -->

Integration Steps

1. SwiftUI App
swift
@main
struct MyApp: App {
    @UIApplicationDelegateAdaptor private var appDelegate: AppDelegate

    var body: some Scene {
        WindowGroup {
            ContentView()
        }
    }
}

class AppDelegate: NSObject, UIApplicationDelegate {
    func application(
        _ application: UIApplication,
        didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
    ) -> Bool {
        UNUserNotificationCenter.current().delegate = NotificationDelegate.shared
        NotificationCategories.registerAll()
        return true
    }

    func application(
        _ application: UIApplication,
        didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data
    ) {
        let token = deviceToken.map { String(format: "%02.2hhx", $0) }.joined()
        print("Device Token: \(token)")
        // Send token to your server
    }
}
2. Request Permission (at appropriate time)
swift
Button("Enable Notifications") {
    Task {
        let granted = try await NotificationManager.shared.requestAuthorization()
        if granted {
            await MainActor.run {
                NotificationManager.shared.registerForRemoteNotifications()
            }
        }
    }
}
3. Server-Side Setup

Configure your server to send APNs requests:

  • Use APNs HTTP/2 API
  • Include team ID, key ID, and .p8 key
  • Target: api.push.apple.com (production) or api.sandbox.push.apple.com (development)

Testing

Local Notifications (Simulator)
swift
func scheduleTestNotification() {
    let content = UNMutableNotificationContent()
    content.title = "Test"
    content.body = "This is a test notification"
    content.sound = .default

    let trigger = UNTimeIntervalNotificationTrigger(timeInterval: 5, repeats: false)
    let request = UNNotificationRequest(identifier: UUID().uuidString, content: content, trigger: trigger)

    UNUserNotificationCenter.current().add(request)
}
Remote Notifications (Physical Device)
  1. Build to physical device
  2. Copy device token from console
  3. Use APNs testing tool or curl:
bash
curl -v \
  --header "authorization: bearer $JWT_TOKEN" \
  --header "apns-topic: com.yourcompany.yourapp" \
  --header "apns-push-type: alert" \
  --http2 \
  --data '{"aps":{"alert":{"title":"Test","body":"Hello"}}}' \
  https://api.sandbox.push.apple.com/3/device/$DEVICE_TOKEN

References

© rshankras, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 5 other files in skills/generators/push-notifications of rshankras/claude-code-apple-skills.

  • SKILL.md
  • push-notification-patterns.md
  • templates/NotificationCategories.swift
  • templates/NotificationDelegate.swift
  • templates/NotificationManager.swift
  • templates/NotificationPayload.swift

Open the folder on GitHubat commit 9ffb831

Compare with similar skills

Push Notifications next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Push Notifications compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Push Notifications this skillrshankras/claude-code-apple-skills783—~2.3kAutomated safety check: NotesMIT
Swiftui Protwostraws/SwiftUI-Agent-Skill5.1k2 repos~1.5kAutomated safety check: PassMIT
Swiftui UI PatternsAFK-surf/OpenBridge4304 repos~887Automated safety check: PassMIT
Swiftui Performance Auditharperreed/dotfiles3348 repos~1.4kAutomated safety check: PassNone
Swift Testing ExpertAvdLee/Swift-Testing-Agent-Skill4691 repos~1.2kAutomated safety check: PassMIT
Hig Project Contextraintree-technology/hig-doctor1435 repos~1.2kAutomated safety check: PassMIT

Similar skills

  • Swiftui Pro

    twostraws/SwiftUI-Agent-Skill

    Comprehensively reviews SwiftUI code for best practices on modern APIs, maintainability, and performance.

    5.1k GitHub starsUsed in 2 repos~1.5k tokens
    MobileAuto-check passed
  • Swiftui UI Patterns

    AFK-surf/OpenBridge

    Best practices and example-driven guidance for building SwiftUI views and components.

    430 GitHub starsUsed in 4 repos~887 tokens
    MobileAuto-check passed
  • Swiftui Performance Audit

    harperreed/dotfiles

    Audit and improve SwiftUI runtime performance from code review and architecture.

    334 GitHub starsUsed in 8 repos~1.4k tokens
    MobileAuto-check passed
  • Swift Testing Expert

    AvdLee/Swift-Testing-Agent-Skill

    Expert guidance for Swift Testing: test structure, expect/require macros, traits and tags, parameterized tests, test plans, parallel execution, async waiting patterns, and XCTest migration.

    469 GitHub starsUsed in 1 repo~1.2k tokens
    MobileAuto-check passed
  • Hig Project Context

    raintree-technology/hig-doctor

    Create or update a shared Apple design context document that other HIG skills use to tailor guidance.

    143 GitHub starsUsed in 5 repos~1.2k tokens
    MobileAuto-check passed
  • Swift Testing Pro

    twostraws/Swift-Testing-Agent-Skill

    Writes, reviews, and improves Swift Testing code using modern APIs and best practices.

    448 GitHub stars~1.1k tokensUpdated 4 mo ago
    MobileAuto-check passed

More from rshankras/claude-code-apple-skills

All 41 skills in this repo
  • Accessibility Generator

    rshankras/claude-code-apple-skills

    Generate accessibility infrastructure for VoiceOver, Dynamic Type, and accessibility features.

    783 GitHub stars~1.4k tokensUpdated 2 mo ago
    Auto-check: notes
  • Animation Patterns

    rshankras/claude-code-apple-skills

    SwiftUI animation patterns including springs, transitions, PhaseAnimator, KeyframeAnimator, SF Symbol effects, scroll-driven effects, mesh gradients, text renderers, and shader effects.

    783 GitHub stars~2.1k tokensUpdated 2 mo ago
    Auto-check passed
  • App Description Writer

    rshankras/claude-code-apple-skills

    Generate compelling App Store descriptions that convert browsers into users.

    783 GitHub stars~1.3k tokensUpdated 2 mo ago
    Auto-check passed
  • App Icon Generator

    rshankras/claude-code-apple-skills

    Generates an app icon for macOS or iOS — a fast CoreGraphics placeholder and/or flat layered source art to finish in Icon Composer (the Liquid Glass / iOS 26+ standard).

    783 GitHub stars~5.1k tokensUpdated 2 mo ago
    Auto-check: notes
  • App Namer

    rshankras/claude-code-apple-skills

    Turn an app idea into validated, App-Store-ready name candidates.

    783 GitHub stars~3.4k tokensUpdated 2 mo ago
    Auto-check passed
  • Bundles And Licensing

    rshankras/claude-code-apple-skills

    Revenue beyond the single-app price tag — own-app bundles, Family Sharing as a conversion lever, cross-developer bundles & suites, and institutional licensing via Group Purchases / Apple School &…

    783 GitHub stars~1.8k tokensUpdated 2 mo ago
    Auto-check passed

Categories

Questions about Push Notifications

What does Push Notifications do?

Generate push notification infrastructure with APNs registration, handling, and rich notifications. Push Notifications is an agent skill from rshankras/claude-code-apple-skills. Generate push notification infrastructure with APNs registration, handling, and rich notifications.

When should I use Push Notifications?

Push Notifications fits situations like: adding push notifications; configuring APNs; notification categories/actions; rich notifications with images and custom UI.

How do I install Push Notifications in Claude Code?

Run `npx skills add rshankras/claude-code-apple-skills --skill push-notifications -a claude-code`. Or copy the skill folder (skills/generators/push-notifications in rshankras/claude-code-apple-skills) into .claude/skills/push-notifications in your project. Claude Code loads it when a task matches its description.

How do I install Push Notifications in Codex?

Run `npx skills add rshankras/claude-code-apple-skills --skill push-notifications -a codex`. Or copy the skill folder (skills/generators/push-notifications in rshankras/claude-code-apple-skills) into .agents/skills/push-notifications in your project. Codex loads it when a task matches its description.

Can I use Push Notifications in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add rshankras/claude-code-apple-skills --skill push-notifications -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/push-notifications, .gemini/skills/push-notifications, .github/skills/push-notifications and .opencode/skills/push-notifications in your project.

What does Push Notifications need to run?

Going by SKILL.md and its folder, Push Notifications needs Swift for the scripts in its folder, the command-line tools its instructions call (curl) and credentials named JWT_TOKEN and DEVICE_TOKEN. Our summary lists: A credential in JWT_TOKEN; A credential in DEVICE_TOKEN. Its frontmatter pre-approves these tools: Read, Write, Edit, Glob, Grep, Bash, AskUserQuestion.

Does Push Notifications access the network?

SKILL.md names 2 domains. In commands or code: api.sandbox.push.apple.com; the agent is likely to contact it when it follows the instructions. As links in the text: developer.apple.com. This is read from the text; nothing was executed.

Is Push Notifications safe to install?

Our automated static check of SKILL.md found notes only (pre-approves every shell command (allowed-tools: bash)), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.

What licence does Push Notifications use?

Push Notifications is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Push Notifications use?

About 2.3k tokens (SKILL.md is roughly 9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Push Notifications?

Skills that share tags, products or a category with Push Notifications: Swiftui Pro (twostraws/SwiftUI-Agent-Skill, 5.1k stars), Swiftui UI Patterns (AFK-surf/OpenBridge, 430 stars), Swiftui Performance Audit (harperreed/dotfiles, 334 stars) and Swift Testing Expert (AvdLee/Swift-Testing-Agent-Skill, 469 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Push Notifications?

rshankras (a GitHub user) maintains it in rshankras/claude-code-apple-skills, which has 783 GitHub stars. The repository holds 41 skills in this directory. The repository was last updated on July 24, 2026.

Source: rshankras/claude-code-apple-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.