Last active
November 29, 2021 21:27
-
-
Save georanma/fb396cd84ee614325454160d55ba0389 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use Carbon\Carbon; | |
// $start = Carbon::now()->subDays(30); | |
// $end = Carbon::now()->subDays(15); | |
$start = Carbon::createFromFormat('m-d-Y', '11-10-2021'); | |
$end = Carbon::createFromFormat('m-d-Y', '11-19-2021'); | |
$period = CarbonPeriod::since($start)->until($end); | |
$accounts = [1896639012498548, 1985512714220476, 3189634405969789, 4276831373018237]; | |
foreach ($accounts as $account) { | |
foreach ($period as $date) { | |
$current = $date->format('m-d-Y'); | |
Artisan::call("amazon-ads:get-sponsored-brands-report {$current} {$account} --fifteen-days-back"); | |
echo $current . "done \n"; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment