https://github.com/baxiry/im
Instant messaging server
https://github.com/baxiry/im
broker golang im instant-messaging pubsub real-time websocket
Last synced: 5 months ago
JSON representation
Instant messaging server
- Host: GitHub
- URL: https://github.com/baxiry/im
- Owner: baxiry
- Created: 2020-09-21T20:57:59.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2024-11-28T17:19:31.000Z (over 1 year ago)
- Last Synced: 2025-01-27T21:03:57.255Z (over 1 year ago)
- Topics: broker, golang, im, instant-messaging, pubsub, real-time, websocket
- Language: Go
- Homepage:
- Size: 159 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# *im*
##### Instant messaging server, easy to use as a server or as a library
### install :
```go get -u github.com/baxiry/im```
### how to use ?
create a websocket on browser and send message as json :
to subscribe to a topic (channel) send :
```json
{
"event":"subscribe",
"channel":"my-channel-id"
}
```
```event``` must be : ```subscribe```, ```unsubscribe```, ```message```,
Later we will add events: ```reseive```, and```seen```,
to send message to channel/topic:
```json
{
"event" : "message",
"channel" : "my-channel-123",
"data" : "hi frends"
}
```
then all client subscribe with "my-channel-123" will be receive "hi frinds" message.
### How do I create a private connection? between two clients?
Just create a channel and share it between two clients only, this is how you create a private connection
### Project status
- [x] websocket
- [x] Pubsub
- [ ] cache message
- [ ] 100% Unit testing
### License
Use this library with whatever license you prefer.