feat: Update swagger to openapi 3.0.4, update request payloads with examples (#11374)

This commit is contained in:
Daniel Jimenez
2025-05-22 19:26:44 +12:00
committed by GitHub
parent 8697a30dc5
commit 4b417ce9e7
189 changed files with 10098 additions and 5847 deletions

View File

@@ -5,37 +5,33 @@ summary: Create an Account User
description: Create an Account User
security:
- platformAppApiKey: []
parameters:
- name: data
in: body
required: true
schema:
type: object
required:
- user_id
- role
properties:
user_id:
type: integer
description: The ID of the user
role:
type: string
description: whether user is an administrator or agent
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/account_user_create_update_payload'
responses:
200:
'200':
description: Success
schema:
properties:
account_id:
type: integer
description: The ID of the user
user_id:
type: integer
description: The ID of the user
role:
type: string
description: whether user is an administrator or agent
401:
content:
application/json:
schema:
type: object
properties:
account_id:
type: integer
description: The ID of the account
user_id:
type: integer
description: The ID of the user
role:
type: string
description: whether user is an administrator or agent
'401':
description: Unauthorized
content:
application/json:
schema:
$ref: '#/components/schemas/bad_request_error'

View File

@@ -5,23 +5,18 @@ summary: Delete an Account User
description: Delete an Account User
security:
- platformAppApiKey: []
parameters:
- name: data
in: body
required: true
schema:
type: object
required:
- user_id
properties:
user_id:
type: integer
description: The ID of the user
responses:
200:
'200':
description: Success
401:
'401':
description: Unauthorized
404:
content:
application/json:
schema:
$ref: '#/components/schemas/bad_request_error'
'404':
description: The account does not exist
content:
application/json:
schema:
$ref: '#/components/schemas/bad_request_error'

View File

@@ -6,23 +6,15 @@ description: List all account users
security:
- platformAppApiKey: []
responses:
200:
'200':
description: Success
schema:
type: array
description: 'Array of account users'
items:
type: object
properties:
account_id:
type: integer
description: The ID of the user
user_id:
type: integer
description: The ID of the user
role:
type: string
description: whether user is an administrator or agent
401:
content:
application/json:
schema:
$ref: '#/components/schemas/account_user'
'401':
description: Unauthorized
content:
application/json:
schema:
$ref: '#/components/schemas/bad_request_error'