1. Packages
  2. Packages
  3. Google Cloud (GCP) Classic
  4. API Docs
  5. apigee
  6. getInstance
Viewing docs for Google Cloud v9.29.0
published on Wednesday, Jun 24, 2026 by Pulumi
gcp logo
Viewing docs for Google Cloud v9.29.0
published on Wednesday, Jun 24, 2026 by Pulumi

    Get information about a Google Apigee Instance.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as gcp from "@pulumi/gcp";
    
    const myInstance = gcp.apigee.getInstance({
        name: "my-instance-name",
        orgId: "organizations/my-org-id",
    });
    
    import pulumi
    import pulumi_gcp as gcp
    
    my_instance = gcp.apigee.get_instance(name="my-instance-name",
        org_id="organizations/my-org-id")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/apigee"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := apigee.LookupInstance(ctx, &apigee.LookupInstanceArgs{
    			Name:  "my-instance-name",
    			OrgId: "organizations/my-org-id",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Gcp = Pulumi.Gcp;
    
    return await Deployment.RunAsync(() => 
    {
        var myInstance = Gcp.Apigee.GetInstance.Invoke(new()
        {
            Name = "my-instance-name",
            OrgId = "organizations/my-org-id",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.gcp.apigee.ApigeeFunctions;
    import com.pulumi.gcp.apigee.inputs.GetInstanceArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    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 myInstance = ApigeeFunctions.getInstance(GetInstanceArgs.builder()
                .name("my-instance-name")
                .orgId("organizations/my-org-id")
                .build());
    
        }
    }
    
    variables:
      myInstance:
        fn::invoke:
          function: gcp:apigee:getInstance
          arguments:
            name: my-instance-name
            orgId: organizations/my-org-id
    
    pulumi {
      required_providers {
        gcp = {
          source = "pulumi/gcp"
        }
      }
    }
    
    data "gcp_apigee_getinstance" "myInstance" {
      name   = "my-instance-name"
      org_id = "organizations/my-org-id"
    }
    

    Using getInstance

    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 getInstance(args: GetInstanceArgs, opts?: InvokeOptions): Promise<GetInstanceResult>
    function getInstanceOutput(args: GetInstanceOutputArgs, opts?: InvokeOptions): Output<GetInstanceResult>
    def get_instance(name: Optional[str] = None,
                     org_id: Optional[str] = None,
                     opts: Optional[InvokeOptions] = None) -> GetInstanceResult
    def get_instance_output(name: pulumi.Input[Optional[str]] = None,
                     org_id: pulumi.Input[Optional[str]] = None,
                     opts: Optional[InvokeOptions] = None) -> Output[GetInstanceResult]
    func LookupInstance(ctx *Context, args *LookupInstanceArgs, opts ...InvokeOption) (*LookupInstanceResult, error)
    func LookupInstanceOutput(ctx *Context, args *LookupInstanceOutputArgs, opts ...InvokeOption) LookupInstanceResultOutput

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

    public static class GetInstance 
    {
        public static Task<GetInstanceResult> InvokeAsync(GetInstanceArgs args, InvokeOptions? opts = null)
        public static Output<GetInstanceResult> Invoke(GetInstanceInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetInstanceResult> getInstance(GetInstanceArgs args, InvokeOptions options)
    public static Output<GetInstanceResult> getInstance(GetInstanceArgs args, InvokeOptions options)
    
    fn::invoke:
      function: gcp:apigee/getInstance:getInstance
      arguments:
        # arguments dictionary
    data "gcp_apigee_getinstance" "name" {
        # arguments
    }

    The following arguments are supported:

    Name string
    The name of the Apigee instance. [3]
    OrgId string
    The Apigee Organization associated with the instance, in the format organizations/{{org_name}}. [3]
    Name string
    The name of the Apigee instance. [3]
    OrgId string
    The Apigee Organization associated with the instance, in the format organizations/{{org_name}}. [3]
    name string
    The name of the Apigee instance. [3]
    org_id string
    The Apigee Organization associated with the instance, in the format organizations/{{org_name}}. [3]
    name String
    The name of the Apigee instance. [3]
    orgId String
    The Apigee Organization associated with the instance, in the format organizations/{{org_name}}. [3]
    name string
    The name of the Apigee instance. [3]
    orgId string
    The Apigee Organization associated with the instance, in the format organizations/{{org_name}}. [3]
    name str
    The name of the Apigee instance. [3]
    org_id str
    The Apigee Organization associated with the instance, in the format organizations/{{org_name}}. [3]
    name String
    The name of the Apigee instance. [3]
    orgId String
    The Apigee Organization associated with the instance, in the format organizations/{{org_name}}. [3]

    getInstance Result

    The following output properties are available:

    AccessLoggingConfigs List<GetInstanceAccessLoggingConfig>
    ConsumerAcceptLists List<string>
    DeletionPolicy string
    Description string
    DiskEncryptionKeyName string
    DisplayName string
    Host string
    The hostname or IP address of the exposed Apigee endpoint. [3]
    Id string
    The provider-assigned unique ID for this managed resource.
    IpRange string
    The IP range used by the instance. [3]
    Location string
    The GCP region where the instance resides. [3]
    Name string
    OrgId string
    PeeringCidrRange string
    Port string
    The port number of the exposed Apigee endpoint. [3]
    ServiceAttachment string
    The PSC service attachment for the instance. [3]
    AccessLoggingConfigs []GetInstanceAccessLoggingConfig
    ConsumerAcceptLists []string
    DeletionPolicy string
    Description string
    DiskEncryptionKeyName string
    DisplayName string
    Host string
    The hostname or IP address of the exposed Apigee endpoint. [3]
    Id string
    The provider-assigned unique ID for this managed resource.
    IpRange string
    The IP range used by the instance. [3]
    Location string
    The GCP region where the instance resides. [3]
    Name string
    OrgId string
    PeeringCidrRange string
    Port string
    The port number of the exposed Apigee endpoint. [3]
    ServiceAttachment string
    The PSC service attachment for the instance. [3]
    access_logging_configs list(object)
    consumer_accept_lists list(string)
    deletion_policy string
    description string
    disk_encryption_key_name string
    display_name string
    host string
    The hostname or IP address of the exposed Apigee endpoint. [3]
    id string
    The provider-assigned unique ID for this managed resource.
    ip_range string
    The IP range used by the instance. [3]
    location string
    The GCP region where the instance resides. [3]
    name string
    org_id string
    peering_cidr_range string
    port string
    The port number of the exposed Apigee endpoint. [3]
    service_attachment string
    The PSC service attachment for the instance. [3]
    accessLoggingConfigs List<GetInstanceAccessLoggingConfig>
    consumerAcceptLists List<String>
    deletionPolicy String
    description String
    diskEncryptionKeyName String
    displayName String
    host String
    The hostname or IP address of the exposed Apigee endpoint. [3]
    id String
    The provider-assigned unique ID for this managed resource.
    ipRange String
    The IP range used by the instance. [3]
    location String
    The GCP region where the instance resides. [3]
    name String
    orgId String
    peeringCidrRange String
    port String
    The port number of the exposed Apigee endpoint. [3]
    serviceAttachment String
    The PSC service attachment for the instance. [3]
    accessLoggingConfigs GetInstanceAccessLoggingConfig[]
    consumerAcceptLists string[]
    deletionPolicy string
    description string
    diskEncryptionKeyName string
    displayName string
    host string
    The hostname or IP address of the exposed Apigee endpoint. [3]
    id string
    The provider-assigned unique ID for this managed resource.
    ipRange string
    The IP range used by the instance. [3]
    location string
    The GCP region where the instance resides. [3]
    name string
    orgId string
    peeringCidrRange string
    port string
    The port number of the exposed Apigee endpoint. [3]
    serviceAttachment string
    The PSC service attachment for the instance. [3]
    access_logging_configs Sequence[GetInstanceAccessLoggingConfig]
    consumer_accept_lists Sequence[str]
    deletion_policy str
    description str
    disk_encryption_key_name str
    display_name str
    host str
    The hostname or IP address of the exposed Apigee endpoint. [3]
    id str
    The provider-assigned unique ID for this managed resource.
    ip_range str
    The IP range used by the instance. [3]
    location str
    The GCP region where the instance resides. [3]
    name str
    org_id str
    peering_cidr_range str
    port str
    The port number of the exposed Apigee endpoint. [3]
    service_attachment str
    The PSC service attachment for the instance. [3]
    accessLoggingConfigs List<Property Map>
    consumerAcceptLists List<String>
    deletionPolicy String
    description String
    diskEncryptionKeyName String
    displayName String
    host String
    The hostname or IP address of the exposed Apigee endpoint. [3]
    id String
    The provider-assigned unique ID for this managed resource.
    ipRange String
    The IP range used by the instance. [3]
    location String
    The GCP region where the instance resides. [3]
    name String
    orgId String
    peeringCidrRange String
    port String
    The port number of the exposed Apigee endpoint. [3]
    serviceAttachment String
    The PSC service attachment for the instance. [3]

    Supporting Types

    GetInstanceAccessLoggingConfig

    Enabled bool
    Boolean flag that specifies whether the customer access log feature is enabled.
    Filter string
    Ship the access log entries that match the statusCode defined in the filter. The statusCode is the only expected/supported filter field. (Ex: statusCode) The filter will parse it to the Common Expression Language semantics for expression evaluation to build the filter condition. (Ex: "filter": statusCode >= 200 && statusCode < 300 )
    Enabled bool
    Boolean flag that specifies whether the customer access log feature is enabled.
    Filter string
    Ship the access log entries that match the statusCode defined in the filter. The statusCode is the only expected/supported filter field. (Ex: statusCode) The filter will parse it to the Common Expression Language semantics for expression evaluation to build the filter condition. (Ex: "filter": statusCode >= 200 && statusCode < 300 )
    enabled bool
    Boolean flag that specifies whether the customer access log feature is enabled.
    filter string
    Ship the access log entries that match the statusCode defined in the filter. The statusCode is the only expected/supported filter field. (Ex: statusCode) The filter will parse it to the Common Expression Language semantics for expression evaluation to build the filter condition. (Ex: "filter": statusCode >= 200 && statusCode < 300 )
    enabled Boolean
    Boolean flag that specifies whether the customer access log feature is enabled.
    filter String
    Ship the access log entries that match the statusCode defined in the filter. The statusCode is the only expected/supported filter field. (Ex: statusCode) The filter will parse it to the Common Expression Language semantics for expression evaluation to build the filter condition. (Ex: "filter": statusCode >= 200 && statusCode < 300 )
    enabled boolean
    Boolean flag that specifies whether the customer access log feature is enabled.
    filter string
    Ship the access log entries that match the statusCode defined in the filter. The statusCode is the only expected/supported filter field. (Ex: statusCode) The filter will parse it to the Common Expression Language semantics for expression evaluation to build the filter condition. (Ex: "filter": statusCode >= 200 && statusCode < 300 )
    enabled bool
    Boolean flag that specifies whether the customer access log feature is enabled.
    filter str
    Ship the access log entries that match the statusCode defined in the filter. The statusCode is the only expected/supported filter field. (Ex: statusCode) The filter will parse it to the Common Expression Language semantics for expression evaluation to build the filter condition. (Ex: "filter": statusCode >= 200 && statusCode < 300 )
    enabled Boolean
    Boolean flag that specifies whether the customer access log feature is enabled.
    filter String
    Ship the access log entries that match the statusCode defined in the filter. The statusCode is the only expected/supported filter field. (Ex: statusCode) The filter will parse it to the Common Expression Language semantics for expression evaluation to build the filter condition. (Ex: "filter": statusCode >= 200 && statusCode < 300 )

    Package Details

    Repository
    Google Cloud (GCP) Classic pulumi/pulumi-gcp
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the google-beta Terraform Provider.
    gcp logo
    Viewing docs for Google Cloud v9.29.0
    published on Wednesday, Jun 24, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial