Microsoft Azure Data Sources API

The Data Sources API from Microsoft Azure, for data sources.

GitHub OpenAPI

Operations 8

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

PUT /datasources/{dataSourceName} Register or update a Purview data source · Microsoft Azure Put Datasources Datasourcename #
Ask an LLM
“Can I register a new data source for Purview scanning?”
“Which kind must I specify when registering a data source in the data catalog?”
Tell an agent
Register Purview data source {dataSourceName} of kind {kind}.
Update the registered scanning source {dataSourceName} with scans {scans}.
GET /datasources/{dataSourceName} Get a registered Purview data source · Microsoft Azure Get Datasources Datasourcename #
Ask an LLM
“How do I look up a data source registered in Microsoft Purview scanning?”
“What kind and scans does a registered Purview data source have?”
Tell an agent
Get Purview data source {dataSourceName}.
Show the registration details of scanning data source {dataSourceName}.
DELETE /datasources/{dataSourceName} Unregister a Purview data source · Microsoft Azure Delete Datasources Datasourcename #
Ask an LLM
“How do I remove a data source from Purview scanning?”
“Does deleting a registered Purview source also drop its scans?”
Tell an agent destructive · confirm first
Delete Purview data source {dataSourceName}.
Unregister scanning source {dataSourceName} from the data catalog.
GET /datasources List data sources registered in Purview · Microsoft Azure Get Datasources #
Ask an LLM
“Which data sources are registered in my Purview data catalog?”
“Can I see every scanning source the catalog knows about?”
Tell an agent
List all data sources registered in the Purview data catalog.
Show the Purview scanning sources using API version {api_version}.
POST /datasources Create a search indexer data source · Microsoft Azure Post Datasources #
Ask an LLM
“How do I create a data source for an Azure AI Search indexer?”
“What credentials and container does a new search datasource need?”
Tell an agent
Create search datasource {name} of type {type} pointing at container {container}.
Add an indexer datasource {name} using connection credentials {credentials}.
PUT /datasources('{dataSourceName}') Create or update a search indexer data source · Microsoft Azure Put Datasources Datasourcename #
Ask an LLM
“Can I overwrite an existing search indexer datasource only if its ETag matches?”
“How do I upsert a datasource definition used by a search indexer?”
Tell an agent
Create or update search datasource {dataSourceName} of type {type} on container {container}.
Replace indexer datasource {dataSourceName} only if ETag {ifMatch} still matches.
DELETE /datasources('{dataSourceName}') Delete a search indexer data source · Microsoft Azure Delete Datasources Datasourcename #
Ask an LLM
“How do I delete a datasource used by a search indexer?”
“Can I make deleting a search datasource conditional on its ETag?”
Tell an agent destructive · confirm first
Delete search datasource {dataSourceName}.
Delete indexer datasource {dataSourceName} if its ETag is {ifMatch}.
GET /datasources('{dataSourceName}') Get a search indexer data source definition · Microsoft Azure Get Datasources Datasourcename #
Ask an LLM
“Can I retrieve the definition of an existing search indexer datasource?”
“What change detection policy is set on a search datasource?”
Tell an agent
Get the search datasource definition for {dataSourceName}.
Show indexer datasource {dataSourceName} and its connection container.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/microsoft-azure:microsoft-azure-data-sources-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

microsoft-azure-data-sources-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Microsoft Azure MicrosoftScanningClient Data Sources API
  description: Creates a Microsoft.Scanning management client.
  version: 2022-07-01-preview
servers:
- url: https://purview.azure.com/scan
security:
- azure_auth:
  - user_impersonation
