Skip to content

Role methods: review, staff, vacate

The Role Verbs review, staff, vacate as typed SDK methods, with inputs, result, refusals and an example.

Reference for Role, one group of Role methods.

Role.review

Review checks one Role against its contract for a period and records a Role Review. Verb page.

TypeScript
interface RoleVerbs {
  review(input: RoleReviewInput, options?: SB.CallOptions): SB.Call<RoleReviewOutput>
}

Emits Role.reviewed.

Inputs

InputTypeRequiredDescription
roleRolerequiredThe Role to review.
periodstringrequiredThe period it covers, such as 2026-W43.

Returns

OutputTypeRequiredDescription
roleRolerequiredThe reviewed Role.
roleReviewRole ReviewrequiredThe recorded Role Review.

Refuses when

CheckErrorFixThen call
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.

Example

TypeScript
import { $ } from 'startup-builder'

const { role, roleReview } = await $.Role.review({ role: 'role_oloMFMUeCH', period: 'Example period' })

Role.staff

Staff fills a Role with a Worker, human or agent, who then performs the Role’s Verbs under its Permissions. Verb page.

TypeScript
interface RoleVerbs {
  staff(input: RoleStaffInput, options?: SB.CallOptions): SB.Call<Role>
}

Emits Role.staffed.

Inputs

InputTypeRequiredDescription
roleRolerequiredThe Role to fill.
workerWorkerrequiredThe Worker who fills it.

Returns

OutputTypeRequiredDescription
roleRolerequiredThe staffed Role.

Refuses when

CheckErrorFixThen call
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 role = await $.Role.staff({ role: 'role_oloMFMUeCH', worker: 'worker_whZFpOKWIV' })

Role.vacate

Vacate takes the Worker out of a Role, and the seat’s Tasks route to the Role it escalates to until a new Worker is staffed. Verb page.

TypeScript
interface RoleVerbs {
  vacate(input: RoleVacateInput, options?: SB.CallOptions): SB.Call<Role>
}

Emits Role.vacated.

Inputs

InputTypeRequiredDescription
roleRolerequiredThe Role to empty.
reasontextWhy the seat empties.

Returns

OutputTypeRequiredDescription
roleRolerequiredThe vacant Role.

Refuses when

CheckErrorFixThen call
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.

Example

TypeScript
import { $ } from 'startup-builder'

const role = await $.Role.vacate({ role: 'role_oloMFMUeCH' })