Download the PHP package syousoufov/alexa-skills-php without Composer
On this page you can find all versions of the php package syousoufov/alexa-skills-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download syousoufov/alexa-skills-php
More information about syousoufov/alexa-skills-php
Files in syousoufov/alexa-skills-php
Package alexa-skills-php
Short Description Utility package to handle the tedium of setting up a custom web service for Alexa skills.
License MIT
Informations about the package alexa-skills-php
Alexa Skills PHP Library
Utility package to handle the tedium of setting up a custom web service for Alexa skills.
Setup
- Require the package
composer require syousoufov/alexa-skills-php
-
Attach the service provider to
config/app.php
: - Publish the
alexa-skills-php
config withphp artisan vendor:publish --provider="AlexaPHP\Providers\AlexaServiceProvider"
and change the required values. The defaults for everything exceptapplication_id
should work just fine. -
Add the route middleware to the
$routeMiddleware
stack inapp/Http/Kernel.php
: - Routes can now be served through the middleware:
Handling requests and returning responses
Alexa requests can be routed to a single controller method which can act as a funnel to pass the request to appropriate handlers.
Response types
Speech Response - return some speech to render to the user
Card - return a card to render to the Amazon Alexa app
Reprompt - issue a reprompt
Output Types
You can also specify PlainText or SSML speech output types for say
and reprompt
:
Extracting data from the request
This is not an exhaustive list of all available methods so please review the source to get a better understanding of what's available while this readme gets filled out.
Testing
- Run
composer install
thenphpunit
. - Code coverage:
phpunit --coverage-html tests/coverage/ && open tests/coverage/index.html
TODO
- Complete documentation
- Open source the example web service
- Re-evaluate API decisions to get a more fluent syntax
- Get from 96% code coverage to 100%
All versions of alexa-skills-php with dependencies
illuminate/routing Version 5.2.*
laravel/framework Version 5.2.*
nesbot/carbon Version ~1.21
ext-openssl Version *