1. Packages
  2. Splight
  3. API Docs
  4. AssetRelation
splight v1.2.13 published on Friday, Feb 14, 2025 by splightplatform

splight.AssetRelation

Explore with Pulumi AI

Example Usage

Create AssetRelation Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new AssetRelation(name: string, args: AssetRelationArgs, opts?: CustomResourceOptions);
@overload
def AssetRelation(resource_name: str,
                  args: AssetRelationArgs,
                  opts: Optional[ResourceOptions] = None)

@overload
def AssetRelation(resource_name: str,
                  opts: Optional[ResourceOptions] = None,
                  asset: Optional[AssetRelationAssetArgs] = None,
                  related_asset_kind: Optional[AssetRelationRelatedAssetKindArgs] = None,
                  description: Optional[str] = None,
                  name: Optional[str] = None,
                  related_asset: Optional[AssetRelationRelatedAssetArgs] = None)
func NewAssetRelation(ctx *Context, name string, args AssetRelationArgs, opts ...ResourceOption) (*AssetRelation, error)
public AssetRelation(string name, AssetRelationArgs args, CustomResourceOptions? opts = null)
public AssetRelation(String name, AssetRelationArgs args)
public AssetRelation(String name, AssetRelationArgs args, CustomResourceOptions options)
type: splight:AssetRelation
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. AssetRelationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. AssetRelationArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. AssetRelationArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. AssetRelationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. AssetRelationArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var assetRelationResource = new Splight.AssetRelation("assetRelationResource", new()
{
    Asset = new Splight.Inputs.AssetRelationAssetArgs
    {
        Id = "string",
        Name = "string",
    },
    RelatedAssetKind = new Splight.Inputs.AssetRelationRelatedAssetKindArgs
    {
        Id = "string",
        Name = "string",
    },
    Description = "string",
    Name = "string",
    RelatedAsset = new Splight.Inputs.AssetRelationRelatedAssetArgs
    {
        Id = "string",
        Name = "string",
    },
});
Copy
example, err := splight.NewAssetRelation(ctx, "assetRelationResource", &splight.AssetRelationArgs{
	Asset: &splight.AssetRelationAssetArgs{
		Id:   pulumi.String("string"),
		Name: pulumi.String("string"),
	},
	RelatedAssetKind: &splight.AssetRelationRelatedAssetKindArgs{
		Id:   pulumi.String("string"),
		Name: pulumi.String("string"),
	},
	Description: pulumi.String("string"),
	Name:        pulumi.String("string"),
	RelatedAsset: &splight.AssetRelationRelatedAssetArgs{
		Id:   pulumi.String("string"),
		Name: pulumi.String("string"),
	},
})
Copy
var assetRelationResource = new AssetRelation("assetRelationResource", AssetRelationArgs.builder()
    .asset(AssetRelationAssetArgs.builder()
        .id("string")
        .name("string")
        .build())
    .relatedAssetKind(AssetRelationRelatedAssetKindArgs.builder()
        .id("string")
        .name("string")
        .build())
    .description("string")
    .name("string")
    .relatedAsset(AssetRelationRelatedAssetArgs.builder()
        .id("string")
        .name("string")
        .build())
    .build());
Copy
asset_relation_resource = splight.AssetRelation("assetRelationResource",
    asset={
        "id": "string",
        "name": "string",
    },
    related_asset_kind={
        "id": "string",
        "name": "string",
    },
    description="string",
    name="string",
    related_asset={
        "id": "string",
        "name": "string",
    })
Copy
const assetRelationResource = new splight.AssetRelation("assetRelationResource", {
    asset: {
        id: "string",
        name: "string",
    },
    relatedAssetKind: {
        id: "string",
        name: "string",
    },
    description: "string",
    name: "string",
    relatedAsset: {
        id: "string",
        name: "string",
    },
});
Copy
type: splight:AssetRelation
properties:
    asset:
        id: string
        name: string
    description: string
    name: string
    relatedAsset:
        id: string
        name: string
    relatedAssetKind:
        id: string
        name: string
Copy

AssetRelation Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The AssetRelation resource accepts the following input properties:

