ReferenceReference by module

Work API

Every Work action (23) and data model (5): endpoints, scopes, input, preconditions, events and examples.

Ask once: Era plans it, splits it across workers that run in parallel, and brings back finished work to use or publish.

Module code work · 23 actions · 5 data models · 18 events. A key or token never does more here than the person behind it can; row-level security applies exactly as in the app. Scopes: work (everything), work:read (read only) or work:<capability>.

Resources

ResourceTableList and readPOSTPATCHDELETE
shop_ordersshop_order/api/v1/shop_orders
shop_rulesshop_rule/api/v1/shop_rules
work_computer_forkswork_computer_fork/api/v1/work_computer_forks
work_jobswork_job/api/v1/work_jobs
work_stepswork_step/api/v1/work_steps

Lists take limit (up to 200), cursor, order (e.g. -created_at), fields and q; every other query parameter is a column filter: ?status=paid, ?total[gte]=100, ?id[in]=a,b, ?x=null.

Actions

ActionNeedsWhat it does
work.add_stepwork:writeAdd a step to a plan
work.answer_needwork:writeAnswer a step that waits for you
work.approve_planwork:writeApprove a plan
work.assign_jobwork:writeGive a plan to someone
work.change_stepwork:writeChange a step
work.message_stepwork:writeTell a working agent something
work.propose_skillwork:handleOffer what Era learned
work.record_forkwork:handleRecord a borrowed computer
work.record_shop_orderwork:handleRecord an order Era placed
work.record_stepwork:handleRecord a step’s progress
work.release_forkwork:writeGive a borrowed computer back
work.replan_stepwork:handleRe-plan a step’s missing input
work.request_forkwork:writeBorrow a copy of my cloud computer
work.requeue_stepwork:handlePut a step back in line
work.resume_jobwork:writeResume a plan
work.retry_stepwork:writeTry a step again
work.review_skillwork:writeDecide what Era keeps
work.set_limitswork:writeChange a plan’s time limit
work.set_shop_rulework:writeSet when Era buys without asking
work.start_jobwork:writeStart a plan
work.stop_jobwork:writeStop a plan
work.supervise_stepwork:handleSupervise a running step
work.use_resultwork:writeUse a result

work.add_step

Add a step to a plan — "Şunu da ekle": one more step for a worker; it starts as soon as what it waits for is done.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_jobs/{id}/actions/add_step
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.add_step

Input

FieldTypeRequiredNotes
jobIduuidyesFilled from the path {id} · Plan · id of work_job
titlestringyesStep · max 200
workerstringyesWorker · dev | research | growth | marketing | creative | data | business | computer · max 20
instructionstringWhat to do · max 8000
runobject / arrayHow it runs
dependsOnobject / arrayWaits for · Step ids of the same plan.
confirmbooleanAsk me before it runs
notestringWhat you said · max 500

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
not_foundThe plan must exist in this workspace.
unknown_workerThe step names one of the eight workers.
unknown_executorThe step’s run names an executor Era has.
unknown_credentialA credential step names a credential Era knows how to ask for.
too_many_stepsA plan has at most 12 steps.
bad_stepsThe step needs a title.
bad_dependencyA step can only wait for steps of the same plan.
duplicate_stepThe plan does not already have this work still to do or done.

Events it publishes: work.step_changed

What it writes: work_step (insert) — Adds the step, queued; work_job (update) — Reopens the plan and notes what was said

curl -X POST https://app.getera.io/api/v1/work_jobs/WORK_JOB_ID/actions/add_step \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"title":"Step","worker":"Worker"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.step_changed"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workJobs.addStep("WORK_JOB_ID", {
  title: "Step",
  worker: "Worker"
})
era work_jobs add_step WORK_JOB_ID \
  --title "Step" \
  --worker "Worker"
