From 5335e761bab13de78d782384acebcf6ae2346ca2 Mon Sep 17 00:00:00 2001 From: Oriol Lopez-Doriga Date: Wed, 26 Jun 2024 21:27:28 +0200 Subject: [PATCH] splitting ressultsets response by oneOf granularity --- .../json/responses/beaconResultsetsResponse.json | 16 ++++++++++++++-- .../analyses/endpoints.json | 12 +----------- .../biosamples/endpoints.json | 12 +----------- .../cohorts/endpoints.json | 12 +----------- .../datasets/endpoints.json | 12 +----------- .../genomicVariations/endpoints.json | 12 +----------- .../individuals/endpoints.json | 12 +----------- .../beacon-v2-default-model/runs/endpoints.json | 12 +----------- 8 files changed, 21 insertions(+), 79 deletions(-) diff --git a/framework/json/responses/beaconResultsetsResponse.json b/framework/json/responses/beaconResultsetsResponse.json index 159fadaab..f2239a57b 100644 --- a/framework/json/responses/beaconResultsetsResponse.json +++ b/framework/json/responses/beaconResultsetsResponse.json @@ -16,8 +16,20 @@ "description": "Information about the response that could be relevant for the Beacon client in order to interpret the results." }, "response": { - "$ref": "./sections/beaconResultsets.json", - "description": "Response for queries that recovers any result." + "oneOf": [ + { + "$ref": "./sections/beaconResultsets.json", + "description": "Response for queries that recovers any result." + }, + { + "$ref": "./sections/beaconCountResultsets.json", + "description": "Response for queries that recovers any result." + }, + { + "$ref": "./sections/beaconBooleanResultsets.json", + "description": "Response for queries that recovers any result." + } + ] }, "responseSummary": { "$ref": "./sections/beaconSummaryResponseSection.json", diff --git a/models/json/beacon-v2-default-model/analyses/endpoints.json b/models/json/beacon-v2-default-model/analyses/endpoints.json index 570d7201d..321ee1708 100644 --- a/models/json/beacon-v2-default-model/analyses/endpoints.json +++ b/models/json/beacon-v2-default-model/analyses/endpoints.json @@ -57,17 +57,7 @@ "content": { "application/json": { "schema": { - "oneOf": [ - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconBooleanResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconCountResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" - } - ] + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" } } }, diff --git a/models/json/beacon-v2-default-model/biosamples/endpoints.json b/models/json/beacon-v2-default-model/biosamples/endpoints.json index 533d5ceda..7ada90a01 100644 --- a/models/json/beacon-v2-default-model/biosamples/endpoints.json +++ b/models/json/beacon-v2-default-model/biosamples/endpoints.json @@ -61,17 +61,7 @@ "content": { "application/json": { "schema": { - "oneOf": [ - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconBooleanResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconCountResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" - } - ] + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" } } }, diff --git a/models/json/beacon-v2-default-model/cohorts/endpoints.json b/models/json/beacon-v2-default-model/cohorts/endpoints.json index 1e36b7462..0bca605c2 100644 --- a/models/json/beacon-v2-default-model/cohorts/endpoints.json +++ b/models/json/beacon-v2-default-model/cohorts/endpoints.json @@ -74,17 +74,7 @@ "content": { "application/json": { "schema": { - "oneOf": [ - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconBooleanResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconCountResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" - } - ] + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" } } }, diff --git a/models/json/beacon-v2-default-model/datasets/endpoints.json b/models/json/beacon-v2-default-model/datasets/endpoints.json index 3fdc832a4..d50ff8f9c 100644 --- a/models/json/beacon-v2-default-model/datasets/endpoints.json +++ b/models/json/beacon-v2-default-model/datasets/endpoints.json @@ -72,17 +72,7 @@ "content": { "application/json": { "schema": { - "oneOf": [ - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconBooleanResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconCountResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" - } - ] + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" } } }, diff --git a/models/json/beacon-v2-default-model/genomicVariations/endpoints.json b/models/json/beacon-v2-default-model/genomicVariations/endpoints.json index e9101f04f..772a3f9ca 100644 --- a/models/json/beacon-v2-default-model/genomicVariations/endpoints.json +++ b/models/json/beacon-v2-default-model/genomicVariations/endpoints.json @@ -159,17 +159,7 @@ "content": { "application/json": { "schema": { - "oneOf": [ - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconBooleanResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconCountResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" - } - ] + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" } } }, diff --git a/models/json/beacon-v2-default-model/individuals/endpoints.json b/models/json/beacon-v2-default-model/individuals/endpoints.json index 32898cb17..a94c3bdab 100644 --- a/models/json/beacon-v2-default-model/individuals/endpoints.json +++ b/models/json/beacon-v2-default-model/individuals/endpoints.json @@ -57,17 +57,7 @@ "content": { "application/json": { "schema": { - "oneOf": [ - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconBooleanResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconCountResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" - } - ] + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" } } }, diff --git a/models/json/beacon-v2-default-model/runs/endpoints.json b/models/json/beacon-v2-default-model/runs/endpoints.json index b5084bba7..5094d6592 100644 --- a/models/json/beacon-v2-default-model/runs/endpoints.json +++ b/models/json/beacon-v2-default-model/runs/endpoints.json @@ -73,17 +73,7 @@ "content": { "application/json": { "schema": { - "oneOf": [ - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconBooleanResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconCountResponse.json" - }, - { - "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" - } - ] + "$ref": "https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconResultsetsResponse.json" } } },