Load Api
Validate Specification
Validating Your API Specification
Validating your API specification is an essential step to ensure its accuracy and compliance with standards. Vaktum provides comprehensive validation tools for both OpenAPI and gRPC definitions.
Validation Benefits
- Detect Errors Early: Identify and fix specification issues before they impact your API consumers
- Ensure Compliance: Verify that your API adheres to industry standards and best practices
- Improve Quality: Enhance the overall quality and consistency of your API documentation
Validating via Vaktum CLI
The quickest way to validate your OpenAPI specification is through the Vaktum CLI:
🖥️ Shell
vaktum validate --api <Path to your OpenAPI file>
This command performs a comprehensive validation and reports any issues found in your specification.
Validating via Vaktum.com
- Navigate to the APIs section of Vaktum.com
- Select your API from the list or upload a new one
- Go to the "Validate" tab
- Review the validation results, which include:
- Syntax errors
- Semantic inconsistencies
- Best practice recommendations
- Security considerations
Validation via Vaktum API
You can programmatically validate your API specification using the Vaktum API:
🖥️ Shell
curl -X POST "https://api.vaktum.com/v1/apis/validate" \
-H "X-API-KEY: your-api-key" \
-H "Content-Type: application/json" \
-d '{"file": "base64-encoded-api-specification"}'
What We Validate
Vaktum's validation includes checks for:
- Syntax Validation: Ensures your specification follows the correct format and structure
- Reference Resolution: Verifies that all references in your specification are valid and can be resolved
- Schema Consistency: Checks that your data schemas are consistent and well-formed
- Operation Validity: Validates that API operations are properly defined
- Security Definitions: Ensures security schemes are correctly specified
- Endpoint Uniqueness: Checks for duplicate endpoints or operations
- Parameter Consistency: Verifies that parameters are consistently defined across operations
Interactive Validation Results
On Vaktum.com, validation results are presented in an interactive format that allows you to:
- Filter issues by severity (errors, warnings, information)
- Jump directly to the problematic section in your specification
- Get detailed explanations and recommendations for each issue
- Apply suggested fixes with a single click