@@ -140,6 +140,18 @@ type Comment {
140
140
text: string
141
141
reactions: Reaction[]?
142
142
}
143
+
144
+ type Direction enum {
145
+ Up
146
+ Down
147
+ Left
148
+ Right
149
+ }
150
+
151
+ type Car {
152
+ brand: string
153
+ direction: Direction?
154
+ }
143
155
```
144
156
145
157
## Functions
@@ -186,4 +198,29 @@ fn getPosts(userAgent: string, lang: string, token: base64): User
186
198
// Sending arguments on path and querystring.
187
199
@rest GET /chats/{chatId}/messages?{since}&{until} [header x-token: {token}]
188
200
fn getMessages(token: base64, chatId: uuid, since: datetime?, until: datetime?): Message[]
201
+
202
+ // Provi
8000
de the @description to be displayed in the swagger
203
+ @description Get the list of company users
204
+ fn getUsers(companyId: uuid, since: datetime?, until: datetime?, token: base64): User?
205
+
206
+ // Provide the @args to be displayed a text for argument in the swagger
207
+ @arg companyId ID from company
208
+ fn getUsers(companyId: uuid, since: datetime?, until: datetime?, token: base64): User?
209
+
210
+ // You can use both at the same time
211
+ @description Get the list of company users
212
+ @arg companyId ID from company
213
+ @arg since provide a date for the start of the search
214
+ @arg until provide a date for the end of the search
215
+ @arg token provide a token in base64
216
+ fn getUsers(companyId: uuid, since: datetime?, until: datetime?, token: base64): User?
217
+
218
+ // Sending enum like as an argument
219
+ type TypeTransfer enum {
220
+ internal
221
+ external
222
+ }
223
+
224
+ @rest GET /transfer/account?{type}&{account}
225
+ fn getTransfersTypeFromAccount(type: TypeTransfer, account: string)
189
226
```
0 commit comments