Akamai

Pulumi Official
Package maintained by Pulumi
v3.0.0 published on Monday, Jul 25, 2022 by Pulumi

getAppSecHostnameCoverageMatchTargets

Scopes: Hostname

Returns information about the API and website match targets used to protect a hostname. The returned information is described in the Get the hostname coverage match targets section of the Application Security API.

Related API Endpoint: /appsec/v1/configs/{configId}/versions/{versionNumber}/hostname-coverage/match-targets

Output Options

The following options can be used to determine the information returned, and how that returned information is formatted:

  • json. JSON-formatted list of the coverage information.
  • output_text. Tabular report of the coverage information.

Example Usage

using Pulumi;
using Akamai = Pulumi.Akamai;

class MyStack : Stack
{
    public MyStack()
    {
        var configuration = Output.Create(Akamai.GetAppSecConfiguration.InvokeAsync(new Akamai.GetAppSecConfigurationArgs
        {
            Name = "Documentation",
        }));
        var matchTargets = configuration.Apply(configuration => Output.Create(Akamai.GetAppSecHostnameCoverageMatchTargets.InvokeAsync(new Akamai.GetAppSecHostnameCoverageMatchTargetsArgs
        {
            ConfigId = configuration.ConfigId,
            Hostname = "documentation.akamai.com",
        })));
    }

}
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		configuration, err := akamai.LookupAppSecConfiguration(ctx, &GetAppSecConfigurationArgs{
			Name: pulumi.StringRef("Documentation"),
		}, nil)
		if err != nil {
			return err
		}
		_, err = akamai.GetAppSecHostnameCoverageMatchTargets(ctx, &GetAppSecHostnameCoverageMatchTargetsArgs{
			ConfigId: configuration.ConfigId,
			Hostname: "documentation.akamai.com",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.akamai.AkamaiFunctions;
import com.pulumi.akamai.inputs.GetAppSecConfigurationArgs;
import com.pulumi.akamai.inputs.GetAppSecHostnameCoverageMatchTargetsArgs;
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 configuration = AkamaiFunctions.getAppSecConfiguration(GetAppSecConfigurationArgs.builder()
            .name("Documentation")
            .build());

        final var matchTargets = AkamaiFunctions.getAppSecHostnameCoverageMatchTargets(GetAppSecHostnameCoverageMatchTargetsArgs.builder()
            .configId(configuration.applyValue(getAppSecConfigurationResult -> getAppSecConfigurationResult.configId()))
            .hostname("documentation.akamai.com")
            .build());

    }
}
import pulumi
import pulumi_akamai as akamai

configuration = akamai.get_app_sec_configuration(name="Documentation")
match_targets = akamai.get_app_sec_hostname_coverage_match_targets(config_id=configuration.config_id,
    hostname="documentation.akamai.com")
import * as pulumi from "@pulumi/pulumi";
import * as akamai from "@pulumi/akamai";

const configuration = akamai.getAppSecConfiguration({
    name: "Documentation",
});
const matchTargets = configuration.then(configuration => akamai.getAppSecHostnameCoverageMatchTargets({
    configId: configuration.configId,
    hostname: "documentation.akamai.com",
}));
variables:
  configuration:
    Fn::Invoke:
      Function: akamai:getAppSecConfiguration
      Arguments:
        name: Documentation
  matchTargets:
    Fn::Invoke:
      Function: akamai:getAppSecHostnameCoverageMatchTargets
      Arguments:
        configId: ${configuration.configId}
        hostname: documentation.akamai.com

Using getAppSecHostnameCoverageMatchTargets

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 getAppSecHostnameCoverageMatchTargets(args: GetAppSecHostnameCoverageMatchTargetsArgs, opts?: InvokeOptions): Promise<GetAppSecHostnameCoverageMatchTargetsResult>
function getAppSecHostnameCoverageMatchTargetsOutput(args: GetAppSecHostnameCoverageMatchTargetsOutputArgs, opts?: InvokeOptions): Output<GetAppSecHostnameCoverageMatchTargetsResult>
def get_app_sec_hostname_coverage_match_targets(config_id: Optional[int] = None,
                                                hostname: Optional[str] = None,
                                                opts: Optional[InvokeOptions] = None) -> GetAppSecHostnameCoverageMatchTargetsResult
def get_app_sec_hostname_coverage_match_targets_output(config_id: Optional[pulumi.Input[int]] = None,
                                                hostname: Optional[pulumi.Input[str]] = None,
                                                opts: Optional[InvokeOptions] = None) -> Output[GetAppSecHostnameCoverageMatchTargetsResult]
func GetAppSecHostnameCoverageMatchTargets(ctx *Context, args *GetAppSecHostnameCoverageMatchTargetsArgs, opts ...InvokeOption) (*GetAppSecHostnameCoverageMatchTargetsResult, error)
func GetAppSecHostnameCoverageMatchTargetsOutput(ctx *Context, args *GetAppSecHostnameCoverageMatchTargetsOutputArgs, opts ...InvokeOption) GetAppSecHostnameCoverageMatchTargetsResultOutput

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

public static class GetAppSecHostnameCoverageMatchTargets 
{
    public static Task<GetAppSecHostnameCoverageMatchTargetsResult> InvokeAsync(GetAppSecHostnameCoverageMatchTargetsArgs args, InvokeOptions? opts = null)
    public static Output<GetAppSecHostnameCoverageMatchTargetsResult> Invoke(GetAppSecHostnameCoverageMatchTargetsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetAppSecHostnameCoverageMatchTargetsResult> getAppSecHostnameCoverageMatchTargets(GetAppSecHostnameCoverageMatchTargetsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: akamai:index/getAppSecHostnameCoverageMatchTargets:getAppSecHostnameCoverageMatchTargets
  Arguments:
    # Arguments dictionary

The following arguments are supported:

ConfigId int
Hostname string

. Name of the host you want to return information for. You can only return information for a single host and hostname at a time.

ConfigId int
Hostname string

. Name of the host you want to return information for. You can only return information for a single host and hostname at a time.

configId Integer
hostname String

. Name of the host you want to return information for. You can only return information for a single host and hostname at a time.

configId number
hostname string

. Name of the host you want to return information for. You can only return information for a single host and hostname at a time.

config_id int
hostname str

. Name of the host you want to return information for. You can only return information for a single host and hostname at a time.

configId Number
hostname String

. Name of the host you want to return information for. You can only return information for a single host and hostname at a time.

getAppSecHostnameCoverageMatchTargets Result

The following output properties are available:

ConfigId int
Hostname string
Id string

The provider-assigned unique ID for this managed resource.

Json string
OutputText string
ConfigId int
Hostname string
Id string

The provider-assigned unique ID for this managed resource.

Json string
OutputText string
configId Integer
hostname String
id String

The provider-assigned unique ID for this managed resource.

json String
outputText String
configId number
hostname string
id string

The provider-assigned unique ID for this managed resource.

json string
outputText string
config_id int
hostname str
id str

The provider-assigned unique ID for this managed resource.

json str
output_text str
configId Number
hostname String
id String

The provider-assigned unique ID for this managed resource.

json String
outputText String

Package Details

Repository
https://github.com/pulumi/pulumi-akamai
License
Apache-2.0
Notes

This Pulumi package is based on the akamai Terraform Provider.