New-PodeLogApiOverride
SYNOPSIS
Creates a new set of override options for the API Log Method.
SYNTAX
New-PodeLogApiOverride [[-Id] <String>] [[-Type] <String>] [[-Data] <Hashtable>] [-Ignore]
[-ProgressAction <ActionPreference>] [<CommonParameters>]
DESCRIPTION
Creates a new set of override options for the API Log Method. This allows you to specify custom data for API Log Methods, and can be retrieved via Get-PodeLogOverride per Log Event.
EXAMPLES
EXAMPLE 1
$override = New-PodeLogApiOverride -Data @{ Key = 'Value' }
EXAMPLE 2
$override = New-PodeLogApiOverride -Id 'ApiMethod' -Data @{ Key = 'Value' }
EXAMPLE 3
$override = New-PodeLogApiOverride -Ignore
EXAMPLE 4
$override = New-PodeLogApiOverride -Type 'NewRelic' -Data @{ Key = 'Value' }
PARAMETERS
-Data
A hashtable of custom data to associate with the API Log Method override.
Type: Hashtable
Parameter Sets: (All)
Aliases:
Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Id
An optional ID to assign to the Log Method to override. (Default: 'API')
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Ignore
Whether to ignore the API Log Method when writing log items.
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
-ProgressAction
{{ Fill ProgressAction Description }}
Type: ActionPreference
Parameter Sets: (All)
Aliases: proga
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Type
An optional Type to assign to the Log Method to override. (Default: API)
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.