-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.ts
More file actions
58 lines (43 loc) · 1.3 KB
/
index.ts
File metadata and controls
58 lines (43 loc) · 1.3 KB
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
import { dailyProgress, dayScoreSchema } from './schemas'
import { getTrueNetworkInstance } from './true-network/true.config'
const main = async () => {
const api = await getTrueNetworkInstance()
// Solana User's Address.
const solanaUserWallet = 'Ap67uX5zrvVAEt5TuFnk9J2w8fFZpht9FAtTdhxViViM'
// Ethereum User's Address.
const ethereumUserWallet = '0x4838B106FCe9647Bdf1E7877BF73cE8B0BAD5f97'
// Polkadot User's Address.
const polkadotUserWallet = '5DHrzaEFnNrwhMy4LqRs43zp8rNAhaEhXNqNMZ9bpZZevCqE'
await dayScoreSchema.attest(api, polkadotUserWallet, {
score: 5,
durationSpent: 11,
treesClimbedPerDay: 23,
villansKilled: 3
})
await dailyProgress.attest(api, polkadotUserWallet, {
radioScore: 5,
miles: 10
})
console.log(await dayScoreSchema.attest(api, solanaUserWallet, {
score: 7,
durationSpent: 1200,
treesClimbedPerDay: 56,
villansKilled: 4
}))
await dailyProgress.attest(api, solanaUserWallet, {
radioScore: 5,
miles: 10
})
console.log(await dayScoreSchema.attest(api, ethereumUserWallet, {
score: 11,
durationSpent: 1,
treesClimbedPerDay: 1,
villansKilled: 1
}))
console.log(await dailyProgress.attest(api, ethereumUserWallet, {
radioScore: 14,
miles: 18
}))
await api.network.disconnect()
}
main()