Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/maxikg/go-hypixel
Community-maintained Hypixel API client in the go language.
https://github.com/maxikg/go-hypixel
Last synced: about 2 months ago
JSON representation
Community-maintained Hypixel API client in the go language.
- Host: GitHub
- URL: https://github.com/maxikg/go-hypixel
- Owner: maxikg
- License: apache-2.0
- Created: 2016-01-02T11:43:29.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2016-02-25T14:18:05.000Z (almost 9 years ago)
- Last Synced: 2024-06-20T11:12:19.836Z (6 months ago)
- Language: Go
- Homepage:
- Size: 27.3 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# go-hypixel [![Build Status](https://travis-ci.org/maxikg/go-hypixel.svg)](https://travis-ci.org/maxikg/go-hypixel) [![GoDoc](https://godoc.org/github.com/maxikg/go-hypixel/hypixel?status.svg)](https://godoc.org/github.com/maxikg/go-hypixel/hypixel)
go-hypixel is a Go client library for interacting with the [Hypixel API](https://api.hypixel.net/).
Please note that this is my first go project. My intention is to get familiar with go. Please excuse any insult of the
aesthetics of the go lang. Please let me know what you think about it.## Installation
Before you can install the software you need to [install go](https://golang.org/doc/install). The `GOPATH` environment
variable is required too.The installation of the library (should be) is pretty simple:
```
go get github.com/maxikg/go-hypixel/hypixel
```Updates can be done using the `-u` option on the `go get`: `go get -u github.com/maxikg/go-hypixel/hypixel`
After the library is installed the import should be resolved.
## Usage
First import the library:
```go
import "github.com/maxikg/go-hypixel/hypixel"
```Construct a new Hypixel client to access the various aspects of their public api. For example, to show an api keys
statistics:```go
client := hypixel.NewClient("your-api-key", nil)
profile, err := client.KeyInfo()
```## Supported API features
* `/key` - Statistic and basic information about the used API key
* `/findGuild` - Gets a guilds id by a player name, a player uuid or a guild name
* `/guild` - Gets a guild by its id
* `/friends` - Get the friend list of a player
* `/player` - Get various information about a player
* `/session` - Get the current minigame server of a player including some additional information about it## ToDo
* Add game type values
* Add tests## License
This library is distributed under the Apache License 2.0. A copy is shipped within the
[LICENSE.txt](/LICENSE.txt) file.