@babamba2/abap-mcp-adt-powerup 4.8.13 → 4.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +122 -0
- package/README.md +2 -2
- package/dist/handlers/adobeform/high/handleCreateAdobeFormFromSmartForm.d.ts +50 -0
- package/dist/handlers/adobeform/high/handleCreateAdobeFormFromSmartForm.d.ts.map +1 -0
- package/dist/handlers/adobeform/high/handleCreateAdobeFormFromSmartForm.js +58 -0
- package/dist/handlers/adobeform/high/handleCreateAdobeFormFromSmartForm.js.map +1 -0
- package/dist/handlers/business/handleBusinessActions.d.ts +134 -0
- package/dist/handlers/business/handleBusinessActions.d.ts.map +1 -0
- package/dist/handlers/business/handleBusinessActions.js +186 -0
- package/dist/handlers/business/handleBusinessActions.js.map +1 -0
- package/dist/handlers/data_element/high/handleCreateDataElement.d.ts.map +1 -1
- package/dist/handlers/data_element/high/handleCreateDataElement.js +2 -2
- package/dist/handlers/data_element/high/handleCreateDataElement.js.map +1 -1
- package/dist/handlers/data_element/high/handleDeleteDataElement.d.ts.map +1 -1
- package/dist/handlers/data_element/high/handleDeleteDataElement.js +2 -2
- package/dist/handlers/data_element/high/handleDeleteDataElement.js.map +1 -1
- package/dist/handlers/data_element/high/handleGetDataElement.js +1 -1
- package/dist/handlers/data_element/high/handleGetDataElement.js.map +1 -1
- package/dist/handlers/data_element/high/handleUpdateDataElement.d.ts.map +1 -1
- package/dist/handlers/data_element/high/handleUpdateDataElement.js +2 -2
- package/dist/handlers/data_element/high/handleUpdateDataElement.js.map +1 -1
- package/dist/handlers/domain/high/handleCreateDomain.d.ts.map +1 -1
- package/dist/handlers/domain/high/handleCreateDomain.js +2 -2
- package/dist/handlers/domain/high/handleCreateDomain.js.map +1 -1
- package/dist/handlers/domain/high/handleDeleteDomain.d.ts.map +1 -1
- package/dist/handlers/domain/high/handleDeleteDomain.js +2 -2
- package/dist/handlers/domain/high/handleDeleteDomain.js.map +1 -1
- package/dist/handlers/domain/high/handleGetDomain.js +1 -1
- package/dist/handlers/domain/high/handleGetDomain.js.map +1 -1
- package/dist/handlers/domain/high/handleUpdateDomain.d.ts.map +1 -1
- package/dist/handlers/domain/high/handleUpdateDomain.js +2 -2
- package/dist/handlers/domain/high/handleUpdateDomain.js.map +1 -1
- package/dist/handlers/enhancement/readonly/handleGetBadiImplementations.js +1 -1
- package/dist/handlers/enhancement/readonly/handleGetBadiImplementations.js.map +1 -1
- package/dist/handlers/gui_status/high/handleGetGuiStatus.d.ts +14 -2
- package/dist/handlers/gui_status/high/handleGetGuiStatus.d.ts.map +1 -1
- package/dist/handlers/gui_status/high/handleGetGuiStatus.js +24 -11
- package/dist/handlers/gui_status/high/handleGetGuiStatus.js.map +1 -1
- package/dist/handlers/interface/high/handleUpdateInterface.d.ts.map +1 -1
- package/dist/handlers/interface/high/handleUpdateInterface.js +5 -3
- package/dist/handlers/interface/high/handleUpdateInterface.js.map +1 -1
- package/dist/handlers/program/readonly/handleGetProgFullCode.d.ts.map +1 -1
- package/dist/handlers/program/readonly/handleGetProgFullCode.js +37 -3
- package/dist/handlers/program/readonly/handleGetProgFullCode.js.map +1 -1
- package/dist/handlers/program/readonly/handleReadProgram.d.ts +1 -1
- package/dist/handlers/program/readonly/handleReadProgram.d.ts.map +1 -1
- package/dist/handlers/program/readonly/handleReadProgram.js +32 -1
- package/dist/handlers/program/readonly/handleReadProgram.js.map +1 -1
- package/dist/handlers/search/readonly/handleSearchObject.d.ts +20 -0
- package/dist/handlers/search/readonly/handleSearchObject.d.ts.map +1 -1
- package/dist/handlers/search/readonly/handleSearchObject.js +115 -0
- package/dist/handlers/search/readonly/handleSearchObject.js.map +1 -1
- package/dist/handlers/structure/high/handleCreateStructure.d.ts +23 -0
- package/dist/handlers/structure/high/handleCreateStructure.d.ts.map +1 -1
- package/dist/handlers/structure/high/handleCreateStructure.js +168 -0
- package/dist/handlers/structure/high/handleCreateStructure.js.map +1 -1
- package/dist/handlers/structure/high/handleDeleteStructure.d.ts.map +1 -1
- package/dist/handlers/structure/high/handleDeleteStructure.js +25 -1
- package/dist/handlers/structure/high/handleDeleteStructure.js.map +1 -1
- package/dist/handlers/structure/high/handleGetStructure.js +1 -1
- package/dist/handlers/structure/high/handleGetStructure.js.map +1 -1
- package/dist/handlers/system/readonly/handleGetAdobeFormContent.d.ts +53 -0
- package/dist/handlers/system/readonly/handleGetAdobeFormContent.d.ts.map +1 -0
- package/dist/handlers/system/readonly/handleGetAdobeFormContent.js +67 -0
- package/dist/handlers/system/readonly/handleGetAdobeFormContent.js.map +1 -0
- package/dist/handlers/system/readonly/handleGetAreaMenu.d.ts +80 -0
- package/dist/handlers/system/readonly/handleGetAreaMenu.d.ts.map +1 -0
- package/dist/handlers/system/readonly/handleGetAreaMenu.js +383 -0
- package/dist/handlers/system/readonly/handleGetAreaMenu.js.map +1 -0
- package/dist/handlers/system/readonly/handleGetJobUsage.js +1 -1
- package/dist/handlers/system/readonly/handleGetJobUsage.js.map +1 -1
- package/dist/handlers/system/readonly/handleGetSqlQuery.d.ts +12 -0
- package/dist/handlers/system/readonly/handleGetSqlQuery.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleGetSqlQuery.js +75 -2
- package/dist/handlers/system/readonly/handleGetSqlQuery.js.map +1 -1
- package/dist/handlers/system/readonly/handleGetTcodeUsage.js +1 -1
- package/dist/handlers/system/readonly/handleGetTcodeUsage.js.map +1 -1
- package/dist/handlers/system/readonly/handleReloadProfile.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleReloadProfile.js +5 -0
- package/dist/handlers/system/readonly/handleReloadProfile.js.map +1 -1
- package/dist/handlers/system/readonly/handleRenderAdobeForm.d.ts +58 -0
- package/dist/handlers/system/readonly/handleRenderAdobeForm.d.ts.map +1 -0
- package/dist/handlers/system/readonly/handleRenderAdobeForm.js +71 -0
- package/dist/handlers/system/readonly/handleRenderAdobeForm.js.map +1 -0
- package/dist/handlers/system/readonly/handleRenderSmartForm.d.ts +1 -1
- package/dist/handlers/system/readonly/handleRenderSmartForm.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleRenderSmartForm.js +3 -36
- package/dist/handlers/system/readonly/handleRenderSmartForm.js.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeAnalyzeDump.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeAnalyzeDump.js +2 -3
- package/dist/handlers/system/readonly/handleRuntimeAnalyzeDump.js.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeGetDumpById.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeGetDumpById.js +2 -3
- package/dist/handlers/system/readonly/handleRuntimeGetDumpById.js.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeListDumps.d.ts +30 -1
- package/dist/handlers/system/readonly/handleRuntimeListDumps.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeListDumps.js +127 -2
- package/dist/handlers/system/readonly/handleRuntimeListDumps.js.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeListFeeds.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeListFeeds.js +10 -0
- package/dist/handlers/system/readonly/handleRuntimeListFeeds.js.map +1 -1
- package/dist/handlers/table/high/handleCreateTable.d.ts +85 -2
- package/dist/handlers/table/high/handleCreateTable.d.ts.map +1 -1
- package/dist/handlers/table/high/handleCreateTable.js +78 -15
- package/dist/handlers/table/high/handleCreateTable.js.map +1 -1
- package/dist/handlers/table/high/handleCreateTableEcc.d.ts +46 -0
- package/dist/handlers/table/high/handleCreateTableEcc.d.ts.map +1 -0
- package/dist/handlers/table/high/handleCreateTableEcc.js +180 -0
- package/dist/handlers/table/high/handleCreateTableEcc.js.map +1 -0
- package/dist/handlers/table/high/handleDeleteTable.d.ts.map +1 -1
- package/dist/handlers/table/high/handleDeleteTable.js +2 -2
- package/dist/handlers/table/high/handleDeleteTable.js.map +1 -1
- package/dist/handlers/table/high/handleGetTable.js +1 -1
- package/dist/handlers/table/high/handleGetTable.js.map +1 -1
- package/dist/handlers/table/readonly/handleGetRemoteTableContents.d.ts +48 -0
- package/dist/handlers/table/readonly/handleGetRemoteTableContents.d.ts.map +1 -0
- package/dist/handlers/table/readonly/handleGetRemoteTableContents.js +272 -0
- package/dist/handlers/table/readonly/handleGetRemoteTableContents.js.map +1 -0
- package/dist/handlers/table_type/high/handleCreateTableType.d.ts +106 -0
- package/dist/handlers/table_type/high/handleCreateTableType.d.ts.map +1 -0
- package/dist/handlers/table_type/high/handleCreateTableType.js +251 -0
- package/dist/handlers/table_type/high/handleCreateTableType.js.map +1 -0
- package/dist/handlers/table_type/high/handleDeleteTableType.d.ts +37 -0
- package/dist/handlers/table_type/high/handleDeleteTableType.d.ts.map +1 -0
- package/dist/handlers/table_type/high/handleDeleteTableType.js +62 -0
- package/dist/handlers/table_type/high/handleDeleteTableType.js.map +1 -0
- package/dist/handlers/text_element/high/handleReadTextElementsBulk.d.ts +12 -0
- package/dist/handlers/text_element/high/handleReadTextElementsBulk.d.ts.map +1 -1
- package/dist/handlers/text_element/high/handleReadTextElementsBulk.js +16 -1
- package/dist/handlers/text_element/high/handleReadTextElementsBulk.js.map +1 -1
- package/dist/handlers/text_element/high/handleWriteTextElementsBulk.d.ts +22 -7
- package/dist/handlers/text_element/high/handleWriteTextElementsBulk.d.ts.map +1 -1
- package/dist/handlers/text_element/high/handleWriteTextElementsBulk.js +37 -14
- package/dist/handlers/text_element/high/handleWriteTextElementsBulk.js.map +1 -1
- package/dist/lib/adobeForm.d.ts +115 -0
- package/dist/lib/adobeForm.d.ts.map +1 -0
- package/dist/lib/adobeForm.js +315 -0
- package/dist/lib/adobeForm.js.map +1 -0
- package/dist/lib/bizRfc.d.ts +35 -0
- package/dist/lib/bizRfc.d.ts.map +1 -0
- package/dist/lib/bizRfc.js +115 -0
- package/dist/lib/bizRfc.js.map +1 -0
- package/dist/lib/config/ArgumentsParser.d.ts +0 -1
- package/dist/lib/config/ArgumentsParser.d.ts.map +1 -1
- package/dist/lib/config/ArgumentsParser.js +5 -3
- package/dist/lib/config/ArgumentsParser.js.map +1 -1
- package/dist/lib/config/IServerConfig.d.ts +0 -2
- package/dist/lib/config/IServerConfig.d.ts.map +1 -1
- package/dist/lib/config/ServerConfigManager.d.ts.map +1 -1
- package/dist/lib/config/ServerConfigManager.js +0 -8
- package/dist/lib/config/ServerConfigManager.js.map +1 -1
- package/dist/lib/config.d.ts.map +1 -1
- package/dist/lib/config.js +2 -5
- package/dist/lib/config.js.map +1 -1
- package/dist/lib/connectionType.d.ts +14 -0
- package/dist/lib/connectionType.d.ts.map +1 -0
- package/dist/lib/connectionType.js +21 -0
- package/dist/lib/connectionType.js.map +1 -0
- package/dist/lib/cuaFilter.d.ts +38 -0
- package/dist/lib/cuaFilter.d.ts.map +1 -0
- package/dist/lib/cuaFilter.js +132 -0
- package/dist/lib/cuaFilter.js.map +1 -0
- package/dist/lib/handlers/groups/HighLevelHandlersGroup.d.ts.map +1 -1
- package/dist/lib/handlers/groups/HighLevelHandlersGroup.js +15 -0
- package/dist/lib/handlers/groups/HighLevelHandlersGroup.js.map +1 -1
- package/dist/lib/handlers/groups/ReadOnlyHandlersGroup.d.ts.map +1 -1
- package/dist/lib/handlers/groups/ReadOnlyHandlersGroup.js +20 -0
- package/dist/lib/handlers/groups/ReadOnlyHandlersGroup.js.map +1 -1
- package/dist/lib/handlers/groups/SystemHandlersGroup.d.ts.map +1 -1
- package/dist/lib/handlers/groups/SystemHandlersGroup.js +18 -0
- package/dist/lib/handlers/groups/SystemHandlersGroup.js.map +1 -1
- package/dist/lib/handlers/interfaces.d.ts +17 -0
- package/dist/lib/handlers/interfaces.d.ts.map +1 -1
- package/dist/lib/handlers/interfaces.js +16 -0
- package/dist/lib/handlers/interfaces.js.map +1 -1
- package/dist/lib/legacyDumps.d.ts +95 -0
- package/dist/lib/legacyDumps.d.ts.map +1 -0
- package/dist/lib/legacyDumps.js +183 -0
- package/dist/lib/legacyDumps.js.map +1 -0
- package/dist/lib/legacyTableRead.js +2 -2
- package/dist/lib/legacyTableRead.js.map +1 -1
- package/dist/lib/ncoRfc.d.ts +46 -0
- package/dist/lib/ncoRfc.d.ts.map +1 -0
- package/dist/lib/ncoRfc.js +175 -0
- package/dist/lib/ncoRfc.js.map +1 -0
- package/dist/lib/odataRfc.d.ts +9 -2
- package/dist/lib/odataRfc.d.ts.map +1 -1
- package/dist/lib/odataRfc.js +10 -1
- package/dist/lib/odataRfc.js.map +1 -1
- package/dist/lib/policy/tableBlocklist.d.ts +5 -1
- package/dist/lib/policy/tableBlocklist.d.ts.map +1 -1
- package/dist/lib/policy/tableBlocklist.js +53 -4
- package/dist/lib/policy/tableBlocklist.js.map +1 -1
- package/dist/lib/profile.d.ts.map +1 -1
- package/dist/lib/profile.js +19 -2
- package/dist/lib/profile.js.map +1 -1
- package/dist/lib/readonlyGuard.d.ts +3 -0
- package/dist/lib/readonlyGuard.d.ts.map +1 -1
- package/dist/lib/readonlyGuard.js +20 -0
- package/dist/lib/readonlyGuard.js.map +1 -1
- package/dist/lib/removedTransports.d.ts +17 -0
- package/dist/lib/removedTransports.d.ts.map +1 -0
- package/dist/lib/removedTransports.js +45 -0
- package/dist/lib/removedTransports.js.map +1 -0
- package/dist/lib/rfcBackend.d.ts +17 -15
- package/dist/lib/rfcBackend.d.ts.map +1 -1
- package/dist/lib/rfcBackend.js +49 -41
- package/dist/lib/rfcBackend.js.map +1 -1
- package/dist/lib/sapLanguage.d.ts +7 -0
- package/dist/lib/sapLanguage.d.ts.map +1 -0
- package/dist/lib/sapLanguage.js +58 -0
- package/dist/lib/sapLanguage.js.map +1 -0
- package/dist/lib/smartFormContent.d.ts +6 -0
- package/dist/lib/smartFormContent.d.ts.map +1 -1
- package/dist/lib/smartFormContent.js +19 -2
- package/dist/lib/smartFormContent.js.map +1 -1
- package/dist/lib/soapRfc.d.ts.map +1 -1
- package/dist/lib/soapRfc.js +3 -0
- package/dist/lib/soapRfc.js.map +1 -1
- package/dist/lib/sourceOutput.d.ts +14 -0
- package/dist/lib/sourceOutput.d.ts.map +1 -1
- package/dist/lib/sourceOutput.js +103 -3
- package/dist/lib/sourceOutput.js.map +1 -1
- package/dist/lib/utils.d.ts +0 -5
- package/dist/lib/utils.d.ts.map +1 -1
- package/dist/lib/utils.js +17 -6
- package/dist/lib/utils.js.map +1 -1
- package/dist/lib/valuesFile.d.ts +6 -0
- package/dist/lib/valuesFile.d.ts.map +1 -0
- package/dist/lib/valuesFile.js +127 -0
- package/dist/lib/valuesFile.js.map +1 -0
- package/dist/server/BaseMcpServer.d.ts.map +1 -1
- package/dist/server/BaseMcpServer.js +13 -9
- package/dist/server/BaseMcpServer.js.map +1 -1
- package/dist/server/launcher.js +12 -14
- package/dist/server/launcher.js.map +1 -1
- package/docs/configuration/YAML_CONFIG.md +0 -17
- package/docs/development/roadmaps/TRANSPORT_CRUD_ISSUE_11.md +2 -0
- package/docs/roadmaps/LEGACY_SUPPORT.md +2 -0
- package/docs/user-guide/AVAILABLE_TOOLS.md +142 -12
- package/docs/user-guide/AVAILABLE_TOOLS_COMPACT.md +1 -1
- package/docs/user-guide/AVAILABLE_TOOLS_HIGH.md +75 -7
- package/docs/user-guide/AVAILABLE_TOOLS_LEGACY.md +68 -10
- package/docs/user-guide/AVAILABLE_TOOLS_LOW.md +1 -1
- package/docs/user-guide/AVAILABLE_TOOLS_READONLY.md +67 -5
- package/docs/user-guide/CLI_OPTIONS.md +1 -40
- package/package.json +3 -4
- package/dist/lib/gatewayRfc.d.ts +0 -47
- package/dist/lib/gatewayRfc.d.ts.map +0 -1
- package/dist/lib/gatewayRfc.js +0 -138
- package/dist/lib/gatewayRfc.js.map +0 -1
- package/dist/lib/nativeRfc.d.ts +0 -39
- package/dist/lib/nativeRfc.d.ts.map +0 -1
- package/dist/lib/nativeRfc.js +0 -165
- package/dist/lib/nativeRfc.js.map +0 -1
- package/dist/lib/zrfcProxy.d.ts +0 -59
- package/dist/lib/zrfcProxy.d.ts.map +0 -1
- package/dist/lib/zrfcProxy.js +0 -252
- package/dist/lib/zrfcProxy.js.map +0 -1
- package/docs/installation/RFC_SETUP.md +0 -101
- package/docs/installation/ZRFC_SETUP.md +0 -162
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,128 @@
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [4.13.0] - 2026-11-17
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
- **Adobe forms (SFP)**. These need the DEV helper `ZMCP_FP_CONTENT` and its dispatcher actions (sc4sap `abap/`). A system without them gets an install hint.
|
|
11
|
+
- **`GetAdobeFormContent`** (read-only): the form XML, the layout XDP and the interface XML of one form, written under the MCP output directory (`adobe/<form>/`). The name is checked before any call. `include_check` (off by default) adds SAP's own form check messages (`<form>.check.json`).
|
|
12
|
+
- **`RenderAdobeForm`** (runs the form, no output): the PDF that ADS produces for given interface values, with no spool and no device. `get_xml` also returns the data XML the form hands ADS; SmartForm-type interfaces have none. It is refused on QA and PRD.
|
|
13
|
+
- **`CreateAdobeFormFromSmartForm`** (DEV write, high-level group): SAP's own SmartForm → Adobe migration (`FP_MIGRATE`) into new `ZSC4SAP_AFM_*` names in `$TMP`. It never overwrites an existing name. The result reports `complete`, SAP's messages, the context nodes it renamed (duplicate sibling names), the layout `cacheInfo`, and what it `adjusted`. An optional `sender_country` is passed through.
|
|
14
|
+
- Tool docs regenerated (342 tools).
|
|
15
|
+
|
|
16
|
+
### Changed
|
|
17
|
+
- **`values_file`** (`RenderSmartForm`, `RenderAdobeForm`): the file must be inside the MCP output directory or `.sc4sap/work/<alias>`, checked on its real path.
|
|
18
|
+
- Links and junctions out, UNC paths and secret-like names are refused before the file is read.
|
|
19
|
+
- Only `.json` up to 1 MB is accepted.
|
|
20
|
+
- A missing file and a refused one get the same answer, so the answer does not reveal whether an outside file exists.
|
|
21
|
+
- Output paths are checked on the real path of the existing parent (all output tools).
|
|
22
|
+
- **`GetSmartFormContent`** symbols: `<(>…<)>` protected text is skipped, `&'pre'NAME'post'&` yields `NAME`, and comment lines are ignored.
|
|
23
|
+
- **Table blocklist**: every table of a `FROM` list is checked (commas, aliases, brackets). `AGR_1016` and `AGR_TIMEB` join the role tables in the minimal blocklist.
|
|
24
|
+
|
|
25
|
+
## [4.12.1] - 2026-11-16
|
|
26
|
+
|
|
27
|
+
### Fixed
|
|
28
|
+
- **`RuntimeListDumps`** follows the feed's time cursor (`to=`) back to `date_from` instead of stopping at the first page, so a week of dumps on S/4HANA (the feed returns about 100 per page) is complete. The answer carries `paging: { pages, complete, reached, oldest }`; `complete: false` says the page cap stopped it before `date_from`.
|
|
29
|
+
|
|
30
|
+
## [4.12.0] - 2026-11-13
|
|
31
|
+
|
|
32
|
+
### Added
|
|
33
|
+
- **`GetRemoteTableContents`** (read-only). Reads rows of one table in another SAP system through an SM59 ABAP destination with the standard `RFC_READ_TABLE`, for realistic test data. Calls the new dispatcher action `REMOTE_READ` (sc4sap `abap/zmcp_adt_dispatch*.abap`); a system whose dispatcher lacks it gets an upload hint. The destination is never guessed: without it the tool lists the destinations saved for the active profile (`config.json` → `remoteDestinations`, most recent first, max 10); a destination is saved after its first successful read. `where` is split into 72-character option lines without cutting quoted literals; `fields`, `max_rows` (default 100, cap 5000), `skip_rows`. Business tables are allowed; the table blocklist applies, and the ABAP side refuses credential / user / authorization tables and sub-queries.
|
|
34
|
+
- Tool docs regenerated (also adds `CreateTableType` / `DeleteTableType`, missing since 4.9.1).
|
|
35
|
+
|
|
36
|
+
## [4.11.0] - 2026-11-11
|
|
37
|
+
|
|
38
|
+
### Added
|
|
39
|
+
- **NCo RFC backend `SAP_RFC_BACKEND=nco`** (Windows, SAP .NET Connector 3.x). The sc4sap helper FMs are called over RFC — no OData service, no SOAP ICF node. It reuses the OData backend's functions: their single transport point (`postFunctionImport`) sends the same FunctionImport and `IV_*` parameters to the FM over NCo (`lib/ncoRfc.ts`). Remote-enabled FMs (`ZMCP_ADT_DISPATCH`, `_TEXTPOOL`, `_DDIC_TABL` / `DTEL` / `DOMA` / `ACTIVATE`) are called directly; the others (DDIC reads, `ZMCP_ADT_DDIC_TTYP`, `_BADI`, `ZMCP_WL_*`) through the new dispatcher action `FM_PROXY` (allow list, sc4sap `abap/zmcp_adt_dispatch*.abap`). Business actions go through the dispatcher (`BIZ_EXECUTE`). DDIC writes and reads on ECC accept `nco` next to `odata`.
|
|
40
|
+
- **NCo ADT connection `SAP_CONNECTION_TYPE=nco`**: ADT requests over `SADT_REST_RFC_ENDPOINT` through `@babamba2/mcp-abap-connection` 1.6.0 (`RfcAbapConnection`, now NCo-driven). Lock / write / unlock run in one RFC session. `SAP_CONNECTION_TYPE=rfc` stays removed.
|
|
41
|
+
- Keys `SAP_NCO_ASHOST`, `SAP_NCO_SYSNR` (default from the `SAP_URL` port 80XX), `SAP_NCO_LANG`, `SAP_NCO_BRIDGE_EXE`; cleared on a profile switch like `SAP_RFC_*`. Open NCo connections are closed when the connection cache is invalidated (ReloadProfile).
|
|
42
|
+
- ECC bridge replies report `path: "ecc-nco-rfc"` / "via NCo RFC" on the NCo backend; OData replies keep `ecc-odata-rfc` / "via OData".
|
|
43
|
+
|
|
44
|
+
### Changed
|
|
45
|
+
- Requires `@babamba2/mcp-abap-connection` ^1.6.0.
|
|
46
|
+
|
|
47
|
+
## [4.10.0] - 2026-11-11
|
|
48
|
+
|
|
49
|
+
### Removed
|
|
50
|
+
- **RFC backends `native`, `gateway` and `zrfc`** (`SAP_RFC_BACKEND`). Function modules are reached through `odata` (default) or `soap`. Files removed: `lib/nativeRfc.ts`, `lib/gatewayRfc.ts`, `lib/zrfcProxy.ts`, the ZRFC ICF handler `abap/zcl_mcp_rfc_http_handler.abap`, `docs/installation/ZRFC_SETUP.md`, their tests and the native parity suite. Business actions on `native` called `ZMCP_BIZ_EXECUTE` directly; `soap` still does, `odata` goes through the dispatcher.
|
|
51
|
+
- **RFC connection** `SAP_CONNECTION_TYPE=rfc` / `--connection-type=rfc` (ADT over node-rfc + SAP NW RFC SDK) and `docs/installation/RFC_SETUP.md`. The server connects over HTTP/HTTPS. `node-rfc` is no longer an optional dependency of this package.
|
|
52
|
+
|
|
53
|
+
### Changed
|
|
54
|
+
- A profile that still selects one of these fails at boot (exit 1) and on `ReloadProfile` with a message naming the fix (`SAP_RFC_BACKEND=odata` or `soap`; drop `SAP_CONNECTION_TYPE`), instead of running over another path (`lib/removedTransports.ts`).
|
|
55
|
+
|
|
56
|
+
## [4.9.1] - 2026-11-11
|
|
57
|
+
|
|
58
|
+
### Added
|
|
59
|
+
- **`CreateTableType` / `DeleteTableType`**. Row type is a structure, a data element or another table type (`row_kind`); `access_type`, `key_definition`, `key_kind`. S/4 goes through ADT. ECC goes through the new FM `ZMCP_ADT_DDIC_TTYP` (OData action `DdicTtyp`, sc4sap setup Step 9a.2); only ECC takes `key_components`. A hashed table type without a unique key is refused before any call to SAP.
|
|
60
|
+
- **`CreateTable` on ECC**: `fields`, `includes`, delivery class and data class are written as DD02V / DD03P / DD09L through `ZMCP_ADT_DDIC_TABL`, then activated.
|
|
61
|
+
- **`CreateStructure` on ECC** takes `structure_ref` and `includes`; **`DeleteStructure`** has an ECC branch.
|
|
62
|
+
- **`GetAreaMenu`** (read-only, on-premise). Reads an SE43 area menu (`TTREE` type `BMENU` → `TMENU01` / `TMENU01R` / `TMENU01T`) as a flat list: every transaction with its folder path and menu text, plus the folders and the links to other area menus. Links to customer menus (Z / Y / namespace) are followed by default (`follow_links`: `customer` | `all` | `none`). `menu_pattern` (e.g. `Z*`) lists the menus with master language and last change instead. Texts in the requested language fall back to the master language, then English; texts stored as `#` only are skipped. `output: "file"` writes the result to `<MCP output dir>/areamenu/<menu>-<time>.json`. Works on the ADT SQL path and on the legacy `TABLE_READ` path (ECC; reference rows are read in batches of 60 nodes).
|
|
63
|
+
|
|
64
|
+
### Docs
|
|
65
|
+
- Tool reference regenerated (`npm run docs:tools`): `GetAreaMenu`, plus descriptions that had drifted from the source (`ReadProgram`, `GetSqlQuery` `output`, `WriteTextElementsBulk` `activate`).
|
|
66
|
+
|
|
67
|
+
## [4.9.0] - 2026-11-10
|
|
68
|
+
|
|
69
|
+
### Added
|
|
70
|
+
- **Business-action tools** `ListBusinessActions`, `RunBusinessQuery` (QUERY or PRECHECK), `PreviewBusinessAction` (returns a one-time token) and `ExecuteBusinessAction` (token required). They call the RFC function module `ZMCP_BIZ_EXECUTE` (sc4sap `abap/biz/`): directly on the `soap` and `native` backends, through the new dispatcher action `BIZ_EXECUTE` on `odata` / `gateway` / `zrfc`. A refusal from SAP (subrc 4) is returned as content with `ok: false`, not as a tool error.
|
|
71
|
+
- **`SAP_TOOL_PROFILE`** = `dev` (default, development tools) | `biz` (business-action tools) | `all`. Tools declare `tool_profile`; untagged tools are `dev`.
|
|
72
|
+
|
|
73
|
+
### Security
|
|
74
|
+
- `PreviewBusinessAction` / `ExecuteBusinessAction` are blocked on PRD-tier profiles (readonly guard + handler); allowed on DEV and QA. SAP also refuses a production client and enforces the preview token.
|
|
75
|
+
|
|
76
|
+
## [4.8.19] - 2026-11-06
|
|
77
|
+
|
|
78
|
+
### Added
|
|
79
|
+
- **`GetSqlQuery` `output: "file"`.** The rows are written to `<MCP output dir>/sql/<table>-<time>.json` (with `sql_query`, `row_number`, `columns`) and the answer carries only `path`, `rows` and `truncated`. Works on the ADT path and on the legacy `TABLE_READ` path (ECC).
|
|
80
|
+
|
|
81
|
+
### Fixed
|
|
82
|
+
- **`GetProgFullCode` `output: "file"` on large function groups.** The answer listed every include with its absolute path and outline; a function group with 170–270 includes reached 54–94k characters, over the client's tool-result limit, so the client dropped the answer although every file had been written. The full listing now always goes to `<folder>/_index.json`, and the answer keeps under 40,000 characters: outlines are left out first (`outline_omitted`), then entries after the first carry only `file` instead of `path` (`paths_shortened`), and as a last resort the list is cut (`code_objects_truncated`). The answer now also carries `folder` and `index_path`. Measured on ECC function groups: 94,248 → 29,186, 58,324 → 39,903 characters.
|
|
83
|
+
|
|
84
|
+
## [4.8.18] - 2026-11-03
|
|
85
|
+
|
|
86
|
+
### Added
|
|
87
|
+
- **`CreateStructure` field args `reference_table` / `reference_field`** for CURR / QUAN fields on ECC. The reference table defaults to the structure itself when only `reference_field` is set.
|
|
88
|
+
|
|
89
|
+
### Fixed
|
|
90
|
+
- **`CreateStructure` on ECC.** ECC systems without the ADT DDIC structure endpoint now create the structure over RFC (`ZMCP_ADT_DDIC_TABL` CREATE with DD02V `INTTAB` + DD03P rows) and activate it with `DDIC_ACTIVATE`. A helper report is no longer needed. Checked on ECC 7.40.
|
|
91
|
+
|
|
92
|
+
## [4.8.17] - 2026-10-30
|
|
93
|
+
|
|
94
|
+
### Changed
|
|
95
|
+
- **`WriteTextElementsBulk`: `activate` defaults to `true`.** `activate: false` stages the text pool inactive, but the pool is not added to the inactive worklist, so activating the program afterwards does not promote it (checked on ECC 7.40). The tool description and the staged-rows message now say so.
|
|
96
|
+
|
|
97
|
+
### Fixed
|
|
98
|
+
- **Selection texts on S/4HANA.** A selection-text row keeps 8 reserved characters (position 1 = `D` for a DDIC reference) before the visible text. The S/4HANA RFC read drops these leading blanks on a non-DDIC row.
|
|
99
|
+
- `ReadTextElementsBulk` strips the prefix only when it is there, so the first 8 characters of the label are no longer cut off. Each selection carries `ddic_reference`.
|
|
100
|
+
- `WriteTextElementsBulk` writes the prefix on new selection texts and puts it back on existing rows during a merge (`replace_existing: false`), so labels do not shift in SE38. A selection text may be up to 124 characters.
|
|
101
|
+
- **`SearchObject` program titles.** Titles of program and include hits (`PROG/*`) are read from TRDIRT, in the logon language first, then English. ECC 7.40 quick search could pair a program with another object's title, and S/4HANA sent no title for programs. When the TRDIRT read fails, the search titles stay as they were.
|
|
102
|
+
- **`ReadProgram` reads includes.** A name that is not a program is retried under `/programs/includes/`; the result carries `object_type` (`PROG/P` or `PROG/I`). An unknown name now returns an error instead of success with empty fields.
|
|
103
|
+
|
|
104
|
+
## [4.8.16] - 2026-10-29
|
|
105
|
+
|
|
106
|
+
### Fixed
|
|
107
|
+
- **`MCP_ALLOW_TABLE` from the launching process survives the profile apply.** A script that starts its own server for one audited read (e.g. the PFCG role tables) sets `MCP_ALLOW_TABLE`; applying the active profile wiped it, so the read was blocked again. The launcher value is now kept and merged with the profile's own value on every apply; a previous profile's value is still dropped on a switch.
|
|
108
|
+
- The `TABLE_READ` "not allowed" hint on BASIS < 7.50 now lists delivery class W (readable since the 2026-10-28 dispatcher).
|
|
109
|
+
|
|
110
|
+
## [4.8.15] - 2026-10-28
|
|
111
|
+
|
|
112
|
+
### Added
|
|
113
|
+
- **ECC dumps older than 24 hours.** On ECC (BASIS 7.40 / 7.31) the ADT dump feed only returns the last 24 hours, whatever `from` is sent. `RuntimeListDumps` takes `date_from` / `date_to`, and when the range is older than 24 hours (or the feed is empty) both it and `RuntimeListFeeds(dumps)` add an `st22` block: the ST22 list for that range (date, time, host, user, client, runtime error, program, include, line, `dump_id`), from `ZMCP_ADT_DISPATCH` action `DUMP_LIST` (SNAP headers, decoded like `RS_ST22_GET_DUMPS`; needs ST22 display authorization). Without the action the answer carries an install hint.
|
|
114
|
+
|
|
115
|
+
### Changed
|
|
116
|
+
- `RuntimeGetDumpById` / `RuntimeAnalyzeDump` on ECC: the 404 for one dump (ECC has no ADT resource for it) now says how to get the facts — `include_summary` for the last 24 hours, the `st22` list plus the source for older dumps.
|
|
117
|
+
|
|
118
|
+
### Fixed
|
|
119
|
+
- SOAP RFC backend (BASIS 7.31): SAP writes `"` in `EV_RESULT` as `"`, which was not decoded, so JSON results failed to parse and came back as 0 rows (e.g. an empty dump list). Numeric character references are now decoded.
|
|
120
|
+
|
|
121
|
+
## [4.8.14] - 2026-10-28
|
|
122
|
+
|
|
123
|
+
### Changed
|
|
124
|
+
- **`GetGuiStatus`** answers with only what was asked for. `status_name` used to narrow the status list alone, so a large program interface still came back whole (15K+ tokens). It now narrows every table to that status: its SET functions, FUN texts, PFK keys, BUT toolbar and ACT / MEN / MTX menus; TIT / DOC / BIV are left out.
|
|
125
|
+
- New `function_codes`: keep only these function codes (narrows FUN / SET / PFK / BUT).
|
|
126
|
+
- New `format: "compact"`: `{ statuses: [{ code, type, functions: [{ code, text, icon?, fkey?, toolbar? }] }] }` — one line per function. `full` (default) keeps the CUA tables.
|
|
127
|
+
- A status still lists the empty-text ALV standard functions it copies; pass `function_codes` when you need a few captions.
|
|
128
|
+
|
|
7
129
|
## [4.8.13] - 2026-10-20
|
|
8
130
|
|
|
9
131
|
### Added
|
package/README.md
CHANGED
|
@@ -97,7 +97,7 @@ Verified on ECC 7.40 (SAP_VERSION=ECC, ABAP_RELEASE=740, SAP_SYSTEM_TYPE=onprem)
|
|
|
97
97
|
| Enhancements | `GetEnhancements`, `GetEnhancementSpot`, `GetEnhancementImpl` | ❌ | `/sap/bc/adt/enhancements` discovery endpoints return 404 on BASIS < 7.50 — use SE18/SE19 or CMOD/SMOD in SAP GUI |
|
|
98
98
|
| Transport | `ListTransports`, `GetTransport`, `CreateTransport` | ✅ | CTS endpoints present |
|
|
99
99
|
| Runtime | `RuntimeListDumps`, `RuntimeAnalyzeDump`, `RuntimeGetDumpById` | ✅ | `/sap/bc/adt/runtime/dumps` present |
|
|
100
|
-
| Screen / GUI Status | `GetScreen`, `GetGuiStatus`, `GetTextElement` (+ Create/Update) | ℹ️ | RFC-dispatched via `SAP_RFC_BACKEND` (`odata` default / `soap` / `
|
|
100
|
+
| Screen / GUI Status | `GetScreen`, `GetGuiStatus`, `GetTextElement` (+ Create/Update) | ℹ️ | RFC-dispatched via `SAP_RFC_BACKEND` (`odata` default / `soap` / `nco`); the chosen backend's prerequisites (OData service classes, the SOAP RFC SICF node, or NCo on Windows) must be in place |
|
|
101
101
|
| RAP / Behavior | `*BehaviorDefinition`, `*BehaviorImplementation` | ❌ | S/4HANA only — RAP does not exist on ECC |
|
|
102
102
|
| Service binding | `*ServiceDefinition`, `*ServiceBinding` | ❌ | S/4HANA / ABAP Cloud only |
|
|
103
103
|
| Metadata extensions | `*MetadataExtension` | ❌ | S/4HANA / ABAP Cloud only |
|
|
@@ -699,7 +699,7 @@ The server respects SAP authorization — whatever your user cannot do in SE80/A
|
|
|
699
699
|
Use `--env <destination>` with per-destination `.env` files, or the YAML config. For HTTP/SSE deployments, pass `x-sap-*` headers per request.
|
|
700
700
|
|
|
701
701
|
**Q. Does it support RFC?**
|
|
702
|
-
Yes,
|
|
702
|
+
Yes, on Windows through SAP .NET Connector (NCo 3.x): `SAP_RFC_BACKEND=nco` calls the helper function modules over RFC, and `SAP_CONNECTION_TYPE=nco` sends the ADT requests over RFC too (`SADT_REST_RFC_ENDPOINT`). The bridge is compiled on first use against the installed NCo. The node-rfc connection (`SAP_CONNECTION_TYPE=rfc`) and the `native` / `gateway` / `zrfc` backends were removed in 4.10.0.
|
|
703
703
|
|
|
704
704
|
---
|
|
705
705
|
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CreateAdobeFormFromSmartForm — SAP's SmartForm → Adobe form migration (CL_SSF_MIGRATION's steps) of a SAP
|
|
3
|
+
* example SmartForm into NEW local objects (ZSC4SAP_AFM_* form and interface, package $TMP), activated, with
|
|
4
|
+
* SAP's migration log. Development systems only: the Create prefix makes the server's tier guard and the
|
|
5
|
+
* plugin hook refuse it on QA / PRD; the SAP helper refuses non-development clients itself.
|
|
6
|
+
*
|
|
7
|
+
* SAP side: ZMCP_ADT_DISPATCH action FP_MIGRATE → FM ZMCP_FP_MIGRATE.
|
|
8
|
+
* Companion ABAP: sc4sap/abap/zmcp_fp_migrate.abap, zmcp_adt_dispatch_fp_migrate_branch.abap.
|
|
9
|
+
*/
|
|
10
|
+
import type { HandlerContext } from '../../../lib/handlers/interfaces';
|
|
11
|
+
export declare const TOOL_DEFINITION: {
|
|
12
|
+
readonly name: "CreateAdobeFormFromSmartForm";
|
|
13
|
+
readonly available_in: readonly ["onprem", "legacy"];
|
|
14
|
+
readonly description: "[writes, DEV only] Migrate a SAP-delivered SmartForm into a NEW Adobe form and interface with SAP's own migration (CL_SSF_MIGRATION steps, all options except 'alternative: true branch' and 'text placeholder'), in package $TMP, activated. Target names must match ZSC4SAP_AFM_* and must not exist — nothing is overwritten or deleted. Returns SAP's migration log, the options used and what was saved / activated; `complete` is true only when both objects are active (otherwise `message` says what is not). When SAP's migration raises, the tool fails and its error names the objects left behind (delete them only with the user's approval). Needs the ZMCP_FP_MIGRATE FM and the FP_MIGRATE dispatcher action.";
|
|
15
|
+
readonly inputSchema: {
|
|
16
|
+
readonly type: "object";
|
|
17
|
+
readonly properties: {
|
|
18
|
+
readonly source: {
|
|
19
|
+
readonly type: "string";
|
|
20
|
+
readonly description: "SAP SmartForm to migrate (e.g. \"SF_EXAMPLE_01\"); customer forms are refused.";
|
|
21
|
+
};
|
|
22
|
+
readonly form_name: {
|
|
23
|
+
readonly type: "string";
|
|
24
|
+
readonly description: "New Adobe form name, ZSC4SAP_AFM_* (≤ 30).";
|
|
25
|
+
};
|
|
26
|
+
readonly interface_name: {
|
|
27
|
+
readonly type: "string";
|
|
28
|
+
readonly description: "New form interface name, ZSC4SAP_AFM_* (≤ 30).";
|
|
29
|
+
};
|
|
30
|
+
readonly sender_country: {
|
|
31
|
+
readonly type: "string";
|
|
32
|
+
readonly description: "Optional country key (T005, e.g. \"DE\") set as sender country on address nodes that have none — the Adobe check requires one, SmartForms did not. Without it nothing is changed and the check reports the address nodes.";
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
readonly required: readonly ["source", "form_name", "interface_name"];
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
export declare function handleCreateAdobeFormFromSmartForm(context: HandlerContext, args: {
|
|
39
|
+
source: string;
|
|
40
|
+
form_name: string;
|
|
41
|
+
interface_name: string;
|
|
42
|
+
sender_country?: string;
|
|
43
|
+
}): Promise<{
|
|
44
|
+
isError: boolean;
|
|
45
|
+
content: {
|
|
46
|
+
type: string;
|
|
47
|
+
text: any;
|
|
48
|
+
}[];
|
|
49
|
+
}>;
|
|
50
|
+
//# sourceMappingURL=handleCreateAdobeFormFromSmartForm.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handleCreateAdobeFormFromSmartForm.d.ts","sourceRoot":"","sources":["../../../../src/handlers/adobeform/high/handleCreateAdobeFormFromSmartForm.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAOvE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;CA6BlB,CAAC;AAEX,wBAAsB,kCAAkC,CACtD,OAAO,EAAE,cAAc,EACvB,IAAI,EAAE;IACJ,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,cAAc,EAAE,MAAM,CAAC;IACvB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;;;;;;GAsBF"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* CreateAdobeFormFromSmartForm — SAP's SmartForm → Adobe form migration (CL_SSF_MIGRATION's steps) of a SAP
|
|
4
|
+
* example SmartForm into NEW local objects (ZSC4SAP_AFM_* form and interface, package $TMP), activated, with
|
|
5
|
+
* SAP's migration log. Development systems only: the Create prefix makes the server's tier guard and the
|
|
6
|
+
* plugin hook refuse it on QA / PRD; the SAP helper refuses non-development clients itself.
|
|
7
|
+
*
|
|
8
|
+
* SAP side: ZMCP_ADT_DISPATCH action FP_MIGRATE → FM ZMCP_FP_MIGRATE.
|
|
9
|
+
* Companion ABAP: sc4sap/abap/zmcp_fp_migrate.abap, zmcp_adt_dispatch_fp_migrate_branch.abap.
|
|
10
|
+
*/
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.TOOL_DEFINITION = void 0;
|
|
13
|
+
exports.handleCreateAdobeFormFromSmartForm = handleCreateAdobeFormFromSmartForm;
|
|
14
|
+
const adobeForm_1 = require("../../../lib/adobeForm");
|
|
15
|
+
const utils_1 = require("../../../lib/utils");
|
|
16
|
+
exports.TOOL_DEFINITION = {
|
|
17
|
+
name: 'CreateAdobeFormFromSmartForm',
|
|
18
|
+
available_in: ['onprem', 'legacy'],
|
|
19
|
+
description: "[writes, DEV only] Migrate a SAP-delivered SmartForm into a NEW Adobe form and interface with SAP's own migration (CL_SSF_MIGRATION steps, all options except 'alternative: true branch' and 'text placeholder'), in package $TMP, activated. Target names must match ZSC4SAP_AFM_* and must not exist — nothing is overwritten or deleted. Returns SAP's migration log, the options used and what was saved / activated; `complete` is true only when both objects are active (otherwise `message` says what is not). When SAP's migration raises, the tool fails and its error names the objects left behind (delete them only with the user's approval). Needs the ZMCP_FP_MIGRATE FM and the FP_MIGRATE dispatcher action.",
|
|
20
|
+
inputSchema: {
|
|
21
|
+
type: 'object',
|
|
22
|
+
properties: {
|
|
23
|
+
source: {
|
|
24
|
+
type: 'string',
|
|
25
|
+
description: 'SAP SmartForm to migrate (e.g. "SF_EXAMPLE_01"); customer forms are refused.',
|
|
26
|
+
},
|
|
27
|
+
form_name: {
|
|
28
|
+
type: 'string',
|
|
29
|
+
description: 'New Adobe form name, ZSC4SAP_AFM_* (≤ 30).',
|
|
30
|
+
},
|
|
31
|
+
interface_name: {
|
|
32
|
+
type: 'string',
|
|
33
|
+
description: 'New form interface name, ZSC4SAP_AFM_* (≤ 30).',
|
|
34
|
+
},
|
|
35
|
+
sender_country: {
|
|
36
|
+
type: 'string',
|
|
37
|
+
description: 'Optional country key (T005, e.g. "DE") set as sender country on address nodes that have none — the Adobe check requires one, SmartForms did not. Without it nothing is changed and the check reports the address nodes.',
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
required: ['source', 'form_name', 'interface_name'],
|
|
41
|
+
},
|
|
42
|
+
};
|
|
43
|
+
async function handleCreateAdobeFormFromSmartForm(context, args) {
|
|
44
|
+
const { connection, logger } = context;
|
|
45
|
+
try {
|
|
46
|
+
logger?.info(`CreateAdobeFormFromSmartForm: ${args?.source} → ${args?.form_name}`);
|
|
47
|
+
const result = await (0, adobeForm_1.createAdobeFormFromSmartForm)(connection, args?.source, args?.form_name, args?.interface_name, args?.sender_country);
|
|
48
|
+
return (0, utils_1.return_response)({
|
|
49
|
+
data: JSON.stringify(result, null, 2),
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
catch (error) {
|
|
53
|
+
const msg = error instanceof Error ? error.message : String(error);
|
|
54
|
+
logger?.error(`CreateAdobeFormFromSmartForm error: ${msg}`);
|
|
55
|
+
return (0, utils_1.return_error)(new Error(msg));
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
//# sourceMappingURL=handleCreateAdobeFormFromSmartForm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handleCreateAdobeFormFromSmartForm.js","sourceRoot":"","sources":["../../../../src/handlers/adobeform/high/handleCreateAdobeFormFromSmartForm.ts"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;;;AAyCH,gFA6BC;AApED,sDAAsE;AAEtE,8CAI4B;AAEf,QAAA,eAAe,GAAG;IAC7B,IAAI,EAAE,8BAA8B;IACpC,YAAY,EAAE,CAAC,QAAQ,EAAE,QAAQ,CAAU;IAC3C,WAAW,EACT,gsBAAgsB;IAClsB,WAAW,EAAE;QACX,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,MAAM,EAAE;gBACN,IAAI,EAAE,QAAQ;gBACd,WAAW,EACT,8EAA8E;aACjF;YACD,SAAS,EAAE;gBACT,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,4CAA4C;aAC1D;YACD,cAAc,EAAE;gBACd,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,gDAAgD;aAC9D;YACD,cAAc,EAAE;gBACd,IAAI,EAAE,QAAQ;gBACd,WAAW,EACT,yNAAyN;aAC5N;SACF;QACD,QAAQ,EAAE,CAAC,QAAQ,EAAE,WAAW,EAAE,gBAAgB,CAAC;KACpD;CACO,CAAC;AAEJ,KAAK,UAAU,kCAAkC,CACtD,OAAuB,EACvB,IAKC;IAED,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC;IACvC,IAAI,CAAC;QACH,MAAM,EAAE,IAAI,CACV,iCAAiC,IAAI,EAAE,MAAM,MAAM,IAAI,EAAE,SAAS,EAAE,CACrE,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,IAAA,wCAA4B,EAC/C,UAAU,EACV,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,SAAS,EACf,IAAI,EAAE,cAAc,EACpB,IAAI,EAAE,cAAc,CACrB,CAAC;QACF,OAAO,IAAA,uBAAe,EAAC;YACrB,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;SACrB,CAAC,CAAC;IACtB,CAAC;IAAC,OAAO,KAAc,EAAE,CAAC;QACxB,MAAM,GAAG,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;QACnE,MAAM,EAAE,KAAK,CAAC,uCAAuC,GAAG,EAAE,CAAC,CAAC;QAC5D,OAAO,IAAA,oBAAY,EAAC,IAAI,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;IACtC,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Business-action tools (tool profile "biz"): ListBusinessActions,
|
|
3
|
+
* RunBusinessQuery, PreviewBusinessAction, ExecuteBusinessAction.
|
|
4
|
+
*
|
|
5
|
+
* All four call ZMCP_BIZ_EXECUTE (see lib/bizRfc.ts). Safety is enforced in
|
|
6
|
+
* SAP (whitelist, AUTHORITY-CHECK, preview token bound to user + parameter
|
|
7
|
+
* hash, production-client block, ZMCP_BIZ_LOG). This layer adds the first
|
|
8
|
+
* block: Preview / Execute are refused on a PRD-tier profile (also in
|
|
9
|
+
* readonlyGuard), and Execute without a token is refused before any call.
|
|
10
|
+
*
|
|
11
|
+
* Companion ABAP: sc4sap/abap/biz/ (ZMCP_BIZ_EXECUTE, ZCL_MCP_BIZ_*).
|
|
12
|
+
*/
|
|
13
|
+
import { type BizMode, type BizResult } from '../../lib/bizRfc';
|
|
14
|
+
import type { HandlerContext } from '../../lib/handlers/interfaces';
|
|
15
|
+
export declare const ListBusinessActions_Tool: {
|
|
16
|
+
readonly name: "ListBusinessActions";
|
|
17
|
+
readonly tool_profile: readonly ["biz"];
|
|
18
|
+
readonly description: "[read-only] List the business actions installed and active in SAP (ZMCP_BIZ registry: id, kind query/write, version). Use before offering an action to the user.";
|
|
19
|
+
readonly inputSchema: {
|
|
20
|
+
readonly type: "object";
|
|
21
|
+
readonly properties: {};
|
|
22
|
+
readonly required: readonly [];
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
export declare const RunBusinessQuery_Tool: {
|
|
26
|
+
readonly name: "RunBusinessQuery";
|
|
27
|
+
readonly tool_profile: readonly ["biz"];
|
|
28
|
+
readonly description: "[read-only] Run a query business action (e.g. open purchase orders) or a PRECHECK of a write action (configuration / status facts that would block it). Never changes SAP data.";
|
|
29
|
+
readonly inputSchema: {
|
|
30
|
+
readonly type: "object";
|
|
31
|
+
readonly properties: {
|
|
32
|
+
readonly action: {
|
|
33
|
+
readonly type: "string";
|
|
34
|
+
readonly description: "Catalog action id, e.g. MM.PO.LIST_OPEN or MM.PO.SET_DELIVERY_COMPLETE.";
|
|
35
|
+
};
|
|
36
|
+
readonly params: {
|
|
37
|
+
readonly type: "object";
|
|
38
|
+
readonly description: "Flat JSON object of action parameters (values as strings; item lists as arrays of strings), named as in the action catalog (configs/<module>/actions.json). Unknown names are refused by SAP.";
|
|
39
|
+
readonly additionalProperties: true;
|
|
40
|
+
};
|
|
41
|
+
readonly precheck: {
|
|
42
|
+
readonly type: "boolean";
|
|
43
|
+
readonly description: "true = run PRECHECK for a write action instead of QUERY. Default false.";
|
|
44
|
+
};
|
|
45
|
+
};
|
|
46
|
+
readonly required: readonly ["action"];
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
export declare const PreviewBusinessAction_Tool: {
|
|
50
|
+
readonly name: "PreviewBusinessAction";
|
|
51
|
+
readonly tool_profile: readonly ["biz"];
|
|
52
|
+
readonly description: "[preview] Simulate a write business action in SAP (BAPI test run or checks only) and return the before/after values plus a one-time confirmation token. Show the preview to the user and get an explicit yes before ExecuteBusinessAction. Blocked on PRD profiles.";
|
|
53
|
+
readonly inputSchema: {
|
|
54
|
+
readonly type: "object";
|
|
55
|
+
readonly properties: {
|
|
56
|
+
readonly action: {
|
|
57
|
+
readonly type: "string";
|
|
58
|
+
readonly description: "Catalog action id, e.g. MM.PO.LIST_OPEN or MM.PO.SET_DELIVERY_COMPLETE.";
|
|
59
|
+
};
|
|
60
|
+
readonly params: {
|
|
61
|
+
readonly type: "object";
|
|
62
|
+
readonly description: "Flat JSON object of action parameters (values as strings; item lists as arrays of strings), named as in the action catalog (configs/<module>/actions.json). Unknown names are refused by SAP.";
|
|
63
|
+
readonly additionalProperties: true;
|
|
64
|
+
};
|
|
65
|
+
};
|
|
66
|
+
readonly required: readonly ["action", "params"];
|
|
67
|
+
};
|
|
68
|
+
};
|
|
69
|
+
export declare const ExecuteBusinessAction_Tool: {
|
|
70
|
+
readonly name: "ExecuteBusinessAction";
|
|
71
|
+
readonly tool_profile: readonly ["biz"];
|
|
72
|
+
readonly description: "[write] Execute a previewed write business action (BAPI + commit) in SAP. Needs the token from PreviewBusinessAction and exactly the same params; the token expires and works once. Only after the user confirmed the preview. Blocked on PRD profiles.";
|
|
73
|
+
readonly inputSchema: {
|
|
74
|
+
readonly type: "object";
|
|
75
|
+
readonly properties: {
|
|
76
|
+
readonly action: {
|
|
77
|
+
readonly type: "string";
|
|
78
|
+
readonly description: "Catalog action id, e.g. MM.PO.LIST_OPEN or MM.PO.SET_DELIVERY_COMPLETE.";
|
|
79
|
+
};
|
|
80
|
+
readonly params: {
|
|
81
|
+
readonly type: "object";
|
|
82
|
+
readonly description: "Flat JSON object of action parameters (values as strings; item lists as arrays of strings), named as in the action catalog (configs/<module>/actions.json). Unknown names are refused by SAP.";
|
|
83
|
+
readonly additionalProperties: true;
|
|
84
|
+
};
|
|
85
|
+
readonly token: {
|
|
86
|
+
readonly type: "string";
|
|
87
|
+
readonly description: "Token returned by PreviewBusinessAction for these params.";
|
|
88
|
+
};
|
|
89
|
+
readonly idem_key: {
|
|
90
|
+
readonly type: "string";
|
|
91
|
+
readonly description: "Optional idempotency key: repeating EXECUTE with the same key returns the stored result instead of posting again.";
|
|
92
|
+
};
|
|
93
|
+
};
|
|
94
|
+
readonly required: readonly ["action", "params", "token"];
|
|
95
|
+
};
|
|
96
|
+
};
|
|
97
|
+
/** Tool names that may change SAP business data (blocked on PRD). */
|
|
98
|
+
export declare const BUSINESS_WRITE_TOOL_NAMES: readonly ["PreviewBusinessAction", "ExecuteBusinessAction"];
|
|
99
|
+
export declare function formatBizResult(mode: BizMode, r: BizResult): {
|
|
100
|
+
isError: boolean;
|
|
101
|
+
content: {
|
|
102
|
+
type: string;
|
|
103
|
+
text: string;
|
|
104
|
+
}[];
|
|
105
|
+
};
|
|
106
|
+
export declare function handleListBusinessActions(context: HandlerContext, _args: any): Promise<{
|
|
107
|
+
isError: boolean;
|
|
108
|
+
content: {
|
|
109
|
+
type: string;
|
|
110
|
+
text: string;
|
|
111
|
+
}[];
|
|
112
|
+
}>;
|
|
113
|
+
export declare function handleRunBusinessQuery(context: HandlerContext, args: any): Promise<{
|
|
114
|
+
isError: boolean;
|
|
115
|
+
content: {
|
|
116
|
+
type: string;
|
|
117
|
+
text: string;
|
|
118
|
+
}[];
|
|
119
|
+
}>;
|
|
120
|
+
export declare function handlePreviewBusinessAction(context: HandlerContext, args: any): Promise<{
|
|
121
|
+
isError: boolean;
|
|
122
|
+
content: {
|
|
123
|
+
type: string;
|
|
124
|
+
text: string;
|
|
125
|
+
}[];
|
|
126
|
+
}>;
|
|
127
|
+
export declare function handleExecuteBusinessAction(context: HandlerContext, args: any): Promise<{
|
|
128
|
+
isError: boolean;
|
|
129
|
+
content: {
|
|
130
|
+
type: string;
|
|
131
|
+
text: string;
|
|
132
|
+
}[];
|
|
133
|
+
}>;
|
|
134
|
+
//# sourceMappingURL=handleBusinessActions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handleBusinessActions.d.ts","sourceRoot":"","sources":["../../../src/handlers/business/handleBusinessActions.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,SAAS,EAAkB,MAAM,kBAAkB,CAAC;AAChF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAiBpE,eAAO,MAAM,wBAAwB;;;;;;;;;CAM3B,CAAC;AAEX,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;CAkBxB,CAAC;AAEX,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;CAU7B,CAAC;AAEX,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuB7B,CAAC;AAEX,qEAAqE;AACrE,eAAO,MAAM,yBAAyB,6DAG5B,CAAC;AAiBX,wBAAgB,eAAe,CAAC,IAAI,EAAE,OAAO,EAAE,CAAC,EAAE,SAAS;;;;;;EAa1D;AA+BD,wBAAsB,yBAAyB,CAC7C,OAAO,EAAE,cAAc,EACvB,KAAK,EAAE,GAAG;;;;;;GAOX;AAED,wBAAsB,sBAAsB,CAC1C,OAAO,EAAE,cAAc,EACvB,IAAI,EAAE,GAAG;;;;;;GAWV;AAED,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,cAAc,EACvB,IAAI,EAAE,GAAG;;;;;;GASV;AAED,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,cAAc,EACvB,IAAI,EAAE,GAAG;;;;;;GAoBV"}
|
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Business-action tools (tool profile "biz"): ListBusinessActions,
|
|
4
|
+
* RunBusinessQuery, PreviewBusinessAction, ExecuteBusinessAction.
|
|
5
|
+
*
|
|
6
|
+
* All four call ZMCP_BIZ_EXECUTE (see lib/bizRfc.ts). Safety is enforced in
|
|
7
|
+
* SAP (whitelist, AUTHORITY-CHECK, preview token bound to user + parameter
|
|
8
|
+
* hash, production-client block, ZMCP_BIZ_LOG). This layer adds the first
|
|
9
|
+
* block: Preview / Execute are refused on a PRD-tier profile (also in
|
|
10
|
+
* readonlyGuard), and Execute without a token is refused before any call.
|
|
11
|
+
*
|
|
12
|
+
* Companion ABAP: sc4sap/abap/biz/ (ZMCP_BIZ_EXECUTE, ZCL_MCP_BIZ_*).
|
|
13
|
+
*/
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
exports.BUSINESS_WRITE_TOOL_NAMES = exports.ExecuteBusinessAction_Tool = exports.PreviewBusinessAction_Tool = exports.RunBusinessQuery_Tool = exports.ListBusinessActions_Tool = void 0;
|
|
16
|
+
exports.formatBizResult = formatBizResult;
|
|
17
|
+
exports.handleListBusinessActions = handleListBusinessActions;
|
|
18
|
+
exports.handleRunBusinessQuery = handleRunBusinessQuery;
|
|
19
|
+
exports.handlePreviewBusinessAction = handlePreviewBusinessAction;
|
|
20
|
+
exports.handleExecuteBusinessAction = handleExecuteBusinessAction;
|
|
21
|
+
const bizRfc_1 = require("../../lib/bizRfc");
|
|
22
|
+
const profile_1 = require("../../lib/profile");
|
|
23
|
+
const utils_1 = require("../../lib/utils");
|
|
24
|
+
const PARAMS_SCHEMA = {
|
|
25
|
+
type: 'object',
|
|
26
|
+
description: 'Flat JSON object of action parameters (values as strings; item lists as arrays of strings), named as in the action catalog (configs/<module>/actions.json). Unknown names are refused by SAP.',
|
|
27
|
+
additionalProperties: true,
|
|
28
|
+
};
|
|
29
|
+
const ACTION_SCHEMA = {
|
|
30
|
+
type: 'string',
|
|
31
|
+
description: 'Catalog action id, e.g. MM.PO.LIST_OPEN or MM.PO.SET_DELIVERY_COMPLETE.',
|
|
32
|
+
};
|
|
33
|
+
exports.ListBusinessActions_Tool = {
|
|
34
|
+
name: 'ListBusinessActions',
|
|
35
|
+
tool_profile: ['biz'],
|
|
36
|
+
description: '[read-only] List the business actions installed and active in SAP (ZMCP_BIZ registry: id, kind query/write, version). Use before offering an action to the user.',
|
|
37
|
+
inputSchema: { type: 'object', properties: {}, required: [] },
|
|
38
|
+
};
|
|
39
|
+
exports.RunBusinessQuery_Tool = {
|
|
40
|
+
name: 'RunBusinessQuery',
|
|
41
|
+
tool_profile: ['biz'],
|
|
42
|
+
description: '[read-only] Run a query business action (e.g. open purchase orders) or a PRECHECK of a write action (configuration / status facts that would block it). Never changes SAP data.',
|
|
43
|
+
inputSchema: {
|
|
44
|
+
type: 'object',
|
|
45
|
+
properties: {
|
|
46
|
+
action: ACTION_SCHEMA,
|
|
47
|
+
params: PARAMS_SCHEMA,
|
|
48
|
+
precheck: {
|
|
49
|
+
type: 'boolean',
|
|
50
|
+
description: 'true = run PRECHECK for a write action instead of QUERY. Default false.',
|
|
51
|
+
},
|
|
52
|
+
},
|
|
53
|
+
required: ['action'],
|
|
54
|
+
},
|
|
55
|
+
};
|
|
56
|
+
exports.PreviewBusinessAction_Tool = {
|
|
57
|
+
name: 'PreviewBusinessAction',
|
|
58
|
+
tool_profile: ['biz'],
|
|
59
|
+
description: '[preview] Simulate a write business action in SAP (BAPI test run or checks only) and return the before/after values plus a one-time confirmation token. Show the preview to the user and get an explicit yes before ExecuteBusinessAction. Blocked on PRD profiles.',
|
|
60
|
+
inputSchema: {
|
|
61
|
+
type: 'object',
|
|
62
|
+
properties: { action: ACTION_SCHEMA, params: PARAMS_SCHEMA },
|
|
63
|
+
required: ['action', 'params'],
|
|
64
|
+
},
|
|
65
|
+
};
|
|
66
|
+
exports.ExecuteBusinessAction_Tool = {
|
|
67
|
+
name: 'ExecuteBusinessAction',
|
|
68
|
+
tool_profile: ['biz'],
|
|
69
|
+
description: '[write] Execute a previewed write business action (BAPI + commit) in SAP. Needs the token from PreviewBusinessAction and exactly the same params; the token expires and works once. Only after the user confirmed the preview. Blocked on PRD profiles.',
|
|
70
|
+
inputSchema: {
|
|
71
|
+
type: 'object',
|
|
72
|
+
properties: {
|
|
73
|
+
action: ACTION_SCHEMA,
|
|
74
|
+
params: PARAMS_SCHEMA,
|
|
75
|
+
token: {
|
|
76
|
+
type: 'string',
|
|
77
|
+
description: 'Token returned by PreviewBusinessAction for these params.',
|
|
78
|
+
},
|
|
79
|
+
idem_key: {
|
|
80
|
+
type: 'string',
|
|
81
|
+
description: 'Optional idempotency key: repeating EXECUTE with the same key returns the stored result instead of posting again.',
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
required: ['action', 'params', 'token'],
|
|
85
|
+
},
|
|
86
|
+
};
|
|
87
|
+
/** Tool names that may change SAP business data (blocked on PRD). */
|
|
88
|
+
exports.BUSINESS_WRITE_TOOL_NAMES = [
|
|
89
|
+
exports.PreviewBusinessAction_Tool.name,
|
|
90
|
+
exports.ExecuteBusinessAction_Tool.name,
|
|
91
|
+
];
|
|
92
|
+
function asParams(v) {
|
|
93
|
+
if (v === undefined || v === null)
|
|
94
|
+
return {};
|
|
95
|
+
if (typeof v === 'string') {
|
|
96
|
+
const parsed = JSON.parse(v);
|
|
97
|
+
if (parsed && typeof parsed === 'object' && !Array.isArray(parsed)) {
|
|
98
|
+
return parsed;
|
|
99
|
+
}
|
|
100
|
+
throw new Error('params must be a JSON object');
|
|
101
|
+
}
|
|
102
|
+
if (typeof v === 'object' && !Array.isArray(v)) {
|
|
103
|
+
return v;
|
|
104
|
+
}
|
|
105
|
+
throw new Error('params must be a JSON object');
|
|
106
|
+
}
|
|
107
|
+
function formatBizResult(mode, r) {
|
|
108
|
+
const body = {
|
|
109
|
+
ok: r.subrc === 0,
|
|
110
|
+
mode,
|
|
111
|
+
subrc: r.subrc,
|
|
112
|
+
message: r.message,
|
|
113
|
+
...(r.token ? { token: r.token } : {}),
|
|
114
|
+
result: r.result,
|
|
115
|
+
};
|
|
116
|
+
return {
|
|
117
|
+
isError: false,
|
|
118
|
+
content: [{ type: 'text', text: JSON.stringify(body, null, 2) }],
|
|
119
|
+
};
|
|
120
|
+
}
|
|
121
|
+
function refuseOnPrd(tool) {
|
|
122
|
+
if ((0, profile_1.getActiveTier)() === 'PRD') {
|
|
123
|
+
return new Error(`${tool} is blocked on a PRD-tier profile: business writes run only on DEV / QA.`);
|
|
124
|
+
}
|
|
125
|
+
return null;
|
|
126
|
+
}
|
|
127
|
+
async function run(context, mode, args, extra = {}) {
|
|
128
|
+
const action = String(args?.action ?? '').trim();
|
|
129
|
+
if (mode !== 'LIST' && !action) {
|
|
130
|
+
return (0, utils_1.return_error)(new Error('action is required'));
|
|
131
|
+
}
|
|
132
|
+
const params = asParams(args?.params);
|
|
133
|
+
const r = await (0, bizRfc_1.callBizExecute)(context.connection, {
|
|
134
|
+
action,
|
|
135
|
+
mode,
|
|
136
|
+
params,
|
|
137
|
+
...extra,
|
|
138
|
+
});
|
|
139
|
+
return formatBizResult(mode, r);
|
|
140
|
+
}
|
|
141
|
+
async function handleListBusinessActions(context, _args) {
|
|
142
|
+
try {
|
|
143
|
+
return await run(context, 'LIST', {});
|
|
144
|
+
}
|
|
145
|
+
catch (e) {
|
|
146
|
+
return (0, utils_1.return_error)(e);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
async function handleRunBusinessQuery(context, args) {
|
|
150
|
+
try {
|
|
151
|
+
return await run(context, args?.precheck === true ? 'PRECHECK' : 'QUERY', args);
|
|
152
|
+
}
|
|
153
|
+
catch (e) {
|
|
154
|
+
return (0, utils_1.return_error)(e);
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
async function handlePreviewBusinessAction(context, args) {
|
|
158
|
+
try {
|
|
159
|
+
const blocked = refuseOnPrd(exports.PreviewBusinessAction_Tool.name);
|
|
160
|
+
if (blocked)
|
|
161
|
+
return (0, utils_1.return_error)(blocked);
|
|
162
|
+
return await run(context, 'PREVIEW', args);
|
|
163
|
+
}
|
|
164
|
+
catch (e) {
|
|
165
|
+
return (0, utils_1.return_error)(e);
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
async function handleExecuteBusinessAction(context, args) {
|
|
169
|
+
try {
|
|
170
|
+
const blocked = refuseOnPrd(exports.ExecuteBusinessAction_Tool.name);
|
|
171
|
+
if (blocked)
|
|
172
|
+
return (0, utils_1.return_error)(blocked);
|
|
173
|
+
const token = String(args?.token ?? '').trim();
|
|
174
|
+
if (!token) {
|
|
175
|
+
return (0, utils_1.return_error)(new Error('token is required: run PreviewBusinessAction first and confirm it with the user'));
|
|
176
|
+
}
|
|
177
|
+
return await run(context, 'EXECUTE', args, {
|
|
178
|
+
token,
|
|
179
|
+
idemKey: args?.idem_key ? String(args.idem_key) : undefined,
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
catch (e) {
|
|
183
|
+
return (0, utils_1.return_error)(e);
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
//# sourceMappingURL=handleBusinessActions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handleBusinessActions.js","sourceRoot":"","sources":["../../../src/handlers/business/handleBusinessActions.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;GAWG;;;AA0GH,0CAaC;AA+BD,8DASC;AAED,wDAaC;AAED,kEAWC;AAED,kEAsBC;AAjND,6CAAgF;AAEhF,+CAAkD;AAClD,2CAA+C;AAE/C,MAAM,aAAa,GAAG;IACpB,IAAI,EAAE,QAAQ;IACd,WAAW,EACT,+LAA+L;IACjM,oBAAoB,EAAE,IAAI;CAClB,CAAC;AAEX,MAAM,aAAa,GAAG;IACpB,IAAI,EAAE,QAAQ;IACd,WAAW,EACT,yEAAyE;CACnE,CAAC;AAEE,QAAA,wBAAwB,GAAG;IACtC,IAAI,EAAE,qBAAqB;IAC3B,YAAY,EAAE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AQ,CAAC,CAAC,CAAC,CAAC,SAAS;SAC5D,CAAC,CAAC;IACL,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACX,OAAO,IAAA,oBAAY,EAAC,CAAC,CAAC,CAAC;IACzB,CAAC;AACH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"handleCreateDataElement.d.ts","sourceRoot":"","sources":["../../../../src/handlers/data_element/high/handleCreateDataElement.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;
|
|
1
|
+
{"version":3,"file":"handleCreateDataElement.d.ts","sourceRoot":"","sources":["../../../../src/handlers/data_element/high/handleCreateDataElement.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAgBvE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkGlB,CAAC;AAEX,UAAU,eAAe;IACvB,iBAAiB,EAAE,MAAM,CAAC;IAC1B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,SAAS,CAAC,EACN,QAAQ,GACR,oBAAoB,GACpB,yBAAyB,GACzB,qBAAqB,GACrB,eAAe,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;;;;GAKG;AACH,wBAAsB,uBAAuB,CAC3C,OAAO,EAAE,cAAc,EACvB,IAAI,EAAE,eAAe;;;;;;GAiKtB"}
|
|
@@ -287,8 +287,8 @@ async function handleCreateDataElementEcc(context, args, dataElementName) {
|
|
|
287
287
|
transport_request: args.transport_request,
|
|
288
288
|
data_type: args.data_type || null,
|
|
289
289
|
status: shouldActivate ? 'active' : 'inactive',
|
|
290
|
-
message: `Data element ${dataElementName} created${shouldActivate ? ' and activated' : ''} successfully (ECC fallback via
|
|
291
|
-
path:
|
|
290
|
+
message: `Data element ${dataElementName} created${shouldActivate ? ' and activated' : ''} successfully (ECC fallback via ${(0, rfcBackend_1.eccBridgeVia)()})`,
|
|
291
|
+
path: (0, rfcBackend_1.eccBridgePath)(),
|
|
292
292
|
}, null, 2),
|
|
293
293
|
});
|
|
294
294
|
}
|