Docs
Automations

Automation Billing and Metering

How automation runs meter usage, what happens when a billing block signal suspends a run, and how Bring Your Own Key (BYOK) affects cost attribution during automation execution.

Automation runs in MarkDocket are billable activities. Every run is metered in real time, and if your account cannot cover the cost of a pending step, the run is suspended — not silently failed — giving you a chance to resolve the billing issue and continue.

How usage is metered during a run

Each automation run executes as a durable function where every graph node runs as its own checkpointed step. Usage events are recorded as each node completes — not speculatively before work is done.

MarkDocket uses two distinct categories of usage event:

  • Product usage — records the feature, unit, and quantity consumed (for example, a trademark search, a watch report, or an agent node turn). This is what appears on your usage dashboard and determines your charges.
  • Direct COGS — records the cost of AI provider calls made on your behalf by the MarkDocket platform. These events are emitted only for calls the platform makes directly and are never double-counted against calls you route through BYOK.

Usage events are written to a durable outbox before they are sent to the billing system. This means a usage event is never lost due to a process restart or transient network issue — the outbox is retried automatically with backoff until the event is confirmed delivered.

Billing blocks and suspended runs

If a billing check determines that a required action cannot proceed — for example, your account balance is insufficient or a payment method needs attention — the automation run receives an AutomationBillingBlockSignal.

When this signal is raised:

  • The run is suspended with status billing_blocked rather than marked as failed.
  • No further nodes in the run execute.
  • The run record is preserved so it can be resumed or reviewed once the billing issue is resolved.
  • The specific reason for the block is surfaced in the run detail view, along with the required action (for example, adding a payment method or confirming account status).

Suspended runs are not failed runs

A billing-blocked run retains its execution state. Once the underlying billing issue is resolved, contact support or retry the run from the Automations dashboard. Steps that already completed before the block are not re-executed.

Resolving a billing block

  1. Navigate to Automations and open the run that shows a billing-blocked status.
  2. Review the reason shown in the run detail — this will indicate whether you need to add a payment method, confirm your billing account, or take another specific action.
  3. Resolve the issue from Settings → Billing.
  4. Return to the blocked run and use the retry or resume action.

Billing block reasons map one-to-one with a required action. The platform will not resume a run until the action matching the block reason has been completed.

Concurrency and fairness

Each user account is limited to 2 simultaneous automation runs at any time. Runs beyond this limit are queued and start automatically as capacity becomes available. This limit applies regardless of billing status.

BYOK and cost attribution

Bring Your Own Key (BYOK) lets you supply your own AI provider credentials so that AI provider costs are billed directly to your own account with the provider rather than through MarkDocket.

BYOK applies to agent nodes in automation runs only

BYOK credentials are used exclusively for agent nodes within automation runs. Interactive agent chat, draft research workflows, and all other platform features always use the MarkDocket-managed AI gateway.

When an automation run uses BYOK for an agent node:

  • No AI provider COGS event is emitted by MarkDocket for that node's LLM calls. The provider cost is between you and your AI provider.
  • Product usage is still metered normally. The automation run itself, the tools invoked, and any data operations performed are still recorded as product usage and count toward your MarkDocket plan.
  • BYOK does not bypass or reduce product-usage billing — it only changes who pays for the underlying AI provider tokens.

What BYOK does not affect

MetricAffected by BYOK?
Automation run product usageNo — always metered
Tool calls (trademark search, patent lookup, etc.)No — always metered
AI provider token costYes — billed to your provider account
MarkDocket AI gateway COGSYes — not charged when BYOK is active for that node
Billing block behaviorNo — blocks still apply
Run concurrency limitNo — still capped at 2 simultaneous runs

Async catalog actions and long-running steps

Some automation nodes trigger long-running catalog actions (for example, a full trademark watch report). These steps enqueue a background job and then wait for a terminal event with a maximum timeout of 2 hours. Usage for these steps is recorded when the job completes, not when it is enqueued.

If a catalog job does not complete within 2 hours, the step times out and the run is marked as failed for that node. Completed steps before the timeout are not re-run.

Viewing usage from automation runs

Usage generated by automation runs appears alongside all other usage on your Settings → Billing → Usage page. Individual run details in the Automations dashboard show per-step outcomes, which you can use to understand which nodes consumed usage within a given run.

On this page