https://github.com/jantrw/spacelinker
🌌 SpaceLinker is a Discord bot that connects people with space. It provides real-time information about the International Space Station (ISS) and the NASA Astronomy Picture of the Day.
https://github.com/jantrw/spacelinker
api astronomy discord-bot exoplanets iss java mars-weather maven nasa slash-commands space
Last synced: about 1 month ago
JSON representation
🌌 SpaceLinker is a Discord bot that connects people with space. It provides real-time information about the International Space Station (ISS) and the NASA Astronomy Picture of the Day.
- Host: GitHub
- URL: https://github.com/jantrw/spacelinker
- Owner: jantrw
- License: mit
- Created: 2025-01-30T08:43:05.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2025-03-31T16:11:51.000Z (about 1 month ago)
- Last Synced: 2025-03-31T17:27:16.831Z (about 1 month ago)
- Topics: api, astronomy, discord-bot, exoplanets, iss, java, mars-weather, maven, nasa, slash-commands, space
- Language: Java
- Homepage:
- Size: 474 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# 🌌 SpaceLinker
A SpaceLinker that connects people with space – with support for NASA APIs and ISS tracking.
## Features
- **ISS Tracking**: Determines the current position (ocean or land with country + city), speed, and altitude of the International Space Station (ISS).

- **NASA Astronomy Picture of the Day**: Displays the current NASA Picture of the Day.

- **NASA Astronomy Picture of the Day with Info**: Displays the current NASA Picture of the Day with its description.

- **Slash Commands**: Supports modern Discord slash commands.

## Installation
### Requirements
- Java 17+
- Maven
- A Discord bot token
- Multiple free APIs (e.g., NASA API, ISS tracking API)### Setup
1. Clone the repository:
`git clone https://github.com/jantrw/SpaceLinker.git`
`cd SpaceLinker`
3. Create a `config.properties` file with the API keys and Discord token:
`DISCORD_TOKEN=your_token_here`
`NASA_API_KEY=your_nasa_api_key_here`
`USERNAME=your_username`
5. Build and run with Maven:
`mvn package`
`java -jar target/SpaceLinker.jar`
## Usage
### Available Commands
| Command | Description |
| ---------------------- | -------------------------------------------- |
| `/iss` | Displays current ISS data |
| `/picture` | Shows the NASA Astronomy Picture of the Day |
| `/pictureinfo` | Shows the NASA Astronomy Picture with Info |
| `/prefix ` | Changes the command prefix |## Architecture
Core classes of the bot:
- `DiscordBot.java` – Starts the bot and registers commands.
- `BotListener.java` – Handles messages and slash commands.
- `GuildDataManager.java` – Stores guild-specific data.
- `ISSData.java` – Sends ISS data as a Discord message.
- `NasaPictureOfTheDay.java` – Sends the NASA Astronomy Picture of the Day as a Discord message.
- `JSONFetcherIss.java` – Fetches current ISS data from an API.
- `JSONFetcherNasa.java` – Fetches the NASA Picture of the Day.## Contributing
Contributions are welcome! Feel free to open an issue or submit a pull request.## Support
If you encounter any issues, create a GitHub issue.## License
MIT License