Skip to content

Commit

Permalink
Updated README.md.
Browse files Browse the repository at this point in the history
  • Loading branch information
ShaneQi committed Jul 23, 2017
1 parent 0018362 commit 1b6001c
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,12 @@ This library wraps the JSON decoding processing, making it easy to decode incomi

This library wraps the processing of converting objects to Telegram Bot API request parameters and the processing of performing request, making it easy to handle incoming update.

**This is a server-side swift library powered by [Perfect](https://github.com/PerfectlySoft/Perfect).
Which will help you build your own Perfect Telegram Bot!**

## Installation

Add this project as a dependency in your Package.swift file.

```swift
.Package(url: "https://github.com/ShaneQi/ZEGBot.git", versions: Version(0,0,0)..<Version(10,0,0))
.Package(url: "https://github.com/shaneqi/ZEGBot.git", majorVersion: 2)
```
## Quick Start

Expand All @@ -28,9 +25,7 @@ import ZEGBot
// Don't forget to fill in your bot token.
let bot = ZEGBot(token: "TYPE YOUR TOKEN HERE")

bot.run(with: {
update, bot in

bot.run { update, bot in
// Handle updates here...

})
Expand Down Expand Up @@ -69,7 +64,7 @@ bot.run(with: {
```swift
...
if let message = update?.message {
bot.send(message: "[Google](https://google.com)", to: message.chat, parseMode: .MARKDOWN, disableWebPagePreview: true, disableNotification: true)
bot.send(message: "[Google](https://google.com)", to: message.chat, parseMode: .markdown, disableWebPagePreview: true, disableNotification: true)
}
...
```
Expand Down Expand Up @@ -134,3 +129,4 @@ Not all the methods are supported, checkout more details on [Telegram Bot API](h

## License
This project is licensed under [Apache License v2.0](http://www.apache.org/licenses/LICENSE-2.0).

0 comments on commit 1b6001c

Please sign in to comment.