Comments
The comment object represents comments made on ideas.
The comment object
{
"id": "b0373e42-2ac9-4c5b-9dae-0e0be53f4320",
"createdAt": "2025-03-07T13:22:12.557Z",
"updatedAt": "2025-03-07T13:22:12.557Z",
"text": "Hello World",
"phase": {
"name": "Grow",
"kind": "GROW"
},
"sender": {
"email": "test@test.com",
"firstName": "Test"
}
}Fields
Field | Type | Description |
|---|---|---|
id |
| The unique identifier of the comment. |
createdAt |
| The date when the comment was created. |
updatedAt |
| The date when the comment was last updated. |
text |
| The content of the comment |
phase | The phase the comment was created in | |
sender | The user who created this comment |
List comments for an idea
curl -X GET "https://api.ideanote.io/v1/ideas/c469e730-043d-4bda-a3a0-5e029f56c027/comments?fields=id,text,sender.firstName" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <API Token>"const result = await fetch("https://api.ideanote.io/v1/ideas/c469e730-043d-4bda-a3a0-5e029f56c027/comments?fields=id,text,sender.firstName", {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer <API Token>",
}
});
const comment = await result.json();The above command returns JSON structured like this:
[
{
"sender": {}
},
{
"sender": {}
},
{
"sender": {}
}
]This endpoint lists all comments on an idea.
HTTP Request
GET /v1/ideas/:idea_id/comments
Query Parameters
Parameter | Description |
|---|---|
idea_id | The ID of the idea to list comments |
Get comment
curl -X GET "https://api.ideanote.io/v1/comments/b0373e42-2ac9-4c5b-9dae-0e0be53f4320?fields=id,text,sender.firstName" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <API Token>"const result = await fetch("https://api.ideanote.io/v1/comments/b0373e42-2ac9-4c5b-9dae-0e0be53f4320?fields=id,text,sender.firstName", {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer <API Token>",
}
});
const comment = await result.json();The above command returns JSON structured like this:
{
"sender": {}
}This endpoint retrieves a specific comment.
HTTP Request
GET /v1/comments/:comment_id
Query Parameters
Parameter | Description |
|---|---|
comment_id | The ID of the comment to retrieve |
Update comment
curl -X PUT "https://api.ideanote.io/v1/comments/b0373e42-2ac9-4c5b-9dae-0e0be53f4320?fields=id,text,sender.firstName" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <API Token>" \
-d '{"text":"This is an edited comment"}'const result = await fetch("https://api.ideanote.io/v1/comments/b0373e42-2ac9-4c5b-9dae-0e0be53f4320?fields=id,text,sender.firstName", {
method: "PUT",
body: {
"text": "This is an edited comment"
},
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer <API Token>",
}
});
const comment = await result.json();The above command returns JSON structured like this:
{
"sender": {}
}This endpoint updates a specific comment.
HTTP Request
PUT /v1/comments/:comment_id
Query Parameters
Parameter | Description |
|---|---|
comment_id | The ID of the comment to update |
Delete comment
curl -X DELETE "https://api.ideanote.io/v1/comments/b0373e42-2ac9-4c5b-9dae-0e0be53f4320" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <API Token>"const result = await fetch("https://api.ideanote.io/v1/comments/b0373e42-2ac9-4c5b-9dae-0e0be53f4320", {
method: "DELETE",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer <API Token>",
}
});
This endpoint deletes a specific comment.
HTTP Request
DELETE /v1/comments/:comment_id
Query Parameters
Parameter | Description |
|---|---|
comment_id | The ID of the comment to delete |