swagger: "2.0"
schemes:
  - https
host: management.azure.com
info:
  title: StreamAnalyticsManagementClient
  version: 2016-03-01
  x-apisguru-categories:
    - cloud
  x-logo:
    url: https://api.apis.guru/v2/cache/logo/https_assets.onestore.ms_cdnfiles_onestorerolling-1606-01000_shell_v3_images_logo_microsoft.png
  x-origin:
    - format: swagger
      url: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/streamanalytics/resource-manager/Microsoft.StreamAnalytics/stable/2016-03-01/functions.json
      version: "2.0"
  x-providerName: azure.com
  x-serviceName: streamanalytics-functions
  x-tags:
    - Azure
    - Microsoft
consumes:
  - application/json
produces:
  - application/json
securityDefinitions:
  azure_auth:
    authorizationUrl: https://login.microsoftonline.com/common/oauth2/authorize
    description: Azure Active Directory OAuth2 Flow
    flow: implicit
    scopes:
      user_impersonation: impersonate your user account
    type: oauth2
security:
  - azure_auth:
      - user_impersonation
parameters:
  ApiVersionParameter:
    description: Client Api Version.
    in: query
    name: api-version
    required: true
    type: string
  FunctionNameParameter:
    description: The name of the function.
    in: path
    name: functionName
    required: true
    type: string
    x-ms-parameter-location: method
  ResourceGroupNameParameter:
    description: The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
    in: path
    name: resourceGroupName
    required: true
    type: string
    x-ms-parameter-location: method
  StreamingJobNameParameter:
    description: The name of the streaming job.
    in: path
    name: jobName
    required: true
    type: string
    x-ms-parameter-location: method
  SubscriptionIdParameter:
    description: GUID which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
    in: path
    name: subscriptionId
    required: true
    type: string
