{"id":21377861,"url":"https://github.com/eltorocorp/eltoro-stats-to-csv","last_synced_at":"2025-10-03T22:30:22.630Z","repository":{"id":115139774,"uuid":"68944019","full_name":"eltorocorp/eltoro-stats-to-csv","owner":"eltorocorp","description":"A helper/example script to consume the El Toro API for Stats","archived":false,"fork":false,"pushed_at":"2017-11-30T16:12:38.000Z","size":34,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":47,"default_branch":"master","last_synced_at":"2024-11-22T09:28:23.644Z","etag":null,"topics":["analyticsmlteam","csv","portal","reporting","stats"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eltorocorp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-09-22T17:12:10.000Z","updated_at":"2017-12-26T15:40:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"59d9cf54-c8cd-4984-8810-f712a1e611b3","html_url":"https://github.com/eltorocorp/eltoro-stats-to-csv","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltorocorp%2Feltoro-stats-to-csv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltorocorp%2Feltoro-stats-to-csv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltorocorp%2Feltoro-stats-to-csv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltorocorp%2Feltoro-stats-to-csv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eltorocorp","download_url":"https://codeload.github.com/eltorocorp/eltoro-stats-to-csv/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235193143,"owners_count":18950464,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["analyticsmlteam","csv","portal","reporting","stats"],"created_at":"2024-11-22T09:24:01.983Z","updated_at":"2025-10-03T22:30:22.295Z","avatar_url":"https://github.com/eltorocorp.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# stats-to-csv\n\n## Overview\n\nProduces a csv summary of click and impression stats from the Eltoro Portal for Stats for running campaigns.\nThis is only functional if you are a customer of Eltoro, and wanting daily\ndumps of stats in CSV format, but it should give you a base to work with for\nany reporting functional desired from our portal.\n\n## Usage\n\n```\npython stats2csv \u003cusername\u003e \u003cpassword\u003e \u003cstart\u003e \u003cend\u003e \u003ctime_frame (default: \"hour\")\u003e\n```\n\nstart and end should be provided in the `%Y-%m-%d` or `%Y-%m-%d %H:%M:%S` format\n\nIf the dates or time_frame is left off, it defaults to yesterday's date with\ntime_frame of hour.\n\n\n### Example\n\n```\npython stats2csv myusername mypassword 2016-01-01 2016-01-31 day\n```\n\n### Scheduling Usage\n\nScheduling this task to be run as a daily `cron` would be quite simple,\njust make sure it is run with *yesterday's* date range, since *today* would not be complete.\n\n## Windows Usage\n\nRun the included windows bat script as a scheduled task.  Be sure to edit the\nlast lines and add your username/password, and make sure the server has python\ninstalled - link is in the batch script.\n\n## Initial Setup\n\nThe first time you set this up on **windows**, you need to run the `setup.bat` script.\n\nThis will install the requests module for python.\n\nIn a **linux or OSX** environment, you need to also have the requests module.\n\nJust run `sudo pip install requests` in addition to python2.x installed.\n\n## Extending / Next Steps\n\n* You could setup this script as a cron or scheduled task\n* You could automatically FTP or POST or import the CSV within your network\n* If you do not want to build a CSV from your stats, just use the API response directly *(an array of objects)*\n* You can query for a single `campaignId`, `orderLineId`, or `creativeId` and get more specific stats\n* If you are doing more than quering stats, use this as a basic guide for API interactions and build your own tool\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feltorocorp%2Feltoro-stats-to-csv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feltorocorp%2Feltoro-stats-to-csv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feltorocorp%2Feltoro-stats-to-csv/lists"}