*Note about the api stability: this package is under heavy development, and it's not intended for production purposes. Its api may change without previous notice.*
This package provides an easy way to interact with [status](https://status.im) messaging system.
This package allows you to create applications that interact with the status messaging system
## Motivation
This library was initially created to have a low-dependency way to interact with status messaging system.
This project is under heavy development process, here is a list of supported features:
**Status messaging basic interaction**
- [x] Setup a new connection
- [x] Close a specific connection
- [x] Sign up on the platform
- [x] Login as a specific account
- [ ] Documented API for basic sdk interaction
**Public channels interaction**
- [x] Join public channels
- [x] Publish messages on public channels
- [x] Subscribe to public channels
- [x] Unsubscribe from a public channel
- [ ] Documented API for public channels interaction
- [x] Working examples for public channel interaction
**Contact management**
- [ ] Invite new contact
- [ ] Accept a contact request
**1 to 1 messages interaction**
- [ ] Send 1 to 1 conversation
- [ ] Subscribe to 1 to 1 conversation
- [ ] Unsubscribe from a 1 to 1 conversation
- [ ] Documented API for 1 to 1 conversation
- [ ] Working examples for 1 to 1 conversations
**Private groups interaction**
- [ ] Publish messages on private groups
- [ ] Subscribe to private groups
- [ ] Unsubscribe from a private groups
- [ ] Documented API for private groups interaction
- [ ] Working examples for private groups interaction
## Code Example
You'll find some code examples on the [examples folder](/examples)
## Installation
status-go-sdk is a lightweight dependency package, that means we try to avoid as much external dependencies as possible. You can install it by running:
```
go get github.com/status-im/status-go-sdk
```
However, and to run some examples you may also want to install `go-ethereum/rpc` with
`status-go-sdk` relies on a running instance of `statusd`, we can quickly configure it by [following its official instructions](https://github.com/status-im/status-go#build), but you can use this as a quick-start:
```
# Clone status-go
mkdir $GOPATH/src/status-im/
cd $GOPATH/src/status-im/
git clone git@github.com:status-im/status-go.git
cd status-go
# Build it and run it
make statusgo && ./build/bin/statusd -shh=true -standalone=false -http=true -status=http -networkid=1
```
With this you'll have a statusd server running on `8545` port.
`status-go-sdk` receives as parameter an [RPCClient interface](https://github.com/status-im/status-go-sdk/blob/master/sdk.go#L7), this allows you to use it in many different ways, here we will use a basic example relying on go-ethereum/rpc client.
```
package main
import (
"fmt"
"log"
"time"
"github.com/ethereum/go-ethereum/rpc"
"github.com/status-im/status-go-sdk"
)
func main() {
// Here we create a new remote client against our running statusd