SlideShare une entreprise Scribd logo
1  sur  24
back4app.com
Push Notifications With Dashboard
and Swift
Push Notifications With Dashboard and Swift
• In this guide, we will show how properly set your app to work with Parse
Push notifications and how send a notification from Parse Dashboard.
• You can read the original publication on:
• http://docs.back4app.com/docs/ios/push-notifications-with-dashboard-and-
swift/
Step 1: Register your app to receive notification
1. To make you app support Push Notifications, your app must use an Explicit
App ID.
• Navigate to the Apple Developer
Member Center website,
and click on Certificates,
Identifiers & Profiles.
Step 1: Register your app to receive notification
2. Select Identifiers on the iOS Apps section.
3. You will see a list of your App IDs. Click on the + button.
4. Enter a name for your new App ID under App ID Description, choose an App
Id Prefix, and under App ID Suffix, select Explicit App ID, enter your iOS app’s
Bundle ID, it should match the Bundle Identifier in your Xcode project
configuration and in the Info.plist file.
Step 1: Register your app to receive notification
5. Enable Push Notifications under App Services. Enable other services that
your app will need.
6. Click on “Continue”, confirm that all values were entered correctly. Click on
“Submit”.
Step 1: Register your app to receive notification
• Now that you’ve created the App ID, you need to configure the App ID for
Push Notifications.
1. Select your new App ID
and click on “Edit”.
Step 1: Register your app to receive notification
2. Scroll down to the Push Notifications section.
• Click on “Create Certificate”
under “Development SSL
Certificate”.
Step 1: Register your app to receive notification
3. Follow the instructions in the next screen to create a Certificate Signing
Request (CSR) using the Keychain Access utility on your Mac.
• This is needed to authenticate the creation of the SSL certificate.
4. Upload the CSR to Apple’s servers, then click on “Generate”.
Step 1: Register your app to receive notification
5. Add the certificate to your login keychain.
Step 1: Register your app to receive notification
6. Open the Keychain Access utility, and locate the certificate under “My
Certificates”.
It should be called “Apple Development Push Services:”.
Right-click on it, select “Export”, and save it as a .p12 file.
Step 1: Register your app to receive notification
Do not enter an export password when prompted!
Step 1: Register your app to receive notification
• You will need to repeat the process to make the Production SSL Certificate.
• Now we need to configure the Xcode project.
Step 1: Register your app to receive notification
1. Go to your project’s Capabilities page, then turn On Push Notifications. If
there are any issues that require your attention, Xcode will let you know.
Step 1: Register your app to receive notification
2. Go to the General page.
• Modify the Bundle Identifier to match your App ID’s Bundle Identifier.
Step 2: Register your app to receive notification
in the back4app Dashboard
1. Go to your app back4app Dashboard
2. Click on “iOS Push Notification Settings”
Step 2: Register your app to receive notification
in the back4app Dashboard
3. Click on “Choose File”, select your .p12 certificate, then click on “Send”
Step 3: Implement Push Notifications Functions
1. Go to AppDelegate.swift file.
• In the application: didFinishLaunchWithOptions method, insert the
following code after the Parse initialization:
• This code are notifications types and settings for the app
Step 3: Implement Push Notifications Functions
2. Next we have to register the application, to make it capable of receive and
send notifications. Just add this code bellow the code you just have write:
Step 3: Implement Push Notifications Functions
3. Next we have to subscribe the app in a channel for enable the background’s
notifications.
• Insert this code in the AppDelegate.swift file:
• Now the app can receive background notifications.
Step 3: Implement Push Notifications Functions
4. It’s also possible to send notifications to just a group of people.
• For this, we have to register the app for the group’s channel.
• When you send a notification to a channel, all the app’s installations that
have the channel in the channels field will receive the notification.
Step 3: Implement Push Notifications Functions
• To register a installation in a channel, we use the following code:
• Now the device will receive all the notifications directed to be back4app
channel.
Step 3: Implement Push Notifications Functions
• 5. If now we dont want anymore to the device receive notifications in
back4app channel, we just need to unregister the installation in the back4app
channel:
Step 3: Implement Push Notifications Functions
• We can check whats channels the installation is registered using the channels
field of the PFInstallation object:
Step 4: Sending notification from Dashboard
1. Go to your app’s Parse Dashboard, and click on Push.
2. Now chose the audience of the notification. You can send notifications to
everyone and for a specific platform.
3. Write the notification text, then click on Send Push to send your
notification.

Contenu connexe

Tendances

Developing your personal Twitter web application in 60 minustes
Developing your personal Twitter web application in 60 minustesDeveloping your personal Twitter web application in 60 minustes
Developing your personal Twitter web application in 60 minustes
Mitesh Sanghvi
 
