1. Packages
  2. Netbox Provider
  3. API Docs
  4. getIpAddress
netbox 5.0.0 published on Friday, Sep 12, 2025 by e-breuninger

netbox.getIpAddress

Explore with Pulumi AI

netbox logo
netbox 5.0.0 published on Friday, Sep 12, 2025 by e-breuninger

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as netbox from "@pulumi/netbox";
    
    const ipAddress = netbox.getIpAddress({
        id: 1001,
    });
    
    import pulumi
    import pulumi_netbox as netbox
    
    ip_address = netbox.get_ip_address(id=1001)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/netbox/v5/netbox"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := netbox.LookupIpAddress(ctx, &netbox.LookupIpAddressArgs{
    			Id: 1001,
    		}, 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 ipAddress = Netbox.GetIpAddress.Invoke(new()
        {
            Id = 1001,
        });
    
    });
    
    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.GetIpAddressArgs;
    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 ipAddress = NetboxFunctions.getIpAddress(GetIpAddressArgs.builder()
                .id(1001)
                .build());
    
        }
    }
    
    variables:
      ipAddress:
        fn::invoke:
          function: netbox:getIpAddress
          arguments:
            id: 1001
    

    Using getIpAddress

    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 getIpAddress(args: GetIpAddressArgs, opts?: InvokeOptions): Promise<GetIpAddressResult>
    function getIpAddressOutput(args: GetIpAddressOutputArgs, opts?: InvokeOptions): Output<GetIpAddressResult>
    def get_ip_address(id: Optional[float] = None,
                       opts: Optional[InvokeOptions] = None) -> GetIpAddressResult
    def get_ip_address_output(id: Optional[pulumi.Input[float]] = None,
                       opts: Optional[InvokeOptions] = None) -> Output[GetIpAddressResult]
    func LookupIpAddress(ctx *Context, args *LookupIpAddressArgs, opts ...InvokeOption) (*LookupIpAddressResult, error)
    func LookupIpAddressOutput(ctx *Context, args *LookupIpAddressOutputArgs, opts ...InvokeOption) LookupIpAddressResultOutput

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

    public static class GetIpAddress 
    {
        public static Task<GetIpAddressResult> InvokeAsync(GetIpAddressArgs args, InvokeOptions? opts = null)
        public static Output<GetIpAddressResult> Invoke(GetIpAddressInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetIpAddressResult> getIpAddress(GetIpAddressArgs args, InvokeOptions options)
    public static Output<GetIpAddressResult> getIpAddress(GetIpAddressArgs args, InvokeOptions options)
    
    fn::invoke:
      function: netbox:index/getIpAddress:getIpAddress
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id double
    The ID of this resource.
    Id float64
    The ID of this resource.
    id Double
    The ID of this resource.
    id number
    The ID of this resource.
    id float
    The ID of this resource.
    id Number
    The ID of this resource.

    getIpAddress Result

    The following output properties are available:

    AddressFamily string
    Created string
    CustomFields Dictionary<string, string>
    Description string
    DnsName string
    Id double
    The ID of this resource.
    IpAddress string
    LastUpdated string
    Role string
    Status string
    Tags List<GetIpAddressTag>
    Tenants List<GetIpAddressTenant>
    AddressFamily string
    Created string
    CustomFields map[string]string
    Description string
    DnsName string
    Id float64
    The ID of this resource.
    IpAddress string
    LastUpdated string
    Role string
    Status string
    Tags []GetIpAddressTag
    Tenants []GetIpAddressTenant
    addressFamily String
    created String
    customFields Map<String,String>
    description String
    dnsName String
    id Double
    The ID of this resource.
    ipAddress String
    lastUpdated String
    role String
    status String
    tags List<GetIpAddressTag>
    tenants List<GetIpAddressTenant>
    addressFamily string
    created string
    customFields {[key: string]: string}
    description string
    dnsName string
    id number
    The ID of this resource.
    ipAddress string
    lastUpdated string
    role string
    status string
    tags GetIpAddressTag[]
    tenants GetIpAddressTenant[]
    addressFamily String
    created String
    customFields Map<String>
    description String
    dnsName String
    id Number
    The ID of this resource.
    ipAddress String
    lastUpdated String
    role String
    status String
    tags List<Property Map>
    tenants List<Property Map>

    Supporting Types

    GetIpAddressTag

    Display string
    Id double
    Name string
    Slug string
    Display string
    Id float64
    Name string
    Slug string
    display String
    id Double
    name String
    slug String
    display string
    id number
    name string
    slug string
    display str
    id float
    name str
    slug str
    display String
    id Number
    name String
    slug String

    GetIpAddressTenant

    Id double
    Name string
    Slug string
    Id float64
    Name string
    Slug string
    id Double
    name String
    slug String
    id number
    name string
    slug string
    id float
    name str
    slug str
    id Number
    name String
    slug String

    Package Details

    Repository
    netbox e-breuninger/terraform-provider-netbox
    License
    Notes
    This Pulumi package is based on the netbox Terraform Provider.
    netbox logo
    netbox 5.0.0 published on Friday, Sep 12, 2025 by e-breuninger