feat(api): add pricing to training
This commit is contained in:
parent
f7572c5007
commit
063ae710e6
1 changed files with 35 additions and 1 deletions
|
|
@ -1,7 +1,7 @@
|
|||
openapi: "3.0.3"
|
||||
info:
|
||||
title: "Backoffice API"
|
||||
version: "0.1.0"
|
||||
version: "0.2.0"
|
||||
license:
|
||||
name: Proprietary
|
||||
contact:
|
||||
|
|
@ -171,10 +171,15 @@ components:
|
|||
minimum: 1
|
||||
maximum: 5
|
||||
default: 1
|
||||
pricing:
|
||||
type: array
|
||||
items:
|
||||
$ref: "#/components/schemas/TrainingPrice"
|
||||
required:
|
||||
- title
|
||||
- description
|
||||
- days
|
||||
- pricing
|
||||
Training:
|
||||
allOf:
|
||||
- $ref: "#/components/schemas/NewTraining"
|
||||
|
|
@ -191,6 +196,35 @@ components:
|
|||
- slug
|
||||
- published
|
||||
- retired
|
||||
TrainingPrice:
|
||||
allOf:
|
||||
- $ref: "#/components/schemas/Price"
|
||||
- type: object
|
||||
properties:
|
||||
type:
|
||||
type: string
|
||||
enum:
|
||||
- OPEN
|
||||
- CORPORATE
|
||||
required:
|
||||
- type
|
||||
Price:
|
||||
type: object
|
||||
properties:
|
||||
currency:
|
||||
type: string
|
||||
enum:
|
||||
- CZK
|
||||
- EUR
|
||||
- USD
|
||||
x-go-type: currency.Currency
|
||||
x-go-type-package:
|
||||
path: gitlab.mareshq.com/hq/backoffice/backoffice-api/internal/currency
|
||||
amount:
|
||||
type: string
|
||||
required:
|
||||
- currency
|
||||
- amount
|
||||
ProblemDetails:
|
||||
type: object
|
||||
description: >
|
||||
|
|
|
|||
Reference in a new issue