with Adhook and Formatting?
Emit new event when a new post is created. See the documentation
Generates a personalized calendar event in AdHook. See the documentation
Adds a new post or modifies an existing post in Adhook. See the documentation
import { axios } from "@pipedream/platform"
export default defineComponent({
  props: {
    adhook: {
      type: "app",
      app: "adhook",
    }
  },
  async run({steps, $}) {
    return await axios($, {
      url: `https://app.adhook.io/api/v1/promotions`,
      headers: {
        Authorization: `Bearer ${this.adhook.$auth.oauth_access_token}`,
      },
    })
  },
})
export default defineComponent({
  async run({ steps, $ }) {
    const text = ' Hello world! ';
    return text.trim()
  },
})