This repository is a fork of InditexTech's API Scoring IDE Plugins, enhanced with additional features and improvements. While the original project provides a robust foundation for API validation, this fork extends its capabilities to better support enterprise use cases.
- WSO2 API Analysis: Added support for analyzing WSO2 API export ZIP files, making it easier to validate APIs exported from WSO2 API Manager.
- Spider Chart Visualization: Introduced a new spider/radar chart representation to visualize API scoring metrics, providing a more intuitive way to understand API quality across different dimensions.
Below is an example of the scoring visualization for a WSO2 API:
The spider chart provides a clear view of the API's performance across three key dimensions:
- Design: 84.29%
- Security: 76.19%
- Documentation: Not Applicable (Testing)
The system provides detailed feedback for each dimension:
This detailed view helps developers identify and fix specific issues in their API design and implementation.
The API Scoring Extension is a comprehensive tool suite designed to evaluate and improve the quality of your APIs. It automatically analyzes API specifications against industry best practices, security standards, and documentation requirements, providing detailed feedback and scoring metrics to help developers create better APIs.
- Automated API Analysis: Validates APIs against predefined rulesets for design, security, and documentation
- Multiple Format Support: Handles OpenAPI, AsyncAPI, Protocol Buffers, Avro schemas, and WSO2 API exports
- Real-time Validation: Integrates with VS Code to provide immediate feedback during development
- Visual Scoring: Spider/radar chart visualization of API quality metrics across different dimensions
- Detailed Reports: Comprehensive analysis with specific recommendations for improvement
- WSO2 Integration: Direct support for WSO2 API Manager exports
The ecosystem contains all necessary components to run the complete API Scoring platform, including the backend service, frontend viewer, and IDE extensions.
The following diagram shows how the different components of the API Scoring Extension ecosystem interact with each other:
graph TB
subgraph "Developer Environment"
IDE["VS Code<br/>Extension"]
style IDE fill:#e1f5fe,stroke:#01579b
end
subgraph "API Scoring Platform"
SPA["Web Viewer<br/>:3000"]
API["Scoring API<br/>:8080"]
CERT["Certification<br/>Service"]
RULES["Rule Engine"]
style SPA fill:#f3e5f5,stroke:#4a148c
style API fill:#e8f5e9,stroke:#1b5e20
style CERT fill:#e8f5e9,stroke:#1b5e20
style RULES fill:#e8f5e9,stroke:#1b5e20
end
subgraph "API Specifications"
direction TB
SPECS["API Specs"]
OAPI["OpenAPI"]
ASYNC["AsyncAPI"]
PROTO["Protocol<br/>Buffers"]
AVRO["Avro"]
WSO2["WSO2"]
SPECS --> OAPI
SPECS --> ASYNC
SPECS --> PROTO
SPECS --> AVRO
SPECS --> WSO2
style SPECS fill:#fff3e0,stroke:#e65100
style OAPI fill:#fff3e0,stroke:#e65100
style ASYNC fill:#fff3e0,stroke:#e65100
style PROTO fill:#fff3e0,stroke:#e65100
style AVRO fill:#fff3e0,stroke:#e65100
style WSO2 fill:#fff3e0,stroke:#e65100
end
%% Flujo principal
IDE -->|"1. Validate"| API
API -->|"2. Process"| CERT
CERT -->|"3. Apply Rules"| RULES
RULES -->|"4. Results"| API
API -->|"5. Display"| SPA
IDE -->|"6. Show"| SPA
%% ConexiΓ³n con especificaciones
OAPI & ASYNC & PROTO & AVRO & WSO2 -->|"Input"| API
The architecture consists of:
- VS Code Extension: Provides IDE integration for real-time API validation
- Frontend SPA: Web interface for viewing detailed scoring results and recommendations
- Backend Services:
- Scoring API: Main entry point for API analysis
- Certification Service: Handles API validation and scoring
- Ruleset Engine: Applies design, security, and documentation rules
- Input Sources: Supports multiple API specification formats including OpenAPI, AsyncAPI, Protocol Buffers, and Avro Schema
# Start the entire ecosystem
./start-ecosystem.sh
# Stop the entire ecosystem
./stop-ecosystem.sh
# Check ecosystem status
./status.shecosystem/
βββ start-ecosystem.sh # Main script to start the ecosystem
βββ stop-ecosystem.sh # Main script to stop the ecosystem
βββ status.sh # Script to check ecosystem status
βββ README.md # This file
βββ ECOSYSTEM-README.md # Detailed ecosystem documentation
The ecosystem includes:
-
Backend API (port 8080)
- API certification and scoring service
- Main endpoint:
http://localhost:8080/apifirst/v1 - Health check:
http://localhost:8080/health
-
Frontend SPA (port 3001)
- Web interface for viewing results
- URL:
http://localhost:3001 - Interactive scoring visualization
-
VS Code Extension
- Integrates with VS Code/Cursor
- Automatically installed during startup
- Provides real-time API validation
Create a project with the following structure:
my-api-project/
βββ metadata.yml
βββ openapi-rest.yml
Example metadata.yml:
apis:
- name: "My REST API"
version: "1.0.1"
description: "Sample API for demonstration"
definition-path: "openapi-rest.yml"
api-spec-type: "REST"- Open your API project in VS Code:
cd my-api-project
code .- Press
Cmd+Shift+P(Mac) orCtrl+Shift+P(Windows/Linux) - Type and select: "APIScoring: Validate local APIs & Open APIScoring Application"
- View your API score and recommendations in the new tab
# Install the CLI
npm install -g @inditex/api-cli
# Verify an API specification
apicli verify-file openapi-rest.yml
# Get full API scoring report
apicli verifyPlace your WSO2 API archive in the project:
my-api-project/
βββ admin-PizzaShackAPI-1.0.0.zip
The extension will automatically detect and analyze the API.
- Podman: For container orchestration and services
- VS Code CLI: For extension installation
- Health Checks: Automatic service verification
- Logs: Container log visualization
# View active containers
podman ps --filter "name=api-scoring"
# View frontend logs
podman logs -f api-scoring-frontend
# View backend logs
podman logs -f api-scoring-engine_scoring-api_1# Stop and remove all containers
podman rm -f $(podman ps -aq --filter 'name=api-scoring')
# Remove images
podman rmi $(podman images --filter 'reference=*api-scoring*' -q)
# Remove volumes
podman volume prune -f
# Uninstall VS Code extension
code --uninstall-extension inditextech.apiscoring- Podman installed and running
- VS Code CLI installed (optional, for automatic extension installation)
- Ports 3001 and 8080 available

