Skip to content

Experiment methods: conclude, start

The Experiment Verbs conclude, start as typed SDK methods, with inputs, result, refusals and an example.

Reference for Experiment, one group of Experiment methods.

Experiment.conclude

Conclude ends an Experiment with a decision to ship, kill, or iterate, recorded as a Decision. Verb page.

TypeScript
interface ExperimentVerbs {
  conclude(input: ExperimentConcludeInput, options?: SB.CallOptions): SB.Call<ExperimentConcludeOutput>
}

Emits Experiment.concluded.

Inputs

InputTypeRequiredDescription
experimentExperimentrequiredThe running Experiment.
decisionstringrequiredOne of ship, kill, iterate.

Returns

OutputTypeRequiredDescription
decisionDecisionrequiredThe recorded Decision.
experimentExperimentrequiredThe Experiment, now concluded.

Refuses when

CheckErrorFixThen call
The input does not match the schema of the operation.invalid-inputRead the schema of the operation, then send every required field with the right type.None.
The key is valid, but its scopes do not allow this operation.forbiddenUse a key whose scopes cover the operation, or ask an owner of the namespace to grant them.None.
The record is not in a state that allows this Verb, so the call is refused.refusedRead the record, run the Verb that moves it to an allowed state, then retry.None.

Example

TypeScript
import { $ } from 'startup-builder'

const { decision, experiment } = await $.Experiment.conclude({ experiment: 'experiment_IyIJJPngKt', decision: 'ship' })

Experiment.start

Start opens an Experiment, splits traffic across its variants, and begins measuring its primary and guardrail Metrics. Verb page.

TypeScript
interface ExperimentVerbs {
  start(input: ExperimentStartInput, options?: SB.CallOptions): SB.Call<Experiment>
}

Emits Experiment.started.

Inputs

InputTypeRequiredDescription
experimentExperimentrequiredThe Experiment to open.

Returns

OutputTypeRequiredDescription
experimentExperimentrequiredThe running Experiment.

Refuses when

CheckErrorFixThen call
The input does not match the schema of the operation.invalid-inputRead the schema of the operation, then send every required field with the right type.None.
The key is valid, but its scopes do not allow this operation.forbiddenUse a key whose scopes cover the operation, or ask an owner of the namespace to grant them.None.
The record is not in a state that allows this Verb, so the call is refused.refusedRead the record, run the Verb that moves it to an allowed state, then retry.None.

Example

TypeScript
import { $ } from 'startup-builder'

const experiment = await $.Experiment.start({ experiment: 'experiment_IyIJJPngKt' })