-
Notifications
You must be signed in to change notification settings - Fork 307
/
userData.ts
39 lines (39 loc) · 1.78 KB
/
userData.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/**
* Returned from the [[UserSession.loadUserData]] function.
*/
export interface UserData {
// public: the email address for the user. only available if the `email`
// scope is requested, and if the user has entered a valid email into
// their profile.
//
// **Note**: Blockstack does not require email validation
// for users for privacy reasons and blah blah (something like this, idk)
email?: string;
// probably public: (a quick description of what this is, and a link to the
// DID foundation and/or the blockstack docs related to DID, idk)
decentralizedID?: string;
// probably private: looks like it happens to be the btc address but idk
// the value of establishing this as a supported field
identityAddress?: string;
// probably public: this is an advanced feature, I think many app devs
// using our more advanced encryption functions (as opposed to putFile/getFile),
// are probably using this. seems useful to explain.
appPrivateKey: string;
// maybe public: possibly useful for advanced devs / webapps. I see an opportunity
// to make a small plug about "user owned data" here, idk.
hubUrl: string;
coreNode: string;
// maybe private: this would be an advanced field for app devs to use.
authResponseToken: string;
// private: does not get sent to webapp at all.
coreSessionToken?: string;
// private: does not get sent to webapp at all.
gaiaAssociationToken?: string;
// public: this is the proper `Person` schema json for the user.
// This is the data that gets used when the `new blockstack.Person(profile)` class is used.
profile: any;
// private: does not get sent to webapp at all.
gaiaHubConfig?: any;
// Based on issue with incorrect appPrivateKey derivation see stacks-web-wallet issue #2238
appPrivateKeyFromWalletSalt?: string;
}