Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

determine what data needs to go into alma transaction #20

Closed
ihardy opened this issue Dec 14, 2018 · 5 comments
Closed

determine what data needs to go into alma transaction #20

ihardy opened this issue Dec 14, 2018 · 5 comments
Assignees
Labels
question Further information is requested
Milestone

Comments

@ihardy
Copy link
Contributor

ihardy commented Dec 14, 2018

List all data that needs to go into the alma transaction to create a reconciliation report below.

@ihardy ihardy self-assigned this Dec 14, 2018
@ihardy ihardy added this to the mvp milestone Dec 14, 2018
@ihardy ihardy added the question Further information is requested label Dec 14, 2018
@ihardy
Copy link
Contributor Author

ihardy commented Dec 18, 2018

Example payment data:

{'id': '3637417490004617',
 'type': {'value': 'CARDRENEWAL', 'desc': 'Card renewal'},
 'status': {'value': 'CLOSED', 'desc': 'Closed'},
 'user_primary_id': {'value': '3314229360004617',
  'link': 'https://api-eu.hosted.exlibrisgroup.com/almaws/v1/users/3314229360004617'},
 'balance': 0.0,
 'remaining_vat_amount': 0.0,
 'original_amount': 1.5,
 'original_vat_amount': 0.0,
 'creation_time': '2018-11-27T16:20:41.297Z',
 'status_time': '2018-12-18T01:47:15.255Z',
 'comment': 'test for fines app',
 'owner': {'value': '01WRLC_SCF', 'desc': 'Shared storage institution'},
 'title': None,
 'barcode': None,
 'transaction': [{'type': {'value': 'PAYMENT', 'desc': 'Payment'},
   'amount': 1.5,
   'vat_amount': 0.0,
   'comment': 'wrlcfineapp IZ_ID',
   'created_by': 'exl_api',
   'transaction_time': '2018-12-18T01:47:15.255Z',
   'received_by': {'value': 'Not At Desk', 'desc': 'Not at Desk'},
   'payment_method': {'value': 'ONLINE', 'desc': 'Online'}}],
 'link': 'https://api-eu.hosted.exlibrisgroup.com/almaws/v1/users/3314229360004617/fees/3637417490004617'}

@ihardy
Copy link
Contributor Author

ihardy commented Dec 18, 2018

@krebeck Are you able to find a record of this payment through analytics? In particular the transaction field 'comment': 'wrlcfineapp IZ_ID', or any payments made by the user exl_api?

The custom data I can add in here is pretty limited, but it seems like if we identify all payments made by exl_api, and then put in the institution that collected the money in the comment field that would be enough to create the reconciliation report.

In terms of security and the possibility of creating bogus transaction that @dongourley reminds me to protect against, I can imagine a far out scenario where a malicious actor uses the api to make payments and puts in bogus comments to scam other universities out of fine money. We could protect against that by verifying that the transaction numbers in the report we generate form analytics, match the transaction numbers in the fines app audit log. This would prevent any sort of transaction spoofing accidental or otherwise.

@dongourley
Copy link
Member

Although I don't think the audit log should be the basis of the reconciliation report -- a report should be generatable just from info in Alma -- using it to validate the information in Alma seems perfectly legit.

I still wonder if having the fines "collected" at a circ desk that only this app user has a role in provides the best security within Alma access control.

@ihardy
Copy link
Contributor Author

ihardy commented Dec 18, 2018

I can't find a way to set the received_by value through the fee payment api as documented here. It does seem like you should be able to set it based on the transaction data dictionary but no luck changing those valued through avaialble api calls that I know of. I tried a couple ways in this notebook (last few calls) https://github.com/WRLC/alma-notebooks/blob/master/fines-data.ipynb

Is there a way to set a default desk for a user? if so, maybe we could set the default desk for the exl_api user to something.

@ihardy
Copy link
Contributor Author

ihardy commented Dec 19, 2018

Necessary Data:

  1. Fee owning institution (this is who the money will be owed to) in this example, 01WRLC_SCF
  2. Fee accepting institution (this will go in the transaction comment) IZ_ID
  3. amount (transaction)
  4. date (transaction)
  5. Fee id (fee) This can be used to compare with the audit log if we need to do an audit

Since I can't figure out how to set the "received by" location when posting the transaction, I think this is the best we'll do. I'll close this if there are no further comments.

@ihardy ihardy closed this as completed Dec 21, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants