kapitancho/walnut-lang-swoole-http-adapter

There is no license information available for the latest version (0.0.4) of this package.

0.0.4 2024-04-09 22:04 UTC

This package is not auto-updated.

Last update: 2024-10-23 00:48:44 UTC


README

A small adapter for performing HTTP calls to Walnut language code using Swoole.

Installation

To install the latest version, use the following command:

$ composer require kapitancho/walnut-lang-swoole-http-adapter

Usage

Start a Swoole HTTP server using server.php or use the sample docker files and call http://localhost:8068/ in your browser.

module demo-swoole-http:

handleRequest = ^HttpRequest => HttpResponse :: [
   statusCode: 200,
   protocolVersion: HttpProtocolVersion.HTTP11,
   headers: [:],
   body: 'Hello world!'
];