Skip to content

Commit

Permalink
feat: Docs for POST admin/corporate_cards/delete
Browse files Browse the repository at this point in the history
  • Loading branch information
RoshanMhatre committed Oct 7, 2024
1 parent 8c242fb commit 57dbcbb
Show file tree
Hide file tree
Showing 4 changed files with 56 additions and 2 deletions.
2 changes: 2 additions & 0 deletions src/admin/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,8 @@ paths:
$ref: paths/admin@corporate_cards@unassign.yaml
/admin/corporate_cards/reassign:
$ref: paths/admin@corporate_cards@reassign.yaml
/admin/corporate_cards/delete:
$ref: paths/admin@corporate_cards@delete.yaml

/admin/corporate_card_transactions:
$ref: paths/admin@corporate_card_transactions.yaml
Expand Down
2 changes: 1 addition & 1 deletion src/admin/paths/admin@corporate_card_transactions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ get:
$ref: '../../components/schemas/401.yaml'
post:
tags:
- Corporate Cards
- Corporate Card Transactions
summary: Create or update corporate card transaction
description: |
Create or update an corporate card transactions.
Expand Down
53 changes: 53 additions & 0 deletions src/admin/paths/admin@corporate_cards@delete.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
post:
tags:
- Corporate Cards
summary: Delete corporate card
description: |
Delete a corporate card and all its associated transactions
operationId: corporate_cards_delete
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
data:
$ref: ../../components/schemas/corporate_card.yaml#/corporate_card_id_in
required:
- data
additionalProperties: False
responses:
'200':
description: OK
content:
application/json:
schema:
type: object
properties:
data:
$ref: '../../components/schemas/corporate_card.yaml#/corporate_card_out'
'400':
description: Bad request
content:
application/json:
schema:
$ref: '../../components/schemas/400.yaml'
'401':
description: Unauthorized request
content:
application/json:
schema:
$ref: '../../components/schemas/401.yaml'
'403':
description: Forbidden
content:
application/json:
schema:
$ref: '../../components/schemas/403.yaml'
'404':
description: Not Found
content:
application/json:
schema:
$ref: '../../components/schemas/404.yaml'
1 change: 0 additions & 1 deletion src/admin/paths/admin@corporate_cards@reassign.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ post:
required:
- data
additionalProperties: False

responses:
'200':
description: OK
Expand Down

0 comments on commit 57dbcbb

Please sign in to comment.