Cycle API
Ask or search…
K
Links

Create a feedback

With the createFeedback mutation you can easily create a feedback in your Cycle workspace from wherever you want (e.g: mobile app, web app, ...)

1. Create a personal access token

Create a personal access token by triggering the createAccessToken mutation and use the received token in your authorization bearer (don't forget put your login bearer token before triggering the mutation. See Queries and mutations).
mutation createToken {
createAccessToken(label: "In App Integration") {
id
token
label
}
}

2. Use the createFeedback mutation

The createFeedback mutation requires a productId parameter. To get one, you can use the me query and use the first productId from your products list if you have multiple. If you don't have any, try to create a workspace first with our get-started path.
query me {
me {
id
products {
edges {
node {
id
name
}
}
}
}
}
Once we have our productId, we can trigger the createFeedback mutation
mutation createFeedback {
createFeedback(
productId: "<productId>"
title: "my first feedback from the api"
customer: "[email protected]"
source: "https://mysupersite.com"
) {
id
title
status {
id
value
}
customer {
id
email
}
}
}

3. Integrate the mutation in your app

Work in progress...