tags:
- name: Data Sources
paths:
  /datasources/{dataSourceName}:
    put:
      tags:
      - Data Sources
      description: Creates or Updates a data source
      operationId: microsoftAzureDatasourcesCreateorupdate
      parameters:
      - in: path
        name: dataSourceName
        required: true
        schema:
          type: string
      - $ref: '#/components/parameters/api-version'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataSource'
        '201':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataSource'
        default:
          description: An error response received from the Scanning Service
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponseModel'
      x-ms-examples:
        DataSources_CreateOrUpdate:
          $ref: ./examples/DataSources_CreateOrUpdate.json
      summary: Microsoft Azure Put Datasources Datasourcename
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DataSource'
    get:
      tags:
      - Data Sources
      description: Get a data source
      operationId: microsoftAzureDatasourcesGet
      parameters:
      - in: path
        name: dataSourceName
        required: true
        schema:
          type: string
      - $ref: '#/components/parameters/api-version'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataSource'
        default:
          description: An error response received from the Scanning Service
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponseModel'
      x-ms-examples:
        DataSources_Get:
          $ref: ./examples/DataSources_Get.json
      summary: Microsoft Azure Get Datasources Datasourcename
    delete:
      tags:
      - Data Sources
      description: Deletes a data source
      operationId: microsoftAzureDatasourcesDelete
      parameters:
      - in: path
        name: dataSourceName
        required: true
        schema:
          type: string
      - $ref: '#/components/parameters/api-version'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataSource'
        '204':
          description: Success
        default:
          description: An error response received from the Scanning Service
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponseModel'
      x-ms-examples:
        DataSources_Delete:
          $ref: ./examples/DataSources_Delete.json
      summary: Microsoft Azure Delete Datasources Datasourcename
  /datasources:
    get:
      tags:
      - Data Sources
      description: List data sources in Data catalog
      operationId: microsoftAzureDatasourcesListall
      parameters:
      - $ref: '#/components/parameters/api-version'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataSourceList'
        default:
          description: An error response received from the Scanning Service
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponseModel'
      x-ms-examples:
        DataSources_ListAll:
          $ref: ./examples/DataSources_ListAll.json
      x-ms-pageable:
        nextLinkName: nextLink
      summary: Microsoft Azure Get Datasources
    post:
      tags:
      - Data Sources
      operationId: microsoftAzureDatasourcesCreate
      x-ms-examples:
        SearchServiceCreateDataSource:
          $ref: ./examples/SearchServiceCreateDataSource.json
      description: Creates a new datasource.
      externalDocs:
        url: https://docs.microsoft.com/rest/api/searchservice/Create-Data-Source
      parameters:
      - $ref: '#/components/parameters/ClientRequestIdParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      x-ms-request-id: request-id
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchIndexerDataSource'
        default:
          description: Error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchError'
      summary: Microsoft Azure Post Datasources
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SearchIndexerDataSource'
        description: The definition of the datasource to create.
        required: true
  /datasources('{dataSourceName}'):
    put:
      tags:
      - Data Sources
      operationId: microsoftAzureDatasourcesCreateorupdate
      x-ms-examples:
        SearchServiceCreateOrUpdateDataSource:
          $ref: ./examples/SearchServiceCreateOrUpdateDataSource.json
      description: Creates a new datasource or updates a datasource if it already exists.
      externalDocs:
        url: https://docs.microsoft.com/rest/api/searchservice/Update-Data-Source
      parameters:
      - name: dataSourceName
        in: path
        required: true
        description: The name of the datasource to create or update.
        schema:
          type: string
      - $ref: '#/components/parameters/ClientRequestIdParameter'
      - $ref: '#/components/parameters/IfMatchParameter'
      - $ref: '#/components/parameters/IfNoneMatchParameter'
      - $ref: '#/components/parameters/PreferHeaderParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      x-ms-request-id: request-id
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchIndexerDataSource'
        '201':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchIndexerDataSource'
        default:
          description: Error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchError'
      summary: Microsoft Azure Put Datasources Datasourcename
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SearchIndexerDataSource'
        description: The definition of the datasource to create or update.
        required: true
    delete:
      tags:
      - Data Sources
      operationId: microsoftAzureDatasourcesDelete
      x-ms-examples:
        SearchServiceDeleteDataSource:
          $ref: ./examples/SearchServiceDeleteDataSource.json
      description: Deletes a datasource.
      externalDocs:
        url: https://docs.microsoft.com/rest/api/searchservice/Delete-Data-Source
      parameters:
      - name: dataSourceName
        in: path
        required: true
        description: The name of the datasource to delete.
        schema:
          type: string
      - $ref: '#/components/parameters/ClientRequestIdParameter'
      - $ref: '#/components/parameters/IfMatchParameter'
      - $ref: '#/components/parameters/IfNoneMatchParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      x-ms-request-id: request-id
      responses:
        '204':
          description: ''
        '404':
          description: ''
        default:
          description: Error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchError'
      summary: Microsoft Azure Delete Datasources Datasourcename
    get:
      tags:
      - Data Sources
      operationId: microsoftAzureDatasourcesGet
      x-ms-examples:
        SearchServiceGetDataSource:
          $ref: ./examples/SearchServiceGetDataSource.json
      description: Retrieves a datasource definition.
      externalDocs:
        url: https://docs.microsoft.com/rest/api/searchservice/Get-Data-Source
      parameters:
      - name: dataSourceName
        in: path
        required: true
        description: The name of the datasource to retrieve.
        schema:
          type: string
      - $ref: '#/components/parameters/ClientRequestIdParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      x-ms-request-id: request-id
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchIndexerDataSource'
        default:
          description: Error response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SearchError'
      summary: Microsoft Azure Get Datasources Datasourcename
