# PowerShellScriptResource.WithArgs

- Module: [CommunityToolkit.Aspire.Hosting.PowerShell](/reference/api/go/communitytoolkit.aspire.hosting.powershell.md)
- Defined on: [PowerShellScriptResource](/reference/api/go/communitytoolkit.aspire.hosting.powershell/powershellscriptresource.md)
- Version: `13.6.1`
- Kind: `method`

## Definition

```go
type PowerShellScriptResource interface {
    // ... omitted for brevity
    WithArgs(args []string) PowerShellScriptResource
}
```

## Signature

```go
WithArgs(args []string) PowerShellScriptResource
```

## Parameters

- `args` (`[]string`)

## Returns

[`PowerShellScriptResource`](/reference/api/go/communitytoolkit.aspire.hosting.powershell/powershellscriptresource.md)

Returns a handle; failures surface later via `Err()`.

## Defined on

- [PowerShellScriptResource](/reference/api/go/communitytoolkit.aspire.hosting.powershell/powershellscriptresource.md) -- `handle`
