The Plain API provides functionality for automating customer support tasks, such as managing conversations, customers, and team inboxes. Within Pipedream, you can leverage these features to create custom workflows that respond to events from your app or external services, triggering actions in Plain. By integrating the Plain API with Pipedream, you can enhance customer support efficiency, streamline communication, and keep customer data synchronized across platforms.
import { axios } from "@pipedream/platform"
export default defineComponent({
props: {
plain: {
type: "app",
app: "plain",
}
},
async run({steps, $}) {
const data = {
"query": `query Workspace {
workspace(workspaceId: "${this.plain.$auth.workspace_id}") {
id
publicName
}
}`,
}
return await axios($, {
method: "post",
url: `https://core-api.uk.plain.com/graphql/v1`,
headers: {
Authorization: `Bearer ${this.plain.$auth.api_key}`,
"Content-Type": `application/json`,
},
data,
})
},
})
Support Ticket Routing: Automatically assign incoming support messages from different channels to the appropriate team inbox based on the content or customer data. This can help ensure that tickets are handled by the right team member quickly.
Customer Feedback Collection: After resolving support tickets, trigger a feedback request workflow. Connect Plain with a survey tool to send personalized surveys, and then store responses back in Plain to keep all customer interaction history in one place.
Real-time Customer Support Notifications: Create a workflow that listens to new messages or updates in Plain, and then sends real-time notifications to Slack or another chat app. This ensures that your support team is instantly informed about customer issues and can react promptly.
Creates or updates customer with customer details. See the documentation
Plain uses API keys for authentication. When you connect your Plain account, Pipedream securely stores the keys so you can easily authenticate to Plain APIs in both code and no-code steps.
To get an API key, follow the following instructions: https://www.plain.com/docs/api-reference/graphql/authentication