Skip to main content

Save Version

POST /schematic/version
curl -X POST "https://api.buildwithtrace.com/api/v2/schematic/version" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "project_path": "/path/to/project",
    "content": "<schematic file content>",
    "description": "Added power supply section",
    "conversation_id": "session-uuid"
  }'

List Versions

GET /schematic/versions
curl -X GET "https://api.buildwithtrace.com/api/v2/schematic/versions?project_path=/path/to/project" \
  -H "Authorization: Bearer YOUR_TOKEN"
Returns version list without file content (for performance).

Get Version

GET /schematic/version/{id}
curl -X GET "https://api.buildwithtrace.com/api/v2/schematic/version/VERSION_ID" \
  -H "Authorization: Bearer YOUR_TOKEN"
Returns the full version including file content.

Restore Version

POST /schematic/restore
curl -X POST "https://api.buildwithtrace.com/api/v2/schematic/restore" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "version_id": "VERSION_ID",
    "project_path": "/path/to/project"
  }'