For AI agents: The documentation index is at https://docs.digitalocean.com/llms.txt. Markdown versions of pages use the same URL with index.html.md in place of the HTML page (for example, append index.html.md to the directory path instead of opening the HTML document).
Usage
client.v2.genAi.scenario_sets.generate.post(body: ApiGenerateScenarioSetInputPublic, requestConfiguration?: RequestConfiguration<object>): Promise<undefined | ApiGenerateScenarioSetOutput>
Description
To dispatch goal-driven scenario generation, send a POST request to /v2/gen-ai/scenario_sets/generate. The scenario set is returned in the generating state. Poll the retrieve scenario set endpoint until the set reaches a ready, failed, or cancelled status.
Parameters
generatorModelUuid string optional
Example: 123e4567-e89b-12d3-a456-426614174000
Optional model to use for generation. Platform default when unset.
goalDescription string optional
Example: Test how the agent handles refund requests
The goal that drives scenario generation.
name string optional
Example: billing-support-generated
The name of the scenario set to create.
numScenarios integer optional
Example: 123
Number of scenarios to generate. Defaults to 1 if unset.
Request Sample
Show Request Sample
import { FetchRequestAdapter } from "@microsoft/kiota-http-fetchlibrary";
import {
createDigitalOceanClient,
DigitalOceanApiKeyAuthenticationProvider,
} from "@digitalocean/dots";
const authProvider = new DigitalOceanApiKeyAuthenticationProvider(process.env.DIGITALOCEAN_TOKEN!);
const adapter = new FetchRequestAdapter(authProvider);
const client = createDigitalOceanClient(adapter);
const response = await client.v2.genAi.scenario_sets.generate.post({
generatorModelUuid: "123e4567-e89b-12d3-a456-426614174000",
goalDescription: "Test how the agent handles refund requests",
name: "billing-support-generated",
numScenarios: 123,
});
Response Example
Show Response Example
{
"scenario_set": {
"bucket_name": "example name",
"bucket_region": "example string",
"created_at": "2023-01-01T00:00:00Z",
"deleted_at": "2023-01-01T00:00:00Z",
"description": "example string",
"failure_reason": "example string",
"generator_model_uuid": "123e4567-e89b-12d3-a456-426614174000",
"library_scenario_uuid": "123e4567-e89b-12d3-a456-426614174000",
"name": "example name",
"scenario_count": 123,
"scenario_set_uuid": "123e4567-e89b-12d3-a456-426614174000",
"source_export_id": "123e4567-e89b-12d3-a456-426614174000",
"source_goal_description": "example string",
"source_kind": "SCENARIO_SET_SOURCE_KIND_UNSPECIFIED",
"spaces_key": "example string",
"status": "SCENARIO_SET_STATUS_UNSPECIFIED",
"updated_at": "2023-01-01T00:00:00Z",
"workflow_uuid": "123e4567-e89b-12d3-a456-426614174000"
}
}
See /v2/gen-ai/scenario_sets/generate in the API reference for additional detail on responses, headers, parameters, and more.