Skip to content

phenpessoa/tibiadata-api-go

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TibiaData API in Golang

GitHub CI Codecov GitHub go.mod version Docker version Docker size GitHub license

TibiaData API written in Golang and deployed in container (version v3 and above).

Documentation of API endpoints can be found on docs.tibiadata.com.

Table of Contents

API versions

Here is a summary of the TibiaData API versions

v4 is under development
v3 is deprecated (since 31rd January 2024)
v2 is deprecated (since 30rd April 2022)
v1 is deprecated (since 30rd April 2018)

How to use

You can either use it in a Docker container or go download the code and deploy it yourself on any server.

Keep in mind that there are restrictions on tibia.com that might impact the usage of the application being hosted yourself.

Helm

We have a Helm chart available for you to use to deploy your application to Kubernetes.

All our charts are available through charts.tibiadata.com.

Add the repository

helm repo add tibiadata https://charts.tibiadata.com
helm repo update

Search for the chart

helm repo search tibiadata

The charts-repository is located in tibiadata-helm-charts.

Docker

Our images are available on both GitHub Container Registry and Docker Hub.

This is how to pull and run the latest release of TibiaData from GHCR:

docker pull ghcr.io/tibiadata/tibiadata-api-go:latest
docker run -p 127.0.0.1:80:8080/tcp --rm -it ghcr.io/tibiadata/tibiadata-api-go:latest

You can also use Docker Hub to pull your images from.

If you want to run the latest code you can switch from latest to edge.

Docker-compose

This is a simple example on how you can get up and running with TibiaData in docker-compose, which will be running on port 8080 and be exposed locally.

version: "3"

services:
  tibiadata:
    image: ghcr.io/tibiadata/tibiadata-api-go:latest
    restart: always
    environment:
      - TIBIADATA_HOST=tibiadata.example.com
    ports:
      - 8080:8080

Local development

Build the code on your computer

docker build -t tibiadata .

Run your build locally

docker run -p 127.0.0.1:80:8080/tcp --rm -it tibiadata

Environment variables

Information will be added at a later stage.

Deployment note

You should consider to add a layer in front of this application, so you can do caching of endpoints, access controll or what ever your needs are.

We do so at least by using Kong API Gateway, which solves features like caching, rate-limiting, authentication and more.

API documentation

The hosted API documentation for our api.tibiadata.com service can be viewd at docs.tibiadata.com.

There is a swagger-generated documentation available for download on the GitHub Release of the version you are looking for.

Available endpoints

Those are the current existing endpoints.

  • GET /ping
  • GET /healthz
  • GET /readyz
  • GET /v4/boostablebosses
  • GET /v4/character/:name
  • GET /v4/creature/:race
  • GET /v4/creatures
  • GET /v4/fansites
  • GET /v4/guild/:name
  • GET /v4/guilds/:world
  • GET /v4/highscores/:world/:category/:vocation/:page
  • GET /v4/house/:world/:house_id
  • GET /v4/houses/:world/:town
  • GET /v4/killstatistics/:world
  • GET /v4/news/archive
  • GET /v4/news/archive/:days
  • GET /v4/news/id/:news_id
  • GET /v4/news/latest
  • GET /v4/news/newsticker
  • GET /v4/spell/:spell_id
  • GET /v4/spells
  • GET /v4/world/:name
  • GET /v4/worlds
  • GET /versions

Deprecated Endpoints

  • GET /health
  • GET /v3/boostablebosses
  • GET /v3/character/:name
  • GET /v3/creature/:race
  • GET /v3/creatures
  • GET /v3/fansites
  • GET /v3/guild/:name
  • GET /v3/guilds/:world
  • GET /v3/highscores/:world/:category/:vocation/:page
  • GET /v3/house/:world/:house_id
  • GET /v3/houses/:world/:town
  • GET /v3/killstatistics/:world
  • GET /v3/news/archive
  • GET /v3/news/archive/:days
  • GET /v3/news/id/:news_id
  • GET /v3/news/latest
  • GET /v3/news/newsticker
  • GET /v3/spell/:spell_id
  • GET /v3/spells
  • GET /v3/world/:name
  • GET /v3/worlds

General information

Tibia is a registered trademark of CipSoft GmbH. Tibia and all products related to Tibia are copyright by CipSoft GmbH.

Credits

About

TibiaData API written in Golang and deployed in container (which contains v3)

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 99.8%
  • Dockerfile 0.2%