Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
paulineribeyre committed Nov 11, 2024
1 parent 1374336 commit f1a4853
Show file tree
Hide file tree
Showing 3 changed files with 77 additions and 8 deletions.
76 changes: 72 additions & 4 deletions docs/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ paths:
summary: Get Version
tags:
- System
/ga4gh-tes/v1/service-info:
/ga4gh/tes/v1/service-info:
get:
operationId: service_info_ga4gh_tes_v1_service_info_get
responses:
Expand All @@ -93,7 +93,7 @@ paths:
summary: Service Info
tags:
- GA4GH TES
/ga4gh-tes/v1/tasks:
/ga4gh/tes/v1/tasks:
get:
operationId: list_tasks_ga4gh_tes_v1_tasks_get
responses:
Expand All @@ -120,7 +120,7 @@ paths:
summary: Create Task
tags:
- GA4GH TES
/ga4gh-tes/v1/tasks/{task_id}:
/ga4gh/tes/v1/tasks/{task_id}:
get:
operationId: get_task_ga4gh_tes_v1_tasks__task_id__get
parameters:
Expand All @@ -147,7 +147,7 @@ paths:
summary: Get Task
tags:
- GA4GH TES
/ga4gh-tes/v1/tasks/{task_id}:cancel:
/ga4gh/tes/v1/tasks/{task_id}:cancel:
post:
operationId: cancel_task_ga4gh_tes_v1_tasks__task_id__cancel_post
parameters:
Expand All @@ -174,3 +174,71 @@ paths:
summary: Cancel Task
tags:
- GA4GH TES
/storage/credentials:
get:
operationId: get_user_keys_storage_credentials_get
responses:
'200':
content:
application/json:
schema: {}
description: Successful Response
security:
- HTTPBearer: []
summary: Get User Keys
tags:
- Storage
post:
operationId: generate_user_key_storage_credentials_post
responses:
'200':
content:
application/json:
schema: {}
description: Successful Response
security:
- HTTPBearer: []
summary: Generate User Key
tags:
- Storage
/storage/credentials/{key_id}:
delete:
operationId: delete_user_key_storage_credentials__key_id__delete
parameters:
- in: path
name: key_id
required: true
schema:
title: Key Id
type: string
responses:
'200':
content:
application/json:
schema: {}
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
security:
- HTTPBearer: []
summary: Delete User Key
tags:
- Storage
/storage/info:
get:
operationId: get_storage_info_storage_info_get
responses:
'200':
content:
application/json:
schema: {}
description: Successful Response
security:
- HTTPBearer: []
summary: Get Storage Info
tags:
- Storage
3 changes: 2 additions & 1 deletion gen3workflow/aws_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ def get_iam_user_name(user_id):
"""
Generate a valid IAM user name for the specified user.
IAM user names can contain up to 64 characters. They can only contain alphanumeric characters
and/or the following: +=,.@_-
and/or the following: +=,.@_- (not enforced here since user IDs and hostname should not contain
special characters).
Args:
user_id (str): The user's unique Gen3 ID
Expand Down
6 changes: 3 additions & 3 deletions tests/test_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ async def test_create_and_list_user_keys(client, access_token_patcher):
},
]

# delete the 2st key
# delete the 1st key
res = await client.delete(
f"/storage/credentials/{keys[0]['aws_key_id']}",
headers={"Authorization": f"bearer 123"},
Expand Down Expand Up @@ -102,7 +102,7 @@ async def test_list_user_keys_status(client, access_token_patcher):
assert "aws_key_id" in key_data and "aws_key_secret" in key_data
keys.append(key_data)

# list the user's key; the 1st key should show as expired
# list the user's keys; the 1st key should show as expired
res = await client.get(
"/storage/credentials", headers={"Authorization": f"bearer 123"}
)
Expand All @@ -121,7 +121,7 @@ async def test_list_user_keys_status(client, access_token_patcher):
)
access_key.deactivate()

# list the user's key; both keys should now show as expired
# list the user's keys; both keys should now show as expired
res = await client.get(
"/storage/credentials", headers={"Authorization": f"bearer 123"}
)
Expand Down

0 comments on commit f1a4853

Please sign in to comment.