# Google Play Game Services API . pushtokens

## Instance Methods

Removes a push token for the current user and application. Removing a non-existent push token will report success.

Registers a push token for the current user and application.

### Method Details

`remove(body, consistencyToken=None)`

    Removes a push token for the current user and application. Removing a non-existent push token will report success.

    Args:
      body: object, The request body. (required)
        The object takes the form of:

    { # This is a JSON template for a push token ID resource.
      "kind": "games#pushTokenId", # Uniquely identifies the type of this resource. Value is always the fixed string games#pushTokenId.
      "ios": { # A push token ID for iOS devices.
        "apns_device_token": "A String", # Device token supplied by an iOS system call to register for remote notifications. Encode this field as web-safe base64.
        "apns_environment": "A String", # Indicates whether this token should be used for the production or sandbox APNS server.
      },
    }

      consistencyToken: string, The last-seen mutation timestamp.

`update(body, consistencyToken=None)`

    Registers a push token for the current user and application.

    Args:
      body: object, The request body. (required)
        The object takes the form of:

    { # This is a JSON template for a push token resource.
        "kind": "games#pushToken", # Uniquely identifies the type of this resource. Value is always the fixed string games#pushToken.
        "clientRevision": "A String", # The revision of the client SDK used by your application, in the same format that's used by revisions.check. Used to send backward compatible messages. Format: [PLATFORM_TYPE]:[VERSION_NUMBER]. Possible values of PLATFORM_TYPE are:
            # - IOS - Push token is for iOS
        "id": { # This is a JSON template for a push token ID resource. # Unique identifier for this push token.
          "kind": "games#pushTokenId", # Uniquely identifies the type of this resource. Value is always the fixed string games#pushTokenId.
          "ios": { # A push token ID for iOS devices.
            "apns_device_token": "A String", # Device token supplied by an iOS system call to register for remote notifications. Encode this field as web-safe base64.
            "apns_environment": "A String", # Indicates whether this token should be used for the production or sandbox APNS server.
          },
        },
        "language": "A String", # The preferred language for notifications that are sent using this token.
      }

      consistencyToken: string, The last-seen mutation timestamp.