Workspaces and files¶
39 endpoints. Every path below is served by trilocore-contractide-backend behind the gateway at https://api.trilocore.ai.
GET /api/v1/ide/workspaces¶
List Workspaces
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces¶
Create Workspace
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
name |
string | yes | — |
slug |
string | yes | — |
▶ Run this example in the sandbox
DELETE /api/v1/ide/workspaces/{uuid}¶
Delete Workspace
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
GET /api/v1/ide/workspaces/{uuid}¶
Get Workspace
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/analyses¶
List Analyses
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces/{uuid}/analyses¶
Start Analysis
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
analysis_type |
string | yes | — |
ref |
one of | no | — |
settings |
object | no | — |
tool_id |
one of | no | — |
tool_version |
one of | no | — |
POST /api/v1/ide/workspaces/{uuid}/annotations¶
Create Dev Note
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
body |
string | no | — |
category |
one of | no | — |
commit_oid |
string | yes | — |
end_line |
integer | yes | — |
kind |
string | no | — |
path |
string | yes | — |
severity |
one of | no | — |
start_line |
integer | yes | — |
GET /api/v1/ide/workspaces/{uuid}/audit-log¶
Get Workspace Audit Log
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/audits¶
List Engagements
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces/{uuid}/audits¶
Open Engagement
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
pinned_commit_oid |
string | yes | — |
title |
string | yes | — |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/bindings¶
Get Bindings
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
PUT /api/v1/ide/workspaces/{uuid}/bindings¶
Put Binding
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
default_branch |
string | no | — |
external_full_name |
string | yes | — |
external_repository_id |
string | yes | — |
integration_id |
string | yes | — |
sync_mode |
string | yes | — |
POST /api/v1/ide/workspaces/{uuid}/bindings/push¶
Push Binding
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
commit_oid |
one of | no | — |
force |
boolean | no | — |
provider |
string | yes | — |
target_ref |
one of | no | — |
GET /api/v1/ide/workspaces/{uuid}/branch-protection¶
List Branch Protection
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
PUT /api/v1/ide/workspaces/{uuid}/branch-protection¶
Put Branch Protection
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
linear_history |
boolean | no | — |
min_approvals |
integer | no | — |
no_deletion |
boolean | no | — |
no_force_push |
boolean | no | — |
ref_pattern |
string | yes | — |
require_code_owner_review |
boolean | no | — |
require_security_approval |
boolean | no | — |
required_status_checks |
array | no | — |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/branches¶
List Branches
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces/{uuid}/branches¶
Create Branch
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
from_oid |
one of | no | — |
name |
string | yes | — |
▶ Run this example in the sandbox
DELETE /api/v1/ide/workspaces/{uuid}/branches/{id}¶
Delete Branch
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
PATCH /api/v1/ide/workspaces/{uuid}/branches/{id}/protection¶
Set Branch Protection
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
protected |
boolean | yes | — |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/draft¶
Get Draft
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
▶ Run this example in the sandbox
PUT /api/v1/ide/workspaces/{uuid}/draft/files/{rest}¶
Autosave Draft
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
application/octet-stream: the raw content, sent as the bodytext/plain: the raw content, sent as the body
The file's autosaved content, as raw bytes (Content-Type is not checked). An absent body saves an empty file. Refused: more than CONTRACTIDE_MAX_FILE_BYTES (default 2 MiB) → 413, the file PUT's cap and refusal; nothing is saved. There is no NUL-byte check on drafts.
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/files¶
List Files
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
ref |
string | no | — | — |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/files/{rest}¶
Get File
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
ref |
string | no | — | — |
PUT /api/v1/ide/workspaces/{uuid}/files/{rest}¶
Update File
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
application/octet-stream: the raw content, sent as the bodytext/plain: the raw content, sent as the body
The file's complete new content, as raw bytes (Content-Type is not checked). An absent body writes an empty file. Refused: more than CONTRACTIDE_MAX_FILE_BYTES (default 2 MiB) → 413, checked on Content-Length before the body is read; a NUL byte in a known text source (.sol, .vy, .rs, …) → 400.
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/findings.sarif¶
Workspace Findings Sarif
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces/{uuid}/findings/ingest¶
Ingest Findings
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
analyzer |
string | no | — |
commit_oid |
string | yes | — |
engagement_id |
one of | no | — |
findings |
array of RawFinding | yes | — |
DELETE /api/v1/ide/workspaces/{uuid}/github¶
Disconnect Github
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
GET /api/v1/ide/workspaces/{uuid}/github¶
Github Status
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
PUT /api/v1/ide/workspaces/{uuid}/github¶
Connect Github
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
branch |
string | no | — |
repo |
string | yes | — |
token |
string | yes | — |
POST /api/v1/ide/workspaces/{uuid}/github/publish¶
Publish To Github
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
force |
boolean | no | — |
ref |
one of | no | — |
remote_branch |
one of | no | — |
GET /api/v1/ide/workspaces/{uuid}/languages¶
Workspace Languages
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/members¶
List Members
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces/{uuid}/members¶
Invite Member
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
engagement_id |
one of | no | — |
expires_at |
one of | no | — |
role |
string | yes | — |
user_id |
string | yes | — |
▶ Run this example in the sandbox
DELETE /api/v1/ide/workspaces/{uuid}/members/{id}¶
Remove Member
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/merge-requests¶
List Merge Requests
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces/{uuid}/merge-requests¶
Create Merge Request
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
description |
one of | no | — |
source_ref |
string | yes | — |
status |
string | no | — |
target_ref |
string | yes | — |
title |
string | yes | — |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces/{uuid}/scaffold¶
Scaffold Workspace
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
force |
boolean | no | — |
template |
string | yes | — |
▶ Run this example in the sandbox
GET /api/v1/ide/workspaces/{uuid}/tags¶
List Tags
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
| Pagination | paged: page_size ≤ 200 (default 50) + page_token; the body is {data, has_more, next_page_token, page_size} |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
page_size |
integer | no | default 50, clamped to 200, minimum 1 |
Items per page. Default 50; values above 200 are clamped to 200 (never an error). The effective value is echoed as page_size. |
page_token |
string | no | maxLength 2048 |
Opaque token from a previous page's next_page_token. Valid for 3 days, only with the same filters and the same caller. Omit it to start from the first page. |
▶ Run this example in the sandbox
POST /api/v1/ide/workspaces/{uuid}/tags¶
Create Tag
| Property | Value |
|---|---|
| Authentication | Authorization: Bearer (jns_ key or SSO session) |
| Idempotency-Key | not required |
| Success | 200 |
| Upstream | trilocore-contractide-backend |
Request body
| Field | Type | Required | Constraints |
|---|---|---|---|
name |
string | yes | — |
oid |
one of | no | — |
protected |
boolean | no | — |