Fuel product growth and team agility. Heap automatically captures web and mobile app behavioral data. Retroactively analyze behavioral data without writing code.
Go to siteimport { axios } from "@pipedream/platform"
export default defineComponent({
props: {
heap: {
type: "app",
app: "heap",
}
},
async run({steps, $}) {
// From the docs: https://docs.heap.io/reference#track-1
// "Requests are limited to 30 requests per 30 seconds per identity per app_id"
return await axios($, {
method: "POST",
url: `https://heapanalytics.com/api/track`,
headers: {
"Content-Type": "application/json",
},
data: {
app_id: this.heap.$auth.app_id,
identity: params.identity,
event: params.event,
timestamp: params.timestamp || (new Date()).toISOString(),
properties: params.properties,
}
})
},
})
Heap uses API keys for authentication. When you connect your Heap account, Pipedream securely stores the keys so you can easily authenticate to Heap APIs in both code and no-code steps.
Your Heap app ID is the number given to you by Heap when you first installed the app, found in your tracking code.