1. Registry
  2. Packages
  3. Mongodbatlas Provider
  4. API Docs
  5. OrgLogIntegration
Viewing docs for MongoDB Atlas v4.17.1
published on Tuesday, Oct 13, 2026 by Pulumi
mongodbatlas logo mongodbatlas logo
Viewing docs for MongoDB Atlas v4.17.1
published on Tuesday, Oct 13, 2026 by Pulumi

    mongodbatlas.OrgLogIntegration provides a resource for managing log integration configurations at the organization level. This resource allows you to export organization events to an external service. Currently, OpenTelemetry is the only supported integration type.

    To use this resource, the requesting Service Account or API Key must have the Organization Owner role.

    Example Usage

    S

    OpenTelemetry

    import * as pulumi from "@pulumi/pulumi";
    import * as mongodbatlas from "@pulumi/mongodbatlas";
    
    const example = new mongodbatlas.OrgLogIntegration("example", {
        orgId: atlasOrgId,
        type: "OTEL_LOG_EXPORT",
        logTypes: ["EVENTS"],
        otelEndpoint: otelEndpoint,
        otelSuppliedHeaders: otelSuppliedHeaders,
    });
    
    import pulumi
    import pulumi_mongodbatlas as mongodbatlas
    
    example = mongodbatlas.OrgLogIntegration("example",
        org_id=atlas_org_id,
        type="OTEL_LOG_EXPORT",
        log_types=["EVENTS"],
        otel_endpoint=otel_endpoint,
        otel_supplied_headers=otel_supplied_headers)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-mongodbatlas/sdk/v4/go/mongodbatlas"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := mongodbatlas.NewOrgLogIntegration(ctx, "example", &mongodbatlas.OrgLogIntegrationArgs{
    			OrgId: pulumi.Any(atlasOrgId),
    			Type:  pulumi.String("OTEL_LOG_EXPORT"),
    			LogTypes: pulumi.StringArray{
    				pulumi.String("EVENTS"),
    			},
    			OtelEndpoint:        pulumi.Any(otelEndpoint),
    			OtelSuppliedHeaders: pulumi.Any(otelSuppliedHeaders),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Mongodbatlas = Pulumi.Mongodbatlas;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Mongodbatlas.OrgLogIntegration("example", new()
        {
            OrgId = atlasOrgId,
            Type = "OTEL_LOG_EXPORT",
            LogTypes = new[]
            {
                "EVENTS",
            },
            OtelEndpoint = otelEndpoint,
            OtelSuppliedHeaders = otelSuppliedHeaders,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.mongodbatlas.OrgLogIntegration;
    import com.pulumi.mongodbatlas.OrgLogIntegrationArgs;
    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) {
            var example = new OrgLogIntegration("example", OrgLogIntegrationArgs.builder()
                .orgId(atlasOrgId)
                .type("OTEL_LOG_EXPORT")
                .logTypes("EVENTS")
                .otelEndpoint(otelEndpoint)
                .otelSuppliedHeaders(otelSuppliedHeaders)
                .build());
    
        }
    }
    
    resources:
      example:
        type: mongodbatlas:OrgLogIntegration
        properties:
          orgId: ${atlasOrgId}
          type: OTEL_LOG_EXPORT
          logTypes:
            - EVENTS
          otelEndpoint: ${otelEndpoint}
          otelSuppliedHeaders: ${otelSuppliedHeaders}
    
    terraform {
      required_providers {
        mongodbatlas = {
          source = "pulumi/mongodbatlas"
        }
      }
    }
    
    resource "mongodbatlas_org_log_integration" "example" {
      lifecycle {
        create_before_destroy = true
      }
      org_id        = atlasOrgId
      type          = "OTEL_LOG_EXPORT"
      log_types     = ["EVENTS"]
      otel_endpoint = otelEndpoint
      otel_supplied_headers {
        content = otelSuppliedHeaders
      }
    }
    

    Create OrgLogIntegration Resource

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

    Constructor syntax

    new OrgLogIntegration(name: string, args: OrgLogIntegrationArgs, opts?: CustomResourceOptions);
    @overload
    def OrgLogIntegration(resource_name: str,
                          args: OrgLogIntegrationArgs,
                          opts: Optional[ResourceOptions] = None)
    
    @overload
    def OrgLogIntegration(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          log_types: Optional[Sequence[str]] = None,
                          org_id: Optional[str] = None,
                          type: Optional[str] = None,
                          otel_endpoint: Optional[str] = None,
                          otel_supplied_headers: Optional[Sequence[OrgLogIntegrationOtelSuppliedHeaderArgs]] = None)
    func NewOrgLogIntegration(ctx *Context, name string, args OrgLogIntegrationArgs, opts ...ResourceOption) (*OrgLogIntegration, error)
    public OrgLogIntegration(string name, OrgLogIntegrationArgs args, CustomResourceOptions? opts = null)
    public OrgLogIntegration(String name, OrgLogIntegrationArgs args)
    public OrgLogIntegration(String name, OrgLogIntegrationArgs args, CustomResourceOptions options)
    
    type: mongodbatlas:OrgLogIntegration
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "mongodbatlas_org_log_integration" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args OrgLogIntegrationArgs
    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 OrgLogIntegrationArgs
    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 OrgLogIntegrationArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args OrgLogIntegrationArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args OrgLogIntegrationArgs
    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 orgLogIntegrationResource = new Mongodbatlas.OrgLogIntegration("orgLogIntegrationResource", new()
    {
        LogTypes = new[]
        {
            "string",
        },
        OrgId = "string",
        Type = "string",
        OtelEndpoint = "string",
        OtelSuppliedHeaders = new[]
        {
            new Mongodbatlas.Inputs.OrgLogIntegrationOtelSuppliedHeaderArgs
            {
                Name = "string",
                Value = "string",
            },
        },
    });
    
    example, err := mongodbatlas.NewOrgLogIntegration(ctx, "orgLogIntegrationResource", &mongodbatlas.OrgLogIntegrationArgs{
    	LogTypes: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	OrgId:        pulumi.String("string"),
    	Type:         pulumi.String("string"),
    	OtelEndpoint: pulumi.String("string"),
    	OtelSuppliedHeaders: mongodbatlas.OrgLogIntegrationOtelSuppliedHeaderArray{
    		&mongodbatlas.OrgLogIntegrationOtelSuppliedHeaderArgs{
    			Name:  pulumi.String("string"),
    			Value: pulumi.String("string"),
    		},
    	},
    })
    
    resource "mongodbatlas_org_log_integration" "orgLogIntegrationResource" {
      lifecycle {
        create_before_destroy = true
      }
      log_types     = ["string"]
      org_id        = "string"
      type          = "string"
      otel_endpoint = "string"
      otel_supplied_headers {
        name  = "string"
        value = "string"
      }
    }
    
    var orgLogIntegrationResource = new OrgLogIntegration("orgLogIntegrationResource", OrgLogIntegrationArgs.builder()
        .logTypes("string")
        .orgId("string")
        .type("string")
        .otelEndpoint("string")
        .otelSuppliedHeaders(OrgLogIntegrationOtelSuppliedHeaderArgs.builder()
            .name("string")
            .value("string")
            .build())
        .build());
    
    org_log_integration_resource = mongodbatlas.OrgLogIntegration("orgLogIntegrationResource",
        log_types=["string"],
        org_id="string",
        type="string",
        otel_endpoint="string",
        otel_supplied_headers=[{
            "name": "string",
            "value": "string",
        }])
    
    const orgLogIntegrationResource = new mongodbatlas.OrgLogIntegration("orgLogIntegrationResource", {
        logTypes: ["string"],
        orgId: "string",
        type: "string",
        otelEndpoint: "string",
        otelSuppliedHeaders: [{
            name: "string",
            value: "string",
        }],
    });
    
    type: mongodbatlas:OrgLogIntegration
    properties:
        logTypes:
            - string
        orgId: string
        otelEndpoint: string
        otelSuppliedHeaders:
            - name: string
              value: string
        type: string
    

    OrgLogIntegration 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 OrgLogIntegration resource accepts the following input properties:

    LogTypes List<string>
    Array of log types exported by this integration.
    OrgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    Type string
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    OtelEndpoint string
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    OtelSuppliedHeaders List<OrgLogIntegrationOtelSuppliedHeader>
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    LogTypes []string
    Array of log types exported by this integration.
    OrgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    Type string
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    OtelEndpoint string
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    OtelSuppliedHeaders []OrgLogIntegrationOtelSuppliedHeaderArgs
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    log_types list(string)
    Array of log types exported by this integration.
    org_id string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    type string
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    otel_endpoint string
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otel_supplied_headers list(object)
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    logTypes List<String>
    Array of log types exported by this integration.
    orgId String
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    type String
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    otelEndpoint String
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otelSuppliedHeaders List<OrgLogIntegrationOtelSuppliedHeader>
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    logTypes string[]
    Array of log types exported by this integration.
    orgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    type string
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    otelEndpoint string
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otelSuppliedHeaders OrgLogIntegrationOtelSuppliedHeader[]
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    log_types Sequence[str]
    Array of log types exported by this integration.
    org_id str
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    type str
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    otel_endpoint str
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otel_supplied_headers Sequence[OrgLogIntegrationOtelSuppliedHeaderArgs]
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    logTypes List<String>
    Array of log types exported by this integration.
    orgId String
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    type String
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    otelEndpoint String
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otelSuppliedHeaders List<Property Map>
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    IntegrationId string
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    Id string
    The provider-assigned unique ID for this managed resource.
    IntegrationId string
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    id string
    The provider-assigned unique ID for this managed resource.
    integration_id string
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    id String
    The provider-assigned unique ID for this managed resource.
    integrationId String
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    id string
    The provider-assigned unique ID for this managed resource.
    integrationId string
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    id str
    The provider-assigned unique ID for this managed resource.
    integration_id str
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    id String
    The provider-assigned unique ID for this managed resource.
    integrationId String
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.

    Look up Existing OrgLogIntegration Resource

    Get an existing OrgLogIntegration 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?: OrgLogIntegrationState, opts?: CustomResourceOptions): OrgLogIntegration
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            integration_id: Optional[str] = None,
            log_types: Optional[Sequence[str]] = None,
            org_id: Optional[str] = None,
            otel_endpoint: Optional[str] = None,
            otel_supplied_headers: Optional[Sequence[OrgLogIntegrationOtelSuppliedHeaderArgs]] = None,
            type: Optional[str] = None) -> OrgLogIntegration
    func GetOrgLogIntegration(ctx *Context, name string, id IDInput, state *OrgLogIntegrationState, opts ...ResourceOption) (*OrgLogIntegration, error)
    public static OrgLogIntegration Get(string name, Input<string> id, OrgLogIntegrationState? state, CustomResourceOptions? opts = null)
    public static OrgLogIntegration get(String name, Output<String> id, OrgLogIntegrationState state, CustomResourceOptions options)
    resources:  _:    type: mongodbatlas:OrgLogIntegration    get:      id: ${id}
    import {
      to = mongodbatlas_org_log_integration.example
      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:
    IntegrationId string
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    LogTypes List<string>
    Array of log types exported by this integration.
    OrgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    OtelEndpoint string
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    OtelSuppliedHeaders List<OrgLogIntegrationOtelSuppliedHeader>
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    Type string
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    IntegrationId string
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    LogTypes []string
    Array of log types exported by this integration.
    OrgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    OtelEndpoint string
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    OtelSuppliedHeaders []OrgLogIntegrationOtelSuppliedHeaderArgs
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    Type string
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    integration_id string
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    log_types list(string)
    Array of log types exported by this integration.
    org_id string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    otel_endpoint string
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otel_supplied_headers list(object)
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    type string
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    integrationId String
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    logTypes List<String>
    Array of log types exported by this integration.
    orgId String
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    otelEndpoint String
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otelSuppliedHeaders List<OrgLogIntegrationOtelSuppliedHeader>
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    type String
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    integrationId string
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    logTypes string[]
    Array of log types exported by this integration.
    orgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    otelEndpoint string
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otelSuppliedHeaders OrgLogIntegrationOtelSuppliedHeader[]
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    type string
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    integration_id str
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    log_types Sequence[str]
    Array of log types exported by this integration.
    org_id str
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    otel_endpoint str
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otel_supplied_headers Sequence[OrgLogIntegrationOtelSuppliedHeaderArgs]
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    type str
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.
    integrationId String
    Unique 24-character hexadecimal digit string that identifies the log integration configuration.
    logTypes List<String>
    Array of log types exported by this integration.
    orgId String
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    otelEndpoint String
    OpenTelemetry collector endpoint URL. Must be HTTPS and not exceed 2048 characters.
    otelSuppliedHeaders List<Property Map>
    HTTP headers for authentication and configuration. Maximum 10 headers, total size limit 2KB.
    type String
    Human-readable label that identifies the service to which you want to integrate with Atlas. The value must match the log integration type. This value cannot be modified after the integration is created.

    Supporting Types

    OrgLogIntegrationOtelSuppliedHeader, OrgLogIntegrationOtelSuppliedHeaderArgs

    Name string
    Header name.
    Value string
    Header value. Redacted in responses.
    Name string
    Header name.
    Value string
    Header value. Redacted in responses.
    name string
    Header name.
    value string
    Header value. Redacted in responses.
    name String
    Header name.
    value String
    Header value. Redacted in responses.
    name string
    Header name.
    value string
    Header value. Redacted in responses.
    name str
    Header name.
    value str
    Header value. Redacted in responses.
    name String
    Header name.
    value String
    Header value. Redacted in responses.

    Import

    Organization Log Integration resource can be imported using the organization ID and log integration ID, separated by a slash, e.g.

    $ terraform import mongodbatlas_org_log_integration.test 650972848269185c55f40ca1/6789abcd1234ef5678901234
    

    NOTE: After importing a mongodbatlas.OrgLogIntegration resource with a configuration that sets non-empty header values, the first pulumi preview shows a diff on otelSuppliedHeaders because the Atlas API redacts these values in GET responses. The diff is expected and resolves after running pulumi up once.

    For more information see: MongoDB Atlas API - Organization Log Integration Documentation.

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

    Package Details

    Repository
    MongoDB Atlas pulumi/pulumi-mongodbatlas
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the mongodbatlas Terraform Provider.
    mongodbatlas logo mongodbatlas logo
    Viewing docs for MongoDB Atlas v4.17.1
    published on Tuesday, Oct 13, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial