PHPackages                             juststeveking/workflow - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. juststeveking/workflow

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

juststeveking/workflow
======================

This package is aimed to be a simplistic PHP workflow package that works in a similar fashion to GitHub Actions.

0.0.1(4y ago)421MITPHPPHP ^8.0

Since Dec 2Pushed 4y ago2 watchersCompare

[ Source](https://github.com/JustSteveKing/workflow)[ Packagist](https://packagist.org/packages/juststeveking/workflow)[ RSS](/packages/juststeveking-workflow/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (6)Versions (2)Used By (0)

Workflow
========

[](#workflow)

[![Tests](https://github.com/JustSteveKing/workflow/actions/workflows/test.yml/badge.svg?branch=main)](https://github.com/JustSteveKing/workflow/actions/workflows/test.yml)

This package is aimed to be a simplistic PHP workflow package that works in a similar fashion to GitHub Actions.

Installation
------------

[](#installation)

To install this package, use the following composer command:

```
composer require juststeveking/workflow
```

Usage
-----

[](#usage)

To create a new Workflow Runner, all you need to do is build it. It will take an optional array of Workflows for you to pass in, or you can allow it to default to empty to programatically build it yourself.

### Building a Workflow Runner without Workflows

[](#building-a-workflow-runner-without-workflows)

```
use JustSteveKing\Workflow\WorkflowRunner;

$runner = WorkflowRunner::build();
```

### Building a Workflow Runner with a Workflow

[](#building-a-workflow-runner-with-a-workflow)

```
use JustSteveKing\Workflow\WorkflowRunner;

$runner = WorkflowRunner::build(
    workflows: [
        WorkflowBuilder::make(
            payload: JsonLoader::load(__DIR__ . '/path/to/workflow.json')
        )
    ]
);
```

Building a Workflow
-------------------

[](#building-a-workflow)

To build a workflow you can use either a `YAML` file or a `JSON` file:

### Example YAML Workflow File

[](#example-yaml-workflow-file)

```
name: 'test'

jobs:
  test:
    run:
      target: JustSteveKing\Workflow\Stubs\Test
      method: run
      args:
        - 'test'
        - 10
        - true

  another:
    run:
      target: JustSteveKing\Workflow\Stubs\Test
      method: another
      args:
        - 'test'
```

### Example JSON Workflow File

[](#example-json-workflow-file)

```
{
  "name": "test",
  "jobs": {
    "test": {
      "run": {
        "target": "JustSteveKing\\Workflow\\Stubs\\Test",
        "method": "run",
        "args": [
          "test",
          10,
          true
        ]
      }
    },
    "another": {
      "run": {
        "target": "JustSteveKing\\Workflow\\Stubs\\Test",
        "method": "another",
        "args": [
          "test"
        ]
      }
    }
  }
}
```

You can pass these files into a WorkflowBuilder using the following approaches:

### JSON Workflow

[](#json-workflow)

```
use JustSteveKing\Workflow\WorkflowBuilder;
use JustSteveKing\Workflow\Loaders\JsonLoader;

$workflow = WorkflowBuilder::make(
    payload: JsonLoader::load(__DIR__ . '/path/to/workflow.json')
);
```

### YAML Workflow

[](#yaml-workflow)

```
use JustSteveKing\Workflow\WorkflowBuilder;
use JustSteveKing\Workflow\Loaders\YamlLoader;

$workflow = WorkflowBuilder::make(
    payload: YamlLoader::load(__DIR__ . '/path/to/workflow.yaml')
);
```

Running a workflow
------------------

[](#running-a-workflow)

Once you have built up your Workflow runner - all you need to do is run it:

```
use JustSteveKing\Workflow\WorkflowRunner;

$runner = WorkflowRunner::build(
    workflows: [
        WorkflowBuilder::make(
            payload: JsonLoader::load(__DIR__ . '/path/to/workflow.json')
        )
    ]
);

$runner->run();
```

Each Job for each workflow anythings returned will be added to an internal log on the runner allowing you to check that they ran. This can be accessed using:

```
$runner->logs();
```

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1623d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/a87fe82b349821ebd49cf57d65c4cd3e33ae0833222a8438d90fe8921ca899ea?d=identicon)[JustSteveKing](/maintainers/JustSteveKing)

---

Top Contributors

[![JustSteveKing](https://avatars.githubusercontent.com/u/6368379?v=4)](https://github.com/JustSteveKing "JustSteveKing (15 commits)")

###  Code Quality

TestsPest

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/juststeveking-workflow/health.svg)

```
[![Health](https://phpackages.com/badges/juststeveking-workflow/health.svg)](https://phpackages.com/packages/juststeveking-workflow)
```

###  Alternatives

[pocketmine/pocketmine-mp

A server software for Minecraft: Bedrock Edition written in PHP

3.5k74.6k86](/packages/pocketmine-pocketmine-mp)[ldaptools/ldaptools

LdapTools is a feature-rich LDAP library for PHP 5.6+.

204263.9k1](/packages/ldaptools-ldaptools)[netgen/layouts-core

Netgen Layouts enables you to build and manage complex web pages in a simpler way and with less coding. This is the core of Netgen Layouts, its heart and soul.

3689.4k10](/packages/netgen-layouts-core)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
