# Prompt Guide

## Retrieve

`client.models.promptGuide.retrieve(stringmodelID, PromptGuideRetrieveParamsquery?, RequestOptionsoptions?): PromptGuideRetrieveResponse`

**get** `/models/{modelId}/prompt-guide`

Get the prompt guide of the given `modelId`

### Parameters

- `modelID: string`

- `query: PromptGuideRetrieveParams`

  - `projectId?: string`

    The projectId used for ownership resource management. Either to assert ownership or to set the owner of the resource(s)

### Returns

- `PromptGuideRetrieveResponse`

  - `promptGuide: PromptGuide`

    - `value: string`

      The markdown prompt guide used as the system prompt for Prompt Spark.

      Instructions and baked-in examples both live in this single markdown document.
      No runtime templating is performed on it.

### Example

```typescript
import Scenario from '@scenario-labs/sdk';

const client = new Scenario({
  apiKey: process.env['SCENARIO_SDK_API_KEY'], // This is the default and can be omitted
  apiSecret: process.env['SCENARIO_SDK_API_SECRET'], // This is the default and can be omitted
});

const promptGuide = await client.models.promptGuide.retrieve('modelId');

console.log(promptGuide.promptGuide);
```

#### Response

```json
{
  "promptGuide": {
    "value": "value"
  }
}
```

## Update

`client.models.promptGuide.update(stringmodelID, PromptGuideUpdateParamsparams, RequestOptionsoptions?): PromptGuideUpdateResponse`

**put** `/models/{modelId}/prompt-guide`

Update the markdown prompt guide of the given `modelId`

### Parameters

- `modelID: string`

- `params: PromptGuideUpdateParams`

  - `promptGuide: string`

    Body param: The markdown prompt guide (ex: `# Instructions\n...`). Set to `null` to delete the prompt guide.

  - `projectId?: string`

    Query param: The projectId used for ownership resource management. Either to assert ownership or to set the owner of the resource(s)

### Returns

- `PromptGuideUpdateResponse`

  - `promptGuide: PromptGuide`

    - `value: string`

      The markdown prompt guide used as the system prompt for Prompt Spark.

      Instructions and baked-in examples both live in this single markdown document.
      No runtime templating is performed on it.

### Example

```typescript
import Scenario from '@scenario-labs/sdk';

const client = new Scenario({
  apiKey: process.env['SCENARIO_SDK_API_KEY'], // This is the default and can be omitted
  apiSecret: process.env['SCENARIO_SDK_API_SECRET'], // This is the default and can be omitted
});

const promptGuide = await client.models.promptGuide.update('modelId', {
  promptGuide: 'promptGuide',
});

console.log(promptGuide.promptGuide);
```

#### Response

```json
{
  "promptGuide": {
    "value": "value"
  }
}
```

## Domain Types

### Prompt Guide Retrieve Response

- `PromptGuideRetrieveResponse`

  - `promptGuide: PromptGuide`

    - `value: string`

      The markdown prompt guide used as the system prompt for Prompt Spark.

      Instructions and baked-in examples both live in this single markdown document.
      No runtime templating is performed on it.

### Prompt Guide Update Response

- `PromptGuideUpdateResponse`

  - `promptGuide: PromptGuide`

    - `value: string`

      The markdown prompt guide used as the system prompt for Prompt Spark.

      Instructions and baked-in examples both live in this single markdown document.
      No runtime templating is performed on it.
