FOSMVVM ServerRequest Generator for Openclaw

An AI coding agent skill designed to scaffold type-safe ServerRequest protocols and server-side controllers for standardized FOSMVVM communication.

foscomputerservices
v2.0.6
Feb 15, 2026
0
0
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install fosmvvm-serverrequest-generator

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install fosmvvm-serverrequest-generator using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is FOSMVVM ServerRequest Generator?

The FOSMVVM ServerRequest Generator is a specialized tool within the ecosystem of Openclaw Skills that enforces a unified communication pattern between clients and servers. In the FOSMVVM architecture, ServerRequest is the exclusive method for data exchange, replacing brittle hardcoded URL strings and manual JSON encoding with type-safe protocols.

This skill automates the creation of request and response structures, ensuring that every interaction—whether from an iOS app, macOS tool, or WebApp—follows a predictable and robust lifecycle. By using this generator, developers ensure that configuration is centralized in the MVVMEnvironment, making the entire networking layer more maintainable and less prone to runtime errors.

FOSMVVM ServerRequest Generator Use Cases

  • Implementing standardized CRUD operations (Create, Read, Update, Delete) across Swift platforms.
  • Building data collectors, CLI tools, or background jobs that require secure server communication.
  • Bridging JavaScript-based WebApps to Swift backends using the WebApp bridge pattern.
  • Migrating legacy URLRequest code to a modern, type-safe architectural pattern.

How FOSMVVM ServerRequest Generator Works

  1. The skill analyzes the conversation context to identify the required CRUD operation and target HTTP semantics.
  2. It selects the appropriate protocol, such as ShowRequest, CreateRequest, or UpdateRequest, based on the identified intent.
  3. Nested data structures for RequestBody, ResponseBody, and ResponseError are designed based on documented requirements.
  4. Swift source files are generated for the ServerRequest type, including validation logic and localization keys.
  5. Corresponding Vapor controllers and route registrations are produced to handle the request on the server side.
  6. For web clients, the skill generates internal bridge routes to connect JavaScript fetch calls to the Swift request logic.

FOSMVVM ServerRequest Generator Setup

To use this within your Openclaw Skills workflow, ensure your project includes the FOSMVVM library. Invoke the generator directly through your AI interface:

/fosmvvm-serverrequest-generator

No manual path configuration is required as the skill references your active conversation context to determine the necessary structures.

FOSMVVM ServerRequest Generator Data Schema & Taxonomy

The skill organizes generated code into a strictly nested taxonomy to prevent namespace pollution:

Component Location Description
{Action}Request.swift ViewModels/Requests/ The primary Swift class containing nested RequestBody, ResponseBody, and ResponseError types.
{Action}Controller.swift WebServer/Controllers/ The Vapor-based server handler that processes the action.
ResponseError Nested within Request A custom error type that supports structured, localizable error responses.
RequestBody Nested within Request Implements ValidatableModel for automatic field validation.

FOSMVVM ServerRequest Generator Advanced Features

  • Support for Typed Error Handling, allowing clients to catch concrete error types instead of generic protocol markers.
  • Automatic localization support using LocalizableSubstitutions for dynamic error messages.
  • Built-in field-level validation error reporting via the ValidationError pattern.
  • Body size limit configuration using ServerRequestBodySize for handling large file or image uploads.
  • Multi-platform support, generating patterns suitable for iOS, macOS, CLI tools, and web-based browsers.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*