Endpoints

Sources And Ingest

Register owned media or a private YouTube range as a local source before any study can start.

GET/v1/source-sessionsList registered local sources with rights scope, duration, and preflight identity.

studio.local-source-session-list.v1

Source Summary

response object
sourceSessionIdstring

Session identity used to start runtimes.

sourceRevisionIdstring

Exact revision; requests naming a stale revision are rejected.

sourceContentIdstring

Content address of the sealed bytes.

sourceKind"owned_local" | "youtube_local"

Which registered producer sealed it.

rightsScopestring

Rights scope carried from the ingest receipt.

durationMsnumber

Probed duration in milliseconds.

trackCountnumber

Probed track count.

preflightSchemastring

Which preflight bundle version backs this source.

detectedLanguageEvidenceAvailableboolean

Whether pinned language-range evidence exists.

200Response
{
    "schema": "studio.local-source-session-list.v1",
    "sourceSessions": [
        {
            "sourceSessionId": "source-session:50e48113837e62499233f29f53ab91f5ed591d39bda98879effb02364e2a03a2",
            "sourceRevisionId": "source-revision:6800f536f61f5d73dc474443cf0469c823ae94a984a209192940fc28b94afa09",
            "sourceContentId": "sha256:e141cd9d0a693f70d7e069deb4bf2b300af64a1a89b0b8e806e7aae6be1c924e",
            "sourceKind": "owned_local",
            "label": "Project-generated Korean conversation fixture",
            "rightsScope": "redistribution",
            "durationMs": 47200,
            "trackCount": 1,
            "preflightSchema": "studio.preflight-bundle.v3",
            "detectedLanguageEvidenceAvailable": true
        },
        {
            "sourceSessionId": "source-session:993e4ef19cfbba39652cd1ea9486524cfa0febf310f0f1136465028c127ca189",
            "sourceRevisionId": "source-revision:1106abf319a7e241fea77847afeedd51b8b9b2a735ea435cddf3f01387b80605",
            "sourceContentId": "sha256:734d28184ea69374d58b7785c7ecdf226c25405b295534f9db08cd2a56357c29",
            "sourceKind": "owned_local",
            "label": "Browser-owned WAV",
            "rightsScope": "local_processing",
            "durationMs": 1000,
            "trackCount": 1,
            "preflightSchema": "studio.preflight-bundle.v1",
            "detectedLanguageEvidenceAvailable": false
        },
        {
            "sourceSessionId": "source-session:bf08edbaef1621c697c7c7f1a7e77cc0bd1cbee74bcd759f62f7cabefd21832c",
            "sourceRevisionId": "source-revision:eb3379fa9d2730cd3ef6d1db8a9c2beed8f3003bad6446021389b05f0d9baa09",
            "sourceContentId": "sha256:3210f53e4d064c188df8d7ccef6b288a2248b6afa158633f9891bf7c7d510603",
            "sourceKind": "owned_local",
            "label": "Browser-owned WAV",
            "rightsScope": "local_processing",
            "durationMs": 1000,
            "trackCount": 1,
            "preflightSchema": "studio.preflight-bundle.v1",
            "detectedLanguageEvidenceAvailable": false
        }
    ]
}
POST/v1/owned-media-ingestsOpen a rights-attested owned-media ingest from declared metadata.

studio.owned-media-ingest.v1

Request Body

application/json
filenamestringrequired

Original basename, retained as provenance only.

declaredBytesnumberrequired

Byte count declared for the coming upload.

labelstringrequired

Operator-facing label for the source.

rightsHolderstringrequired

Named rights holder for the bytes.

rightsScope"local_processing"required

The only scope that exists. Nothing here authorizes redistribution.

ownershipAttestedtruerequired

Literal true. The request is rejected without the attestation.

Request
curl -X POST http://127.0.0.1:4312/v1/owned-media-ingests \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "filename": "clip.m4a",
  "declaredBytes": 329662,
  "label": "Project-generated Korean conversation fixture",
  "rightsHolder": "1321 project",
  "rightsScope": "local_processing",
  "ownershipAttested": true
}'
202Response
{
    "schema": "studio.owned-media-ingest.v1",
    "ingestId": "owned-ingest:2e21dfc3-8a93-4528-b2de-d01652a03d48",
    "status": "queued",
    "updatedAt": "2026-07-19T17:14:11.933Z",
    "source": null,
    "failure": null
}
PUT/v1/owned-media-ingests/:ingestId/mediaUpload the raw bytes for one open ingest as an octet stream.

studio.owned-media-ingest.v1

Ingest Status

response
ingestIdstring

Identity for polling this ingest.

status"queued" | "probing" | "sealing" | "registered" | "failed"

YouTube ingests add "resolving" and "downloading" before probing.

updatedAtstring

ISO timestamp of the last state change.

sourceobject | null

Registered source summary once sealed, else null.

failure{ code, message } | null

Closed failure-code set; null unless failed.

