external help file: SitecoreInstallFramework-help.xml
online version:
schema: 2.0.0
---
Requests a web page, with optional retries
Invoke-WebRequestTask [-Uri] <String> [[-RetryCount] <Int32>] [[-RetryDelay] <Int32>]
[[-RequestTimeout] <Int32>] [-WhatIf] [-Confirm] [<CommonParameters>]
Makes a request to the given URI. If the request fails, it will be retried a specified
number of times (defaults to five). The delay between each request can be specified
by RetryDelay. RequestTimeout can be specified to fail a request if the response is not
served within the timeout.
If a response returns a non-200 status code, the attempt is treated as an error.
PS C:\> Invoke-WebRequestTask -Uri http://localhost
Requests the localhost site
PS C:\> Invoke-WebRequestTask -Uri http://localhost -RetryCount 3
Requests the localhost site. If the site does not return successfully within three
attempts an error is thrown.
Time in milliseconds allow request to complete.
Defaults to an infinite timeout.
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The number of times to attempt requests to URI.
Defaults to 5.
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Time in milliseconds to wait between each request.
Defaults to 2000 (two seconds).
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
The URI to request
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Prompts you for confirmation before running the cmdlet.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: cf
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Shows what would happen if the cmdlet runs.
The cmdlet is not run.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: wi
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).