{ "components": { "schemas": { "Analysis": { "properties": { "age_months": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Age Months" }, "checks": { "items": { "additionalProperties": true, "type": "object" }, "title": "Checks", "type": "array" }, "id": { "title": "Id", "type": "string" }, "level": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Level" }, "metrics": { "items": { "$ref": "#/components/schemas/Metric" }, "title": "Metrics", "type": "array" }, "regions": { "items": { "additionalProperties": true, "type": "object" }, "title": "Regions", "type": "array" }, "valid": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Valid" } }, "required": [ "id", "valid", "level", "age_months", "metrics", "checks", "regions" ], "title": "Analysis", "type": "object" }, "Analyze": { "properties": { "execution": { "anyOf": [ { "$ref": "#/components/schemas/Execution" }, { "type": "null" } ] } }, "title": "Analyze", "type": "object" }, "AnalyzeRequest": { "properties": { "execution": { "anyOf": [ { "$ref": "#/components/schemas/Execution" }, { "type": "null" } ] }, "scope": { "$ref": "#/components/schemas/Scope", "default": { "ids": [], "mode": "pending" } } }, "title": "AnalyzeRequest", "type": "object" }, "Body_add_clinical_validation": { "properties": { "file": { "contentMediaType": "application/octet-stream", "title": "File", "type": "string" } }, "required": [ "file" ], "title": "Body_add_clinical_validation", "type": "object" }, "Body_import_models": { "properties": { "file": { "contentMediaType": "application/octet-stream", "title": "File", "type": "string" } }, "required": [ "file" ], "title": "Body_import_models", "type": "object" }, "Body_start_preview": { "properties": { "ados2": { "anyOf": [ { "format": "binary", "type": "string" }, { "type": "null" } ], "title": "Ados2" }, "birth_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "title": "Birth Date" }, "edf": { "format": "binary", "title": "Edf", "type": "string" }, "pipeline": { "default": "tea", "title": "Pipeline", "type": "string" } }, "required": [ "edf" ], "title": "Body_start_preview", "type": "object" }, "Body_upload": { "properties": { "file": { "contentMediaType": "application/octet-stream", "title": "File", "type": "string" } }, "required": [ "file" ], "title": "Body_upload", "type": "object" }, "Body_upload_training_inputs": { "properties": { "files": { "items": { "format": "binary", "type": "string" }, "minItems": 1, "title": "Files", "type": "array" } }, "required": [ "files" ], "title": "Body_upload_training_inputs", "type": "object" }, "Cancel": { "properties": { "id": { "title": "Id", "type": "string" }, "state": { "enum": [ "queued", "running", "succeeded", "failed", "cancelling", "cancelled" ], "title": "State", "type": "string" }, "status": { "title": "Status", "type": "string" } }, "required": [ "id", "status", "state" ], "title": "Cancel", "type": "object" }, "Condition": { "properties": { "column": { "title": "Column", "type": "string" }, "op": { "enum": [ "equals", "contains", "matches", "present" ], "title": "Op", "type": "string" }, "value": { "default": "", "title": "Value", "type": "string" } }, "required": [ "column", "op" ], "title": "Condition", "type": "object" }, "Correction": { "description": "One field of one record as a reviewer read it in the source document: an identity\nfield (a mistyped record number) or a study's (a stage the scan made unreadable).", "properties": { "entity": { "default": "identity", "enum": [ "identity", "cervical_cytology", "cervical_biopsy", "mammography", "breast_biopsy", "breast_treatment", "clinical_note", "death", "mchat", "ados2", "eeg" ], "title": "Entity", "type": "string" }, "field": { "title": "Field", "type": "string" }, "record": { "title": "Record", "type": "string" }, "value": { "title": "Value", "type": "string" } }, "required": [ "record", "field", "value" ], "title": "Correction", "type": "object" }, "Domain": { "enum": [ "cacu", "cama", "tea" ], "title": "Domain", "type": "string" }, "Edf": { "additionalProperties": false, "description": "EDF files (a column of file hashes) to the facts their header holds: patient code, sex,\nbirth date, recording date, record code, duration and channel count, as `edf_*` columns.\nAn unreadable file keeps its row with `edf_error` set.\n\nUse a filesystem source (`dlt.sources.filesystem:filesystem`) with the uploads folder as\n`bucket_url`, `file_glob: \"*.edf\"`, and `then: \"persistance.readers:read_bytes\"`. Read its\n`content` column with this node. Map `edf_patient_code`, `edf_birth_date`, and `edf_sex` to\nidentity's `record_number`, `birth_date`, and `sex`, using the site's formats and ConceptMap.\n\nThe patient code must match the hospital's record number including its prefix. Feed the\nidentity map into the pipeline's link node alongside the hospital identity source. Map\n`edf_study_date` to `study_date` (format `%Y-%m-%d`), `edf_record_code` to `lab_record_id`,\nand `content` to `edf`, then feed that map and the link into a target with entity `eeg`.", "properties": { "column": { "title": "Column", "type": "string" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "edf", "default": "edf", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] } }, "required": [ "id", "column" ], "title": "Edf", "type": "object" }, "Execution": { "additionalProperties": false, "description": "What a request or a job config carries: None means the deployment's default.", "properties": { "mode": { "anyOf": [ { "enum": [ "sync", "local", "remote" ], "type": "string" }, { "type": "null" } ], "title": "Modo" }, "scheduler": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Planificador Dask" } }, "title": "Ejecuci\u00f3n", "type": "object" }, "Extract": { "additionalProperties": false, "description": "Platform fields read from text, each kept with the text it was read from.\n\n`auto` asks the LLM when one is configured and answering, else applies `patterns`;\nwith neither, the row is held. Patterns are regexes with one group, per field (the\nLLM can propose them from sample documents); their values go through the ConceptMap\nand `formats` as in `map`.", "properties": { "column": { "anyOf": [ { "type": "string" }, { "items": { "type": "string" }, "type": "array" } ], "title": "Column" }, "concept_map": { "anyOf": [ { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, { "type": "null" } ], "title": "Concept Map" }, "entity": { "enum": [ "identity", "cervical_cytology", "cervical_biopsy", "mammography", "breast_biopsy", "breast_treatment", "clinical_note", "death", "mchat", "ados2", "eeg" ], "title": "Entity", "type": "string" }, "formats": { "additionalProperties": { "type": "string" }, "default": {}, "title": "Formats", "type": "object" }, "hints": { "default": "", "title": "Hints", "type": "string" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "extract", "default": "extract", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "method": { "default": "auto", "enum": [ "auto", "llm", "patterns" ], "title": "Method", "type": "string" }, "patterns": { "additionalProperties": { "type": "string" }, "default": {}, "title": "Patterns", "type": "object" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] } }, "required": [ "id", "column", "entity" ], "title": "Extract", "type": "object" }, "Fhir": { "additionalProperties": false, "description": "FHIR R4 Bundles a standard hospital sent (a column of their JSON) as rows of one\nentity: identity, death or a study (core.fhir_in). The sender's own codes go through\nits ConceptMap.", "properties": { "column": { "default": "doc", "title": "Column", "type": "string" }, "concept_map": { "anyOf": [ { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, { "type": "null" } ], "title": "Concept Map" }, "entity": { "enum": [ "identity", "cervical_cytology", "cervical_biopsy", "mammography", "breast_biopsy", "breast_treatment", "clinical_note", "death", "mchat", "ados2", "eeg" ], "title": "Entity", "type": "string" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "fhir", "default": "fhir", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] } }, "required": [ "id", "entity" ], "title": "Fhir", "type": "object" }, "HTTPValidationError": { "properties": { "detail": { "items": { "$ref": "#/components/schemas/ValidationError" }, "title": "Detail", "type": "array" } }, "title": "HTTPValidationError", "type": "object" }, "Health": { "properties": { "dashboard_ok": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Dashboard Ok" }, "dashboard_url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Dashboard Url" }, "error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Error" }, "expected_workers": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Expected Workers" }, "latency_ms": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Latency Ms" }, "mode": { "enum": [ "sync", "local", "remote" ], "title": "Mode", "type": "string" }, "reachable": { "title": "Reachable", "type": "boolean" }, "reference": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Reference" }, "scheduler": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scheduler" }, "threads": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Threads" }, "version_error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Version Error" }, "versions_ok": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Versions Ok" }, "workers": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Workers" } }, "required": [ "mode", "scheduler", "reachable" ], "title": "Health", "type": "object" }, "Join": { "additionalProperties": false, "description": "Two inputs side by side where their columns match.", "properties": { "how": { "default": "inner", "enum": [ "inner", "left" ], "title": "How", "type": "string" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "join", "default": "join", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "on": { "items": { "maxItems": 2, "minItems": 2, "prefixItems": [ { "type": "string" }, { "type": "string" } ], "type": "array" }, "title": "On", "type": "array" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] } }, "required": [ "id", "on" ], "title": "Join", "type": "object" }, "Link": { "additionalProperties": false, "description": "Identity rows from every input, grouped into persons (Splink).\n\nTwo records are the same person when any rule holds (Splink's SQL rule syntax, `l.`\nand `r.` for the two records); persons are the connected groups. A person whose\nrecords disagree on birth date or sex is held for review as a whole. Pairs Splink\nscores above `review` that ended up apart are queued as possible matches.", "properties": { "fields": { "default": [ "record_number", "full_name", "curp", "nss", "birth_date", "sex" ], "items": { "type": "string" }, "title": "Fields", "type": "array" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "link", "default": "link", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] }, "review": { "default": 0.5, "exclusiveMinimum": 0.0, "maximum": 1.0, "title": "Review", "type": "number" }, "rules": { "default": [], "items": { "type": "string" }, "title": "Rules", "type": "array" } }, "required": [ "id" ], "title": "Link", "type": "object" }, "Map": { "additionalProperties": false, "description": "Columns to platform fields, the site's codes translated by its ConceptMap\n(core.concept_map), and its date formats.", "properties": { "concept_map": { "anyOf": [ { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, { "type": "null" } ], "title": "Concept Map" }, "fields": { "additionalProperties": { "type": "string" }, "title": "Fields", "type": "object" }, "formats": { "additionalProperties": { "type": "string" }, "default": {}, "title": "Formats", "type": "object" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "map", "default": "map", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] }, "values": { "additionalProperties": { "type": "string" }, "default": {}, "title": "Values", "type": "object" } }, "required": [ "id", "fields" ], "title": "Map", "type": "object" }, "Metric": { "properties": { "code": { "title": "Code", "type": "string" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model" }, "outside": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Outside" }, "value": { "title": "Value", "type": "number" }, "z": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Z" } }, "required": [ "code", "value", "z", "outside", "model" ], "title": "Metric", "type": "object" }, "Options": { "properties": { "default_mode": { "enum": [ "sync", "local", "remote" ], "title": "Default Mode", "type": "string" }, "schedulers": { "items": { "type": "string" }, "title": "Schedulers", "type": "array" } }, "required": [ "default_mode", "schedulers" ], "title": "Options", "type": "object" }, "PersonDecision": { "properties": { "candidate": { "title": "Candidate", "type": "string" }, "person": { "title": "Person", "type": "string" }, "same": { "title": "Same", "type": "boolean" } }, "required": [ "person", "candidate", "same" ], "title": "PersonDecision", "type": "object" }, "Pipeline": { "properties": { "nodes": { "items": { "discriminator": { "mapping": { "edf": "#/components/schemas/Edf", "extract": "#/components/schemas/Extract", "fhir": "#/components/schemas/Fhir", "join": "#/components/schemas/Join", "link": "#/components/schemas/Link", "map": "#/components/schemas/Map", "read": "#/components/schemas/Read", "route": "#/components/schemas/Route", "source": "#/components/schemas/Source", "target": "#/components/schemas/Target" }, "propertyName": "kind" }, "oneOf": [ { "$ref": "#/components/schemas/Source" }, { "$ref": "#/components/schemas/Read" }, { "$ref": "#/components/schemas/Route" }, { "$ref": "#/components/schemas/Map" }, { "$ref": "#/components/schemas/Extract" }, { "$ref": "#/components/schemas/Edf" }, { "$ref": "#/components/schemas/Fhir" }, { "$ref": "#/components/schemas/Join" }, { "$ref": "#/components/schemas/Link" }, { "$ref": "#/components/schemas/Target" } ] }, "title": "Nodes", "type": "array" } }, "required": [ "nodes" ], "title": "Pipeline", "type": "object" }, "Position": { "properties": { "x": { "title": "X", "type": "number" }, "y": { "title": "Y", "type": "number" } }, "required": [ "x", "y" ], "title": "Position", "type": "object" }, "PreviewAdos2": { "properties": { "classification": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Classification" }, "css": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Css" }, "evaluation_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "title": "Evaluation Date" }, "items": { "additionalProperties": { "anyOf": [ { "type": "number" }, { "type": "null" } ] }, "title": "Items", "type": "object" }, "module": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Module" }, "read": { "items": { "type": "string" }, "title": "Read", "type": "array" }, "titles": { "additionalProperties": { "type": "string" }, "title": "Titles", "type": "object" } }, "required": [ "module", "evaluation_date", "items", "titles", "css", "classification", "read" ], "title": "PreviewAdos2", "type": "object" }, "PreviewEeg": { "properties": { "age_months": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Age Months" }, "bad_channels": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Bad Channels" }, "channels": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Channels" }, "checks": { "items": { "additionalProperties": true, "type": "object" }, "title": "Checks", "type": "array" }, "clean_fraction": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Clean Fraction" }, "duration_min": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Duration Min" }, "error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Error" }, "level": { "title": "Level", "type": "string" }, "line_noise_db": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Line Noise Db" }, "metrics": { "items": { "$ref": "#/components/schemas/PreviewMetric" }, "title": "Metrics", "type": "array" }, "recorded_on": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "title": "Recorded On" }, "sleep": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Sleep" }, "valid": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Valid" } }, "required": [ "valid", "level", "recorded_on", "age_months", "clean_fraction", "bad_channels", "channels", "duration_min", "line_noise_db", "sleep", "checks", "metrics", "error" ], "title": "PreviewEeg", "type": "object" }, "PreviewMetric": { "properties": { "code": { "title": "Code", "type": "string" }, "electrodes": { "additionalProperties": { "$ref": "#/components/schemas/Site" }, "title": "Electrodes", "type": "object" }, "model": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Model" }, "score": { "anyOf": [ { "$ref": "#/components/schemas/Score" }, { "type": "null" } ] }, "value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Value" }, "zones": { "additionalProperties": { "$ref": "#/components/schemas/Site" }, "title": "Zones", "type": "object" } }, "required": [ "code", "value", "score", "model", "electrodes", "zones" ], "title": "PreviewMetric", "type": "object" }, "PreviewResult": { "properties": { "ados2": { "anyOf": [ { "$ref": "#/components/schemas/PreviewAdos2" }, { "type": "null" } ] }, "eeg": { "$ref": "#/components/schemas/PreviewEeg" }, "warnings": { "items": { "type": "string" }, "title": "Warnings", "type": "array" } }, "required": [ "eeg", "ados2", "warnings" ], "title": "PreviewResult", "type": "object" }, "PreviewStatus": { "properties": { "result": { "anyOf": [ { "$ref": "#/components/schemas/PreviewResult" }, { "type": "null" } ] }, "state": { "enum": [ "queued", "running", "succeeded", "failed", "cancelling", "cancelled" ], "title": "State", "type": "string" } }, "required": [ "state", "result" ], "title": "PreviewStatus", "type": "object" }, "Progress": { "description": "The run tag's JSON; the API returns it as it is.", "properties": { "done": { "title": "Done", "type": "integer" }, "elapsed_s": { "title": "Elapsed S", "type": "number" }, "eta_s": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Eta S" }, "mode": { "enum": [ "sync", "local", "remote" ], "title": "Mode", "type": "string" }, "phase": { "title": "Phase", "type": "string" }, "scheduler": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scheduler" }, "tasks": { "anyOf": [ { "$ref": "#/components/schemas/Tasks" }, { "type": "null" } ] }, "total": { "title": "Total", "type": "integer" }, "updated_at": { "title": "Updated At", "type": "string" }, "workers": { "default": [], "items": { "$ref": "#/components/schemas/Worker" }, "title": "Workers", "type": "array" } }, "required": [ "phase", "done", "total", "elapsed_s", "eta_s", "mode", "scheduler", "updated_at" ], "title": "Progress", "type": "object" }, "Read": { "additionalProperties": false, "description": "Files in a column (PDF, Word, Excel, scans...) to text (MarkItDown, OCRmyPDF).", "properties": { "column": { "title": "Column", "type": "string" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "read", "default": "read", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] } }, "required": [ "id", "column" ], "title": "Read", "type": "object" }, "Reference": { "additionalProperties": false, "properties": { "line_hz": { "default": 50, "enum": [ 50, 60 ], "title": "Frecuencia de la red el\u00e9ctrica (Hz)", "type": "integer" }, "name": { "description": "Carpeta dentro de TEA_REFERENCE_ROOT con los EDF y edades.csv", "pattern": "^[A-Za-z0-9._-]{1,64}$", "title": "Cohorte de referencia", "type": "string" } }, "required": [ "name" ], "title": "Reference", "type": "object" }, "Rejection": { "properties": { "entity": { "enum": [ "identity", "cervical_cytology", "cervical_biopsy", "mammography", "breast_biopsy", "breast_treatment", "clinical_note", "death", "mchat", "ados2", "eeg" ], "title": "Entity", "type": "string" }, "reason": { "title": "Reason", "type": "string" }, "record": { "title": "Record", "type": "string" } }, "required": [ "entity", "record", "reason" ], "title": "Rejection", "type": "object" }, "Route": { "additionalProperties": false, "description": "Only the rows where every condition holds (e.g. reports titled \"Citolog\u00eda\").", "properties": { "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "route", "default": "route", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] }, "when": { "items": { "$ref": "#/components/schemas/Condition" }, "title": "When", "type": "array" } }, "required": [ "id", "when" ], "title": "Route", "type": "object" }, "Run": { "properties": { "domain": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Domain" }, "ended": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Ended" }, "error": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Error" }, "id": { "title": "Id", "type": "string" }, "info": { "items": { "type": "string" }, "title": "Info", "type": "array" }, "job": { "title": "Job", "type": "string" }, "outputs": { "anyOf": [ { "additionalProperties": true, "type": "object" }, { "type": "null" } ], "title": "Outputs" }, "progress": { "anyOf": [ { "$ref": "#/components/schemas/Progress" }, { "type": "null" } ] }, "started": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Started" }, "state": { "enum": [ "queued", "running", "succeeded", "failed", "cancelling", "cancelled" ], "title": "State", "type": "string" }, "status": { "title": "Status", "type": "string" }, "steps": { "items": { "$ref": "#/components/schemas/Step" }, "title": "Steps", "type": "array" }, "warnings": { "items": { "type": "string" }, "title": "Warnings", "type": "array" } }, "required": [ "id", "job", "domain", "status", "state", "started", "ended", "progress", "steps", "info", "warnings", "error" ], "title": "Run", "type": "object" }, "RunRequest": { "properties": { "version": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Version" } }, "title": "RunRequest", "type": "object" }, "RunSummary": { "properties": { "domain": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Domain" }, "ended": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Ended" }, "id": { "title": "Id", "type": "string" }, "job": { "title": "Job", "type": "string" }, "started": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Started" }, "state": { "enum": [ "queued", "running", "succeeded", "failed", "cancelling", "cancelled" ], "title": "State", "type": "string" }, "status": { "title": "Status", "type": "string" } }, "required": [ "id", "job", "domain", "status", "state", "started", "ended" ], "title": "RunSummary", "type": "object" }, "SavedPipeline": { "properties": { "pipeline": { "$ref": "#/components/schemas/Pipeline" }, "version": { "title": "Version", "type": "integer" } }, "required": [ "version", "pipeline" ], "title": "SavedPipeline", "type": "object" }, "Scope": { "additionalProperties": false, "description": "Which EEGs an analysis takes: the pending ones, the first `n` of them, or the named\nones (re-analysis), each named by the `id` that `/tea/eegs` shows.", "properties": { "ids": { "default": [], "items": { "type": "string" }, "title": "Ids", "type": "array" }, "mode": { "default": "pending", "enum": [ "pending", "first_n", "ids" ], "title": "Mode", "type": "string" }, "n": { "anyOf": [ { "minimum": 1.0, "type": "integer" }, { "type": "null" } ], "title": "N" } }, "title": "Scope", "type": "object" }, "Score": { "properties": { "median": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Median" }, "outside": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Outside" }, "p5": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P5" }, "p95": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "P95" }, "z": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Z" } }, "required": [ "z", "outside", "p5", "median", "p95" ], "title": "Score", "type": "object" }, "Site": { "properties": { "score": { "anyOf": [ { "$ref": "#/components/schemas/Score" }, { "type": "null" } ] }, "value": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Value" } }, "required": [ "value", "score" ], "title": "Site", "type": "object" }, "Source": { "additionalProperties": false, "description": "One table, file set or API resource, copied as it is (dlt). Merged on the source's\nown primary key or `primary_key`; replaced whole when it has none.", "properties": { "args": { "additionalProperties": true, "default": {}, "title": "Args", "type": "object" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "source", "default": "source", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] }, "primary_key": { "default": [], "items": { "type": "string" }, "title": "Primary Key", "type": "array" }, "resource": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Resource" }, "source": { "pattern": "^[A-Za-z_][\\w.]*:[A-Za-z_]\\w*$", "title": "Source", "type": "string" }, "then": { "anyOf": [ { "pattern": "^[A-Za-z_][\\w.]*:[A-Za-z_]\\w*$", "type": "string" }, { "type": "null" } ], "title": "Then" } }, "required": [ "id", "source" ], "title": "Source", "type": "object" }, "SourceRef": { "properties": { "args": { "additionalProperties": true, "default": {}, "title": "Args", "type": "object" }, "source": { "pattern": "^[A-Za-z_][\\w.]*:[A-Za-z_]\\w*$", "title": "Source", "type": "string" } }, "required": [ "source" ], "title": "SourceRef", "type": "object" }, "Step": { "properties": { "ended": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Ended" }, "key": { "title": "Key", "type": "string" }, "started": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "title": "Started" }, "status": { "title": "Status", "type": "string" } }, "required": [ "key", "status", "started", "ended" ], "title": "Step", "type": "object" }, "Study": { "properties": { "analysed": { "title": "Analysed", "type": "boolean" }, "id": { "title": "Id", "type": "string" }, "lab_record_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Lab Record Id" }, "level": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Level" }, "person_id": { "title": "Person Id", "type": "string" }, "study_date": { "title": "Study Date", "type": "string" }, "valid": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "title": "Valid" } }, "required": [ "id", "person_id", "study_date", "lab_record_id", "analysed", "valid", "level" ], "title": "Study", "type": "object" }, "Target": { "additionalProperties": false, "description": "Rows of platform fields into one platform entity, each row given its person by the\none `link` node among the inputs. Rule breaks are held for review.", "properties": { "entity": { "enum": [ "identity", "cervical_cytology", "cervical_biopsy", "mammography", "breast_biopsy", "breast_treatment", "clinical_note", "death", "mchat", "ados2", "eeg" ], "title": "Entity", "type": "string" }, "id": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Id", "type": "string" }, "inputs": { "default": [], "items": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "type": "string" }, "title": "Inputs", "type": "array" }, "kind": { "const": "target", "default": "target", "title": "Kind", "type": "string" }, "label": { "default": "", "title": "Label", "type": "string" }, "position": { "anyOf": [ { "$ref": "#/components/schemas/Position" }, { "type": "null" } ] } }, "required": [ "id", "entity" ], "title": "Target", "type": "object" }, "Tasks": { "properties": { "erred": { "default": 0, "title": "Erred", "type": "integer" }, "memory": { "default": 0, "title": "Memory", "type": "integer" }, "processing": { "default": 0, "title": "Processing", "type": "integer" }, "queued": { "default": 0, "title": "Queued", "type": "integer" }, "waiting": { "default": 0, "title": "Waiting", "type": "integer" } }, "title": "Tasks", "type": "object" }, "Training": { "properties": { "as_of": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "description": "Fecha de corte de los datos (por omisi\u00f3n, hoy)", "title": "Datos hasta" }, "execution": { "anyOf": [ { "$ref": "#/components/schemas/Execution" }, { "type": "null" } ] }, "models": { "default": [], "items": { "type": "string" }, "title": "Models", "type": "array" }, "reference": { "anyOf": [ { "$ref": "#/components/schemas/Reference" }, { "type": "null" } ] } }, "title": "Training", "type": "object" }, "TrainingConfig": { "properties": { "defaults": { "additionalProperties": true, "title": "Defaults", "type": "object" }, "domain": { "title": "Domain", "type": "string" }, "json_schema": { "additionalProperties": true, "title": "Json Schema", "type": "object" }, "name": { "title": "Name", "type": "string" } }, "required": [ "domain", "name", "json_schema", "defaults" ], "title": "TrainingConfig", "type": "object" }, "ValidationError": { "properties": { "ctx": { "title": "Context", "type": "object" }, "input": { "title": "Input" }, "loc": { "items": { "anyOf": [ { "type": "string" }, { "type": "integer" } ] }, "title": "Location", "type": "array" }, "msg": { "title": "Message", "type": "string" }, "type": { "title": "Error Type", "type": "string" } }, "required": [ "loc", "msg", "type" ], "title": "ValidationError", "type": "object" }, "Version": { "properties": { "aliases": { "items": { "type": "string" }, "title": "Aliases", "type": "array" }, "created": { "title": "Created", "type": "integer" }, "metrics": { "additionalProperties": { "type": "number" }, "title": "Metrics", "type": "object" }, "params": { "additionalProperties": { "type": "string" }, "title": "Params", "type": "object" }, "reports": { "items": { "type": "string" }, "title": "Reports", "type": "array" }, "status": { "enum": [ "champion", "retired", "candidate" ], "title": "Status", "type": "string" }, "version": { "title": "Version", "type": "integer" } }, "required": [ "version", "created", "aliases", "metrics", "params", "reports", "status" ], "title": "Version", "type": "object" }, "Worker": { "properties": { "cpu_pct": { "title": "Cpu Pct", "type": "number" }, "executing": { "title": "Executing", "type": "integer" }, "memory_bytes": { "title": "Memory Bytes", "type": "integer" }, "memory_limit": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Memory Limit" }, "name": { "title": "Name", "type": "string" }, "threads": { "title": "Threads", "type": "integer" } }, "required": [ "name", "cpu_pct", "memory_bytes", "memory_limit", "executing", "threads" ], "title": "Worker", "type": "object" } } }, "info": { "title": "ISSSTELEON", "version": "0.0.0" }, "openapi": "3.1.0", "paths": { "/domains": { "get": { "operationId": "domains", "responses": { "200": { "content": { "application/json": { "schema": { "items": { "$ref": "#/components/schemas/Domain" }, "title": "Response Domains", "type": "array" } } }, "description": "Successful Response" } }, "summary": "Domains" } }, "/execution/health": { "get": { "operationId": "execution_health", "parameters": [ { "in": "query", "name": "mode", "required": false, "schema": { "anyOf": [ { "enum": [ "sync", "local", "remote" ], "type": "string" }, { "type": "null" } ], "title": "Mode" } }, { "in": "query", "name": "scheduler", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Scheduler" } }, { "in": "query", "name": "reference", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Reference" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Health" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Execution Health", "tags": [ "execution" ] } }, "/execution/options": { "get": { "operationId": "execution_options", "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Options" } } }, "description": "Successful Response" } }, "summary": "Execution Options", "tags": [ "execution" ] } }, "/health": { "get": { "operationId": "health", "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Health", "type": "object" } } }, "description": "Successful Response" } }, "summary": "Health" } }, "/ingest/concept-maps": { "get": { "description": "Every ConceptMap a site saved: its id, latest version and when.", "operationId": "concept_maps", "responses": { "200": { "content": { "application/json": { "schema": { "items": { "additionalProperties": true, "type": "object" }, "title": "Response Concept Maps", "type": "array" } } }, "description": "Successful Response" } }, "summary": "Concept Maps", "tags": [ "ingest" ] } }, "/ingest/concept-maps/{map_id}": { "get": { "description": "A site's codes in platform terms (FHIR R4B ConceptMap), latest version.", "operationId": "get_concept_map", "parameters": [ { "in": "path", "name": "map_id", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Map Id", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Response Get Concept Map", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Get Concept Map", "tags": [ "ingest" ] }, "put": { "description": "Saves a new version of a ConceptMap. Its groups target the systems platform fields\ntake codes from, and only codes those fields allow (core.concept_map).", "operationId": "save_concept_map", "parameters": [ { "in": "path", "name": "map_id", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Map Id", "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Doc", "type": "object" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "integer" }, "title": "Response Save Concept Map", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Save Concept Map", "tags": [ "ingest" ] } }, "/ingest/pipelines": { "get": { "operationId": "pipelines", "responses": { "200": { "content": { "application/json": { "schema": { "items": { "additionalProperties": true, "type": "object" }, "title": "Response Pipelines", "type": "array" } } }, "description": "Successful Response" } }, "summary": "Pipelines", "tags": [ "ingest" ] } }, "/ingest/pipelines/{pipeline_id}": { "get": { "description": "A saved pipeline (latest by default), with its secrets masked.", "operationId": "pipeline", "parameters": [ { "in": "path", "name": "pipeline_id", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Pipeline Id", "type": "string" } }, { "in": "query", "name": "version", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": "Version" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SavedPipeline" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Pipeline", "tags": [ "ingest" ] }, "put": { "description": "Saves a new version. Masked secrets sent back are kept as they were saved; every\nConceptMap a node names must exist.", "operationId": "save_pipeline", "parameters": [ { "in": "path", "name": "pipeline_id", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Pipeline Id", "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Pipeline" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "integer" }, "title": "Response Save Pipeline", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Save Pipeline", "tags": [ "ingest" ] } }, "/ingest/pipelines/{pipeline_id}/nodes/{node_id}/rows": { "get": { "description": "What a node produced in the last run (empty if it produced nothing yet).", "operationId": "node_rows", "parameters": [ { "in": "path", "name": "pipeline_id", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Pipeline Id", "type": "string" } }, { "in": "path", "name": "node_id", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Node Id", "type": "string" } }, { "in": "query", "name": "limit", "required": false, "schema": { "default": 50, "maximum": 500, "minimum": 1, "title": "Limit", "type": "integer" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "items": { "additionalProperties": true, "type": "object" }, "title": "Response Node Rows", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Node Rows", "tags": [ "ingest" ] } }, "/ingest/pipelines/{pipeline_id}/runs": { "post": { "description": "Starts the `ingest` job for this pipeline; follow it at /runs/{run_id}.", "operationId": "start_run", "parameters": [ { "in": "path", "name": "pipeline_id", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Pipeline Id", "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RunRequest" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Start Run", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Start Run", "tags": [ "ingest" ] } }, "/ingest/schema": { "get": { "description": "What the canvas draws with: every node kind's form, and the platform entities.", "operationId": "schema", "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Response Schema", "type": "object" } } }, "description": "Successful Response" } }, "summary": "Schema", "tags": [ "ingest" ] } }, "/ingest/sources/preview": { "post": { "description": "The first rows a source node would load.", "operationId": "source_preview", "parameters": [ { "in": "query", "name": "limit", "required": false, "schema": { "default": 20, "maximum": 200, "minimum": 1, "title": "Limit", "type": "integer" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Source" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "items": { "additionalProperties": true, "type": "object" }, "title": "Response Source Preview", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Source Preview", "tags": [ "ingest" ] } }, "/ingest/sources/resources": { "post": { "description": "What a source offers (a database's tables...): also tests that it can be reached.", "operationId": "source_resources", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/SourceRef" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "items": { "type": "string" }, "title": "Response Source Resources", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Source Resources", "tags": [ "ingest" ] } }, "/ingest/uploads": { "post": { "description": "A CSV, Excel or document file for a `filesystem` source: use `bucket_url`.", "operationId": "upload", "requestBody": { "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_upload" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Upload", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Upload", "tags": [ "ingest" ] } }, "/models/{domain}": { "get": { "operationId": "models", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "items": { "type": "string" }, "title": "Response Models", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Models", "tags": [ "models" ] } }, "/models/{domain}/analyze": { "post": { "description": "Starts analysing the studies the domain's models read whole (TEA: its EEGs); follow\nit at /runs.", "operationId": "analyze", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Analyze", "default": {} } } } }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Analyze", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Analyze", "tags": [ "models" ] } }, "/models/{domain}/export": { "get": { "operationId": "export_models", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "query", "name": "names", "required": false, "schema": { "anyOf": [ { "items": { "type": "string" }, "type": "array" }, { "type": "null" } ], "title": "Names" } }, { "in": "query", "name": "versions", "required": false, "schema": { "default": "champion", "enum": [ "champion", "latest", "all" ], "title": "Versions", "type": "string" } } ], "responses": { "200": { "content": { "application/zip": {} }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Export Models", "tags": [ "models" ] } }, "/models/{domain}/import": { "post": { "operationId": "import_models", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "query", "name": "sha256", "required": true, "schema": { "pattern": "^[0-9a-fA-F]{64}$", "title": "Sha256", "type": "string" } } ], "requestBody": { "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_import_models" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Import Models", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Import Models", "tags": [ "models" ] } }, "/models/{domain}/score": { "post": { "description": "Starts a risk batch from each model's champion; follow it at /runs.", "operationId": "score", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Score", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Score", "tags": [ "models" ] } }, "/models/{domain}/train": { "post": { "description": "Starts training a new version of every model of the domain; follow it at /runs.", "operationId": "train", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } } ], "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Training" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Train", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Train", "tags": [ "models" ] } }, "/models/{domain}/{name}/inputs": { "get": { "operationId": "training_inputs", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Response Training Inputs", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Training Inputs", "tags": [ "models" ] } }, "/models/{domain}/{name}/inputs/{set}/files": { "post": { "operationId": "upload_training_inputs", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } }, { "in": "path", "name": "set", "required": true, "schema": { "title": "Set", "type": "string" } } ], "requestBody": { "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_upload_training_inputs" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Response Upload Training Inputs", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Upload Training Inputs", "tags": [ "models" ] } }, "/models/{domain}/{name}/training-config": { "get": { "operationId": "training_config", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TrainingConfig" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Training Config", "tags": [ "models" ] } }, "/models/{domain}/{name}/versions": { "get": { "operationId": "versions", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "items": { "$ref": "#/components/schemas/Version" }, "title": "Response Versions", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Versions", "tags": [ "models" ] } }, "/models/{domain}/{name}/versions/{version}/checks": { "get": { "operationId": "version_checks", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } }, { "in": "path", "name": "version", "required": true, "schema": { "title": "Version", "type": "integer" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Response Version Checks", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Version Checks", "tags": [ "models" ] } }, "/models/{domain}/{name}/versions/{version}/curve": { "get": { "operationId": "curve", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } }, { "in": "path", "name": "version", "required": true, "schema": { "title": "Version", "type": "integer" } }, { "in": "query", "name": "feature", "required": false, "schema": { "default": "value", "title": "Feature", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "items": { "additionalProperties": true, "type": "object" }, "title": "Response Curve", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Curve", "tags": [ "models" ] } }, "/models/{domain}/{name}/versions/{version}/lineage": { "get": { "operationId": "lineage", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } }, { "in": "path", "name": "version", "required": true, "schema": { "title": "Version", "type": "integer" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Response Lineage", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Lineage", "tags": [ "models" ] } }, "/models/{domain}/{name}/versions/{version}/promote": { "post": { "description": "The version risk batches come from from now on; refused (409) without its three\nreports: technical validation, interpretability and clinical validation.", "operationId": "promote", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } }, { "in": "path", "name": "version", "required": true, "schema": { "title": "Version", "type": "integer" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Response Promote", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Promote", "tags": [ "models" ] } }, "/models/{domain}/{name}/versions/{version}/reports/clinical_validation": { "post": { "description": "The clinical team's validation of a version: the third report promotion needs.", "operationId": "add_clinical_validation", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } }, { "in": "path", "name": "version", "required": true, "schema": { "title": "Version", "type": "integer" } } ], "requestBody": { "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_add_clinical_validation" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": true, "title": "Response Add Clinical Validation", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Add Clinical Validation", "tags": [ "models" ] } }, "/models/{domain}/{name}/versions/{version}/reports/{report}": { "get": { "description": "A version's report: the generated ones as JSON (what the governance page draws), the\nclinical validation as the file the clinical team uploaded.", "operationId": "read_report", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } }, { "in": "path", "name": "version", "required": true, "schema": { "title": "Version", "type": "integer" } }, { "in": "path", "name": "report", "required": true, "schema": { "title": "Report", "type": "string" } } ], "responses": { "200": { "content": { "application/json": {}, "application/octet-stream": {} }, "description": "the report as stored" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Read Report", "tags": [ "models" ] } }, "/models/{domain}/{name}/versions/{version}/retire": { "post": { "operationId": "retire", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "name", "required": true, "schema": { "title": "Name", "type": "string" } }, { "in": "path", "name": "version", "required": true, "schema": { "title": "Version", "type": "integer" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Retire", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Retire", "tags": [ "models" ] } }, "/review/conflicts": { "get": { "description": "Rows of one person and date that disagree; reject the wrong ones.", "operationId": "conflicts", "parameters": [ { "in": "query", "name": "entity", "required": true, "schema": { "enum": [ "identity", "cervical_cytology", "cervical_biopsy", "mammography", "breast_biopsy", "breast_treatment", "clinical_note", "death", "mchat", "ados2", "eeg" ], "title": "Entity", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "items": { "additionalProperties": true, "type": "object" }, "title": "Response Conflicts", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Conflicts", "tags": [ "review" ] } }, "/review/corrections": { "post": { "description": "A corrected field of one record; the next run uses it (linking for identity fields,\nthe study's target for the others). Fixing the source too is still worth it.", "operationId": "correct", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Correction" } } }, "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Correct", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Correct", "tags": [ "review" ] } }, "/review/held": { "get": { "description": "Rows a rule held, with the reasons and the values as they came.", "operationId": "held", "parameters": [ { "in": "query", "name": "entity", "required": true, "schema": { "enum": [ "identity", "cervical_cytology", "cervical_biopsy", "mammography", "breast_biopsy", "breast_treatment", "clinical_note", "death", "mchat", "ados2", "eeg" ], "title": "Entity", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "items": { "additionalProperties": true, "type": "object" }, "title": "Response Held", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Held", "tags": [ "review" ] } }, "/review/persons": { "get": { "description": "Persons to settle (with their possible owners) and torn persons (with their\nrecords) left by a pipeline's link node.", "operationId": "persons", "parameters": [ { "in": "query", "name": "pipeline", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Pipeline", "type": "string" } }, { "in": "query", "name": "node", "required": true, "schema": { "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Node", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "items": { "additionalProperties": true, "type": "object" }, "type": "array" }, "title": "Response Persons", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Persons", "tags": [ "review" ] }, "post": { "description": "Whether a person and a possible owner are one patient; applied on the next run.", "operationId": "decide_persons", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PersonDecision" } } }, "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Decide Persons", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Decide Persons", "tags": [ "review" ] } }, "/review/rejections": { "post": { "description": "This record's row must not reach silver; applied on the next run.", "operationId": "reject", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Rejection" } } }, "required": true }, "responses": { "201": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Reject", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Reject", "tags": [ "review" ] } }, "/runs": { "get": { "operationId": "run_history", "parameters": [ { "in": "query", "name": "job", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Job" } }, { "in": "query", "name": "domain", "required": false, "schema": { "anyOf": [ { "$ref": "#/components/schemas/Domain" }, { "type": "null" } ], "title": "Domain" } }, { "in": "query", "name": "limit", "required": false, "schema": { "default": 50, "maximum": 200, "minimum": 1, "title": "Limit", "type": "integer" } }, { "in": "query", "name": "before", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Before" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "items": { "$ref": "#/components/schemas/RunSummary" }, "title": "Response Run History", "type": "array" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Run History", "tags": [ "runs" ] } }, "/runs/{run_id}": { "get": { "operationId": "run_status", "parameters": [ { "in": "path", "name": "run_id", "required": true, "schema": { "title": "Run Id", "type": "string" } }, { "in": "query", "name": "outputs", "required": false, "schema": { "default": false, "title": "Outputs", "type": "boolean" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Run" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Run Status", "tags": [ "runs" ] } }, "/runs/{run_id}/cancel": { "post": { "operationId": "cancel_run", "parameters": [ { "in": "path", "name": "run_id", "required": true, "schema": { "title": "Run Id", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Cancel" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Cancel Run", "tags": [ "runs" ] } }, "/tea/eegs": { "get": { "operationId": "studies", "responses": { "200": { "content": { "application/json": { "schema": { "items": { "$ref": "#/components/schemas/Study" }, "title": "Response Studies", "type": "array" } } }, "description": "Successful Response" } }, "summary": "Studies", "tags": [ "eeg" ] } }, "/tea/eegs/analyze": { "post": { "description": "Starts `tea_eeg`: analyse the EEGs in scope, score the curves, rebuild gold.", "operationId": "analyze_eegs", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/AnalyzeRequest" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Analyze Eegs", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Analyze Eegs", "tags": [ "eeg" ] } }, "/tea/eegs/summary": { "get": { "operationId": "eeg_studies_summary", "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "integer" }, "title": "Response Eeg Studies Summary", "type": "object" } } }, "description": "Successful Response" } }, "summary": "Eeg Studies Summary", "tags": [ "eeg" ] } }, "/tea/eegs/{eeg_id}": { "get": { "operationId": "study", "parameters": [ { "in": "path", "name": "eeg_id", "required": true, "schema": { "title": "Eeg Id", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Analysis" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Study", "tags": [ "eeg" ] } }, "/tea/preview": { "post": { "operationId": "start_preview", "requestBody": { "content": { "multipart/form-data": { "schema": { "$ref": "#/components/schemas/Body_start_preview" } } }, "required": true }, "responses": { "200": { "content": { "application/json": { "schema": { "additionalProperties": { "type": "string" }, "title": "Response Start Preview", "type": "object" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Start Preview", "tags": [ "preview" ] } }, "/tea/preview/{run_id}": { "get": { "operationId": "preview_status", "parameters": [ { "in": "path", "name": "run_id", "required": true, "schema": { "title": "Run Id", "type": "string" } } ], "responses": { "200": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PreviewStatus" } } }, "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Preview Status", "tags": [ "preview" ] } }, "/{domain}/fhir": { "post": { "description": "A standard hospital's Bundle: checked as FHIR, kept as sent in the sender's inbox,\nand placed by the sender's pipeline (a run starts; follow it at the Location).", "operationId": "post_bundle", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "the sender's pipeline (its fhir nodes read this inbox)", "in": "query", "name": "sender", "required": true, "schema": { "description": "the sender's pipeline (its fhir nodes read this inbox)", "maxLength": 40, "pattern": "^[a-z][a-z0-9_]*$", "title": "Sender", "type": "string" } } ], "requestBody": { "content": { "application/json": { "schema": { "additionalProperties": true, "description": "a FHIR R4 batch or transaction Bundle", "title": "Bundle", "type": "object" } } }, "required": true }, "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "202": { "description": "Successful Response" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Post Bundle", "tags": [ "fhir" ] } }, "/{domain}/fhir/Condition": { "get": { "description": "What clinical notes diagnosed.", "operationId": "search_condition", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "Patient/, comma-separated", "in": "query", "name": "subject", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "Patient/, comma-separated", "title": "Subject" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Condition", "tags": [ "fhir" ] } }, "/{domain}/fhir/DiagnosticReport": { "get": { "description": "The domain's reports (each study of the catalog with a report), as known by the last\nday with data.", "operationId": "search_diagnostic_report", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "Patient/, comma-separated", "in": "query", "name": "subject", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "Patient/, comma-separated", "title": "Subject" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Diagnostic Report", "tags": [ "fhir" ] } }, "/{domain}/fhir/Encounter": { "get": { "description": "Consultations: each study of the catalog without a report, as an encounter.", "operationId": "search_encounter", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "Patient/, comma-separated", "in": "query", "name": "subject", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "Patient/, comma-separated", "title": "Subject" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Encounter", "tags": [ "fhir" ] } }, "/{domain}/fhir/Measure": { "get": { "description": "Every measure of the domain (none for a domain without them yet).", "operationId": "search_measure", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Measure", "tags": [ "fhir" ] } }, "/{domain}/fhir/Measure/{id}": { "get": { "operationId": "read_measure", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "id", "required": true, "schema": { "title": "Id", "type": "string" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Read Measure", "tags": [ "fhir" ] } }, "/{domain}/fhir/MeasureReport": { "get": { "description": "The measure's summary report for each period asked for, evaluated over gold.", "operationId": "search_measure_report", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "the Measure's id or canonical URL", "in": "query", "name": "measure", "required": true, "schema": { "description": "the Measure's id or canonical URL", "title": "Measure", "type": "string" } }, { "description": "semesters (2025-S1) or months (2025-03), comma-separated", "in": "query", "name": "reporting-period", "required": true, "schema": { "description": "semesters (2025-S1) or months (2025-03), comma-separated", "title": "Reporting-Period", "type": "string" } }, { "description": "count only what was known by then", "in": "query", "name": "as-of", "required": false, "schema": { "anyOf": [ { "format": "date-time", "type": "string" }, { "type": "null" } ], "description": "count only what was known by then", "title": "As-Of" } }, { "description": "durations count to this day", "in": "query", "name": "event-cutoff", "required": false, "schema": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "description": "durations count to this day", "title": "Event-Cutoff" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Measure Report", "tags": [ "fhir" ] } }, "/{domain}/fhir/Observation": { "get": { "description": "Every result of the domain's reports, one per field of the catalog.", "operationId": "search_observation", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "Patient/, comma-separated", "in": "query", "name": "subject", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "Patient/, comma-separated", "title": "Subject" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Observation", "tags": [ "fhir" ] } }, "/{domain}/fhir/Patient": { "get": { "description": "Patients, or the domain's follow-up list selected by window or start.\n\nFor TEA, a cutoff or a TEA filter also selects the follow-up list. Patients without\nfollow-up episodes appear only in the plain search.", "operationId": "search_patient", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "query", "name": "_id", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": " Id" } }, { "description": "months: the domain's follow-up list over that window up to the cut-off", "in": "query", "name": "follow-up-window", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "months: the domain's follow-up list over that window up to the cut-off", "title": "Follow-Up-Window" } }, { "description": "explicit window start that overrides follow-up-window", "in": "query", "name": "follow-up-start", "required": false, "schema": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "description": "explicit window start that overrides follow-up-window", "title": "Follow-Up-Start" } }, { "description": "default: the last day with data", "in": "query", "name": "follow-up-cutoff", "required": false, "schema": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "description": "default: the last day with data", "title": "Follow-Up-Cutoff" } }, { "in": "query", "name": "follow-up-status", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Follow-Up-Status" } }, { "description": "-recent or -risk-", "in": "query", "name": "_sort", "required": false, "schema": { "default": "-recent", "description": "-recent or -risk-", "title": " Sort", "type": "string" } }, { "description": "years", "in": "query", "name": "risk-horizon", "required": false, "schema": { "anyOf": [ { "type": "number" }, { "type": "null" } ], "description": "years", "title": "Risk-Horizon" } }, { "description": "any of ('DiagnosticReport:subject', 'RiskAssessment:subject', 'Observation:subject')", "in": "query", "name": "_revinclude", "required": false, "schema": { "default": [], "description": "any of ('DiagnosticReport:subject', 'RiskAssessment:subject', 'Observation:subject')", "items": { "type": "string" }, "title": " Revinclude", "type": "array" } }, { "description": "DiagnosticReport:result", "in": "query", "name": "_include:iterate", "required": false, "schema": { "default": [], "description": "DiagnosticReport:result", "items": { "type": "string" }, "title": " Include:Iterate", "type": "array" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Patient", "tags": [ "fhir" ] } }, "/{domain}/fhir/Patient/$eeg-summary": { "get": { "description": "EEG counts for the follow-up list. Without a window or start, use the whole history.", "operationId": "eeg_summary", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "months: the domain's follow-up list over that window up to the cut-off", "in": "query", "name": "follow-up-window", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "description": "months: the domain's follow-up list over that window up to the cut-off", "title": "Follow-Up-Window" } }, { "description": "explicit window start that overrides follow-up-window", "in": "query", "name": "follow-up-start", "required": false, "schema": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "description": "explicit window start that overrides follow-up-window", "title": "Follow-Up-Start" } }, { "description": "default: the last day with data", "in": "query", "name": "follow-up-cutoff", "required": false, "schema": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "description": "default: the last day with data", "title": "Follow-Up-Cutoff" } }, { "in": "query", "name": "follow-up-status", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "title": "Follow-Up-Status" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Eeg Summary", "tags": [ "fhir" ] } }, "/{domain}/fhir/Patient/{id}": { "get": { "operationId": "read_patient", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "in": "path", "name": "id", "required": true, "schema": { "title": "Id", "type": "string" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Read Patient", "tags": [ "fhir" ] } }, "/{domain}/fhir/Procedure": { "get": { "description": "The procedures the domain's timeline infers (CaCu: colposcopies and treatments).", "operationId": "search_procedure", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "Patient/, comma-separated", "in": "query", "name": "subject", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "Patient/, comma-separated", "title": "Subject" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Procedure", "tags": [ "fhir" ] } }, "/{domain}/fhir/RiskAssessment": { "get": { "description": "The champion models' risks, one per model and index date.", "operationId": "search_risk_assessment", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } }, { "description": "Patient/, comma-separated", "in": "query", "name": "subject", "required": false, "schema": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "description": "Patient/, comma-separated", "title": "Subject" } }, { "in": "query", "name": "_count", "required": false, "schema": { "anyOf": [ { "type": "integer" }, { "type": "null" } ], "title": " Count" } }, { "in": "query", "name": "_offset", "required": false, "schema": { "default": 0, "title": " Offset", "type": "integer" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Search Risk Assessment", "tags": [ "fhir" ] } }, "/{domain}/fhir/metadata": { "get": { "description": "What this base serves: built from the routes above, so it cannot drift from them.", "operationId": "metadata", "parameters": [ { "in": "path", "name": "domain", "required": true, "schema": { "$ref": "#/components/schemas/Domain" } } ], "responses": { "200": { "content": { "application/fhir+json": { "schema": { "type": "object" } } }, "description": "FHIR" }, "422": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } }, "description": "Validation Error" } }, "summary": "Metadata", "tags": [ "fhir" ] } } } }