Download the PHP package open-feature/go-feature-flag-provider without Composer

On this page you can find all versions of the php package open-feature/go-feature-flag-provider. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package go-feature-flag-provider

go-feature-flag logo

GO Feature Flag - OpenFeature PHP provider

Packagist Version Documentation Issues Join us on slack

This repository contains the official PHP OpenFeature provider for accessing your feature flags with GO Feature Flag.

In conjunction with the OpenFeature SDK you will be able to evaluate your feature flags in your Ruby applications.

For documentation related to flags management in GO Feature Flag, refer to the GO Feature Flag documentation website.

Functionalities:

Dependency Setup

Composer

Getting started

Initialize the provider

The GoFeatureFlagProvider takes a config object as parameter to be initialized.

The constructor of the config object has the following options:

Option Description
endpoint (mandatory) The URL to access to the relay-proxy.
(example: https://relay.proxy.gofeatureflag.org/)
apiKey The token used to call the relay proxy.
customHeaders Any headers you want to add to call the relay-proxy.
httpclient The HTTP Client to use (if you want to use a custom one). It has to be a PSR-7 compliant implementation.

The only required option to create a GoFeatureFlagProvider is the URL (endpoint) to your GO Feature Flag relay-proxy instance.

The evaluation context is the way for the client to specify contextual data that GO Feature Flag uses to evaluate the feature flags, it allows to define rules on the flag.

The targeting_key is mandatory for GO Feature Flag to evaluate the feature flag, it could be the id of a user, a session ID or anything you find relevant to use as identifier during the evaluation.

Evaluate a feature flag

The client is used to retrieve values for the current EvaluationContext. For example, retrieving a boolean value for the flag "my-flag":

GO Feature Flag supports different all OpenFeature supported types of feature flags, it means that you can use all the accessor directly

Features status

Status Feature Description
Flag evaluation It is possible to evaluate all the type of flags
Caching Mechanism is in place to refresh the cache in case of configuration change
Event Streaming Not supported by the SDK
Logging Not supported by the SDK
Flag Metadata Not supported by the SDK

Implemented: ✅ | In-progress: ⚠️ | Not implemented yet: ❌

Contributing

This project welcomes contributions from the community. If you're interested in contributing, see the contributors' guide for some helpful tips.

PHP Versioning

This library targets PHP version 8.0 and newer. As long as you have any compatible version of PHP on your system you should be able to utilize the OpenFeature SDK.

This package also has a .tool-versions file for use with PHP version managers like asdf.

Installation and Dependencies

Install dependencies with composer install, it will update the composer.lock with the most recent compatible versions.

We value having as few runtime dependencies as possible. The addition of any dependencies requires careful consideration and review.


All versions of go-feature-flag-provider with dependencies

PHP Build Version
Package Version
Requires php Version ^8
guzzlehttp/guzzle Version ^7.9
open-feature/sdk Version ^2.0
psr/http-message Version ^2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package open-feature/go-feature-flag-provider contains the following files

Loading the files please wait ....