workflow

class afwf.alfred.workflow.AlfredWorkflow(dir_workflow: Path)[source]

Represents a single Alfred Workflow directory.

The directory is typically located at:

<Alfred.alfredpreferences>/workflows/user.workflow.<UUID>/

and is expected to contain:

  • info.plist — workflow definition (name, version, bundle id, …)

  • icon.png — workflow icon

  • main.py — Python entry point (for afwf-based workflows)

  • lib/ — installed Python dependencies

All attributes are lazily evaluated and cached on first access.

Parameters:

dir_workflow – Path to the workflow folder, e.g. …/workflows/user.workflow.76458317-….

property workflow_id: str

UUID extracted from the folder name (user.workflow.<UUID>).

property path_info_plist: Path

info.plist workflow definition file.

property path_icon_png: Path

icon.png workflow icon.

property name: str

Human-readable workflow name (name key in info.plist).

property bundle_id: str

Reverse-DNS bundle identifier (bundleid key in info.plist), e.g. "MacHu-GWU.afwf_fts_anything".

property version: str

Workflow version string (version key in info.plist).

property description: str

Short description (description key in info.plist).

property created_by: str

Author name (createdby key in info.plist).

property web_address: str

Homepage / repo URL (webaddress key in info.plist).

property readme: str

Full readme text (readme key in info.plist).

property disabled: bool

Whether the workflow is currently disabled in Alfred.