1. Packages
  2. Octopusdeploy Provider
  3. API Docs
  4. getScriptModules
octopusdeploy 0.43.1 published on Wednesday, Apr 30, 2025 by octopusdeploylabs

octopusdeploy.getScriptModules

Explore with Pulumi AI

octopusdeploy logo
octopusdeploy 0.43.1 published on Wednesday, Apr 30, 2025 by octopusdeploylabs

    Provides information about existing script modules.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as octopusdeploy from "@pulumi/octopusdeploy";
    
    const example = octopusdeploy.getScriptModules({
        ids: [
            "LibraryVariableSets-123",
            "LibraryVariableSets-321",
        ],
        partialName: "Defau",
        skip: 5,
        take: 100,
    });
    
    import pulumi
    import pulumi_octopusdeploy as octopusdeploy
    
    example = octopusdeploy.get_script_modules(ids=[
            "LibraryVariableSets-123",
            "LibraryVariableSets-321",
        ],
        partial_name="Defau",
        skip=5,
        take=100)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/octopusdeploy/octopusdeploy"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := octopusdeploy.GetScriptModules(ctx, &octopusdeploy.GetScriptModulesArgs{
    			Ids: []string{
    				"LibraryVariableSets-123",
    				"LibraryVariableSets-321",
    			},
    			PartialName: pulumi.StringRef("Defau"),
    			Skip:        pulumi.Float64Ref(5),
    			Take:        pulumi.Float64Ref(100),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Octopusdeploy = Pulumi.Octopusdeploy;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Octopusdeploy.GetScriptModules.Invoke(new()
        {
            Ids = new[]
            {
                "LibraryVariableSets-123",
                "LibraryVariableSets-321",
            },
            PartialName = "Defau",
            Skip = 5,
            Take = 100,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.octopusdeploy.OctopusdeployFunctions;
    import com.pulumi.octopusdeploy.inputs.GetScriptModulesArgs;
    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 = OctopusdeployFunctions.getScriptModules(GetScriptModulesArgs.builder()
                .ids(            
                    "LibraryVariableSets-123",
                    "LibraryVariableSets-321")
                .partialName("Defau")
                .skip(5)
                .take(100)
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: octopusdeploy:getScriptModules
          arguments:
            ids:
              - LibraryVariableSets-123
              - LibraryVariableSets-321
            partialName: Defau
            skip: 5
            take: 100
    

    Using getScriptModules

    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 getScriptModules(args: GetScriptModulesArgs, opts?: InvokeOptions): Promise<GetScriptModulesResult>
    function getScriptModulesOutput(args: GetScriptModulesOutputArgs, opts?: InvokeOptions): Output<GetScriptModulesResult>
    def get_script_modules(ids: Optional[Sequence[str]] = None,
                           partial_name: Optional[str] = None,
                           skip: Optional[float] = None,
                           space_id: Optional[str] = None,
                           take: Optional[float] = None,
                           opts: Optional[InvokeOptions] = None) -> GetScriptModulesResult
    def get_script_modules_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                           partial_name: Optional[pulumi.Input[str]] = None,
                           skip: Optional[pulumi.Input[float]] = None,
                           space_id: Optional[pulumi.Input[str]] = None,
                           take: Optional[pulumi.Input[float]] = None,
                           opts: Optional[InvokeOptions] = None) -> Output[GetScriptModulesResult]
    func GetScriptModules(ctx *Context, args *GetScriptModulesArgs, opts ...InvokeOption) (*GetScriptModulesResult, error)
    func GetScriptModulesOutput(ctx *Context, args *GetScriptModulesOutputArgs, opts ...InvokeOption) GetScriptModulesResultOutput

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

    public static class GetScriptModules 
    {
        public static Task<GetScriptModulesResult> InvokeAsync(GetScriptModulesArgs args, InvokeOptions? opts = null)
        public static Output<GetScriptModulesResult> Invoke(GetScriptModulesInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetScriptModulesResult> getScriptModules(GetScriptModulesArgs args, InvokeOptions options)
    public static Output<GetScriptModulesResult> getScriptModules(GetScriptModulesArgs args, InvokeOptions options)
    
    fn::invoke:
      function: octopusdeploy:index/getScriptModules:getScriptModules
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Ids List<string>
    A filter to search by a list of IDs.
    PartialName string
    A filter to search by a partial name.
    Skip double
    A filter to specify the number of items to skip in the response.
    SpaceId string
    The space ID associated with this script module.
    Take double
    A filter to specify the number of items to take (or return) in the response.
    Ids []string
    A filter to search by a list of IDs.
    PartialName string
    A filter to search by a partial name.
    Skip float64
    A filter to specify the number of items to skip in the response.
    SpaceId string
    The space ID associated with this script module.
    Take float64
    A filter to specify the number of items to take (or return) in the response.
    ids List<String>
    A filter to search by a list of IDs.
    partialName String
    A filter to search by a partial name.
    skip Double
    A filter to specify the number of items to skip in the response.
    spaceId String
    The space ID associated with this script module.
    take Double
    A filter to specify the number of items to take (or return) in the response.
    ids string[]
    A filter to search by a list of IDs.
    partialName string
    A filter to search by a partial name.
    skip number
    A filter to specify the number of items to skip in the response.
    spaceId string
    The space ID associated with this script module.
    take number
    A filter to specify the number of items to take (or return) in the response.
    ids Sequence[str]
    A filter to search by a list of IDs.
    partial_name str
    A filter to search by a partial name.
    skip float
    A filter to specify the number of items to skip in the response.
    space_id str
    The space ID associated with this script module.
    take float
    A filter to specify the number of items to take (or return) in the response.
    ids List<String>
    A filter to search by a list of IDs.
    partialName String
    A filter to search by a partial name.
    skip Number
    A filter to specify the number of items to skip in the response.
    spaceId String
    The space ID associated with this script module.
    take Number
    A filter to specify the number of items to take (or return) in the response.

    getScriptModules Result

    The following output properties are available:

    Id string
    The unique ID for this resource.
    ScriptModules List<GetScriptModulesScriptModule>
    SpaceId string
    The space ID associated with this script module.
    Ids List<string>
    A filter to search by a list of IDs.
    PartialName string
    A filter to search by a partial name.
    Skip double
    A filter to specify the number of items to skip in the response.
    Take double
    A filter to specify the number of items to take (or return) in the response.
    Id string
    The unique ID for this resource.
    ScriptModules []GetScriptModulesScriptModule
    SpaceId string
    The space ID associated with this script module.
    Ids []string
    A filter to search by a list of IDs.
    PartialName string
    A filter to search by a partial name.
    Skip float64
    A filter to specify the number of items to skip in the response.
    Take float64
    A filter to specify the number of items to take (or return) in the response.
    id String
    The unique ID for this resource.
    scriptModules List<GetScriptModulesScriptModule>
    spaceId String
    The space ID associated with this script module.
    ids List<String>
    A filter to search by a list of IDs.
    partialName String
    A filter to search by a partial name.
    skip Double
    A filter to specify the number of items to skip in the response.
    take Double
    A filter to specify the number of items to take (or return) in the response.
    id string
    The unique ID for this resource.
    scriptModules GetScriptModulesScriptModule[]
    spaceId string
    The space ID associated with this script module.
    ids string[]
    A filter to search by a list of IDs.
    partialName string
    A filter to search by a partial name.
    skip number
    A filter to specify the number of items to skip in the response.
    take number
    A filter to specify the number of items to take (or return) in the response.
    id str
    The unique ID for this resource.
    script_modules Sequence[GetScriptModulesScriptModule]
    space_id str
    The space ID associated with this script module.
    ids Sequence[str]
    A filter to search by a list of IDs.
    partial_name str
    A filter to search by a partial name.
    skip float
    A filter to specify the number of items to skip in the response.
    take float
    A filter to specify the number of items to take (or return) in the response.
    id String
    The unique ID for this resource.
    scriptModules List<Property Map>
    spaceId String
    The space ID associated with this script module.
    ids List<String>
    A filter to search by a list of IDs.
    partialName String
    A filter to search by a partial name.
    skip Number
    A filter to specify the number of items to skip in the response.
    take Number
    A filter to specify the number of items to take (or return) in the response.

    Supporting Types

    GetScriptModulesScriptModule

    Description string
    The description of this script module.
    Id string
    The unique ID for this resource.
    Name string
    The name of this resource.
    Scripts List<GetScriptModulesScriptModuleScript>
    The script associated with this script module.
    SpaceId string
    The space ID associated with this Script Module.
    VariableSetId string
    The variable set ID for this script module.
    Description string
    The description of this script module.
    Id string
    The unique ID for this resource.
    Name string
    The name of this resource.
    Scripts []GetScriptModulesScriptModuleScript
    The script associated with this script module.
    SpaceId string
    The space ID associated with this Script Module.
    VariableSetId string
    The variable set ID for this script module.
    description String
    The description of this script module.
    id String
    The unique ID for this resource.
    name String
    The name of this resource.
    scripts List<GetScriptModulesScriptModuleScript>
    The script associated with this script module.
    spaceId String
    The space ID associated with this Script Module.
    variableSetId String
    The variable set ID for this script module.
    description string
    The description of this script module.
    id string
    The unique ID for this resource.
    name string
    The name of this resource.
    scripts GetScriptModulesScriptModuleScript[]
    The script associated with this script module.
    spaceId string
    The space ID associated with this Script Module.
    variableSetId string
    The variable set ID for this script module.
    description str
    The description of this script module.
    id str
    The unique ID for this resource.
    name str
    The name of this resource.
    scripts Sequence[GetScriptModulesScriptModuleScript]
    The script associated with this script module.
    space_id str
    The space ID associated with this Script Module.
    variable_set_id str
    The variable set ID for this script module.
    description String
    The description of this script module.
    id String
    The unique ID for this resource.
    name String
    The name of this resource.
    scripts List<Property Map>
    The script associated with this script module.
    spaceId String
    The space ID associated with this Script Module.
    variableSetId String
    The variable set ID for this script module.

    GetScriptModulesScriptModuleScript

    Body string
    The body of this script module.
    Syntax string
    The syntax of the script. Valid types are Bash, CSharp, FSharp, PowerShell, or Python.
    Body string
    The body of this script module.
    Syntax string
    The syntax of the script. Valid types are Bash, CSharp, FSharp, PowerShell, or Python.
    body String
    The body of this script module.
    syntax String
    The syntax of the script. Valid types are Bash, CSharp, FSharp, PowerShell, or Python.
    body string
    The body of this script module.
    syntax string
    The syntax of the script. Valid types are Bash, CSharp, FSharp, PowerShell, or Python.
    body str
    The body of this script module.
    syntax str
    The syntax of the script. Valid types are Bash, CSharp, FSharp, PowerShell, or Python.
    body String
    The body of this script module.
    syntax String
    The syntax of the script. Valid types are Bash, CSharp, FSharp, PowerShell, or Python.

    Package Details

    Repository
    octopusdeploy octopusdeploylabs/terraform-provider-octopusdeploy
    License
    Notes
    This Pulumi package is based on the octopusdeploy Terraform Provider.
    octopusdeploy logo
    octopusdeploy 0.43.1 published on Wednesday, Apr 30, 2025 by octopusdeploylabs