with Strapi and Prisma Postgres?
Creates a new Postgres database project via Prisma Management API. See docs here
Creates a new connection string for an existing database via Prisma Management API. See docs here
Create a new database in an existing Prisma project. Requires Project ID. See docs here
Deletes a Postgres database project via Prisma Management API. See docs here
Delete a specific database by Database ID via Prisma Management API. This action is irreversible. See docs here
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
strapi: {
type: "app",
app: "strapi",
}
},
async run({steps, $}) {
return await axios($, {
url: `${this.strapi.$auth.api_url}/api/users`,
headers: {
Authorization: `Bearer ${this.strapi.$auth.api_token}`,
},
})
},
})
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
prisma_management_api: {
type: "app",
app: "prisma_management_api",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://api.prisma.io/v1/workspaces`,
headers: {
Authorization: `Bearer ${this.prisma_management_api.$auth.api_token}`,
"accept": `application/json`,
},
params: {
limit: `100`,
},
})
},
})