I have created a REST resource to expose it as an MCP tool, but when am clicking the 'SFDX: Create OpenAI Documentation' in VS Code, the externalServiceRegistrations folder is created, but under that YAML file is not created, and throwing the error below.
OpenAPI document generation produced no content. Last failure: LLM call failed: TypeError: Vu.getChannelService(...).showCommandWithTimestamp is not a function
I have done all the basic setup, but still am feeling like some settings I missed. Please let me know if you have any ideas to solve this issue.
Just FYI,
In the project.json file, I added the option below
"sourceBehaviorOptions": ["decomposeExternalServiceRegistrationBeta"]
in setting.json file, I added the option below
"salesforcedx-vscode-apex-oas.enableRestOASGen": true,
Also, I downgraded the Agentforce Vibe extension(I didn't explicitly install it, may be came in through the Salesforce Extension package) to 3.40 cause with the latest 4.x version, it was throwing an error during openAI document creation.
#Salesforce Developer #Agentforce #Mcp
To resolve the OpenAI document generation failure when building your MCP tool, the error Vu.getChannelService(...).showCommandWithTimestamp is not a function
typically points to an incompatibility between your VS Code extension versions and the Salesforce Extension Pack. This usually happens when a command registry or underlying service method is missing or deprecated in the specific extension build you are running.
Since you mentioned downgrading the Agentforce Vibe extension to version 3.40 to workaround previous errors, this version mismatch likely broke the command registration pipeline required by the Apex-OAS generator. The extension is trying to invoke a UI logging or command timestamp method that doesn't exist in that particular release build, causing the LLM call and subsequent YAML generation to fail mid-stream.
To fix this, try updating your Salesforce extension ecosystem to the latest compatible versions so that all required internal helper functions and channel services align correctly. If you need to keep a specific version pinned, ensure both the Salesforce Extension Pack and any companion tool extensions are fully synchronized, or try running the command from a clean VS Code workspace profile to bypass conflicting global extension states.