-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathledgers.raml
More file actions
85 lines (79 loc) · 2.78 KB
/
ledgers.raml
File metadata and controls
85 lines (79 loc) · 2.78 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
#%RAML 1.0
title: Finance ledger
version: v1.1
protocols: [ HTTP, HTTPS ]
baseUri: https://github.com/folio-org/mod-finance
documentation:
- title: Ledger API
content: This documents the API calls that can be made to manage ledgers
types:
ledger: !include acq-models/mod-finance/schemas/ledger.json
fiscal_year: !include acq-models/mod-finance/schemas/fiscal_year.json
ledgersCollection: !include acq-models/mod-finance/schemas/ledger_collection.json
errors: !include raml-util/schemas/errors.schema
UUID:
type: string
pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$
traits:
validate: !include raml-util/traits/validation.raml
pageable: !include raml-util/traits/pageable.raml
searchable: !include raml-util/traits/searchable.raml
resourceTypes:
collection: !include raml-util/rtypes/collection-with-json-response.raml
collection-item: !include raml-util/rtypes/item-collection-with-json-response.raml
item-collection-get: !include raml-util/rtypes/item-collection-get-with-json-response.raml
/finance/ledgers:
displayName: Finance ledger
description: Finance ledger APIs
type:
collection:
schemaCollection: ledgersCollection
schemaItem: ledger
exampleCollection: !include acq-models/mod-finance/examples/ledger_collection.sample
exampleItem: !include acq-models/mod-finance/examples/ledger.sample
post:
is: [validate]
get:
is: [
pageable,
searchable: {description: "with valid searchable fields: for example code", example: "[\"code\", \"MEDGRANT\", \"=\"]"}
]
queryParameters:
fiscalYear:
description: Fiscal Year Id
type: UUID
required: false
example: "3defdcde-3002-41d3-a31c-1fb88288f872"
default: null
/{id}:
uriParameters:
id:
description: The UUID of a ledger
type: UUID
displayName: Ledger
description: Get, Delete or Update a specific ledger
type:
collection-item:
schema: ledger
exampleItem: !include acq-models/mod-finance/examples/ledger.sample
put:
is: [validate]
get:
queryParameters:
fiscalYear:
description: The UUID of a fiscal year
type: UUID
/current-fiscal-year:
displayName: Current fiscal year
description: Get current fiscal year for a specific ledger
type:
item-collection-get:
schema: fiscal_year
exampleItem: !include acq-models/mod-finance/examples/fiscal_year.sample
/planned-fiscal-year:
displayName: Planned fiscal year
description: Get planned fiscal year for a specific ledger
type:
item-collection-get:
schema: fiscal_year
exampleItem: !include acq-models/mod-finance/examples/fiscal_year.sample