Akamai

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

getAppSecReputationProfiles

Scopes: Security configuration; reputation profile

Returns information about your reputation profiles. Reputation profiles grade the security risk of an IP address based on previous activities associated with that address. Depending on the reputation score, and depending on how your configuration has been set up, requests from a specific IP address can trigger an alert, or even be blocked.

Related API Endpoint: /appsec/v1/configs/{configId}/versions/{versionNumber}/reputation-profiles

Output Options

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

  • output_text. Tabular report of the details about the specified reputation profile or profiles.
  • json. JSON-formatted report of the details about the specified reputation profile or profiles.

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 reputationProfiles = configuration.Apply(configuration => Output.Create(Akamai.GetAppSecReputationProfiles.InvokeAsync(new Akamai.GetAppSecReputationProfilesArgs
        {
            ConfigId = configuration.ConfigId,
        })));
        this.ReputationProfilesOutput = reputationProfiles.Apply(reputationProfiles => reputationProfiles.OutputText);
        this.ReputationProfilesJson = reputationProfiles.Apply(reputationProfiles => reputationProfiles.Json);
        var reputationProfile = configuration.Apply(configuration => Output.Create(Akamai.GetAppSecReputationProfiles.InvokeAsync(new Akamai.GetAppSecReputationProfilesArgs
        {
            ConfigId = configuration.ConfigId,
            ReputationProfileId = 12345,
        })));
        this.ReputationProfileJson = reputationProfile.Apply(reputationProfile => reputationProfile.Json);
        this.ReputationProfileOutput = reputationProfile.Apply(reputationProfile => reputationProfile.OutputText);
    }

    [Output("reputationProfilesOutput")]
    public Output<string> ReputationProfilesOutput { get; set; }
    [Output("reputationProfilesJson")]
    public Output<string> ReputationProfilesJson { get; set; }
    [Output("reputationProfileJson")]
    public Output<string> ReputationProfileJson { get; set; }
    [Output("reputationProfileOutput")]
    public Output<string> ReputationProfileOutput { get; set; }
}
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
		}
		reputationProfiles, err := akamai.GetAppSecReputationProfiles(ctx, &GetAppSecReputationProfilesArgs{
			ConfigId: configuration.ConfigId,
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("reputationProfilesOutput", reputationProfiles.OutputText)
		ctx.Export("reputationProfilesJson", reputationProfiles.Json)
		reputationProfile, err := akamai.GetAppSecReputationProfiles(ctx, &GetAppSecReputationProfilesArgs{
			ConfigId:            configuration.ConfigId,
			ReputationProfileId: pulumi.IntRef(12345),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("reputationProfileJson", reputationProfile.Json)
		ctx.Export("reputationProfileOutput", reputationProfile.OutputText)
		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.GetAppSecReputationProfilesArgs;
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 reputationProfiles = AkamaiFunctions.getAppSecReputationProfiles(GetAppSecReputationProfilesArgs.builder()
            .configId(configuration.applyValue(getAppSecConfigurationResult -> getAppSecConfigurationResult.configId()))
            .build());

        ctx.export("reputationProfilesOutput", reputationProfiles.applyValue(getAppSecReputationProfilesResult -> getAppSecReputationProfilesResult.outputText()));
        ctx.export("reputationProfilesJson", reputationProfiles.applyValue(getAppSecReputationProfilesResult -> getAppSecReputationProfilesResult.json()));
        final var reputationProfile = AkamaiFunctions.getAppSecReputationProfiles(GetAppSecReputationProfilesArgs.builder()
            .configId(configuration.applyValue(getAppSecConfigurationResult -> getAppSecConfigurationResult.configId()))
            .reputationProfileId("12345")
            .build());

        ctx.export("reputationProfileJson", reputationProfile.applyValue(getAppSecReputationProfilesResult -> getAppSecReputationProfilesResult.json()));
        ctx.export("reputationProfileOutput", reputationProfile.applyValue(getAppSecReputationProfilesResult -> getAppSecReputationProfilesResult.outputText()));
    }
}
import pulumi
import pulumi_akamai as akamai

configuration = akamai.get_app_sec_configuration(name="Documentation")
reputation_profiles = akamai.get_app_sec_reputation_profiles(config_id=configuration.config_id)
pulumi.export("reputationProfilesOutput", reputation_profiles.output_text)
pulumi.export("reputationProfilesJson", reputation_profiles.json)
reputation_profile = akamai.get_app_sec_reputation_profiles(config_id=configuration.config_id,
    reputation_profile_id=12345)
pulumi.export("reputationProfileJson", reputation_profile.json)
pulumi.export("reputationProfileOutput", reputation_profile.output_text)
import * as pulumi from "@pulumi/pulumi";
import * as akamai from "@pulumi/akamai";

const configuration = akamai.getAppSecConfiguration({
    name: "Documentation",
});
const reputationProfiles = configuration.then(configuration => akamai.getAppSecReputationProfiles({
    configId: configuration.configId,
}));
export const reputationProfilesOutput = reputationProfiles.then(reputationProfiles => reputationProfiles.outputText);
export const reputationProfilesJson = reputationProfiles.then(reputationProfiles => reputationProfiles.json);
const reputationProfile = configuration.then(configuration => akamai.getAppSecReputationProfiles({
    configId: configuration.configId,
    reputationProfileId: 12345,
}));
export const reputationProfileJson = reputationProfile.then(reputationProfile => reputationProfile.json);
export const reputationProfileOutput = reputationProfile.then(reputationProfile => reputationProfile.outputText);
variables:
  configuration: # USE CASE: User wants to view all the reputation profiles associated with a security configuration.
    Fn::Invoke:
      Function: akamai:getAppSecConfiguration
      Arguments:
        name: Documentation
  reputationProfiles:
    Fn::Invoke:
      Function: akamai:getAppSecReputationProfiles
      Arguments:
        configId: ${configuration.configId}
  reputationProfile:
    Fn::Invoke:
      Function: akamai:getAppSecReputationProfiles
      Arguments:
        configId: ${configuration.configId}
        reputationProfileId: 12345
outputs:
  reputationProfilesOutput: ${reputationProfiles.outputText}
  reputationProfilesJson: ${reputationProfiles.json} # USE CASE: User wants to view a specific reputation profile associated with a given configuration
  reputationProfileJson: ${reputationProfile.json}
  reputationProfileOutput: ${reputationProfile.outputText}

Using getAppSecReputationProfiles

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 getAppSecReputationProfiles(args: GetAppSecReputationProfilesArgs, opts?: InvokeOptions): Promise<GetAppSecReputationProfilesResult>
function getAppSecReputationProfilesOutput(args: GetAppSecReputationProfilesOutputArgs, opts?: InvokeOptions): Output<GetAppSecReputationProfilesResult>
def get_app_sec_reputation_profiles(config_id: Optional[int] = None,
                                    reputation_profile_id: Optional[int] = None,
                                    opts: Optional[InvokeOptions] = None) -> GetAppSecReputationProfilesResult
def get_app_sec_reputation_profiles_output(config_id: Optional[pulumi.Input[int]] = None,
                                    reputation_profile_id: Optional[pulumi.Input[int]] = None,
                                    opts: Optional[InvokeOptions] = None) -> Output[GetAppSecReputationProfilesResult]
func GetAppSecReputationProfiles(ctx *Context, args *GetAppSecReputationProfilesArgs, opts ...InvokeOption) (*GetAppSecReputationProfilesResult, error)
func GetAppSecReputationProfilesOutput(ctx *Context, args *GetAppSecReputationProfilesOutputArgs, opts ...InvokeOption) GetAppSecReputationProfilesResultOutput

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

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

The following arguments are supported:

ConfigId int

. Unique identifier of the security configuration associated with the reputation profiles.

ReputationProfileId int

. Unique identifier of the reputation profile you want to return information for. If not included, information is returned for all your reputation profiles.

ConfigId int

. Unique identifier of the security configuration associated with the reputation profiles.

ReputationProfileId int

. Unique identifier of the reputation profile you want to return information for. If not included, information is returned for all your reputation profiles.

configId Integer

. Unique identifier of the security configuration associated with the reputation profiles.

reputationProfileId Integer

. Unique identifier of the reputation profile you want to return information for. If not included, information is returned for all your reputation profiles.

configId number

. Unique identifier of the security configuration associated with the reputation profiles.

reputationProfileId number

. Unique identifier of the reputation profile you want to return information for. If not included, information is returned for all your reputation profiles.

config_id int

. Unique identifier of the security configuration associated with the reputation profiles.

reputation_profile_id int

. Unique identifier of the reputation profile you want to return information for. If not included, information is returned for all your reputation profiles.

configId Number

. Unique identifier of the security configuration associated with the reputation profiles.

reputationProfileId Number

. Unique identifier of the reputation profile you want to return information for. If not included, information is returned for all your reputation profiles.

getAppSecReputationProfiles Result

The following output properties are available:

ConfigId int
Id string

The provider-assigned unique ID for this managed resource.

Json string
OutputText string
ReputationProfileId int
ConfigId int
Id string

The provider-assigned unique ID for this managed resource.

Json string
OutputText string
ReputationProfileId int
configId Integer
id String

The provider-assigned unique ID for this managed resource.

json String
outputText String
reputationProfileId Integer
configId number
id string

The provider-assigned unique ID for this managed resource.

json string
outputText string
reputationProfileId number
config_id int
id str

The provider-assigned unique ID for this managed resource.

json str
output_text str
reputation_profile_id int
configId Number
id String

The provider-assigned unique ID for this managed resource.

json String
outputText String
reputationProfileId Number

Package Details

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

This Pulumi package is based on the akamai Terraform Provider.