Skip to content

SmartAPI OpenAPI metadata update #17

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
75 changes: 75 additions & 0 deletions SmartAPI/smartapi_openapi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,81 @@ paths:
$ref: '#/components/schemas/PathsResponse'
tags:
- metakg
/metakg/parse:
get:
summary: Parse metadata from its URL.
parameters:
- name: url
in: query
required: true
schema:
type: string
maxLength: 1000
description: Metadata url for API document to be parsed. *Required*.
example: "https://raw.githubusercontent.com/NCATS-Tangerine/translator-api-registry/master/mygene.info/openapi_full.yml"
- name: api_details
in: query
required: false
schema:
type: boolean
description: >-
Optional, used to display API details in the response. If set to true, the response will include more information about the api. Default: false.
- name: bte
in: query
required: false
schema:
type: boolean
description: >-
Optional, used to display the BTE (BioThings Explorer) details in the response. If set to true, the response will include BTE information. Default: false.
responses:
200:
description: Successfully parsed metadata.
content:
application/json:
schema:
$ref: '#/components/schemas/MetakgResponse'
tags:
- metakg
post:
summary: Parse metadata from a given request body.
parameters:
- name: api_details
in: query
required: false
schema:
type: boolean
description: >-
Optional, used to display API details in the response. If set to true, the response will include more information about the api. Default: false.
- name: bte
in: query
required: false
schema:
type: boolean
description: >-
Optional, used to display the BTE (BioThings Explorer) details in the response. If set to true, the response will include BTE information. Default: false.
requestBody:
required: true
content:
application/json:
schema:
type: object
description: Parsed metadata JSON object in a list.
application/yaml:
schema:
type: object
description: Parsed metadata YAML object in a list.
responses:
200:
description: Successfully parsed metadata.
content:
application/json:
schema:
$ref: '#/components/schemas/MetakgResponse'
application/yaml:
schema:
$ref: '#/components/schemas/MetakgResponse'
tags:
- metakg
components:
schemas:
MetakgResponse:
Expand Down