diff --git a/packages/cbioportal-ts-api-client/src/generated/CBioPortalAPIInternal-docs.json b/packages/cbioportal-ts-api-client/src/generated/CBioPortalAPIInternal-docs.json index a8616dca66f..b4a4c0dc49e 100644 --- a/packages/cbioportal-ts-api-client/src/generated/CBioPortalAPIInternal-docs.json +++ b/packages/cbioportal-ts-api-client/src/generated/CBioPortalAPIInternal-docs.json @@ -558,6 +558,41 @@ "operationId": "getClinicalEventTypeCountsUsingPOST" } }, + "/api/clinical-events-meta/fetch": { + "post": { + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "clinicalEventAttributeRequest", + "schema": { + "$ref": "#/definitions/ClinicalEventAttributeRequest" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "items": { + "$ref": "#/definitions/ClinicalEvent" + }, + "type": "array" + } + } + }, + "tags": [ + "Clinical Events" + ], + "description": "Fetch clinical events meta", + "operationId": "fetchClinicalEventsMetaUsingPOST" + } + }, "/api/cna-genes/fetch": { "post": { "consumes": [ @@ -3219,6 +3254,41 @@ "operationId": "getSignificantlyMutatedGenesUsingGET" } }, + "/api/survival-data/fetch": { + "post": { + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "in": "body", + "name": "survivalRequest", + "schema": { + "$ref": "#/definitions/SurvivalRequest" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "items": { + "$ref": "#/definitions/ClinicalData" + }, + "type": "array" + } + } + }, + "tags": [ + "Survival" + ], + "description": "Fetch survival data", + "operationId": "fetchSurvivalDataUsingPOST" + } + }, "/api/timestamps": { "get": { "produces": [ @@ -3958,6 +4028,27 @@ ], "type": "object" }, + "ClinicalEventAttributeRequest": { + "description": "clinical events Request", + "properties": { + "clinicalEventRequests": { + "items": { + "$ref": "#/definitions/ClinicalEventRequest" + }, + "type": "array", + "uniqueItems": true + }, + "patientIdentifiers": { + "items": { + "$ref": "#/definitions/PatientIdentifier" + }, + "maxItems": 10000000, + "minItems": 1, + "type": "array" + } + }, + "type": "object" + }, "ClinicalEventData": { "properties": { "key": { @@ -3973,6 +4064,47 @@ ], "type": "object" }, + "ClinicalEventRequest": { + "properties": { + "attributes": { + "items": { + "$ref": "#/definitions/ClinicalEventData" + }, + "type": "array" + }, + "eventType": { + "type": "string" + } + }, + "required": [ + "eventType" + ], + "type": "object" + }, + "ClinicalEventRequestIdentifier": { + "properties": { + "clinicalEventRequests": { + "items": { + "$ref": "#/definitions/ClinicalEventRequest" + }, + "maxItems": 10000000, + "minItems": 0, + "type": "array", + "uniqueItems": true + }, + "position": { + "enum": [ + "FIRST", + "LAST" + ], + "type": "string" + } + }, + "required": [ + "position" + ], + "type": "object" + }, "ClinicalEventSample": { "properties": { "patientId": { @@ -5464,6 +5596,17 @@ }, "type": "object" }, + "PatientIdentifier": { + "properties": { + "patientId": { + "type": "string" + }, + "studyId": { + "type": "string" + } + }, + "type": "object" + }, "PatientTreatmentFilter": { "properties": { "treatment": { @@ -6126,6 +6269,35 @@ }, "type": "object" }, + "SurvivalRequest": { + "description": "Survival Data Request", + "properties": { + "attributeIdPrefix": { + "type": "string" + }, + "censoredEventRequestIdentifier": { + "$ref": "#/definitions/ClinicalEventRequestIdentifier" + }, + "endEventRequestIdentifier": { + "$ref": "#/definitions/ClinicalEventRequestIdentifier" + }, + "patientIdentifiers": { + "items": { + "$ref": "#/definitions/PatientIdentifier" + }, + "maxItems": 10000000, + "minItems": 1, + "type": "array" + }, + "startEventRequestIdentifier": { + "$ref": "#/definitions/ClinicalEventRequestIdentifier" + } + }, + "required": [ + "attributeIdPrefix" + ], + "type": "object" + }, "VariantCount": { "properties": { "entrezGeneId": { diff --git a/packages/cbioportal-ts-api-client/src/generated/CBioPortalAPIInternal.ts b/packages/cbioportal-ts-api-client/src/generated/CBioPortalAPIInternal.ts index 02610206a86..d6793bfaaa4 100644 --- a/packages/cbioportal-ts-api-client/src/generated/CBioPortalAPIInternal.ts +++ b/packages/cbioportal-ts-api-client/src/generated/CBioPortalAPIInternal.ts @@ -238,12 +238,30 @@ export type ClinicalEvent = { 'uniqueSampleKey': string +}; +export type ClinicalEventAttributeRequest = { + 'clinicalEventRequests': Array < ClinicalEventRequest > + + 'patientIdentifiers': Array < PatientIdentifier > + }; export type ClinicalEventData = { 'key': string 'value': string +}; +export type ClinicalEventRequest = { + 'attributes': Array < ClinicalEventData > + + 'eventType': string + +}; +export type ClinicalEventRequestIdentifier = { + 'clinicalEventRequests': Array < ClinicalEventRequest > + + 'position': "FIRST" | "LAST" + }; export type ClinicalEventSample = { 'patientId': string @@ -896,6 +914,12 @@ export type OredPatientTreatmentFilters = { export type OredSampleTreatmentFilters = { 'filters': Array < SampleTreatmentFilter > +}; +export type PatientIdentifier = { + 'patientId': string + + 'studyId': string + }; export type PatientTreatmentFilter = { 'treatment': string @@ -1203,6 +1227,18 @@ export type StudyViewStructuralVariantFilter = { 'structVarQueries': Array < Array < StructuralVariantFilterQuery > > +}; +export type SurvivalRequest = { + 'attributeIdPrefix': string + + 'censoredEventRequestIdentifier': ClinicalEventRequestIdentifier + + 'endEventRequestIdentifier': ClinicalEventRequestIdentifier + + 'patientIdentifiers': Array < PatientIdentifier > + + 'startEventRequestIdentifier': ClinicalEventRequestIdentifier + }; export type VariantCount = { 'entrezGeneId': number @@ -2339,6 +2375,78 @@ export default class CBioPortalAPIInternal { return response.body; }); }; + fetchClinicalEventsMetaUsingPOSTURL(parameters: { + 'clinicalEventAttributeRequest' ? : ClinicalEventAttributeRequest, + $queryParameters ? : any + }): string { + let queryParameters: any = {}; + let path = '/api/clinical-events-meta/fetch'; + + if (parameters.$queryParameters) { + Object.keys(parameters.$queryParameters).forEach(function(parameterName) { + var parameter = parameters.$queryParameters[parameterName]; + queryParameters[parameterName] = parameter; + }); + } + let keys = Object.keys(queryParameters); + return this.domain + path + (keys.length > 0 ? '?' + (keys.map(key => key + '=' + encodeURIComponent(queryParameters[key])).join('&')) : ''); + }; + + /** + * Fetch clinical events meta + * @method + * @name CBioPortalAPIInternal#fetchClinicalEventsMetaUsingPOST + * @param {} clinicalEventAttributeRequest - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change. + */ + fetchClinicalEventsMetaUsingPOSTWithHttpInfo(parameters: { + 'clinicalEventAttributeRequest' ? : ClinicalEventAttributeRequest, + $queryParameters ? : any, + $domain ? : string + }): Promise < request.Response > { + const domain = parameters.$domain ? parameters.$domain : this.domain; + const errorHandlers = this.errorHandlers; + const request = this.request; + let path = '/api/clinical-events-meta/fetch'; + let body: any; + let queryParameters: any = {}; + let headers: any = {}; + let form: any = {}; + return new Promise(function(resolve, reject) { + headers['Accept'] = 'application/json'; + headers['Content-Type'] = 'application/json'; + + if (parameters['clinicalEventAttributeRequest'] !== undefined) { + body = parameters['clinicalEventAttributeRequest']; + } + + if (parameters.$queryParameters) { + Object.keys(parameters.$queryParameters).forEach(function(parameterName) { + var parameter = parameters.$queryParameters[parameterName]; + queryParameters[parameterName] = parameter; + }); + } + + request('POST', domain + path, body, headers, queryParameters, form, reject, resolve, errorHandlers); + + }); + }; + + /** + * Fetch clinical events meta + * @method + * @name CBioPortalAPIInternal#fetchClinicalEventsMetaUsingPOST + * @param {} clinicalEventAttributeRequest - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change. + */ + fetchClinicalEventsMetaUsingPOST(parameters: { + 'clinicalEventAttributeRequest' ? : ClinicalEventAttributeRequest, + $queryParameters ? : any, + $domain ? : string + }): Promise < Array < ClinicalEvent > + > { + return this.fetchClinicalEventsMetaUsingPOSTWithHttpInfo(parameters).then(function(response: request.Response) { + return response.body; + }); + }; fetchCNAGenesUsingPOSTURL(parameters: { 'studyViewFilter' ? : StudyViewFilter, $queryParameters ? : any @@ -7314,6 +7422,78 @@ export default class CBioPortalAPIInternal { return response.body; }); }; + fetchSurvivalDataUsingPOSTURL(parameters: { + 'survivalRequest' ? : SurvivalRequest, + $queryParameters ? : any + }): string { + let queryParameters: any = {}; + let path = '/api/survival-data/fetch'; + + if (parameters.$queryParameters) { + Object.keys(parameters.$queryParameters).forEach(function(parameterName) { + var parameter = parameters.$queryParameters[parameterName]; + queryParameters[parameterName] = parameter; + }); + } + let keys = Object.keys(queryParameters); + return this.domain + path + (keys.length > 0 ? '?' + (keys.map(key => key + '=' + encodeURIComponent(queryParameters[key])).join('&')) : ''); + }; + + /** + * Fetch survival data + * @method + * @name CBioPortalAPIInternal#fetchSurvivalDataUsingPOST + * @param {} survivalRequest - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change. + */ + fetchSurvivalDataUsingPOSTWithHttpInfo(parameters: { + 'survivalRequest' ? : SurvivalRequest, + $queryParameters ? : any, + $domain ? : string + }): Promise < request.Response > { + const domain = parameters.$domain ? parameters.$domain : this.domain; + const errorHandlers = this.errorHandlers; + const request = this.request; + let path = '/api/survival-data/fetch'; + let body: any; + let queryParameters: any = {}; + let headers: any = {}; + let form: any = {}; + return new Promise(function(resolve, reject) { + headers['Accept'] = 'application/json'; + headers['Content-Type'] = 'application/json'; + + if (parameters['survivalRequest'] !== undefined) { + body = parameters['survivalRequest']; + } + + if (parameters.$queryParameters) { + Object.keys(parameters.$queryParameters).forEach(function(parameterName) { + var parameter = parameters.$queryParameters[parameterName]; + queryParameters[parameterName] = parameter; + }); + } + + request('POST', domain + path, body, headers, queryParameters, form, reject, resolve, errorHandlers); + + }); + }; + + /** + * Fetch survival data + * @method + * @name CBioPortalAPIInternal#fetchSurvivalDataUsingPOST + * @param {} survivalRequest - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change. + */ + fetchSurvivalDataUsingPOST(parameters: { + 'survivalRequest' ? : SurvivalRequest, + $queryParameters ? : any, + $domain ? : string + }): Promise < Array < ClinicalData > + > { + return this.fetchSurvivalDataUsingPOSTWithHttpInfo(parameters).then(function(response: request.Response) { + return response.body; + }); + }; getAllTimestampsUsingGETURL(parameters: { $queryParameters ? : any }): string {