logiapp teams api connection terraform user sign in

53 Views Asked by At

I have logic app that needs to read messages from teams channel which I want to provision via terraform (logic-app) on portal inside of design of workflow I can login to teams with my user (azure portal user) and connection works. I am not sure how to setup api-connection teams and how to pass my private user for login inside Iac? since only my private user can login to teams and have access to channel I do not have some generic user for teams like service principle...

any idea this is my team api-connection?

  resource "azapi_resource" "teams-connection" {
  type      = "Microsoft.Web/connections@2016-06-01"
  name      = "teams"
  parent_id = azurerm_resource_group.resource_group_name.id
  location  = var.location

  body = jsonencode({
    properties = {
      api = {
        id   = data.azurerm_managed_api.teams-api.id,
        type = "Microsoft.Web/locations/managedApis"
      }
      authentication = {
        type = "ManagedServiceIdentity"
      }
      parameterValueSet: {
        name: "managedIdentityAuth"
        values: {}
        }
      }
  })
  schema_validation_enabled = false
}
0

There are 0 best solutions below