1. Packages
  2. Datadog Provider
  3. API Docs
  4. OrgConnection
Datadog v4.57.0 published on Thursday, Oct 2, 2025 by Pulumi

datadog.OrgConnection

Explore with Pulumi AI

datadog logo
Datadog v4.57.0 published on Thursday, Oct 2, 2025 by Pulumi

    Provides a Datadog Org Connection resource. Org Connections make data from a source org available in the destination org for selected connection data types (for example, logs or metrics). Org Connections can only be created from a source org to a specified destination org

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as datadog from "@pulumi/datadog";
    
    // Create new org connection resource
    const foo = new datadog.OrgConnection("foo", {
        connectionTypes: [
            "metrics",
            "logs",
        ],
        sinkOrgId: "00000000-0000-0000-0000-000000000000",
    });
    
    import pulumi
    import pulumi_datadog as datadog
    
    # Create new org connection resource
    foo = datadog.OrgConnection("foo",
        connection_types=[
            "metrics",
            "logs",
        ],
        sink_org_id="00000000-0000-0000-0000-000000000000")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-datadog/sdk/v4/go/datadog"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Create new org connection resource
    		_, err := datadog.NewOrgConnection(ctx, "foo", &datadog.OrgConnectionArgs{
    			ConnectionTypes: pulumi.StringArray{
    				pulumi.String("metrics"),
    				pulumi.String("logs"),
    			},
    			SinkOrgId: pulumi.String("00000000-0000-0000-0000-000000000000"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Datadog = Pulumi.Datadog;
    
    return await Deployment.RunAsync(() => 
    {
        // Create new org connection resource
        var foo = new Datadog.OrgConnection("foo", new()
        {
            ConnectionTypes = new[]
            {
                "metrics",
                "logs",
            },
            SinkOrgId = "00000000-0000-0000-0000-000000000000",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.datadog.OrgConnection;
    import com.pulumi.datadog.OrgConnectionArgs;
    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) {
            // Create new org connection resource
            var foo = new OrgConnection("foo", OrgConnectionArgs.builder()
                .connectionTypes(            
                    "metrics",
                    "logs")
                .sinkOrgId("00000000-0000-0000-0000-000000000000")
                .build());
    
        }
    }
    
    resources:
      # Create new org connection resource
      foo:
        type: datadog:OrgConnection
        properties:
          connectionTypes:
            - metrics
            - logs
          sinkOrgId: 00000000-0000-0000-0000-000000000000
    

    Create OrgConnection Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new OrgConnection(name: string, args: OrgConnectionArgs, opts?: CustomResourceOptions);
    @overload
    def OrgConnection(resource_name: str,
                      args: OrgConnectionArgs,
                      opts: Optional[ResourceOptions] = None)
    
    @overload
    def OrgConnection(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      connection_types: Optional[Sequence[str]] = None,
                      sink_org_id: Optional[str] = None)
    func NewOrgConnection(ctx *Context, name string, args OrgConnectionArgs, opts ...ResourceOption) (*OrgConnection, error)
    public OrgConnection(string name, OrgConnectionArgs args, CustomResourceOptions? opts = null)
    public OrgConnection(String name, OrgConnectionArgs args)
    public OrgConnection(String name, OrgConnectionArgs args, CustomResourceOptions options)
    
    type: datadog:OrgConnection
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args OrgConnectionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args OrgConnectionArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args OrgConnectionArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args OrgConnectionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args OrgConnectionArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var orgConnectionResource = new Datadog.OrgConnection("orgConnectionResource", new()
    {
        ConnectionTypes = new[]
        {
            "string",
        },
        SinkOrgId = "string",
    });
    
    example, err := datadog.NewOrgConnection(ctx, "orgConnectionResource", &datadog.OrgConnectionArgs{
    	ConnectionTypes: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	SinkOrgId: pulumi.String("string"),
    })
    
    var orgConnectionResource = new OrgConnection("orgConnectionResource", OrgConnectionArgs.builder()
        .connectionTypes("string")
        .sinkOrgId("string")
        .build());
    
    org_connection_resource = datadog.OrgConnection("orgConnectionResource",
        connection_types=["string"],
        sink_org_id="string")
    
    const orgConnectionResource = new datadog.OrgConnection("orgConnectionResource", {
        connectionTypes: ["string"],
        sinkOrgId: "string",
    });
    
    type: datadog:OrgConnection
    properties:
        connectionTypes:
            - string
        sinkOrgId: string
    

    OrgConnection Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The OrgConnection resource accepts the following input properties:

    ConnectionTypes List<string>
    Set of connection types to enable for this connection (., metrics, logs).
    SinkOrgId string
    UUID of the sink (destination) organization. Must be a valid UUID.
    ConnectionTypes []string
    Set of connection types to enable for this connection (., metrics, logs).
    SinkOrgId string
    UUID of the sink (destination) organization. Must be a valid UUID.
    connectionTypes List<String>
    Set of connection types to enable for this connection (., metrics, logs).
    sinkOrgId String
    UUID of the sink (destination) organization. Must be a valid UUID.
    connectionTypes string[]
    Set of connection types to enable for this connection (., metrics, logs).
    sinkOrgId string
    UUID of the sink (destination) organization. Must be a valid UUID.
    connection_types Sequence[str]
    Set of connection types to enable for this connection (., metrics, logs).
    sink_org_id str
    UUID of the sink (destination) organization. Must be a valid UUID.
    connectionTypes List<String>
    Set of connection types to enable for this connection (., metrics, logs).
    sinkOrgId String
    UUID of the sink (destination) organization. Must be a valid UUID.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the OrgConnection resource produces the following output properties:

    CreatedAt string
    Timestamp when the connection was created (RFC 3339).
    CreatedBy string
    Creator user ID (UUID).
    Id string
    The provider-assigned unique ID for this managed resource.
    SinkOrgName string
    Name of the sink (destination) organization.
    SourceOrgId string
    UUID of the source (current) organization.
    SourceOrgName string
    Name of the source organization.
    CreatedAt string
    Timestamp when the connection was created (RFC 3339).
    CreatedBy string
    Creator user ID (UUID).
    Id string
    The provider-assigned unique ID for this managed resource.
    SinkOrgName string
    Name of the sink (destination) organization.
    SourceOrgId string
    UUID of the source (current) organization.
    SourceOrgName string
    Name of the source organization.
    createdAt String
    Timestamp when the connection was created (RFC 3339).
    createdBy String
    Creator user ID (UUID).
    id String
    The provider-assigned unique ID for this managed resource.
    sinkOrgName String
    Name of the sink (destination) organization.
    sourceOrgId String
    UUID of the source (current) organization.
    sourceOrgName String
    Name of the source organization.
    createdAt string
    Timestamp when the connection was created (RFC 3339).
    createdBy string
    Creator user ID (UUID).
    id string
    The provider-assigned unique ID for this managed resource.
    sinkOrgName string
    Name of the sink (destination) organization.
    sourceOrgId string
    UUID of the source (current) organization.
    sourceOrgName string
    Name of the source organization.
    created_at str
    Timestamp when the connection was created (RFC 3339).
    created_by str
    Creator user ID (UUID).
    id str
    The provider-assigned unique ID for this managed resource.
    sink_org_name str
    Name of the sink (destination) organization.
    source_org_id str
    UUID of the source (current) organization.
    source_org_name str
    Name of the source organization.
    createdAt String
    Timestamp when the connection was created (RFC 3339).
    createdBy String
    Creator user ID (UUID).
    id String
    The provider-assigned unique ID for this managed resource.
    sinkOrgName String
    Name of the sink (destination) organization.
    sourceOrgId String
    UUID of the source (current) organization.
    sourceOrgName String
    Name of the source organization.

    Look up Existing OrgConnection Resource

    Get an existing OrgConnection resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: OrgConnectionState, opts?: CustomResourceOptions): OrgConnection
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            connection_types: Optional[Sequence[str]] = None,
            created_at: Optional[str] = None,
            created_by: Optional[str] = None,
            sink_org_id: Optional[str] = None,
            sink_org_name: Optional[str] = None,
            source_org_id: Optional[str] = None,
            source_org_name: Optional[str] = None) -> OrgConnection
    func GetOrgConnection(ctx *Context, name string, id IDInput, state *OrgConnectionState, opts ...ResourceOption) (*OrgConnection, error)
    public static OrgConnection Get(string name, Input<string> id, OrgConnectionState? state, CustomResourceOptions? opts = null)
    public static OrgConnection get(String name, Output<String> id, OrgConnectionState state, CustomResourceOptions options)
    resources:  _:    type: datadog:OrgConnection    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    ConnectionTypes List<string>
    Set of connection types to enable for this connection (., metrics, logs).
    CreatedAt string
    Timestamp when the connection was created (RFC 3339).
    CreatedBy string
    Creator user ID (UUID).
    SinkOrgId string
    UUID of the sink (destination) organization. Must be a valid UUID.
    SinkOrgName string
    Name of the sink (destination) organization.
    SourceOrgId string
    UUID of the source (current) organization.
    SourceOrgName string
    Name of the source organization.
    ConnectionTypes []string
    Set of connection types to enable for this connection (., metrics, logs).
    CreatedAt string
    Timestamp when the connection was created (RFC 3339).
    CreatedBy string
    Creator user ID (UUID).
    SinkOrgId string
    UUID of the sink (destination) organization. Must be a valid UUID.
    SinkOrgName string
    Name of the sink (destination) organization.
    SourceOrgId string
    UUID of the source (current) organization.
    SourceOrgName string
    Name of the source organization.
    connectionTypes List<String>
    Set of connection types to enable for this connection (., metrics, logs).
    createdAt String
    Timestamp when the connection was created (RFC 3339).
    createdBy String
    Creator user ID (UUID).
    sinkOrgId String
    UUID of the sink (destination) organization. Must be a valid UUID.
    sinkOrgName String
    Name of the sink (destination) organization.
    sourceOrgId String
    UUID of the source (current) organization.
    sourceOrgName String
    Name of the source organization.
    connectionTypes string[]
    Set of connection types to enable for this connection (., metrics, logs).
    createdAt string
    Timestamp when the connection was created (RFC 3339).
    createdBy string
    Creator user ID (UUID).
    sinkOrgId string
    UUID of the sink (destination) organization. Must be a valid UUID.
    sinkOrgName string
    Name of the sink (destination) organization.
    sourceOrgId string
    UUID of the source (current) organization.
    sourceOrgName string
    Name of the source organization.
    connection_types Sequence[str]
    Set of connection types to enable for this connection (., metrics, logs).
    created_at str
    Timestamp when the connection was created (RFC 3339).
    created_by str
    Creator user ID (UUID).
    sink_org_id str
    UUID of the sink (destination) organization. Must be a valid UUID.
    sink_org_name str
    Name of the sink (destination) organization.
    source_org_id str
    UUID of the source (current) organization.
    source_org_name str
    Name of the source organization.
    connectionTypes List<String>
    Set of connection types to enable for this connection (., metrics, logs).
    createdAt String
    Timestamp when the connection was created (RFC 3339).
    createdBy String
    Creator user ID (UUID).
    sinkOrgId String
    UUID of the sink (destination) organization. Must be a valid UUID.
    sinkOrgName String
    Name of the sink (destination) organization.
    sourceOrgId String
    UUID of the source (current) organization.
    sourceOrgName String
    Name of the source organization.

    Import

    The pulumi import command can be used, for example:

    $ pulumi import datadog:index/orgConnection:OrgConnection foo "<org_connection_id>"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Datadog pulumi/pulumi-datadog
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the datadog Terraform Provider.
    datadog logo
    Datadog v4.57.0 published on Thursday, Oct 2, 2025 by Pulumi
      AI Agentic Workflows: Register now