- GET /api/v1/actions (discovery, 47 actions), GET /api/v1/actions/:id (contract) - POST /api/v1/actions/:actionId (unified execute via Action Runtime) - GET /api/v1/v2/resources (resource discovery) - legacy bridge wraps WorkspaceAction.run into execute (fixed registration) - ActionContext.organizationId used by legacy bridge for workspace scoping
17 lines
412 B
TypeScript
17 lines
412 B
TypeScript
/**
|
||
* # Resource Discovery 控制器(docs 03 §90;/api/v1/v2/resources)
|
||
*/
|
||
import { Controller, Get } from "@nestjs/common";
|
||
import { ActionRuntime } from "../runtime/action-runtime";
|
||
|
||
@Controller("v2/resources")
|
||
export class V2ResourcesController {
|
||
constructor(private readonly runtime: ActionRuntime) {}
|
||
|
||
/** # 资源发现 */
|
||
@Get()
|
||
list() {
|
||
return this.runtime.discoverResources();
|
||
}
|
||
}
|