All Projects → hagmas → APNsKit

hagmas / APNsKit

Licence: MIT license
A framework to send Apple Notifications

Programming Languages

swift
15916 projects
objective c
16641 projects - #2 most used programming language

Projects that are alternatives of or similar to APNsKit

Rpush
The push notification service for Ruby.
Stars: ✭ 1,886 (+9330%)
Mutual labels:  notification-service, apns
PushMeBaby
iOS Push Notification Debug App. You can use this app during iOS Push Notification (development or production) to push notifications on your device from your Mac.
Stars: ✭ 47 (+135%)
Mutual labels:  notification-service, apns
pg-deadlock-playground
Playground for verifying that queries cannot deadlock
Stars: ✭ 17 (-15%)
Mutual labels:  playground
meeting-app-unit-tests-playground
Unit tests patterns when using JEST and Vue2 (vue-test-utils)
Stars: ✭ 21 (+5%)
Mutual labels:  playground
Forum-Advanced
This is built on Laravel Framework 5.5. This was built for demonstrate purpose.
Stars: ✭ 14 (-30%)
Mutual labels:  notification-service
merge-request-notifier
This app shows your merge requests grouped by projects and WIP status. It is accessible from the system tray.
Stars: ✭ 47 (+135%)
Mutual labels:  notification-service
whats-new-in-swift-5-2
An Xcode playground that demonstrates the new features introduced in Swift 5.2.
Stars: ✭ 94 (+370%)
Mutual labels:  playground
apns
Helpful extensions and abstractions for using APNSwift
Stars: ✭ 75 (+275%)
Mutual labels:  apns
Gunfish
No description or website provided.
Stars: ✭ 35 (+75%)
Mutual labels:  apns
react-runner
Run your React code on the go
Stars: ✭ 308 (+1440%)
Mutual labels:  playground
pushex
Push notifications for Elixir
Stars: ✭ 96 (+380%)
Mutual labels:  apns
OneSignal-Codeigniter-Push-Notification
OneSignal is a free push notification service for web and mobile apps. This Codeigniter example makes it easy to integrate your website with OneSignal Push Notifications. https://onesignal.com/ DEMO - http://ci3onesignal.codefort.ru/
Stars: ✭ 27 (+35%)
Mutual labels:  notification-service
HeadFirstDesignPatternsSwift
An implementation of examples from "Head First Design Patterns", written in Swift.
Stars: ✭ 20 (+0%)
Mutual labels:  playground
prompts-ai
Advanced playground for GPT-3
Stars: ✭ 156 (+680%)
Mutual labels:  playground
apns-guide
🔔 Guide to setup APNS
Stars: ✭ 82 (+310%)
Mutual labels:  apns
A-World-of-Circles
WWDC 2017 Scholarship Recipient. A Swift Playgrounds Book that visually teaches the relationship between sines and circles.
Stars: ✭ 24 (+20%)
Mutual labels:  playground
CodeINN
CodeINN is an instant code editor 📃, that makes programming and development easier. Practice quickly and directly from your web browser, without any setup needed. CodeINN gives the perfect environment to developers technologists, coders computers, and geeks 🤓 to do more with their tech.
Stars: ✭ 39 (+95%)
Mutual labels:  playground
apnsapi
Simple apns api (http/2) client for golang.
Stars: ✭ 21 (+5%)
Mutual labels:  apns
mobile-messaging-sdk-ios
Mobile Messaging SDK for iOS
Stars: ✭ 45 (+125%)
Mutual labels:  apns
extkeras
Playground for implementing custom layers and other components compatible with keras, with the purpose to learn the framework better and perhaps in future offer some utils for others.
Stars: ✭ 18 (-10%)
Mutual labels:  playground

APNsKit

A framework to send Apple notifications.

Carthage compatible

About APNsKit

APNsKit is a swift framework to send Apple notifications to iOS devices. Especially, with Playground it lets you to create interactive tool to send push notifications for debugging purposes. Check out the Playground PushViewController.playground bundled with the Workspace.

Usage

import APNsKit

// Setting header fields is optional. Refer (#1) for configurable header fields of APNs request.
let header = APNsRequest.Header(priority: .p10, topic: "<#The topic of the remote notification#>")

// Create a APNs payload. See Apple's Payload Key Reference (#2) for its specifications.
let payload = APNsPayload(title: "Hello World!", body: "This is APNsKit.", contentAvailable: 1)
let request = APNsRequest(port: .p2197,
                          server: .development,
                          deviceToken: "<#The target device token#>",
                          header: header,
                          payload: payload)

// Create a connection that wraps up URLSession and its authentication challenges.
if let connection = try? Connection(p12FileName: "<#Your p12 file name#>", passPhrase: "<#The pass phrase for the file#>") {
    
    // Send the request to the APNs server. The connection has to be retained until the server responses.
    connection.send(request: request, resultHandler: { result in
        switch result {
        case .success:
            print("Succeeded!")
        case .failure(let code, let message):
            print("Failed to send: \(code), \(message)")
        }
    })
}

#1 HTTP/2 Request to APNs

#2 Apple's Payload Key Reference

Requirements

  • Xcode 8.2.1
  • Swift 3.0

Installation

  • APNsKit doesn't include any external depenancies.
  • APNsKit currently supports only Carthage.

Carthage

Tested with carthage version: 0.20.1

Add this to Cartfile

github "hagmas/APNsKit"
$ carthage update
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].