with Rapid7 Insight Platform and AI Textraction?
Extract custom data from text using AI Textraction. See the documentation
The Rapid7 Insight Platform API allows users to automate and integrate their security data with other applications. By harnessing this API on Pipedream, you can create custom workflows to streamline security operations, such as automating threat detection, managing vulnerabilities, or orchestrating incident response. This means you can connect the Insight Platform's capabilities with numerous other apps to trigger actions, process data, and get real-time insights, all within Pipedream's low-code environment.
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
rapid7_insight_platform: {
type: "app",
app: "rapid7_insight_platform",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://us.api.insight.rapid7.com/validate`,
headers: {
"X-Api-Key": `${this.rapid7_insight_platform.$auth.api_key}`,
},
})
},
})
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
ai_textraction: {
type: "app",
app: "ai_textraction",
}
},
async run({steps, $}) {
const data = {"text":"John Doe is a software engineer with 5 years of experience. He specializes in web development and has expertise in multiple programming languages such as JavaScript, Python, and HTML. John has worked on various projects, including e-commerce websites and mobile applications. In his free time, John enjoys playing the guitar, hiking, and reading books.","entities":[{"var_name":"first_name","type":"string","description":"first name of the person"},{"var_name":"last_name","type":"string","description":"last name of the person"},{"var_name":"years_of_experience","type":"integer","description":"years of experience"},{"var_name":"programming_languages","type":"array[string]","description":"programming languages experienced with"},{"var_name":"hobbies","type":"array[string]","description":"hobbies"}]}
return await axios($, {
method: "post",
url: `https://ai-textraction.p.rapidapi.com/textraction`,
headers: {
"x-rapidapi-host": `ai-textraction.p.rapidapi.com`,
"x-rapidapi-key": `${this.ai_textraction.$auth.rapid_key}`,
},
data,
})
},
})