Personal tools
  • We're Hiring!

You are here: Home Documentation Previous versions OME Server Developer Image Server Interfaces

Interfaces

HTTP Interface

The HTTP interface to OMEIS consists of GET and POST requests. Methods that do not need to transmit binary data to OMEIS can specify all of their parameters using GET requests (i.e. using URL-encoded parameters). Methods that require transmitting binary pixel or file data (UploadFile and the Set* methods for Pixels) must be called using POST requests with multi-part forms. The binary payload must be the last part of the multi-part form. This is the same mechanism used by browsers for uploading files over HTTP.

Values returned by OMEIS have a text/plain mime-type specified in the header. Other return types (i.e. XML, various image formats) have the appropriate mime-type. When errors are reported by OMEIS, the response is always "500 Server Error" with the error message text following the header with a text/plain mime-type.

CLI Interface

OMEIS may also be used as a command-line executable, with parameters following the CGI style, i.e.:

./omeis Parameter1=value Parameter2=value
Other than the parameters, all I/O occurs via standard input/output. For example, to upload a file, use:
./omeis Method=UploadFile UploadSize=123456 < myFile.foo
Note that an "UploadSize" parameter is required for the "UploadFile" call issued on the command-line. Most http libraries set the Content-Length header in POST requests, which makes this parameter unnecessary when calling OMEIS via http.

Note that the "Method" and "SessionKey" parameters are required for all OMEIS requests regardless of interface.

cURL Client Interface

We provide a C client library, based on cURL, of functions that very closely mirror the OMEIS server HTTP interface. The library composes and parses the appropriate GET and POST requests allowing clients to easily interact with OMEIS. Please read the client interface documentation to learn more.

Since the library was written in C, language specific bindings can easily be written. We exploited this to write MATLAB MEX bindings. Please see the MATLAB MEX interface documentation for more information.

Document Actions