Skip to content

Commit

Permalink
Update api clients after fixes to swagger decorators
Browse files Browse the repository at this point in the history
  • Loading branch information
alisman committed Nov 25, 2024
1 parent f6c445f commit 22501dd
Show file tree
Hide file tree
Showing 3 changed files with 329 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -628,6 +628,93 @@
"operationId": "fetchCNAGenesUsingPOST"
}
},
"/api/column-store/treatments/patient-counts/fetch": {
"post": {
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"default": "Agent",
"enum": [
"Agent",
"AgentClass",
"AgentTarget"
],
"in": "query",
"name": "tier",
"required": false,
"type": "string"
},
{
"in": "body",
"name": "studyViewFilter",
"schema": {
"$ref": "#/definitions/StudyViewFilter"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/PatientTreatmentReport"
}
}
},
"tags": [
"study-view-column-store-controller"
],
"description": "Get all patient level treatments",
"operationId": "fetchPatientTreatmentCountsUsingPOST"
}
},
"/api/column-store/treatments/sample-counts/fetch": {
"post": {
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"default": "Agent",
"enum": [
"Agent",
"AgentClass",
"AgentTarget"
],
"in": "query",
"name": "tier",
"required": false,
"type": "string"
},
{
"in": "body",
"name": "studyViewFilter",
"schema": {
"$ref": "#/definitions/StudyViewFilter"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/SampleTreatmentReport"
}
}
},
"tags": [
"study-view-column-store-controller"
],
"operationId": "fetchSampleTreatmentCountsUsingPOST"
}
},
"/api/cosmic-counts/fetch": {
"post": {
"consumes": [
Expand Down Expand Up @@ -5704,6 +5791,18 @@
},
"type": "object"
},
"PatientTreatment": {
"properties": {
"count": {
"format": "int32",
"type": "integer"
},
"treatment": {
"type": "string"
}
},
"type": "object"
},
"PatientTreatmentFilter": {
"properties": {
"treatment": {
Expand All @@ -5712,6 +5811,25 @@
},
"type": "object"
},
"PatientTreatmentReport": {
"properties": {
"patientTreatments": {
"items": {
"$ref": "#/definitions/PatientTreatment"
},
"type": "array"
},
"totalPatients": {
"format": "int32",
"type": "integer"
},
"totalSamples": {
"format": "int32",
"type": "integer"
}
},
"type": "object"
},
"PatientTreatmentRow": {
"properties": {
"count": {
Expand Down Expand Up @@ -5930,6 +6048,21 @@
},
"type": "object"
},
"SampleTreatmentReport": {
"properties": {
"totalSamples": {
"format": "int32",
"type": "integer"
},
"treatments": {
"items": {
"$ref": "#/definitions/SampleTreatmentRow"
},
"type": "array"
}
},
"type": "object"
},
"SampleTreatmentRow": {
"properties": {
"count": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -920,10 +920,24 @@ export type PatientIdentifier = {

'studyId': string

};
export type PatientTreatment = {
'count': number

'treatment': string

};
export type PatientTreatmentFilter = {
'treatment': string

};
export type PatientTreatmentReport = {
'patientTreatments': Array < PatientTreatment >

'totalPatients': number

'totalSamples': number

};
export type PatientTreatmentRow = {
'count': number
Expand Down Expand Up @@ -1022,6 +1036,12 @@ export type SampleTreatmentFilter = {

'treatment': string

};
export type SampleTreatmentReport = {
'totalSamples': number

'treatments': Array < SampleTreatmentRow >

};
export type SampleTreatmentRow = {
'count': number
Expand Down Expand Up @@ -2519,6 +2539,172 @@ export default class CBioPortalAPIInternal {
return response.body;
});
};
fetchPatientTreatmentCountsUsingPOSTURL(parameters: {
'tier' ? : "Agent" | "AgentClass" | "AgentTarget",
'studyViewFilter' ? : StudyViewFilter,
$queryParameters ? : any
}): string {
let queryParameters: any = {};
let path = '/api/column-store/treatments/patient-counts/fetch';
if (parameters['tier'] !== undefined) {
queryParameters['tier'] = parameters['tier'];
}

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('&')) : '');
};

/**
* Get all patient level treatments
* @method
* @name CBioPortalAPIInternal#fetchPatientTreatmentCountsUsingPOST
* @param {string} tier - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change.
* @param {} studyViewFilter - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change.
*/
fetchPatientTreatmentCountsUsingPOSTWithHttpInfo(parameters: {
'tier' ? : "Agent" | "AgentClass" | "AgentTarget",
'studyViewFilter' ? : StudyViewFilter,
$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/column-store/treatments/patient-counts/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['tier'] !== undefined) {
queryParameters['tier'] = parameters['tier'];
}

if (parameters['studyViewFilter'] !== undefined) {
body = parameters['studyViewFilter'];
}

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);

});
};

/**
* Get all patient level treatments
* @method
* @name CBioPortalAPIInternal#fetchPatientTreatmentCountsUsingPOST
* @param {string} tier - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change.
* @param {} studyViewFilter - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change.
*/
fetchPatientTreatmentCountsUsingPOST(parameters: {
'tier' ? : "Agent" | "AgentClass" | "AgentTarget",
'studyViewFilter' ? : StudyViewFilter,
$queryParameters ? : any,
$domain ? : string
}): Promise < PatientTreatmentReport > {
return this.fetchPatientTreatmentCountsUsingPOSTWithHttpInfo(parameters).then(function(response: request.Response) {
return response.body;
});
};
fetchSampleTreatmentCountsUsingPOSTURL(parameters: {
'tier' ? : "Agent" | "AgentClass" | "AgentTarget",
'studyViewFilter' ? : StudyViewFilter,
$queryParameters ? : any
}): string {
let queryParameters: any = {};
let path = '/api/column-store/treatments/sample-counts/fetch';
if (parameters['tier'] !== undefined) {
queryParameters['tier'] = parameters['tier'];
}

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('&')) : '');
};

/**
*
* @method
* @name CBioPortalAPIInternal#fetchSampleTreatmentCountsUsingPOST
* @param {string} tier - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change.
* @param {} studyViewFilter - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change.
*/
fetchSampleTreatmentCountsUsingPOSTWithHttpInfo(parameters: {
'tier' ? : "Agent" | "AgentClass" | "AgentTarget",
'studyViewFilter' ? : StudyViewFilter,
$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/column-store/treatments/sample-counts/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['tier'] !== undefined) {
queryParameters['tier'] = parameters['tier'];
}

if (parameters['studyViewFilter'] !== undefined) {
body = parameters['studyViewFilter'];
}

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);

});
};

/**
*
* @method
* @name CBioPortalAPIInternal#fetchSampleTreatmentCountsUsingPOST
* @param {string} tier - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change.
* @param {} studyViewFilter - A web service for supplying JSON formatted data to cBioPortal clients. Please note that this API is currently in beta and subject to change.
*/
fetchSampleTreatmentCountsUsingPOST(parameters: {
'tier' ? : "Agent" | "AgentClass" | "AgentTarget",
'studyViewFilter' ? : StudyViewFilter,
$queryParameters ? : any,
$domain ? : string
}): Promise < SampleTreatmentReport > {
return this.fetchSampleTreatmentCountsUsingPOSTWithHttpInfo(parameters).then(function(response: request.Response) {
return response.body;
});
};
fetchCosmicCountsUsingPOSTURL(parameters: {
'keywords': Array < string > ,
$queryParameters ? : any
Expand Down
Loading

0 comments on commit 22501dd

Please sign in to comment.