The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

WebService::Braintree::Configuration

PURPOSE

This keeps all configuration information for your WebService::Braintree installation.

A singleton of this class is instantiated when you use WebService::Braintree. You are intended to set attributes of this class immediately, then the rest of the distribution knows what to do.

ATTRIBUTES

Get these values from Braintree's API credentials documentation.

These attributes are standard mutators. If you invoke them with a value, they will set the attribute to that value. If you invoke them without a value, they will return the current value.

merchant_id(?$value)

This is your merchant_id.

public_key(?$value)

This is your public_key.

private_key(?$value)

This is your private_key.

environment(?$value)

This is your environment. The environment can be:

development | integration

This is when you're using a local server for testing. It's unlikely you will ever want to use this.

sandbox

This is when you're using your Braintree sandbox for testing.

qa

This is when you're using qa-master.braintreegateway.com for testing.

production

This is when you're live and rocking.

If you provide a value other than the ones listed above, a warning will be thrown. This distribution will probably not work properly in that case.

Management reserves the right to change this from a warning to a thrown exception in the future.

USAGE

Do yourself a favor and store these values in a configuration file, not your source-controlled code.

METHODS

There is one read-only method.

api_version()

This returns the Braintree API version this distribution speaks.