Find & Set Test Subscriptions
How to find and setup test subscriptions in OneSignal.
Audience > Subscriptions shows a list of every subscription in your OneSignal App, and Data Collected by the OneSignal SDK. More details in our Users guide.
There are 3 types of subscriptions. Check the Channel and Device columns for each time:
- Push Subscription. Has a "Push Notification Icon". Can be sent push notifications.
- Android, iOS, Huawei and Amazon mobile app push subscriptions can also get In-App Messages.
- Email Subscription. Has an "Email Icon". Can be sent email messages.
- SMS Subscription. Has a "Chat Icon". Can be sent SMS and MMS messages.
You can search for a user and all associated subscription records by the External ID or OneSignal ID (details in Aliases & External ID). If you don't know the ID of the user, you can search by email address or phone number to find it.
Set any subscriptions for a given user to be test subscriptions to make it easier to find them.
You can show/hide the data attributes with the columns button (1), search by Subscription ID, OneSignal ID, External ID, Email or Phone Number (2) and filter by Segments (3).
Test Subscriptions
Test Subscriptions are a group of records that you manage directly in order to test delivery of messages.
To add your device as a test subscription:
- First find your subscription. There are several options listed below.
- Once you have your External ID, OneSignal ID or Subscription ID, you can search for it (1), then next to the device record select Options > Add to Test Subscriptions (2).
Next you can Segment devices by Test Subscriptions Filter and/or send messages using the Send To Test Device Button.
Finding Subscriptions
There are a couple options for finding your device depending on the data you currently have.
Find your Subscription ID for Web Desktop
- Using the same browser profile you are subscribed to your site, open the site URL with the OneSignal code active.
- Open the Debugger console (F12 or Right Click the site > Inspect).
- Click the "Console" section
- Add this code:
OneSignal.User.PushSubscription.id
- You will see your OneSignal Subscription Id logged to the console if you have a device record.
You found your Subscription ID on Web!
Copy the Subscription ID without quotes and see above to add it as a Test Subscription.
Find your device for Web Mobile
- Plug your Android device subscribed to the site into your computer and visit your site on the Android device.
- On your desktop, open chrome to this url:
chrome://inspect/#devices
Your mobile device should prompt you to enable USB Debugging - Select the inspect button
- A new window on desktop should open to your site seen on the mobile device.
- Make sure the site URL is correct with the OneSignal code active.
- Click the "Console" section
- Add this code:
OneSignal.User.PushSubscription.id
- You will see your OneSignal Subscription ID logged to the console if you have a device record.
You found your Subscription ID on Web Mobile!
Copy the Subscription ID without quotes and see above to add it as a Test Subscription.
Find your device for Mobile App
Using the OneSignal SDK User Data Methods, plugin your device to Xcode or Android Studio and log the Subscription ID of your device in the console.
You found your Subscription ID on Mobile App!
Copy the Subscription ID without quotes and see above to add it as a Test Subscription.
Find Device by Tag
If you added a specific tag to the user like a user_name
, email
tag, or other identifier, you can create a Segment with the User Tag filter to find your specific device.
Find Subscription in Dashboard
Open your app or site with your subscribed device. Make sure you are visiting a page of your site/app with OneSignal initialized (code actively running). Then in your OneSignal dashboard Audience > Subscriptions sort by "Last Active" so the arrow points up to see the latest active devices.
You may need to confirm it is your device by making some data visible. Click the Displayed Columns List filter at the top-right. Some helpful data to check is:
Column | Details |
---|---|
External ID | This should be the same ID found in your database for your user. You may need to ask your developer for more info. |
Last Active | The most recent time the user visited the site/app. You may want to refresh the page to get updated values. |
First Session | The first time you subscribed to the website or opened the app with OneSignal code. Check if this is the first time you subscribed to the site/app. |
IP Address | If enabled, visit https://whatismyipaddress.com/ to see if the IPs match. More details in Data Collected by the OneSignal SDK |
Tags, Country | This is additional information that can be used to check if you know this data. |
Device | - Mobile Website subscribers will show "Linux Arm..." with the Browser icon and Browser version. - Desktop Website subscribers will show Mac or Win with Browser icon and Browser version. - Android Mobile Apps - will have the device model and corresponding icons. - iOS Mobile Apps - the model is based on the Hardware String. For example "iPhone9,3 (12.3.1)" means "iPhone 7 with operating system version 12.3.1". |
Updated about 2 months ago