{"id":31580569,"url":"https://github.com/peteretelej/nasa","last_synced_at":"2025-10-27T02:01:29.688Z","repository":{"id":57527221,"uuid":"90969749","full_name":"peteretelej/nasa","owner":"peteretelej","description":"Go Library for accessing the NASA API, nasa CLI and apps","archived":false,"fork":false,"pushed_at":"2018-12-19T22:11:22.000Z","size":48,"stargazers_count":17,"open_issues_count":1,"forks_count":3,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-09-22T01:37:34.246Z","etag":null,"topics":["go","golang","nasa-api","nasa-astronomy-picture"],"latest_commit_sha":null,"homepage":"https://nasa.etelej.com","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/peteretelej.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-05-11T11:01:36.000Z","updated_at":"2025-06-15T02:46:51.000Z","dependencies_parsed_at":"2022-09-07T05:31:06.406Z","dependency_job_id":null,"html_url":"https://github.com/peteretelej/nasa","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/peteretelej/nasa","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peteretelej%2Fnasa","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peteretelej%2Fnasa/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peteretelej%2Fnasa/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peteretelej%2Fnasa/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/peteretelej","download_url":"https://codeload.github.com/peteretelej/nasa/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/peteretelej%2Fnasa/sbom","scorecard":{"id":728818,"data":{"date":"2025-08-11","repo":{"name":"github.com/peteretelej/nasa","commit":"7a9680211873d3dc21a5ba27c1cbe082bc34e4e6"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.2,"checks":[{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":1,"reason":"Found 4/26 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 8 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-22T13:47:12.092Z","repository_id":57527221,"created_at":"2025-08-22T13:47:12.092Z","updated_at":"2025-08-22T13:47:12.092Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278520492,"owners_count":26000494,"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","status":"online","status_checked_at":"2025-10-05T02:00:06.059Z","response_time":54,"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":["go","golang","nasa-api","nasa-astronomy-picture"],"created_at":"2025-10-05T21:15:08.170Z","updated_at":"2025-10-05T21:15:09.452Z","avatar_url":"https://github.com/peteretelej.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# nasa - Go library and apps based on the NASA API\n\n[![CircleCI](https://circleci.com/gh/peteretelej/nasa/tree/master.svg?style=svg)](https://circleci.com/gh/peteretelej/nasa/tree/master) [![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fpeteretelej%2Fnasa.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fpeteretelej%2Fnasa?ref=badge_shield)\n\n[![GoDoc](https://godoc.org/github.com/peteretelej/nasa?status.svg)](https://godoc.org/github.com/peteretelej/nasa)\n[![Go Report Card](https://goreportcard.com/badge/github.com/peteretelej/nasa)](https://goreportcard.com/report/github.com/peteretelej/nasa)\n\n\n\nIncludes:\n- Go Library for accessing and using the NASA API (APOD, NEO)\n- Command line interface (CLI) for accessing NASA API's services\n- Apps based on the NASA API: e.g. Desktop Wallpapers, Web Server for APOD and Random APOD ..\n\n\n## NASA API KEY\n\nKindly grab a NASA API key from [here](https://api.nasa.gov/index.html#apply-for-an-api-key), and set it to the environment variable __NASAKEY__.\n```\nexport NASAKEY=YOUR-API_KEY\n```\nThe API Key will increase the rate limits for your application/package to access the NASA API. \nThis package \u0026 its apps default to the demo key `NASAKEY=DEMO_KEY` if you haven't set one. \nThe DEMO_KEY has very low limits (30reqs/hr, 50req/day), only sufficient for demoing.\n\n\n## nasa Library Usage\n``` go\npackage main\n\nimport (\n\t\"fmt\"\n\t\"log\"\n\t\"time\"\n\n\t\"github.com/peteretelej/nasa\"\n)\n\nfunc main() {\n\tapod, err := nasa.ApodImage(time.Now())\n\thandle(err)\n\tfmt.Println(apod)\n\n\t// apod has structure of nasa.Image, hence get details with:\n\t// apod.Date, apod.Title, apod.Explanation, apod.URL, apod.HDURL etc\n\tfmt.Printf(\"Today's APOD is %s, available at %s\", apod.Title, apod.HDURL)\n\n\tlastweek := time.Now().Add(-(7 * 24 * time.Hour))\n\tapod, err = nasa.ApodImage(lastweek)\n\thandle(err)\n\tfmt.Printf(\"APOD for 1 week ago:\\n%s\\n\", apod)\n}\nfunc handle(err error) {\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n}\n```\n\n## nasa CLI\n``` sh\n# installation\ngo get -u github.com/peteretelej/nasa/cmd/nasa\n\nnasa apod \n# returns the NASA Astronomy Picture of the day\n\nnasa apod -date 2016-01-17 \n# returns the NASA APOD for the date specified\n\nnasa neo\n# returns Near Earth Objects for today\n\nnasa neo -start 2017-05-10 -end 2017-05-12\n# returns Near Earth Objects for the range of dates specified\n```\n\n## Webserver for APOD pictures and Random Pics\nServe APOD on the web (demo: nasa.etelej.com)\n```\nnasa web\n# serves website at :8080\n\nnasa web -listen localhost:9000\n# serves website at localhost:9000\n```\n\n__Web server demo pages:__\n- [nasa.etelej.com](https://nasa.etelej.com): NASA Astronomy Picture of the Day (for today)\n- [nasa.etelej.com/random-apod](https://nasa.etelej.com/random-apod): Random images (HD images, updated every second, no autoreload)\n- [nasa.etelej.com/random-apod?sd=1](https://nasa.etelej.com/random-apod?sd=1): Gets Standard Definition images (lower quality,faster load, saves bandwidth).\n- [nasa.etelej.com/random-apod?auto=1](https://nasa.etelej.com/random-apod?auto=1): Automatically reload page (default reload interval: 5 minutes)\n- [nasa.etelej.com/random-apod?auto=1\u0026interval=60](https://nasa.etelej.com/random-apod?auto=1\u0026interval=60): Automatically reloads every 1800 seconds (1 hr)\n- [nasa.etelej.com/random-apod?sd=1\u0026auto=1\u0026interval=5](https://nasa.etelej.com/random-apod?sd=1\u0026auto=1\u0026interval=5): Automatically reloads SD images every 5 seconds\n- [nasa.etelej.com/random-apod?auto=1\u0026legacy=1](https://nasa.etelej.com/random-apod?auto=1\u0026legacy=1): Legacy browser support for reloading\n\n\n## NASA Desktop Wallpapers \nAutomatically change your desktop wallpaper to randomly selected NASA Astronomy Pictures of the Day.\n- Supports various Linux desktop variants (at the moment) incl Gnome, Gnome2, Lubuntu, KDE and others.\n- Also supports custom command to set the wallpaper.\n```\ngo get -u github.com/peteretelej/nasa/cmd/nasa-wallpapers\n\nnasa-wallpapers\n# automatically changes wallpapers every 10 minutes\n# tries to change wallpaper with an existing command, use -cmdDefault to change the default command\n# e.g -cmdDefault feh\n\nnasa-wallpapers -cmdDefault gnome\n# uses the gnome command for changing wallpapers (ie gsettings)\n\nnasa-wallpapers -interval 30s -cmdDefault kde\n# automatically changes wallpaper every 30seconds\n# rem to get and set NASA API KEY to env NASAKEY to avoid ratelimits\n\nnasa-wallpapers -cmd \"myCustomCommand %s\"\n# automatically changes wallpaper every 10 minutes with myCustomCommand\n```\n\n\n\n## License\n[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fpeteretelej%2Fnasa.svg?type=large)](https://app.fossa.io/projects/git%2Bgithub.com%2Fpeteretelej%2Fnasa?ref=badge_large)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpeteretelej%2Fnasa","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpeteretelej%2Fnasa","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpeteretelej%2Fnasa/lists"}