with LogSnag and Microsoft Dataverse?
LogSnag is a real-time event tracking API that enables developers to monitor and track events in their applications. With LogSnag, you can create simple, powerful dashboards to watch events as they happen and set up triggers to notify you of important activities. On Pipedream, LogSnag's capabilities can be harnessed to automate workflows, integrating with numerous services to create a blend of operations, such as triggering notifications, logging significant events, and gathering metrics across various platforms.
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
logsnag: {
type: "app",
app: "logsnag",
}
},
async run({steps, $}) {
const data = {
"project": `[project_name]`,
"channel": `[channel]`,
"event": `Test request`,
"description": `Making a test request on LogSnag`,
}
return await axios($, {
method: "post",
url: `https://api.logsnag.com/v1/log`,
headers: {
Authorization: `Bearer ${this.logsnag.$auth.api_token}`,
"Content-Type": `application/json`,
},
data,
})
},
})
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
microsoft_dataverse: {
type: "app",
app: "microsoft_dataverse",
}
},
async run({steps, $}) {
return await axios($, {
url: `${this.microsoft_dataverse.$auth.environment_url}/api/data/v9.2/WhoAmI`,
headers: {
Accept: `application/json`,
Authorization: `Bearer ${this.microsoft_dataverse.$auth.oauth_access_token}`,
"OData-MaxVersion": `4.0`,
"OData-Version": `4.0`,
"Accept": `application/json`,
},
})
},
})