DevelopmentIntegrationGuides-Warbler
DevelopmentIntegrationGuides-WarblerDevelopmentIntegrationGuides-Warbler
DevelopmentIntegrationGuides-Warbler
Mark Dunlap
 

Tendances (18)

ApiDD Consumer
ApiDD ConsumerApiDD Consumer
ApiDD Consumer
 
Developing your personal Twitter web application in 60 minustes
Developing your personal Twitter web application in 60 minustesDeveloping your personal Twitter web application in 60 minustes
Developing your personal Twitter web application in 60 minustes
 
OpManager - Clickatell integration for SMS notification
OpManager - Clickatell integration for SMS notificationOpManager - Clickatell integration for SMS notification
OpManager - Clickatell integration for SMS notification
 
Linkdialler
LinkdiallerLinkdialler
Linkdialler
 
Apidd Member Management
Apidd Member ManagementApidd Member Management
Apidd Member Management
 
How to get data from twitter (by hnnrrhm)
How to get data from twitter (by hnnrrhm)How to get data from twitter (by hnnrrhm)
How to get data from twitter (by hnnrrhm)
 
Icon in iphone itouch
Icon in iphone itouchIcon in iphone itouch
Icon in iphone itouch
 
Approck dealer portal
Approck dealer portalApprock dealer portal
Approck dealer portal
 
Rest security in mule
Rest security in muleRest security in mule
Rest security in mule
 
Readme
ReadmeReadme
Readme
 
EasiShare AWS Setup Guide
EasiShare AWS Setup GuideEasiShare AWS Setup Guide
EasiShare AWS Setup Guide
 
Indonesia data-lake
Indonesia data-lakeIndonesia data-lake
Indonesia data-lake
 
IoT Quick Demo for Heroku & Salesforce
IoT Quick Demo for Heroku & SalesforceIoT Quick Demo for Heroku & Salesforce
IoT Quick Demo for Heroku & Salesforce
 
Rest security with oauth 2.0
Rest security with oauth 2.0Rest security with oauth 2.0
Rest security with oauth 2.0
 
How to get registered in salesforce
How to get registered in salesforceHow to get registered in salesforce
How to get registered in salesforce
 
Selenium training in Chennai
Selenium training in Chennai Selenium training in Chennai
Selenium training in Chennai
 
How to Use IFTTT
How to Use IFTTTHow to Use IFTTT
How to Use IFTTT
 
DevelopmentIntegrationGuides-Warbler
DevelopmentIntegrationGuides-WarblerDevelopmentIntegrationGuides-Warbler
DevelopmentIntegrationGuides-Warbler
 

En vedette

Image Slide ( Animal Companion in Maze )
Image Slide ( Animal Companion in Maze )Image Slide ( Animal Companion in Maze )
Image Slide ( Animal Companion in Maze )
tadamasa yamaguchi
 

En vedette (13)

อุปกรณ์เชื่อมต่อคอมพิวเตอร์
อุปกรณ์เชื่อมต่อคอมพิวเตอร์อุปกรณ์เชื่อมต่อคอมพิวเตอร์
อุปกรณ์เชื่อมต่อคอมพิวเตอร์
 
Firebase vs Parse Server - Português
Firebase vs Parse Server - PortuguêsFirebase vs Parse Server - Português
Firebase vs Parse Server - Português
 
Image Slide ( Animal Companion in Maze )
Image Slide ( Animal Companion in Maze )Image Slide ( Animal Companion in Maze )
Image Slide ( Animal Companion in Maze )
 
CV-C.Mouli
CV-C.MouliCV-C.Mouli
CV-C.Mouli
 
อุปกรณ์เชื่อมต่อคอมพิวเตอร์
อุปกรณ์เชื่อมต่อคอมพิวเตอร์อุปกรณ์เชื่อมต่อคอมพิวเตอร์
อุปกรณ์เชื่อมต่อคอมพิวเตอร์
 
ORIGEN DE LOS HIDROCARBUROS
ORIGEN DE LOS HIDROCARBUROSORIGEN DE LOS HIDROCARBUROS
ORIGEN DE LOS HIDROCARBUROS
 
イメージ
イメージイメージ
イメージ
 
อุปกรณ์เชื่อมต่อคอมพิวเตอร์
อุปกรณ์เชื่อมต่อคอมพิวเตอร์อุปกรณ์เชื่อมต่อคอมพิวเตอร์
อุปกรณ์เชื่อมต่อคอมพิวเตอร์
 
Estructura naomi hara
Estructura naomi haraEstructura naomi hara
Estructura naomi hara
 
Final Dissertation
Final DissertationFinal Dissertation
Final Dissertation
 
How to build a Pokemon Go App
How to build a Pokemon Go AppHow to build a Pokemon Go App
How to build a Pokemon Go App
 
Gecko Labs - Our Student Engagement Solutions
Gecko Labs - Our Student Engagement SolutionsGecko Labs - Our Student Engagement Solutions
Gecko Labs - Our Student Engagement Solutions
 
Denim Garments Quality Control and Inspection Services
Denim Garments Quality Control and Inspection ServicesDenim Garments Quality Control and Inspection Services
Denim Garments Quality Control and Inspection Services
 

Similaire à Push notifications with dashboard and swift

Firefox marketplace
Firefox marketplaceFirefox marketplace
Firefox marketplace
Tina Verbo
 

Similaire à Push notifications with dashboard and swift (20)

iOS Distribution and App store pushing and more
iOS Distribution and App store pushing and moreiOS Distribution and App store pushing and more
iOS Distribution and App store pushing and more
 
Flutter Android / iOS Build Preparation
Flutter Android / iOS Build PreparationFlutter Android / iOS Build Preparation
Flutter Android / iOS Build Preparation
 
StackLabs-DataDriven Labs - iPhone App Development Training in Mohali
StackLabs-DataDriven Labs - iPhone App Development  Training in MohaliStackLabs-DataDriven Labs - iPhone App Development  Training in Mohali
StackLabs-DataDriven Labs - iPhone App Development Training in Mohali
 
Hospital app project (how to upload app)
Hospital app project (how to upload app)Hospital app project (how to upload app)
Hospital app project (how to upload app)
 
Ios development training presentation
Ios development training presentationIos development training presentation
Ios development training presentation
 
Appium_set_up
Appium_set_upAppium_set_up
Appium_set_up
 
iPhone first App Store submission
iPhone  first App Store submissioniPhone  first App Store submission
iPhone first App Store submission
 
Apple notification push
Apple notification pushApple notification push
Apple notification push
 
Build apps for slack
Build apps for slackBuild apps for slack
Build apps for slack
 
iPhone University Developer Program
iPhone University Developer ProgramiPhone University Developer Program
iPhone University Developer Program
 
vident Ilink400 update guide vxdas
vident Ilink400 update guide   vxdasvident Ilink400 update guide   vxdas
vident Ilink400 update guide vxdas
 
Firefox marketplace
Firefox marketplaceFirefox marketplace
Firefox marketplace
 
Provisioning Profile
Provisioning ProfileProvisioning Profile
Provisioning Profile
 
iOS App Distribution Tactics – What If I Don’t Want to Use App Store_.pdf
iOS App Distribution Tactics – What If I Don’t Want to Use App Store_.pdfiOS App Distribution Tactics – What If I Don’t Want to Use App Store_.pdf
iOS App Distribution Tactics – What If I Don’t Want to Use App Store_.pdf
 
Facebook SSO.docx
Facebook SSO.docxFacebook SSO.docx
Facebook SSO.docx
 
Configure & send push notification on i os device
Configure & send push notification on i os deviceConfigure & send push notification on i os device
Configure & send push notification on i os device
 
Push Notification with Unity in iOS using App42 Backend
Push Notification with Unity in iOS using App42 BackendPush Notification with Unity in iOS using App42 Backend
Push Notification with Unity in iOS using App42 Backend
 
Osx workflow guide (1)
Osx workflow guide (1)Osx workflow guide (1)
Osx workflow guide (1)
 
12 simple steps to prepare your i os app for development and distribution (1)...
12 simple steps to prepare your i os app for development and distribution (1)...12 simple steps to prepare your i os app for development and distribution (1)...
12 simple steps to prepare your i os app for development and distribution (1)...
 
The Mobile ToolChain with Fastlane - Code Red Talk at RedBlackTree
The Mobile ToolChain with Fastlane - Code Red Talk at RedBlackTreeThe Mobile ToolChain with Fastlane - Code Red Talk at RedBlackTree
The Mobile ToolChain with Fastlane - Code Red Talk at RedBlackTree
 

Dernier

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 

Dernier (20)

Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 

