OneSignal's REST API enables developers to automate the delivery of push notifications, manage users and segments, and gather analytics to refine communication strategies. By integrating OneSignal with Pipedream, you can orchestrate complex workflows that react to events or schedules, synchronize user data across platforms, and personalize user engagement with cross-channel marketing tools.
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
onesignal_rest_api: {
type: "app",
app: "onesignal_rest_api",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://onesignal.com/api/v1/players`,
headers: {
"Authorization": `Basic ${this.onesignal_rest_api.$auth.rest_api_key}`,
},
params: {
app_id: `${this.onesignal_rest_api.$auth.app_id}`,
},
})
},
})
User Activity-Based Notifications: Trigger personalized push notifications via OneSignal when a user performs a specific action in your app, such as completing a purchase. Use Pipedream to listen for the event, process the user's activity, and call the OneSignal API to send a tailored message.
Scheduled Digest Notifications: Compile and send daily or weekly digest notifications to users by collecting updates or content from various sources (like RSS feeds, website updates, or database records). Pipedream can automate the aggregation of content and scheduling of notification dispatches with OneSignal at predefined intervals.
Multi-Channel User Engagement: Enhance user retention by connecting OneSignal with email marketing services (e.g., Mailchimp) using Pipedream. Detect inactive users via OneSignal analytics, then automatically enroll them in re-engagement email campaigns, harmonizing push notifications with email outreach.
OneSignal (REST API) uses API keys for authentication. When you connect your OneSignal (REST API) account, Pipedream securely stores the keys so you can easily authenticate to OneSignal (REST API) APIs in both code and no-code steps.
You can find the your app's REST API Key and App ID in Settings > Keys & IDs.