with Buddy and Sanity?
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
buddy: {
type: "app",
app: "buddy",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://api.buddy.works/user`,
headers: {
Authorization: `Bearer ${this.buddy.$auth.oauth_access_token}`,
},
})
},
})
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
sanity: {
type: "app",
app: "sanity",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://${this.sanity.$auth.project_id}.api.sanity.io/v2021-06-07/data/query/production`,
headers: {
Authorization: `Bearer ${this.sanity.$auth.api_token}`,
},
params: {
query: `*`,
},
})
},
})