WebAPI

These are notes about possible services to be implemented. In the future, this section will be removed, or transformed into a real WebAPI that describes the implemented services.

Composers Services

Composers are services that combine serveral services into a composed one, usually for cleaner interface. As an example, take the mapper proxy service that maps one URL into another, possibly much simpler:

http://www.mycom.com/products/*.html 
        
 -->
        
http://services.restscape.org/xslt
        ?xml=http://www.mycom.com/products/{1}.xml
        &xsl=http://www.mycom.com/xslt/product2html.xsl

Mapping services

  • mps: Serves (proxy) maped URLs. The service allows hot URL add/remove.

Processors Services

Processors are services that take one or more input resources, process them, and generate a transformed output. One of the most simple ones is the XSLT processor.

XML/XSL related

  • xslt: Transforms an input XML, given an input XSLT, into an output XML.

Renderers

Data filtering

  • file2text: Extracts text from a given resource (PDF, word, xml, html...)
  • file2metadata: Extracts metadata from resource and produces a resource descriptor in RDF.

Producers Services

Producers are services that generate resources from scratch, given non-resources inputs. For example, take text2img service that builds an image representation of a given text, or the more impresive text2speech that reads the text.

Producers should be used along with a proxy cache for improved performance.

Image producers

  • text2img: Produces a image representation of a text text2img - Image generation from a font

    This service takes a text and format info (font, colors, size...) and builds a corresponding image. You can use it to build better interfaces for your websites. Should be used with a cache proxy for better performance.

    Inputs:
            text: The text to write
            mime: The image mimetype among "gif, jpg, png" (default: gif)
            align: The text align among "left, right, center, justify" (default: left)
            font-url: The font to use (default: url pointing to Times New Roman)
            fore-color: Foreground color (default: black)
            back-color: Background color (default: white)
            width: The image width (default: autowidth)
            height: The image height (default: autoheight)
    
    Outputs:
            The binary image with the selected mimetype

    The only URL parameter for this service is the font-url, that must point to a TTF file. You can get hundreds of fonts from http://www.1001freefonts.com/.

Voice producers

  • text2speech: Produces an audio representation of a text

Storers Services

Storers are services that store resources (sometimes just a subset)

Temporal storers

  • tempstore: Stores a resource for a short time. It's useful for testing and temporal processing

Generic storers

  • resstore: Generic resource storage (web file store)

Searchable storers

  • resstore: Publish database tables as RDF resources. Allows query, insert, update, and delete operations.
  • rdfstore: Generic RDF store. Allows RDFQL and SPARQL query operations
  • rdfindex: Indexes RDFs. Allows index-like query operations.