Skip to content

Tags

Tags let you categorize and filter ideas. Each tag has a name, an optional color, and a count of associated ideas.

GET /api/v1/tags

Returns all tags for the authenticated user, including the number of ideas associated with each tag.

Terminal window
curl https://neuralrepo.com/api/v1/tags \
-H "X-API-Key: nrp_YOUR_KEY"

Response 200 OK

[
{
"id": 1,
"name": "feature-request",
"color": "#4f46e5",
"idea_count": 12
},
{
"id": 2,
"name": "bug",
"color": "#dc2626",
"idea_count": 5
}
]

POST /api/v1/tags

FieldTypeRequiredDescription
namestringYes1-50 characters, must be unique
colorstringNoHex color in #rrggbb format
Terminal window
curl -X POST https://neuralrepo.com/api/v1/tags \
-H "X-API-Key: nrp_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"name": "backend", "color": "#059669"}'

Response 201 Created

{
"id": 3,
"name": "backend",
"color": "#059669",
"idea_count": 0
}

PATCH /api/v1/tags/:id

Update the name, color, or both. Only provided fields are changed.

FieldTypeRequiredDescription
namestringNo1-50 characters
colorstringNoHex color in #rrggbb format
Terminal window
curl -X PATCH https://neuralrepo.com/api/v1/tags/3 \
-H "X-API-Key: nrp_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"color": "#0ea5e9"}'

Response 200 OK

{
"id": 3,
"name": "backend",
"color": "#0ea5e9",
"idea_count": 0
}

DELETE /api/v1/tags/:id

Removes the tag. Ideas that had this tag will have it detached but are not otherwise affected.

Terminal window
curl -X DELETE https://neuralrepo.com/api/v1/tags/3 \
-H "X-API-Key: nrp_YOUR_KEY"

Response 204 No Content

FieldTypeDescription
idnumberUnique tag identifier
namestringDisplay name
colorstring | nullHex color code
idea_countnumberNumber of ideas using this tag
StatusMeaning
200 OKSuccessful read or update
201 CreatedTag created
204 No ContentTag deleted
400 Bad RequestValidation error (name too long, invalid color)
401 UnauthorizedMissing or invalid auth
404 Not FoundTag not found
409 ConflictTag with that name already exists