paths:
  "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.StreamAnalytics/streamingjobs/{jobName}/functions":
    get:
      description: Lists all of the functions under the specified streaming job.
      operationId: Functions_ListByStreamingJob
      parameters:
        - description: The $select OData query parameter. This is a comma-separated list of structural properties to include in the response, or "*" to include all properties. By default, all properties are returned except diagnostics. Currently only accepts '*' as a valid value.
          in: query
          name: $select
          required: false
          type: string
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ResourceGroupNameParameter"
        - $ref: "#/parameters/StreamingJobNameParameter"
      responses:
        "200":
          description: Successfully listed the functions under the specified streaming job.
          schema:
            $ref: "#/definitions/FunctionListResult"
      tags:
        - Functions
      x-ms-examples:
        List all functions in a streaming job:
          parameters:
            api-version: 2016-03-01
            jobName: sj8653
            resourceGroupName: sjrg1637
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                value:
                  - id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg1637/providers/Microsoft.StreamAnalytics/streamingjobs/sj8653/functions/function588
                    name: function588
                    properties:
                      etag: 281cbf11-cd50-4a44-b833-cf170ce74748
                      properties:
                        binding:
                          properties:
                            batchSize: 5000
                            endpoint: someAzureMLEndpointURL
                            inputs:
                              columnNames:
                                - dataType: string
                                  mapTo: 0
                                  name: tweet
                              name: input1
                            outputs:
                              - dataType: string
                                name: Sentiment
                          type: Microsoft.MachineLearning/WebService
                        inputs:
                          - dataType: nvarchar(max)
                        output:
                          dataType: nvarchar(max)
                      type: Scalar
                    type: Microsoft.StreamAnalytics/streamingjobs/functions
                  - id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg1637/providers/Microsoft.StreamAnalytics/streamingjobs/sj8653/functions/function8197
                    name: function8197
                    properties:
                      etag: 94a512d5-2f59-4e39-b9c8-bca4abd74b7e
                      properties:
                        binding:
                          properties:
                            script: function (a, b) { return a * b; }
                          type: Microsoft.StreamAnalytics/JavascriptUdf
                        inputs:
                          - dataType: Any
                        output:
                          dataType: Any
                      type: Scalar
                    type: Microsoft.StreamAnalytics/streamingjobs/functions
      x-ms-pageable:
        nextLinkName: nextLink
  "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.StreamAnalytics/streamingjobs/{jobName}/functions/{functionName}":
    delete:
      description: Deletes a function from the streaming job.
      operationId: Functions_Delete
      parameters:
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ResourceGroupNameParameter"
        - $ref: "#/parameters/StreamingJobNameParameter"
        - $ref: "#/parameters/FunctionNameParameter"
      responses:
        "200":
          description: The function was successfully deleted.
        "204":
          description: The function does not exist.
      tags:
        - Functions
      x-ms-examples:
        Delete a function:
          parameters:
            api-version: 2016-03-01
            functionName: function8197
            jobName: sj8653
            resourceGroupName: sjrg1637
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200": {}
            "204": {}
    get:
      description: Gets details about the specified function.
      operationId: Functions_Get
      parameters:
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ResourceGroupNameParameter"
        - $ref: "#/parameters/StreamingJobNameParameter"
        - $ref: "#/parameters/FunctionNameParameter"
      responses:
        "200":
          description: Successfully retrieved the specified function.
          headers:
            ETag:
              description: The current entity tag for the function. This is an opaque string. You can use it to detect whether the resource has changed between requests. You can also use it in the If-Match or If-None-Match headers for write operations for optimistic concurrency.
              type: string
          schema:
            $ref: "#/definitions/Function"
      tags:
        - Functions
      x-ms-examples:
        Get a JavaScript function:
          parameters:
            api-version: 2016-03-01
            functionName: function8197
            jobName: sj8653
            resourceGroupName: sjrg1637
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg1637/providers/Microsoft.StreamAnalytics/streamingjobs/sj8653/functions/function8197
                name: function8197
                properties:
                  properties:
                    binding:
                      properties:
                        script: function (x, y) { return x + y; }
                      type: Microsoft.StreamAnalytics/JavascriptUdf
                    inputs:
                      - dataType: Any
                    output:
                      dataType: Any
                  type: Scalar
                type: Microsoft.StreamAnalytics/streamingjobs/functions
              headers:
                ETag: 07495b35-da28-4c28-a3ed-e0d75d0b6eff
        Get an Azure ML function:
          parameters:
            api-version: 2016-03-01
            functionName: function588
            jobName: sj9093
            resourceGroupName: sjrg7
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg7/providers/Microsoft.StreamAnalytics/streamingjobs/sj9093/functions/function588
                name: function588
                properties:
                  properties:
                    binding:
                      properties:
                        batchSize: 1000
                        endpoint: someAzureMLEndpointURL
                        inputs:
                          columnNames:
                            - dataType: string
                              mapTo: 0
                              name: tweet
                          name: input1
                        outputs:
                          - dataType: string
                            name: Sentiment
                      type: Microsoft.MachineLearning/WebService
                    inputs:
                      - dataType: nvarchar(max)
                    output:
                      dataType: nvarchar(max)
                  type: Scalar
                type: Microsoft.StreamAnalytics/streamingjobs/functions
              headers:
                ETag: dac52a15-66be-4aa7-8a18-20c5409983df
    patch:
      description: Updates an existing function under an existing streaming job. This can be used to partially update (ie. update one or two properties) a function without affecting the rest the job or function definition.
      operationId: Functions_Update
      parameters:
        - description: A function object. The properties specified here will overwrite the corresponding properties in the existing function (ie. Those properties will be updated). Any properties that are set to null here will mean that the corresponding property in the existing function will remain the same and not change as a result of this PATCH operation.
          in: body
          name: function
          required: true
          schema:
            $ref: "#/definitions/Function"
        - description: The ETag of the function. Omit this value to always overwrite the current function. Specify the last-seen ETag value to prevent accidentally overwriting concurrent changes.
          in: header
          name: If-Match
          required: false
          type: string
          x-ms-client-name: IfMatch
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ResourceGroupNameParameter"
        - $ref: "#/parameters/StreamingJobNameParameter"
        - $ref: "#/parameters/FunctionNameParameter"
      responses:
        "200":
          description: The function was successfully updated.
          headers:
            ETag:
              description: The current entity tag for the function. This is an opaque string. You can use it to detect whether the resource has changed between requests. You can also use it in the If-Match or If-None-Match headers for write operations for optimistic concurrency.
              type: string
          schema:
            $ref: "#/definitions/Function"
      tags:
        - Functions
      x-ms-examples:
        Update a JavaScript function:
          parameters:
            api-version: 2016-03-01
            function:
              properties:
                properties:
                  binding:
                    properties:
                      script: function (a, b) { return a * b; }
                    type: Microsoft.StreamAnalytics/JavascriptUdf
                type: Scalar
            functionName: function8197
            jobName: sj8653
            resourceGroupName: sjrg1637
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg1637/providers/Microsoft.StreamAnalytics/streamingjobs/sj8653/functions/function8197
                name: function8197
                properties:
                  properties:
                    binding:
                      properties:
                        script: function (a, b) { return a * b; }
                      type: Microsoft.StreamAnalytics/JavascriptUdf
                    inputs:
                      - dataType: Any
                    output:
                      dataType: Any
                  type: Scalar
                type: Microsoft.StreamAnalytics/streamingjobs/functions
              headers:
                ETag: 94a512d5-2f59-4e39-b9c8-bca4abd74b7e
        Update an Azure ML function:
          parameters:
            api-version: 2016-03-01
            function:
              properties:
                properties:
                  binding:
                    properties:
                      batchSize: 5000
                    type: Microsoft.MachineLearning/WebService
                type: Scalar
            functionName: function588
            jobName: sj9093
            resourceGroupName: sjrg7
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg7/providers/Microsoft.StreamAnalytics/streamingjobs/sj9093/functions/function588
                name: function588
                properties:
                  properties:
                    binding:
                      properties:
                        batchSize: 5000
                        endpoint: someAzureMLEndpointURL
                        inputs:
                          columnNames:
                            - dataType: string
                              mapTo: 0
                              name: tweet
                          name: input1
                        outputs:
                          - dataType: string
                            name: Sentiment
                      type: Microsoft.MachineLearning/WebService
                    inputs:
                      - dataType: nvarchar(max)
                    output:
                      dataType: nvarchar(max)
                  type: Scalar
                type: Microsoft.StreamAnalytics/streamingjobs/functions
              headers:
                ETag: 281cbf11-cd50-4a44-b833-cf170ce74748
    put:
      description: Creates a function or replaces an already existing function under an existing streaming job.
      operationId: Functions_CreateOrReplace
      parameters:
        - description: The definition of the function that will be used to create a new function or replace the existing one under the streaming job.
          in: body
          name: function
          required: true
          schema:
            $ref: "#/definitions/Function"
        - description: The ETag of the function. Omit this value to always overwrite the current function. Specify the last-seen ETag value to prevent accidentally overwriting concurrent changes.
          in: header
          name: If-Match
          required: false
          type: string
          x-ms-client-name: IfMatch
        - description: Set to '*' to allow a new function to be created, but to prevent updating an existing function. Other values will result in a 412 Pre-condition Failed response.
          in: header
          name: If-None-Match
          required: false
          type: string
          x-ms-client-name: IfNoneMatch
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ResourceGroupNameParameter"
        - $ref: "#/parameters/StreamingJobNameParameter"
        - $ref: "#/parameters/FunctionNameParameter"
      responses:
        "200":
          description: The function was successfully created or replaced.
          headers:
            ETag:
              description: The current entity tag for the function. This is an opaque string. You can use it to detect whether the resource has changed between requests. You can also use it in the If-Match or If-None-Match headers for write operations for optimistic concurrency.
              type: string
          schema:
            $ref: "#/definitions/Function"
        "201":
          description: The function was successfully created or replaced.
          headers:
            ETag:
              description: The current entity tag for the function. This is an opaque string. You can use it to detect whether the resource has changed between requests. You can also use it in the If-Match or If-None-Match headers for write operations for optimistic concurrency.
              type: string
          schema:
            $ref: "#/definitions/Function"
      tags:
        - Functions
      x-ms-examples:
        Create a JavaScript function:
          parameters:
            api-version: 2016-03-01
            function:
              properties:
                properties:
                  binding:
                    properties:
                      script: function (x, y) { return x + y; }
                    type: Microsoft.StreamAnalytics/JavascriptUdf
                  inputs:
                    - dataType: Any
                  output:
                    dataType: Any
                type: Scalar
            functionName: function8197
            jobName: sj8653
            resourceGroupName: sjrg1637
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg1637/providers/Microsoft.StreamAnalytics/streamingjobs/sj8653/functions/function8197
                name: function8197
                properties:
                  properties:
                    binding:
                      properties:
                        script: function (x, y) { return x + y; }
                      type: Microsoft.StreamAnalytics/JavascriptUdf
                    inputs:
                      - dataType: Any
                    output:
                      dataType: Any
                  type: Scalar
                type: Microsoft.StreamAnalytics/streamingjobs/functions
              headers:
                ETag: 07495b35-da28-4c28-a3ed-e0d75d0b6eff
            "201":
              body:
                id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg1637/providers/Microsoft.StreamAnalytics/streamingjobs/sj8653/functions/function8197
                name: function8197
                properties:
                  properties:
                    binding:
                      properties:
                        script: function (x, y) { return x + y; }
                      type: Microsoft.StreamAnalytics/JavascriptUdf
                    inputs:
                      - dataType: Any
                    output:
                      dataType: Any
                  type: Scalar
                type: Microsoft.StreamAnalytics/streamingjobs/functions
              headers:
                ETag: 07495b35-da28-4c28-a3ed-e0d75d0b6eff
        Create an Azure ML function:
          parameters:
            api-version: 2016-03-01
            function:
              properties:
                properties:
                  binding:
                    properties:
                      apiKey: someApiKey==
                      batchSize: 1000
                      endpoint: someAzureMLEndpointURL
                      inputs:
                        columnNames:
                          - dataType: string
                            mapTo: 0
                            name: tweet
                        name: input1
                      outputs:
                        - dataType: string
                          name: Sentiment
                    type: Microsoft.MachineLearning/WebService
                  inputs:
                    - dataType: nvarchar(max)
                  output:
                    dataType: nvarchar(max)
                type: Scalar
            functionName: function588
            jobName: sj9093
            resourceGroupName: sjrg7
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg7/providers/Microsoft.StreamAnalytics/streamingjobs/sj9093/functions/function588
                name: function588
                properties:
                  properties:
                    binding:
                      properties:
                        batchSize: 1000
                        endpoint: someAzureMLEndpointURL
                        inputs:
                          columnNames:
                            - dataType: string
                              mapTo: 0
                              name: tweet
                          name: input1
                        outputs:
                          - dataType: string
                            name: Sentiment
                      type: Microsoft.MachineLearning/WebService
                    inputs:
                      - dataType: nvarchar(max)
                    output:
                      dataType: nvarchar(max)
                  type: Scalar
                type: Microsoft.StreamAnalytics/streamingjobs/functions
              headers:
                ETag: dac52a15-66be-4aa7-8a18-20c5409983df
            "201":
              body:
                id: /subscriptions/56b5e0a9-b645-407d-99b0-c64f86013e3d/resourceGroups/sjrg7/providers/Microsoft.StreamAnalytics/streamingjobs/sj9093/functions/function588
                name: function588
                properties:
                  properties:
                    binding:
                      properties:
                        batchSize: 1000
                        endpoint: someAzureMLEndpointURL
                        inputs:
                          columnNames:
                            - dataType: string
                              mapTo: 0
                              name: tweet
                          name: input1
                        outputs:
                          - dataType: string
                            name: Sentiment
                      type: Microsoft.MachineLearning/WebService
                    inputs:
                      - dataType: nvarchar(max)
                    output:
                      dataType: nvarchar(max)
                  type: Scalar
                type: Microsoft.StreamAnalytics/streamingjobs/functions
              headers:
                ETag: dac52a15-66be-4aa7-8a18-20c5409983df
  "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.StreamAnalytics/streamingjobs/{jobName}/functions/{functionName}/RetrieveDefaultDefinition":
    post:
      description: Retrieves the default definition of a function based on the parameters specified.
      operationId: Functions_RetrieveDefaultDefinition
      parameters:
        - description: Parameters used to specify the type of function to retrieve the default definition for.
          in: body
          name: functionRetrieveDefaultDefinitionParameters
          required: false
          schema:
            $ref: "#/definitions/FunctionRetrieveDefaultDefinitionParameters"
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ResourceGroupNameParameter"
        - $ref: "#/parameters/StreamingJobNameParameter"
        - $ref: "#/parameters/FunctionNameParameter"
      responses:
        "200":
          description: Successfully retrieved the function's default definition.
          schema:
            $ref: "#/definitions/Function"
      tags:
        - Functions
      x-ms-examples:
        Retrieve the default definition for an Azure ML function:
          parameters:
            api-version: 2016-03-01
            functionName: function588
            functionRetrieveDefaultDefinitionParameters:
              bindingRetrievalProperties:
                executeEndpoint: someAzureMLExecuteEndpointUrl
                udfType: Scalar
              bindingType: Microsoft.MachineLearning/WebService
            jobName: sj9093
            resourceGroupName: sjrg7
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                name: function588
                properties:
                  properties:
                    binding:
                      properties:
                        batchSize: 1000
                        endpoint: someAzureMLExecuteEndpointUrl
                        inputs:
                          columnNames:
                            - dataType: string
                              mapTo: 0
                              name: tweet
                          name: input1
                        outputs:
                          - dataType: string
                            name: Sentiment
                      type: Microsoft.MachineLearning/WebService
                    inputs:
                      - dataType: nvarchar(max)
                    output:
                      dataType: nvarchar(max)
                  type: Scalar
  "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.StreamAnalytics/streamingjobs/{jobName}/functions/{functionName}/test":
    post:
      description: Tests if the information provided for a function is valid. This can range from testing the connection to the underlying web service behind the function or making sure the function code provided is syntactically correct.
      operationId: Functions_Test
      parameters:
        - description: If the function specified does not already exist, this parameter must contain the full function definition intended to be tested. If the function specified already exists, this parameter can be left null to test the existing function as is or if specified, the properties specified will overwrite the corresponding properties in the existing function (exactly like a PATCH operation) and the resulting function will be tested.
          in: body
          name: function
          required: false
          schema:
            $ref: "#/definitions/Function"
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - $ref: "#/parameters/ResourceGroupNameParameter"
        - $ref: "#/parameters/StreamingJobNameParameter"
        - $ref: "#/parameters/FunctionNameParameter"
      responses:
        "200":
          description: The test operation completed successfully.
          schema:
            description: Describes the status of the test operation along with error information, if applicable.
            properties:
              error:
                description: Describes the error that occurred.
                properties:
                  code:
                    description: Error code associated with the error that occurred.
                    readOnly: true
                    type: string
                  message:
                    description: Describes the error in detail.
                    readOnly: true
                    type: string
              status:
                description: The status of the test operation.
                readOnly: true
                type: string
        "202":
          description: The test request was successfully initiated.
      tags:
        - Functions
      x-ms-examples:
        Test the connection for a JavaScript function:
          parameters:
            api-version: 2016-03-01
            functionName: function8197
            jobName: sj8653
            resourceGroupName: sjrg1637
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                error:
                  code: BadRequest
                  message: "Test operation is not supported for function type: Microsoft.StreamAnalytics/JavascriptUdf"
                status: TestFailed
            "202": {}
        Test the connection for an Azure ML function:
          parameters:
            api-version: 2016-03-01
            functionName: function588
            jobName: sj9093
            resourceGroupName: sjrg7
            subscriptionId: 56b5e0a9-b645-407d-99b0-c64f86013e3d
          responses:
            "200":
              body:
                status: TestSucceeded
            "202": {}
      x-ms-long-running-operation: true
