2017 © Pedro Peláez
 

library lib-php

PHP Library to use Feature Toggle services

image

featuretoggle/lib-php

PHP Library to use Feature Toggle services

  • Sunday, September 11, 2016
  • by presencenet
  • Repository
  • 1 Watchers
  • 0 Stars
  • 8 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

Feature Toggle

A PHP client library for interacting with featuretoggle.com. This library is under active development and is likely to change frequently. Bug reports and pull requests are welcome., (*1)

Installation

Install with Composer, (*2)

php composer.phar require featuretoggle/lib-php

Usage

require 'vendor/autoload.php';

// Create a new FTClient with your customer and environment API key's
$featuretoggle = new FeatureToggle\FTClient('customerKey', 'environmentKey', array('options'));

// Get features
$features = $featuretoggle->getFeatures();

// Check feature status
$enabled = $featuretoggle->isEnabled('feature_key');
if($enabled) {
    // Feature is enabled, do something
}
else {
    // Feature is disabled, do something else
}

Configuration Options

The library caches responses from received the Feature Toggle API locally to limit the number of requests. The default cache timeout is 300 seconds (5 minutes). You can adjust the cache timeout by providing the 'cache_timeout' config option when initializing the library., (*3)

array(
    'cache_timeout' => SECONDS, // optional, defaults to 300 seconds
)

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/featuretoggle/lib-php., (*4)

License

The library is available as open source under the terms of the MIT License., (*5)

The Versions

11/09 2016

dev-github

dev-github https://github.com/feature-toggle/lib-php

PHP Library to use Feature Toggle services

  Sources   Download

MIT

The Requires

 

client feature toggle feature flag feature toggle featuretoggle feature-toggle featuretoggle php

11/09 2016

v1.0.1

1.0.1.0 https://github.com/feature-toggle/lib-php

PHP Library to use Feature Toggle services

  Sources   Download

MIT

The Requires

 

client feature toggle feature flag feature toggle featuretoggle feature-toggle featuretoggle php

11/09 2016

v1.0

1.0.0.0 https://github.com/feature-toggle/lib-php

PHP Library to use Feature Toggle services

  Sources   Download

MIT

The Requires

 

client feature toggle feature flag feature toggle featuretoggle feature-toggle