Skip to content

Commit

Permalink
Merge branch 'main' into mobile
Browse files Browse the repository at this point in the history
  • Loading branch information
MSghais committed May 15, 2024
2 parents 432c0a7 + dfe1e77 commit fa5cbb2
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 2 deletions.
26 changes: 24 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,37 @@ Freedom requires censorship resistance, and Nostr provides exactly that.

## Roadmap

- [ ] Cairo implementation of Nostr signature verification
- [x] Cairo implementation of Nostr signature verification
- [ ] Starknet account contract implementation, controlled by Nostr keypair
- [ ] Simple frontend to sign and verify messages (using a browser extension lke [Flamingo](https://www.getflamingo.org/) or any other [NIP-07](https://github.com/nostr-protocol/nips/blob/master/07.md) compatible extension, list can be found [here](https://github.com/aljazceru/awesome-nostr#nip-07-browser-extensions))
- [ ] Joyboy landing page
- [ ] SocialPay feature to send and receive tips through Nostr signed messages
- [ ] Implement a full Nostr client application with Starknet integration
- [ ] Run Nostr relay server
- [ ] Crossover with [Vault](https://github.com/keep-starknet-strange/vault) to bring Social features to the Vault application

## Architecture
### SocialPay
#### Alice sends tokens to Bob
```mermaid
sequenceDiagram
actor Alice
actor Bob
participant SocialPay relay
participant Starknet Node
participant Alice Account
participant STRK Token
Alice->>SocialPay relay: @joyboy send 10 STRK to @bob
activate SocialPay relay
SocialPay relay->>Starknet Node: SocialPay transaction
Starknet Node->>Alice Account: SocialPay handler
Alice Account->>STRK Token: transfer
Starknet Node->>SocialPay relay: SocialPay transaction complete
SocialPay relay->>Bob: @bob you just recived 10 STRK from @alice
SocialPay relay->>Alice: @alice transfer of 10 STRK to @bob is complete
deactivate SocialPay relay
```

## Modules

<details>
Expand Down
12 changes: 12 additions & 0 deletions onchain/src/nip01.cairo
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#[derive(Copy, Drop)]
struct NIP01Event {
id: u256,
pubkey: u256,
created_at: u64,
kind: u16,
tags: Array<Array<ByteArray>>,
content: ByteArray,
sig_r: u256,
sig_s: u256
}

0 comments on commit fa5cbb2

Please sign in to comment.