definitions:
  AzureMachineLearningWebServiceFunctionBinding:
    allOf:
      - $ref: "#/definitions/FunctionBinding"
    description: The binding to an Azure Machine Learning web service.
    properties:
      properties:
        $ref: "#/definitions/AzureMachineLearningWebServiceFunctionBindingProperties"
        description: The binding properties associated with an Azure Machine learning web service.
        x-ms-client-flatten: true
    x-ms-discriminator-value: Microsoft.MachineLearning/WebService
  AzureMachineLearningWebServiceFunctionBindingProperties:
    description: The binding properties associated with an Azure Machine learning web service.
    properties:
      apiKey:
        description: The API key used to authenticate with Request-Response endpoint.
        type: string
      batchSize:
        description: Number between 1 and 10000 describing maximum number of rows for every Azure ML RRS execute request. Default is 1000.
        format: int32
        type: integer
      endpoint:
        description: "The Request-Response execute endpoint of the Azure Machine Learning web service. Find out more here: https://docs.microsoft.com/en-us/azure/machine-learning/machine-learning-consume-web-services#request-response-service-rrs"
        type: string
      inputs:
        $ref: "#/definitions/AzureMachineLearningWebServiceInputs"
        description: The inputs for the Azure Machine Learning web service endpoint.
      outputs:
        description: A list of outputs from the Azure Machine Learning web service endpoint execution.
        items:
          $ref: "#/definitions/AzureMachineLearningWebServiceOutputColumn"
        type: array
  AzureMachineLearningWebServiceFunctionBindingRetrievalProperties:
    description: The binding retrieval properties associated with an Azure Machine learning web service.
    properties:
      executeEndpoint:
        description: "The Request-Response execute endpoint of the Azure Machine Learning web service. Find out more here: https://docs.microsoft.com/en-us/azure/machine-learning/machine-learning-consume-web-services#request-response-service-rrs"
        type: string
      udfType:
        $ref: "#/definitions/UdfType"
        description: The function type.
  AzureMachineLearningWebServiceFunctionRetrieveDefaultDefinitionParameters:
    allOf:
      - $ref: "#/definitions/FunctionRetrieveDefaultDefinitionParameters"
    description: The parameters needed to retrieve the default function definition for an Azure Machine Learning web service function.
    properties:
      bindingRetrievalProperties:
        $ref: "#/definitions/AzureMachineLearningWebServiceFunctionBindingRetrievalProperties"
        description: The binding retrieval properties associated with an Azure Machine learning web service.
        x-ms-client-flatten: true
    x-ms-discriminator-value: Microsoft.MachineLearning/WebService
  AzureMachineLearningWebServiceInputColumn:
    description: Describes an input column for the Azure Machine Learning web service endpoint.
    properties:
      dataType:
        description: The (Azure Machine Learning supported) data type of the input column. A list of valid  Azure Machine Learning data types are described at https://msdn.microsoft.com/en-us/library/azure/dn905923.aspx .
        type: string
      mapTo:
        description: The zero based index of the function parameter this input maps to.
        format: int32
        type: integer
      name:
        description: The name of the input column.
        type: string
  AzureMachineLearningWebServiceInputs:
    description: The inputs for the Azure Machine Learning web service endpoint.
    properties:
      columnNames:
        description: A list of input columns for the Azure Machine Learning web service endpoint.
        items:
          $ref: "#/definitions/AzureMachineLearningWebServiceInputColumn"
        type: array
      name:
        description: The name of the input. This is the name provided while authoring the endpoint.
        type: string
  AzureMachineLearningWebServiceOutputColumn:
    description: Describes an output column for the Azure Machine Learning web service endpoint.
    properties:
      dataType:
        description: The (Azure Machine Learning supported) data type of the output column. A list of valid  Azure Machine Learning data types are described at https://msdn.microsoft.com/en-us/library/azure/dn905923.aspx .
        type: string
      name:
        description: The name of the output column.
        type: string
  Function:
    allOf:
      - $ref: "#/definitions/SubResource"
    description: A function object, containing all information associated with the named function. All functions are contained under a streaming job.
    properties:
      properties:
        $ref: "#/definitions/FunctionProperties"
        description: The properties that are associated with a function.
  FunctionBinding:
    description: The physical binding of the function. For example, in the Azure Machine Learning web service’s case, this describes the endpoint.
    discriminator: type
    properties:
      type:
        description: Indicates the function binding type.
        type: string
  FunctionInput:
    description: Describes one input parameter of a function.
    properties:
      dataType:
        description: The (Azure Stream Analytics supported) data type of the function input parameter. A list of valid Azure Stream Analytics data types are described at https://msdn.microsoft.com/en-us/library/azure/dn835065.aspx
        type: string
      isConfigurationParameter:
        description: A flag indicating if the parameter is a configuration parameter. True if this input parameter is expected to be a constant. Default is false.
        type: boolean
  FunctionListResult:
    description: Object containing a list of functions under a streaming job.
    properties:
      nextLink:
        description: The link (url) to the next page of results.
        readOnly: true
        type: string
      value:
        description: A list of functions under a streaming job. Populated by a 'List' operation.
        items:
          $ref: "#/definitions/Function"
        readOnly: true
        type: array
  FunctionOutput:
    description: Describes the output of a function.
    properties:
      dataType:
        description: The (Azure Stream Analytics supported) data type of the function output. A list of valid Azure Stream Analytics data types are described at https://msdn.microsoft.com/en-us/library/azure/dn835065.aspx
        type: string
  FunctionProperties:
    description: The properties that are associated with a function.
    discriminator: type
    properties:
      etag:
        description: The current entity tag for the function. This is an opaque string. You can use it to detect whether the resource has changed between requests. You can also use it in the If-Match or If-None-Match headers for write operations for optimistic concurrency.
        readOnly: true
        type: string
      type:
        description: Indicates the type of function.
        type: string
  FunctionRetrieveDefaultDefinitionParameters:
    description: Parameters used to specify the type of function to retrieve the default definition for.
    discriminator: bindingType
    properties:
      bindingType:
        description: Indicates the function binding type.
        type: string
  JavaScriptFunctionBinding:
    allOf:
      - $ref: "#/definitions/FunctionBinding"
    description: The binding to a JavaScript function.
    properties:
      properties:
        $ref: "#/definitions/JavaScriptFunctionBindingProperties"
        description: The binding properties associated with a JavaScript function.
        x-ms-client-flatten: true
    x-ms-discriminator-value: Microsoft.StreamAnalytics/JavascriptUdf
  JavaScriptFunctionBindingProperties:
    description: The binding properties associated with a JavaScript function.
    properties:
      script:
        description: "The JavaScript code containing a single function definition. For example: 'function (x, y) { return x + y; }'"
        type: string
  JavaScriptFunctionBindingRetrievalProperties:
    description: The binding retrieval properties associated with a JavaScript function.
    properties:
      script:
        description: "The JavaScript code containing a single function definition. For example: 'function (x, y) { return x + y; }'."
        type: string
      udfType:
        $ref: "#/definitions/UdfType"
        description: The function type.
  JavaScriptFunctionRetrieveDefaultDefinitionParameters:
    allOf:
      - $ref: "#/definitions/FunctionRetrieveDefaultDefinitionParameters"
    description: The parameters needed to retrieve the default function definition for a JavaScript function.
    properties:
      bindingRetrievalProperties:
        $ref: "#/definitions/JavaScriptFunctionBindingRetrievalProperties"
        description: The binding retrieval properties associated with a JavaScript function.
        x-ms-client-flatten: true
    x-ms-discriminator-value: Microsoft.StreamAnalytics/JavascriptUdf
  ScalarFunctionConfiguration:
    description: Describes the configuration of the scalar function.
    properties:
      binding:
        $ref: "#/definitions/FunctionBinding"
        description: The physical binding of the function. For example, in the Azure Machine Learning web service’s case, this describes the endpoint.
      inputs:
        description: A list of inputs describing the parameters of the function.
        items:
          $ref: "#/definitions/FunctionInput"
        type: array
      output:
        $ref: "#/definitions/FunctionOutput"
        description: The output of the function.
  ScalarFunctionProperties:
    allOf:
      - $ref: "#/definitions/FunctionProperties"
    description: The properties that are associated with a scalar function.
    properties:
      properties:
        $ref: "#/definitions/ScalarFunctionConfiguration"
        description: Describes the configuration of the scalar function.
        x-ms-client-flatten: true
    x-ms-discriminator-value: Scalar
  SubResource:
    description: The base sub-resource model definition.
    properties:
      id:
        description: Resource Id
        readOnly: true
        type: string
      name:
        description: Resource name
        type: string
      type:
        description: Resource type
        readOnly: true
        type: string
    x-ms-azure-resource: true
  UdfType:
    description: The function type.
    enum:
      - Scalar
    type: string
    x-ms-enum:
      modelAsString: false
      name: UdfType
