Skip to content

An example app built using the DevCycle PHP SDK and the Laravel Framework

License

Notifications You must be signed in to change notification settings

DevCycleHQ-Labs/example-php-laravel

Repository files navigation

DevCycle PHP Server SDK Example App

An example app built using the DevCycle PHP Server SDK and the Laravel Framework

Requirements

PHP 8.2+ Composer

Creating a Demo Feature

This example app requires that your project has a feature with the expected variables, as well as some simple targeting rules.

Click here to automatically create the feature in your project ⇦

When you run the example app and switch your identity between users, you'll be able to see the feature's different variations.

Installing Composer Locally

  • php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
  • php composer-setup.php
  • php -r "unlink('composer-setup.php');"

Running the Example

Setup

  • Run php composer.phar install (local install) or composer install (global install) in the project directory to install dependencies
  • Update the .env file and set DEVCYCLE_SERVER_SDK_KEY to your Environment's SDK Key.
    You can find this under Settings > Environments on the DevCycle dashboard. Learn more about environments.

Development

php artisan serve --port=8000

Runs the app in the development mode. Requests may be sent to http://localhost:8000

Documentation

For more information about using the DevCycle PHP Server SDK, see the documentation

About

An example app built using the DevCycle PHP SDK and the Laravel Framework

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published