MongoDB Atlas v4.3.0 published on Thursday, Feb 5, 2026 by Pulumi
MongoDB Atlas v4.3.0 published on Thursday, Feb 5, 2026 by Pulumi
mongodbatlas.getProjectIpAccessLists returns all IP Access List entries for a project. The access list grants access from IPs, CIDRs or AWS Security Groups (if VPC Peering is enabled) to clusters within the Project.
NOTE: Groups and projects are synonymous terms. You may find
groupIdin the official documentation.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as mongodbatlas from "@pulumi/mongodbatlas";
const ip = new mongodbatlas.ProjectIpAccessList("ip", {
projectId: projectId,
ipAddress: "2.3.4.5",
comment: "ip address test",
});
const cidr = new mongodbatlas.ProjectIpAccessList("cidr", {
projectId: projectId,
cidrBlock: "1.2.3.4/32",
comment: "cidr block test",
});
const _this = mongodbatlas.getProjectIpAccessLists({
projectId: projectId,
});
import pulumi
import pulumi_mongodbatlas as mongodbatlas
ip = mongodbatlas.ProjectIpAccessList("ip",
project_id=project_id,
ip_address="2.3.4.5",
comment="ip address test")
cidr = mongodbatlas.ProjectIpAccessList("cidr",
project_id=project_id,
cidr_block="1.2.3.4/32",
comment="cidr block test")
this = mongodbatlas.get_project_ip_access_lists(project_id=project_id)
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.NewProjectIpAccessList(ctx, "ip", &mongodbatlas.ProjectIpAccessListArgs{
ProjectId: pulumi.Any(projectId),
IpAddress: pulumi.String("2.3.4.5"),
Comment: pulumi.String("ip address test"),
})
if err != nil {
return err
}
_, err = mongodbatlas.NewProjectIpAccessList(ctx, "cidr", &mongodbatlas.ProjectIpAccessListArgs{
ProjectId: pulumi.Any(projectId),
CidrBlock: pulumi.String("1.2.3.4/32"),
Comment: pulumi.String("cidr block test"),
})
if err != nil {
return err
}
_, err = mongodbatlas.LookupProjectIpAccessLists(ctx, &mongodbatlas.LookupProjectIpAccessListsArgs{
ProjectId: projectId,
}, nil)
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 ip = new Mongodbatlas.ProjectIpAccessList("ip", new()
{
ProjectId = projectId,
IpAddress = "2.3.4.5",
Comment = "ip address test",
});
var cidr = new Mongodbatlas.ProjectIpAccessList("cidr", new()
{
ProjectId = projectId,
CidrBlock = "1.2.3.4/32",
Comment = "cidr block test",
});
var @this = Mongodbatlas.GetProjectIpAccessLists.Invoke(new()
{
ProjectId = projectId,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.mongodbatlas.ProjectIpAccessList;
import com.pulumi.mongodbatlas.ProjectIpAccessListArgs;
import com.pulumi.mongodbatlas.MongodbatlasFunctions;
import com.pulumi.mongodbatlas.inputs.GetProjectIpAccessListsArgs;
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) {
var ip = new ProjectIpAccessList("ip", ProjectIpAccessListArgs.builder()
.projectId(projectId)
.ipAddress("2.3.4.5")
.comment("ip address test")
.build());
var cidr = new ProjectIpAccessList("cidr", ProjectIpAccessListArgs.builder()
.projectId(projectId)
.cidrBlock("1.2.3.4/32")
.comment("cidr block test")
.build());
final var this = MongodbatlasFunctions.getProjectIpAccessLists(GetProjectIpAccessListsArgs.builder()
.projectId(projectId)
.build());
}
}
resources:
ip:
type: mongodbatlas:ProjectIpAccessList
properties:
projectId: ${projectId}
ipAddress: 2.3.4.5
comment: ip address test
cidr:
type: mongodbatlas:ProjectIpAccessList
properties:
projectId: ${projectId}
cidrBlock: 1.2.3.4/32
comment: cidr block test
variables:
this:
fn::invoke:
function: mongodbatlas:getProjectIpAccessLists
arguments:
projectId: ${projectId}
Using getProjectIpAccessLists
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 getProjectIpAccessLists(args: GetProjectIpAccessListsArgs, opts?: InvokeOptions): Promise<GetProjectIpAccessListsResult>
function getProjectIpAccessListsOutput(args: GetProjectIpAccessListsOutputArgs, opts?: InvokeOptions): Output<GetProjectIpAccessListsResult>def get_project_ip_access_lists(project_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetProjectIpAccessListsResult
def get_project_ip_access_lists_output(project_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetProjectIpAccessListsResult]func LookupProjectIpAccessLists(ctx *Context, args *LookupProjectIpAccessListsArgs, opts ...InvokeOption) (*LookupProjectIpAccessListsResult, error)
func LookupProjectIpAccessListsOutput(ctx *Context, args *LookupProjectIpAccessListsOutputArgs, opts ...InvokeOption) LookupProjectIpAccessListsResultOutput> Note: This function is named LookupProjectIpAccessLists in the Go SDK.
public static class GetProjectIpAccessLists
{
public static Task<GetProjectIpAccessListsResult> InvokeAsync(GetProjectIpAccessListsArgs args, InvokeOptions? opts = null)
public static Output<GetProjectIpAccessListsResult> Invoke(GetProjectIpAccessListsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetProjectIpAccessListsResult> getProjectIpAccessLists(GetProjectIpAccessListsArgs args, InvokeOptions options)
public static Output<GetProjectIpAccessListsResult> getProjectIpAccessLists(GetProjectIpAccessListsArgs args, InvokeOptions options)
fn::invoke:
function: mongodbatlas:index/getProjectIpAccessLists:getProjectIpAccessLists
arguments:
# arguments dictionaryThe following arguments are supported:
- Project
Id string - Unique 24-hexadecimal digit string that identifies your project.
- Project
Id string - Unique 24-hexadecimal digit string that identifies your project.
- project
Id String - Unique 24-hexadecimal digit string that identifies your project.
- project
Id string - Unique 24-hexadecimal digit string that identifies your project.
- project_
id str - Unique 24-hexadecimal digit string that identifies your project.
- project
Id String - Unique 24-hexadecimal digit string that identifies your project.
getProjectIpAccessLists Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Project
Id string - Unique 24-hexadecimal digit string that identifies your project.
- Results
List<Get
Project Ip Access Lists Result> - List of returned documents that MongoDB Cloud provides when completing this request.
- Id string
- The provider-assigned unique ID for this managed resource.
- Project
Id string - Unique 24-hexadecimal digit string that identifies your project.
- Results
[]Get
Project Ip Access Lists Result - List of returned documents that MongoDB Cloud provides when completing this request.
- id String
- The provider-assigned unique ID for this managed resource.
- project
Id String - Unique 24-hexadecimal digit string that identifies your project.
- results
List<Get
Project Ip Access Lists Result> - List of returned documents that MongoDB Cloud provides when completing this request.
- id string
- The provider-assigned unique ID for this managed resource.
- project
Id string - Unique 24-hexadecimal digit string that identifies your project.
- results
Get
Project Ip Access Lists Result[] - List of returned documents that MongoDB Cloud provides when completing this request.
- id str
- The provider-assigned unique ID for this managed resource.
- project_
id str - Unique 24-hexadecimal digit string that identifies your project.
- results
Sequence[Get
Project Ip Access Lists Result] - List of returned documents that MongoDB Cloud provides when completing this request.
- id String
- The provider-assigned unique ID for this managed resource.
- project
Id String - Unique 24-hexadecimal digit string that identifies your project.
- results List<Property Map>
- List of returned documents that MongoDB Cloud provides when completing this request.
Supporting Types
GetProjectIpAccessListsResult
- Aws
Security stringGroup - Unique identifier of the AWS security group to add to the access list. Mutually exclusive with
cidr_blockandip_address. - Cidr
Block string - Range of IP addresses in CIDR notation to be added to the access list. Mutually exclusive with
aws_security_groupandip_address. - Comment string
- Remark that explains the purpose or scope of this IP access list entry.
- Ip
Address string - Single IP address to be added to the access list. Mutually exclusive with
cidr_blockandaws_security_group.
- Aws
Security stringGroup - Unique identifier of the AWS security group to add to the access list. Mutually exclusive with
cidr_blockandip_address. - Cidr
Block string - Range of IP addresses in CIDR notation to be added to the access list. Mutually exclusive with
aws_security_groupandip_address. - Comment string
- Remark that explains the purpose or scope of this IP access list entry.
- Ip
Address string - Single IP address to be added to the access list. Mutually exclusive with
cidr_blockandaws_security_group.
- aws
Security StringGroup - Unique identifier of the AWS security group to add to the access list. Mutually exclusive with
cidr_blockandip_address. - cidr
Block String - Range of IP addresses in CIDR notation to be added to the access list. Mutually exclusive with
aws_security_groupandip_address. - comment String
- Remark that explains the purpose or scope of this IP access list entry.
- ip
Address String - Single IP address to be added to the access list. Mutually exclusive with
cidr_blockandaws_security_group.
- aws
Security stringGroup - Unique identifier of the AWS security group to add to the access list. Mutually exclusive with
cidr_blockandip_address. - cidr
Block string - Range of IP addresses in CIDR notation to be added to the access list. Mutually exclusive with
aws_security_groupandip_address. - comment string
- Remark that explains the purpose or scope of this IP access list entry.
- ip
Address string - Single IP address to be added to the access list. Mutually exclusive with
cidr_blockandaws_security_group.
- aws_
security_ strgroup - Unique identifier of the AWS security group to add to the access list. Mutually exclusive with
cidr_blockandip_address. - cidr_
block str - Range of IP addresses in CIDR notation to be added to the access list. Mutually exclusive with
aws_security_groupandip_address. - comment str
- Remark that explains the purpose or scope of this IP access list entry.
- ip_
address str - Single IP address to be added to the access list. Mutually exclusive with
cidr_blockandaws_security_group.
- aws
Security StringGroup - Unique identifier of the AWS security group to add to the access list. Mutually exclusive with
cidr_blockandip_address. - cidr
Block String - Range of IP addresses in CIDR notation to be added to the access list. Mutually exclusive with
aws_security_groupandip_address. - comment String
- Remark that explains the purpose or scope of this IP access list entry.
- ip
Address String - Single IP address to be added to the access list. Mutually exclusive with
cidr_blockandaws_security_group.
Package Details
- Repository
- MongoDB Atlas pulumi/pulumi-mongodbatlas
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
mongodbatlasTerraform Provider.
MongoDB Atlas v4.3.0 published on Thursday, Feb 5, 2026 by Pulumi
