with Parsera and Shutterstock?
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
parsera: {
type: "app",
app: "parsera",
}
},
async run({steps, $}) {
const data = {
"url": "https://news.ycombinator.com/",
"attributes": [
{
"name": "Title",
"description": "News title"
},
{
"name": "Points",
"description": "Number of points"
}
]
}
return await axios($, {
method: "POST",
url: `https://api.parsera.org/v1/extract`,
headers: {
"X-API-KEY": `${this.parsera.$auth.api_key}`,
"Accept": `application/json`,
},
data,
})
},
})
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
shutterstock: {
type: "app",
app: "shutterstock",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://api.shutterstock.com/v2/user`,
headers: {
Authorization: `Bearer ${this.shutterstock.$auth.oauth_access_token}`,
},
})
},
})