1. Registry
  2. Packages
  3. Mongodbatlas Provider
  4. API Docs
  5. McpConfigSecret
Viewing docs for MongoDB Atlas v4.16.0
published on Thursday, Sep 17, 2026 by Pulumi
mongodbatlas logo mongodbatlas logo
Viewing docs for MongoDB Atlas v4.16.0
published on Thursday, Sep 17, 2026 by Pulumi

    mongodbatlas.McpConfigSecret provides an Organization MCP Config Secret resource. The resource lets you create and delete ingress secrets for an mongodbatlas.McpConfig configuration.

    IMPORTANT: Managing MCP Config Secrets with Terraform exposes sensitive organizational secrets in Terraform’s state. We suggest following Terraform’s best practices.

    NOTE: This resource does not support updates. To rotate a secret, create a new secret resource and delete the old one once no longer needed. Up to two secrets can be active at once.

    Example Usage

    S

    import * as pulumi from "@pulumi/pulumi";
    import * as mongodbatlas from "@pulumi/mongodbatlas";
    
    const _this = new mongodbatlas.McpConfig("this", {
        orgId: orgId,
        mcpConfigName: "example-mcp-config",
        roles: ["ORG_READ_ONLY"],
    });
    const thisMcpConfigSecret = new mongodbatlas.McpConfigSecret("this", {
        orgId: orgId,
        mcpConfigId: _this.mcpConfigId,
        secretExpiresAfterHours: 720,
    });
    export const secretId = thisMcpConfigSecret.secretId;
    export const secret = thisMcpConfigSecret.secret;
    
    import pulumi
    import pulumi_mongodbatlas as mongodbatlas
    
    this = mongodbatlas.McpConfig("this",
        org_id=org_id,
        mcp_config_name="example-mcp-config",
        roles=["ORG_READ_ONLY"])
    this_mcp_config_secret = mongodbatlas.McpConfigSecret("this",
        org_id=org_id,
        mcp_config_id=this.mcp_config_id,
        secret_expires_after_hours=720)
    pulumi.export("secretId", this_mcp_config_secret.secret_id)
    pulumi.export("secret", this_mcp_config_secret.secret)
    
    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 {
    		this, err := mongodbatlas.NewMcpConfig(ctx, "this", &mongodbatlas.McpConfigArgs{
    			OrgId:         pulumi.Any(orgId),
    			McpConfigName: pulumi.String("example-mcp-config"),
    			Roles: pulumi.StringArray{
    				pulumi.String("ORG_READ_ONLY"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		thisMcpConfigSecret, err := mongodbatlas.NewMcpConfigSecret(ctx, "this", &mongodbatlas.McpConfigSecretArgs{
    			OrgId:                   pulumi.Any(orgId),
    			McpConfigId:             this.McpConfigId,
    			SecretExpiresAfterHours: pulumi.Int(720),
    		})
    		if err != nil {
    			return err
    		}
    		ctx.Export("secretId", thisMcpConfigSecret.SecretId)
    		ctx.Export("secret", thisMcpConfigSecret.Secret)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Mongodbatlas = Pulumi.Mongodbatlas;
    
    return await Deployment.RunAsync(() => 
    {
        var @this = new Mongodbatlas.McpConfig("this", new()
        {
            OrgId = orgId,
            McpConfigName = "example-mcp-config",
            Roles = new[]
            {
                "ORG_READ_ONLY",
            },
        });
    
        var thisMcpConfigSecret = new Mongodbatlas.McpConfigSecret("this", new()
        {
            OrgId = orgId,
            McpConfigId = @this.McpConfigId,
            SecretExpiresAfterHours = 720,
        });
    
        return new Dictionary<string, object?>
        {
            ["secretId"] = thisMcpConfigSecret.SecretId,
            ["secret"] = thisMcpConfigSecret.Secret,
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.mongodbatlas.McpConfig;
    import com.pulumi.mongodbatlas.McpConfigArgs;
    import com.pulumi.mongodbatlas.McpConfigSecret;
    import com.pulumi.mongodbatlas.McpConfigSecretArgs;
    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 this_ = new McpConfig("this", McpConfigArgs.builder()
                .orgId(orgId)
                .mcpConfigName("example-mcp-config")
                .roles("ORG_READ_ONLY")
                .build());
    
            var thisMcpConfigSecret = new McpConfigSecret("thisMcpConfigSecret", McpConfigSecretArgs.builder()
                .orgId(orgId)
                .mcpConfigId(this_.mcpConfigId())
                .secretExpiresAfterHours(720)
                .build());
    
            ctx.export("secretId", thisMcpConfigSecret.secretId());
            ctx.export("secret", thisMcpConfigSecret.secret());
        }
    }
    
    resources:
      this:
        type: mongodbatlas:McpConfig
        properties:
          orgId: ${orgId}
          mcpConfigName: example-mcp-config
          roles:
            - ORG_READ_ONLY
      thisMcpConfigSecret:
        type: mongodbatlas:McpConfigSecret
        name: this
        properties:
          orgId: ${orgId}
          mcpConfigId: ${this.mcpConfigId}
          secretExpiresAfterHours: 720 # 30 days
    outputs:
      secretId: ${thisMcpConfigSecret.secretId}
      secret: ${thisMcpConfigSecret.secret}
    
    pulumi {
      required_providers {
        mongodbatlas = {
          source = "pulumi/mongodbatlas"
        }
      }
    }
    
    resource "mongodbatlas_mcpconfig" "this" {
      org_id          = orgId
      mcp_config_name = "example-mcp-config"
      roles           = ["ORG_READ_ONLY"]
    }
    resource "mongodbatlas_mcpconfigsecret" "this" {
      org_id                     = orgId
      mcp_config_id              = mongodbatlas_mcpconfig.this.mcp_config_id
      secret_expires_after_hours = 720 # 30 days
    }
    output "secretId" {
      value = mongodbatlas_mcpconfigsecret.this.secret_id
    }
    output "secret" {
      value = mongodbatlas_mcpconfigsecret.this.secret
    }
    

    Create McpConfigSecret Resource

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

    Constructor syntax

    new McpConfigSecret(name: string, args: McpConfigSecretArgs, opts?: CustomResourceOptions);
    @overload
    def McpConfigSecret(resource_name: str,
                        args: McpConfigSecretArgs,
                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def McpConfigSecret(resource_name: str,
                        opts: Optional[ResourceOptions] = None,
                        mcp_config_id: Optional[str] = None,
                        org_id: Optional[str] = None,
                        secret_expires_after_hours: Optional[int] = None)
    func NewMcpConfigSecret(ctx *Context, name string, args McpConfigSecretArgs, opts ...ResourceOption) (*McpConfigSecret, error)
    public McpConfigSecret(string name, McpConfigSecretArgs args, CustomResourceOptions? opts = null)
    public McpConfigSecret(String name, McpConfigSecretArgs args)
    public McpConfigSecret(String name, McpConfigSecretArgs args, CustomResourceOptions options)
    
    type: mongodbatlas:McpConfigSecret
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "mongodbatlas_mcp_config_secret" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args McpConfigSecretArgs
    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 McpConfigSecretArgs
    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 McpConfigSecretArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args McpConfigSecretArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args McpConfigSecretArgs
    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 mcpConfigSecretResource = new Mongodbatlas.McpConfigSecret("mcpConfigSecretResource", new()
    {
        McpConfigId = "string",
        OrgId = "string",
        SecretExpiresAfterHours = 0,
    });
    
    example, err := mongodbatlas.NewMcpConfigSecret(ctx, "mcpConfigSecretResource", &mongodbatlas.McpConfigSecretArgs{
    	McpConfigId:             pulumi.String("string"),
    	OrgId:                   pulumi.String("string"),
    	SecretExpiresAfterHours: pulumi.Int(0),
    })
    
    resource "mongodbatlas_mcp_config_secret" "mcpConfigSecretResource" {
      lifecycle {
        create_before_destroy = true
      }
      mcp_config_id              = "string"
      org_id                     = "string"
      secret_expires_after_hours = 0
    }
    
    var mcpConfigSecretResource = new McpConfigSecret("mcpConfigSecretResource", McpConfigSecretArgs.builder()
        .mcpConfigId("string")
        .orgId("string")
        .secretExpiresAfterHours(0)
        .build());
    
    mcp_config_secret_resource = mongodbatlas.McpConfigSecret("mcpConfigSecretResource",
        mcp_config_id="string",
        org_id="string",
        secret_expires_after_hours=0)
    
    const mcpConfigSecretResource = new mongodbatlas.McpConfigSecret("mcpConfigSecretResource", {
        mcpConfigId: "string",
        orgId: "string",
        secretExpiresAfterHours: 0,
    });
    
    type: mongodbatlas:McpConfigSecret
    properties:
        mcpConfigId: string
        orgId: string
        secretExpiresAfterHours: 0
    

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

    McpConfigId string
    Unique identifier of the MCP configuration.
    OrgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    SecretExpiresAfterHours int
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    McpConfigId string
    Unique identifier of the MCP configuration.
    OrgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    SecretExpiresAfterHours int
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    mcp_config_id string
    Unique identifier of the MCP configuration.
    org_id string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secret_expires_after_hours number
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    mcpConfigId String
    Unique identifier of the MCP configuration.
    orgId String
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secretExpiresAfterHours Integer
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    mcpConfigId string
    Unique identifier of the MCP configuration.
    orgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secretExpiresAfterHours number
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    mcp_config_id str
    Unique identifier of the MCP configuration.
    org_id str
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secret_expires_after_hours int
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    mcpConfigId String
    Unique identifier of the MCP configuration.
    orgId String
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secretExpiresAfterHours Number
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.

    Outputs

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

    CreatedAt string
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    ExpiresAt string
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUsedAt string
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    MaskedSecretValue string
    The masked Service Account secret.
    Secret string
    The secret for the Service Account. It will be returned only the first time after creation.
    SecretId string
    Unique 24-hexadecimal digit string that identifies the secret.
    CreatedAt string
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    ExpiresAt string
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUsedAt string
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    MaskedSecretValue string
    The masked Service Account secret.
    Secret string
    The secret for the Service Account. It will be returned only the first time after creation.
    SecretId string
    Unique 24-hexadecimal digit string that identifies the secret.
    created_at string
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expires_at string
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    id string
    The provider-assigned unique ID for this managed resource.
    last_used_at string
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    masked_secret_value string
    The masked Service Account secret.
    secret string
    The secret for the Service Account. It will be returned only the first time after creation.
    secret_id string
    Unique 24-hexadecimal digit string that identifies the secret.
    createdAt String
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expiresAt String
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    id String
    The provider-assigned unique ID for this managed resource.
    lastUsedAt String
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    maskedSecretValue String
    The masked Service Account secret.
    secret String
    The secret for the Service Account. It will be returned only the first time after creation.
    secretId String
    Unique 24-hexadecimal digit string that identifies the secret.
    createdAt string
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expiresAt string
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    id string
    The provider-assigned unique ID for this managed resource.
    lastUsedAt string
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    maskedSecretValue string
    The masked Service Account secret.
    secret string
    The secret for the Service Account. It will be returned only the first time after creation.
    secretId string
    Unique 24-hexadecimal digit string that identifies the secret.
    created_at str
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expires_at str
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    id str
    The provider-assigned unique ID for this managed resource.
    last_used_at str
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    masked_secret_value str
    The masked Service Account secret.
    secret str
    The secret for the Service Account. It will be returned only the first time after creation.
    secret_id str
    Unique 24-hexadecimal digit string that identifies the secret.
    createdAt String
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expiresAt String
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    id String
    The provider-assigned unique ID for this managed resource.
    lastUsedAt String
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    maskedSecretValue String
    The masked Service Account secret.
    secret String
    The secret for the Service Account. It will be returned only the first time after creation.
    secretId String
    Unique 24-hexadecimal digit string that identifies the secret.

    Look up Existing McpConfigSecret Resource

    Get an existing McpConfigSecret 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?: McpConfigSecretState, opts?: CustomResourceOptions): McpConfigSecret
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            created_at: Optional[str] = None,
            expires_at: Optional[str] = None,
            last_used_at: Optional[str] = None,
            masked_secret_value: Optional[str] = None,
            mcp_config_id: Optional[str] = None,
            org_id: Optional[str] = None,
            secret: Optional[str] = None,
            secret_expires_after_hours: Optional[int] = None,
            secret_id: Optional[str] = None) -> McpConfigSecret
    func GetMcpConfigSecret(ctx *Context, name string, id IDInput, state *McpConfigSecretState, opts ...ResourceOption) (*McpConfigSecret, error)
    public static McpConfigSecret Get(string name, Input<string> id, McpConfigSecretState? state, CustomResourceOptions? opts = null)
    public static McpConfigSecret get(String name, Output<String> id, McpConfigSecretState state, CustomResourceOptions options)
    resources:  _:    type: mongodbatlas:McpConfigSecret    get:      id: ${id}
    import {
      to = mongodbatlas_mcp_config_secret.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:
    CreatedAt string
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    ExpiresAt string
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    LastUsedAt string
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    MaskedSecretValue string
    The masked Service Account secret.
    McpConfigId string
    Unique identifier of the MCP configuration.
    OrgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    Secret string
    The secret for the Service Account. It will be returned only the first time after creation.
    SecretExpiresAfterHours int
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    SecretId string
    Unique 24-hexadecimal digit string that identifies the secret.
    CreatedAt string
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    ExpiresAt string
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    LastUsedAt string
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    MaskedSecretValue string
    The masked Service Account secret.
    McpConfigId string
    Unique identifier of the MCP configuration.
    OrgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    Secret string
    The secret for the Service Account. It will be returned only the first time after creation.
    SecretExpiresAfterHours int
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    SecretId string
    Unique 24-hexadecimal digit string that identifies the secret.
    created_at string
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expires_at string
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    last_used_at string
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    masked_secret_value string
    The masked Service Account secret.
    mcp_config_id string
    Unique identifier of the MCP configuration.
    org_id string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secret string
    The secret for the Service Account. It will be returned only the first time after creation.
    secret_expires_after_hours number
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    secret_id string
    Unique 24-hexadecimal digit string that identifies the secret.
    createdAt String
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expiresAt String
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    lastUsedAt String
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    maskedSecretValue String
    The masked Service Account secret.
    mcpConfigId String
    Unique identifier of the MCP configuration.
    orgId String
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secret String
    The secret for the Service Account. It will be returned only the first time after creation.
    secretExpiresAfterHours Integer
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    secretId String
    Unique 24-hexadecimal digit string that identifies the secret.
    createdAt string
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expiresAt string
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    lastUsedAt string
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    maskedSecretValue string
    The masked Service Account secret.
    mcpConfigId string
    Unique identifier of the MCP configuration.
    orgId string
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secret string
    The secret for the Service Account. It will be returned only the first time after creation.
    secretExpiresAfterHours number
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    secretId string
    Unique 24-hexadecimal digit string that identifies the secret.
    created_at str
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expires_at str
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    last_used_at str
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    masked_secret_value str
    The masked Service Account secret.
    mcp_config_id str
    Unique identifier of the MCP configuration.
    org_id str
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secret str
    The secret for the Service Account. It will be returned only the first time after creation.
    secret_expires_after_hours int
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    secret_id str
    Unique 24-hexadecimal digit string that identifies the secret.
    createdAt String
    The date that the secret was created on. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    expiresAt String
    The date for the expiration of the secret. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    lastUsedAt String
    The last time the secret was used. This parameter expresses its value in the ISO 8601 timestamp format in UTC.
    maskedSecretValue String
    The masked Service Account secret.
    mcpConfigId String
    Unique identifier of the MCP configuration.
    orgId String
    Unique 24-hexadecimal digit string that identifies the organization that contains your projects.
    secret String
    The secret for the Service Account. It will be returned only the first time after creation.
    secretExpiresAfterHours Number
    The expiration time of the new ingress Service Account secret, provided in hours. This attribute is required when creating the secret and cannot be updated later.
    secretId String
    Unique 24-hexadecimal digit string that identifies the secret.

    Import

    Import the MCP Config Secret resource by using the Organization ID, MCP Config ID, and Secret ID in the format ORG_ID/MCP_CONFIG_ID/SECRET_ID, e.g.

    $ pulumi import mongodbatlas:index/mcpConfigSecret:McpConfigSecret test 6117ac2fe2a3d04ed27a987v/8423867e-394c-4f1e-9d81-32d323a1dd81/6a79adb34c91a97469c7fd1d
    

    For more information, see Create One Secret for One Organization MCP Configuration in the MongoDB Atlas API 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.16.0
    published on Thursday, Sep 17, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial