diff --git a/azurerm/resource_arm_api_management.go b/azurerm/resource_arm_api_management.go index 9594c083e835d..9e708e16c3092 100644 --- a/azurerm/resource_arm_api_management.go +++ b/azurerm/resource_arm_api_management.go @@ -54,8 +54,8 @@ func resourceArmApiManagementService() *schema.Resource { Schema: map[string]*schema.Schema{ "name": { Type: schema.TypeString, - Required: true, - // Default: string(apimanagement.SkuTypeDeveloper), + Optional: true, + Default: string(apimanagement.SkuTypeDeveloper), ValidateFunc: validation.StringInSlice([]string{ string(apimanagement.SkuTypeDeveloper), string(apimanagement.SkuTypeBasic), @@ -87,25 +87,6 @@ func resourceArmApiManagementService() *schema.Resource { Schema: map[string]*schema.Schema{ "location": locationSchema(), - "sku": { - Type: schema.TypeList, - Computed: true, - MaxItems: 1, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "name": { - Type: schema.TypeString, - Required: true, - }, - "capacity": { - Type: schema.TypeInt, - Optional: true, - Default: 1, - }, - }, - }, - }, - "gateway_regional_url": { Type: schema.TypeString, Computed: true, @@ -512,7 +493,6 @@ func expandAzureRmApiManagementAdditionalLocations(d *schema.ResourceData, sku * for _, v := range inputLocations { config := v.(map[string]interface{}) location := config["location"].(string) - // sku := expandAzureRmApiManagementSku(config["sku"].([]interface{})) additionalLocation := apimanagement.AdditionalLocation{ Location: &location, @@ -591,12 +571,6 @@ func flattenApiManagementAdditionalLocations(props *[]apimanagement.AdditionalLo additional_location["gateway_regional_url"] = *prop.GatewayRegionalURL } - if prop.Sku != nil { - if sku := flattenApiManagementServiceSku(prop.Sku); sku != nil { - additional_location["sku"] = sku - } - } - additional_locations = append(additional_locations, additional_location) } }