# IResourceWithArgs.withArgs

- Module: [Aspire.Hosting](/reference/api/typescript/aspire.hosting.md)
- Defined on: [IResourceWithArgs](/reference/api/typescript/aspire.hosting/iresourcewithargs.md)
- Version: `13.4.0`
- Kind: `method`

Adds arguments to be passed to a resource that supports arguments when it is launched.

## Definition

```typescript
interface IResourceWithArgs {
  // ... omitted for brevity
  withArgs(args: string[]): IResourceWithArgs;
}
```

## Signature

```typescript
withArgs(args: string[]): IResourceWithArgs
```

## Parameters

- `args` (`string[]`)

## Returns

[IResourceWithArgs](/reference/api/typescript/aspire.hosting/iresourcewithargs.md) `builder`

## Defined on

- [IResourceWithArgs](/reference/api/typescript/aspire.hosting/iresourcewithargs.md) -- `interface`
