1. Registry
  2. Packages
  3. Netbox Provider
  4. API Docs
  5. getPermission
Viewing docs for netbox 6.0.0
published on Wednesday, Nov 4, 2026 by e-breuninger
netbox
Viewing docs for netbox 6.0.0
published on Wednesday, Nov 4, 2026 by e-breuninger

    An object permission granting actions on object types to users and groups (users.objectpermission).

    From the official documentation:

    An object permission grants the ability to perform one or more actions (e.g. view, add, change, delete) against a defined set of object types, and may be restricted to a subset of objects matching a configured filter. Permissions are assigned to users and/or groups; a user’s effective permissions are the union of those assigned directly and those inherited via group membership.

    See the permissions documentation for a detailed walkthrough of how permissions are evaluated.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as netbox from "@pulumi/netbox";
    
    const test = netbox.getPermission({
        name: "test-permission",
    });
    
    import pulumi
    import pulumi_netbox as netbox
    
    test = netbox.get_permission(name="test-permission")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/netbox/v6/netbox"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := netbox.LookupPermission(ctx, &netbox.LookupPermissionArgs{
    			Name: pulumi.StringRef("test-permission"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Netbox = Pulumi.Netbox;
    
    return await Deployment.RunAsync(() => 
    {
        var test = Netbox.GetPermission.Invoke(new()
        {
            Name = "test-permission",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.netbox.NetboxFunctions;
    import com.pulumi.netbox.inputs.GetPermissionArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var test = NetboxFunctions.getPermission(GetPermissionArgs.builder()
                .name("test-permission")
                .build());
    
        }
    }
    
    variables:
      test:
        fn::invoke:
          function: netbox:getPermission
          arguments:
            name: test-permission
    
    Example coming soon!
    

    Using getPermission

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getPermission(args: GetPermissionArgs, opts?: InvokeOptions): Promise<GetPermissionResult>
    function getPermissionOutput(args: GetPermissionOutputArgs, opts?: InvokeOutputOptions): Output<GetPermissionResult>
    def get_permission(id: Optional[float] = None,
                       name: Optional[str] = None,
                       opts: Optional[InvokeOptions] = None) -> GetPermissionResult
    def get_permission_output(id: pulumi.Input[Optional[float]] = None,
                       name: pulumi.Input[Optional[str]] = None,
                       opts: Optional[InvokeOutputOptions] = None) -> Output[GetPermissionResult]
    func LookupPermission(ctx *Context, args *LookupPermissionArgs, opts ...InvokeOption) (*LookupPermissionResult, error)
    func LookupPermissionOutput(ctx *Context, args *LookupPermissionOutputArgs, opts ...InvokeOption) LookupPermissionResultOutput

    > Note: This function is named LookupPermission in the Go SDK.

    public static class GetPermission 
    {
        public static Task<GetPermissionResult> InvokeAsync(GetPermissionArgs args, InvokeOptions? opts = null)
        public static Output<GetPermissionResult> Invoke(GetPermissionInvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetPermissionResult> Invoke(GetPermissionInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetPermissionResult> getPermission(GetPermissionArgs args, InvokeOptions options)
    public static Output<GetPermissionResult> getPermission(GetPermissionArgs args, InvokeOptions options)
    public static Output<GetPermissionResult> getPermission(GetPermissionArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: netbox:index/getPermission:getPermission
      arguments:
        # arguments dictionary
    data "netbox_get_permission" "name" {
        # arguments
    }

    The following arguments are supported:

    Id double
    NetBox id.
    Name string
    Id float64
    NetBox id.
    Name string
    id number
    NetBox id.
    name string
    id Double
    NetBox id.
    name String
    id number
    NetBox id.
    name string
    id float
    NetBox id.
    name str
    id Number
    NetBox id.
    name String

    getPermission Result

    The following output properties are available:

    Actions List<string>
    Permitted actions: view, add, change, delete or a custom action name.
    Constraints string
    Queryset filter as JSON text, an object or a list of objects (use jsonencode()).
    Description string
    Enabled bool
    Whether the permission is in effect.
    GroupIds List<double>
    Ids of the groups the permission is granted to.
    Groups List<double>
    Deprecated alias of group_ids.

    Deprecated: Deprecated

    Id double
    NetBox id.
    Name string
    ObjectTypes List<string>
    Object types the permission applies to, as app-labelled content types (dcim.device).
    Url string
    UserIds List<double>
    Ids of the users the permission is granted to.
    Users List<double>
    Deprecated alias of user_ids.

    Deprecated: Deprecated

    Actions []string
    Permitted actions: view, add, change, delete or a custom action name.
    Constraints string
    Queryset filter as JSON text, an object or a list of objects (use jsonencode()).
    Description string
    Enabled bool
    Whether the permission is in effect.
    GroupIds []float64
    Ids of the groups the permission is granted to.
    Groups []float64
    Deprecated alias of group_ids.

    Deprecated: Deprecated

    Id float64
    NetBox id.
    Name string
    ObjectTypes []string
    Object types the permission applies to, as app-labelled content types (dcim.device).
    Url string
    UserIds []float64
    Ids of the users the permission is granted to.
    Users []float64
    Deprecated alias of user_ids.

    Deprecated: Deprecated

    actions list(string)
    Permitted actions: view, add, change, delete or a custom action name.
    constraints string
    Queryset filter as JSON text, an object or a list of objects (use jsonencode()).
    description string
    enabled bool
    Whether the permission is in effect.
    group_ids list(number)
    Ids of the groups the permission is granted to.
    groups list(number)
    Deprecated alias of group_ids.

    Deprecated: Deprecated

    id number
    NetBox id.
    name string
    object_types list(string)
    Object types the permission applies to, as app-labelled content types (dcim.device).
    url string
    user_ids list(number)
    Ids of the users the permission is granted to.
    users list(number)
    Deprecated alias of user_ids.

    Deprecated: Deprecated

    actions List<String>
    Permitted actions: view, add, change, delete or a custom action name.
    constraints String
    Queryset filter as JSON text, an object or a list of objects (use jsonencode()).
    description String
    enabled Boolean
    Whether the permission is in effect.
    groupIds List<Double>
    Ids of the groups the permission is granted to.
    groups List<Double>
    Deprecated alias of group_ids.

    Deprecated: Deprecated

    id Double
    NetBox id.
    name String
    objectTypes List<String>
    Object types the permission applies to, as app-labelled content types (dcim.device).
    url String
    userIds List<Double>
    Ids of the users the permission is granted to.
    users List<Double>
    Deprecated alias of user_ids.

    Deprecated: Deprecated

    actions string[]
    Permitted actions: view, add, change, delete or a custom action name.
    constraints string
    Queryset filter as JSON text, an object or a list of objects (use jsonencode()).
    description string
    enabled boolean
    Whether the permission is in effect.
    groupIds number[]
    Ids of the groups the permission is granted to.
    groups number[]
    Deprecated alias of group_ids.

    Deprecated: Deprecated

    id number
    NetBox id.
    name string
    objectTypes string[]
    Object types the permission applies to, as app-labelled content types (dcim.device).
    url string
    userIds number[]
    Ids of the users the permission is granted to.
    users number[]
    Deprecated alias of user_ids.

    Deprecated: Deprecated

    actions Sequence[str]
    Permitted actions: view, add, change, delete or a custom action name.
    constraints str
    Queryset filter as JSON text, an object or a list of objects (use jsonencode()).
    description str
    enabled bool
    Whether the permission is in effect.
    group_ids Sequence[float]
    Ids of the groups the permission is granted to.
    groups Sequence[float]
    Deprecated alias of group_ids.

    Deprecated: Deprecated

    id float
    NetBox id.
    name str
    object_types Sequence[str]
    Object types the permission applies to, as app-labelled content types (dcim.device).
    url str
    user_ids Sequence[float]
    Ids of the users the permission is granted to.
    users Sequence[float]
    Deprecated alias of user_ids.

    Deprecated: Deprecated

    actions List<String>
    Permitted actions: view, add, change, delete or a custom action name.
    constraints String
    Queryset filter as JSON text, an object or a list of objects (use jsonencode()).
    description String
    enabled Boolean
    Whether the permission is in effect.
    groupIds List<Number>
    Ids of the groups the permission is granted to.
    groups List<Number>
    Deprecated alias of group_ids.

    Deprecated: Deprecated

    id Number
    NetBox id.
    name String
    objectTypes List<String>
    Object types the permission applies to, as app-labelled content types (dcim.device).
    url String
    userIds List<Number>
    Ids of the users the permission is granted to.
    users List<Number>
    Deprecated alias of user_ids.

    Deprecated: Deprecated

    Package Details

    Repository
    netbox e-breuninger/terraform-provider-netbox
    License
    Notes
    This Pulumi package is based on the netbox Terraform Provider.
    netbox
    Viewing docs for netbox 6.0.0
    published on Wednesday, Nov 4, 2026 by e-breuninger

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial