http_server_lua_demo

Serve a Hello World web UI with toggle state via Lua HTTP endpoints.

2.0k|410|Updated Apr 17, 2026
One-click install
npx skills add https://github.com/espressif/esp-claw --skill http-server-lua-demo
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: http_server_lua_demo
Source: https://github.com/espressif/esp-claw/tree/main/components/lua_modules/lua_module_http_server/skills/http_server_lua_demo
Command: npx skills add https://github.com/espressif/esp-claw --skill http-server-lua-demo

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and assets (resource) components.

What problem does it solve?

This skill solves the need for a quick, local demo of how an ESP-based device can serve a simple web page and react to browser input without writing a full application from scratch.

Core Features & Use Cases

  • HTTP server demo with a browser UI: Serve a Hello World page with a toggle switch backed by Lua handlers.
  • Live state and event logging: Use GET to read state and POST to toggle it, with Lua logging switch toggle events.
  • Static web assets on device: Mount the skill-provided web assets so the browser can load CSS/JS and interact with the device.

Quick Start

Start the bundled Lua HTTP server script, then open /lua/lua_demo/ in your browser to view the Hello World page and toggle the switch while it logs events.

Frequently Asked Questions about http_server_lua_demo

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create an HTTP server with Lua on an embedded device?

To create an HTTP server with Lua on an embedded device, use this skill to run a bundled Lua script that serves a web UI and handles browser input via GET and POST endpoints. It mounts web assets and processes JSON requests directly on the device.

Can I build a web UI toggle switch that logs events using Lua?

Yes, you can build a web UI toggle switch that logs events using Lua by deploying this skill's HTTP server. It provides a toggle control on a web page and logs switch events on the device when the browser sends a POST request to the toggle API.

How do I expose a JSON API for IoT state management using Lua?

Expose a JSON API for IoT state management using Lua by utilizing this skill's HTTP server, which decodes and encodes JSON bodies for state and toggle endpoints. The API allows GET requests to read state and POST requests to change it.

Does this Lua HTTP server demo require any external dependencies?

No, this Lua HTTP server demo does not require any external dependencies. It runs asynchronously using a bundled script and includes a mounted assets directory to serve the necessary CSS and JS for the browser interface.

What is the best way to handle browser-driven input on an ESP device with Lua?

The best way to handle browser-driven input on an ESP device with Lua is using this skill's HTTP server. It processes browser requests through GET and POST handlers, updating the device state and logging toggle events without needing a full application.