Skip to content

Commit 667e8b1

Browse files
committed
add table object
1 parent ecc1d75 commit 667e8b1

File tree

1 file changed

+185
-1
lines changed

1 file changed

+185
-1
lines changed

neurostore-openapi.yml

Lines changed: 185 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -663,8 +663,13 @@ paths:
663663
- $ref: '#/components/parameters/desc'
664664
- $ref: '#/components/parameters/page_size'
665665
- $ref: '#/components/parameters/paginate'
666+
- name: study
667+
in: query
668+
required: false
669+
description: Filter tables by study id
670+
schema:
671+
type: string
666672
- $ref: '#/components/parameters/name'
667-
- $ref: '#/components/parameters/description'
668673
- $ref: '#/components/parameters/nested'
669674
parameters: []
670675
post:
@@ -745,6 +750,109 @@ paths:
745750
tags:
746751
- analyses
747752
- store
753+
/tables/:
754+
get:
755+
summary: GET list of tables
756+
tags:
757+
- tables
758+
- store
759+
responses:
760+
'200':
761+
description: OK
762+
content:
763+
application/json:
764+
schema:
765+
$ref: '#/components/schemas/table-list'
766+
description: List all tables across studies.
767+
parameters:
768+
- $ref: '#/components/parameters/search'
769+
- $ref: '#/components/parameters/sort'
770+
- $ref: '#/components/parameters/page'
771+
- $ref: '#/components/parameters/desc'
772+
- $ref: '#/components/parameters/page_size'
773+
- $ref: '#/components/parameters/paginate'
774+
- $ref: '#/components/parameters/name'
775+
- $ref: '#/components/parameters/description'
776+
- $ref: '#/components/parameters/nested'
777+
post:
778+
summary: POST/create a table
779+
responses:
780+
'200':
781+
description: OK
782+
content:
783+
application/json:
784+
schema:
785+
$ref: '#/components/schemas/table-return'
786+
requestBody:
787+
content:
788+
application/json:
789+
schema:
790+
$ref: '#/components/schemas/table-request'
791+
tags:
792+
- tables
793+
- store
794+
description: create a table
795+
parameters: []
796+
security:
797+
- JSON-Web-Token: []
798+
'/tables/{id}':
799+
parameters:
800+
- schema:
801+
type: string
802+
name: id
803+
in: path
804+
required: true
805+
get:
806+
summary: GET a table
807+
tags:
808+
- tables
809+
- store
810+
responses:
811+
'200':
812+
description: OK
813+
content:
814+
application/json:
815+
schema:
816+
$ref: '#/components/schemas/table-return'
817+
'404':
818+
$ref: '#/components/responses/404'
819+
description: Information about a specific table.
820+
parameters:
821+
- $ref: '#/components/parameters/nested'
822+
put:
823+
summary: PUT/update a table
824+
responses:
825+
'200':
826+
description: OK
827+
content:
828+
application/json:
829+
schema:
830+
$ref: '#/components/schemas/table-return'
831+
'422':
832+
$ref: '#/components/responses/422'
833+
requestBody:
834+
content:
835+
application/json:
836+
schema:
837+
$ref: '#/components/schemas/table-request'
838+
tags:
839+
- tables
840+
- store
841+
description: update a table
842+
parameters: []
843+
security:
844+
- JSON-Web-Token: []
845+
delete:
846+
summary: DELETE a table
847+
responses:
848+
'200':
849+
description: OK
850+
description: delete a table
851+
security:
852+
- JSON-Web-Token: []
853+
tags:
854+
- tables
855+
- store
748856
/points/:
749857
get:
750858
summary: Get Points
@@ -1841,6 +1949,10 @@ components:
18411949
- items:
18421950
type: string
18431951
type: array
1952+
tables:
1953+
type: array
1954+
items:
1955+
type: string
18441956
study-request-relationships:
18451957
title: study-relationships
18461958
x-tags:
@@ -1875,6 +1987,9 @@ components:
18751987
properties:
18761988
study:
18771989
type: string
1990+
table_id:
1991+
type: string
1992+
nullable: true
18781993
entities:
18791994
type: array
18801995
x-stoplight:
@@ -2170,6 +2285,75 @@ components:
21702285
$ref: '#/components/schemas/metadata'
21712286
x-tags:
21722287
- condition
2288+
table-return:
2289+
title: table-return
2290+
allOf:
2291+
- $ref: '#/components/schemas/resource-attributes'
2292+
- $ref: '#/components/schemas/table-common'
2293+
- $ref: '#/components/schemas/table-return-relationships'
2294+
x-tags:
2295+
- table
2296+
table-request:
2297+
title: table-request
2298+
allOf:
2299+
- $ref: '#/components/schemas/writeable-resource-attributes'
2300+
- $ref: '#/components/schemas/table-common'
2301+
- $ref: '#/components/schemas/table-request-relationships'
2302+
x-tags:
2303+
- table
2304+
table-common:
2305+
title: table-common
2306+
type: object
2307+
properties:
2308+
t_id:
2309+
type: string
2310+
nullable: true
2311+
name:
2312+
type: string
2313+
nullable: true
2314+
footer:
2315+
type: string
2316+
nullable: true
2317+
caption:
2318+
type: string
2319+
nullable: true
2320+
table-return-relationships:
2321+
title: table-relationships
2322+
x-tags:
2323+
- table
2324+
type: object
2325+
properties:
2326+
study:
2327+
type: string
2328+
analyses:
2329+
oneOf:
2330+
- items:
2331+
$ref: '#/components/schemas/analysis-return'
2332+
minItems: 1
2333+
type: array
2334+
- items:
2335+
type: string
2336+
type: array
2337+
table-request-relationships:
2338+
title: table-relationships
2339+
x-tags:
2340+
- table
2341+
type: object
2342+
properties:
2343+
study:
2344+
type: string
2345+
table-list:
2346+
title: table-list
2347+
type: object
2348+
properties:
2349+
results:
2350+
type: array
2351+
items:
2352+
$ref: '#/components/schemas/table-return'
2353+
metadata:
2354+
$ref: '#/components/schemas/metadata'
2355+
x-tags:
2356+
- table
21732357
annotation-return:
21742358
title: annotation-return
21752359
oneOf:

0 commit comments

Comments
 (0)