Skip to content

Commit

Permalink
intents: session opened proof
Browse files Browse the repository at this point in the history
  • Loading branch information
marino39 committed Mar 13, 2024
1 parent fded76d commit 7b47e8e
Show file tree
Hide file tree
Showing 3 changed files with 94 additions and 20 deletions.
88 changes: 71 additions & 17 deletions intents/intent.gen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 11 additions & 3 deletions intents/intent.gen.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* eslint-disable */
// sequence-waas-intents v0.1.0 80bee7d15d1c82c2791adf35c50c7b9d70dc49bc
// sequence-waas-intents v0.1.0 5f9a4f32ed8f89b69bc488504504f205876d4520
// --
// Code generated by webrpc-gen@v0.14.0-dev with typescript generator. DO NOT EDIT.
// Code generated by webrpc-gen@v0.15.5 with typescript generator. DO NOT EDIT.
//
// webrpc-gen -schema=intent.ridl -target=typescript -client -out=./intent.gen.ts

Expand All @@ -12,7 +12,7 @@ export const WebRPCVersion = "v1"
export const WebRPCSchemaVersion = "v0.1.0"

// Schema hash generated from your RIDL schema
export const WebRPCSchemaHash = "80bee7d15d1c82c2791adf35c50c7b9d70dc49bc"
export const WebRPCSchemaHash = "5f9a4f32ed8f89b69bc488504504f205876d4520"

//
// Types
Expand Down Expand Up @@ -43,6 +43,7 @@ export interface IntentDataOpenSession {
sessionId: string
email?: string
idToken?: string
proofNonce?: string
}

export interface IntentDataCloseSession {
Expand Down Expand Up @@ -143,6 +144,13 @@ export interface IntentResponse {
export interface IntentResponseSessionOpened {
sessionId: string
wallet: string
proof: SessionOpenedProof
}

export interface SessionOpenedProof {
wallet: string
message: string
signature: string
}

export interface IntentResponseSessionClosed {
Expand Down
12 changes: 12 additions & 0 deletions intents/intent.ridl
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ struct IntentDataOpenSession
+ go.tag.json = email,omitempty
- idToken?: string
+ go.tag.json = idToken,omitempty
# the user defined nonce that will be included in session opened proof
- proofNonce?: string
+ go.tag.json = proofNonce,omitempty

struct IntentDataCloseSession
- sessionId: string
Expand Down Expand Up @@ -148,6 +151,15 @@ struct IntentResponseSessionOpened
- sessionId: string
+ go.field.name = SessionID
- wallet: string
- proof: SessionOpenedProof

struct SessionOpenedProof
# The wallet address
- wallet: string
# The message contents: “Registered <sessionId> <wallet> <proofNonce?>”
- message: string
# The signature of the message
- signature: string

struct IntentResponseSessionClosed

Expand Down

0 comments on commit 7b47e8e

Please sign in to comment.