tools/call
{
  "name": "era__work__add_step",
  "arguments": {
    "jobId": "WORK_JOB_ID",
    "title": "Step",
    "worker": "Worker"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 not_found, unknown_worker, unknown_executor, unknown_credential, too_many_steps, bad_steps, bad_dependency, duplicate_step · 429 slow down

work.answer_need

Answer a step that waits for you — Approve a risky step (it runs once) or decline it (it is skipped).

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/answer_need
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.answer_need

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Step · id of work_step
decisionstring (enum)yesDecision · Allowed values: approve, deny

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
nothing_to_answerOnly a step that waits for you can be answered.

Events it publishes: work.step_changed, work.job_finished, work.needs_you

What it writes: work_step (update) — Queues or skips the step; work_job (update) — Updates the plan’s status

curl -X POST https://app.getera.io/api/v1/work_steps/WORK_STEP_ID/actions/answer_need \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"decision":"approve"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.step_changed",
    "work.job_finished",
    "work.needs_you"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workSteps.answerNeed("WORK_STEP_ID", {
  decision: "approve"
})
era work_steps answer_need WORK_STEP_ID \
  --decision "approve"
tools/call
{
  "name": "era__work__answer_need",
  "arguments": {
    "id": "WORK_STEP_ID",
    "decision": "approve"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, nothing_to_answer · 429 slow down

work.approve_plan

Approve a plan — The go-ahead: the workers start on every step that waits for nothing.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_jobs/{id}/actions/approve_plan
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.approve_plan

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Plan · id of work_job

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
not_foundThe plan must exist in this workspace.
not_proposedOnly a plan waiting for approval can be approved.

Events it publishes: work.plan_approved

What it writes: work_job (update) — Marks the plan approved and running

curl -X POST https://app.getera.io/api/v1/work_jobs/WORK_JOB_ID/actions/approve_plan \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.plan_approved"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workJobs.approvePlan("WORK_JOB_ID")
era work_jobs approve_plan WORK_JOB_ID
tools/call
{
  "name": "era__work__approve_plan",
  "arguments": {
    "id": "WORK_JOB_ID"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 not_found, not_proposed · 429 slow down

work.assign_job

Give a plan to someone — Gives a plan to a person or back to Era, and says who sees it: the whole workspace or only the people on it.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_jobs/{id}/actions/assign_job
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.assign_job

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Plan · id of work_job
assigneeUserIduuidGive to · id of app_user
visibilitystring (enum)Who sees it · Allowed values: workspace, private

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
not_foundThe plan must exist in this workspace.
not_allowedOnly its author, its assignee or a work manager can hand it on.
finishedA finished plan keeps who answered for it.
not_a_memberA plan is given only to an active member of the workspace.

Events it publishes: work.job_assigned

What it writes: work_job (update) — Writes who answers for the plan and who sees it

curl -X POST https://app.getera.io/api/v1/work_jobs/WORK_JOB_ID/actions/assign_job \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"assigneeUserId":"APP_USER_ID"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.job_assigned"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workJobs.assignJob("WORK_JOB_ID", {
  assigneeUserId: "APP_USER_ID"
})
era work_jobs assign_job WORK_JOB_ID \
  --assignee-user-id "APP_USER_ID"
tools/call
{
  "name": "era__work__assign_job",
  "arguments": {
    "id": "WORK_JOB_ID",
    "assigneeUserId": "APP_USER_ID"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 not_found, not_allowed, finished, not_a_member · 429 slow down

work.change_step

Change a step — "Bunu değiştir": rewrites a step that has not started yet.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/change_step
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.change_step

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Step · id of work_step
titlestringStep · max 200
instructionstringWhat to do · max 8000
notestringWhat you said · max 500

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
step_startedA step that has started is not rewritten; a follow-up step is added instead.
bad_stepsA step keeps a title.

Events it publishes: work.step_changed

What it writes: work_step (update) — Rewrites the step; work_job (update) — Notes what was said

curl -X POST https://app.getera.io/api/v1/work_steps/WORK_STEP_ID/actions/change_step \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"title":"Step"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.step_changed"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workSteps.changeStep("WORK_STEP_ID", {
  title: "Step"
})
era work_steps change_step WORK_STEP_ID \
  --title "Step"
tools/call
{
  "name": "era__work__change_step",
  "arguments": {
    "id": "WORK_STEP_ID",
    "title": "Step"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, step_started, bad_steps · 429 slow down

work.message_step

Tell a working agent something — Sends a message to an agent while it works on your computer ("also do this", "wait, do it like that"); it takes it into account at its next step.

Needs work:write · reaches outside (sends, publishes or charges)

POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/message_step
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.message_step

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Step · id of work_step
textstringyesMessage

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
empty_messageThe message must say something.
step_not_runningOnly a step that is working (or waiting for you mid-run) can be told something.
step_not_talkableOnly an agent running on a computer (a live harness session) can hear a message.

Events it publishes: work.step_changed

What it writes: work_job (update) — Adds the message to the plan’s steering; work_step (update) — Shows the message as the step’s activity

curl -X POST https://app.getera.io/api/v1/work_steps/WORK_STEP_ID/actions/message_step \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"text":"Message"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.step_changed"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workSteps.messageStep("WORK_STEP_ID", {
  text: "Message"
})
era work_steps message_step WORK_STEP_ID \
  --text "Message"
tools/call
{
  "name": "era__work__message_step",
  "arguments": {
    "id": "WORK_STEP_ID",
    "text": "Message"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, empty_message, step_not_running, step_not_talkable · 429 slow down

work.propose_skill

Offer what Era learned — "Era learned a new skill from this job — keep it?": the procedure that worked, waiting for the author. Machine-only.

Needs work:handle · changes data

Run by Era itself (machine-only). Listed so the reference is complete; an API key or a token is refused (403 machine_only).
POSThttps://app.getera.io/api/v1/work_jobs/{id}/actions/propose_skill
API key or OAuth token · work:handle
  • Canonical address: POST /api/v1/actions/work.propose_skill

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Plan · id of work_job
namestringSkill name · max 64
descriptionstringWhat it does · max 600
contentstringSteps · max 20000
whystringLearned from · max 600
nothingbooleanNothing worth keeping

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
not_foundThe plan must exist in this workspace.
not_doneEra learns only from a plan that worked.
already_proposedOne offer per plan.
bad_skillA kebab-case name, a line on what it does and the steps.

Events it publishes: work.skill_proposed

What it writes: work_job (update) — Writes the offer on the plan

Errors: 401 no or expired credential · 403 the credential does not hold work:handle · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 not_found, not_done, already_proposed, bad_skill · 429 slow down

work.record_fork

Record a borrowed computer — The computer worker reports a copy made, running, given back or failed, and its running time. Machine-only.

Needs work:handle · changes data

Run by Era itself (machine-only). Listed so the reference is complete; an API key or a token is refused (403 machine_only).
POSThttps://app.getera.io/api/v1/work_computer_forks/{id}/actions/record_fork
API key or OAuth token · work:handle
  • Canonical address: POST /api/v1/actions/work.record_fork

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Copy · id of work_computer_fork
statestringyesState · forking | running | released | failed · max 20
externalIdstringProvider id · max 200
deviceIdstringRunner · max 200
errorstringError · max 500
addSecondsnumberSeconds it ran · min 0

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
fork_not_foundThe copy must exist in this workspace.
bad_stateThe state must be a fork state.

Events it publishes: work.fork_changed

What it writes: work_computer_fork (update) — Writes the copy’s state and time

Errors: 401 no or expired credential · 403 the credential does not hold work:handle · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 fork_not_found, bad_state · 429 slow down

work.record_shop_order

Record an order Era placed — The shopping step’s report: what was ordered, the total, the card’s last four digits, the order number and — later — where it is. Never a card number. Machine-only.

Needs work:handle · changes data

Run by Era itself (machine-only). Listed so the reference is complete; an API key or a token is refused (403 machine_only).
POSThttps://app.getera.io/api/v1/shop_orders/{id}/actions/record_shop_order
API key or OAuth token · work:handle
  • Canonical address: POST /api/v1/actions/work.record_shop_order

Input

FieldTypeRequiredNotes
iduuidFilled from the path {id} · Order (to update) · id of shop_order
storestringyesStore · max 40
requeststringWhat was asked · max 1000
itemsobject / arrayItems · [{ name, qty, price (kuruş), image, variant }]
totalMinornumberTotal (kuruş) · min 0
deliveryFeeMinornumberDelivery fee (kuruş) · min 0
currencystringCurrency · max 3
statusstringStatus · placed | preparing | on_the_way | delivered | cancelled | unknown · max 20
etastringArrives · max 200
courierstringCourier · max 200
orderNostringOrder number · max 120
trackUrlstringTracking page · max 2000
cardLast4stringCard (last four digits) · Four digits; anything longer is refused. · max 40
addressLabelstringDelivery address · max 300
spacestring (enum)Personal or business · Allowed values: personal, business
jobIduuidPlan · id of work_job
stepIduuidStep · id of work_step
autoApprovedbooleanBought under the limit without asking
expenseIduuidExpense

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
bad_storeThe store must be one Era shops at.
bad_orderAn order has 1–50 named items, whole kuruş amounts and a known status.
card_number_refusedNo card number is ever stored — only the last four digits.
order_not_foundAn update must name one of your own orders.

Events it publishes: work.order_placed, work.order_updated

What it writes: shop_order (update) — Writes the order, or its tracking

Errors: 401 no or expired credential · 403 the credential does not hold work:handle · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 bad_store, bad_order, card_number_refused, order_not_found · 429 slow down

work.record_step

Record a step’s progress — The engine’s report: taken, progress, what it is doing, what it needs, its result. Derives the plan’s status. Machine-only.

Needs work:handle · changes data

Run by Era itself (machine-only). Listed so the reference is complete; an API key or a token is refused (403 machine_only).
POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/record_step
API key or OAuth token · work:handle
  • Canonical address: POST /api/v1/actions/work.record_step

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Step · id of work_step
claimbooleanTake it
statusstringStatus · queued | running | needs_you | done | failed | skipped | stopped · max 20
progressnumberProgress · min 0 · max 100
activitystringDoing now · max 300
needobject / arrayWaits for
executorRefstringExecutor record · max 200
runtimestringRuns on · max 300
resultobject / arrayResult
errorstringError · max 1000
checkpointobject / arrayCheckpoint · Where the executor picks up after a restart: its record, its cursor, the text so far.

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
bad_statusThe status must be a step status.
bad_transitionA finished step does not change; it is retried.
bad_resultA result and a need are objects.
bad_checkpointA checkpoint is an object of at most 40 000 characters.

Events it publishes: work.step_changed, work.needs_you, work.job_finished, work.held

What it writes: work_step (update) — Writes the step’s progress, checkpoint and result; work_job (update) — Holds the plan at its time limit and derives its status from its steps

Errors: 401 no or expired credential · 403 the credential does not hold work:handle · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, bad_status, bad_transition, bad_result, bad_checkpoint · 429 slow down

work.release_fork

Give a borrowed computer back — The step is done with its copy; the computer worker deletes it.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_computer_forks/{id}/actions/release_fork
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.release_fork

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Copy · id of work_computer_fork

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
fork_not_foundThe copy must exist in this workspace.
already_releasedA copy is given back once.

Events it publishes: work.fork_requested

What it writes: work_computer_fork (update) — Marks it to be deleted

curl -X POST https://app.getera.io/api/v1/work_computer_forks/WORK_COMPUTER_FORK_ID/actions/release_fork \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.fork_requested"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workComputerForks.releaseFork("WORK_COMPUTER_FORK_ID")
era work_computer_forks release_fork WORK_COMPUTER_FORK_ID
tools/call
{
  "name": "era__work__release_fork",
  "arguments": {
    "id": "WORK_COMPUTER_FORK_ID"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 fork_not_found, already_released · 429 slow down

work.replan_step

Re-plan a step’s missing input — A step that found none of the input it needs (no rows to export or import) gets one step that produces it, and waits for it. Machine-only.

Needs work:handle · changes data

Run by Era itself (machine-only). Listed so the reference is complete; an API key or a token is refused (403 machine_only).
POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/replan_step
API key or OAuth token · work:handle
  • Canonical address: POST /api/v1/actions/work.replan_step

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Step · id of work_step
titlestringyesNew step · max 200
workerstringyesWorker · max 20
instructionstringWhat to do · max 8000
runobject / arrayHow it runs
reasonstringWhy · max 500

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
not_runningOnly a running step asks for its missing input.
already_replannedA step re-plans its input once; a second miss is a failure.
unknown_workerThe new step names one of the eight workers.
unknown_executorThe new step’s run names an executor Era has.
unknown_credentialA credential step names a credential Era knows how to ask for.
too_many_stepsA plan has at most 12 steps.
bad_stepsThe new step needs a title.

Events it publishes: work.step_changed, work.needs_you, work.job_finished

What it writes: work_step (insert) — Adds the step that produces the missing input; work_step (update) — The consumer waits for it and goes back in line; work_job (update) — Notes the re-plan and derives the plan’s status

Errors: 401 no or expired credential · 403 the credential does not hold work:handle · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, not_running, already_replanned, unknown_worker, unknown_executor, unknown_credential, too_many_steps, bad_steps · 429 slow down

work.request_fork

Borrow a copy of my cloud computer — One forked copy of your own signed-in cloud computer for one step, so parallel workers each get their own machine.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_computer_forks/actions/request_fork
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.request_fork

Input

FieldTypeRequiredNotes
stepIduuidyesStep · id of work_step

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
not_foundThe step’s plan must exist.
not_ownerOnly the plan’s author lends a copy of their own computer.
no_base_computerThe author needs a cloud computer that is running or asleep.
fork_limitAt most the workspace plan’s "at once" number of copies per job.
hours_used_upThe month’s cloud computer hours must not be used up.

Events it publishes: work.fork_requested

What it writes: work_computer_fork (insert) — Asks the computer worker for a copy

curl -X POST https://app.getera.io/api/v1/work_computer_forks/actions/request_fork \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"stepId":"WORK_STEP_ID"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.fork_requested"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workComputerForks.requestFork({
  stepId: "WORK_STEP_ID"
})
era work_computer_forks request_fork \
  --step-id "WORK_STEP_ID"
tools/call
{
  "name": "era__work__request_fork",
  "arguments": {
    "stepId": "WORK_STEP_ID"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, not_found, not_owner, no_base_computer, fork_limit, hours_used_up · 429 slow down

work.requeue_step

Put a step back in line — A step whose process went away goes back in line; the next taker resumes from its checkpoint. Machine-only.

Needs work:handle · changes data

Run by Era itself (machine-only). Listed so the reference is complete; an API key or a token is refused (403 machine_only).
POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/requeue_step
API key or OAuth token · work:handle
  • Canonical address: POST /api/v1/actions/work.requeue_step

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Step · id of work_step
reasonstringWhy · max 300

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
not_runningOnly a running step goes back in line.

Events it publishes: work.step_changed, work.needs_you, work.job_finished

What it writes: work_step (update) — Queues the step, keeping its checkpoint; work_job (update) — Derives the plan’s status

Errors: 401 no or expired credential · 403 the credential does not hold work:handle · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, not_running · 429 slow down

work.resume_job

Resume a plan — Puts a stopped or failed plan’s unfinished steps back in line.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_jobs/{id}/actions/resume_job
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.resume_job

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Plan · id of work_job

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
not_foundThe plan must exist in this workspace.
not_stoppedOnly a stopped or failed plan can be resumed.

Events it publishes: work.job_resumed

What it writes: work_step (update) — Queues the stopped and failed steps again; work_job (update) — Marks the plan running

curl -X POST https://app.getera.io/api/v1/work_jobs/WORK_JOB_ID/actions/resume_job \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.job_resumed"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workJobs.resumeJob("WORK_JOB_ID")
era work_jobs resume_job WORK_JOB_ID
tools/call
{
  "name": "era__work__resume_job",
  "arguments": {
    "id": "WORK_JOB_ID"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 not_found, not_stopped · 429 slow down

work.retry_step

Try a step again — Puts a failed, stopped or skipped step back in line.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/retry_step
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.retry_step

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Step · id of work_step

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
not_failedOnly a failed, stopped or skipped step can be tried again.

Events it publishes: work.step_changed

What it writes: work_step (update) — Queues the step again; work_job (update) — Marks the plan running

curl -X POST https://app.getera.io/api/v1/work_steps/WORK_STEP_ID/actions/retry_step \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.step_changed"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workSteps.retryStep("WORK_STEP_ID")
era work_steps retry_step WORK_STEP_ID
tools/call
{
  "name": "era__work__retry_step",
  "arguments": {
    "id": "WORK_STEP_ID"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, not_failed · 429 slow down

work.review_skill

Decide what Era keeps — Keep it (the workspace’s Eras may use it), keep it private (only yours), correct it, or forget it.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_jobs/{id}/actions/review_skill
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.review_skill

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Plan · id of work_job
decisionstring (enum)yesDecision · Allowed values: keep, private, forget
contentstringCorrected steps · max 20000
skillIdstringSaved skill · max 200

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
not_foundThe plan must exist in this workspace.
no_proposalEra must have offered something from this plan.
already_reviewedOne decision per offer.
not_ownerThe plan’s author decides.
bad_skillA kept skill keeps its steps.

Events it publishes: work.skill_reviewed

What it writes: work_job (update) — Records the decision

curl -X POST https://app.getera.io/api/v1/work_jobs/WORK_JOB_ID/actions/review_skill \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"decision":"keep"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.skill_reviewed"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workJobs.reviewSkill("WORK_JOB_ID", {
  decision: "keep"
})
era work_jobs review_skill WORK_JOB_ID \
  --decision "keep"
tools/call
{
  "name": "era__work__review_skill",
  "arguments": {
    "id": "WORK_JOB_ID",
    "decision": "keep"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 not_found, no_proposal, already_reviewed, not_owner, bad_skill · 429 slow down

work.set_limits

Change a plan’s time limit — How many minutes a plan may run. A plan held at its time limit goes on from where it stopped.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_jobs/{id}/actions/set_limits
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.set_limits

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Plan · id of work_job
maxMinutesnumberTime limit (minutes from the start, empty = no cap)

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
not_foundThe plan must exist in this workspace.
already_finishedA finished plan has no limits to change.
bad_limitsA time limit is 1 minute to a week.
still_overA new time limit must end after now.

Events it publishes: work.limits_changed, work.needs_you, work.job_finished

What it writes: work_job (update) — Writes the time limit; lifts the hold it caused

curl -X POST https://app.getera.io/api/v1/work_jobs/WORK_JOB_ID/actions/set_limits \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"maxMinutes":1}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.limits_changed",
    "work.needs_you",
    "work.job_finished"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workJobs.setLimits("WORK_JOB_ID", {
  maxMinutes: 1
})
era work_jobs set_limits WORK_JOB_ID \
  --max-minutes 1
tools/call
{
  "name": "era__work__set_limits",
  "arguments": {
    "id": "WORK_JOB_ID",
    "maxMinutes": 1
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 not_found, already_finished, bad_limits, still_over · 429 slow down

work.set_shop_rule

Set when Era buys without asking — Purchases up to this amount at this store (or every store) go through without the confirmation card. Empty or 0 = ask every time, which is the default.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/shop_rules/actions/set_shop_rule
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.set_shop_rule

Input

FieldTypeRequiredNotes
storestringyesStore · getir | trendyol | yemeksepeti | hepsiburada | amazon_tr | migros | mock | * (every store) · max 40
askAboveMinornumberBuy without asking up to (kuruş) · Whole kuruş, 0 to 10 000 000 (100 000 TL); 0 or empty = ask every time.
currencystringCurrency · max 3

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
bad_storeThe store must be one Era shops at, or * for every store.
bad_amountThe limit is a whole amount from 1 kuruş to 100 000 TL.

Events it publishes: work.shop_rule_changed

What it writes: shop_rule (update) — Writes or clears the person’s limit for that store

curl -X POST https://app.getera.io/api/v1/shop_rules/actions/set_shop_rule \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"store":"Store"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.shop_rule_changed"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.shopRules.setShopRule({
  store: "Store"
})
era shop_rules set_shop_rule \
  --store "Store"
tools/call
{
  "name": "era__work__set_shop_rule",
  "arguments": {
    "store": "Store"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 bad_store, bad_amount · 429 slow down

work.start_job

Start a plan — Era’s plan for one ask: numbered steps, each for a worker (dev, research, growth, marketing, creative, data, business, computer), run in parallel where nothing waits.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_jobs/actions/start_job
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.start_job

Input

FieldTypeRequiredNotes
titlestringyesName · max 200
goalstringWhat was asked · max 8000
modestring (enum)Started from · Allowed values: chat, background, scheduled
conversationIdstringConversation · max 200
agentRefstringEra · max 200
askFirstbooleanWait for my approval of the plan
nextStepstringSuggested next step · max 300
scopeCtxobject / arrayScope · The wire scope the workers run with (ids only).
stepsobject / arrayyesSteps · [{ title, worker, instruction, run?: { kind, … }, dependsOn?: [earlier step numbers], confirm? }]
deliverablestringDeliver · none (the results) | report (a report as PDF + slides) · max 20
maxMinutesnumberTime limit (minutes)

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
bad_limitsA time limit is 1 minute to a week.
bad_deliverableA plan delivers its results, or a report.
empty_titleA plan needs a name.
no_stepsA plan needs at least one step.
too_many_stepsA plan has at most 12 steps.
bad_stepsEvery step is an object with a title.
unknown_workerEvery step names one of the eight workers.
unknown_executorA step’s run names an executor Era has.
unknown_credentialA credential step names a credential Era knows how to ask for.
bad_dependencyA step can only wait for an earlier step of the same plan.
duplicate_stepA plan does the same work once: no two steps with one title, export format or Sales import.

Events it publishes: work.job_started

What it writes: work_job (insert) — Writes the plan, running or waiting for approval; work_step (insert) — Writes its steps, queued

curl -X POST https://app.getera.io/api/v1/work_jobs/actions/start_job \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"title":"Name","steps":{}}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.job_started"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workJobs.startJob({
  title: "Name",
  steps: {}
})
era work_jobs start_job --data '{"title":"Name","steps":{}}'
tools/call
{
  "name": "era__work__start_job",
  "arguments": {
    "title": "Name",
    "steps": {}
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 bad_limits, bad_deliverable, empty_title, no_steps, too_many_steps, bad_steps, unknown_worker, unknown_executor, unknown_credential, bad_dependency, duplicate_step · 429 slow down

work.stop_job

Stop a plan — "Dur": every step that has not finished stops; what is done stays done.

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_jobs/{id}/actions/stop_job
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.stop_job

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Plan · id of work_job
reasonstringWhy · max 500

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
not_foundThe plan must exist in this workspace.
already_finishedA finished plan cannot be stopped.

Events it publishes: work.job_stopped

What it writes: work_step (update) — Stops every unfinished step; work_job (update) — Marks the plan stopped and notes it

curl -X POST https://app.getera.io/api/v1/work_jobs/WORK_JOB_ID/actions/stop_job \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"reason":"Why"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.job_stopped"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workJobs.stopJob("WORK_JOB_ID", {
  reason: "Why"
})
era work_jobs stop_job WORK_JOB_ID \
  --reason "Why"
tools/call
{
  "name": "era__work__stop_job",
  "arguments": {
    "id": "WORK_JOB_ID",
    "reason": "Why"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 not_found, already_finished · 429 slow down

work.supervise_step

Supervise a running step — The work sweep’s ladder: nudge a quiet step, interrupt and send it again (twice at most), hand it to you when it stays stuck, remind you once about an unanswered approval. Machine-only.

Needs work:handle · changes data

Run by Era itself (machine-only). Listed so the reference is complete; an API key or a token is refused (403 machine_only).
POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/supervise_step
API key or OAuth token · work:handle
  • Canonical address: POST /api/v1/actions/work.supervise_step

Input

FieldTypeRequiredNotes
iduuidyesFilled from the path {id} · Step · id of work_step
opstringyesLadder step · nudge | recover | give_up | remind · max 20
quietMinutesnumberQuiet for (minutes) · min 0
reasonstringWhy · max 300

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
bad_supervisionNudge, recover, give up or remind.
not_runningOnly a running step is nudged, restarted or handed to you.
recoveries_usedA step is restarted at most twice; then it waits for you.
not_waitingOnly a step that waits for you is reminded about.
already_remindedOne reminder per wait.

Events it publishes: work.step_changed, work.needs_you, work.job_finished

What it writes: work_step (update) — Writes the ladder’s state; queues a restarted step (keeping its checkpoint) or hands a stuck one to you; work_job (update) — Derives the plan’s status

Errors: 401 no or expired credential · 403 the credential does not hold work:handle · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, bad_supervision, not_running, recoveries_used, not_waiting, already_reminded · 429 slow down

work.use_result

Use a result — Records that a result card was used or published (the card’s own action runs as you).

Needs work:write · changes data

POSThttps://app.getera.io/api/v1/work_steps/{id}/actions/use_result
API key or OAuth token · work:write
  • Canonical address: POST /api/v1/actions/work.use_result

Input

FieldTypeRequiredNotes
stepIduuidyesFilled from the path {id} · Step · id of work_step
cardnumberyesResult · min 0 · max 50
kindstring (enum)yesWhat · Allowed values: use, publish, approve, open
targetstringWhere · max 200

Preconditions

The action is refused with 409 and one of these codes:

CodeRefused when
step_not_foundThe step must exist in this workspace.
no_such_cardThe result must be one of the step’s cards.

Events it publishes: work.result_used

What it writes: work_step (update) — Marks the card used or live

curl -X POST https://app.getera.io/api/v1/work_steps/WORK_STEP_ID/actions/use_result \
  -H "Authorization: Bearer $ERA_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"card":1,"kind":"use"}'
Response
{
  "ok": true,
  "result": "…",
  "events": [
    "work.result_used"
  ]
}
import { createEra } from "@getera/sdk"

const era = createEra({ apiKey: process.env.ERA_API_KEY })
const res = await era.workSteps.useResult("WORK_STEP_ID", {
  card: 1,
  kind: "use"
})
era work_steps use_result WORK_STEP_ID \
  --card 1 \
  --kind "use"
tools/call
{
  "name": "era__work__use_result",
  "arguments": {
    "stepId": "WORK_STEP_ID",
    "card": 1,
    "kind": "use"
  }
}

Errors: 401 no or expired credential · 403 the credential does not hold work:write · 404 the record or module is outside what it may reach · 422 invalid input (problems[]) · 409 step_not_found, no_such_card · 429 slow down

Data models

ShopOrder

Table shop_order · Resource shop_orders

  • GET /api/v1/shop_orders
  • GET /api/v1/shop_orders/{id}
ColumnTypeNullableAllowed valuesReferences
idstring (uuid) · uuid
organization_idstring (uuid) · uuidorganization
workspace_idstring (uuid) · uuidworkspace
user_idstring (uuid) · uuidapp_user
storestring · text
requeststring · text
itemsobject · jsonb
total_minorstring (int64) · int8yes
delivery_fee_minorstring (int64) · int8yes
currencystring · text
statusstring · textplaced, preparing, on_the_way, delivered, cancelled, unknown
status_atstring (date-time) · timestamptz
etastring · textyes
courierstring · textyes
order_nostring · textyes
track_urlstring · textyes
card_last4string · textyes
address_labelstring · textyes
spacestring · textpersonal, business
expense_idstring (uuid) · uuidyes
job_idstring (uuid) · uuidyeswork_job
step_idstring (uuid) · uuidyeswork_step
auto_approvedboolean · bool
visibilitystring · textprivate, workspace
placed_atstring (date-time) · timestamptz
created_atstring (date-time) · timestamptz
updated_atstring (date-time) · timestamptz

Primary key: id

Checks:

  • CHECK (((address_label IS NULL) OR (length(address_label) <= 300)))
  • CHECK (((card_last4 IS NULL) OR (card_last4 ~ '^[0-9]{4}$'::text)))
  • CHECK (((courier IS NULL) OR (length(courier) <= 200)))
  • CHECK ((currency ~ '^[A-Z]{3}$'::text))
  • CHECK (((delivery_fee_minor IS NULL) OR (delivery_fee_minor >= 0)))
  • CHECK (((eta IS NULL) OR (length(eta) <= 200)))
  • CHECK ((jsonb_typeof(items) = 'array'::text))
  • CHECK (((order_no IS NULL) OR (length(order_no) <= 120)))
  • CHECK ((length(request) <= 1000))
  • CHECK ((store ~ '^[a-z_]{2,40}$'::text))
  • CHECK (((total_minor IS NULL) OR (total_minor >= 0)))
  • CHECK (((track_url IS NULL) OR (length(track_url) <= 2000)))

ShopRule

Table shop_rule · Resource shop_rules

  • GET /api/v1/shop_rules
  • GET /api/v1/shop_rules/{id}
ColumnTypeNullableAllowed valuesReferences
idstring (uuid) · uuid
organization_idstring (uuid) · uuidorganization
workspace_idstring (uuid) · uuidworkspace
user_idstring (uuid) · uuidapp_user
storestring · text
ask_above_minorstring (int64) · int8
currencystring · text
visibilitystring · textprivate, workspace
created_atstring (date-time) · timestamptz
updated_atstring (date-time) · timestamptz

Primary key: id

Unique: workspace_id, user_id, store

Checks:

  • CHECK (((ask_above_minor > 0) AND (ask_above_minor <= 10000000)))
  • CHECK ((currency ~ '^[A-Z]{3}$'::text))
  • CHECK ((store ~ '^(\*\|[a-z_]{2,40})$'::text))

WorkComputerFork

Table work_computer_fork · Resource work_computer_forks

  • GET /api/v1/work_computer_forks
  • GET /api/v1/work_computer_forks/{id}
ColumnTypeNullableAllowed valuesReferences
idstring (uuid) · uuid
organization_idstring (uuid) · uuidorganization
workspace_idstring (uuid) · uuidworkspace
job_idstring (uuid) · uuidwork_job
step_idstring (uuid) · uuidwork_step
owner_user_idstring (uuid) · uuidapp_user
base_machine_idstring (uuid) · uuidcomputer_machine
providerstring · text
external_idstring · textyes
device_idstring · textyes
statestring · textrequested, forking, running, releasing, released, failed
errorstring · textyes
seconds_usedstring (int64) · int8
started_atstring (date-time) · timestamptzyes
released_atstring (date-time) · timestamptzyes
created_atstring (date-time) · timestamptz
updated_atstring (date-time) · timestamptz

Primary key: id

Checks:

  • CHECK (((device_id IS NULL) OR (length(device_id) <= 200)))
  • CHECK (((error IS NULL) OR (length(error) <= 500)))
  • CHECK (((external_id IS NULL) OR (length(external_id) <= 200)))
  • CHECK ((seconds_used >= 0))

WorkJob

Table work_job · Resource work_jobs

  • GET /api/v1/work_jobs
  • GET /api/v1/work_jobs/{id}
ColumnTypeNullableAllowed valuesReferences
idstring (uuid) · uuid
organization_idstring (uuid) · uuidorganization
workspace_idstring (uuid) · uuidworkspace
titlestring · text
goalstring · text
statusstring · textproposed, running, needs_you, done, failed, stopped
modestring · textchat, background, scheduled
conversation_idstring · textyes
agent_refstring · textyes
ask_firstboolean · bool
plan_approved_atstring (date-time) · timestamptzyes
next_stepstring · textyes
steeringobject · jsonb
scope_ctxobject · jsonb
summarystring · textyes
created_bystring (uuid) · uuidapp_user
created_atstring (date-time) · timestamptz
updated_atstring (date-time) · timestamptz
finished_atstring (date-time) · timestamptzyes
deliverablestring · textnone, report
max_minutesinteger · int4yes
deadline_atstring (date-time) · timestamptzyes
holdobject · jsonbyes
learnedobject · jsonbyes
assignee_user_idstring (uuid) · uuidyesapp_user
visibilitystring · textprivate, workspace

Primary key: id

Checks:

  • CHECK ((length(goal) <= 8000))
  • CHECK (((hold IS NULL) OR ((jsonb_typeof(hold) = 'object'::text) AND (hold ? 'kind'::text))))
  • CHECK (((learned IS NULL) OR ((jsonb_typeof(learned) = 'object'::text) AND (learned ? 'status'::text))))
  • CHECK (((max_minutes IS NULL) OR ((max_minutes >= 1) AND (max_minutes <= 10080))))
  • CHECK (((next_step IS NULL) OR (length(next_step) <= 300)))
  • CHECK ((jsonb_typeof(scope_ctx) = 'object'::text))
  • CHECK ((jsonb_typeof(steering) = 'array'::text))
  • CHECK (((summary IS NULL) OR (length(summary) <= 4000)))
  • CHECK (((length(btrim(title)) >= 1) AND (length(btrim(title)) <= 200)))

WorkStep

Table work_step · Resource work_steps

  • GET /api/v1/work_steps
  • GET /api/v1/work_steps/{id}
ColumnTypeNullableAllowed valuesReferences
idstring (uuid) · uuid
organization_idstring (uuid) · uuidorganization
workspace_idstring (uuid) · uuidworkspace
job_idstring (uuid) · uuidwork_job
positioninteger · int4
titlestring · text
instructionstring · text
workerstring · textdev, research, growth, marketing, creative, data, business, computer
runobject · jsonb
depends_onstring[] · uuid[]
confirmboolean · bool
statusstring · textqueued, running, needs_you, done, failed, skipped, stopped
progressinteger · int4
activitystring · textyes
needobject · jsonbyes
executor_refstring · textyes
runtimestring · textyes
resultobject · jsonb
errorstring · textyes
started_atstring (date-time) · timestamptzyes
finished_atstring (date-time) · timestamptzyes
heartbeat_atstring (date-time) · timestamptzyes
created_atstring (date-time) · timestamptz
updated_atstring (date-time) · timestamptz
checkpointobject · jsonbyes
checkpoint_atstring (date-time) · timestamptzyes
attemptsinteger · int4
supervisionobject · jsonbyes

Primary key: id

Checks:

  • CHECK (((activity IS NULL) OR (length(activity) <= 300)))
  • CHECK (((attempts >= 0) AND (attempts <= 1000)))
  • CHECK (((checkpoint IS NULL) OR (jsonb_typeof(checkpoint) = 'object'::text)))
  • CHECK (((error IS NULL) OR (length(error) <= 1000)))
  • CHECK (((executor_ref IS NULL) OR (length(executor_ref) <= 200)))
  • CHECK ((length(instruction) <= 8000))
  • CHECK (((need IS NULL) OR (jsonb_typeof(need) = 'object'::text)))
  • CHECK ((("position" >= 1) AND ("position" <= 50)))
  • CHECK (((progress >= 0) AND (progress <= 100)))
  • CHECK ((jsonb_typeof(result) = 'object'::text))
  • CHECK (((jsonb_typeof(run) = 'object'::text) AND (run ? 'kind'::text)))
  • CHECK (((runtime IS NULL) OR (length(runtime) <= 300)))
  • CHECK (((supervision IS NULL) OR (jsonb_typeof(supervision) = 'object'::text)))
  • CHECK (((length(btrim(title)) >= 1) AND (length(btrim(title)) <= 200)))

Events

Workflows and webhooks react to these events.

EventWhat happensPayload
work.fork_changedA borrowed cloud computer was made, started, given back or failed.id, state, jobId, stepId
work.fork_requestedA step asked for (or gave back) a copy of its author’s cloud computer.id, op, jobId, stepId
work.heldA plan reached its time limit and waits for the person.id, title, kind, steps
work.job_assignedA plan was given to a person or back to Era, or who sees it changed.id, title, assigneeUserId, visibility, link, recipientUserId
work.job_finishedA plan finished (done, failed or stopped).id, title, status, message, link, recipientUserId
work.job_resumedA stopped plan was resumed.id, title, steps
work.job_startedEra started a plan (or proposed one for approval).id, title, steps, status, recipientUserId
work.job_stoppedSomebody stopped a plan.id, title
work.limits_changedA plan’s time limit changed.id, maxMinutes, resumed
work.needs_youA plan waits for you — an approval, a credential, a computer, or more time.id, title, message, link, recipientUserId
work.order_placedEra placed an order in the person’s store account.id, store, title, total, currency, status, eta, recipientUserId
work.order_updatedAn order Era placed moved on (preparing, on the way, delivered).id, store, status, eta, recipientUserId
work.plan_approvedA plan was approved; its workers start.id, title
work.result_usedA result card was used or published.id, jobId, card, kind, target
work.shop_rule_changedSomebody changed when Era buys without asking.store, askAboveMinor
work.skill_proposedEra learned a procedure from a plan that worked and asks whether to keep it.id, title, name, message, link, recipientUserId
work.skill_reviewedThe author kept, kept private or forgot what Era learned.id, decision, skillId
work.step_changedA step was taken, finished, added, changed or answered.id, jobId, status
Was this page helpful?