https://github.com/codedynasty-dev/wo
wo: Telegram bot API lib in zig
https://github.com/codedynasty-dev/wo
Last synced: 3 months ago
JSON representation
wo: Telegram bot API lib in zig
- Host: GitHub
- URL: https://github.com/codedynasty-dev/wo
- Owner: CodeDynasty-dev
- License: mit
- Created: 2023-05-08T23:06:46.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2023-06-06T07:25:56.000Z (almost 2 years ago)
- Last Synced: 2025-03-01T05:24:46.875Z (3 months ago)
- Language: Zig
- Size: 19.5 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: license
Awesome Lists containing this project
README
# wo
## All your bots are belong to us
Telegram bot API lib in zig
---
### Current apis
```zig
const std = @import("std");
const tm = @import("./tmstruct.zig");
pub fn main() !void {
var gpa = std.heap.GeneralPurposeAllocator(.{}){};
const allocator = gpa.allocator();
var token = "1234567890:aaaaaaaaaaaaa-bbbbbbbbbbbb-ccccccc";
const bot = tm.Bot.init(allocator, token);
// retrieve bot's getMe info
_ = try bot.getMe();// join the api and this path and return the url
_ = try bot.getUri("/api");
// https://api.telegram.org/bot1234567890:aaaaaaaaaaaaa-bbbbbbbbbbbb-ccccccc/api
}```
Currently working adding more apis, create a pr if you want to help support.
## How do i use it?
---
By riping out what you want, am not ready for providing packaging or something till it's mostly usable
## Enjoy