RegisterPushNotificationToken
Overview
The RegisterPushNotificationToken
endpoint registers a push notification token for your account.
POST https://rivian.com/api/gql/gateway/graphql
Required Headers
a-sess: <your app session token>
u-sess: <your user session token>
csrf-token: <your CSRF token>
Request Body
{
"operationName": "RegisterPushNotificationToken",
"variables": {
"data": {
"locale": "en_US",
"token": <your-push-token>,
"type": "FCM",
"userId": <your-user-id>
}
},
"query": "mutation RegisterPushNotificationToken($data: RegistrationInput!) { registerPushNotificationToken(data: $data) { __typename deviceTokenId locale success token } }"
}
Example Response
{
"data": {
"registerPushNotificationToken": {
"__typename": "RegistrationResponse",
"deviceTokenId": <your-device-token-id>,
"locale": "en_US",
"success": true,
"token": <your-push-token>
}
}
}