-
Notifications
You must be signed in to change notification settings - Fork 324
Open
Description
What?
When DAB is not strict it no longer requires NoAutoPk or NoPk types in OpenAPI.
- This is misleading to tooling that doesn't realize these useless types are not required.
- This also multiplies the size of the OpenAPI document, 2x for every entity.
Configuration
{
"$schema": "https://github.com/Azure/data-api-builder/releases/download/vmajor.minor.patch/dab.draft.schema.json",
"data-source": {
"database-type": "mssql",
"connection-string": "@env('MSSQL_CONNECTION_STRING')",
"options": {
"set-session-context": false
}
},
"runtime": {
"telemetry": {
"log-level": {
"Default": "information"
}
},
"rest": {
"enabled": true,
"path": "/api",
"request-body-strict": false // set to false
},
"graphql": {
"enabled": true,
"path": "/graphql",
"allow-introspection": true
},
"mcp": {
"enabled": true,
"path": "/mcp"
},
"host": {
"cors": {
"origins": [],
"allow-credentials": false
},
"authentication": {
"provider": "Unauthenticated"
},
"mode": "development"
}
},
"autoentities": {
"default": {
"patterns": {
"include": [
"%.%%"
]
},
"permissions": [
{
"role": "anonymous",
"actions": [
{
"action": "*"
}
]
}
]
}
},
"entities": {}
}OpenAPI
{
"openapi": "3.0.1",
"info": {
"title": "Data API builder - REST Endpoint - anonymous",
"version": "2.0.0"
},
[snip]
"components": {
"schemas": {
"Todo": {
"type": "object",
"properties": {
"id": {
"type": "number",
"format": ""
},
"title": {
"type": "string",
"format": ""
},
"completed": {
"type": "boolean",
"format": ""
}
}
},
"Todo_NoAutoPK": { // should not exist
"type": "object",
"properties": {
"title": {
"type": "string",
"format": ""
},
"completed": {
"type": "boolean",
"format": ""
}
}
},
"Todo_NoPK": { // should not exist
"type": "object",
"properties": {
"title": {
"type": "string",
"format": ""
},
"completed": {
"type": "boolean",
"format": ""
}
}
}
}
},
"tags": [
{
"name": "Todo"
}
]
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Type
Projects
Status
Todo