components:
  schemas:
    ErrorModel:
      type: object
      properties:
        code:
          type: string
        message:
          type: string
        target:
          type: string
        details:
          type: array
          items:
            $ref: '#/components/schemas/ErrorModel'
    DataSourceList:
      required:
      - value
      type: object
      properties:
        value:
          type: array
          items:
            $ref: '#/components/schemas/DataSource'
        nextLink:
          type: string
        count:
          format: int64
          type: integer
    Scan:
      required:
      - kind
      type: object
      allOf:
      - $ref: '#/components/schemas/ProxyResource'
      properties:
        kind:
          enum:
          - AzureSubscriptionCredential
          - AzureSubscriptionMsi
          - AzureResourceGroupCredential
          - AzureResourceGroupMsi
          - AzureSynapseWorkspaceCredential
          - AzureSynapseWorkspaceMsi
          - AzureSynapseCredential
          - AzureSynapseMsi
          - AdlsGen1Credential
          - AdlsGen1Msi
          - AdlsGen2Credential
          - AdlsGen2Msi
          - AmazonAccountCredential
          - AmazonS3Credential
          - AmazonS3RoleARN
          - AmazonSqlCredential
          - AzureCosmosDbCredential
          - AzureDataExplorerCredential
          - AzureDataExplorerMsi
          - AzureFileServiceCredential
          - AzureSqlDatabaseCredential
          - AzureSqlDatabaseMsi
          - AmazonPostgreSqlCredential
          - AzurePostgreSqlCredential
          - SqlServerDatabaseCredential
          - AzureSqlDatabaseManagedInstanceCredential
          - AzureSqlDatabaseManagedInstanceMsi
          - AzureSqlDataWarehouseCredential
          - AzureSqlDataWarehouseMsi
          - AzureMySqlCredential
          - AzureStorageCredential
          - AzureStorageMsi
          - TeradataTeradataCredential
          - TeradataTeradataUserPass
          - TeradataUserPass
          - OracleOracleCredential
          - OracleOracleUserPass
          - SapS4HanaSapS4HanaCredential
          - SapS4HanaSapS4HanaUserPass
          - SapEccSapEccCredential
          - SapEccSapEccUserPass
          - PowerBIDelegated
          - PowerBIMsi
          type: string
          x-ms-enum:
            name: ScanAuthorizationType
            modelAsString: true
        scanResults:
          type: array
          items:
            $ref: '#/components/schemas/ScanResult'
          readOnly: true
      discriminator:
        propertyName: kind
    DataSource:
      required:
      - kind
      type: object
      allOf:
      - $ref: '#/components/schemas/ProxyResource'
      properties:
        kind:
          enum:
          - None
          - AzureSubscription
          - AzureResourceGroup
          - AzureSynapseWorkspace
          - AzureSynapse
          - AdlsGen1
          - AdlsGen2
          - AmazonAccount
          - AmazonS3
          - AmazonSql
          - AzureCosmosDb
          - AzureDataExplorer
          - AzureFileService
          - AzureSqlDatabase
          - AmazonPostgreSql
          - AzurePostgreSql
          - SqlServerDatabase
          - AzureSqlDatabaseManagedInstance
          - AzureSqlDataWarehouse
          - AzureMySql
          - AzureStorage
          - Teradata
          - Oracle
          - SapS4Hana
          - SapEcc
          - PowerBI
          type: string
          x-ms-enum:
            name: DataSourceType
            modelAsString: true
        scans:
          type: array
          items:
            $ref: '#/components/schemas/Scan'
          readOnly: true
      discriminator:
        propertyName: kind
    ScanDiagnostics:
      type: object
      properties:
        notifications:
          type: array
          items:
            $ref: '#/components/schemas/Notification'
        exceptionCountMap:
          type: object
          additionalProperties:
            format: int32
            type: integer
          readOnly: true
    ErrorResponseModel:
      type: object
      properties:
        error:
          allOf:
          - $ref: '#/components/schemas/ErrorModel'
    ScanResult:
      type: object
      properties:
        parentId:
          type: string
          readOnly: true
        id:
          type: string
          readOnly: true
        resourceId:
          type: string
          readOnly: true
        status:
          type: string
          readOnly: true
        assetsDiscovered:
          format: int64
          type: integer
          readOnly: true
        assetsClassified:
          format: int64
          type: integer
          readOnly: true
        diagnostics:
          allOf:
          - $ref: '#/components/schemas/ScanDiagnostics'
          readOnly: true
        startTime:
          format: date-time
          type: string
          readOnly: true
        queuedTime:
          format: date-time
          type: string
          readOnly: true
        pipelineStartTime:
          format: date-time
          type: string
          readOnly: true
        endTime:
          format: date-time
          type: string
          readOnly: true
        scanRulesetVersion:
          format: int32
          type: integer
          readOnly: true
        scanRulesetType:
          enum:
          - Custom
          - System
          type: string
          readOnly: true
          x-ms-enum:
            name: ScanRulesetType
            modelAsString: true
        scanLevelType:
          enum:
          - Full
          - Incremental
          type: string
          readOnly: true
          x-ms-enum:
            name: ScanLevelType
            modelAsString: true
        errorMessage:
          type: string
          readOnly: true
        error:
          allOf:
          - $ref: '#/components/schemas/ErrorModel'
          readOnly: true
        runType:
          type: string
          readOnly: true
        dataSourceType:
          enum:
          - None
          - AzureSubscription
          - AzureResourceGroup
          - AzureSynapseWorkspace
          - AzureSynapse
          - AdlsGen1
          - AdlsGen2
          - AmazonAccount
          - AmazonS3
          - AmazonSql
          - AzureCosmosDb
          - AzureDataExplorer
          - AzureFileService
          - AzureSqlDatabase
          - AmazonPostgreSql
          - AzurePostgreSql
          - SqlServerDatabase
          - AzureSqlDatabaseManagedInstance
          - AzureSqlDataWarehouse
          - AzureMySql
          - AzureStorage
          - Teradata
          - Oracle
          - SapS4Hana
          - SapEcc
          - PowerBI
          type: string
          readOnly: true
          x-ms-enum:
            name: DataSourceType
            modelAsString: true
    Notification:
      type: object
      properties:
        message:
          type: string
        code:
          format: int32
          type: integer
    ProxyResource:
      type: object
      properties:
        id:
          type: string
          readOnly: true
        name:
          type: string
          readOnly: true
    SearchError:
      properties:
        code:
          type: string
          readOnly: true
          description: One of a server-defined set of error codes.
        message:
          type: string
          readOnly: true
          description: A human-readable representation of the error.
        details:
          type: array
          items:
            $ref: '#/components/schemas/SearchError'
          readOnly: true
          description: An array of details about specific errors that led to this reported error.
      required:
      - message
      description: Describes an error condition for the Azure Cognitive Search API.
    SearchIndexerDataSource:
      properties:
        name:
          externalDocs:
            url: https://docs.microsoft.com/rest/api/searchservice/Naming-rules
          type: string
          description: The name of the datasource.
        description:
          type: string
          description: The description of the datasource.
        type:
          $ref: '#/components/schemas/SearchIndexerDataSourceType'
          description: The type of the datasource.
        credentials:
          $ref: '#/components/schemas/DataSourceCredentials'
          description: Credentials for the datasource.
        container:
          $ref: '#/components/schemas/SearchIndexerDataContainer'
          description: The data container for the datasource.
        dataChangeDetectionPolicy:
          $ref: '#/components/schemas/DataChangeDetectionPolicy'
          description: The data change detection policy for the datasource.
        dataDeletionDetectionPolicy:
          $ref: '#/components/schemas/DataDeletionDetectionPolicy'
          description: The data deletion detection policy for the datasource.
        '@odata.etag':
          x-ms-client-name: ETag
          type: string
          description: The ETag of the data source.
      required:
      - name
      - type
      - credentials
      - container
      description: Represents a datasource definition, which can be used to configure an indexer.
    SearchIndexerDataContainer:
      properties:
        name:
          type: string
          description: The name of the table or view (for Azure SQL data source) or collection (for CosmosDB data source) that will be indexed.
        query:
          type: string
          description: A query that is applied to this data container. The syntax and meaning of this parameter is datasource-specific. Not supported by Azure SQL datasources.
      required:
      - name
      description: Represents information about the entity (such as Azure SQL table or CosmosDB collection) that will be indexed.
    ListDataSourcesResult:
      properties:
        value:
          x-ms-client-name: DataSources
          type: array
          readOnly: true
          items:
            $ref: '#/components/schemas/SearchIndexerDataSource'
          description: The datasources in the Search service.
      required:
      - value
      description: Response from a List Datasources request. If successful, it includes the full definitions of all datasources.
    DataDeletionDetectionPolicy:
      discriminator:
        propertyName: '@odata.type'
      properties:
        '@odata.type':
          type: string
          description: Identifies the concrete type of the data deletion detection policy.
      required:
      - '@odata.type'
      description: Base type for data deletion detection policies.
    DataChangeDetectionPolicy:
      discriminator:
        propertyName: '@odata.type'
      properties:
        '@odata.type':
          type: string
          description: Identifies the concrete type of the data change detection policy.
      required:
      - '@odata.type'
      description: Base type for data change detection policies.
    SearchIndexerDataSourceType:
      type: string
      enum:
      - azuresql
      - cosmosdb
      - azureblob
      - azuretable
      - mysql
      x-ms-enum:
        name: SearchIndexerDataSourceType
        modelAsString: true
        values:
        - value: azuresql
          name: AzureSql
          description: Indicates an Azure SQL datasource.
        - value: cosmosdb
          name: CosmosDb
          description: Indicates a CosmosDB datasource.
        - value: azureblob
          name: AzureBlob
          description: Indicates a Azure Blob datasource.
        - value: azuretable
          name: AzureTable
          description: Indicates a Azure Table datasource.
        - value: mysql
          name: MySql
          description: Indicates a MySql datasource.
      description: Defines the type of a datasource.
    DataSourceCredentials:
      properties:
        connectionString:
          externalDocs:
            url: https://docs.microsoft.com/rest/api/searchservice/Create-Data-Source
          type: string
          description: The connection string for the datasource.
      description: Represents credentials that can be used to connect to a datasource.
  parameters:
    api-version:
      in: query
      name: api-version
      description: The api version to use.
      required: true
      x-ms-client-name: ApiVersion
      schema:
        type: string
    PreferHeaderParameter:
      name: Prefer
      in: header
      required: true
      description: For HTTP PUT requests, instructs the service to return the created/updated resource on success.
      x-ms-parameter-location: method
      schema:
        type: string
        enum:
        - return=representation
    IfMatchParameter:
      name: If-Match
      in: header
      required: false
      description: Defines the If-Match condition. The operation will be performed only if the ETag on the server matches this value.
      x-ms-parameter-location: method
      schema:
        type: string
    ApiVersionParameter:
      name: api-version
      in: query
      required: true
      description: Client Api Version.
      schema:
        type: string
    IfNoneMatchParameter:
      name: If-None-Match
      in: header
      required: false
      description: Defines the If-None-Match condition. The operation will be performed only if the ETag on the server does not match this value.
      x-ms-parameter-location: method
      schema:
        type: string
    ClientRequestIdParameter:
      name: x-ms-client-request-id
      in: header
      required: false
      description: The tracking ID sent with the request to help with debugging.
      x-ms-client-request-id: true
      x-ms-parameter-grouping:
        name: request-options
      x-ms-parameter-location: method
      schema:
        type: string
        format: uuid
  securitySchemes:
    azure_auth:
      type: oauth2
      flows:
        implicit:
          scopes:
            user_impersonation: impersonate your user account
          authorizationUrl: https://login.microsoftonline.com/common/oauth2/authorize
      description: Azure Active Directory OAuth2 Flow.
x-ms-parameterized-host:
  hostTemplate: '{Endpoint}'
  useSchemePrefix: false
  parameters:
  - $ref: '#/components/parameters/Endpoint'