alexa-request:图书馆处理Alexa传入的请求和传出的消息

时间:2024-05-30 17:12:39
【文件属性】:

文件名称:alexa-request:图书馆处理Alexa传入的请求和传出的消息

文件大小:33KB

文件格式:ZIP

更新时间:2024-05-30 17:12:39

PHP

Alexa请求处理程序 小型PHP库,用于处理PHP中针对Amazon的Alexa应用程序的传入和传出请求。 安装 composer require weysan/alexa-request 如何使用它 该库现在与PSR-7兼容。 如果使用HttpFoundation,则需要使用库zendframework/zend-diactoros在ServerRequestInterface类中转换Request 。 请参阅此处的文档: : 首先,您必须创建一个实现Weysan\Alexa\Intents\IntentsInterface的Intent类。 您需要创建一个方法getResponseObject ,该方法将返回Weysan\Alexa\Response\Response实例。 您还需要创建一个getSessionAttributes方法,该方法将返回Weysan\Alexa\


【文件预览】:
alexa-request-master
----.gitignore(16B)
----Helper()
--------AlexaIncomingRequestAwareTrait.php(728B)
----Exceptions()
--------AlexaRequestException.php(221B)
--------UnexpectedOutputTypeException.php(474B)
--------UnexpectedCardTypeException.php(366B)
--------WrongOutputFormatException.php(377B)
----.travis.yml(203B)
----Response()
--------OutputSpeech.php(2KB)
--------SessionAttributes.php(965B)
--------Cards()
--------Response.php(2KB)
--------Card.php(976B)
----samples()
--------simple()
--------intent-with-incoming()
----composer.json(735B)
----composer.lock(83KB)
----README.md(3KB)
----phpunit.xml(947B)
----IntentRegistry.php(1KB)
----ValidateRequest.php(801B)
----AlexaIncomingRequest.php(2KB)
----Tests()
--------incoming.json(512B)
--------Response()
--------incoming_session_off.json(522B)
--------AlexaIncomingRequestTest.php(3KB)
--------IntentRegistryTest.php(2KB)
--------incoming_with_slot.json(654B)
--------AlexaOutgoingGeneratorTest.php(6KB)
--------incoming_ssml.json(516B)
--------ValidateRequestTest.php(2KB)
--------Mock()
----Intents()
--------IntentsInterface.php(453B)
----AlexaOutgoingGenerator.php(1KB)

网友评论