{"id":20372649,"url":"https://github.com/txchen/brightday-dl","last_synced_at":"2026-04-22T03:33:49.844Z","repository":{"id":72708604,"uuid":"83017102","full_name":"txchen/brightday-dl","owner":"txchen","description":"To backup the pictures from my bright day app","archived":false,"fork":false,"pushed_at":"2017-07-17T17:46:58.000Z","size":6,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-09T15:22:35.531Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/txchen.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":"2017-02-24T08:04:31.000Z","updated_at":"2020-12-11T19:25:39.000Z","dependencies_parsed_at":"2023-03-03T00:45:36.864Z","dependency_job_id":null,"html_url":"https://github.com/txchen/brightday-dl","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/txchen/brightday-dl","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/txchen%2Fbrightday-dl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/txchen%2Fbrightday-dl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/txchen%2Fbrightday-dl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/txchen%2Fbrightday-dl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/txchen","download_url":"https://codeload.github.com/txchen/brightday-dl/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/txchen%2Fbrightday-dl/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32119980,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-22T00:31:26.853Z","status":"online","status_checked_at":"2026-04-22T02:00:05.693Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-11-15T01:14:14.328Z","updated_at":"2026-04-22T03:33:49.818Z","avatar_url":"https://github.com/txchen.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## My bright day downloader\n\nTo backup the pictures from my bright day app.\n\nYou can now download the pics from their app, but the jpg has not correct exif time info, so putting them into your gallery will be a mess.\n\nThis tool will help you to download the pictures and set the correct exif for you.\n\n### Usage\n\nStep 1) fetch events\n\n`node fetchevents.js magiccookie`\n\nStep 2) download photos and videos\n\n`node downloadpic.js magiccookie`\n\nStep 3) modify the exif info\n\n`node modifyexif.js`\n\nStep 4) copy the files and upload to somewhere\n\n`cp data/**/*-mod.jpg finaldata \u0026\u0026 cp data/**/*.MOV finaldata`\n\n### App protocol\n\n#### Login\n\n`http -f POST https://familyinfocenter.brighthorizons.com/mybrightday/login 'username=xxx@yyy.com' 'password=secret' response=jwt`\n\nIf success, response body will be the jwt token. Then validate it.\n\n`http -f POST https://www.tadpoles.com/auth/jwt/validate 'token=THELONGTOKEN'`\n\nIf okay, the response will return a cookie, record it. Next, we need to admit something?\n\n`http -f POST https://www.tadpoles.com/remote/v1/athome/admit 'cookie:COOKIE_IN_LAST_STEP' available_memory=16298568 uses_dst=true 'utc_offset=-08:00' 'tz=America Los_Angeles' logged_in=false 'mac=00:00:00:00:00:00' locale=en-US state=client v=2 battery_level=-1 app_version=7.2.7 platform_version=5.1.1 device_id=GUID ostype=32bit os_name=android model=SM-G920I`\n\nThis call will set another cookie in response, let's say cookie_2\n\nThen register with this cookie.\n\n`http -f POST https://www.tadpoles.com/remote/v1/push/register 'registration=URL_ENCODED_JSON_PALOAD_STUPID' 'cookie:COOKIE_2'`\n\nThe registration payload is like.\n\n```json\n{\"alias\":\"your_account_email\",\"badge\":0,\"quiettime\":{\"start\":\"1:00\",\"end\":\"6:30\"},\"tz\":\"America/Los_Angeles\",\"messageservice\":\"gcm\",\"tags\":[],\"device_token\":\"some magic string\",\"device_id\":\"a guid\",\"app\":\"parent:bh\",\"app_version\":\"7.2.7\",\"is_provider\":false}\n```\n\nI am too lazy to implement this flow in code, so you can either do it with httpie yourself, or, capture the phone packets and get the magic cookie.\n\n#### Fetch all the events\n\nNow, the cookie_2 is all you need, you can do crazy things. First, you might want to fetch all the events.\n\n`http https://www.tadpoles.com/remote/v1/events?num_events=78\u0026state=client 'cookie:THECOOKIEYOUSAVED'`\n\nAnd maybe this is for pagination: `/remote/v1/events?num_events=78\u0026state=client\u0026direction=newer\u0026latest_create_time=1487815536`\n\nEvent has type, it can be `Activity` or `DailyReport`\n\nActivity sample:\n\n```json\n{\n  \"comment\": \"The comment that should be put into exif\",\n  \"members_display\": [\n    \"Name\"\n  ],\n  \"attachments\": [\n    \"picture_id\"\n  ],\n  \"labels\": [\n    \"label1 label2\"\n  ],\n  \"create_time\": 1487815534.0,\n  \"event_eta\": null,\n  \"tz\": \"America/Los_Angeles\",\n  \"event_time\": 1487791483.0,\n  \"actor\": \"aaaaaaaa\",\n  \"member\": \"mmmmmm\",\n  \"location\": \"llllll\",\n  \"scope\": \"dependant\",\n  \"type\": \"Activity\",\n  \"new_attachments\": [\n    {\n      \"width\": null,\n      \"filename\": \"01487791485.bin\",\n      \"source\": \"providerapp\",\n      \"key\": \"picture_id\",\n      \"height\": null,\n      \"mime_type\": \"image/jpeg\"\n    }\n  ],\n  \"members\": [\n    \"mmmmmm\"\n  ],\n  \"actor_display\": \"qqqq\",\n  \"visibility\": [\n    \"p\",\n    \"d\",\n    \"t\"\n  ],\n  \"location_display\": \"Some Campus\",\n  \"grouped_event_is_primary\": false,\n  \"key\": \"kkkkkk\",\n  \"event_date\": \"2017-02-22\",\n  \"group\": \"gggggg\",\n  \"grouped_event_id\": null,\n  \"member_display\": \"Name\",\n  \"in_outbox\": false,\n  \"action\": \"AddToDaily\",\n  \"c_domains\": [\n    \"0KIaRPjLQ1ud2_YOuGiZOA\"\n  ]\n},\n```\n\nDailyReport sample:\n\n```json\n{\n  \"comment\": null,\n  \"members_display\": [\n    \"Name\"\n  ],\n  \"attachments\": [\n  ],\n  \"entries\": [\n    {\n      \"start_time\": 1487793600.0,\n      \"child_type\": \"toddler\",\n      \"type\": \"nap\",\n      \"id\": \"h8_waj7zqecxk3vl-ebv6a\",\n      \"end_time\": 1487803080.0\n    }\n  ],\n  \"create_time\": 1487815536.0,\n  \"event_eta\": null,\n  \"report_type\": \"toddler\",\n  \"tz\": \"America/Los_Angeles\",\n  \"event_time\": 1487750400.0,\n  \"actor\": \"xxxxxxxx\",\n  \"member\": \"xxxx\",\n  \"location\": \"xxxx\",\n  \"scope\": \"dependant\",\n  \"type\": \"DailyReport\",\n  \"new_attachments\": [\n  ],\n  \"members\": [\n    \"xxxxxx\"\n  ],\n  \"actor_display\": \"QQQQ\",\n  \"visibility\": [\n  ],\n  \"location_display\": \"Some Campus\",\n  \"grouped_event_is_primary\": false,\n  \"key\": \"kkkk\",\n  \"event_date\": \"2017-01-22\",\n  \"group\": \"gggg\",\n  \"grouped_event_id\": null,\n  \"member_display\": \"Zachary\",\n  \"in_outbox\": false,\n  \"action\": \"Notify\",\n  \"server_report_key\": \"rrrr\"\n}\n```\n\n#### Download a picture\n\n`http https://www.tadpoles.com/remote/v1/attachment?key=picture_id_in_acvitity 'cookie:COOKIE_2'","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftxchen%2Fbrightday-dl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftxchen%2Fbrightday-dl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftxchen%2Fbrightday-dl/lists"}