Bug 16652 - Omnibus: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers
Summary: Omnibus: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers
Status: ASSIGNED
Alias: None
Product: Koha
Classification: Unclassified
Component: REST api (show other bugs)
Version: master
Hardware: All All
: P1 - high enhancement with 4 votes (vote)
Deadline: 2016-08-31
Assignee: Jiri Kozlovsky
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 13895 13927 15165 16202 16330 16497 16825 16826 17003 17004 17005 17006 17314 13903 14868 16699 17007
Blocks:
  Show dependency treegraph
 
Reported: 2016-06-03 18:56 UTC by Mike
Modified: 2017-09-25 18:01 UTC (History)
8 users (show)

See Also:
Change sponsored?: Sponsored
Patch complexity: Large patch
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:


Attachments
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers (130.20 KB, patch)
2016-08-02 01:43 UTC, Jiri Kozlovsky
Details | Diff | Splinter Review
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers (135.91 KB, patch)
2016-08-03 12:28 UTC, Jiri Kozlovsky
Details | Diff | Splinter Review
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers (144.49 KB, patch)
2016-08-03 12:38 UTC, Jiri Kozlovsky
Details | Diff | Splinter Review
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers (145.20 KB, patch)
2016-09-18 09:47 UTC, Jiri Kozlovsky
Details | Diff | Splinter Review
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers (155.63 KB, patch)
2016-09-18 10:28 UTC, Jiri Kozlovsky
Details | Diff | Splinter Review
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers (158.37 KB, patch)
2016-09-18 11:24 UTC, Jiri Kozlovsky
Details | Diff | Splinter Review
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers (158.60 KB, patch)
2016-09-18 11:35 UTC, Jiri Kozlovsky
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Mike 2016-06-03 18:56:00 UTC

    
Comment 1 Josef Moravec 2016-06-08 05:43:03 UTC
This bug is just omnibus. We would like to base our new Koha driver for VuFind on RESTful API and to rewrite driver for xcnciptoolkit using this API too. These drivers has many functions so we need the API to be heavily extended.
Comment 2 Jiri Kozlovsky 2016-06-28 12:35:16 UTC
The extensions we need for xcncip2toolkit:

Authenticate user's credentials
 - can this be done using API?

Retrieve user's personal information (bug #16330 - Signed off at the moment)
 - email, firstname, lastname, middlename, street, city & distinction between employee/reader for providing the user's identity to a simpleSAMLphp xcncip2 module (https://github.com/moravianlibrary/SimpleSAMLphp-modules/tree/master/modules/xcncip2) & for showing the profile in VuFind
 - also user's blocks and traps  (called debarred in Koha) would be useful

Retrieve, create & cancel user's holds (bug #13903 - Pushed to master)
 - within the retrieval we need the hold queue length for each hold

Retrieve & renew user's checkouts/issues (bug #13895 - Failed QA)
 - we need to include the renewability to prevent user from being denied while trying to renew

Retrieve user's checkouts history with pagination support (no bug yet)

Retrieval of user's accounlines (bug #15165 - In discussion)

Retrieve items & biblios - especially availability & current location
 - it also would be nice to include the requestability to currently logged in user in VuFind somehow to prevent user from being denied while trying to borrow
Comment 3 Jiri Kozlovsky 2016-08-02 01:43:50 UTC Comment hidden (obsolete)
Comment 4 Jiri Kozlovsky 2016-08-03 12:28:52 UTC Comment hidden (obsolete)
Comment 5 Jiri Kozlovsky 2016-08-03 12:38:53 UTC
Created attachment 53943 [details] [review]
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers

Actualized included bugs.
Comment 6 Lari Taskula 2016-08-19 11:06:31 UTC
A little advertisement if you don't mind... I recommend checking out Bug 16212, Bug 16699 and Bug 14868 because they make Swagger more maintainable as new operations are introduced, fix problems with our spec being actually valid against Swagger schema and also enable our spec to be used with Swagger-UI (which is awesome), and introduce required permissions for an operation directly in Swagger instead of having them (hidden) inside controllers. If possible it would be nice to have sign-offs for them ASAP because as API grows larger, it will be more and more annoying to rebase those 3 bugs on master.

Thank you!
Comment 7 Lari Taskula 2016-08-19 11:08:49 UTC
We have also rebased these bugs on top of master, see our API in our test server at http://renki.pohjoiskarjala.net/api/v1/doc with Swagger-UI.
Comment 8 Jiri Kozlovsky 2016-09-18 09:47:30 UTC
Created attachment 55642 [details] [review]
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers

Fixed checkout endpoint for null itemnumbers & renamed "borrowers" tags
to "patrons"

Note that this patch is about to be used with the current Koha stable
version, which has not implemented Bug 16202, Bug 16699 and Bug 14868 just yet.

We want to be capable of patching the stable so that it can contain all
the services needed with basically zero-effort.

Lari: I hope those patches are going to be backported to current stable
soon so that we don't have to do this hassle. And, the Swagger-UI is
quite awesome! :)
Comment 9 Jiri Kozlovsky 2016-09-18 10:28:16 UTC
Created attachment 55647 [details] [review]
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers

Added auth endpoint

Note that this patch is about to be used with the current Koha stable
version, which has not implemented Bug 16202, Bug 16699 and Bug 14868 just yet.




Current depends: 13895 13903 13927 14868 15165 16202 16699 16330 16497 16825 16826 17003 17004 17005 17006 17007
Comment 10 Jiri Kozlovsky 2016-09-18 10:30:07 UTC
Updated dependecies
Comment 11 Jiri Kozlovsky 2016-09-18 11:24:53 UTC
Created attachment 55651 [details] [review]
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers

Added renewability endpoint

Note that this patch is about to be used with the current Koha stable
version, which has not implemented Bug 16202, Bug 16699 and Bug 14868 just yet.
Comment 12 Jiri Kozlovsky 2016-09-18 11:35:53 UTC
Created attachment 55652 [details] [review]
Bug 16652: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers

Fixed availability endpoint

Note that this patch is about to be used with the current Koha stable
version, which has not implemented Bug 16202, Bug 16699 and Bug 14868 just yet.
Comment 13 Jiri Kozlovsky 2016-09-18 15:01:24 UTC
We also want to have the API for manipulating suggestions implemented, so I've included Bug 17314 to dependecies.
Comment 14 Tomás Cohen Arazi 2016-09-18 15:41:50 UTC
I'd like to mention that having such a big patch won't help this work get into master. You need to split it into several smaller units, that can be tested on their own, and have precise instructions so you find people willing to sign this work.
Comment 15 Jiri Kozlovsky 2016-09-18 15:56:40 UTC
(In reply to Tomás Cohen Arazi from comment #14)
> I'd like to mention that having such a big patch won't help this work get
> into master. You need to split it into several smaller units, that can be
> tested on their own, and have precise instructions so you find people
> willing to sign this work.

Yes, I know that. All those patches actually exists already - those are the dependency bugs. This is just omnibus which should not have an implementation on it's own.

The purpose of the only one attachment here is to easily perform one patch on a stable version of Koha in order to implement all the dependency patches at once. We do that because the bugs are changing their structure due to changes in swagger implementation but we still want those bugs to function on stable version of Koha (currently 16.05.x) as there probably won't be backported the newest swagger implementation