Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
755bbe9
refactor: simplify some lines of code
null8626 Sep 21, 2024
41afa18
fix: proper avatar URL coverage
null8626 Oct 13, 2024
4ded956
doc: ALRIGHT WE GET IT ITS A (DISCORD) BOT
null8626 Oct 13, 2024
7bff326
meta: update copyright year
null8626 Feb 15, 2025
fb67642
feat: deprecate features no longer available in Top.gg API v0 [skip ci]
null8626 Feb 17, 2025
b8dc6ba
feat: add get_bots() again
null8626 Feb 18, 2025
aee55e0
feat: add sort_by methods in GetBots
null8626 Feb 18, 2025
f38c5f0
feat: add v0
null8626 Feb 18, 2025
cc310a7
feat: add tests
null8626 Feb 18, 2025
00649aa
refactor: use iter instead of into_iter
null8626 Feb 18, 2025
43ec709
refactor: ignore unreachable_patterns
null8626 Feb 18, 2025
33bfceb
doc: update docs for server count [skip ci]
null8626 Feb 18, 2025
b50a48c
okay veld
null8626 Feb 19, 2025
7ed5e65
style: prettier
null8626 Feb 19, 2025
4ce932c
doc: tweak documentation for GetBots
null8626 Feb 19, 2025
86cc496
fix: remove get_user and fix several bugs
null8626 Feb 19, 2025
a05052f
ci: uncomment tests [skip ci]
null8626 Feb 20, 2025
cefca8d
feat: name instead of username
null8626 Feb 21, 2025
d119d73
refactor: rework BotQuery
null8626 Feb 26, 2025
376cc56
feat: add reviews
null8626 Feb 27, 2025
d2c5ee5
ci: remove test workflow
null8626 Mar 4, 2025
2af90fc
feat: add page to get_voters
null8626 Mar 4, 2025
f4633a0
doc: reword documentation
null8626 Mar 4, 2025
49d95f6
doc: add NotFound description in has_voted
null8626 Mar 6, 2025
57bd4a7
doc: make this consistent
null8626 Mar 6, 2025
7c69ed0
doc: shorten documentation
null8626 Mar 6, 2025
09ccf9f
refactor: refactor from pedantic clippy
null8626 Mar 20, 2025
48821be
feat: remove url
null8626 May 5, 2025
f8888f0
fix: fix: GET /bots/votes not working
null8626 May 23, 2025
5569174
feat: fully adapt to v0
null8626 Jun 16, 2025
5763d2f
feat: add widgets
null8626 Jun 16, 2025
66b3e7a
feat: add small widgets
null8626 Jun 18, 2025
6142f1f
docs: readme overhaul
null8626 Jun 23, 2025
bc9f676
refactor: return 400 if json is not valid
null8626 Jun 24, 2025
48a6902
feat: rename webhook to webhooks
null8626 Jun 26, 2025
1945816
doc: documentation overhaul
null8626 Jul 9, 2025
f34f8ae
feat: adapt to v1
null8626 Sep 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 37 additions & 13 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
[package]
name = "topgg"
version = "1.4.2"
version = "2.0.0"
edition = "2021"
authors = ["null (https://github.com/null8626)", "Top.gg <support@top.gg> (https://top.gg)"]
description = "The official Rust wrapper for the Top.gg API"
description = "A simple API wrapper for Top.gg written in Rust."
readme = "README.md"
repository = "https://github.com/Top-gg-Community/rust-sdk"
license = "MIT"
Expand All @@ -12,45 +12,69 @@ categories = ["api-bindings", "web-programming::http-client"]
exclude = [".gitattributes", ".github/", ".gitignore", "rustfmt.toml"]

[dependencies]
base64 = { version = "0.22", optional = true }
cfg-if = "1"
paste = { version = "1", optional = true }
reqwest = { version = "0.12", optional = true }
serde = { version = "1", features = ["derive"] }
tokio = { version = "1", features = ["rt", "sync", "time"], optional = true }
urlencoding = { version = "2", optional = true }
urlencoding = "2"

serenity = { version = "0.12", features = ["builder", "client", "gateway", "model", "utils"], optional = true }

twilight-http = { version = "0.15", optional = true }
twilight-model = { version = "0.15", optional = true }
twilight-cache-inmemory = { version = "0.15", optional = true }

chrono = { version = "0.4", default-features = false, optional = true, features = ["serde"] }
chrono = { version = "0.4", default-features = false, optional = true, features = ["serde", "now"] }
serde_json = { version = "1", optional = true }

rocket = { version = "0.5", default-features = false, features = ["json"], optional = true }
axum = { version = "0.7", default-features = false, optional = true, features = ["http1", "tokio"] }
axum = { version = "0.8", default-features = false, optional = true, features = ["http1", "tokio"] }
async-trait = { version = "0.1", optional = true }
warp = { version = "0.3", default-features = false, optional = true }
actix-web = { version = "4", default-features = false, optional = true }

[dev-dependencies]
tokio = { version = "1", features = ["rt", "macros"] }
twilight-gateway = "0.15"

[lints.clippy]
all = { level = "warn", priority = -1 }
pedantic = { level = "warn", priority = -1 }
cast-lossless = "allow"
cast-possible-truncation = "allow"
cast-possible-wrap = "allow"
cast-sign-loss = "allow"
inline-always = "allow"
module-name-repetitions = "allow"
must-use-candidate = "allow"
return-self-not-must-use = "allow"
similar-names = "allow"
single-match-else = "allow"
too-many-lines = "allow"
unnecessary-wraps = "allow"
unreadable-literal = "allow"

[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "docsrs"]
rustc-args = ["--cfg", "docsrs"]

[features]
default = ["api"]
api = ["chrono", "reqwest", "serde_json"]
autoposter = ["api", "tokio"]
api = ["async-trait", "base64", "chrono", "reqwest", "serde_json"]
bot-autoposter = ["api", "tokio"]
autoposter = ["bot-autoposter"]

serenity = ["dep:serenity", "paste"]
serenity-cached = ["serenity", "serenity/cache"]

twilight = ["twilight-model"]
twilight = ["twilight-model", "twilight-http"]
twilight-cached = ["twilight", "twilight-cache-inmemory"]

webhook = ["urlencoding"]
rocket = ["webhook", "dep:rocket"]
axum = ["webhook", "async-trait", "serde_json", "dep:axum"]
warp = ["webhook", "async-trait", "dep:warp"]
actix-web = ["webhook", "dep:actix-web"]
webhooks = []
rocket = ["webhooks", "dep:rocket"]
axum = ["webhooks", "async-trait", "serde_json", "dep:axum"]
warp = ["webhooks", "async-trait", "dep:warp"]
actix-web = ["webhooks", "dep:actix-web"]
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2023-2024 Top.gg & null8626
Copyright (c) 2023-2025 Top.gg & null8626

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
Loading