Need some inspiration for your next blog post, email, or landing page? Try Writesonic, the smart and fast way to write better.
Go to siteimport { axios } from "@pipedream/platform"
export default defineComponent({
props: {
writesonic: {
type: "app",
app: "writesonic",
}
},
async run({steps, $}) {
const data = {
"topic": `{your_topic}`,
}
return await axios($, {
method: "post",
url: `https://api.writesonic.com/v2/business/content/blog-ideas`,
headers: {
"X-API-KEY": `${this.writesonic.$auth.api_key}`,
"Accept": `application/json`,
"Content-Type": `application/json`,
},
params: {
engine: `economy`,
language: `en`,
num_copies: `1`,
},
data,
})
},
})
Writesonic uses API keys for authentication. When you connect your Writesonic account, Pipedream securely stores the keys so you can easily authenticate to Writesonic APIs in both code and no-code steps.
To retrieve your API Key,