No description
- Go 97.8%
- Dockerfile 2.2%
|
All checks were successful
continuous-integration/drone/push Build is passing
|
||
|---|---|---|
| internal | ||
| vendor | ||
| .drone.yml | ||
| .gitignore | ||
| config.toml | ||
| Dockerfile | ||
| go.mod | ||
| go.sum | ||
| main.go | ||
| README.md | ||
extraless api
Open source replacement for the exteraGram backend.
run
go build -o api .
BOT_TOKEN=... ./api
da server listens on :8080 by default:
curl http://127.0.0.1:8080/api/v1/profile
curl http://127.0.0.1:8080/api/v1/profiles
conf
profiles are read from config.toml:
[profiles]
[profiles."8094510458"]
status = "DEVELOPER"
[profiles."123456789"]
status = "SUPPORTER"
canChangeBadge = true
[profiles."123456789".badge]
documentId = 5391059537102927631
text = "custom badge"
[profiles."123456789".nowPlaying]
serviceType = "LAST_FM"
username = "exampleuser"
supported fields:
status:DEVELOPER,SUPPORTER,DEFAULTtype:USER,CHATcanChangeBadge:trueorfalsebadge.documentIdbadge.textnowPlaying.serviceType:NONE,LAST_FM,STATS_FMnowPlaying.username
DEV_IDS is not required for profile status. its' only used for bot-side permissions such as addregdate and badge changes.
env
BOT_TOKENrequiredADDRdefault::8080DATA_PATHdefault:data.jsonCONFIG_PATHdefault:config.tomlDEV_IDSoptionalBOOTSTRAP_PROFILES_URLoptional