Bug 29453: Add endpoints for fetching patron credits & debits
[koha.git] / api / v1 / swagger / definitions / account_line.yaml
1 ---
2 type: object
3 properties:
4   account_line_id:
5     type:
6       - integer
7       - "null"
8     readOnly: true
9     description: Internal account line identifier
10   amount:
11     type: number
12     description: Account line amount
13   amount_outstanding:
14     type: number
15     readOnly: true
16     description: Outstanding amount
17   cash_register_id:
18     type:
19       - integer
20       - "null"
21     description: Internal identifier for the cash register used for the payment (if any)
22   checkout_id:
23     type:
24       - integer
25       - "null"
26     description: Internal identifier for the checkout the account line is related to
27   credit_number:
28     type:
29       - string
30       - "null"
31     readOnly: true
32     description: Internally generated identifier for credits
33   credit_type:
34     type:
35       - string
36       - "null"
37     description: Account line credit type
38   date:
39     type: string
40     format: date-time
41     readOnly: true
42     description: Date the account line was created
43   debit_type:
44     type:
45       - string
46       - "null"
47     description: Account line debit type
48   description:
49     type:
50       - string
51       - "null"
52     readOnly: true
53     description: Account line description
54   interface:
55     type:
56       - string
57       - "null"
58     readOnly: true
59     description: 'Interface in which the account line was generated (values can be: api, cron, commandline, intranet, opac and sip)'
60   internal_note:
61     type:
62       - string
63       - "null"
64     description: Internal note
65   item_id:
66     type:
67       - integer
68       - "null"
69     description: Internal identifier for the item the account line is related to
70   library_id:
71     type:
72       - string
73       - "null"
74     description: Internal identifier for the library in which the transaction took place
75   patron_id:
76     type: integer
77     readOnly: true
78     description: Internal identifier for the patron the account line belongs to
79   payment_type:
80     type:
81       - string
82       - "null"
83     description: Payment type
84   payout_type:
85     type:
86       - string
87       - "null"
88     description: Payout type
89   status:
90     type:
91       - string
92       - "null"
93     readOnly: true
94     description: The credit/debit status
95   timestamp:
96     type: string
97     format: date-time
98     readOnly: true
99     description: Timestamp for the latest line update
100   user_id:
101     type:
102       - integer
103       - "null"
104     description: Internal patron identifier for the staff member that introduced the account line
105 required:
106   - amount
107 additionalProperties: false