Skip to content

Commit

Permalink
update for security.
Browse files Browse the repository at this point in the history
  • Loading branch information
vsmalladi committed Oct 28, 2024
1 parent 7e0f90c commit 15c3088
Showing 1 changed file with 31 additions and 2 deletions.
33 changes: 31 additions & 2 deletions openapi/task_execution_service.openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ info:
license:
name: Apache 2.0
url: 'https://raw.githubusercontent.com/ga4gh/task-execution-schemas/develop/LICENSE'
# This API has no security by default, please see documentation for authentication
security: []
description: >
## Executive Summary
Expand Down Expand Up @@ -65,6 +63,10 @@ info:
If TES API implementation is to be used by another website or domain it must implement Cross Origin Resource Sharing (CORS).
Please refer to https://w3id.org/ga4gh/product-approval-support/cors for more information about GA4GH’s recommendations and how to implement CORS.
security:
# Optionally, this section can be removed or adjusted by implementers based on their needs.
- BearerAuth: [] # Apply globally if authentication is required
- BasicAuth: [] # Alternatively, use Basic Authentication

servers:
- url: /ga4gh/tes/v1
Expand All @@ -87,6 +89,9 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/tesServiceInfo'
security:
- BearerAuth: [] # Endpoint secured with Bearer token
- BasicAuth: [] # Alternatively, secured with Basic Auth
/tasks:
get:
tags:
Expand Down Expand Up @@ -181,6 +186,11 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/tesListTasksResponse'

security:
- BearerAuth: [] # Endpoint secured with Bearer token
- BasicAuth: [] # Alternatively, secured with Basic Auth

post:
tags:
- TaskService
Expand All @@ -203,6 +213,9 @@ paths:
schema:
$ref: '#/components/schemas/tesCreateTaskResponse'
x-codegen-request-body-name: body
security:
- BearerAuth: [] # Endpoint secured with Bearer token
- BasicAuth: [] # Alternatively, secured with Basic Auth
/tasks/{id}:
get:
tags:
Expand All @@ -226,6 +239,9 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/tesTask'
security:
- BearerAuth: [] # Endpoint secured with Bearer token
- BasicAuth: [] # Alternatively, secured with Basic Auth
/tasks/{id}:cancel:
post:
tags:
Expand All @@ -247,7 +263,20 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/tesCancelTaskResponse'
security:
- BearerAuth: [] # Endpoint secured with Bearer token
- BasicAuth: [] # Alternatively, secured with Basic Auth
components:
securitySchemes:
BearerAuth:
type: http
scheme: bearer
bearerFormat: JWT # optional, can specify format if using JWT tokens

BasicAuth:
type: http
scheme: basic

parameters:
view:
name: view
Expand Down

0 comments on commit 15c3088

Please sign in to comment.