Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fork of https://bitbucket.org/taka2ru/clj-soap updated to latest Clojure version
Clojure
branch: master

This branch is 7 commits behind seancorfield:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
src/clj_soap
test/clj_soap/test
.gitignore
.lein-repl-history
README.md
project.clj

README.md

clj-soap

clj-soap is SOAP server and client using Apache Axis2.

This version is updated from Tetsuya Takatsuru's version to use Clojure 1.4.0 (and modern contrib).

Usage

Client

You can call remote SOAP method as following:

(require '[clj-soap.core :as soap])

(let [client (soap/client-fn "http://... (URL for WSDL)")]
  (client :someMethod param1 param2 ...))

Server

To make SOAP service:

(require '[clj-soap.core :as soap])

;; Defining service class
(soap/defservice my.some.SoapClass
  (someMethod ^String [^Integer x ^String s]
              (str "x is " x "\ts is " s)))

;; Start SOAP Service
(serve "my.some.SoapClass")

defservice needs to be AOT-compiled. For example, lein compile before running server.

Type Hint

SOAP services need typehints. String for arguments nad void for return value, if you don't specify typehints.

License

Copyright (C) 2011 Tetsuya Takatsuru

Distributed under the Eclipse Public License, the same as Clojure.

Something went wrong with that request. Please try again.