http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13799 --- Comment #5 from Kyle M Hall <kyle@bywatersolutions.com> --- (In reply to Benjamin Rokseth from comment #4)
Tested this patch locally on a koha dev setup, and some remarks:
* incredibly fast! ~50msec on 50 borrowers...promising! * few deps:
apt-get install -y make cpanm cpanm Mojolicious cpanm Swagger2
Yes, the dependancies will definitely need to be added to PerlDependancies.pm
* clean and little "glue-code" to Koha * self-documenting, in a way, with Swagger
I propose that this POC is moved forward to a fully working example covering Borrowers, that can be part of Koha 3.20 if the New_REST_API_RFC (http://wiki.koha-community.org/wiki/New_REST_API_RFC) are fullfilled.
I completely agree, this should definitely move forward!
What's missing now: - authentication
Yes, there are a number of ways for handle this: 1) The way /svc works now 2) Ability to pass in a auth_username and auth_password ( simpler, stateless, easy for command line use of /rest, only safe over https or from localhost ) 3) API tokens ( best idea, will require a whole separate feature ) I think one or both of the first two ways would be perfectly acceptable.
- C4::Borrowers vs Koha::Borrowers?
We should use this as an opportunity to take full advantage of the new Koha::Object system wherever possible.
- versioning
Versioning should be a simple matter ( as described in http://wiki.koha-community.org/wiki/New_REST_API_RFC )
- content negotiation
I personally think supporting JSON is adequate, but that's just my opinion. Supporting other formats would be great as long as we implement it at a low enough level that future developers will not have to deal with it ; ) I believe there is already a patch floating around that adds a to_json method to Koha::Object. We could add a method 'serialize' instead that takes a format and could output json, xml, yaml or whatever.
- full CRUD
Definitely! This is a great start! -- You are receiving this mail because: You are watching all bug changes.