getAppSecMatchTargets

Use the akamai.getAppSecMatchTargets data source to retrieve information about the match targets associated with a given configuration, or about a specific match target.

Example Usage

using Pulumi;
using Akamai = Pulumi.Akamai;

class MyStack : Stack
{
    public MyStack()
    {
        var configuration = Output.Create(Akamai.GetAppSecConfiguration.InvokeAsync(new Akamai.GetAppSecConfigurationArgs
        {
            Name = @var.Security_configuration,
        }));
        var matchTargetsAppSecMatchTargets = configuration.Apply(configuration => Output.Create(Akamai.GetAppSecMatchTargets.InvokeAsync(new Akamai.GetAppSecMatchTargetsArgs
        {
            ConfigId = configuration.ConfigId,
        })));
        this.MatchTargets = matchTargetsAppSecMatchTargets.Apply(matchTargetsAppSecMatchTargets => matchTargetsAppSecMatchTargets.OutputText);
        var matchTarget = configuration.Apply(configuration => Output.Create(Akamai.GetAppSecMatchTargets.InvokeAsync(new Akamai.GetAppSecMatchTargetsArgs
        {
            ConfigId = configuration.ConfigId,
            MatchTargetId = @var.Match_target_id,
        })));
        this.MatchTargetOutput = matchTarget.Apply(matchTarget => matchTarget.OutputText);
    }

    [Output("matchTargets")]
    public Output<string> MatchTargets { get; set; }
    [Output("matchTargetOutput")]
    public Output<string> MatchTargetOutput { get; set; }
}
package main

import (
	"github.com/pulumi/pulumi-akamai/sdk/v2/go/akamai"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		opt0 := _var.Security_configuration
		configuration, err := akamai.LookupAppSecConfiguration(ctx, &GetAppSecConfigurationArgs{
			Name: &opt0,
		}, nil)
		if err != nil {
			return err
		}
		matchTargetsAppSecMatchTargets, err := akamai.GetAppSecMatchTargets(ctx, &GetAppSecMatchTargetsArgs{
			ConfigId: configuration.ConfigId,
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("matchTargets", matchTargetsAppSecMatchTargets.OutputText)
		opt1 := _var.Match_target_id
		matchTarget, err := akamai.GetAppSecMatchTargets(ctx, &GetAppSecMatchTargetsArgs{
			ConfigId:      configuration.ConfigId,
			MatchTargetId: &opt1,
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("matchTargetOutput", matchTarget.OutputText)
		return nil
	})
}
import pulumi
import pulumi_akamai as akamai

configuration = akamai.get_app_sec_configuration(name=var["security_configuration"])
match_targets_app_sec_match_targets = akamai.get_app_sec_match_targets(config_id=configuration.config_id)
pulumi.export("matchTargets", match_targets_app_sec_match_targets.output_text)
match_target = akamai.get_app_sec_match_targets(config_id=configuration.config_id,
    match_target_id=var["match_target_id"])
pulumi.export("matchTargetOutput", match_target.output_text)
import * as pulumi from "@pulumi/pulumi";
import * as akamai from "@pulumi/akamai";

const configuration = akamai.getAppSecConfiguration({
    name: _var.security_configuration,
});
const matchTargetsAppSecMatchTargets = configuration.then(configuration => akamai.getAppSecMatchTargets({
    configId: configuration.configId,
}));
export const matchTargets = matchTargetsAppSecMatchTargets.then(matchTargetsAppSecMatchTargets => matchTargetsAppSecMatchTargets.outputText);
const matchTarget = configuration.then(configuration => akamai.getAppSecMatchTargets({
    configId: configuration.configId,
    matchTargetId: _var.match_target_id,
}));
export const matchTargetOutput = matchTarget.then(matchTarget => matchTarget.outputText);

Using getAppSecMatchTargets

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 getAppSecMatchTargets(args: GetAppSecMatchTargetsArgs, opts?: InvokeOptions): Promise<GetAppSecMatchTargetsResult>
function getAppSecMatchTargetsOutput(args: GetAppSecMatchTargetsOutputArgs, opts?: InvokeOptions): Output<GetAppSecMatchTargetsResult>
def get_app_sec_match_targets(config_id: Optional[int] = None,
                              match_target_id: Optional[int] = None,
                              opts: Optional[InvokeOptions] = None) -> GetAppSecMatchTargetsResult
def get_app_sec_match_targets_output(config_id: Optional[pulumi.Input[int]] = None,
                              match_target_id: Optional[pulumi.Input[int]] = None,
                              opts: Optional[InvokeOptions] = None) -> Output[GetAppSecMatchTargetsResult]
func GetAppSecMatchTargets(ctx *Context, args *GetAppSecMatchTargetsArgs, opts ...InvokeOption) (*GetAppSecMatchTargetsResult, error)
func GetAppSecMatchTargetsOutput(ctx *Context, args *GetAppSecMatchTargetsOutputArgs, opts ...InvokeOption) GetAppSecMatchTargetsResultOutput

> Note: This function is named GetAppSecMatchTargets in the Go SDK.

public static class GetAppSecMatchTargets 
{
    public static Task<GetAppSecMatchTargetsResult> InvokeAsync(GetAppSecMatchTargetsArgs args, InvokeOptions? opts = null)
    public static Output<GetAppSecMatchTargetsResult> Invoke(GetAppSecMatchTargetsInvokeArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

ConfigId int
The ID of the security configuration to use.
MatchTargetId int
The ID of the match target to use. If not supplied, information about all match targets is returned.
ConfigId int
The ID of the security configuration to use.
MatchTargetId int
The ID of the match target to use. If not supplied, information about all match targets is returned.
configId number
The ID of the security configuration to use.
matchTargetId number
The ID of the match target to use. If not supplied, information about all match targets is returned.
config_id int
The ID of the security configuration to use.
match_target_id int
The ID of the match target to use. If not supplied, information about all match targets is returned.

getAppSecMatchTargets Result

The following output properties are available:

ConfigId int
Id string
The provider-assigned unique ID for this managed resource.
Json string
A JSON-formatted list of the match target information.
OutputText string
A tabular display showing the ID and Policy ID of all match targets associated with the specified security configuration, or of the specific match target if match_target_id was supplied.
MatchTargetId int
ConfigId int
Id string
The provider-assigned unique ID for this managed resource.
Json string
A JSON-formatted list of the match target information.
OutputText string
A tabular display showing the ID and Policy ID of all match targets associated with the specified security configuration, or of the specific match target if match_target_id was supplied.
MatchTargetId int
configId number
id string
The provider-assigned unique ID for this managed resource.
json string
A JSON-formatted list of the match target information.
outputText string
A tabular display showing the ID and Policy ID of all match targets associated with the specified security configuration, or of the specific match target if match_target_id was supplied.
matchTargetId number
config_id int
id str
The provider-assigned unique ID for this managed resource.
json str
A JSON-formatted list of the match target information.
output_text str
A tabular display showing the ID and Policy ID of all match targets associated with the specified security configuration, or of the specific match target if match_target_id was supplied.
match_target_id int

Package Details

Repository
https://github.com/pulumi/pulumi-akamai
License
Apache-2.0
Notes
This Pulumi package is based on the akamai Terraform Provider.