docs.unity3d.com
    Show / Hide Table of Contents

    Class PushNotifications

    Inheritance
    Object
    PushNotifications
    Namespace: Unity.Services.PushNotifications
    Syntax
    public class PushNotifications : object

    Properties

    Analytics

    Declaration
    public static PushNotificationAnalytics Analytics { get; }
    Property Value
    Type Description
    PushNotificationAnalytics

    Methods

    RegisterForPushNotificationsAsync(PushNotificationSettings)

    Registers for push notifications with the appropriate mechanism for the current platform.

    This method will automatically handle platform specific intricacies of getting a push notification token, and will send the appropriate analytics events to Unity Analytics 2.

    Declaration
    public static Task<string> RegisterForPushNotificationsAsync(PushNotificationSettings settings)
    Parameters
    Type Name Description
    PushNotificationSettings settings

    A PushNotificationSettings object with the settings for the SDK. See the documentation on that class for more information.

    Returns
    Type Description
    Task<String>

    (Asynchronously via a Task) The device token as a string.

    Events

    OnNotificationReceived

    Declaration
    public static event Action<Dictionary<string, object>> OnNotificationReceived
    Event Type
    Type Description
    Action<Dictionary<String, Object>>
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023