POST
/
v1
/
benchmarks
import Runloop from '@runloop/api-client';

const client = new Runloop({
  bearerToken: process.env['RUNLOOP_API_KEY'], // This is the default and can be omitted
});

async function main() {
  const benchmark = await client.benchmarks.create({ is_public: true, name: 'name' });

  console.log(benchmark.id);
}

main();
{
  "id": "<string>",
  "name": "<string>",
  "scenarioIds": [
    "<string>"
  ],
  "metadata": {},
  "is_public": true
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

BenchmarkCreateParameters contain the set of paramters to create a Benchmark.

name
string
required

The name of the Benchmark.

is_public
boolean
required

Whether this benchmark is public.

scenario_ids
string[] | null

The Scenario IDs that make up the Benchmark.

metadata
object | null

User defined metadata to attach to the benchmark for organization.

Response

200 - application/json
OK

A BenchmarkView represents a grouped set of Scenarios that together form a Benchmark.

id
string
required

The ID of the Benchmark.

name
string
required

The name of the Benchmark.

scenarioIds
string[]
required

List of Scenario IDs that make up the benchmark.

metadata
object
required

User defined metadata to attach to the benchmark for organization.

is_public
boolean

Whether this benchmark is public.

Was this page helpful?