Skip to content

Commit 5db894f

Browse files
committed
add tags endpoint for neurosynth compose
1 parent ec14bcf commit 5db894f

1 file changed

Lines changed: 144 additions & 0 deletions

File tree

neurosynth-compose-openapi.yml

Lines changed: 144 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1015,6 +1015,76 @@ paths:
10151015
security:
10161016
- JSON-Web-Token: []
10171017
x-internal: true
1018+
/tags:
1019+
get:
1020+
summary: Get a list of Tags
1021+
tags:
1022+
- tags
1023+
- get
1024+
- compose
1025+
responses:
1026+
'200':
1027+
description: OK
1028+
content:
1029+
application/json:
1030+
schema:
1031+
$ref: '#/components/schemas/tag-list'
1032+
security:
1033+
- JSON-Web-Token: []
1034+
- {}
1035+
parameters:
1036+
- $ref: '#/components/parameters/ids'
1037+
- $ref: '#/components/parameters/page'
1038+
- $ref: '#/components/parameters/page_size'
1039+
- $ref: '#/components/parameters/name'
1040+
- $ref: '#/components/parameters/search'
1041+
- $ref: '#/components/parameters/filter'
1042+
- $ref: '#/components/parameters/description'
1043+
- $ref: '#/components/parameters/group'
1044+
- $ref: '#/components/parameters/official'
1045+
- $ref: '#/components/parameters/sort'
1046+
- $ref: '#/components/parameters/desc'
1047+
- $ref: '#/components/parameters/user_id'
1048+
post:
1049+
summary: Create a new Tag
1050+
responses:
1051+
'200':
1052+
description: OK
1053+
content:
1054+
application/json:
1055+
schema:
1056+
$ref: '#/components/schemas/tag-return'
1057+
requestBody:
1058+
content:
1059+
application/json:
1060+
schema:
1061+
$ref: '#/components/schemas/tag'
1062+
security:
1063+
- JSON-Web-Token: []
1064+
tags:
1065+
- tags
1066+
- post
1067+
- compose
1068+
'/tags/{id}':
1069+
parameters:
1070+
- schema:
1071+
type: string
1072+
name: id
1073+
in: path
1074+
required: true
1075+
get:
1076+
summary: Get information about a Tag
1077+
tags:
1078+
- tags
1079+
- get
1080+
- compose
1081+
responses:
1082+
'200':
1083+
description: OK
1084+
content:
1085+
application/json:
1086+
schema:
1087+
$ref: '#/components/schemas/tag-return'
10181088
/studyset-references:
10191089
get:
10201090
summary: Your GET endpoint
@@ -1175,6 +1245,17 @@ components:
11751245
type: string
11761246
description: Long form description of the meta-analysis.
11771247
nullable: true
1248+
tags:
1249+
description: Tags associated with this meta-analysis (use tag names or tag IDs).
1250+
oneOf:
1251+
- minItems: 1
1252+
items:
1253+
$ref: '#/components/schemas/tag'
1254+
type: array
1255+
- items:
1256+
type: string
1257+
description: Tag name or tag ID
1258+
type: array
11781259
cached_studyset_id:
11791260
type: string
11801261
description: The id of the studyset on neurosynth-compose (as opposed to the id of the studyset on neurostore). Multiple snapshots of the studyset can be stored on neurosynth-compose so knowing which snapshot is being referenced is necessary.
@@ -1732,6 +1813,47 @@ components:
17321813
$ref: '#/components/schemas/metadata'
17331814
x-tags:
17341815
- neurovault
1816+
tag:
1817+
title: tag
1818+
type: object
1819+
x-tags:
1820+
- tags
1821+
description: A user-scoped or global label that can be attached to multiple resources. Tag groups are free-form categories (e.g., "visibility", "topic") used to segment tags across different resource types.
1822+
required:
1823+
- name
1824+
properties:
1825+
name:
1826+
type: string
1827+
description: Case-insensitive unique name within the tag scope (user or global).
1828+
group:
1829+
type: string
1830+
nullable: true
1831+
description: Optional grouping key to categorize tags (case-insensitive exact match in queries).
1832+
description:
1833+
type: string
1834+
nullable: true
1835+
official:
1836+
type: boolean
1837+
nullable: true
1838+
tag-return:
1839+
title: tag-return
1840+
allOf:
1841+
- $ref: '#/components/schemas/tag'
1842+
- $ref: '#/components/schemas/read-only'
1843+
x-tags:
1844+
- tags
1845+
tag-list:
1846+
title: tag-list
1847+
type: object
1848+
x-tags:
1849+
- tags
1850+
properties:
1851+
results:
1852+
type: array
1853+
items:
1854+
$ref: '#/components/schemas/tag-return'
1855+
metadata:
1856+
$ref: '#/components/schemas/metadata'
17351857
project:
17361858
title: project
17371859
x-tags:
@@ -1988,6 +2110,27 @@ components:
19882110
in: header
19892111
name: Compose-Upload-Key
19902112
parameters:
2113+
group:
2114+
name: group
2115+
in: query
2116+
required: false
2117+
schema:
2118+
type: string
2119+
description: filter tags by group
2120+
filter:
2121+
name: filter
2122+
in: query
2123+
required: false
2124+
schema:
2125+
type: string
2126+
description: alias for search when filtering tags
2127+
official:
2128+
name: official
2129+
in: query
2130+
required: false
2131+
schema:
2132+
type: boolean
2133+
description: filter tags by official flag
19912134
desc:
19922135
name: desc
19932136
in: query
@@ -2117,4 +2260,5 @@ tags:
21172260
- name: put
21182261
- name: specifications
21192262
- name: studysets
2263+
- name: tags
21202264
- name: users

0 commit comments

Comments
 (0)