Akamai

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

getProperty

Deprecated:

akamai.properties.getProperty has been deprecated in favor of akamai.getProperty

Use the akamai.Property data source to query and list the property ID and rule tree based on the property name.

Attributes reference

This data source returns these attributes:

  • property_ID - A property’s unique identifier, including the prp_ prefix.
  • rules - A JSON-encoded rule tree for a given property.

Example Usage

using Pulumi;
using Akamai = Pulumi.Akamai;

class MyStack : Stack
{
    public MyStack()
    {
        var example = Output.Create(Akamai.GetProperty.InvokeAsync(new Akamai.GetPropertyArgs
        {
            Name = "terraform-demo",
            Version = 1,
        }));
        this.MyPropertyID = example;
    }

    [Output("myPropertyID")]
    public Output<string> MyPropertyID { 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 {
		example, err := akamai.LookupProperty(ctx, &GetPropertyArgs{
			Name:    "terraform-demo",
			Version: pulumi.IntRef(1),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("myPropertyID", example)
		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.GetPropertyArgs;
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 example = AkamaiFunctions.getProperty(GetPropertyArgs.builder()
            .name("terraform-demo")
            .version("1")
            .build());

        ctx.export("myPropertyID", example.applyValue(getPropertyResult -> getPropertyResult));
    }
}
import pulumi
import pulumi_akamai as akamai

example = akamai.get_property(name="terraform-demo",
    version=1)
pulumi.export("myPropertyID", example)
import * as pulumi from "@pulumi/pulumi";
import * as akamai from "@pulumi/akamai";

const example = akamai.getProperty({
    name: "terraform-demo",
    version: 1,
});
export const myPropertyID = example;
variables:
  example:
    Fn::Invoke:
      Function: akamai:getProperty
      Arguments:
        name: terraform-demo
        version: 1
outputs:
  myPropertyID: ${example}

Using getProperty

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 getProperty(args: GetPropertyArgs, opts?: InvokeOptions): Promise<GetPropertyResult>
function getPropertyOutput(args: GetPropertyOutputArgs, opts?: InvokeOptions): Output<GetPropertyResult>
def get_property(name: Optional[str] = None,
                 version: Optional[int] = None,
                 opts: Optional[InvokeOptions] = None) -> GetPropertyResult
def get_property_output(name: Optional[pulumi.Input[str]] = None,
                 version: Optional[pulumi.Input[int]] = None,
                 opts: Optional[InvokeOptions] = None) -> Output[GetPropertyResult]
func LookupProperty(ctx *Context, args *LookupPropertyArgs, opts ...InvokeOption) (*LookupPropertyResult, error)
func LookupPropertyOutput(ctx *Context, args *LookupPropertyOutputArgs, opts ...InvokeOption) LookupPropertyResultOutput

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

public static class GetProperty 
{
    public static Task<GetPropertyResult> InvokeAsync(GetPropertyArgs args, InvokeOptions? opts = null)
    public static Output<GetPropertyResult> Invoke(GetPropertyInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetPropertyResult> getProperty(GetPropertyArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: akamai:properties/getProperty:getProperty
  Arguments:
    # Arguments dictionary

The following arguments are supported:

Name string

- (Required) The property name.

Version int

- (Optional) The version of the property whose ID you want to list.

Name string

- (Required) The property name.

Version int

- (Optional) The version of the property whose ID you want to list.

name String

- (Required) The property name.

version Integer

- (Optional) The version of the property whose ID you want to list.

name string

- (Required) The property name.

version number

- (Optional) The version of the property whose ID you want to list.

name str

- (Required) The property name.

version int

- (Optional) The version of the property whose ID you want to list.

name String

- (Required) The property name.

version Number

- (Optional) The version of the property whose ID you want to list.

getProperty Result

The following output properties are available:

Id string

The provider-assigned unique ID for this managed resource.

Name string
Rules string
Version int
Id string

The provider-assigned unique ID for this managed resource.

Name string
Rules string
Version int
id String

The provider-assigned unique ID for this managed resource.

name String
rules String
version Integer
id string

The provider-assigned unique ID for this managed resource.

name string
rules string
version number
id str

The provider-assigned unique ID for this managed resource.

name str
rules str
version int
id String

The provider-assigned unique ID for this managed resource.

name String
rules String
version 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.