Skip to main content
Tasks are declared in config/tasks.yml. Each task records its accepted input extensions, the binary it requires, the handler used to run it, the output directory, and the output filename template.

Import

convert-fdx-to-screenjson

Converts Final Draft (.fdx) to ScreenJSON.
FieldValue
Accepts.fdx
Requires/usr/local/bin/screenjson
Handlergreenlight.convert (format: fdx)
Output dirjson
Output{stem}.json

convert-fountain-to-screenjson

Converts Fountain (.fountain) plain-text screenplay to ScreenJSON.
FieldValue
Accepts.fountain
Requiresscreenjson
Handlergreenlight.convert (format: fountain)
Output dirjson
Output{stem}.json

convert-fadein-to-screenjson

Converts FadeIn Pro (.fadein) to ScreenJSON.
FieldValue
Accepts.fadein
Requiresscreenjson
Handlergreenlight.convert (format: fadein)
Output dirjson
Output{stem}.json

convert-pdf-to-screenjson

Extracts screenplay structure from a PDF via Poppler and converts to ScreenJSON. Best-effort for scanned / image PDFs.
FieldValue
Accepts.pdf
Requiresscreenjson, pdftohtml
Handlergreenlight.convert (format: pdf)
Output dirjson
Output{stem}.json

Export

export-to-fdx

FieldValue
Accepts.json, .yaml, .yml
Handlergreenlight.export (format: fdx)
Output dirfdx
Output{stem}.fdx

export-to-fountain

FieldValue
Accepts.json, .yaml, .yml
Handlergreenlight.export (format: fountain)
Output dirfountain
Output{stem}.fountain

export-to-fadein

FieldValue
Accepts.json, .yaml, .yml
Handlergreenlight.export (format: fadein)
Output dirfadein
Output{stem}.fadein

export-to-pdf

Renders the document as a screenplay PDF using the native encoder.
FieldValue
Accepts.json, .yaml, .yml
Handlergreenlight.export (format: pdf, paper_size: letter, font: courier)
Output dirpdf
Output{stem}.pdf

Validation

validate-screenjson

Schema-checks a document and emits a JSON report.
FieldValue
Accepts.json
Handlergreenlight.validate
Output dirvalidation
Output{stem}_validation.json

Encryption

encrypt-screenjson

AES-256 encrypts every text run. Requires an encrypt_key job variable.
FieldValue
Accepts.json
Handlergreenlight.encrypt
Output direncrypted
Output{stem}_encrypted.json
Required varsencrypt_key

decrypt-screenjson

Decrypts. Requires the same encrypt_key used to encrypt.
FieldValue
Accepts.json
Handlergreenlight.decrypt
Output dirdecrypted
Output{stem}_decrypted.json
Required varsencrypt_key

Packaging

zip-output

ZIPs the entire output directory.
FieldValue
Acceptsany
Requires/usr/bin/zip
Handlercli
Commandcd {output_dir} && zip -r package.zip . -x package.zip
Outputpackage.zip

Adding tasks

config/tasks.yml is loaded on boot. New entries follow this schema:
- name: my-task
  description: Short label
  human: Longer explanation shown in the UI
  icon: mdi:something
  accept: [.json]
  requires:
    - { type: binary, path: /usr/local/bin/screenjson, name: screenjson }
  handler: greenlight.convert  # or cli
  output_dir: output
  params: { format: fdx }
  job_vars: [optional_var_names]
  cmd: "shell command (only when handler is cli)"
  output:
    - "{stem}.ext"
Restart the service to pick up changes.