ibm.getSccReportRule
Explore with Pulumi AI
Retrieve information about a report rule from a read-only data source. Then, you can reference the fields of the data source in other resources within the same configuration by using interpolation syntax.
NOTE: Security Compliance Center is a regional service. Please specify the IBM Cloud Provider attribute
region
to target another region. Else, exporting the environmental variable IBMCLOUD_SCC_API_ENDPOINT will also override which region is being targeted for all ibm providers(ex.export IBMCLOUD_SCC_API_ENDPOINT=https://eu-es.compliance.cloud.ibm.com
).
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";
const sccReportRule = ibm.getSccReportRule({
instanceId: "00000000-1111-2222-3333-444444444444",
reportId: "report_id",
ruleId: "rule-8d444f8c-fd1d-48de-bcaa-f43732568761",
});
import pulumi
import pulumi_ibm as ibm
scc_report_rule = ibm.get_scc_report_rule(instance_id="00000000-1111-2222-3333-444444444444",
report_id="report_id",
rule_id="rule-8d444f8c-fd1d-48de-bcaa-f43732568761")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ibm.GetSccReportRule(ctx, &ibm.GetSccReportRuleArgs{
InstanceId: "00000000-1111-2222-3333-444444444444",
ReportId: "report_id",
RuleId: "rule-8d444f8c-fd1d-48de-bcaa-f43732568761",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Ibm = Pulumi.Ibm;
return await Deployment.RunAsync(() =>
{
var sccReportRule = Ibm.GetSccReportRule.Invoke(new()
{
InstanceId = "00000000-1111-2222-3333-444444444444",
ReportId = "report_id",
RuleId = "rule-8d444f8c-fd1d-48de-bcaa-f43732568761",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ibm.IbmFunctions;
import com.pulumi.ibm.inputs.GetSccReportRuleArgs;
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 sccReportRule = IbmFunctions.getSccReportRule(GetSccReportRuleArgs.builder()
.instanceId("00000000-1111-2222-3333-444444444444")
.reportId("report_id")
.ruleId("rule-8d444f8c-fd1d-48de-bcaa-f43732568761")
.build());
}
}
variables:
sccReportRule:
fn::invoke:
function: ibm:getSccReportRule
arguments:
instanceId: 00000000-1111-2222-3333-444444444444
reportId: report_id
ruleId: rule-8d444f8c-fd1d-48de-bcaa-f43732568761
Using getSccReportRule
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 getSccReportRule(args: GetSccReportRuleArgs, opts?: InvokeOptions): Promise<GetSccReportRuleResult>
function getSccReportRuleOutput(args: GetSccReportRuleOutputArgs, opts?: InvokeOptions): Output<GetSccReportRuleResult>
def get_scc_report_rule(instance_id: Optional[str] = None,
report_id: Optional[str] = None,
rule_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetSccReportRuleResult
def get_scc_report_rule_output(instance_id: Optional[pulumi.Input[str]] = None,
report_id: Optional[pulumi.Input[str]] = None,
rule_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetSccReportRuleResult]
func GetSccReportRule(ctx *Context, args *GetSccReportRuleArgs, opts ...InvokeOption) (*GetSccReportRuleResult, error)
func GetSccReportRuleOutput(ctx *Context, args *GetSccReportRuleOutputArgs, opts ...InvokeOption) GetSccReportRuleResultOutput
> Note: This function is named GetSccReportRule
in the Go SDK.
public static class GetSccReportRule
{
public static Task<GetSccReportRuleResult> InvokeAsync(GetSccReportRuleArgs args, InvokeOptions? opts = null)
public static Output<GetSccReportRuleResult> Invoke(GetSccReportRuleInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetSccReportRuleResult> getSccReportRule(GetSccReportRuleArgs args, InvokeOptions options)
public static Output<GetSccReportRuleResult> getSccReportRule(GetSccReportRuleArgs args, InvokeOptions options)
fn::invoke:
function: ibm:index/getSccReportRule:getSccReportRule
arguments:
# arguments dictionary
The following arguments are supported:
- Instance
Id string - The ID of the SCC instance in a particular region.
- Report
Id string - The ID of the scan that is associated with a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- Rule
Id string - The ID of a rule in a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- Instance
Id string - The ID of the SCC instance in a particular region.
- Report
Id string - The ID of the scan that is associated with a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- Rule
Id string - The ID of a rule in a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- instance
Id String - The ID of the SCC instance in a particular region.
- report
Id String - The ID of the scan that is associated with a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- rule
Id String - The ID of a rule in a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- instance
Id string - The ID of the SCC instance in a particular region.
- report
Id string - The ID of the scan that is associated with a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- rule
Id string - The ID of a rule in a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- instance_
id str - The ID of the SCC instance in a particular region.
- report_
id str - The ID of the scan that is associated with a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- rule_
id str - The ID of a rule in a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- instance
Id String - The ID of the SCC instance in a particular region.
- report
Id String - The ID of the scan that is associated with a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
- rule
Id String - The ID of a rule in a report.
- Constraints: The maximum length is
128
characters. The minimum length is1
character. The value must match regular expression/^[a-zA-Z0-9\\-]+$/
.
- Constraints: The maximum length is
getSccReportRule Result
The following output properties are available:
- Account
Id string - (String) The rule account ID.
- Created
By string - (String) The ID of the user who created the rule.
- Created
On string - (String) The date when the rule was created.
- Description string
- (String) The rule description.
- Id string
- (String) The rule ID.
- Instance
Id string - Labels List<string>
- (List) The rule labels.
- Constraints: The maximum length is
100
items. The minimum length is0
items.
- Constraints: The maximum length is
- Report
Id string - Rule
Id string - Type string
- (String) The rule type.
- Updated
By string - (String) The ID of the user who updated the rule.
- Updated
On string - (String) The date when the rule was updated.
- Version string
- (String) The rule version.
- Account
Id string - (String) The rule account ID.
- Created
By string - (String) The ID of the user who created the rule.
- Created
On string - (String) The date when the rule was created.
- Description string
- (String) The rule description.
- Id string
- (String) The rule ID.
- Instance
Id string - Labels []string
- (List) The rule labels.
- Constraints: The maximum length is
100
items. The minimum length is0
items.
- Constraints: The maximum length is
- Report
Id string - Rule
Id string - Type string
- (String) The rule type.
- Updated
By string - (String) The ID of the user who updated the rule.
- Updated
On string - (String) The date when the rule was updated.
- Version string
- (String) The rule version.
- account
Id String - (String) The rule account ID.
- created
By String - (String) The ID of the user who created the rule.
- created
On String - (String) The date when the rule was created.
- description String
- (String) The rule description.
- id String
- (String) The rule ID.
- instance
Id String - labels List<String>
- (List) The rule labels.
- Constraints: The maximum length is
100
items. The minimum length is0
items.
- Constraints: The maximum length is
- report
Id String - rule
Id String - type String
- (String) The rule type.
- updated
By String - (String) The ID of the user who updated the rule.
- updated
On String - (String) The date when the rule was updated.
- version String
- (String) The rule version.
- account
Id string - (String) The rule account ID.
- created
By string - (String) The ID of the user who created the rule.
- created
On string - (String) The date when the rule was created.
- description string
- (String) The rule description.
- id string
- (String) The rule ID.
- instance
Id string - labels string[]
- (List) The rule labels.
- Constraints: The maximum length is
100
items. The minimum length is0
items.
- Constraints: The maximum length is
- report
Id string - rule
Id string - type string
- (String) The rule type.
- updated
By string - (String) The ID of the user who updated the rule.
- updated
On string - (String) The date when the rule was updated.
- version string
- (String) The rule version.
- account_
id str - (String) The rule account ID.
- created_
by str - (String) The ID of the user who created the rule.
- created_
on str - (String) The date when the rule was created.
- description str
- (String) The rule description.
- id str
- (String) The rule ID.
- instance_
id str - labels Sequence[str]
- (List) The rule labels.
- Constraints: The maximum length is
100
items. The minimum length is0
items.
- Constraints: The maximum length is
- report_
id str - rule_
id str - type str
- (String) The rule type.
- updated_
by str - (String) The ID of the user who updated the rule.
- updated_
on str - (String) The date when the rule was updated.
- version str
- (String) The rule version.
- account
Id String - (String) The rule account ID.
- created
By String - (String) The ID of the user who created the rule.
- created
On String - (String) The date when the rule was created.
- description String
- (String) The rule description.
- id String
- (String) The rule ID.
- instance
Id String - labels List<String>
- (List) The rule labels.
- Constraints: The maximum length is
100
items. The minimum length is0
items.
- Constraints: The maximum length is
- report
Id String - rule
Id String - type String
- (String) The rule type.
- updated
By String - (String) The ID of the user who updated the rule.
- updated
On String - (String) The date when the rule was updated.
- version String
- (String) The rule version.
Package Details
- Repository
- ibm ibm-cloud/terraform-provider-ibm
- License
- Notes
- This Pulumi package is based on the
ibm
Terraform Provider.