Asset
This property is required.
Changes to this property will trigger replacement.
Splight.Splight.Inputs.AssetRelationAsset
asset where the relation origins
RelatedAssetKind This property is required. Splight.Splight.Inputs.AssetRelationRelatedAssetKind
kind of the target relation asset
Description string
relation description
Name Changes to this property will trigger replacement. string
relation name
RelatedAsset Splight.Splight.Inputs.AssetRelationRelatedAsset
target asset of the relation
Asset
This property is required.
Changes to this property will trigger replacement.
AssetRelationAssetArgs
asset where the relation origins
RelatedAssetKind This property is required. AssetRelationRelatedAssetKindArgs
kind of the target relation asset
Description string
relation description
Name Changes to this property will trigger replacement. string
relation name
RelatedAsset AssetRelationRelatedAssetArgs
target asset of the relation
asset
This property is required.
Changes to this property will trigger replacement.
AssetRelationAsset
asset where the relation origins
relatedAssetKind This property is required. AssetRelationRelatedAssetKind
kind of the target relation asset
description String
relation description
name Changes to this property will trigger replacement. String
relation name
relatedAsset AssetRelationRelatedAsset
target asset of the relation
asset
This property is required.
Changes to this property will trigger replacement.
AssetRelationAsset
asset where the relation origins
relatedAssetKind This property is required. AssetRelationRelatedAssetKind
kind of the target relation asset
description string
relation description
name Changes to this property will trigger replacement. string
relation name
relatedAsset AssetRelationRelatedAsset
target asset of the relation
asset
This property is required.
Changes to this property will trigger replacement.
AssetRelationAssetArgs
asset where the relation origins
related_asset_kind This property is required. AssetRelationRelatedAssetKindArgs
kind of the target relation asset
description str
relation description
name Changes to this property will trigger replacement. str
relation name
related_asset AssetRelationRelatedAssetArgs
target asset of the relation
asset
This property is required.
Changes to this property will trigger replacement.
Property Map
asset where the relation origins
relatedAssetKind This property is required. Property Map
kind of the target relation asset
description String
relation description
name Changes to this property will trigger replacement. String
relation name
relatedAsset Property Map
target asset of the relation

Outputs

All input properties are implicitly available as output properties. Additionally, the AssetRelation resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing AssetRelation Resource

Get an existing AssetRelation resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: AssetRelationState, opts?: CustomResourceOptions): AssetRelation
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        asset: Optional[AssetRelationAssetArgs] = None,
        description: Optional[str] = None,
        name: Optional[str] = None,
        related_asset: Optional[AssetRelationRelatedAssetArgs] = None,
        related_asset_kind: Optional[AssetRelationRelatedAssetKindArgs] = None) -> AssetRelation
func GetAssetRelation(ctx *Context, name string, id IDInput, state *AssetRelationState, opts ...ResourceOption) (*AssetRelation, error)
public static AssetRelation Get(string name, Input<string> id, AssetRelationState? state, CustomResourceOptions? opts = null)
public static AssetRelation get(String name, Output<String> id, AssetRelationState state, CustomResourceOptions options)
resources:  _:    type: splight:AssetRelation    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
Asset Changes to this property will trigger replacement. Splight.Splight.Inputs.AssetRelationAsset
asset where the relation origins
Description string
relation description
Name Changes to this property will trigger replacement. string
relation name
RelatedAsset Splight.Splight.Inputs.AssetRelationRelatedAsset
target asset of the relation
RelatedAssetKind Splight.Splight.Inputs.AssetRelationRelatedAssetKind
kind of the target relation asset
Asset Changes to this property will trigger replacement. AssetRelationAssetArgs
asset where the relation origins
Description string
relation description
Name Changes to this property will trigger replacement. string
relation name
RelatedAsset AssetRelationRelatedAssetArgs
target asset of the relation
RelatedAssetKind AssetRelationRelatedAssetKindArgs
kind of the target relation asset
asset Changes to this property will trigger replacement. AssetRelationAsset
asset where the relation origins
description String
relation description
name Changes to this property will trigger replacement. String
relation name
relatedAsset AssetRelationRelatedAsset
target asset of the relation
relatedAssetKind AssetRelationRelatedAssetKind
kind of the target relation asset
asset Changes to this property will trigger replacement. AssetRelationAsset
asset where the relation origins
description string
relation description
name Changes to this property will trigger replacement. string
relation name
relatedAsset AssetRelationRelatedAsset
target asset of the relation
relatedAssetKind AssetRelationRelatedAssetKind
kind of the target relation asset
asset Changes to this property will trigger replacement. AssetRelationAssetArgs
asset where the relation origins
description str
relation description
name Changes to this property will trigger replacement. str
relation name
related_asset AssetRelationRelatedAssetArgs
target asset of the relation
related_asset_kind AssetRelationRelatedAssetKindArgs
kind of the target relation asset
asset Changes to this property will trigger replacement. Property Map
asset where the relation origins
description String
relation description
name Changes to this property will trigger replacement. String
relation name
relatedAsset Property Map
target asset of the relation
relatedAssetKind Property Map
kind of the target relation asset

