I started documentation about /svc/ API in Koha at http://wiki.koha-community.org/wiki/Import_MARC_to_Koha
Created attachment 6276 [details] [review] simple /svc/ HTTP example
Created attachment 6277 [details] [review] Bug 7213: simple /svc/ HTTP example
Created attachment 6280 [details] [review] Bug 7213: simple /svc/ HTTP example Simple command-line client which can authorize itself to Koha, get MARC XML record based on biblio number and update record
Created attachment 6281 [details] [review] Bug 7213: simple /svc/ HTTP example Simple command-line client which can authorize itself to Koha, get MARC XML record based on biblio number and update record
Created attachment 6282 [details] [review] Bug 7213: simple /svc/ HTTP example Simple command-line client which can authorize itself to Koha, get MARC XML record based on biblio number and update record
I extracted /svc/ API into own wiki page at: http://wiki.koha-community.org/wiki/Koha_/svc/_HTTP_API I will also stop spamming attachments for this bug, and move development of koha-svc.pl to my git repo at http://koha-dev.rot13.org:8081/gitweb/?p=koha-ffzg.git;a=shortlog;h=refs/heads/bug_7213-svc until code stabilize enough for me to submit it back to this ticket
Created attachment 8449 [details] [review] Bug 7213: simple /svc/ HTTP example
Created attachment 8466 [details] [review] Bug 7213: simple /svc/ HTTP example Simple command-line client which can authorize itself to Koha, get MARC XML record based on biblio number and update record This script can also be used as module using require "koha-svc.pl" from other scripts which can implement MARC XML creation or parsing.
Created attachment 9004 [details] [review] Bug 7213: simple /svc/ HTTP example Simple command-line client which can authorize itself to Koha, get MARC XML record based on biblio number and update record This script can also be used as module using require "koha-svc.pl" from other scripts which can implement MARC XML creation or parsing. Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Well documented script, works well.
Created attachment 9257 [details] [review] Bug 7213 - simple /svc/ HTTP example Simple command-line client which can authorize itself to Koha, get MARC XML record based on biblio number and update record This script can also be used as module using require "koha-svc.pl" from other scripts which can implement MARC XML creation or parsing. This is follow up version which now uses Content-type: text/xml header when using POST method to be in sync with documentation at http://wiki.koha-community.org/wiki/Koha_/svc/_HTTP_API
Created attachment 9258 [details] [review] Bug 7213 - simple /svc/ HTTP example Simple command-line client which can authorize itself to Koha, get MARC XML record based on biblio number and update record This script can also be used as module using require "koha-svc.pl" from other scripts which can implement MARC XML creation or parsing. This is follow up version which now uses Content-type: text/xml header when using POST method to be in sync with documentation at http://wiki.koha-community.org/wiki/Koha_/svc/_HTTP_API
Chris, can I bother you for another sign-off? MJ Ray pointed out that my usage of POSTDATA is gross hack and should be replaced with proper Content-type: text/xml header instead :-) Follow-ups are much more useful if I remember to git add code before git commit --amend...
Created attachment 9265 [details] [review] Bug 7213 - simple /svc/ HTTP example Simple command-line client which can authorize itself to Koha, get MARC XML record based on biblio number and update record This script can also be used as module using require "koha-svc.pl" from other scripts which can implement MARC XML creation or parsing. This is follow up version which now uses Content-type: text/xml header when using POST method to be in sync with documentation at http://wiki.koha-community.org/wiki/Koha_/svc/_HTTP_API Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
QA comment: * quite a large patch, but not linked to the core of Koha. No risk of any side effect * extensive documentation * coding guidelines seems OK * passes perlcritic => passes QA
Created attachment 9575 [details] [review] Bug 7213 : Follow up fixing license information
Harmless patch, pushed to 3.8.1
Follow up needs signoff
trivial follow-up, sign-off, passed QA and pushed in one go
As the /svc/ API already existed in 3.6.x, having documentation would be useful. This patch will be in 3.6.6.
There have been no further reports of problems so I am marking this bug resolved.