-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathTicket_Allocation.swagger.yaml
More file actions
135 lines (135 loc) · 4.24 KB
/
Ticket_Allocation.swagger.yaml
File metadata and controls
135 lines (135 loc) · 4.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
openapi: 3.0.3
info:
title: Ticket Allocation
version: 1.0.0
contact: {}
servers:
- url: localhost
paths:
/ticket_options/{ticketOptionID}:
get:
summary: Get ticket option
description: Get Ticket Option by provided Ticket Option ID
operationId: getTicketOption
responses:
'200':
description: ''
parameters:
- name: ticketOptionID
in: path
required: true
schema:
type: string
/ticket_options:
post:
summary: Create ticket option
description: Create Ticket Option with given attributes
operationId: createTicketOption
requestBody:
content:
application/json:
schema:
type: object
properties:
data:
type: object
properties:
attributes:
type: object
properties:
allocation:
type: number
example: 100
description:
type: string
example: ticket option description
name:
type: string
example: Test ticket option
type:
type: string
example: ticket_options
examples:
Create ticket option:
value:
data:
attributes:
allocation: 100
description: ticket opion description
name: Test ticket option
type: ticket_options
responses:
'200':
description: ''
/purchases:
post:
summary: Create Purchase
description: >-
Create Purchase with quantity and associated User / Ticket Option
relationship
operationId: createPurchase
requestBody:
content:
application/json:
schema:
type: object
properties:
data:
type: object
properties:
attributes:
type: object
properties:
quantity:
type: number
example: 1
relationships:
type: object
properties:
ticket_option:
type: object
properties:
data:
type: object
properties:
id:
type: string
example: '{{ticketOptionID}}'
type:
type: string
example: ticket_options
user:
type: object
properties:
data:
type: object
properties:
id:
type: string
example: d6abe829-c28c-44ec-bee6-3183f2c53fef
type:
type: string
example: users
type:
type: string
example: purchases
examples:
Create Purchase:
value:
data:
attributes:
quantity: 1
relationships:
ticket_option:
data:
id: '{{ticketOptionID}}'
type: ticket_options
user:
data:
id: d6abe829-c28c-44ec-bee6-3183f2c53fef
type: users
type: purchases
responses:
'200':
description: ''
tags: []