1. Packages
  2. Spectrocloud Provider
  3. API Docs
  4. Macros
Viewing docs for spectrocloud 0.28.3
published on Friday, Mar 6, 2026 by spectrocloud
spectrocloud logo
Viewing docs for spectrocloud 0.28.3
published on Friday, Mar 6, 2026 by spectrocloud

    A resource for creating and managing service output variables and macros.

    Create Macros Resource

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

    Constructor syntax

    new Macros(name: string, args: MacrosArgs, opts?: CustomResourceOptions);
    @overload
    def Macros(resource_name: str,
               args: MacrosArgs,
               opts: Optional[ResourceOptions] = None)
    
    @overload
    def Macros(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               macros: Optional[Mapping[str, str]] = None,
               context: Optional[str] = None,
               macros_id: Optional[str] = None,
               timeouts: Optional[MacrosTimeoutsArgs] = None)
    func NewMacros(ctx *Context, name string, args MacrosArgs, opts ...ResourceOption) (*Macros, error)
    public Macros(string name, MacrosArgs args, CustomResourceOptions? opts = null)
    public Macros(String name, MacrosArgs args)
    public Macros(String name, MacrosArgs args, CustomResourceOptions options)
    
    type: spectrocloud:Macros
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args MacrosArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args MacrosArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args MacrosArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args MacrosArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args MacrosArgs
    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 macrosResource = new Spectrocloud.Macros("macrosResource", new()
    {
        Macros = 
        {
            { "string", "string" },
        },
        Context = "string",
        MacrosId = "string",
        Timeouts = new Spectrocloud.Inputs.MacrosTimeoutsArgs
        {
            Create = "string",
            Delete = "string",
            Update = "string",
        },
    });
    
    example, err := spectrocloud.NewMacros(ctx, "macrosResource", &spectrocloud.MacrosArgs{
    	Macros: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    	Context:  pulumi.String("string"),
    	MacrosId: pulumi.String("string"),
    	Timeouts: &spectrocloud.MacrosTimeoutsArgs{
    		Create: pulumi.String("string"),
    		Delete: pulumi.String("string"),
    		Update: pulumi.String("string"),
    	},
    })
    
    var macrosResource = new Macros("macrosResource", MacrosArgs.builder()
        .macros(Map.of("string", "string"))
        .context("string")
        .macrosId("string")
        .timeouts(MacrosTimeoutsArgs.builder()
            .create("string")
            .delete("string")
            .update("string")
            .build())
        .build());
    
    macros_resource = spectrocloud.Macros("macrosResource",
        macros={
            "string": "string",
        },
        context="string",
        macros_id="string",
        timeouts={
            "create": "string",
            "delete": "string",
            "update": "string",
        })
    
    const macrosResource = new spectrocloud.Macros("macrosResource", {
        macros: {
            string: "string",
        },
        context: "string",
        macrosId: "string",
        timeouts: {
            create: "string",
            "delete": "string",
            update: "string",
        },
    });
    
    type: spectrocloud:Macros
    properties:
        context: string
        macros:
            string: string
        macrosId: string
        timeouts:
            create: string
            delete: string
            update: string
    

    Macros 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 Macros resource accepts the following input properties:

    Macros Dictionary<string, string>
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    Context string
    MacrosId string
    Timeouts MacrosTimeouts
    Macros map[string]string
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    Context string
    MacrosId string
    Timeouts MacrosTimeoutsArgs
    macros Map<String,String>
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    context String
    macrosId String
    timeouts MacrosTimeouts
    macros {[key: string]: string}
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    context string
    macrosId string
    timeouts MacrosTimeouts
    macros Mapping[str, str]
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    context str
    macros_id str
    timeouts MacrosTimeoutsArgs
    macros Map<String>
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    context String
    macrosId String
    timeouts Property Map

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Macros 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 Macros Resource

    Get an existing Macros 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?: MacrosState, opts?: CustomResourceOptions): Macros
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            context: Optional[str] = None,
            macros: Optional[Mapping[str, str]] = None,
            macros_id: Optional[str] = None,
            timeouts: Optional[MacrosTimeoutsArgs] = None) -> Macros
    func GetMacros(ctx *Context, name string, id IDInput, state *MacrosState, opts ...ResourceOption) (*Macros, error)
    public static Macros Get(string name, Input<string> id, MacrosState? state, CustomResourceOptions? opts = null)
    public static Macros get(String name, Output<String> id, MacrosState state, CustomResourceOptions options)
    resources:  _:    type: spectrocloud:Macros    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    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
    The unique name of the resulting resource.
    id
    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:
    Context string
    Macros Dictionary<string, string>
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    MacrosId string
    Timeouts MacrosTimeouts
    Context string
    Macros map[string]string
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    MacrosId string
    Timeouts MacrosTimeoutsArgs
    context String
    macros Map<String,String>
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    macrosId String
    timeouts MacrosTimeouts
    context string
    macros {[key: string]: string}
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    macrosId string
    timeouts MacrosTimeouts
    context str
    macros Mapping[str, str]
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    macros_id str
    timeouts MacrosTimeoutsArgs
    context String
    macros Map<String>
    The key-value mapping includes the macro name and its corresponding value, representing either a macro or a service variable output.
    macrosId String
    timeouts Property Map

    Supporting Types

    MacrosTimeouts, MacrosTimeoutsArgs

    Create string
    Delete string
    Update string
    Create string
    Delete string
    Update string
    create String
    delete String
    update String
    create string
    delete string
    update string
    create str
    delete str
    update str
    create String
    delete String
    update String

    Package Details

    Repository
    spectrocloud spectrocloud/terraform-provider-spectrocloud
    License
    Notes
    This Pulumi package is based on the spectrocloud Terraform Provider.
    spectrocloud logo
    Viewing docs for spectrocloud 0.28.3
    published on Friday, Mar 6, 2026 by spectrocloud
      Try Pulumi Cloud free. Your team will thank you.