tencentcloud 1.81.183 published on Wednesday, Apr 16, 2025 by tencentcloudstack
tencentcloud.getCamGroupPolicyAttachments
Explore with Pulumi AI
tencentcloud 1.81.183 published on Wednesday, Apr 16, 2025 by tencentcloudstack
Use this data source to query detailed information of CAM group policy attachments
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const foo = tencentcloud.getCamGroupPolicyAttachments({
    groupId: tencentcloud_cam_group.foo.id,
});
const bar = tencentcloud.getCamGroupPolicyAttachments({
    groupId: tencentcloud_cam_group.foo.id,
    policyId: tencentcloud_cam_policy.foo.id,
});
import pulumi
import pulumi_tencentcloud as tencentcloud
foo = tencentcloud.get_cam_group_policy_attachments(group_id=tencentcloud_cam_group["foo"]["id"])
bar = tencentcloud.get_cam_group_policy_attachments(group_id=tencentcloud_cam_group["foo"]["id"],
    policy_id=tencentcloud_cam_policy["foo"]["id"])
package main
import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := tencentcloud.GetCamGroupPolicyAttachments(ctx, &tencentcloud.GetCamGroupPolicyAttachmentsArgs{
			GroupId: tencentcloud_cam_group.Foo.Id,
		}, nil)
		if err != nil {
			return err
		}
		_, err = tencentcloud.GetCamGroupPolicyAttachments(ctx, &tencentcloud.GetCamGroupPolicyAttachmentsArgs{
			GroupId:  tencentcloud_cam_group.Foo.Id,
			PolicyId: pulumi.StringRef(tencentcloud_cam_policy.Foo.Id),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() => 
{
    var foo = Tencentcloud.GetCamGroupPolicyAttachments.Invoke(new()
    {
        GroupId = tencentcloud_cam_group.Foo.Id,
    });
    var bar = Tencentcloud.GetCamGroupPolicyAttachments.Invoke(new()
    {
        GroupId = tencentcloud_cam_group.Foo.Id,
        PolicyId = tencentcloud_cam_policy.Foo.Id,
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.TencentcloudFunctions;
import com.pulumi.tencentcloud.inputs.GetCamGroupPolicyAttachmentsArgs;
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) {
        final var foo = TencentcloudFunctions.getCamGroupPolicyAttachments(GetCamGroupPolicyAttachmentsArgs.builder()
            .groupId(tencentcloud_cam_group.foo().id())
            .build());
        final var bar = TencentcloudFunctions.getCamGroupPolicyAttachments(GetCamGroupPolicyAttachmentsArgs.builder()
            .groupId(tencentcloud_cam_group.foo().id())
            .policyId(tencentcloud_cam_policy.foo().id())
            .build());
    }
}
variables:
  foo:
    fn::invoke:
      function: tencentcloud:getCamGroupPolicyAttachments
      arguments:
        groupId: ${tencentcloud_cam_group.foo.id}
  bar:
    fn::invoke:
      function: tencentcloud:getCamGroupPolicyAttachments
      arguments:
        groupId: ${tencentcloud_cam_group.foo.id}
        policyId: ${tencentcloud_cam_policy.foo.id}
Using getCamGroupPolicyAttachments
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 getCamGroupPolicyAttachments(args: GetCamGroupPolicyAttachmentsArgs, opts?: InvokeOptions): Promise<GetCamGroupPolicyAttachmentsResult>
function getCamGroupPolicyAttachmentsOutput(args: GetCamGroupPolicyAttachmentsOutputArgs, opts?: InvokeOptions): Output<GetCamGroupPolicyAttachmentsResult>def get_cam_group_policy_attachments(create_mode: Optional[float] = None,
                                     group_id: Optional[str] = None,
                                     id: Optional[str] = None,
                                     policy_id: Optional[str] = None,
                                     policy_type: Optional[str] = None,
                                     result_output_file: Optional[str] = None,
                                     opts: Optional[InvokeOptions] = None) -> GetCamGroupPolicyAttachmentsResult
def get_cam_group_policy_attachments_output(create_mode: Optional[pulumi.Input[float]] = None,
                                     group_id: Optional[pulumi.Input[str]] = None,
                                     id: Optional[pulumi.Input[str]] = None,
                                     policy_id: Optional[pulumi.Input[str]] = None,
                                     policy_type: Optional[pulumi.Input[str]] = None,
                                     result_output_file: Optional[pulumi.Input[str]] = None,
                                     opts: Optional[InvokeOptions] = None) -> Output[GetCamGroupPolicyAttachmentsResult]func GetCamGroupPolicyAttachments(ctx *Context, args *GetCamGroupPolicyAttachmentsArgs, opts ...InvokeOption) (*GetCamGroupPolicyAttachmentsResult, error)
func GetCamGroupPolicyAttachmentsOutput(ctx *Context, args *GetCamGroupPolicyAttachmentsOutputArgs, opts ...InvokeOption) GetCamGroupPolicyAttachmentsResultOutput> Note: This function is named GetCamGroupPolicyAttachments in the Go SDK.
public static class GetCamGroupPolicyAttachments 
{
    public static Task<GetCamGroupPolicyAttachmentsResult> InvokeAsync(GetCamGroupPolicyAttachmentsArgs args, InvokeOptions? opts = null)
    public static Output<GetCamGroupPolicyAttachmentsResult> Invoke(GetCamGroupPolicyAttachmentsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetCamGroupPolicyAttachmentsResult> getCamGroupPolicyAttachments(GetCamGroupPolicyAttachmentsArgs args, InvokeOptions options)
public static Output<GetCamGroupPolicyAttachmentsResult> getCamGroupPolicyAttachments(GetCamGroupPolicyAttachmentsArgs args, InvokeOptions options)
fn::invoke:
  function: tencentcloud:index/getCamGroupPolicyAttachments:getCamGroupPolicyAttachments
  arguments:
    # arguments dictionaryThe following arguments are supported:
- GroupId string
- ID of the attached CAM group to be queried.
- CreateMode double
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- Id string
- PolicyId string
- ID of CAM policy to be queried.
- PolicyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- ResultOutput stringFile 
- Used to save results.
- GroupId string
- ID of the attached CAM group to be queried.
- CreateMode float64
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- Id string
- PolicyId string
- ID of CAM policy to be queried.
- PolicyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- ResultOutput stringFile 
- Used to save results.
- groupId String
- ID of the attached CAM group to be queried.
- createMode Double
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- id String
- policyId String
- ID of CAM policy to be queried.
- policyType String
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- resultOutput StringFile 
- Used to save results.
- groupId string
- ID of the attached CAM group to be queried.
- createMode number
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- id string
- policyId string
- ID of CAM policy to be queried.
- policyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- resultOutput stringFile 
- Used to save results.
- group_id str
- ID of the attached CAM group to be queried.
- create_mode float
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- id str
- policy_id str
- ID of CAM policy to be queried.
- policy_type str
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- result_output_ strfile 
- Used to save results.
- groupId String
- ID of the attached CAM group to be queried.
- createMode Number
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- id String
- policyId String
- ID of CAM policy to be queried.
- policyType String
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- resultOutput StringFile 
- Used to save results.
getCamGroupPolicyAttachments Result
The following output properties are available:
- GroupId string
- ID of CAM group.
- GroupPolicy List<GetAttachment Lists Cam Group Policy Attachments Group Policy Attachment List> 
- A list of CAM group policy attachments. Each element contains the following attributes:
- Id string
- CreateMode double
- Mode of Creation of the CAM group policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- PolicyId string
- Name of CAM group.
- PolicyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- ResultOutput stringFile 
- GroupId string
- ID of CAM group.
- GroupPolicy []GetAttachment Lists Cam Group Policy Attachments Group Policy Attachment List 
- A list of CAM group policy attachments. Each element contains the following attributes:
- Id string
- CreateMode float64
- Mode of Creation of the CAM group policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- PolicyId string
- Name of CAM group.
- PolicyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- ResultOutput stringFile 
- groupId String
- ID of CAM group.
- groupPolicy List<GetAttachment Lists Cam Group Policy Attachments Group Policy Attachment List> 
- A list of CAM group policy attachments. Each element contains the following attributes:
- id String
- createMode Double
- Mode of Creation of the CAM group policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- policyId String
- Name of CAM group.
- policyType String
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- resultOutput StringFile 
- groupId string
- ID of CAM group.
- groupPolicy GetAttachment Lists Cam Group Policy Attachments Group Policy Attachment List[] 
- A list of CAM group policy attachments. Each element contains the following attributes:
- id string
- createMode number
- Mode of Creation of the CAM group policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- policyId string
- Name of CAM group.
- policyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- resultOutput stringFile 
- group_id str
- ID of CAM group.
- group_policy_ Sequence[Getattachment_ lists Cam Group Policy Attachments Group Policy Attachment List] 
- A list of CAM group policy attachments. Each element contains the following attributes:
- id str
- create_mode float
- Mode of Creation of the CAM group policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- policy_id str
- Name of CAM group.
- policy_type str
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- result_output_ strfile 
- groupId String
- ID of CAM group.
- groupPolicy List<Property Map>Attachment Lists 
- A list of CAM group policy attachments. Each element contains the following attributes:
- id String
- createMode Number
- Mode of Creation of the CAM group policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- policyId String
- Name of CAM group.
- policyType String
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- resultOutput StringFile 
Supporting Types
GetCamGroupPolicyAttachmentsGroupPolicyAttachmentList        
- CreateMode double
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- CreateTime string
- Create time of the CAM group policy attachment.
- GroupId string
- ID of the attached CAM group to be queried.
- PolicyId string
- ID of CAM policy to be queried.
- PolicyName string
- Name of the policy.
- PolicyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- CreateMode float64
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- CreateTime string
- Create time of the CAM group policy attachment.
- GroupId string
- ID of the attached CAM group to be queried.
- PolicyId string
- ID of CAM policy to be queried.
- PolicyName string
- Name of the policy.
- PolicyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- createMode Double
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- createTime String
- Create time of the CAM group policy attachment.
- groupId String
- ID of the attached CAM group to be queried.
- policyId String
- ID of CAM policy to be queried.
- policyName String
- Name of the policy.
- policyType String
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- createMode number
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- createTime string
- Create time of the CAM group policy attachment.
- groupId string
- ID of the attached CAM group to be queried.
- policyId string
- ID of CAM policy to be queried.
- policyName string
- Name of the policy.
- policyType string
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- create_mode float
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- create_time str
- Create time of the CAM group policy attachment.
- group_id str
- ID of the attached CAM group to be queried.
- policy_id str
- ID of CAM policy to be queried.
- policy_name str
- Name of the policy.
- policy_type str
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
- createMode Number
- Mode of creation of the CAM user policy attachment. 1 means the cam policy attachment is created by production, and the others indicate syntax strategy ways.
- createTime String
- Create time of the CAM group policy attachment.
- groupId String
- ID of the attached CAM group to be queried.
- policyId String
- ID of CAM policy to be queried.
- policyName String
- Name of the policy.
- policyType String
- Type of the policy strategy. 'User' means customer strategy and 'QCS' means preset strategy.
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the tencentcloudTerraform Provider.
tencentcloud 1.81.183 published on Wednesday, Apr 16, 2025 by tencentcloudstack