swagger: '2.0' info: version: 2020-08-01-preview title: Microsoft Azure AccessControlClient AccessConnector AccessPolicies API schemes: - https tags: - name: AccessPolicies paths: ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.TimeSeriesInsights/environments/{environmentName}/accessPolicies/{accessPolicyName} : put: tags: - AccessPolicies operationId: microsoftAzureAccesspoliciesCreateorupdate x-ms-examples: AccessPoliciesCreate: $ref: ./examples/AccessPoliciesCreate.json description: Create or update an access policy in the specified environment. parameters: - $ref: '#/parameters/SubscriptionIdParameter' - $ref: '#/parameters/ResourceGroupNameParameter' - $ref: '#/parameters/EnvironmentNameParameter' - name: accessPolicyName in: path required: true type: string pattern: ^[-\w\._\(\)]+$ minLength: 1 maxLength: 90 description: Name of the access policy. - $ref: '#/parameters/ApiVersionParameter' - name: parameters in: body required: true schema: $ref: '#/definitions/AccessPolicyCreateOrUpdateParameters' description: Parameters for creating an access policy. responses: '200': description: The existing access policy definition was successfully updated. schema: $ref: '#/definitions/AccessPolicyResource' '201': description: The access policy was successfully created. schema: $ref: '#/definitions/AccessPolicyResource' default: description: 'HTTP 400 (Bad Request): The given access policy request body is invalid; See the error code and message in the response for details.' schema: $ref: '#/definitions/CloudError' summary: Microsoft Azure Put Subscriptions Subscriptionid Resourcegroups Resourcegroupname Providers Microsoft Timeseriesinsights Environments Environmentname Accesspolicies Accesspolicyname get: tags: - AccessPolicies operationId: microsoftAzureAccesspoliciesGet x-ms-examples: AccessPoliciesGet: $ref: ./examples/AccessPoliciesGet.json description: Gets the access policy with the specified name in the specified environment. parameters: - $ref: '#/parameters/SubscriptionIdParameter' - $ref: '#/parameters/ResourceGroupNameParameter' - $ref: '#/parameters/EnvironmentNameParameter' - $ref: '#/parameters/AccessPolicyNameParameter' - $ref: '#/parameters/ApiVersionParameter' responses: '200': description: The access policy definition was successfully retrieved and is in the response. schema: $ref: '#/definitions/AccessPolicyResource' default: description: 'HTTP 404 (Not Found): The subscription, resource group, environment, or access policy could not be found.' schema: $ref: '#/definitions/CloudError' summary: Microsoft Azure Get Subscriptions Subscriptionid Resourcegroups Resourcegroupname Providers Microsoft Timeseriesinsights Environments Environmentname Accesspolicies Accesspolicyname patch: tags: - AccessPolicies operationId: microsoftAzureAccesspoliciesUpdate x-ms-examples: AccessPoliciesUpdate: $ref: ./examples/AccessPoliciesPatchRoles.json description: Updates the access policy with the specified name in the specified subscription, resource group, and environment. parameters: - $ref: '#/parameters/SubscriptionIdParameter' - $ref: '#/parameters/ResourceGroupNameParameter' - $ref: '#/parameters/EnvironmentNameParameter' - $ref: '#/parameters/AccessPolicyNameParameter' - $ref: '#/parameters/ApiVersionParameter' - name: accessPolicyUpdateParameters in: body required: true schema: $ref: '#/definitions/AccessPolicyUpdateParameters' description: Request object that contains the updated information for the access policy. responses: '200': description: The access policy definition was successfully updated and is in the response. schema: $ref: '#/definitions/AccessPolicyResource' default: description: 'HTTP 404 (Not Found): The subscription, resource group, environment, or access policy could not be found.' schema: $ref: '#/definitions/CloudError' summary: Microsoft Azure Patch Subscriptions Subscriptionid Resourcegroups Resourcegroupname Providers Microsoft Timeseriesinsights Environments Environmentname Accesspolicies Accesspolicyname delete: tags: - AccessPolicies operationId: microsoftAzureAccesspoliciesDelete x-ms-examples: AccessPoliciesDelete: $ref: ./examples/AccessPoliciesDelete.json description: Deletes the access policy with the specified name in the specified subscription, resource group, and environment parameters: - $ref: '#/parameters/SubscriptionIdParameter' - $ref: '#/parameters/ResourceGroupNameParameter' - $ref: '#/parameters/EnvironmentNameParameter' - $ref: '#/parameters/AccessPolicyNameParameter' - $ref: '#/parameters/ApiVersionParameter' responses: '200': description: The access policy was successfully deleted. '204': description: The access policy was successfully deleted. default: description: 'HTTP 404 (Not Found): The subscription, resource group, environment, or access policy could not be found.' schema: $ref: '#/definitions/CloudError' summary: Microsoft Azure Delete Subscriptions Subscriptionid Resourcegroups Resourcegroupname Providers Microsoft Timeseriesinsights Environments Environmentname Accesspolicies Accesspolicyname ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.TimeSeriesInsights/environments/{environmentName}/accessPolicies : get: tags: - AccessPolicies operationId: microsoftAzureAccesspoliciesListbyenvironment x-ms-examples: AccessPoliciesByEnvironment: $ref: ./examples/AccessPoliciesListByEnvironment.json description: Lists all the available access policies associated with the environment. parameters: - $ref: '#/parameters/SubscriptionIdParameter' - $ref: '#/parameters/ResourceGroupNameParameter' - $ref: '#/parameters/EnvironmentNameParameter' - $ref: '#/parameters/ApiVersionParameter' responses: '200': description: access policies returned successfully. schema: $ref: '#/definitions/AccessPolicyListResponse' default: description: 'HTTP 404 (Not Found): The subscription, resource group, or environment could not be found.' schema: $ref: '#/definitions/CloudError' summary: Microsoft Azure Get Subscriptions Subscriptionid Resourcegroups Resourcegroupname Providers Microsoft Timeseriesinsights Environments Environmentname Accesspolicies definitions: AccessPolicyResource: properties: properties: x-ms-client-flatten: true $ref: '#/definitions/AccessPolicyResourceProperties' allOf: - $ref: '#/definitions/Resource' description: An access policy is used to grant users and applications access to the environment. Roles are assigned to service principals in Azure Active Directory. These roles define the actions the principal can perform through the Time Series Insights data plane APIs. Resource: properties: id: readOnly: true type: string description: Resource Id name: readOnly: true type: string description: Resource name type: readOnly: true type: string description: Resource type description: Time Series Insights resource x-ms-azure-resource: true AccessPolicyResourceProperties: properties: principalObjectId: type: string description: The objectId of the principal in Azure Active Directory. x-ms-mutability: - create - read description: type: string description: An description of the access policy. roles: type: array items: type: string description: A role defining the data plane operations that a principal can perform on a Time Series Insights client. enum: - Reader - Contributor x-ms-enum: name: AccessPolicyRole modelAsString: true description: The list of roles the principal is assigned on the environment. CloudError: type: object properties: error: $ref: '#/definitions/CloudErrorBody' description: Describes a particular API error with an error code and a message. description: Contains information about an API error. x-ms-external: true CloudErrorBody: type: object description: Describes a particular API error with an error code and a message. properties: code: type: string description: An error code that describes the error condition more precisely than an HTTP status code. Can be used to programmatically handle specific error cases. message: type: string description: A message that describes the error in detail and provides debugging information. target: type: string description: The target of the particular error (for example, the name of the property in error). details: type: array items: $ref: '#/definitions/CloudErrorBody' description: Describes a particular API error with an error code and a message. x-ms-identifiers: [] description: Contains nested errors that are related to this error. x-ms-external: true AccessPolicyUpdateParameters: properties: properties: x-ms-client-flatten: true $ref: '#/definitions/AccessPolicyMutableProperties' AccessPolicyMutableProperties: description: An object that represents a set of mutable access policy resource properties. type: object properties: description: type: string description: An description of the access policy. roles: type: array items: type: string description: A role defining the data plane operations that a principal can perform on a Time Series Insights client. enum: - Reader - Contributor x-ms-enum: name: AccessPolicyRole modelAsString: true description: The list of roles the principal is assigned on the environment. AccessPolicyListResponse: properties: value: type: array items: $ref: '#/definitions/AccessPolicyResource' description: Result of the List access policies operation. description: The response of the List access policies operation. AccessPolicyCreateOrUpdateParameters: properties: properties: x-ms-client-flatten: true $ref: '#/definitions/AccessPolicyResourceProperties' required: - properties parameters: AccessPolicyNameParameter: name: accessPolicyName in: path required: true type: string description: The name of the Time Series Insights access policy associated with the specified environment. x-ms-parameter-location: method ApiVersionParameter: name: api-version in: query required: true type: string description: Version of the API to be used with the client request. EnvironmentNameParameter: name: environmentName in: path required: true type: string description: The name of the Time Series Insights environment associated with the specified resource group. x-ms-parameter-location: method SubscriptionIdParameter: name: subscriptionId in: path description: Azure Subscription ID. required: true type: string ResourceGroupNameParameter: name: resourceGroupName in: path required: true type: string x-ms-parameter-location: method description: Name of an Azure Resource group. x-ms-parameterized-host: hostTemplate: '{endpoint}' useSchemePrefix: false parameters: - $ref: '#/parameters/Endpoint'