Replace the project annotation schema, requireReview, and overlap flag
PUT
/v1/projects/{projectId}/annotation-schemacurl -X PUT 'https://api.embodiflow.io/v1/projects/{projectId}/annotation-schema' \
-H 'Authorization: Bearer $EMBODIFLOW_PAT' \
-H 'Content-Type: application/json' \
-d '{
"version": 1,
"languages": "en",
"fields": {
"task": {
"enabled": true
},
"outcome": {
"enabled": true
},
"subtasks": {
"enabled": true
},
"subtaskOutcome": {
"enabled": true
},
"relevance": {
"enabled": true
},
"keyframeBoxes": {
"enabled": false
}
},
"subtaskLabels": [
{
"en": "string",
"zh": "string"
}
],
"attributes": [
{
"key": "string",
"type": "text",
"options": [
"string"
]
}
],
"requireReview": true,
"allowEpisodeOverlap": true
}'认证
每个请求都需要携带个人访问令牌(PAT)。
- Authorization: Bearer PAT
路径参数
- projectIdstring必填
请求头参数
- If-Matchstring必填
Required precondition. Absent returns 428 PRECONDITION_REQUIRED. A stale tag returns 412 PRECONDITION_FAILED with no write. If-Match: * succeeds when the resource exists. Malformed values return 400 IF_MATCH_INVALID.
请求体
Content-Typeapplication/json
- versionnumber必填可选值1
- languagesarray<string>必填
- fieldsobject必填
- taskobject必填
- outcomeobject必填
- subtasksobject必填
- subtaskOutcomeobject必填
- relevanceobject必填
- keyframeBoxesobject必填
- subtaskLabelsarray<LocalizedTextDto>必填
- enstring
- zhstring
- attributesarray<AnnotationAttributeDto>必填
- keystring必填
- typestring必填可选值textsingle_choicenumber
- optionsarray<string>
- requireReviewboolean必填
- allowEpisodeOverlapboolean必填
响应
Success
- dataobject必填
- versionnumber必填可选值1
- languagesarray<string>必填
- fieldsobject必填
- subtaskLabelsarray<object>必填
- attributesarray<object>必填
- requireReviewone of必填
- allowEpisodeOverlapone of必填
- taskListarray<object>必填
响应示例
{
"data": {
"version": 1,
"languages": "en",
"fields": {
"task": {
"enabled": false
},
"outcome": {
"enabled": false
},
"subtasks": {
"enabled": false
},
"subtaskOutcome": {
"enabled": false
},
"relevance": {
"enabled": false
},
"keyframeBoxes": {
"enabled": false
}
},
"subtaskLabels": [
{
"en": "string",
"zh": "string"
}
],
"attributes": [
{
"key": "string",
"type": "number",
"options": [
"string"
]
}
],
"requireReview": false,
"allowEpisodeOverlap": false,
"taskList": [
{
"en": "string",
"zh": "string"
}
]
}
}服务器https://api.embodiflow.io/v1https://api.embodiflow.dev/v1