We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is your feature request related to a problem? Please describe. Create a JSON Schema to ease JSON based API development
Starting point:
{ "$schema": "https://www.github.com/deejaytc/net-dynamic-api/apidefinition-schema.json", "$id": "https://www.github.com/deejaytc/net-dynamic-api/apidefinition-schema.json", "type": "array", "default": [], "items": { "type": "object", "title": "API Definition for a single class", "required": [ "name", "route", "idType", "Fields" ], "properties": { "name": { "type": "string", "title": "Name of the class", "examples": [ "Make", "Car" ], "pattern": "^[a-zA-Z]+$" }, "route": { "type": "string", "title": "Api route ie /students for the class", "examples": [ "/make", "/cars" ] }, "idType": { "type": "string", "title": "Type of primary key, allows string, int and guid", "examples": [ "int" ], "oneOf": [ {"enum": ["int", "string", "guid"]} ] }, "Fields": { "type": "array", "title": "The Fields Schema", "items": { "type": "object", "title": "A Schema", "required": [ "name", "type" ], "properties": { "name": { "type": "string", "title": "The name Schema", "examples": [ "Name", "Description", "Year", "Make", "MakeId" ] }, "type": { "type": "string", "title": "The type Schema", "description": "Any compilable type", "examples": [ "String", "int", "virtual Make", "List<Make>" ] } }, "examples": [{ "name": "Name", "type": "String" }, { "name": "Description", "type": "String" }, { "name": "Year", "type": "int" }, { "name": "Name", "type": "String" }, { "name": "Description", "type": "String" }, { "name": "Year", "type": "int" }, { "name": "Make", "type": "virtual Make" }, { "name": "MakeId", "type": "int" }] }, "examples": [ [{ "name": "Name", "type": "String" }, { "name": "Description", "type": "String" }, { "name": "Year", "type": "int" }], [{ "name": "Name", "type": "String" }, { "name": "Description", "type": "String" }, { "name": "Year", "type": "int" }, { "name": "Make", "type": "virtual Make" }, { "name": "MakeId", "type": "int" }] ] } }, "examples": [{ "name": "Make", "route": "/make", "idType": "int", "Fields": [{ "name": "Name", "type": "String" }, { "name": "Description", "type": "String" }, { "name": "Year", "type": "int" }] }, { "name": "Car", "route": "/cars", "idType": "int", "Fields": [{ "name": "Name", "type": "String" }, { "name": "Description", "type": "String" }, { "name": "Year", "type": "int" }, { "name": "Make", "type": "virtual Make" }, { "name": "MakeId", "type": "int" }] }] }, "examples": [ [{ "name": "Make", "route": "/make", "idType": "int", "Fields": [{ "name": "Name", "type": "String" }, { "name": "Description", "type": "String" }, { "name": "Year", "type": "int" }] }, { "name": "Car", "route": "/cars", "idType": "int", "Fields": [{ "name": "Name", "type": "String" }, { "name": "Description", "type": "String" }, { "name": "Year", "type": "int" }, { "name": "Make", "type": "virtual Make" }, { "name": "MakeId", "type": "int" }] }] ] }
The text was updated successfully, but these errors were encountered:
DeeJayTC
No branches or pull requests
Is your feature request related to a problem? Please describe.
Create a JSON Schema to ease JSON based API development
Starting point:
The text was updated successfully, but these errors were encountered: