Doubtless, it is crucial to inform the gambler of new aspects of the games, exclusive Microgaming casino bonuses or any other important information. So, we need additional special notifications to an app. There are 2 types of them: live and sandboxed, where only the second one works at the stage of development as well as in the normal regime.
We will establish a demo version, let’s call it Mcasinos, and include push notifications. Notwithstanding, firstly, you have to comply with certain elements:
- Create an Xcode’ project, but don’t add content there.
- Have an entry to a Developer acc.(paid one)
- Obtain at least one (or more) Development Certificate (only for iOS).
- Remember, that, here, push notifications = APN (Apple Push Notifications).
Certificate Signing Request (CSR)
Procedure to make it: find in your Mac device Keychain Access app. Then, look for a line ”Certificate Assistance” and, later on, ” Request a certificate…”. After, there will be few boxes to insert: email and name. On that page, choose “saved to disk”. Press “continue” and, later, “done”.
Identifying a Microgaming App with ID
You need to obtain a Microgaming iPhone App ID:
- Visit a center for developers > then, “Certificates, Identifiers…” > Identifiers > App IDs (category-Identifiers) > find “+” (top-right).
- Fill in 2 forms: App ID Description (regardless to content) and Bundle ID (copy the title of the project). Other notions leave by default.
- Scroll to the bloc of App Services. Find “Push Notif….” and tick there.
- Click on “Continue” > Submit (after verification) > Registration Complete page > Done.
Generate the CSR
- Find a button “Edit” (App ID) > Push Notif.. > Development SSL > Create Certificate…
- “Continue” > choose a file of your CSR > Generate > Download >.
- This new doc will be in a “login” part (top-left). Make a right click on that file and choose “Export…” > Save. > Skip the password page. > Done.
Register the Testing Device
Open Xcode > afterwards, Window > Devices > choose your phone/tablet > double click on “identifier” field and copy it. Then, go to website of Apple Developers > category “Devices” > click on “All” > find “+” (top-right). Tape the name and paste an identifier to UDID > Continue. > Register.
iOS Provisioning Profile
- Apple Developer’s address > Provisioning Profiles > Development > Click on “+” button.
- iOS App Development > Continue.
- Connect the project with the ID.
- Include a relevant iOS Development certificate > Continue.
- Choose the appropriate devices > Continue.
- Tape a name, like “Development Profile – Mcasinos” > Generate > Download (.mobileprovision file).
- Double click – install it.
- Open Xcode, find the project in the main Project Navigator.
- General tab > Team > Find a proper team.
- Capabilities tab > Push Notifications section (turn it on).
- Build Setting tab > section of “Code Signing” > Provisioning Prof. > Debug > choose “Automatic”.
- The same section > the arrow in Code Signing Identity > Debug > iOS (sometimes, iPhone) Developer > Click on a proper category.
- General tab (top-left) > Target > Select the Project.
Next step – to code a right type(s) of the notification. It is the lightest part, which takes a couple of minutes to do. Open a file “AppDelegate.swift” and use a method of “application (_:didFinishLaunchingWithOptions:)”.
Useful Delegate Methods for Microgaming Casino App
Now, we have to establish a proper way of sending the text: conditions to send it, whether the Microgaming casino should be on or not, etc. There are plenty of such schemes. Look separately for all of them to pick the most convenient for your device.
Testing Push Notifications
There are many special programs, which help to check the result of the work. We will take, as an example, “APN Tester Free”. Open it, fill in 3 boxes before clicking on push:
- Device token: find it in a console of your app.
- Payload, where “alert” is an actual text (f.e. Check our new weekly bonuses), “badge”: 1 and “sound”: “default”.
- Certificate – browse in the device. Usually, it is called as aps_development.cer.