Set-​Azure​Rm​Api​Management​Api

Modifies an API.

Syntax

Set-AzureRmApiManagementApi
   -Context <PsApiManagementContext>
   -ApiId <String>
   -Name <String>
   [-Description <String>]
   -ServiceUrl <String>
   [-Path <String>]
   -Protocols <PsApiManagementSchema[]>
   [-AuthorizationServerId <String>]
   [-AuthorizationScope <String>]
   [-SubscriptionKeyHeaderName <String>]
   [-SubscriptionKeyQueryParamName <String>]
   [-PassThru]
   [-InformationAction <ActionPreference>]
   [-InformationVariable <String>]
   [<CommonParameters>]

Description

The Set-AzureRmApiManagementApi cmdlet modifies an Azure API Management API.

Examples

Example 1 Modify an API

PS C:\>Set-AzureRmApiManagementApi -Context $ApiMgmtContext -Name "EchoApi" -ServiceUrl "https://contoso.com/apis/echo" -Protocols @('https') -Description "Responds with what was sent" -Path "echo"

Required Parameters

-ApiId

Specifies the ID of the API to modify.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Context

Specifies a PsApiManagementContext object.

Type:PsApiManagementContext
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Name

Specifies the name of the web API.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Protocols

Specifies an array of web API protocols. The acceptable values for this parameter are: http and https. These are the web protocols over which the API is made available. The default value is $Null.

Type:PsApiManagementSchema[]
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-ServiceUrl

Specifies the URL of the web service that exposes the API. This URL is used only by Azure API Management, and is not made public. The URL must be one to 2000 characters long.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Optional Parameters

-AuthorizationScope

Specifies the OAuth operations scope. The default value is $Null.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-AuthorizationServerId

Specifies the OAuth authorization server identifier. The default value is $Null. You must specify this parameter if AuthorizationScope is specified.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Description

Specifies a description for the web API.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-InformationAction

Specifies how this cmdlet responds to an information event.The acceptable values for this parameter are:- Continue

  • Ignore
  • Inquire
  • SilentlyContinue
  • Stop
  • Suspend
Type:ActionPreference
Aliases:infa
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-InformationVariable

Specifies an information variable.

Type:String
Aliases:iv
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PassThru

Returns an object representing the item with which you are working. By default, this cmdlet does not generate any output.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Path

Specifies the web API path, which is the last part of the API's public URL. This URL is used by API consumers to send requests to the web service, and must be one to 400 characters long. The default value is $Null.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-SubscriptionKeyHeaderName

Specifies the name of the subscription key header. The default value is $Null.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-SubscriptionKeyQueryParamName

Specifies the name of the subscription key query string parameter. The default value is $Null.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Outputs

Microsoft.Azure.Commands.ApiManagement.ServiceManagement.Models.PsApiManagementApi