Upload request
curl -X PUT http://127.0.0.1:4312/v1/owned-media-ingests/$INGEST_ID/media \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/octet-stream" \
  --data-binary @public/demo/runs/run-005/clip.m4a
202Response
{
    "schema": "studio.owned-media-ingest.v1",
    "ingestId": "owned-ingest:2e21dfc3-8a93-4528-b2de-d01652a03d48",
    "status": "queued",
    "updatedAt": "2026-07-19T17:14:12.063Z",
    "source": null,
    "failure": null
}
GET/v1/owned-media-ingests/:ingestIdPoll ingest state until registered or failed.

studio.owned-media-ingest.v1

Ingest Status

response
ingestIdstring

Identity for polling this ingest.

status"queued" | "probing" | "sealing" | "registered" | "failed"

YouTube ingests add "resolving" and "downloading" before probing.

updatedAtstring

ISO timestamp of the last state change.

sourceobject | null

Registered source summary once sealed, else null.

failure{ code, message } | null

Closed failure-code set; null unless failed.

Request
curl http://127.0.0.1:4312/v1/owned-media-ingests/$INGEST_ID \
  -H "Authorization: Bearer $TOKEN"
200Response
{
    "schema": "studio.owned-media-ingest.v1",
    "ingestId": "owned-ingest:2e21dfc3-8a93-4528-b2de-d01652a03d48",
    "status": "registered",
    "updatedAt": "2026-07-19T17:14:12.330Z",
    "source": {
        "sourceSessionId": "source-session:50e48113837e62499233f29f53ab91f5ed591d39bda98879effb02364e2a03a2",
        "sourceRevisionId": "source-revision:f6b47a3ecc4da9e2463b2d7afcdf517dcaec4e5bf13953af0849d74a27110f4b",
        "sourceContentId": "sha256:e141cd9d0a693f70d7e069deb4bf2b300af64a1a89b0b8e806e7aae6be1c924e",
        "sourceKind": "owned_local",
        "label": "Project-generated Korean conversation fixture",
        "rightsScope": "local_processing",
        "durationMs": 47200,
        "trackCount": 1,
        "preflightSchema": "studio.preflight-bundle.v1",
        "detectedLanguageEvidenceAvailable": false
    },
    "failure": null
}
POST/v1/youtube-local-ingestsOpen a private local YouTube range ingest.

studio.youtube-local-ingest.v1

Request Body

application/json
urlstringrequired

Watch URL of the video.

startMsnumberrequired

Range start in integer milliseconds.

endMsnumberrequired

Range end; the range cap is enforced by the host.

localProcessingConfirmedtruerequired

Literal true. Confirms private local processing only.

Request
curl -X POST http://127.0.0.1:4312/v1/youtube-local-ingests \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "url": "https://www.youtube.com/watch?v=Ux-TMWnmntM",
  "startMs": 754000,
  "endMs": 784000,
  "localProcessingConfirmed": true
}'
202Response
{
    "schema": "studio.youtube-local-ingest.v1",
    "ingestId": "youtube-ingest:6d6c5f19-d1ea-4908-8b19-fe3e319dd192",
    "status": "queued",
    "updatedAt": "2026-07-19T17:21:06.351Z",
    "source": null,
    "failure": null
}
GET/v1/youtube-local-ingests/:ingestIdPoll YouTube-local ingest state.

studio.youtube-local-ingest.v1

Ingest Status

response
ingestIdstring

Identity for polling this ingest.

status"queued" | "probing" | "sealing" | "registered" | "failed"

YouTube ingests add "resolving" and "downloading" before probing.

updatedAtstring

ISO timestamp of the last state change.

sourceobject | null

Registered source summary once sealed, else null.

failure{ code, message } | null

Closed failure-code set; null unless failed.

Request
curl http://127.0.0.1:4312/v1/youtube-local-ingests/$INGEST_ID \
  -H "Authorization: Bearer $TOKEN"
200Response
{
    "schema": "studio.youtube-local-ingest.v1",
    "ingestId": "youtube-ingest:6d6c5f19-d1ea-4908-8b19-fe3e319dd192",
    "status": "registered",
    "updatedAt": "2026-07-19T17:21:30.763Z",
    "source": {
        "sourceSessionId": "source-session:d3dc44dbe87db3457a0c43ccb213371d1e4775340b437201ac8e2d92bd822d36",
        "sourceRevisionId": "source-revision:153f159f77f54093d8707f6d94d220b95a494a6e3428d7c4126c12111794a301",
        "sourceContentId": "sha256:4a6f299950234797d790981eb1901acab91e215636df92dba0a2f702055cec2a",
        "sourceKind": "youtube_local",
        "label": "Natural Korean Conversation with 태웅쌤 | 이렇게 귀하신 분이 ①",
        "rightsScope": "local_processing",
        "durationMs": 30030,
        "trackCount": 2,
        "preflightSchema": "studio.preflight-bundle.v1",
        "detectedLanguageEvidenceAvailable": false
    },
    "failure": null
}