OVE Asset Manager REST APIΒΆ
This API is designed to allow you to perform the majority of necessary file operations using a REST API
- /api/list:
GET
: Lists available file stores- Response:
- Success:
HTTP Code: 200
Content:['store1', 'store2', '...']
- Success:
- /api/{store_id}/list
GET
: Lists available projects in a file store- Query params:
metadata=true | false
- optional, if true the project list include some metadata - Response:
- Success:
HTTP Code: 200
Content:[{name: "project1", "creationDate": "date"}, "..."]
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Success:
/api/{store_id}/create
POST
: Create project- Data Params:
Requires JSON body
{ "name":"project_name" }
- Response:
- Success:
HTTP Code: 200
Content:{'Project': project_name}
- Error: Store not found
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Error: Project already exists
HTTP Code: 409 Conflict
Content:{title="Project already in use", description="..."}
- Success:
- Notes: With S3 storage, the project name must conform to s3 bucket name conventions
- /api/{store_id}/{project_name}/list
GET
: Lists available assets in a file store with meta data- Query params:
includeEmpty=(True|False)
- optional, if true all folders are included regardless of whether they are ove assets`filterByTag=<tag_name>
- optional, filter all assets tagged by tag_name
- Response:
- Success:
HTTP Code: 200
Content:{ "Assets" : ["Asset1"] }
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Success:
/api/{store_id}/{project_name}/create
POST
: Create asset- Data Params:
Requires JSON body
{ "name":"asset_name" }
- Response:
- Success:
HTTP Code: 200
Content:{'Asset': asset_name}
- Error: Store not found
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Error: Asset already exists
HTTP Code: 409 Conflict
Content:{title="Asset already in use", description="..."}
- Success:
- Notes: _With S3 storage, asset name is not allowed to contain / or any restricted asset names (e.g. new, .ovemeta, list, create)
- /api/{store_id}/{project_name}/object/{object_id}
HEAD
: Check if an object exists- Response:
- Success: HTTP Code 200
- Not found: HTTP Code 404
GET
: Get an object in JSON format- Response:
- Success:
HTTP Code: 200
Content:{ ... }
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Object not found:
HTTP Code: 400 Bad Request
Content:{title="Object not found", description="..."}
- Success:
POST
: Create an object in JSON format- Data Params:
{ ... }
- Response:
- Success:
HTTP Code: 200
Content:{ ... }
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Object not found:
HTTP Code: 400 Bad Request
Content:{title="Object not found", description="..."}
- Object already in use:
HTTP Code: 400 Bad Request
Content:{title="Object already in use", description="..."}
- Success:
PUT
: Update an object in JSON format- Data Params:
{ ... }
- Response:
- Success:
HTTP Code: 200
Content:{ ... }
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Object not found:
HTTP Code: 400 Bad Request
Content:{title="Object not found", description="..."}
- Success:
- /api/{store_id}/{project_name}/object/{object_id}/info
GET
: Get the object metadata- Response:
- Success:
HTTP Code: 200
Content:{ name="...", index_file="..."}
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Object not found:
HTTP Code: 400 Bad Request
Content:{title="Object not found", description="..."}
- Success:
- /api/{store_id}/{project_name}/meta/{asset_id}
HEAD
: Check if an asset exists- Response:
- Success: HTTP Code 200
- Not found: HTTP Code 404
GET
: Get an asset metadata- Response:
- Success:
HTTP Code: 200
Content:{ "name": "...", "project": "...", "description": "...", "index_file": "...", "version": "...", "history": "...", "tags": "...", "worker": "...", "processing_status": "...", "processing_error": "..." }
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Asset not found:
HTTP Code: 400 Bad Request
Content:{title="Asset not found", description="..."}
- Success:
POST
: Update a project metadata- Data Params:
{"description": "...", "tags": "..."}
- Response:
- Success:
HTTP Code: 200
Content:{"Status": "OK"}
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Asset not found:
HTTP Code: 400 Bad Request
Content:{title="Asset not found", description="..."}
- Success:
- /api/{store_id}/{project_id}/files/{asset_id}
GET
: list of files under the current version of the asset- Response:
- Success:
HTTP Code: 200
Content:[{name: "...", url: "..."}]
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Asset not found:
HTTP Code: 400 Bad Request
Content:{title="Asset not found", description="..."}
- Success:
- /api/{store_id}/{project_name}/upload/{asset_id}
POST
: Upload an asset- Headers:
content-disposition: filename="<file_name>"
- Body:
the file octet stream
- Response:
- Success:
HTTP Code: 200
Content:{"Status": "OK"}
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Asset not found:
HTTP Code: 400 Bad Request
Content:{title="Asset not found", description="..."}
- Asset exists:
HTTP Code: 409 Conflict
Content:{title="Asset exists", description="..."}
- Success:
- /api/{store_id}/{project_name}/update/{asset_id}
POST
: Update an asset file- Headers:
content-disposition: filename="<file_name>"
- Body:
the file octet stream
- Response:
- Success:
HTTP Code: 200
Content:{"Status": "OK"}
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Asset not found:
HTTP Code: 400 Bad Request
Content:{title="Asset not found", description="..."}
- Success:
- /api/{store_id}/{project_name}/createUpload/{asset_id}
POST
: Create an asset and upload the file content- Headers:
content-disposition: filename="<file_name>"
- Body:
the file octet stream
- Response:
- Success:
HTTP Code: 200
Content:{"Status": "OK"}
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Success:
- /api/{store_id}/{project_name}/process/{asset_id}
POST
: Schedule a worker processing task on the selected asset- Data Params:
{"worker_type": "...",}
- Response:
- Success:
HTTP Code: 200
Content:{"Status": "OK"}
- Store not found:
HTTP Code: 400 Bad Request
Content:{title="Store not found", description="..."}
- Project not found:
HTTP Code: 400 Bad Request
Content:{title="Project not found", description="..."}
- Asset not found:
HTTP Code: 400 Bad Request
Content:{title="Asset not found", description="..."}
- Worker not found:
HTTP Code: 400 Bad Request
Content:{title="Worker not found", description="..."}
- Success:
- /api/workers
GET
: Worker list- Response:
- Success:
HTTP Code: 200
Content:['worker1', ...]
- Success:
POST
: Register worker- Data Params:
{ "name": "...", "type": "...", "description": "...", "extensions": "...", "status": "...", "callback": "...", "status_callback": "...", "parameters": "...", "docs": "..." }
- Response:
- Success:
HTTP Code: 200
Content:{ "name": "...", "type": "...", "description": "...", "extensions": "...", "status": "...", "callback": "...", "status_callback": "...", "parameters": "...", "docs": "..." }
- Worker already exists:
HTTP Code: 400 Bad Request
Content:{title="Worker already exists", description="..."}
- Success:
PATCH
: Update the status of a worker- Data Params:
{ name: "...", status: "..." }
- Response:
- Success:
HTTP Code: 200
Content:{ 'Status': 'OK' }
- Worker not found:
HTTP Code: 400 Bad Request
Content:{title="Worker not found", description="..."}
- Success:
DELETE
: Unregister a worker- Data Params:
{ name: "..." }
- Response:
- Success:
HTTP Code: 200
Content:{ 'Status': 'OK' }
- Worker not found:
HTTP Code: 400 Bad Request
Content:{title="Worker not found", description="..."}
- Success: