with RunPod and Notion (API Key)?
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
runpod: {
type: "app",
app: "runpod",
}
},
async run({steps, $}) {
const data = {
"query": `query GpuTypes { gpuTypes { id displayName memoryInGb } }`,
}
return await axios($, {
method: "post",
url: `https://api.runpod.io/graphql`,
headers: {
"Content-Type": `application/json`,
},
params: {
api_key: `${this.runpod.$auth.api_key}`,
},
data,
})
},
})
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
notion_api_key: {
type: "app",
app: "notion_api_key",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://api.notion.com/v1/users/me`,
headers: {
Authorization: `Bearer ${this.notion_api_key.$auth.api_secret}`,
"Notion-Version": `2021-08-16`,
},
})
},
})