Skip to content

A tool to extract table and column information from an MS SQL server and convert it to OpenAPI3 schemas

License

Notifications You must be signed in to change notification settings

caligo-erik/MSSqlToOpenApi3Schemas

Repository files navigation

Caligo.SqlToOpenApi3Schemas

This is a command-line tool that extracts schema information from a Microsoft SQL Server database and generates the schemas.yaml to be used in an OpenAPI 3 specification.

Bugs

Please report any bugs on Github: https://github.com/caligo-erik/MSSqlToOpenApi3Schemas/issues

Usage

Once Caligo.SqlToOpenApi3Schemas is installed, you can use it from the command line as follows:

SqlToOpenApi3Schemas -c "your-connection-string"

Optional parameters

Database schema

You can specify a specific database schema, and the extractor will only extract the schema information for the specified schema:

SqlToOpenApi3Schemas -c "your-connection-string" -s your-schema

If no schema is specified, the default schema assigned to the login will be used, typically dbo.

Output path

You can also specify the output path for the schemas.yaml file:

SqlToOpenApi3Schemas -c "your-connection-string" -o outputPath

CRUD paths

You can specify the fileName and prefix for the crud paths

SqlToOpenApi3Schemas -c "your-connection-string" --pathPrefix /api/data --paths pathsFileName

About

A tool to extract table and column information from an MS SQL server and convert it to OpenAPI3 schemas

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages