yakupbeyoglu / ForgeAPI

ForgeAPI is a powerful and automated C++ tool(compiler) designed to streamline the process of building RESTful APIs from structured JSON inputs.
MIT License
2 stars 0 forks source link

Syntax analysis #3

Open yakupbeyoglu opened 8 hours ago

yakupbeyoglu commented 8 hours ago

Syntax Analysis Checklist for JSON Structure

Example json can be found at https://github.com/yakupbeyoglu/ForgeAPI/issues/2#issue-2540546808

1. Overall Structure

2. Table Definition

3. Fields Array

4. Relations Array

5. Routes Array

6. Middleware Array

7. Authorization Groups

Validation Steps

  1. Check Required Fields: Ensure all required fields are present and correctly formatted.
  2. Validate Data Types: Confirm that data types match the expected types for each field.
  3. Verify Constraints: Check constraints such as field lengths and foreign key relationships.
  4. Handle Nested Structures: Validate the structure and content of nested arrays and objects.
  5. Error Handling: Report errors with details on missing fields, incorrect types, and structural issues.