workspace versions
workspace versions requests Workflow Server to return a list of remote versions of the specified workflow. It is often used to confirm the latest point, release results and version online status.
Command Format
pnpm exec workflow-code workspace versions <workflow>
Parameter
| Parameter | Description |
|---|---|
<workflow> | The remote workflow name. |
API
| Steps | Endpoint |
|---|---|
| Query Version | GET /api/workflows/{workflow}/versions |
Output
| Situation | Output |
|---|---|
| Query succeeds | Server versions API JSON. |
| workflow does not exist | The server returned an error JSON, with exit code 1. |
| Not logged in | Output error message with exit code 1. |
Example
pnpm exec workflow-code workspace versions hello
Common uses
| Scene | Description |
|---|---|
| Confirmation after release | Check whether a new version is generated. |
| Run the specified version | Copy the version number from the version of status: "online" to run --target. |
| Download the specified version | Copy the version number from the list to download --target. |
Version Status
Each version returned contains the status, activation, online, runnable, and latest fields. preparing indicates that the release process is preparing dependencies and runtime, and latest will not be switched for the time being;online can be run, Embed or Webhook can be accessed;offline still retains the database and object storage backup, but the running entry will deny access. The management terminal can re-launch the offline version, and the version that is manually launched will not be automatically offline by the default "last three automatic online versions" policy.