Push notifications with dashboard and swift

  • 2. Push Notifications With Dashboard and Swift • In this guide, we will show how properly set your app to work with Parse Push notifications and how send a notification from Parse Dashboard. • You can read the original publication on: • http://docs.back4app.com/docs/ios/push-notifications-with-dashboard-and- swift/
  • 3. Step 1: Register your app to receive notification 1. To make you app support Push Notifications, your app must use an Explicit App ID. • Navigate to the Apple Developer Member Center website, and click on Certificates, Identifiers & Profiles.
  • 4. Step 1: Register your app to receive notification 2. Select Identifiers on the iOS Apps section. 3. You will see a list of your App IDs. Click on the + button. 4. Enter a name for your new App ID under App ID Description, choose an App Id Prefix, and under App ID Suffix, select Explicit App ID, enter your iOS app’s Bundle ID, it should match the Bundle Identifier in your Xcode project configuration and in the Info.plist file.
  • 5. Step 1: Register your app to receive notification 5. Enable Push Notifications under App Services. Enable other services that your app will need. 6. Click on “Continue”, confirm that all values were entered correctly. Click on “Submit”.
  • 6. Step 1: Register your app to receive notification • Now that you’ve created the App ID, you need to configure the App ID for Push Notifications. 1. Select your new App ID and click on “Edit”.
  • 7. Step 1: Register your app to receive notification 2. Scroll down to the Push Notifications section. • Click on “Create Certificate” under “Development SSL Certificate”.
  • 8. Step 1: Register your app to receive notification 3. Follow the instructions in the next screen to create a Certificate Signing Request (CSR) using the Keychain Access utility on your Mac. • This is needed to authenticate the creation of the SSL certificate. 4. Upload the CSR to Apple’s servers, then click on “Generate”.
  • 9. Step 1: Register your app to receive notification 5. Add the certificate to your login keychain.
  • 10. Step 1: Register your app to receive notification 6. Open the Keychain Access utility, and locate the certificate under “My Certificates”. It should be called “Apple Development Push Services:”. Right-click on it, select “Export”, and save it as a .p12 file.
  • 11. Step 1: Register your app to receive notification Do not enter an export password when prompted!
  • 12. Step 1: Register your app to receive notification • You will need to repeat the process to make the Production SSL Certificate. • Now we need to configure the Xcode project.
  • 13. Step 1: Register your app to receive notification 1. Go to your project’s Capabilities page, then turn On Push Notifications. If there are any issues that require your attention, Xcode will let you know.
  • 14. Step 1: Register your app to receive notification 2. Go to the General page. • Modify the Bundle Identifier to match your App ID’s Bundle Identifier.
  • 15. Step 2: Register your app to receive notification in the back4app Dashboard 1. Go to your app back4app Dashboard 2. Click on “iOS Push Notification Settings”
  • 16. Step 2: Register your app to receive notification in the back4app Dashboard 3. Click on “Choose File”, select your .p12 certificate, then click on “Send”
  • 17. Step 3: Implement Push Notifications Functions 1. Go to AppDelegate.swift file. • In the application: didFinishLaunchWithOptions method, insert the following code after the Parse initialization: • This code are notifications types and settings for the app
  • 18. Step 3: Implement Push Notifications Functions 2. Next we have to register the application, to make it capable of receive and send notifications. Just add this code bellow the code you just have write:
  • 19. Step 3: Implement Push Notifications Functions 3. Next we have to subscribe the app in a channel for enable the background’s notifications. • Insert this code in the AppDelegate.swift file: • Now the app can receive background notifications.
  • 20. Step 3: Implement Push Notifications Functions 4. It’s also possible to send notifications to just a group of people. • For this, we have to register the app for the group’s channel. • When you send a notification to a channel, all the app’s installations that have the channel in the channels field will receive the notification.
  • 21. Step 3: Implement Push Notifications Functions • To register a installation in a channel, we use the following code: • Now the device will receive all the notifications directed to be back4app channel.
  • 22. Step 3: Implement Push Notifications Functions • 5. If now we dont want anymore to the device receive notifications in back4app channel, we just need to unregister the installation in the back4app channel:
  • 23. Step 3: Implement Push Notifications Functions • We can check whats channels the installation is registered using the channels field of the PFInstallation object:
  • 24. Step 4: Sending notification from Dashboard 1. Go to your app’s Parse Dashboard, and click on Push. 2. Now chose the audience of the notification. You can send notifications to everyone and for a specific platform. 3. Write the notification text, then click on Send Push to send your notification.

Notes de l'éditeur

  1. Davi
  2. Alysson
  3. Alysson
  4. Alysson
  5. Alysson
  6. Alysson
  7. Alysson
  8. Alysson
  9. Alysson
  10. Alysson
  11. Alysson
  12. Alysson
  13. Alysson
  14. Alysson
  15. Alysson
  16. Alysson
  17. Alysson
  18. Alysson
  19. Alysson
  20. Alysson
  21. Alysson
  22. Alysson
  23. Alysson
  24. Alysson