-
Notifications
You must be signed in to change notification settings - Fork 285
Commit a090e37
[MCP] Fixes and Refactoring execute_entity (#2902)
## Why make this change?
### Closes on
- `execute_entity` #2831
## What is this change?
This PR implements built-int tool execute_entity as part of built-in
tools to support execution of stored procedures or functions.
- Performs execute operation on a stored procedure or function entity
- Supports both querying and mutation
- `entity` (required) name and `parameters` (optional based on entity
parameters signature) should be specified (see sample below)
- Operation is performed based on permissions as configured in
dab-config
- Success or Failure message response is generated on execution of the
delete operation
## How was this tested?
- [ ] Manual functional test using MCP inpector/HTTP client
- [ ] Integration Tests
- [ ] Unit Tests
## Sample Request(s)
Execute stored procedure to read queries-
```
POST http://localhost:5000/mcp
{
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"name": "execute_entity",
"arguments": {
"entity": "GetBook",
"parameters": {
"id": 1
}
}
}
}
```
Execute stored procedure without parameters-
```
POST http://localhost:5000/mcp
{
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"name": "execute_entity",
"arguments": {
"entity": "GetBooks"
}
}
}
```
---------
Co-authored-by: Copilot <[email protected]>1 parent cbd3b7c commit a090e37Copy full SHA for a090e37
File tree
Expand file treeCollapse file tree
1 file changed
+453
-0
lines changedOpen diff view settings
Filter options
- src/Azure.DataApiBuilder.Mcp/BuiltInTools
Expand file treeCollapse file tree
1 file changed
+453
-0
lines changedOpen diff view settings
0 commit comments