jaizendra-netizen / campaign-roi-report
PHP CLI and library: spend against revenue per campaign from a CSV, with ROI, ROAS and a verdict against the ROAS target you set.
Package info
github.com/jaizendra-netizen/campaign-roi-report
Type:project
pkg:composer/jaizendra-netizen/campaign-roi-report
Requires
- php: >=8.1
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is not auto-updated.
Last update: 2026-11-29 19:33:45 UTC
README
PHP command line tool and library. Give it a CSV of campaigns with spend and revenue and it prints ROI and ROAS for each one (repeated campaign rows are added together) and a verdict against the ROAS target you choose: on target, below target, losing money or no spend.
Part of the OneGTMLab free GTM tools. Background on the idea: paid media.
Install
composer require jaizendra-netizen/campaign-roi-report
Use
CSV columns: campaign, spend, revenue. The default target ROAS is 3.0; change it with --target-roas.
$ php bin/campaign-roi sample.csv
campaign spend revenue ROI ROAS verdict
LinkedIn ads Q4 12000 30000 150% 2.50x below target
Webinar series 4000 5200 30% 1.30x below target
Retargeting 4000 2700 -32% 0.68x losing money
Podcast sponsor 5000 0 -100% 0.00x losing money
ALL 25000 37900 52% 1.52x target ROAS 3.0x
Test
php tests/run.php
Offline, no network calls, no dependencies beyond the language runtime. MIT licensed.