-
Notifications
You must be signed in to change notification settings - Fork 2
/
eventHandlers.raml
66 lines (60 loc) · 1.92 KB
/
eventHandlers.raml
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
#%RAML 1.0
title: Event handlers API
version: v1.1
protocols: [ HTTP, HTTPS ]
baseUri: http://localhost:9130
documentation:
- title: Event handlers API
content: <b>API for consuming events</b>
traits:
validate: !include raml-util/traits/validation.raml
types:
errors: !include raml-util/schemas/errors.schema
userSummary: !include userSummary.json
fee-fine-balance-changed-event: !include events/fee-fine-balance-changed.json
item-checked-out-event: !include events/item-checked-out.json
item-checked-in-event: !include events/item-checked-in.json
item-declared-lost-event: !include events/item-declared-lost.json
item-aged-to-lost-event: !include events/item-aged-to-lost.json
item-claimed-returned-event: !include events/item-claimed-returned.json
loan-due-date-changed-event: !include events/loan-due-date-changed.json
loan-closed-event: !include events/loan-closed.json
resourceTypes:
event-handler:
description: "Handler for <<resourcePathName | !upperunderscorecase>> events"
post:
is: [validate]
body:
application/json:
type: <<resourcePathName>>-event
responses:
204:
description: "Event received successfully"
400:
description: "Bad request"
body:
application/json:
type: errors
500:
description: "Internal server error"
body:
text/plain:
example: "Internal server error"
/automated-patron-blocks/handlers:
description: "Handlers for events the module is subscribed to"
/fee-fine-balance-changed:
type: event-handler
/item-checked-out:
type: event-handler
/item-checked-in:
type: event-handler
/item-declared-lost:
type: event-handler
/item-aged-to-lost:
type: event-handler
/item-claimed-returned:
type: event-handler
/loan-due-date-changed:
type: event-handler
/loan-closed:
type: event-handler