Formerly known as Azure AI Services or Azure Cognitive Services is a unified collection of prebuilt AI capabilities within the Microsoft Foundry platform
Hi everyone,
If you are encountering the following validation error when creating a Knowledge Base for your Agent in Microsoft AI Foundry:
“Error saving knowledge base. The request is invalid. Details: The property 'kind' does not exist on type 'Microsoft.WindowsAzure.Search.Core.Models.V2025_11_01_Preview.Agents.AgentKnowledgeSourceReference' or is not present in the API version '2025-11-01-Preview'.”
This is caused by a platform schema mismatch bug in the portal's internal frontend wrapper (ai.azure.com/nextgen/api/). The UI drops required properties during serialization, and the 2025-11-01-Preview API endpoint fails to process the nested agent schema properties correctly in certain regions (like swedencentral).
You can completely bypass this bug by creating the resources directly using the Azure AI Search Data-Plane API (Stable version 2026-04-01) via the Azure CLI and curl.
Here is the exact step-by-step solution to provision your Knowledge Base and attach it to your Agent:
Step 1: Get an Azure AI Search Scoped Token
Open your terminal, log into your Azure CLI account, and pull an access token scoped explicitly for Azure AI Search:
Bash
# Log in and set your active subscription
Step 2: Create the Knowledge Source Directly
Run the following curl command to provision your Knowledge Source mapping. Note that we target the stable 2026-04-01 API and explicitly inject the required "kind": "azureBlob" and "kind": "azureOpenAI" fields that the UI is currently breaking:
Bash
curl -X PUT
Note: If Azure returns a naming conflict error indicating a component already exists, simply change <YOUR-KS-NAME> slightly (e.g., append -v2) to route around cached metadata states.
Step 3: Create the Knowledge Base Wrapper
Once the Knowledge Source returns a success confirmation, link it to the orchestration layer. CRITICAL: Ensure you explicitly declare the "modelName" parameter using an accepted naming convention format (e.g., gpt-4o, gpt-4.1), otherwise the backend engine will reject the model configuration setup.
Bash
curl -X PUT
Step 4: Link it in the Azure AI Foundry UI
Go back to your Azure AI Foundry Studio browser window.
Hard refresh the page to update the portal UI engine cache.
Open your Agent configuration panel and go to the Knowledge tab.
Select Add Existing Knowledge Base instead of attempting a fresh creation.
Choose <YOUR-KB-NAME> from the list and hit save.
Your agent will instantly bind onto the manually built operational data-plane connection map cleanly, completely avoiding the preview registration bug!