feedback.io exposes an endpoint for submitting feedback. You will need to provide:
Include these in your request headers as x-client-id and x-project-id respectively. For security, do not hardcode these IDs in your code. Use environment variables to store them securely.
To submit feedback, send a POST request to the following endpoint with mentioned request headers.
POST https://feedmo.vercel.app/api/v1/feedback
Header | Type | Description |
---|---|---|
x-client-id | string | Required. Your Account ID |
x-project-id | string | Required. Your Project ID |
Your request body should be a JSON object with the following structure:
{
"email": "example@gmail.com",
"type": "bug",
"feedback": "Some message"
}
Parameter | Type | Description |
---|---|---|
string |
Required. Email address of the feedback sender | |
type | string |
Required. Type of feedback: bug or feature or suggestion |
feedback | string |
Required. Content of the feedback message |
If your POST request is successful, you will receive a 200 status code along with the following JSON response:
{
"success": true,
"message": "Feedback sent successfully."
}
If the POST request fails, you will receive an appropriate status code depending on the error type, along with a JSON response. Common error status codes:
{
"success": false,
"message": "Some error message"
}
1import axios from 'axios';
2
3axios.post(https://feedmo.vercel.app/api/v1/feedback, {
4 email: 'abc@gmail.com',
5 type: "bug",
6 feedback: "There is a bug in the login page."
7}, {
8 headers: {
9 'Content-Type': 'application/json',
10 'account': 'Your-Client-ID',
11 'project': 'Your-Project-ID'
12 },
13})