http://github.com/org/folio/mod-feesfines
This documents the API calls that can be made to query and manage feefine of the system
Collection of feefineaction items.
Return a list of feefineactions
GET /feefineactions
A query expressed as a CQL string (see dev.folio.org/reference/glossary#cql) using valid searchable fields. The first example below shows the general form of a full CQL query, but those fields might not be relevant in this context.
with valid searchable fields
Example:
(username=="ab*" or personal.firstName=="ab*" or personal.lastName=="ab*") and active=="true" sortby personal.lastName personal.firstName barcode
active=true
Order by field: field A, field B
Order
How to calculate the totalRecords property. "exact" for the correct number, "estimated" for an estimation, "auto" to automatically select "exact" or "estimated", "none" for suppressing the totalRecords property. For details see https://github.com/folio-org/raml-module-builder#estimated-totalrecords
Example:
none
Skip over a number of elements by specifying an offset value for the query
Example:
0
Limit the number of elements returned in the response. Using limit=0 will return totalRecords with the exact value. For details about totalRecords see https://github.com/folio-org/raml-module-builder#estimated-totalrecords
Example:
10
Returns a list of feefineaction items
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Collection of feefineactions",
"type": "object",
"properties": {
"feefineactions": {
"description": "List of feefineaction items",
"type": "array",
"id": "feefineactionsData",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Fee/fine actions schema",
"description": "Transactions or activities associated with a user fee/fine account",
"properties": {
"dateAction": {
"description": "Date and time the transaction of the fine/fee was created",
"type": "string",
"format": "date-time"
},
"typeAction": {
"description": "Type of activity including the type of transaction",
"type": "string",
"x-fqm-values": [
{
"value": "Paid partially",
"label": "Paid partially"
},
{
"value": "Paid fully",
"label": "Paid fully"
},
{
"value": "Waived partially",
"label": "Waived partially"
},
{
"value": "Waived fully",
"label": "Waived fully"
},
{
"value": "Transferred partially",
"label": "Transferred partially"
},
{
"value": "Transferred fully",
"label": "Transferred fully"
},
{
"value": "Refunded partially",
"label": "Refunded partially"
},
{
"value": "Refunded fully",
"label": "Refunded fully"
},
{
"value": "Credited partially",
"label": "Credited partially"
},
{
"value": "Credited fully",
"label": "Credited fully"
},
{
"value": "Cancelled as error",
"label": "Cancelled as error"
}
]
},
"comments": {
"description": "Additional information entered as part of the activity or on this screen as a 'Staff info only' activity",
"type": "string"
},
"notify": {
"description": "A flag to determine if a patron should be notified or not",
"type": "boolean"
},
"amountAction": {
"description": "Amount of activity",
"javaType": "org.folio.rest.domain.MonetaryValue",
"type": "number"
},
"balance": {
"description": "Calculated amount of remaining balance based on original fee/fine and what has been paid/waived/transferred/refunded",
"javaType": "org.folio.rest.domain.MonetaryValue",
"type": "number"
},
"transactionInformation": {
"description": "Number or other transaction id related to payment",
"type": "string"
},
"createdAt": {
"description": "ID of the service point where the action was created",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"originalCreatedAt": {
"description": "Original invalid (non-UUID) value of 'createdAt' moved here when UUID-validation was enabled for 'createdAt'",
"type": "string"
},
"source": {
"description": "Person who processed activity (from login information)",
"type": "string"
},
"paymentMethod": {
"description": "Overall status of the action-setting",
"type": "string"
},
"accountId": {
"description": "ID of the accounts",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"userId": {
"description": "ID of the user",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"id": {
"description": "Fine/fee action id, UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
}
},
"additionalProperties": false,
"required": [
"accountId",
"userId"
]
}
},
"totalRecords": {
"type": "integer"
}
},
"required": [
"feefineactions",
"totalRecords"
]
}
Example:
{
"feefineactions":[
{
"dateAction":"2017-07-24T01:24:01Z",
"typeAction":"Payment-ckeck",
"amountAction": 200.00,
"balance":50.00,
"transactionInformation": "Department ENG-345",
"comments":"This a comment",
"notify": true,
"createdAt":"Main Library",
"source":"Doe,Jane",
"paymentMethod": "Check",
"accountId":"fc8a995f-f076-465e-b108-6b5d528d0d38",
"userId":"1ad737b0-d847-11e6-bf26-cec0c932ce01",
"id":"bcb9b1d9-b967-41c4-a476-a4c282527cea"
}
],
"totalRecords":1
}
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Media type: text/plain
Type: any
Example:
unable to list feefineactions -- malformed parameter 'query', syntax error at column 6
Not authorized to perform requested action
Media type: text/plain
Type: any
Example:
unable to list feefineactions -- unauthorized
Internal server error, e.g. due to misconfiguration
Media type: text/plain
Type: any
Example:
internal server error, contact administrator
Create a feefineaction
POST /feefineactions
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Fee/fine actions schema",
"description": "Transactions or activities associated with a user fee/fine account",
"type": "object",
"properties": {
"dateAction": {
"description": "Date and time the transaction of the fine/fee was created",
"type": "string",
"format": "date-time"
},
"typeAction": {
"description": "Type of activity including the type of transaction",
"type": "string",
"x-fqm-values": [
{
"value": "Paid partially",
"label": "Paid partially"
},
{
"value": "Paid fully",
"label": "Paid fully"
},
{
"value": "Waived partially",
"label": "Waived partially"
},
{
"value": "Waived fully",
"label": "Waived fully"
},
{
"value": "Transferred partially",
"label": "Transferred partially"
},
{
"value": "Transferred fully",
"label": "Transferred fully"
},
{
"value": "Refunded partially",
"label": "Refunded partially"
},
{
"value": "Refunded fully",
"label": "Refunded fully"
},
{
"value": "Credited partially",
"label": "Credited partially"
},
{
"value": "Credited fully",
"label": "Credited fully"
},
{
"value": "Cancelled as error",
"label": "Cancelled as error"
}
]
},
"comments": {
"description": "Additional information entered as part of the activity or on this screen as a 'Staff info only' activity",
"type": "string"
},
"notify": {
"description": "A flag to determine if a patron should be notified or not",
"type": "boolean"
},
"amountAction": {
"description": "Amount of activity",
"javaType": "org.folio.rest.domain.MonetaryValue",
"type": "number"
},
"balance": {
"description": "Calculated amount of remaining balance based on original fee/fine and what has been paid/waived/transferred/refunded",
"javaType": "org.folio.rest.domain.MonetaryValue",
"type": "number"
},
"transactionInformation": {
"description": "Number or other transaction id related to payment",
"type": "string"
},
"createdAt": {
"description": "ID of the service point where the action was created",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"originalCreatedAt": {
"description": "Original invalid (non-UUID) value of 'createdAt' moved here when UUID-validation was enabled for 'createdAt'",
"type": "string"
},
"source": {
"description": "Person who processed activity (from login information)",
"type": "string"
},
"paymentMethod": {
"description": "Overall status of the action-setting",
"type": "string"
},
"accountId": {
"description": "ID of the accounts",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"userId": {
"description": "ID of the user",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"id": {
"description": "Fine/fee action id, UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
}
},
"additionalProperties": false,
"required": [
"accountId",
"userId"
]
}
Example:
{
"dateAction": "2017-07-24T01:24:01Z",
"typeAction": "Payment-ckeck",
"amountAction": 200.00,
"balance": 50.00,
"transactionInformation": "Department ENG-345",
"comments": "This a comment",
"notify": true,
"createdAt": "Main Library",
"source": "Doe,Jane",
"paymentMethod": "Check",
"accountId": "fc8a995f-f076-465e-b108-6b5d528d0d38",
"userId": "1ad737b0-d847-11e6-bf26-cec0c932ce01",
"id": "bcb9b1d9-b967-41c4-a476-a4c282527cea"
}
Returns a newly created item, with server-controlled fields like 'id' populated
URI to the created feefineaction item
Media type: application/json
Type: any
Example:
{
"dateAction": "2017-07-24T01:24:01Z",
"typeAction": "Payment-ckeck",
"amountAction": 200.00,
"balance": 50.00,
"transactionInformation": "Department ENG-345",
"comments": "This a comment",
"notify": true,
"createdAt": "Main Library",
"source": "Doe,Jane",
"paymentMethod": "Check",
"accountId": "fc8a995f-f076-465e-b108-6b5d528d0d38",
"userId": "1ad737b0-d847-11e6-bf26-cec0c932ce01",
"id": "bcb9b1d9-b967-41c4-a476-a4c282527cea"
}
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Media type: text/plain
Type: any
Example:
"unable to add feefineaction -- malformed JSON at 13:3"
Not authorized to perform requested action
Media type: text/plain
Type: any
Example:
unable to create feefineactions -- unauthorized
Validation errors
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "errors.schema",
"description": "A set of errors",
"type": "object",
"properties": {
"errors": {
"description": "List of errors",
"id": "errors",
"type": "array",
"items": {
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "error.schema",
"description": "An error",
"properties": {
"message": {
"type": "string",
"description": "Error message text"
},
"type": {
"type": "string",
"description": "Error message type"
},
"code": {
"type": "string",
"description": "Error message code"
},
"parameters": {
"description": "Error message parameters",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "parameters.schema",
"type": "array",
"items": {
"type": "object",
"properties": {
"key": {
"type": "string"
},
"value": {
"type": "string"
}
}
}
}
},
"required": [
"message"
]
}
},
"total_records": {
"description": "Total number of errors",
"type": "integer"
}
}
}
Example:
{
"errors": [
{
"message": "may not be null",
"type": "1",
"code": "-1",
"parameters": [
{
"key": "moduleTo",
"value": "null"
}
]
}
]
}
Internal server error, e.g. due to misconfiguration
Media type: text/plain
Type: any
Example:
Internal server error, contact administrator
Get a single feefineaction
GET /feefineactions/{feefineactionId}
Returns item with a given ID
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Fee/fine actions schema",
"description": "Transactions or activities associated with a user fee/fine account",
"type": "object",
"properties": {
"dateAction": {
"description": "Date and time the transaction of the fine/fee was created",
"type": "string",
"format": "date-time"
},
"typeAction": {
"description": "Type of activity including the type of transaction",
"type": "string",
"x-fqm-values": [
{
"value": "Paid partially",
"label": "Paid partially"
},
{
"value": "Paid fully",
"label": "Paid fully"
},
{
"value": "Waived partially",
"label": "Waived partially"
},
{
"value": "Waived fully",
"label": "Waived fully"
},
{
"value": "Transferred partially",
"label": "Transferred partially"
},
{
"value": "Transferred fully",
"label": "Transferred fully"
},
{
"value": "Refunded partially",
"label": "Refunded partially"
},
{
"value": "Refunded fully",
"label": "Refunded fully"
},
{
"value": "Credited partially",
"label": "Credited partially"
},
{
"value": "Credited fully",
"label": "Credited fully"
},
{
"value": "Cancelled as error",
"label": "Cancelled as error"
}
]
},
"comments": {
"description": "Additional information entered as part of the activity or on this screen as a 'Staff info only' activity",
"type": "string"
},
"notify": {
"description": "A flag to determine if a patron should be notified or not",
"type": "boolean"
},
"amountAction": {
"description": "Amount of activity",
"javaType": "org.folio.rest.domain.MonetaryValue",
"type": "number"
},
"balance": {
"description": "Calculated amount of remaining balance based on original fee/fine and what has been paid/waived/transferred/refunded",
"javaType": "org.folio.rest.domain.MonetaryValue",
"type": "number"
},
"transactionInformation": {
"description": "Number or other transaction id related to payment",
"type": "string"
},
"createdAt": {
"description": "ID of the service point where the action was created",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"originalCreatedAt": {
"description": "Original invalid (non-UUID) value of 'createdAt' moved here when UUID-validation was enabled for 'createdAt'",
"type": "string"
},
"source": {
"description": "Person who processed activity (from login information)",
"type": "string"
},
"paymentMethod": {
"description": "Overall status of the action-setting",
"type": "string"
},
"accountId": {
"description": "ID of the accounts",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"userId": {
"description": "ID of the user",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"id": {
"description": "Fine/fee action id, UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
}
},
"additionalProperties": false,
"required": [
"accountId",
"userId"
]
}
Example:
{
"dateAction": "2017-07-24T01:24:01Z",
"typeAction": "Payment-ckeck",
"amountAction": 200.00,
"balance": 50.00,
"transactionInformation": "Department ENG-345",
"comments": "This a comment",
"notify": true,
"createdAt": "Main Library",
"source": "Doe,Jane",
"paymentMethod": "Check",
"accountId": "fc8a995f-f076-465e-b108-6b5d528d0d38",
"userId": "1ad737b0-d847-11e6-bf26-cec0c932ce01",
"id": "bcb9b1d9-b967-41c4-a476-a4c282527cea"
}
Item with a given ID not found
Media type: text/plain
Type: any
Example:
"feefineaction not found"
Internal server error, e.g. due to misconfiguration
Media type: text/plain
Type: any
Example:
internal server error, contact administrator
Delete feefineaction item with given {feefineactionId}
DELETE /feefineactions/{feefineactionId}
Item deleted successfully
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Media type: text/plain
Type: any
Example:
"unable to delete feefineaction -- constraint violation"
Item with a given ID not found
Media type: text/plain
Type: any
Example:
"feefineaction not found"
Internal server error, e.g. due to misconfiguration
Media type: text/plain
Type: any
Example:
Internal server error, contact administrator
Update feefineaction item with given {feefineactionId}
PUT /feefineactions/{feefineactionId}
Media type: application/json
Type: json
Content:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Fee/fine actions schema",
"description": "Transactions or activities associated with a user fee/fine account",
"type": "object",
"properties": {
"dateAction": {
"description": "Date and time the transaction of the fine/fee was created",
"type": "string",
"format": "date-time"
},
"typeAction": {
"description": "Type of activity including the type of transaction",
"type": "string",
"x-fqm-values": [
{
"value": "Paid partially",
"label": "Paid partially"
},
{
"value": "Paid fully",
"label": "Paid fully"
},
{
"value": "Waived partially",
"label": "Waived partially"
},
{
"value": "Waived fully",
"label": "Waived fully"
},
{
"value": "Transferred partially",
"label": "Transferred partially"
},
{
"value": "Transferred fully",
"label": "Transferred fully"
},
{
"value": "Refunded partially",
"label": "Refunded partially"
},
{
"value": "Refunded fully",
"label": "Refunded fully"
},
{
"value": "Credited partially",
"label": "Credited partially"
},
{
"value": "Credited fully",
"label": "Credited fully"
},
{
"value": "Cancelled as error",
"label": "Cancelled as error"
}
]
},
"comments": {
"description": "Additional information entered as part of the activity or on this screen as a 'Staff info only' activity",
"type": "string"
},
"notify": {
"description": "A flag to determine if a patron should be notified or not",
"type": "boolean"
},
"amountAction": {
"description": "Amount of activity",
"javaType": "org.folio.rest.domain.MonetaryValue",
"type": "number"
},
"balance": {
"description": "Calculated amount of remaining balance based on original fee/fine and what has been paid/waived/transferred/refunded",
"javaType": "org.folio.rest.domain.MonetaryValue",
"type": "number"
},
"transactionInformation": {
"description": "Number or other transaction id related to payment",
"type": "string"
},
"createdAt": {
"description": "ID of the service point where the action was created",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"originalCreatedAt": {
"description": "Original invalid (non-UUID) value of 'createdAt' moved here when UUID-validation was enabled for 'createdAt'",
"type": "string"
},
"source": {
"description": "Person who processed activity (from login information)",
"type": "string"
},
"paymentMethod": {
"description": "Overall status of the action-setting",
"type": "string"
},
"accountId": {
"description": "ID of the accounts",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"userId": {
"description": "ID of the user",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
},
"id": {
"description": "Fine/fee action id, UUID",
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "uuid.schema",
"type": "string",
"pattern": "^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}$"
}
},
"additionalProperties": false,
"required": [
"accountId",
"userId"
]
}
Example:
{
"dateAction": "2017-07-24T01:24:01Z",
"typeAction": "Payment-ckeck",
"amountAction": 200.00,
"balance": 50.00,
"transactionInformation": "Department ENG-345",
"comments": "This a comment",
"notify": true,
"createdAt": "Main Library",
"source": "Doe,Jane",
"paymentMethod": "Check",
"accountId": "fc8a995f-f076-465e-b108-6b5d528d0d38",
"userId": "1ad737b0-d847-11e6-bf26-cec0c932ce01",
"id": "bcb9b1d9-b967-41c4-a476-a4c282527cea"
}
Item successfully updated
Bad request, e.g. malformed request body or query parameter. Details of the error (e.g. name of the parameter or line/character number with malformed data) provided in the response.
Media type: text/plain
Type: any
Example:
"unable to update feefineaction -- malformed JSON at 13:4"
Item with a given ID not found
Media type: text/plain
Type: any
Example:
"feefineaction not found"
Optimistic locking version conflict
Media type: text/plain
Type: any
Example:
version conflict
Internal server error, e.g. due to misconfiguration
Media type: text/plain
Type: any
Example:
internal server error, contact administrator