with Campaign Monitor and PostHog?
Emit new event when a new subscriber is added to a specific list
Emit new event when an action is performed in a project. See the documentation
Creates a new subscriber on a specific list. See the documentation
Captures a given event within the PostHog system. See the documentation
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
campaign_monitor: {
type: "app",
app: "campaign_monitor",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://api.createsend.com/api/v3.3/primarycontact.json`,
headers: {
Authorization: `Bearer ${this.campaign_monitor.$auth.oauth_access_token}`,
"Content-Type": `application/json; charset=utf-8`,
},
})
},
})
The PostHog API lets you track events, update user properties, and extract analytics to understand user behavior within your applications. Integrating this API into Pipedream workflows allows you to automate actions based on event data, sync user properties across platforms, and trigger alerts or notifications.
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
posthog: {
type: "app",
app: "posthog",
}
},
async run({steps, $}) {
return await axios($, {
url: `https:///${this.posthog.$auth.instance_url}/api/users/@me/`,
headers: {
Authorization: `Bearer ${this.posthog.$auth.api_key}`,
},
})
},
})