Links
Links let you attach external URLs to ideas — reference material, GitHub issues, design documents, or any relevant resource.
List Links
Section titled “List Links”GET /api/v1/ideas/:id/links
Returns all links attached to the specified idea.
curl https://neuralrepo.com/api/v1/ideas/42/links \ -H "X-API-Key: nrp_YOUR_KEY"const res = await fetch( "https://neuralrepo.com/api/v1/ideas/42/links", { headers: { "X-API-Key": "nrp_YOUR_KEY" } });const links = await res.json();Response 200 OK
[ { "id": 1, "url": "https://github.com/org/repo/issues/42", "title": "GitHub Issue #42", "link_type": "github-issue", "created_at": "2026-03-20T10:00:00Z" }]Add Link
Section titled “Add Link”POST /api/v1/ideas/:id/links
Request Body
Section titled “Request Body”| Field | Type | Required | Description |
|---|---|---|---|
url | string | Yes | Valid URL, max 2,000 characters |
title | string | No | Display title, max 200 characters |
link_type | string | No | Type of link (default: url) |
curl -X POST https://neuralrepo.com/api/v1/ideas/42/links \ -H "X-API-Key: nrp_YOUR_KEY" \ -H "Content-Type: application/json" \ -d '{ "url": "https://github.com/org/repo", "title": "Project repository", "link_type": "github-repo" }'const res = await fetch( "https://neuralrepo.com/api/v1/ideas/42/links", { method: "POST", headers: { "X-API-Key": "nrp_YOUR_KEY", "Content-Type": "application/json", }, body: JSON.stringify({ url: "https://github.com/org/repo", title: "Project repository", link_type: "github-repo", }), });const link = await res.json();Response 201 Created
{ "id": 2, "url": "https://github.com/org/repo", "title": "Project repository", "link_type": "github-repo", "created_at": "2026-03-24T09:00:00Z"}Delete Link
Section titled “Delete Link”DELETE /api/v1/ideas/:id/links/:linkId
Removes a link from an idea.
curl -X DELETE https://neuralrepo.com/api/v1/ideas/42/links/2 \ -H "X-API-Key: nrp_YOUR_KEY"Response 204 No Content
Link Types
Section titled “Link Types”The link_type field uses one of these enumerated values:
| Type | Description |
|---|---|
url | General web link (default) |
claude-chat | Claude conversation link |
github-repo | GitHub repository |
github-issue | GitHub issue or PR |
attachment | File attachment uploaded via web |
Link Schema
Section titled “Link Schema”| Field | Type | Description |
|---|---|---|
id | number | Unique link identifier |
url | string | The linked URL |
title | string | null | Display title |
link_type | string | Categorization of the link |
created_at | string | ISO 8601 timestamp |
Status Codes
Section titled “Status Codes”| Status | Meaning |
|---|---|
200 OK | Links listed |
201 Created | Link added |
204 No Content | Link deleted |
400 Bad Request | Invalid URL or title too long |
401 Unauthorized | Missing or invalid auth |
404 Not Found | Idea or link not found |