# NAME

Catalyst::Model::WebService::MyGengo - Catalyst Model providing access to the [WebService::MyGengo](http://search.cpan.org/perldoc?WebService::MyGengo) library

# SYNOPSIS

In your model class:

    package MyApp::Model::MyGengo;
    

    use strict;
    use parent qw( Catalyst::Model::WebService::MyGengo );
    

    __PACKAGE__->config({
        class           => 'WebService::MyGengo::Client'
        , public_key    => 'your API public key'
        , private_key   => 'your API private key'
        , use_sandbox   => 0    # Whether to use the production site or the sandbox
        # See WebService::MyGengo::Client for other options
        });
    

    1;

Or in your myapp.conf or myapp_local.conf file ( be sure to escape any #
characters in your keys (eg \#) ):

    <Model::MyGengo>
        class           WebService::MyGengo::Client
        public_key      my-sandbox-pubkey
        private_key     my-sandbox-privkey
        use_sandbox     1
    </Model::MyGengo>

Then, in a controller:

    # Grab a WebService::MyGengo::Job
    my $job = $c->model('MyGengo')->get_job( 123 );

    # Add comments, etc.
    $job = $c->model('MyGengo')->add_job_comment( $job, "Nicey nice nice!" );

# SEE ALSO

[http://mygengo.com](http://mygengo.com)

[WebService::MyGengo::Client](http://search.cpan.org/perldoc?WebService::MyGengo::Client)

[Catalyst::Model::Factory::PerRequest](http://search.cpan.org/perldoc?Catalyst::Model::Factory::PerRequest)

# AUTHOR

Nathaniel Heinrichs

# LICENSE

Copyright (c) 2011, Nathaniel Heinrichs <nheinric-at-cpan.org>.
All rights reserved.

This library is free software. You can redistribute it and/or modify
it under the same terms as Perl itself.