[sword-devel] SOAP interface

Chris Little sword-devel@crosswire.org
Tue, 4 Dec 2001 09:53:56 -0800


I committed a SOAP server (using CGI) and client (just for testing the
server) to CVS today.  They're buried down in
sword/apps/console/diatheke/soap.  sapouni.cgi is the server.
soapatheke.pl is the client.  Both require the SOAP::Lite Perl module as
well as everything needed for HTTP transport using SOAP::Lite.

The server is running on my server with the following:
uri: http://bible.gotjesus.org/sapouni
proxy: http://bible.gotjesus.org/cgi-bin/sapouni.cgi

It has only one function, at least for now:
biblequery(<books>, <verse/word/search key>, <options>, <encoding>,
<markup>, <searchtype>, <locale>, <transliteration script>, <max
verses>)

<books> can be a space delimited list of books, a single book, or "" for
KJV (default).
For everything else, consult the output from diatheke (the command-line
version) for valid arguments/syntax.
If you want to use the default value or no value for one of the
arguments, omit it or set it to "".

The return value will be the verses you request in a format identical to
what you would receive when executing diatheke on the command line.

This is basically a stripped down version of the web/CGI perl script
that took me all of about 2 hours to write, and most of that was spent
installing Perl modules.  SOAP functionality is provided entirely by
SOAP::Lite, so don't ask me anything about SOAP, because I don't know
the answer. :)

Sapouni is Greek for soap, for those who were wondering.

--Chris