Supporting Types

AssetRelationAsset
, AssetRelationAssetArgs

Id
This property is required.
Changes to this property will trigger replacement.
string
asset id
Name
This property is required.
Changes to this property will trigger replacement.
string
asset name
Id
This property is required.
Changes to this property will trigger replacement.
string
asset id
Name
This property is required.
Changes to this property will trigger replacement.
string
asset name
id
This property is required.
Changes to this property will trigger replacement.
String
asset id
name
This property is required.
Changes to this property will trigger replacement.
String
asset name
id
This property is required.
Changes to this property will trigger replacement.
string
asset id
name
This property is required.
Changes to this property will trigger replacement.
string
asset name
id
This property is required.
Changes to this property will trigger replacement.
str
asset id
name
This property is required.
Changes to this property will trigger replacement.
str
asset name
id
This property is required.
Changes to this property will trigger replacement.
String
asset id
name
This property is required.
Changes to this property will trigger replacement.
String
asset name

AssetRelationRelatedAsset
, AssetRelationRelatedAssetArgs

Id
This property is required.
Changes to this property will trigger replacement.
string
asset id
Name
This property is required.
Changes to this property will trigger replacement.
string
asset name
Id
This property is required.
Changes to this property will trigger replacement.
string
asset id
Name
This property is required.
Changes to this property will trigger replacement.
string
asset name
id
This property is required.
Changes to this property will trigger replacement.
String
asset id
name
This property is required.
Changes to this property will trigger replacement.
String
asset name
id
This property is required.
Changes to this property will trigger replacement.
string
asset id
name
This property is required.
Changes to this property will trigger replacement.
string
asset name
id
This property is required.
Changes to this property will trigger replacement.
str
asset id
name
This property is required.
Changes to this property will trigger replacement.
str
asset name
id
This property is required.
Changes to this property will trigger replacement.
String
asset id
name
This property is required.
Changes to this property will trigger replacement.
String
asset name

AssetRelationRelatedAssetKind
, AssetRelationRelatedAssetKindArgs

Id
This property is required.
Changes to this property will trigger replacement.
string
kind id
Name
This property is required.
Changes to this property will trigger replacement.
string
kind name
Id
This property is required.
Changes to this property will trigger replacement.
string
kind id
Name
This property is required.
Changes to this property will trigger replacement.
string
kind name
id
This property is required.
Changes to this property will trigger replacement.
String
kind id
name
This property is required.
Changes to this property will trigger replacement.
String
kind name
id
This property is required.
Changes to this property will trigger replacement.
string
kind id
name
This property is required.
Changes to this property will trigger replacement.
string
kind name
id
This property is required.
Changes to this property will trigger replacement.
str
kind id
name
This property is required.
Changes to this property will trigger replacement.
str
kind name
id
This property is required.
Changes to this property will trigger replacement.
String
kind id
name
This property is required.
Changes to this property will trigger replacement.
String
kind name

Import

$ pulumi import splight:index/assetRelation:AssetRelation [options] splight_relation.<name> <relation_id>
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
splight splightplatform/pulumi-splight
License
Apache-2.0
Notes
This Pulumi package is based on the splight Terraform Provider.