soap-to-rest-converter
Scannednpx machina-cli add skill a5c-ai/babysitter/soap-to-rest-converter --openclawSOAP to REST Converter Skill
Converts SOAP web services to REST APIs, handling WSDL parsing, operation mapping, and RESTful resource modeling.
Purpose
Enable SOAP modernization for:
- WSDL parsing
- Operation-to-endpoint mapping
- Type conversion
- Authentication migration
- REST resource modeling
Capabilities
1. WSDL Parsing
- Parse WSDL documents
- Extract operations
- Map data types
- Identify bindings
2. Operation-to-Endpoint Mapping
- Map operations to HTTP methods
- Design resource URIs
- Handle parameters
- Transform responses
3. Type Conversion
- Convert XML types to JSON
- Map complex types
- Handle enumerations
- Transform arrays
4. Authentication Migration
- Convert WS-Security
- Implement OAuth2
- Migrate certificates
- Handle API keys
5. SOAP Envelope Removal
- Strip envelope structure
- Extract body content
- Transform headers
- Handle faults
6. REST Resource Modeling
- Design resource hierarchy
- Implement HATEOAS
- Define link relations
- Model collections
Tool Integrations
| Tool | Purpose | Integration Method |
|---|---|---|
| SOAP UI | WSDL analysis | GUI |
| wsdl2rest | Conversion | CLI |
| Custom transformers | Type mapping | Library |
Output Schema
{
"conversionId": "string",
"timestamp": "ISO8601",
"source": {
"wsdl": "string",
"operations": "number"
},
"target": {
"openapi": "string",
"endpoints": "number"
},
"mappings": [
{
"soapOperation": "string",
"restEndpoint": "string",
"method": "string",
"notes": "string"
}
],
"typeConversions": [],
"manualReview": []
}
Integration with Migration Processes
- api-modernization: SOAP to REST conversion
Related Skills
openapi-generator: REST spec generationapi-inventory-scanner: Endpoint discovery
Related Agents
api-modernization-architect: API design
Source
git clone https://github.com/a5c-ai/babysitter/blob/main/plugins/babysitter/skills/babysit/process/specializations/code-migration-modernization/skills/soap-to-rest-converter/SKILL.mdView on GitHub Overview
Converts SOAP web services to REST APIs by parsing WSDLs, extracting operations, and modeling REST resources. It handles type conversion, authentication migration, and SOAP envelope removal to deliver modern, JSON-based endpoints. This reduces integration complexity and enables REST clients and microservices to consume legacy services.
How This Skill Works
The skill parses WSDL documents to extract operations, bindings, and data types. It maps each SOAP operation to an HTTP method and a RESTful URI, while converting XML schema types to JSON and modeling resources with possible HATEOAS links. It also migrates authentication (e.g., WS-Security to OAuth2 or API keys) and strips SOAP envelopes to expose clean REST payloads.
When to Use It
- Modernizing a legacy SOAP API to serve REST clients and mobile apps
- Designing REST endpoints guided by WSDL-defined operations
- Migrating authentication schemes from WS-Security to OAuth2 or API keys
- Producing a clean JSON payload by removing SOAP envelopes and transforming headers
- Generating a mappings document that links SOAP operations to REST endpoints for governance
Quick Start
- Step 1: Load and analyze the WSDL to identify operations, bindings, and types
- Step 2: Map each SOAP operation to a REST endpoint and HTTP method, and design resource models
- Step 3: Remove SOAP envelopes, convert XML types to JSON, migrate authentication, and validate with tests
Best Practices
- Start with a complete WSDL and validate operation coverage
- Define intuitive REST URIs and HTTP methods per operation
- Consolidate type mappings to JSON, preserving data types
- Test end-to-end with sample requests and responses
- Document the mappings and support OpenAPI-like output for teams
Example Use Cases
- Legacy CRM SOAP service migrated to REST endpoints like /customers and /customers/{id}
- ERP inventory SOAP service redesigned as REST resources such as /inventory/items and /inventory/items/{id}
- Payment gateway SOAP API migrated to REST with OAuth2 authentication
- HR system exposed as REST resources: /employees, /departments, and /roles
- Order processing SOAP service converted to REST with resources like /orders and /orders/{id}/lines