Skip to content

Set-NBConfigContext

Since

v4.4.10.0

SYNOPSIS

Updates an existing config context in Netbox.

SYNTAX

Set-NBConfigContext [-Id] <UInt64> [[-Name] <String>] [[-Weight] <UInt16>] [[-Description] <String>] [[-Is_Active] <Boolean>] [[-Data] <Object>] [[-Regions] <UInt64[]>] [[-Site_Groups] <UInt64[]>] [[-Sites] <UInt64[]>] [[-Locations] <UInt64[]>] [[-Device_Types] <UInt64[]>] [[-Roles] <UInt64[]>] [[-Platforms] <UInt64[]>] [[-Cluster_Types] <UInt64[]>] [[-Cluster_Groups] <UInt64[]>] [[-Clusters] <UInt64[]>] [[-Tenant_Groups] <UInt64[]>] [[-Tenants] <UInt64[]>] [[-Tags] <String[]>] [-Raw] [-ProgressAction <ActionPreference>] [-WhatIf] [-Confirm] [<CommonParameters>]

DESCRIPTION

Updates an existing config context in Netbox Extras module.

EXAMPLES

EXAMPLE 1

Set-NBConfigContext -Id 1 -Is_Active $false

PARAMETERS

-Id

The ID of the config context to update.

```yaml Type: UInt64 Parameter Sets: (All) Aliases:

Required: True Position: 1 Default value: 0 Accept pipeline input: True (ByPropertyName) Accept wildcard characters: False ```

-Name

Name of the config context.

```yaml Type: String Parameter Sets: (All) Aliases:

Required: False Position: 2 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Weight

Weight for ordering (0-32767).

```yaml Type: UInt16 Parameter Sets: (All) Aliases:

Required: False Position: 3 Default value: 0 Accept pipeline input: False Accept wildcard characters: False ```

-Description

Description of the config context.

```yaml Type: String Parameter Sets: (All) Aliases:

Required: False Position: 4 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Is_Active

Whether the config context is active.

```yaml Type: Boolean Parameter Sets: (All) Aliases:

Required: False Position: 5 Default value: False Accept pipeline input: False Accept wildcard characters: False ```

-Data

Configuration data (hashtable or JSON).

```yaml Type: Object Parameter Sets: (All) Aliases:

Required: False Position: 6 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Regions

Array of region IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 7 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Site_Groups

Array of site group IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 8 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Sites

Array of site IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 9 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Locations

Array of location IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 10 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Device_Types

Array of device type IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 11 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Roles

Array of role IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 12 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Platforms

Array of platform IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 13 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Cluster_Types

Array of cluster type IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 14 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Cluster_Groups

Array of cluster group IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 15 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Clusters

Array of cluster IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 16 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Tenant_Groups

Array of tenant group IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 17 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Tenants

Array of tenant IDs.

```yaml Type: UInt64[] Parameter Sets: (All) Aliases:

Required: False Position: 18 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Tags

Array of tag slugs.

```yaml Type: String[] Parameter Sets: (All) Aliases:

Required: False Position: 19 Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Raw

Return the raw API response.

```yaml Type: SwitchParameter Parameter Sets: (All) Aliases:

Required: False Position: Named Default value: False Accept pipeline input: False Accept wildcard characters: False ```

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

```yaml Type: SwitchParameter Parameter Sets: (All) Aliases: wi

Required: False Position: Named Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-Confirm

Prompts you for confirmation before running the cmdlet.

```yaml Type: SwitchParameter Parameter Sets: (All) Aliases: cf

Required: False Position: Named Default value: None Accept pipeline input: False Accept wildcard characters: False ```

-ProgressAction

{{ Fill ProgressAction Description }}

```yaml Type: ActionPreference Parameter Sets: (All) Aliases: proga

Required: False Position: Named 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.

INPUTS

OUTPUTS

System.Management.Automation.PSObject

NOTES

AddedInVersion: v4.4.10.0

Common parameters

common request params

https://netbox.readthedocs.io/en/stable/rest-api/overview/