# getTargetCapability()

[**PromptScript API**](https://getpromptscript.dev/api-reference/index.md)

***

# Function: getTargetCapability()

> **getTargetCapability**(`name`): [`TargetCapability`](https://getpromptscript.dev/api-reference/core/src/interfaces/TargetCapability/index.md)

Defined in: [core/src/target-catalog.ts:926](https://github.com/mrwogu/promptscript/blob/49aa50f943865b985366c4eda6e95c5a31ef39a6/packages/core/src/target-catalog.ts#L926)

Get the complete capability contract for a known target.

## Parameters

### name

[`KnownTarget`](https://getpromptscript.dev/api-reference/core/src/type-aliases/KnownTarget/index.md)

The target name

## Returns

[`TargetCapability`](https://getpromptscript.dev/api-reference/core/src/interfaces/TargetCapability/index.md)

The target capability contract