Tool

Job status

Technical name: job_stato

Model › Open models

Reads

Tells how far a long job started by your AI has got, such as opening a model or a team action waiting for your approval, and returns its result.

What it does

Follows a job: a long operation your AI started without waiting for it, such as opening a model with Open a model or a team action waiting for your approval in Revit.

For each job it returns:

  • the state: queued, running, completed, failed, canceled;
  • the progress: the stage and percentage reported by Revit, the available memory, a Revit dialog waiting for your answer;
  • the seconds elapsed;
  • at the end, the result, the error or the reason for the cancellation;
  • for team actions, the state of the approval: pending, approved, executed or failed, or else denied or canceled.

It answers at once even while Revit is busy (for example while it opens a large model). It changes nothing.

How it works

  1. Your AI calls the tool with the job's id, given by the tool that started it. Without an id it uses the only running job; if there is not exactly one, it lists this Revit's latest jobs.
  2. BIMit waits, up to the time given (30 seconds by default, at most 120), for the job to change state or finish, then answers with the updated state.
  3. Your AI calls the tool again until the job is finished and reports the outcome; if Revit shows a dialog or waits for your approval, it tells you so you can answer in Revit.

Example requests

  • "How far along is the model opening?"
  • "Wait for the model to finish opening, then tell me how many worksets it has."
  • "I approved the synchronization in Revit: did it go through?"

What changes and how to undo

Nothing: the tool only reads the state of jobs and touches neither the model nor any file. There is nothing to undo.

To stop a queued or running job, use Cancel the job.

Limits

  • It sees only this Revit's jobs: finished jobs remain available for at least an hour; a job of a Revit that was closed is gone.
  • One call waits at most 120 seconds.

Parameters

ParameterMeaning
idThe job's id (e.g. "j1-9c1e"), given by the tool that started it. Without an id: the only running job, otherwise the list of the latest jobs.
attesa_sMaximum seconds to wait for a change of state (0-120, default 30).

Related tools

All tools