diff --git a/pr_body.md b/pr_body.md index 3c64218..a3b24d4 100644 --- a/pr_body.md +++ b/pr_body.md @@ -3,37 +3,17 @@ This PR was automatically generated by the schema check workflow. ### Changed Files -- `schema/chemi-chet-dev.json` -- `schema/chemi-chet-staging.json` -- `schema/chemi-opera-dev.json` -- `schema/chemi-opera-staging.json` -- `schema/chemi-pfas_cats-dev.json` -- `schema/chemi-pfas_cats-staging.json` -- `schema/chemi-services-dev.json` +- `schema/chemi-amos-dev.json` +- `schema/chemi-amos-staging.json` +- `schema/chemi-arn_cats-dev.json` +- `schema/chemi-ncc_cats-dev.json` - `schema/chemi-services-staging.json` - `schema/chemi-webtest-dev.json` - `schema/chemi-webtest-prod.json` - `schema/chemi-webtest-staging.json` - `schema/coverage_baseline.json` -### Endpoint Changes - -**Summary:** 2 endpoints added, 1 removed, 1 modified across 2 schemas - - -#### Breaking Changes - -| Schema | Endpoint | Change | Detail | -|--------|----------|--------|--------| -| chemi-chet-staging.json | POST /reaction/reaction_DL | Removed | Endpoint no longer exists | -| chemi-opera-staging.json | POST /api/opera | Modified | body params removed: [smiles] | - -#### Non-Breaking Changes - -| Schema | Endpoint | Change | Detail | -|--------|----------|--------|--------| -| chemi-chet-staging.json | OPTIONS /reaction/map_DL | Added | New endpoint | -| chemi-chet-staging.json | POST /reaction/reaction_dl | Added | New endpoint | +No endpoint-level changes detected. ### Function Stub Generation - **Stubs Generated:** 0 @@ -45,11 +25,10 @@ This PR was automatically generated by the schema check workflow. ### API Coverage | API | Coverage | Endpoints | Functions | |-----|----------|-----------|-----------| -| CompTox Dashboard (ct_*) | 100.0% | 135 | 145 (-1) | +| CompTox Dashboard (ct_*) | 100.0% | 135 | 145 | | Cheminformatics (chemi_*) | 98.9% | 186 | 184 | ### Review Checklist -- [ ] **⚠ BREAKING CHANGES detected** — review removed/modified endpoints above - [ ] Review schema changes for breaking API modifications - [ ] Review generated function stubs for correctness - [ ] Check if any existing package functions need updates diff --git a/schema/chemi-amos-dev.json b/schema/chemi-amos-dev.json index 17fcf6b..11eb7a5 100644 --- a/schema/chemi-amos-dev.json +++ b/schema/chemi-amos-dev.json @@ -344,6 +344,18 @@ } } }, + "dtxsids_search_schema": { + "properties": { + "dtxsids": { + "description": "Array of DTXSIDs as strings.", + "example": [ + "DTXSID9020112", + "DTXSID2023985" + ], + "type": "array" + } + } + }, "entropy_similarity_request": { "properties": { "spectrum_1": { @@ -799,6 +811,22 @@ "summary": "Returns a summary of the records in the database, organized by record types, methodologies, and sources." } }, + "/api/amos/dtxsids/": { + "post": { + "description": "", + "parameters": [ + { + "in": "body", + "name": "body", + "schema": { + "$ref": "#/definitions/dtxsids_search_schema" + } + } + ], + "responses": {}, + "summary": "Returns substance information and record counts for a list of DTXSIDs." + } + }, "/api/amos/entropy_similarity/": { "post": { "description": "", @@ -1458,7 +1486,7 @@ ], "responses": { "200": { - "description": "A JSON object with DTXSIDs as keys and an array of highest found entropy similarity scores as the values. The order of values in the array corresponds to their order in the list of user-submitted spectra. If no spectra were found for a given DTXSID, the DTXSID will map to None." + "description": "A JSON object with DTXSIDs as keys and an array of dictionaries as the values. Each dictionary contains a similarity score and the spectrum that had that score. The order of values in the array corresponds to their order in the list of user-submitted spectra. If no spectra were found for a given DTXSID, the result will be None instead of a dictionary." } }, "summary": "Given a list of DTXSIDs and a list of mass spectra, return the highest similarity score for each combination of" @@ -1720,6 +1748,66 @@ "summary": "Returns a list of release notes for AMOS." } }, + "/api/amos/retrieve_fact_sheets/": { + "post": { + "description": "", + "parameters": [ + { + "description": "List of fact sheet IDs to return information on.", + "in": "query", + "name": "internal_ids", + "required": false, + "type": "array of strings" + } + ], + "responses": { + "200": { + "description": "A list of information on the submitted batch of fact sheets." + } + }, + "summary": "Returns information on a batch of fact sheets specified by internal ID." + } + }, + "/api/amos/retrieve_product_declarations/": { + "post": { + "description": "", + "parameters": [ + { + "description": "List of product declaration IDs to return information on.", + "in": "query", + "name": "internal_ids", + "required": false, + "type": "array of strings" + } + ], + "responses": { + "200": { + "description": "A list of information on the submitted batch of product declarations." + } + }, + "summary": "Returns information on a batch of product declarations specified by internal ID." + } + }, + "/api/amos/retrieve_safety_data_sheets/": { + "post": { + "description": "", + "parameters": [ + { + "description": "List of safety data sheet IDs to return information on.", + "in": "query", + "name": "internal_ids", + "required": false, + "type": "array of strings" + } + ], + "responses": { + "200": { + "description": "A list of information on the submitted batch of safety data sheets." + } + }, + "summary": "Returns information on a batch of safety data sheets specified by internal ID." + } + }, "/api/amos/safety_data_sheet_keyset_pagination/{limit}": { "get": { "description": "", @@ -1814,6 +1902,41 @@ "summary": "Retrieves a list of records from the ElasticSearch database that contain a searched substring" } }, + "/api/amos/search_for_document_ids/{record_type}": { + "post": { + "description": "matches, and document text.", + "parameters": [ + { + "description": "Record type to filter by. Should be either 'Fact Sheet', 'Method', 'Product Declaration', or 'Safety Data Sheet' (capitalization included).", + "in": "path", + "name": "record_type", + "required": true, + "type": "string" + }, + { + "description": "Search query parameters. Exact parameters are still in flux, but generally consist of database field names with values and flags for whether to perform exact matches or not.", + "in": "query", + "name": "search_info", + "required": false, + "type": "dict" + }, + { + "description": "List of field names in search_info that are fields in the record_info table in PostgreSQL.", + "in": "query", + "name": "record_info_fields", + "type": "array of strings" + }, + { + "description": "List of field names in search_info that are fields in the fact_sheets table in PostgreSQL.", + "in": "query", + "name": "table_fields", + "type": "array of strings" + } + ], + "responses": {}, + "summary": "Runs searches for document IDs that pass a list of submitted filters, including document metadata, substance" + } + }, "/api/amos/spectral_entropy/": { "post": { "description": "", diff --git a/schema/chemi-amos-staging.json b/schema/chemi-amos-staging.json index 17fcf6b..11eb7a5 100644 --- a/schema/chemi-amos-staging.json +++ b/schema/chemi-amos-staging.json @@ -344,6 +344,18 @@ } } }, + "dtxsids_search_schema": { + "properties": { + "dtxsids": { + "description": "Array of DTXSIDs as strings.", + "example": [ + "DTXSID9020112", + "DTXSID2023985" + ], + "type": "array" + } + } + }, "entropy_similarity_request": { "properties": { "spectrum_1": { @@ -799,6 +811,22 @@ "summary": "Returns a summary of the records in the database, organized by record types, methodologies, and sources." } }, + "/api/amos/dtxsids/": { + "post": { + "description": "", + "parameters": [ + { + "in": "body", + "name": "body", + "schema": { + "$ref": "#/definitions/dtxsids_search_schema" + } + } + ], + "responses": {}, + "summary": "Returns substance information and record counts for a list of DTXSIDs." + } + }, "/api/amos/entropy_similarity/": { "post": { "description": "", @@ -1458,7 +1486,7 @@ ], "responses": { "200": { - "description": "A JSON object with DTXSIDs as keys and an array of highest found entropy similarity scores as the values. The order of values in the array corresponds to their order in the list of user-submitted spectra. If no spectra were found for a given DTXSID, the DTXSID will map to None." + "description": "A JSON object with DTXSIDs as keys and an array of dictionaries as the values. Each dictionary contains a similarity score and the spectrum that had that score. The order of values in the array corresponds to their order in the list of user-submitted spectra. If no spectra were found for a given DTXSID, the result will be None instead of a dictionary." } }, "summary": "Given a list of DTXSIDs and a list of mass spectra, return the highest similarity score for each combination of" @@ -1720,6 +1748,66 @@ "summary": "Returns a list of release notes for AMOS." } }, + "/api/amos/retrieve_fact_sheets/": { + "post": { + "description": "", + "parameters": [ + { + "description": "List of fact sheet IDs to return information on.", + "in": "query", + "name": "internal_ids", + "required": false, + "type": "array of strings" + } + ], + "responses": { + "200": { + "description": "A list of information on the submitted batch of fact sheets." + } + }, + "summary": "Returns information on a batch of fact sheets specified by internal ID." + } + }, + "/api/amos/retrieve_product_declarations/": { + "post": { + "description": "", + "parameters": [ + { + "description": "List of product declaration IDs to return information on.", + "in": "query", + "name": "internal_ids", + "required": false, + "type": "array of strings" + } + ], + "responses": { + "200": { + "description": "A list of information on the submitted batch of product declarations." + } + }, + "summary": "Returns information on a batch of product declarations specified by internal ID." + } + }, + "/api/amos/retrieve_safety_data_sheets/": { + "post": { + "description": "", + "parameters": [ + { + "description": "List of safety data sheet IDs to return information on.", + "in": "query", + "name": "internal_ids", + "required": false, + "type": "array of strings" + } + ], + "responses": { + "200": { + "description": "A list of information on the submitted batch of safety data sheets." + } + }, + "summary": "Returns information on a batch of safety data sheets specified by internal ID." + } + }, "/api/amos/safety_data_sheet_keyset_pagination/{limit}": { "get": { "description": "", @@ -1814,6 +1902,41 @@ "summary": "Retrieves a list of records from the ElasticSearch database that contain a searched substring" } }, + "/api/amos/search_for_document_ids/{record_type}": { + "post": { + "description": "matches, and document text.", + "parameters": [ + { + "description": "Record type to filter by. Should be either 'Fact Sheet', 'Method', 'Product Declaration', or 'Safety Data Sheet' (capitalization included).", + "in": "path", + "name": "record_type", + "required": true, + "type": "string" + }, + { + "description": "Search query parameters. Exact parameters are still in flux, but generally consist of database field names with values and flags for whether to perform exact matches or not.", + "in": "query", + "name": "search_info", + "required": false, + "type": "dict" + }, + { + "description": "List of field names in search_info that are fields in the record_info table in PostgreSQL.", + "in": "query", + "name": "record_info_fields", + "type": "array of strings" + }, + { + "description": "List of field names in search_info that are fields in the fact_sheets table in PostgreSQL.", + "in": "query", + "name": "table_fields", + "type": "array of strings" + } + ], + "responses": {}, + "summary": "Runs searches for document IDs that pass a list of submitted filters, including document metadata, substance" + } + }, "/api/amos/spectral_entropy/": { "post": { "description": "", diff --git a/schema/chemi-arn_cats-dev.json b/schema/chemi-arn_cats-dev.json index 6ca16f5..6aa4a26 100644 --- a/schema/chemi-arn_cats-dev.json +++ b/schema/chemi-arn_cats-dev.json @@ -237,100 +237,30 @@ "content": { "application/json": { "schema": { - "anyOf": [ - { - "type": "object", - "properties": { - "smiles": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Array of SMILES strings, same input style as amnb_nate." - }, - "model": { - "type": "string", - "enum": [ - "RF", - "NN" - ], - "default": "RF" - } + "type": "object", + "properties": { + "smiles": { + "type": "array", + "items": { + "type": "string" }, - "required": [ - "smiles" - ], - "additionalProperties": false + "description": "Array of SMILES strings, same input style as amnb_nate." }, - { - "type": "object", - "properties": { - "chemicals": { - "type": "array", - "items": { - "type": "object", - "properties": { - "id": { - "oneOf": [ - { - "type": "integer" - }, - { - "type": "string" - } - ] - }, - "smiles": { - "type": "string" - } - }, - "required": [ - "id", - "smiles" - ], - "additionalProperties": false - }, - "description": "Array of objects with required id and smiles." - }, - "model": { - "type": "string", - "enum": [ - "RF", - "NN" - ], - "default": "RF" - } - }, - "required": [ - "chemicals" - ], - "additionalProperties": false + "chemicals": { + "type": "array", + "items": {}, + "description": "Array of objects with optional id and smiles, or an array of SMILES strings for backward compatibility." }, - { - "type": "object", - "properties": { - "chemicals": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Array of SMILES strings accepted through the legacy chemicals field for backward compatibility." - }, - "model": { - "type": "string", - "enum": [ - "RF", - "NN" - ], - "default": "RF" - } - }, - "required": [ - "chemicals" + "model": { + "type": "string", + "enum": [ + "RF", + "NN" ], - "additionalProperties": false + "default": "RF" } - ] + }, + "additionalProperties": false }, "examples": { "smilesRequest": { @@ -540,6 +470,32 @@ }, "components": { "schemas": { + "Request": { + "type": "object", + "properties": { + "smiles": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Array of SMILES strings, same input style as amnb_nate." + }, + "chemicals": { + "type": "array", + "items": {}, + "description": "Array of objects with optional id and smiles, or an array of SMILES strings for backward compatibility." + }, + "model": { + "type": "string", + "enum": [ + "RF", + "NN" + ], + "default": "RF" + } + }, + "additionalProperties": false + }, "PredictionItem": { "type": "object", "properties": { diff --git a/schema/chemi-ncc_cats-dev.json b/schema/chemi-ncc_cats-dev.json index b4d18dc..3da6c17 100644 --- a/schema/chemi-ncc_cats-dev.json +++ b/schema/chemi-ncc_cats-dev.json @@ -268,17 +268,11 @@ ] } }, - "required": [ - "smiles" - ], "additionalProperties": false }, - "description": "Array of input chemicals with required smiles and optional id, logp, and ws." + "description": "Array of input chemicals with optional id, smiles, logp, and ws. Missing smiles are returned as item-level errors." } }, - "required": [ - "chemicals" - ], "additionalProperties": false }, "examples": { @@ -517,17 +511,11 @@ ] } }, - "required": [ - "smiles" - ], "additionalProperties": false }, - "description": "Array of input chemicals with required smiles and optional id, logp, and ws." + "description": "Array of input chemicals with optional id, smiles, logp, and ws. Missing smiles are returned as item-level errors." } }, - "required": [ - "chemicals" - ], "additionalProperties": false }, "InputChemical": { @@ -569,9 +557,6 @@ ] } }, - "required": [ - "smiles" - ], "additionalProperties": false }, "PredictionItem": { diff --git a/schema/chemi-services-staging.json b/schema/chemi-services-staging.json index dcf74b6..14cf37b 100644 --- a/schema/chemi-services-staging.json +++ b/schema/chemi-services-staging.json @@ -678,10 +678,10 @@ "unit": { "type": "string" }, - "headerNameWithUnits": { + "fullName": { "type": "string" }, - "fullName": { + "headerNameWithUnits": { "type": "string" } } diff --git a/schema/chemi-webtest-dev.json b/schema/chemi-webtest-dev.json index c476e6b..d55e87c 100644 --- a/schema/chemi-webtest-dev.json +++ b/schema/chemi-webtest-dev.json @@ -784,10 +784,6 @@ "description": { "type": "string" }, - "valueDigits": { - "type": "integer", - "format": "int32" - }, "binary": { "type": "boolean" }, @@ -803,6 +799,10 @@ "logValueDigits": { "type": "integer", "format": "int32" + }, + "valueDigits": { + "type": "integer", + "format": "int32" } } }, diff --git a/schema/chemi-webtest-prod.json b/schema/chemi-webtest-prod.json index 3adf7e6..013419c 100644 --- a/schema/chemi-webtest-prod.json +++ b/schema/chemi-webtest-prod.json @@ -597,12 +597,6 @@ "$ref": "#/components/schemas/MethodInfo" } }, - "endpoints": { - "type": "array", - "items": { - "$ref": "#/components/schemas/EndpointInfo" - } - }, "inputFormats": { "type": "array", "items": { @@ -625,6 +619,12 @@ "MSP" ] } + }, + "endpoints": { + "type": "array", + "items": { + "$ref": "#/components/schemas/EndpointInfo" + } } } } diff --git a/schema/chemi-webtest-staging.json b/schema/chemi-webtest-staging.json index c476e6b..53eaa56 100644 --- a/schema/chemi-webtest-staging.json +++ b/schema/chemi-webtest-staging.json @@ -784,13 +784,13 @@ "description": { "type": "string" }, + "binary": { + "type": "boolean" + }, "valueDigits": { "type": "integer", "format": "int32" }, - "binary": { - "type": "boolean" - }, "units": { "type": "string" }, diff --git a/schema/coverage_baseline.json b/schema/coverage_baseline.json index efd8ae9..c04ca24 100644 --- a/schema/coverage_baseline.json +++ b/schema/coverage_baseline.json @@ -5,5 +5,5 @@ "chemi_coverage": 98.9, "chemi_endpoints": 186, "chemi_functions": 184, - "timestamp": "2026-04-08T10:17:14Z" + "timestamp": "2026-04-13T09:44:08Z" } diff --git a/schema_diff_report.md b/schema_diff_report.md index 0316211..839d750 100644 --- a/schema_diff_report.md +++ b/schema_diff_report.md @@ -1,18 +1 @@ -### Endpoint Changes - -**Summary:** 2 endpoints added, 1 removed, 1 modified across 2 schemas - - -#### Breaking Changes - -| Schema | Endpoint | Change | Detail | -|--------|----------|--------|--------| -| chemi-chet-staging.json | POST /reaction/reaction_DL | Removed | Endpoint no longer exists | -| chemi-opera-staging.json | POST /api/opera | Modified | body params removed: [smiles] | - -#### Non-Breaking Changes - -| Schema | Endpoint | Change | Detail | -|--------|----------|--------|--------| -| chemi-chet-staging.json | OPTIONS /reaction/map_DL | Added | New endpoint | -| chemi-chet-staging.json | POST /reaction/reaction_dl | Added | New endpoint | +No endpoint-level changes detected.