Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V1.0.0 beta #17

Merged
merged 11 commits into from
Jan 30, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
# WalletConnect v0.7.x
# WalletConnect v1.0.0-beta

## Introduction

Wallet Connect is a simple solution that enables communication between desktop Dapps and mobile Wallets using a QR Code to establish a session. It's an open protocol and does not require the User to have specific hardware or install any software. The protocol is agnostic to any mobile Wallets that wishes to support it and enables Dapp developers to integrate with several mobile Wallets through a single implementation.
WalletConnect is an open protocol to communicate securely between Wallets and Dapps (Web3 Apps). The protocol establishes a remote connection between two apps and/or devices using a Bridge server to relay payloads. These payloads are symmetrically encrypted through a shared key between the two peers. The connection is initiated by one peer displaying a QR Code or deep link with a standard WalletConnect URI and is established when the counter-party approves this connection request. It also includes an optional Push server to allow Native applications to notify the user of incoming payloads for establishes connections.

## Getting Started

Currently the WalletConnect protocol has implementations in Javascript for Browser SDK, Wallet SDK, Push Notification Webhook and in Python for the Bridge Server.
Currently the WalletConnect protocol has references implementations written in Typescript for the Client SDK (browser/react-native), the Bridge Server and the Push server.

To quickly setup for your Dapp or Wallet, go to [Quick Start](quick-start.md)
To quickly setup for your Dapp or Wallet, go to [Quick Start](quick-start.md) for code examples.

To read the technical specification of the WalletConnect protocol, go to [Technical Specification](tech-spec.md)
To read in more detail about the WalletConnect protocol, go to [Technical Specification](tech-spec.md)

To reference all the Bridge API calls go to [Bridge API](bridge-api.md)
Additionally you can also consult the API references for [Client SDK](bridge-sdk.md), [Bridge Server](bridge-server.md) and [Push Server](push-server.md)

## Community

Share your experience, contribute or ask questions with the WalletConnect Community

* Github: [https://github.com/walletconnect](https://github.com/walletconnect)
* Telegram: [https://t.me/walletconnect](https://t.me/walletconnect)
* Forum: [https://discuss.walletconnect.org](https://discuss.walletconnect.org)
* Discord: [https://discord.walletconnect.org](https://discord.walletconnect.org)

- Github: [https://github.walletconnect.org](https://github.walletconnect.org)
- Forum: [https://discuss.walletconnect.org](https://discuss.walletconnect.org)
- Discord: [https://discord.walletconnect.org](https://discord.walletconnect.org)
- Telegram: [https://telegram.walletconnect.org](https://telegram.walletconnect.org)
- Twitter: [https://twitter.walletconnect.org](https://twitter.walletconnect.org)
11 changes: 6 additions & 5 deletions SUMMARY.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Table of contents

* [WalletConnect v0.7.x](README.md)
* [Quick Start](quick-start.md)
* [Technical Specification](tech-spec.md)
* [Bridge API](bridge-api.md)

- [WalletConnect v1.0.0-beta](README.md)
- [Quick Start (Examples)](quick-start.md)
- [Technical Specification](tech-spec.md)
- [Client SDK API Reference](client-sdk.md)
- [Bridge Server API Reference](bridge-server.md)
- [Push Server API Reference](push-server.md)
Binary file removed assets/walletconnect-accounts-diagram.png
Binary file not shown.
Binary file removed assets/walletconnect-transaction-diagram.png
Binary file not shown.
137 changes: 0 additions & 137 deletions bridge-api.md

This file was deleted.

48 changes: 48 additions & 0 deletions bridge-server.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# Bridge Server API Reference

## Test Hello World

```bash
GET https://bridge.walletconnect.org/hello

Response:
Status: 200
Content-Type: text/plain; charset=utf-8
Body: Hello World, this is WalletConnect v1.0.0-beta
```

## Get Bridge Server Info

```bash
GET https://bridge.walletconnect.org/info

Response:
Status: 200
Content-Type: application/json; charset=utf-8
Body:
{
"name": "WalletConnect Bridge Server",
"repository": "walletconnect-bridge",
"version": "1.0.0-beta"
}
```

## Subscribe Push Notification Webhook

```bash
POST https://bridge.walletconnect.org/subscribe
Content-Type: application/json
Body:
{
"topic": <client_id>,
"webhook": <push_notification_webhook>
}

Response:
Status: 200
Content-Type: application/json; charset=utf-8
Body:
{
"success": true
}
```
102 changes: 102 additions & 0 deletions client-sdk.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
# Client SDK API Reference

## Register Event Subscription

```typescript
function on(
event: string,
callback: (error: Error | null, payload: any | null) => void
): void;
```

Events: `connect`, `disconnect`, `session_update`, `call_request`, `wc_sessionRequest`, `wc_sessionUpdate`, `wc_exchangeKey`

## Create New Session

```typescript
async function createSession(): Promise<void>;
```

## Approve Session Request

```typescript
function approveSession({
chainId: number, // Required
accounts: string[] // Required
}): void;
```

## Reject Session Request

```typescript
function rejectSession({
message: string // Optional
}): void;
```

## Update Session

```typescript
function updateSession({
chainId: number, // Required
accounts: string[] // Required
}): void;
```

## Kill Session (disconnect)

```typescript
function killSession({
message: string // Optional
}): void;
```

## Send Transaction (eth_sendTransaction)

```typescript
async function sendTransaction({
from: string, // Required
to: string, // Required
gasLimit: string, // Required
gasPrice: string, // Required
value: string, // Required
data: string, // Required
nonde: string // Required
}): Promise<string>;
```

Returns: Transaction hash

## Sign Message (eth_sign)

```typescript
async function signMessage(params: string[]): Promise<string>;
```

Returns: Signature

## Sign Typed Data (eth_signTypedData)

```typescript
async function signTypedData(params: any[]): Promise<string>;
```

Returns: Signature

## Approve Call Request

```typescript
function approveRequest({
id: number, // Required
result: any // Required
}): void;
```

## Reject Call Request

```typescript
function rejectRequest({
id: number, // Required
result: null // Required
}): void;
```
Loading