Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Note
Foundry IQ (Azure AI Search) provides direct indexing and query APIs alongside higher-level knowledge source and knowledge base APIs for managed retrieval. Use the Azure portal, REST APIs, or Azure SDKs to configure these capabilities, or connect agents to knowledge bases in the Microsoft Foundry portal.
A blob knowledge source ingests Azure Blob Storage or ADLS Gen2 content into an agentic retrieval pipeline in Foundry IQ (Azure AI Search). Knowledge sources are created independently, referenced in a knowledge base, and used as grounding data when the knowledge base is queried at runtime.
When you create a blob knowledge source, you specify an external data source, models, and properties to automatically generate the following Foundry IQ objects:
- A data source that represents a blob container.
- A skillset that chunks and optionally vectorizes multimodal content from the container.
- An index that stores enriched content and meets the criteria for agentic retrieval.
- An indexer that uses the previous objects to drive the indexing and enrichment pipeline.
The generated indexer conforms to the blob indexer, whose prerequisites, supported document formats, and limitations also apply to blob knowledge sources. For more information, see the blob indexer documentation and indexer limits. If the generated skillset calls an external service, that skill's input and service limits also apply.
Usage support
| Azure portal | Microsoft Foundry portal | .NET SDK | Python SDK | Java SDK | JavaScript SDK | REST API |
|---|---|---|---|---|---|---|
| ✔️ | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ |
Prerequisites
A Foundry IQ service in any region that provides agentic retrieval.
An Azure Blob Storage or Azure Data Lake Storage (ADLS) Gen2 account.
A blob container with supported content types for text content. For optional image verbalization, the supported content type depends on whether your chat completion model can analyze and describe the image file.
If
contentExtractionModeisstandard, use a Microsoft Foundry resource in a region supported by Content Understanding in Foundry Tools with ahttps://<resource-name>.services.ai.azure.comendpoint. The resource must have an embedding model deployment and, if you enable image verbalization, a multimodal chat model deployment.Permission to create knowledge sources. Configure keyless authentication with the Search Service Contributor and Search Index Data Contributor roles assigned to your user account (recommended) or use an admin API key.
A managed identity for the Foundry IQ service with Storage Blob Data Reader at the source storage-account scope and Cognitive Services User on the Microsoft Foundry resource. If you configure an asset store in a different storage account, also assign Storage Blob Data Contributor at that storage-account scope. If the source and asset containers share an account, Storage Blob Data Contributor provides both source read access and asset-store read/write access.
- For managed-identity calls to Azure OpenAI embedding or chat deployments, assign Cognitive Services OpenAI User to the selected identity on the Azure OpenAI or parent Foundry resource that matches
resourceUri. Extraction-service permissions are separate. See Assign a role.
- For managed-identity calls to Azure OpenAI embedding or chat deployments, assign Cognitive Services OpenAI User to the selected identity on the Azure OpenAI or parent Foundry resource that matches
If you set
networkAccessModetoprivate, complete the following requirements:Use an S2, S3, L1, or L2 Foundry IQ service. Check the canonical shared private link support matrix for configuration and tier qualifications.
Enable a system-assigned or user-assigned managed identity on the Foundry IQ service, grant it the Storage Blob Data Reader role on the storage account, and use a
ResourceId=/subscriptions/<subscription-id>/resourceGroups/<resource-group>/providers/Microsoft.Storage/storageAccounts/<storage-account>connection string. For a user-assigned identity, also setingestionParameters.identity.Create and approve the storage links listed under supported resource types. For ADLS Gen2, both
blobanddfslinks are required.Create and approve a link for each protected model, extraction, enrichment, or asset-storage dependency that your configuration uses. Follow the supported resource types for each target and group ID.
Required
Azure.Search.Documentspackage:For
2026-08-01-previewfeatures, the latest preview package:dotnet add package Azure.Search.Documents --prereleaseFor
2026-10-01, the latest stable package:dotnet add package Azure.Search.Documents
For keyless authentication, the
Azure.Identitypackage:dotnet add package Azure.Identity
Required
azure-search-documentspackage:For
2026-08-01-previewfeatures, the latest preview package:pip install --pre azure-search-documentsFor
2026-10-01, the latest stable package:pip install azure-search-documents
For keyless authentication, the
azure-identitypackage:pip install azure-identity
Required Search Service REST API version:
For preview features: 2026-11-01-preview
For generally available features, including private ingestion: 2026-10-01
For keyless authentication, include a Microsoft Entra ID token in the
Authorizationheader of each HTTP request.
For permission ingestion, use REST 2026-10-01 as shown in Enforce document-level permissions. The stable 2026-04-01 SDK examples don't configure permission ingestion. Check the package changelog for support of the required API version and properties.
The REST examples use the latest preview API, 2026-11-01-preview. Preview SDK examples retain their documented 2026-08-01-preview contract. Check the package changelog before targeting a newer API version.
Check for existing knowledge sources
A knowledge source is a top-level, reusable object. Knowing about existing knowledge sources is helpful for either reuse or naming new objects.
Run the following code to list knowledge sources by name and type.
// List knowledge sources by name and type
using Azure.Search.Documents.Indexes;
var indexClient = new SearchIndexClient(new Uri(searchEndpoint), credential);
var knowledgeSources = indexClient.GetKnowledgeSourcesAsync();
Console.WriteLine("Knowledge Sources:");
await foreach (var ks in knowledgeSources)
{
Console.WriteLine($" Name: {ks.Name}, Type: {ks.GetType().Name}");
}
Reference: SearchIndexClient
# List knowledge sources by name and type
from azure.core.credentials import AzureKeyCredential
from azure.search.documents.indexes import SearchIndexClient
index_client = SearchIndexClient(endpoint = "search_url", credential = AzureKeyCredential("api_key"))
for ks in index_client.list_knowledge_sources():
print(f" - {ks.name} ({ks.kind})")
Reference: SearchIndexClient
### List knowledge sources by name and type
GET {{search-url}}/knowledgesources?api-version={{api-version}}&$select=name,kind
Authorization: Bearer {{token}}
Reference: Knowledge Sources - List
You can also return a single knowledge source by name to review its JSON definition.
using Azure.Search.Documents.Indexes;
using System.Text.Json;
var indexClient = new SearchIndexClient(new Uri(searchEndpoint), credential);
// Specify the knowledge source name to retrieve
string ksNameToGet = "earth-knowledge-source";
// Get its definition
var knowledgeSourceResponse = await indexClient.GetKnowledgeSourceAsync(ksNameToGet);
var ks = knowledgeSourceResponse.Value;
// Serialize to JSON for display
var jsonOptions = new JsonSerializerOptions
{
WriteIndented = true,
DefaultIgnoreCondition = System.Text.Json.Serialization.JsonIgnoreCondition.Never
};
Console.WriteLine(JsonSerializer.Serialize(ks, ks.GetType(), jsonOptions));
Reference: SearchIndexClient
# Get a knowledge source definition
from azure.core.credentials import AzureKeyCredential
from azure.search.documents.indexes import SearchIndexClient
import json
index_client = SearchIndexClient(endpoint = "search_url", credential = AzureKeyCredential("api_key"))
ks = index_client.get_knowledge_source("knowledge_source_name")
print(json.dumps(ks.as_dict(), indent = 2))
Reference: SearchIndexClient
### Get a knowledge source definition
GET {{search-url}}/knowledgesources('{{knowledge-source-name}}')?api-version={{api-version}}
Authorization: Bearer {{token}}
Reference: Knowledge Sources - Get
The following response redacts sensitive values and lists generated objects under createdResources. Before reusing it to create another knowledge source, supply target credentials or configure supported managed identity; redacted values aren't credentials.
{
"name": "my-blob-ks",
"kind": "azureBlob",
"description": "A sample blob knowledge source.",
"encryptionKey": null,
"azureBlobParameters": {
"connectionString": "<REDACTED>",
"containerName": "blobcontainer",
"folderPath": null,
"isADLSGen2": false,
"ingestionParameters": {
"disableImageVerbalization": false,
"ingestionPermissionOptions": [],
"contentExtractionMode": "standard",
"identity": null,
"embeddingModel": {
"kind": "azureOpenAI",
"azureOpenAIParameters": {
"resourceUri": "<REDACTED>",
"deploymentId": "text-embedding-3-large",
"modelName": "text-embedding-3-large",
"authIdentity": null
}
},
"chatCompletionModel": {
"kind": "azureOpenAI",
"azureOpenAIParameters": {
"resourceUri": "<aoai-endpoint>",
"deploymentId": "gpt-5-mini",
"modelName": "gpt-5-mini",
"authIdentity": null
}
},
"ingestionSchedule": null,
"assetStore": null,
"aiServices": {
"uri": "<aoai-endpoint>"
}
},
"createdResources": {
"datasource": "my-blob-ks-datasource",
"indexer": "my-blob-ks-indexer",
"skillset": "my-blob-ks-skillset",
"index": "my-blob-ks-index"
}
}
}
Create a knowledge source
By using REST API 2026-11-01-preview, embedding and chat ingestion models support Azure API Management (APIM) Premium v2 endpoints. Content Understanding extraction doesn't support APIM endpoints.
Run the following code to create a blob knowledge source.
// Create a blob knowledge source
using Azure.Search.Documents.Indexes;
using Azure.Search.Documents.Indexes.Models;
using Azure.Search.Documents.KnowledgeBases.Models;
using Azure.Search.Documents.Models;
using Azure.Identity;
var indexClient = new SearchIndexClient(new Uri(searchEndpoint), new DefaultAzureCredential());
var chatCompletionParams = new AzureOpenAIVectorizerParameters
{
ResourceUri = new Uri(aoaiEndpoint),
DeploymentName = aoaiGptDeployment,
ModelName = aoaiGptModel
};
var embeddingParams = new AzureOpenAIVectorizerParameters
{
ResourceUri = new Uri(aoaiEndpoint),
DeploymentName = aoaiEmbeddingDeployment,
ModelName = aoaiEmbeddingModel
};
var ingestionParams = new KnowledgeSourceIngestionParameters
{
NetworkAccessMode = KnowledgeSourceNetworkAccessMode.Public,
DisableImageVerbalization = false,
ChatCompletionModel = new KnowledgeBaseAzureOpenAIModel(azureOpenAIParameters: chatCompletionParams),
EmbeddingModel = new KnowledgeSourceAzureOpenAIVectorizer
{
AzureOpenAIParameters = embeddingParams
},
IngestionPermissionOptions = new List<KnowledgeSourceIngestionPermissionOption>
{
KnowledgeSourceIngestionPermissionOption.RbacScope
}
};
var blobParams = new AzureBlobKnowledgeSourceParameters(
connectionString: connectionString,
containerName: containerName
)
{
IsAdlsGen2 = false,
IngestionParameters = ingestionParams
};
var knowledgeSource = new AzureBlobKnowledgeSource(
name: "my-blob-ks",
azureBlobParameters: blobParams
)
{
Description = "This knowledge source pulls from a blob storage container."
};
await indexClient.CreateOrUpdateKnowledgeSourceAsync(knowledgeSource);
Console.WriteLine($"Knowledge source '{knowledgeSource.Name}' created or updated successfully.");
Reference: SearchIndexClient, AzureBlobKnowledgeSource
# Create a blob knowledge source
from azure.identity import DefaultAzureCredential
from azure.search.documents.indexes import SearchIndexClient
from azure.search.documents.indexes.models import AzureBlobKnowledgeSource, AzureBlobKnowledgeSourceParameters, KnowledgeBaseAzureOpenAIModel, AzureOpenAIVectorizerParameters, KnowledgeSourceAzureOpenAIVectorizer, KnowledgeSourceContentExtractionMode, KnowledgeSourceIngestionParameters
from azure.search.documents.knowledgebases.models import KnowledgeSourceNetworkAccessMode
index_client = SearchIndexClient(endpoint = "<search-endpoint>", credential = DefaultAzureCredential())
knowledge_source = AzureBlobKnowledgeSource(
name = "my-blob-ks",
description = "This knowledge source pulls from a blob storage container.",
encryption_key = None,
azure_blob_parameters = AzureBlobKnowledgeSourceParameters(
connection_string = "blob_connection_string",
container_name = "blob_container_name",
folder_path = None,
is_adls_gen2 = False,
ingestion_parameters = KnowledgeSourceIngestionParameters(
network_access_mode = KnowledgeSourceNetworkAccessMode.PUBLIC,
identity = None,
disable_image_verbalization = False,
chat_completion_model = KnowledgeBaseAzureOpenAIModel(
azure_open_ai_parameters = AzureOpenAIVectorizerParameters(
resource_url = "<aoai-endpoint>",
deployment_name = "<aoai-gpt-deployment>",
model_name = "<aoai-gpt-model>",
)
),
embedding_model = KnowledgeSourceAzureOpenAIVectorizer(
azure_open_ai_parameters=AzureOpenAIVectorizerParameters(
resource_url = "<aoai-endpoint>",
deployment_name = "<aoai-embedding-deployment>",
model_name = "<aoai-embedding-model>",
)
),
content_extraction_mode = KnowledgeSourceContentExtractionMode.MINIMAL,
ingestion_schedule = None,
ingestion_permission_options = ["rbacScope"]
)
)
)
index_client.create_or_update_knowledge_source(knowledge_source)
print(f"Knowledge source '{knowledge_source.name}' created or updated successfully.")
Reference: SearchIndexClient
### Create a blob knowledge source
PUT {{search-endpoint}}/knowledgesources/my-blob-ks?api-version=2026-11-01-preview
Authorization: Bearer {{search-access-token}}
Content-Type: application/json
{
"name": "my-blob-ks",
"kind": "azureBlob",
"description": "This knowledge source pulls from a blob storage container.",
"encryptionKey": null,
"azureBlobParameters": {
"connectionString": "ResourceId=<storage-resource-id>",
"containerName": "<blob-container-name>",
"folderPath": null,
"isADLSGen2": false,
"ingestionParameters": {
"networkAccessMode": "public",
"identity": null,
"disableImageVerbalization": null,
"chatCompletionModel": {
"kind": "azureOpenAI",
"azureOpenAIParameters": {
"resourceUri": "{{aoai-endpoint}}",
"deploymentId": "{{aoai-gpt-deployment}}",
"modelName": "{{aoai-gpt-model}}"
}
},
"embeddingModel": {
"kind": "azureOpenAI",
"azureOpenAIParameters": {
"resourceUri": "{{aoai-endpoint}}",
"deploymentId": "{{aoai-embedding-deployment}}",
"modelName": "{{aoai-embedding-model}}"
}
},
"contentExtractionMode": "minimal",
"ingestionSchedule": null,
"ingestionPermissionOptions": ["rbacScope"]
}
}
}
Reference: Knowledge Sources - Create or Update
Configure the ingestion schedule
Set ingestionParameters.ingestionSchedule to control how often the generated indexer polls for source changes. Eligible unfinished ingestion can continue automatically after an execution-time stop without waiting for the next poll.
Configure standard extraction
To use Content Understanding for layout extraction and semantic chunking instead of the minimal extraction in the preceding examples, set contentExtractionMode to standard and configure aiServices with your Foundry resource endpoint. Use the resource and deployments described in Prerequisites.
Standard extraction incurs Content Understanding charges and, when image verbalization is enabled, model usage charges. For more information, see billing and image description controls.
Restrict ingestion to a private network
In the stable 2026-10-01 API, networkAccessMode controls the network environment in which the generated indexer for a blob knowledge source runs. This setting affects ingestion only and doesn't change knowledge base retrieve requests or responses. Check the shared private link support matrix for eligible configurations. Independent preview features, such as automatic per-language analyzers and image serving, retain their own API requirements.
networkAccessMode defaults to public, which preserves existing public network behavior. When networkAccessMode is private, the generated indexer runs in the private execution environment. It uses approved shared private links to access the Azure Blob Storage or ADLS Gen2 source connection and supported Azure dependencies, such as Azure OpenAI models and Microsoft Foundry resources.
To configure and verify private network access:
Complete the private network prerequisites.
Set
networkAccessModetoprivatein the knowledge source creation request. You can only set this property during creation, including in the stable2026-10-01API. To change the stored mode later, delete and recreate the knowledge source. Eligible Blob, ADLS Gen2, and Azure SQL sources can instead use the interim generated-indexer networking override. That exception doesn't apply to indexed SharePoint or other source kinds.Creation can fail if the service tier or runtime doesn't support private execution or if a required shared private link doesn't exist. Serverless and S3 HD don't support private execution. Network security perimeter configuration controls supported public-endpoint access, not private execution.
Confirm that the generated indexer's
parameters.configuration.executionEnvironmentisprivate.Confirm that each required shared private link is approved, provisioned, and targets the correct dependency. Successful creation alone doesn't confirm link approval or targeting. If a portal check can't resolve a cross-subscription resource, manually verify approval and readiness on the target resource and Foundry IQ service.
Poll the knowledge source status until
lastSynchronizationState.endTimehas a value. Confirm thatitemsUpdatesFailedis0, and then verify the connector-specific source content. Synchronization fails if a dependency isn't reachable.
Use automatic per-language analyzers (preview)
Starting with the 2026-08-01-preview API version, automatic per-language analyzers are available for blob, indexed OneLake, and indexed SharePoint knowledge sources. When enabled, Foundry IQ (Azure AI Search) detects each source document's language and automatically applies a matching Microsoft language analyzer. You don't specify an analyzer in the knowledge source definition or in a query.
To enable automatic per-language analyzers, set contentExtractionMode to minimal and configure ingestionParameters.aiServices in the knowledge source definition.
For keyless authentication, omit aiServices.apiKey and assign the Cognitive Services User role on your Microsoft Foundry resource to the managed identity of your Foundry IQ service. For key-based authentication, set aiServices.apiKey to a valid key for your Foundry resource.
The following languages are supported:
- English
- Japanese
- French
- Spanish
- German
- Dutch
- Italian
- Brazilian Portuguese
- European Portuguese
- Simplified Chinese
- Traditional Chinese
- Korean
For multilingual content, Foundry IQ selects an analyzer based on the predominant detected language. It uses the standard analyzer when the language is unsupported or uncertain.
When you enable automatic per-language analyzers, Foundry IQ adds language-specific content fields for every supported language to the generated index schema, whether or not your data contains documents in those languages. During ingestion, documents are routed to the appropriate language-specific field based on their detected language.
Unused language fields don't contain indexed content and have minimal storage impact, but they remain part of the index schema and count toward the index field limit. Consider the additional fields when you plan your index design, field count, and storage requirements. For more information, see Index limits and Estimate and manage capacity of a Foundry IQ service.
Language detection is billable after the free AI enrichment allocation. For more information, see Free enrichments.
After ingestion, verify language routing without editing the generated objects:
- Inspect the generated index schema. Confirm that language-specific fields have their matching analyzers, such as
snippet_enwithen.microsoft, and thatsnippet_defaultprovides the standard-analyzer fallback. - Confirm that the generated semantic configuration lists the language-specific content fields and
snippet_default. - Inspect indexed chunks for a document detected as a supported language. Each chunk's text belongs in the corresponding language field. Unsupported or uncertain detection routes text to
snippet_default. - Read content from the populated language or fallback field. In this mode, the generated schema doesn't include a separate
snippetfield.
If the schema or results don't match, review the activation settings above and indexer errors. These checks don't define an update or migration procedure for an existing generated index.
Check ingestion status
Run the following code to monitor ingestion progress and health, including the knowledge source kind and detailed indexing errors for knowledge sources that generate an indexer pipeline and populate a search index.
using Azure.Search.Documents.Indexes;
using System.Text.Json;
var indexClient = new SearchIndexClient(new Uri(searchEndpoint), new AzureKeyCredential(apiKey));
// Get knowledge source ingestion status
var statusResponse = await indexClient.GetKnowledgeSourceStatusAsync(knowledgeSourceName);
var status = statusResponse.Value;
// Serialize to JSON for display
var json = JsonSerializer.Serialize(status, new JsonSerializerOptions { WriteIndented = true });
Console.WriteLine(json);
Reference: SearchIndexClient
# Check knowledge source ingestion status
from azure.core.credentials import AzureKeyCredential
from azure.search.documents.indexes import SearchIndexClient
import json
index_client = SearchIndexClient(endpoint="search_url", credential=AzureKeyCredential("api_key"))
status = index_client.get_knowledge_source_status("knowledge_source_name")
print(json.dumps(status.as_dict(), indent=2))
Reference: SearchIndexClient
### Check knowledge source ingestion status
GET {{search-url}}/knowledgesources/{{knowledge-source-name}}/status?api-version={{api-version}}
Authorization: Bearer {{token}}
Content-Type: application/json
Reference: Knowledge Sources - Get Status
A response for a request that includes ingestion parameters and is actively ingesting content might look like the following example.
{
"kind": "azureBlob",
"synchronizationStatus": "active",
"synchronizationInterval": "1d",
"currentSynchronizationState": {
"startTime": "2026-04-10T19:30:00Z",
"itemUpdatesProcessed": 1100,
"itemsUpdatesFailed": 100,
"itemsSkipped": 1100,
"errors": [
{
"key": "Item id 1",
"docURL": "https://contoso.blob.core.windows.net/contracts/2024/Q4/doc-00023.csv",
"statusCode": 400,
"componentName": "DocumentExtraction.AzureBlob.MyDataSource",
"errorMessage": "Could not read the value of column 'foo' at index '0'.",
"details": "The file could not be parsed.",
"documentationLink": "https://go.microsoft.com/fwlink/?linkid=2049388"
}
]
},
"lastSynchronizationState": {
"status": "partialSuccess",
"startTime": "2026-04-09T19:30:00Z",
"endTime": "2026-04-09T19:40:01Z",
"itemUpdatesProcessed": 1100,
"itemsUpdatesFailed": 100,
"itemsSkipped": 1100,
"errors": null
},
"statistics": {
"totalSynchronizations": 25,
"averageSynchronizationDuration": "00:15:20",
"averageItemsProcessedPerSynchronization": 500
}
}
Note
The kind property and currentSynchronizationState.errors[] array with document-level error details are available starting with the 2026-04-01 API version. For earlier API versions, these fields aren't returned. The lastSynchronizationState.status field is also new in 2026-04-01.
Review the generated objects
When you create this knowledge source, Foundry IQ (Azure AI Search) automatically generates a data source, indexer, and index, plus a skillset when the ingestion pipeline requires one. The creation response lists each object under createdResources.
These objects are generated according to a fixed template, and their names are based on the name of the knowledge source. You can't change the object names. Avoid editing these objects directly, as changes can introduce errors or incompatibilities that break the indexer pipeline.
For eligible Blob, ADLS Gen2, and Azure SQL sources only, the interim networking override permits changing the generated indexer's execution environment. This exception doesn't apply to indexed SharePoint or OneLake, and doesn't permit other generated-object changes. Later knowledge-source updates or regeneration can overwrite the override.
You can use the Azure portal to validate object creation. The workflow is:
Check the indexer for success or failure messages. Connection or quota errors appear here.
Check the data source to verify the connection to your data store. The connection uses either a connection string or a managed identity, depending on how you configured the knowledge source.
If a skillset is generated, check its enrichment and vectorization settings. SQL knowledge sources generate a skillset only when you specify
embeddingColumns.Check the index to see how your content is indexed and exposed for retrieval, including which fields are searchable and filterable and which fields store vectors for similarity search. Use Search Explorer to run queries against the generated index.
Treat the generated data source, indexer, index, and skillset, if present, as one ingestion configuration. Restrict who can change that configuration or publish documents to its index. Generated identifiers and permission field names don't establish document ownership or make ordinary content an authorized source of grants. Follow the preventive ingestion guidance and the documented customization boundaries; don't use arbitrary direct edits to generated keys or mappings as an ownership control.
Assign to a knowledge base
If you're satisfied with the knowledge source, add it to a knowledge base.
Query a knowledge base
After you configure the knowledge base, call the retrieve action or MCP endpoint to query the knowledge source. Choose the configuration that matches your scenario.
Enforce document-level permissions
Use the default extraction option (contentExtractionMode: "minimal") or Content Understanding-based standard extraction (contentExtractionMode: "standard") where supported. Every generated chunk retains the source item's permission metadata and source context. Document-level permissions don't support specialized customer-selected parsing modes. See Supported parsing and content extraction for permission ingestion. Configure these options on the knowledge source; don't change generated parser settings.
Set ingestionPermissionOptions when you create the knowledge source with REST API 2026-10-01:
- For standard Blob Storage, set
isADLSGen2tofalseand requestrbacScope. See the complete Blob REST configuration. - For ADLS Gen2, set
isADLSGen2totrueand requestuserIds,groupIds, andrbacScope. Start with the ADLS REST configuration, and addrbacScopeto itsingestionPermissionOptionsarray to ingest both ACLs and container RBAC scopes.
The generated index includes metadata_storage_path and the configured permission fields, with mappings on projected chunks. The path is required for ADLS permission ingestion, including RBAC-only ingestion. Its presence in a generated standard Blob schema doesn't make it a requirement for calculating a direct Blob indexer's container scope.
Review the generated index, skillset projections, and indexer together. Preserve source-path context and authoritative permission mappings on every protected chunk. For existing records with missing values, correcting the schema alone doesn't backfill metadata; follow schema and projection remediation.
Generated ADLS indexers follow the automatic ACL refresh settings and cadence. Configure parameters.configuration.refreshAllAcls on the generated indexer. For an on-demand refresh, use that indexer's name in the permissions resync procedure.
Include the delegated user's access token in the retrieve request. For the request headers, see Enforce permissions at query time.
Surface document-embedded images (preview)
To surface document-embedded images (such as diagrams or scans) in answer synthesis responses, configure assetStore on this knowledge source, and then enable image serving on the knowledge base. Image serving isn't supported when ingestionPermissionOptions is configured. For more information, see Surface document-embedded images in agentic retrieval (preview).
Delete a knowledge source
Before you can delete a knowledge source, you must delete any knowledge base that references it or update the knowledge base definition to remove the reference. For knowledge sources that generate an index and indexer pipeline, all generated objects are also deleted. However, if you used an existing index to create a knowledge source, your index isn't deleted.
If you try to delete a knowledge source that's in use, the action fails and returns a list of affected knowledge bases.
To delete a knowledge source:
Get a list of all knowledge bases on your Foundry IQ service.
using Azure.Search.Documents.Indexes; var indexClient = new SearchIndexClient(new Uri(searchEndpoint), credential); var knowledgeBases = indexClient.GetKnowledgeBasesAsync(); Console.WriteLine("Knowledge Bases:"); await foreach (var kb in knowledgeBases) { Console.WriteLine($" - {kb.Name}"); }Reference: SearchIndexClient
An example response might look like the following:
{ "@odata.context": "https://my-search-service.search.windows.net/$metadata#knowledgebases(name)", "value": [ { "name": "my-kb" }, { "name": "my-kb-2" } ] }Get an individual knowledge base definition to check for knowledge source references.
using Azure.Search.Documents.Indexes; using System.Text.Json; var indexClient = new SearchIndexClient(new Uri(searchEndpoint), credential); // Specify the knowledge base name to retrieve string kbNameToGet = "earth-knowledge-base"; // Get a specific knowledge base definition var knowledgeBaseResponse = await indexClient.GetKnowledgeBaseAsync(kbNameToGet); var kb = knowledgeBaseResponse.Value; // Serialize to JSON for display string json = JsonSerializer.Serialize(kb, new JsonSerializerOptions { WriteIndented = true }); Console.WriteLine(json);Reference: SearchIndexClient
An example response might look like the following:
{ "Name": "earth-knowledge-base", "KnowledgeSources": [ { "Name": "earth-knowledge-source" } ], "Models": [ {} ], "RetrievalReasoningEffort": {}, "OutputMode": {}, "ETag": "\u00220x8DE278629D782B3\u0022", "EncryptionKey": null, "Description": null, "RetrievalInstructions": null, "AnswerInstructions": null }Either delete the knowledge base or, if you have multiple knowledge sources, update the knowledge base to remove the source. This example shows deletion.
using Azure.Search.Documents.Indexes; var indexClient = new SearchIndexClient(new Uri(searchEndpoint), credential); await indexClient.DeleteKnowledgeBaseAsync(knowledgeBaseName); System.Console.WriteLine($"Knowledge base '{knowledgeBaseName}' deleted successfully.");Reference: SearchIndexClient
Delete the knowledge source.
await indexClient.DeleteKnowledgeSourceAsync(knowledgeSourceName); System.Console.WriteLine($"Knowledge source '{knowledgeSourceName}' deleted successfully.");Reference: SearchIndexClient
Get a list of all knowledge bases on your Foundry IQ service.
# Get knowledge bases from azure.core.credentials import AzureKeyCredential from azure.search.documents.indexes import SearchIndexClient index_client = SearchIndexClient(endpoint = "search_url", credential = AzureKeyCredential("api_key")) print("Knowledge Bases:") for kb in index_client.list_knowledge_bases(): print(f" - {kb.name}")Reference: SearchIndexClient
An example response might look like the following:
{ "@odata.context": "https://my-search-service.search.windows.net/$metadata#knowledgebases(name)", "value": [ { "name": "my-kb" }, { "name": "my-kb-2" } ] }Get an individual knowledge base definition to check for knowledge source references.
# Get a knowledge base definition from azure.core.credentials import AzureKeyCredential from azure.search.documents.indexes import SearchIndexClient index_client = SearchIndexClient(endpoint = "search_url", credential = AzureKeyCredential("api_key")) kb = index_client.get_knowledge_base("knowledge_base_name") print(kb)Reference: SearchIndexClient
An example response might look like the following:
{ "name": "my-kb", "description": null, "retrievalInstructions": null, "answerInstructions": null, "outputMode": null, "knowledgeSources": [ { "name": "my-blob-ks" } ], "models": [], "encryptionKey": null, "retrievalReasoningEffort": { "kind": "low" } }Either delete the knowledge base or, if you have multiple knowledge sources, update the knowledge base to remove the source. This example shows deletion.
# Delete a knowledge base from azure.core.credentials import AzureKeyCredential from azure.search.documents.indexes import SearchIndexClient index_client = SearchIndexClient(endpoint = "search_url", credential = AzureKeyCredential("api_key")) index_client.delete_knowledge_base("knowledge_base_name") print(f"Knowledge base deleted successfully.")Reference: SearchIndexClient
Delete the knowledge source.
# Delete a knowledge source from azure.core.credentials import AzureKeyCredential from azure.search.documents.indexes import SearchIndexClient index_client = SearchIndexClient(endpoint = "search_url", credential = AzureKeyCredential("api_key")) index_client.delete_knowledge_source("knowledge_source_name") print(f"Knowledge source deleted successfully.")Reference: SearchIndexClient
Get a list of all knowledge bases on your Foundry IQ service.
### Get knowledge bases GET {{search-url}}/knowledgebases?api-version={{api-version}}&$select=name Authorization: Bearer {{token}}Reference: Knowledge Bases - List
An example response might look like the following:
{ "@odata.context": "https://my-search-service.search.windows.net/$metadata#knowledgebases(name)", "value": [ { "name": "my-kb" }, { "name": "my-kb-2" } ] }Get an individual knowledge base definition to check for knowledge source references.
### Get a knowledge base definition GET {{search-url}}/knowledgebases('{{knowledge-base-name}}')?api-version={{api-version}} Authorization: Bearer {{token}}Reference: Knowledge Bases - Get
An example response might look like the following:
{ "name": "my-kb", "description": null, "retrievalInstructions": null, "answerInstructions": null, "outputMode": null, "knowledgeSources": [ { "name": "my-blob-ks" } ], "models": [], "encryptionKey": null, "retrievalReasoningEffort": { "kind": "low" } }Either delete the knowledge base or, if you have multiple knowledge sources, update the knowledge base to remove the source. This example shows deletion.
### Delete a knowledge base DELETE {{search-url}}/knowledgebases('{{knowledge-base-name}}')?api-version={{api-version}} Authorization: Bearer {{token}}Reference: Knowledge Bases - Delete
Delete the knowledge source.
### Delete a knowledge source DELETE {{search-url}}/knowledgesources('{{knowledge-source-name}}')?api-version={{api-version}} Authorization: Bearer {{token}}Reference: Knowledge Sources - Delete