{"openapi":"3.0.2","info":{"title":"Dataops Service","description":"Dataops","version":"2.5.8"},"paths":{"/v1/health/":{"get":{"tags":["Health"],"summary":"Healthcheck if all service dependencies are online.","description":"Return response that represents status of the database and redis connections.","operationId":"get_health_status_v1_health__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/v1/tasks/":{"get":{"tags":["Task Dispatch"],"summary":"Asynchronized Task Management API, Get task information","description":"Retrieve job info for a given session.","operationId":"get_v1_tasks__get","parameters":[{"required":true,"schema":{"title":"Session Id"},"name":"session_id","in":"query"},{"required":false,"schema":{"title":"Label","default":"Container"},"name":"label","in":"query"},{"required":false,"schema":{"title":"Job Id","default":"*"},"name":"job_id","in":"query"},{"required":false,"schema":{"title":"Code","default":"*"},"name":"code","in":"query"},{"required":false,"schema":{"title":"Action","default":"*"},"name":"action","in":"query"},{"required":false,"schema":{"title":"Operator","default":"*"},"name":"operator","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskRetrieveResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Task Dispatch"],"summary":"Asynchronized Task Management API, Update tasks","description":"Update job info for a given session.","operationId":"put_v1_tasks__put","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskUpdateSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskUpdateResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Task Dispatch"],"summary":"Asynchronized Task Management API, Create a new task","description":"Create new job if job_id does not exist for a given session.","operationId":"post_v1_tasks__post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Task Dispatch"],"summary":"Asynchronized Task Management API, Delete tasks","description":"Delete job for a given session.","operationId":"delete_v1_tasks__delete","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskDeleteSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/task-stream/":{"get":{"tags":["Task Streaming"],"summary":"Stream file status events over SSE","description":"Stream file status events over SSE.","operationId":"get_status_with_sse_v1_task_stream__get","parameters":[{"required":true,"schema":{"title":"Session Id","type":"string"},"name":"session_id","in":"query"},{"required":false,"schema":{"title":"Container Code","type":"string"},"name":"container_code","in":"query"},{"required":false,"schema":{"title":"Container Type","type":"string"},"name":"container_type","in":"query"},{"required":false,"schema":{"title":"Action Type","type":"string"},"name":"action_type","in":"query"},{"required":false,"schema":{"title":"Target Names","type":"string"},"name":"target_names","in":"query"},{"required":false,"schema":{"title":"Job Id","type":"string","format":"uuid"},"name":"job_id","in":"query"},{"required":false,"schema":{"title":"Request Timeout","type":"integer"},"name":"request_timeout","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Task Streaming"],"summary":"Write a new file status event to Redis","description":"Write a new file status event to Redis.","operationId":"write_status_v1_task_stream__post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskStreamCreateSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskStreamResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Task Streaming"],"summary":"Delete a user's old file status events from Redis","description":"Delete a user's old file status events from Redis.","operationId":"delete_status_v1_task_stream__delete","parameters":[{"required":true,"schema":{"title":"User","type":"string"},"name":"user","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskStreamResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/task-stream/static/":{"get":{"tags":["Task Streaming"],"summary":"Get file status events without SSE streaming","description":"Get file status events without SSE streaming.","operationId":"get_static_status_v1_task_stream_static__get","parameters":[{"required":true,"schema":{"title":"Session Id","type":"string"},"name":"session_id","in":"query"},{"required":false,"schema":{"title":"Container Code","type":"string"},"name":"container_code","in":"query"},{"required":false,"schema":{"title":"Container Type","type":"string"},"name":"container_type","in":"query"},{"required":false,"schema":{"title":"Action Type","type":"string"},"name":"action_type","in":"query"},{"required":false,"schema":{"title":"Target Names","type":"string"},"name":"target_names","in":"query"},{"required":false,"schema":{"title":"Job Id","type":"string","format":"uuid"},"name":"job_id","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskStreamResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/files/actions/":{"post":{"tags":["Resource Operations"],"summary":"API to invoke resource operation request","description":"Invoke dispatcher for incoming resource operation request.","operationId":"invoke_dispatcher_v1_files_actions__post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceOperationSchema"}}},"required":true},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceOperationResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/archive":{"get":{"tags":["Archive Preview"],"summary":"Get a archive preview given file id","description":"Get an archive preview by id or code.","operationId":"get_archive_preview_v1_archive_get","parameters":[{"required":true,"schema":{"title":"File Id","anyOf":[{"type":"string","format":"uuid"},{"type":"string"}]},"name":"file_id","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArchivePreviewResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Archive Preview"],"summary":"Create a new archive preview.","description":"Create a new archive preview.","operationId":"create_archive_preview_v1_archive_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArchivePreviewSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArchivePreviewResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Archive Preview"],"summary":"Delete a new archive preview by file_id.","description":"Delete a new archive preview by file_id.","operationId":"delete_archive_preview_v1_archive_delete","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArchivePreviewDeleteSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v2/resource/lock/":{"get":{"tags":["Resource Locking"],"summary":"Check a lock status","description":"Retrieve status of lock via a resource key.","operationId":"check_lock_v2_resource_lock__get","parameters":[{"required":true,"schema":{"title":"Resource Key","type":"string"},"name":"resource_key","in":"query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Resource Locking"],"summary":"Create a new lock","description":"Create operation lock on a respective resource via a resource key.","operationId":"lock_v2_resource_lock__post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockCreateSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Resource Locking"],"summary":"Remove a lock","description":"Remove operation lock on a respective resource via a resource key.","operationId":"unlock_v2_resource_lock__delete","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockCreateSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v2/resource/lock/bulk":{"post":{"tags":["Resource Locking"],"summary":"Create multiple locks","description":"Bulk create operation locks on respective resources via resource keys.","operationId":"bulk_lock_v2_resource_lock_bulk_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockBulkCreateSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockBulkResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Resource Locking"],"summary":"Remove multiple locks","description":"Bulk remove operation locks on respective resources via resource keys.","operationId":"bulk_unlock_v2_resource_lock_bulk_delete","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockBulkCreateSchema"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResourceLockBulkResponseSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"ArchivePreviewDeleteSchema":{"title":"ArchivePreviewDeleteSchema","required":["file_id"],"type":"object","properties":{"file_id":{"title":"File Id","type":"string","format":"uuid"}}},"ArchivePreviewResponseSchema":{"title":"ArchivePreviewResponseSchema","required":["file_id"],"type":"object","properties":{"file_id":{"title":"File Id","type":"string","format":"uuid"},"archive_preview":{"title":"Archive Preview","type":"string","format":"json-string"}},"description":"Default schema for single workbench in response."},"ArchivePreviewSchema":{"title":"ArchivePreviewSchema","required":["file_id","archive_preview"],"type":"object","properties":{"file_id":{"title":"File Id","type":"string","format":"uuid"},"archive_preview":{"title":"Archive Preview","type":"object"}},"description":"General archive peview schema."},"FileStatusSchema":{"title":"FileStatusSchema","required":["session_id","target_names","target_type","container_code","container_type","action_type","job_id"],"type":"object","properties":{"session_id":{"title":"Session Id","type":"string"},"target_names":{"title":"Target Names","type":"array","items":{"type":"string"}},"target_type":{"title":"Target Type","type":"string"},"container_code":{"title":"Container Code","type":"string"},"container_type":{"title":"Container Type","type":"string"},"action_type":{"title":"Action Type","type":"string"},"status":{"title":"Status","type":"string","default":"RUNNING"},"job_id":{"title":"Job Id","type":"string","format":"uuid"}},"description":"Schema of file status update for Redis streams."},"HTTPValidationError":{"title":"HTTPValidationError","type":"object","properties":{"detail":{"title":"Detail","type":"array","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ResourceLockBulkCreateSchema":{"title":"ResourceLockBulkCreateSchema","required":["resource_keys","operation"],"type":"object","properties":{"resource_keys":{"title":"Resource Keys","type":"array","items":{"type":"string"}},"operation":{"$ref":"#/components/schemas/ResourceLockOperationSchema"}},"description":"Schema for bulk creating resource lock by keys and operations."},"ResourceLockBulkResponseSchema":{"title":"ResourceLockBulkResponseSchema","required":["keys_status"],"type":"object","properties":{"keys_status":{"title":"Keys Status","type":"array","items":{"maxItems":2,"minItems":2,"type":"array","items":[{"type":"string"},{"type":"boolean"}]}}},"description":"Schema for status of operation locking for multiple keys."},"ResourceLockCreateSchema":{"title":"ResourceLockCreateSchema","required":["resource_key","operation"],"type":"object","properties":{"resource_key":{"title":"Resource Key","type":"string"},"operation":{"$ref":"#/components/schemas/ResourceLockOperationSchema"}},"description":"Schema for creating resource lock by key and operation."},"ResourceLockOperationSchema":{"title":"ResourceLockOperationSchema","enum":["read","write","<class 'dataops.components.resource_lock.schemas.ResourceLockOperationSchema.Config'>"],"type":"string","description":"Operations schema for locking a resource."},"ResourceLockResponseSchema":{"title":"ResourceLockResponseSchema","required":["key"],"type":"object","properties":{"key":{"title":"Key","type":"string"},"status":{"title":"Status","type":"string","default":false}},"description":"Schema for key and status of locked resource in response."},"ResourceOperationPayloadSchema":{"title":"ResourceOperationPayloadSchema","required":["targets","source"],"type":"object","properties":{"request_info":{"title":"Request Info","type":"object"},"targets":{"title":"Targets","type":"array","items":{"$ref":"#/components/schemas/ResourceOperationTargetSchema"}},"source":{"title":"Source","type":"string"},"destination":{"title":"Destination","type":"string"}},"description":"Schema of payload for resource operation request."},"ResourceOperationResponseSchema":{"title":"ResourceOperationResponseSchema","required":["operation_info"],"type":"object","properties":{"operation_info":{"title":"Operation Info","type":"array","items":{"$ref":"#/components/schemas/FileStatusSchema"}}},"description":"Schema of resource operation request response."},"ResourceOperationSchema":{"title":"ResourceOperationSchema","required":["session_id","payload","operator","operation","project_code"],"type":"object","properties":{"session_id":{"title":"Session Id","type":"string"},"task_id":{"title":"Task Id","type":"string","default":"default_task_id"},"job_id":{"title":"Job Id","type":"string","default":"default_job_id"},"payload":{"$ref":"#/components/schemas/ResourceOperationPayloadSchema"},"operator":{"title":"Operator","type":"string"},"operation":{"title":"Operation","type":"string"},"project_code":{"title":"Project Code","type":"string"},"status":{"title":"Status","type":"string","default":"RUNNING"},"str":{"title":"Str","type":"string","default":"RUNNING"},"progress":{"title":"Progress","type":"integer","default":0},"int":{"title":"Int","type":"integer","default":0}},"description":"Schema of resource operation request for session job creation."},"ResourceOperationTargetSchema":{"title":"ResourceOperationTargetSchema","required":["id"],"type":"object","properties":{"id":{"title":"Id","type":"string"}},"description":"Schema of resource operation target id for session job creation."},"TaskDeleteSchema":{"title":"TaskDeleteSchema","required":["session_id"],"type":"object","properties":{"session_id":{"title":"Session Id","type":"string"},"label":{"title":"Label","type":"string","default":"Container"},"job_id":{"title":"Job Id","type":"string","default":"*"},"action":{"title":"Action","type":"string","default":"*"},"code":{"title":"Code","type":"string","default":"*"},"operator":{"title":"Operator","type":"string","default":"*"}},"description":"Schema for deleting session job."},"TaskResponseSchema":{"title":"TaskResponseSchema","type":"object","properties":{"task_status":{"title":"Task Status","type":"string","default":"SUCCEED"}},"description":"Response schema for creating session job."},"TaskRetrieveResponseSchema":{"title":"TaskRetrieveResponseSchema","type":"object","properties":{"task_info":{"title":"Task Info","type":"array","items":{},"default":[]}},"description":"Response schema for retrieving session job info."},"TaskSchema":{"title":"TaskSchema","required":["session_id","job_id","source","action","code","operator"],"type":"object","properties":{"session_id":{"title":"Session Id","type":"string"},"label":{"title":"Label","type":"string","default":"Container"},"task_id":{"title":"Task Id","type":"string","default":"default_task"},"job_id":{"title":"Job Id","type":"string"},"source":{"title":"Source","type":"string"},"action":{"title":"Action","type":"string"},"target_status":{"title":"Target Status","type":"string","default":"INIT"},"code":{"title":"Code","type":"string"},"operator":{"title":"Operator","type":"string"},"progress":{"title":"Progress","type":"integer","default":0},"payload":{"title":"Payload","type":"object","default":{}}},"description":"Schema for creating session job."},"TaskStreamCreateSchema":{"title":"TaskStreamCreateSchema","required":["session_id","target_names","target_type","container_code","container_type","action_type","status"],"type":"object","properties":{"session_id":{"title":"Session Id","type":"string"},"target_names":{"title":"Target Names","type":"array","items":{"type":"string"}},"target_type":{"title":"Target Type","type":"string"},"container_code":{"title":"Container Code","type":"string"},"container_type":{"title":"Container Type","type":"string"},"action_type":{"title":"Action Type","type":"string"},"status":{"title":"Status","type":"string"},"job_id":{"title":"Job Id","type":"string","format":"uuid","default":"6636848e-12c6-4114-ab69-943c972b0237"},"entry_id":{"title":"Entry Id","type":"string"}},"description":"Schema for writing file status."},"TaskStreamResponseSchema":{"title":"TaskStreamResponseSchema","type":"object","properties":{"total":{"title":"Total","type":"integer","default":0},"stream_info":{"title":"Stream Info","anyOf":[{"type":"object"},{"type":"array","items":{}},{"type":"array","items":{"type":"object"}}],"default":{}}},"description":"Response schema for writing and retrieving file status."},"TaskUpdateResponseSchema":{"title":"TaskUpdateResponseSchema","type":"object","properties":{"task_info":{"title":"Task Info","type":"object","default":{}}},"description":"Response schema for updating session job info."},"TaskUpdateSchema":{"title":"TaskUpdateSchema","required":["session_id","job_id","status"],"type":"object","properties":{"session_id":{"title":"Session Id","type":"string"},"label":{"title":"Label","type":"string","default":"Container"},"job_id":{"title":"Job Id","type":"string"},"status":{"title":"Status","type":"string"},"add_payload":{"title":"Add Payload","type":"object","default":{}},"progress":{"title":"Progress","type":"integer","default":0}},"description":"Schema for updating session job."},"ValidationError":{"title":"ValidationError","required":["loc","msg","type"],"type":"object","properties":{"loc":{"title":"Location","type":"array","items":{"anyOf":[{"type":"string"},{"type":"integer"}]}},"msg":{"title":"Message","type":"string"},"type":{"title":"Error Type","type":"string"}}}}}}