Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: New name

This article describes what you need to consider when implementing your own mobile app using Smart ID Mobile SDK and you want to get push notifications triggered from Smart ID Digital Access component (Hybrid Access Gateway)

  1. Your app must register its current device token together with a list of currently installed profile IDs (push IDs), using a Device registration API that you must implement in your organization's notification server. The mandatory data is described below.
  2. Hybrid Smart ID Digital Access Gateway component will post requests for all known profile IDs by using the Push API described below. This data can be used in push notifications and handled in your mobile app. This logic must also be implemented by your organization, both the notification server and the mobile app.  

This image shows the communication between the mobile app, Personal Smart ID Messaging and Hybrid Smart ID Digital Access Gatewaycomponent


Image RemovedImage Added

Device registration API

Your organization's notification server must know the correlation between the profile ID (push ID) and the vendor and device ID. Therefore you must implement a Device registration API with the following details, which the app must provide: 

  • profileID - this equals pushId in the Push API 
  • OS:
    • iOS
    • Android
  • deviceID:
    • For iOS: device token
    • For Android: device registration token


For more information, see 

Push API

Smart ID Digital Access component (Hybrid Access Gateway) will send a REST (POST) request to your company's notification server with the following data which can be used in the push notifications:

Expand
titlePOST /https://<url-to-my-pushserver>/

Description

Sends a push notification to the Personal Smart ID Mobile App. 

Method

POST

JSON data

Code Block
titleJSON data
{
  "messageId": "7bcc1708-be42-48f4-ac67-c76afddae805",
  "pushId": " 74db355b-ecec-48b4-a4d8-9e6f13084bab",
  "requestor": "Acme",
  "type": "AUTH"
}


JSON schema

Code Block
titleJSON schema
{
   "type":"object",
   "required":[
      "pushId",
      "requestor",
      "type",
      "messageId"
   ],
   "properties":{
      "pushId":{
         "type":"string",
         "description":"Globally unique push identifier. Make sure that the app uses the same id. E.g. base64(mbox-url)"
      },
      "requestor":{
         "type":"string",
         "description":"Requestor of the push notification"
      },
      "type":{
         "type":"string",
         "enum":[
            "AUTH",
            "SIGN"
         ],
         "description":"Type of push"
      },
      "messageId":{
         "type":"string",
         "description":"Id of message which notification is sent for"
      },
      "timeToLive":{
         "type":"integer",
         "description":"OPTIONAL - Time to live for notification (will override configured value)"
      }        
   }
}