David E. Wheeler > PGXN-API-v0.16.2 > PGXN::API::Router

Download:
PGXN-API-v0.16.2.tar.gz

Dependencies

Annotate this POD

Website

View/Report Bugs
Module Version: v0.16.2   Source   Latest Release: PGXN-API-v0.16.3

Name ^

PGXN::API::Router - The PGXN::API request router.

Synopsis ^

  # In app.pgsi
  use PGXN::API::Router;
  PGXN::API::Router->app;

Description ^

This class defines the HTTP request routing table used by PGXN::API. Unless you're modifying the PGXN::API routes, you won't have to worry about it. Just know that this is the class that Plack uses to fire up the app.

Interface ^

Class Methods

app

  PGXN::API->app(%params);

Returns the PGXN::API Plack app. The supported parameters are:

doc_root

The path to use for the API document root.

errors_to

An email address to which error emails should be sent.

errors_from

An email address from which alert emails should be sent.

See pgxn_api_server for an example usage.

Author ^

David E. Wheeler <david.wheeler@pgexperts.com>

Copyright and License ^

Copyright (c) 2011 David E. Wheeler.

This module is free software; you can redistribute it and/or modify it under the PostgreSQL License.

Permission to use, copy, modify, and distribute this software and its documentation for any purpose, without fee, and without a written agreement is hereby granted, provided that the above copyright notice and this paragraph and the following two paragraphs appear in all copies.

In no event shall David E. Wheeler be liable to any party for direct, indirect, special, incidental, or consequential damages, including lost profits, arising out of the use of this software and its documentation, even if David E. Wheeler has been advised of the possibility of such damage.

David E. Wheeler specifically disclaims any warranties, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose. The software provided hereunder is on an "as is" basis, and David E. Wheeler has no obligations to provide maintenance, support, updates, enhancements, or modifications.

syntax highlighting: