-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
123 changed files
with
1,483 additions
and
1,139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
{ | ||
"__Candid_UI": { | ||
"local": "bd3sg-teaaa-aaaaa-qaaba-cai" | ||
"local": "be2us-64aaa-aaaaa-qaabq-cai" | ||
}, | ||
"assets": { | ||
"local": "br5f7-7uaaa-aaaaa-qaaca-cai" | ||
"local": "bw4dl-smaaa-aaaaa-qaacq-cai" | ||
}, | ||
"backend": { | ||
"local": "bw4dl-smaaa-aaaaa-qaacq-cai" | ||
"local": "bd3sg-teaaa-aaaaa-qaaba-cai" | ||
}, | ||
"ckbtc_ledger": { | ||
"local": "bkyz2-fmaaa-aaaaa-qaaaq-cai" | ||
}, | ||
"icrc1_index": { | ||
"local": "be2us-64aaa-aaaaa-qaabq-cai" | ||
"local": "br5f7-7uaaa-aaaaa-qaaca-cai" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
() | ||
(nat) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,91 +1,58 @@ | ||
type UserId = nat32; | ||
type User = | ||
record { | ||
created_at: int; | ||
email: text; | ||
email_notifications: bool; | ||
id: nat; | ||
name: text; | ||
phone: text; | ||
phone_notifications: bool; | ||
wallet: principal; | ||
}; | ||
type Trie = | ||
variant { | ||
branch: Branch; | ||
"empty"; | ||
leaf: Leaf; | ||
}; | ||
type TransactionId = nat32; | ||
type Transaction = | ||
record { | ||
amount: nat; | ||
created_at: int; | ||
from: principal; | ||
memo: text; | ||
to: principal; | ||
}; | ||
type Subaccount = blob; | ||
type Result = | ||
variant { | ||
err: text; | ||
ok: text; | ||
}; | ||
type List = | ||
opt record { | ||
record { | ||
Key; | ||
User; | ||
}; | ||
List; | ||
}; | ||
type Leaf = | ||
record { | ||
keyvals: AssocList; | ||
size: nat; | ||
}; | ||
type Key = | ||
record { | ||
hash: Hash; | ||
key: UserId; | ||
}; | ||
type Account = record { owner : principal; subaccount : opt Subaccount }; | ||
type AssocList = opt record { record { Key; User }; List }; | ||
type Backend = service { | ||
create : (User) -> (UserId); | ||
delete : (UserId) -> (bool); | ||
getAllUsers : () -> (Trie) query; | ||
getCanisterAddress : () -> (text); | ||
getCanisterBalance : () -> (text); | ||
getFundingAddress : () -> (text); | ||
getFundingBalance : () -> (text); | ||
getInvoice : () -> (Account); | ||
getLogs : () -> (vec text) query; | ||
getTradingAddress : () -> (text); | ||
getTradingBalance : () -> (text); | ||
read : (UserId) -> (opt User) query; | ||
saveTransaction : (Transaction) -> (TransactionId); | ||
setCourierApiKey : (text) -> (Response); | ||
transactionsLength : () -> (text) query; | ||
transferFromCanistertoSubAccount : () -> (Result); | ||
transferFromSubAccountToSubAccount : (text, nat) -> (Result); | ||
update : (UserId, User) -> (bool); | ||
userLength : () -> (text) query; | ||
whoami : () -> (principal); | ||
}; | ||
type Branch = record { left : Trie; size : nat; right : Trie }; | ||
type Hash = nat32; | ||
type Branch = | ||
record { | ||
left: Trie; | ||
right: Trie; | ||
size: nat; | ||
}; | ||
type AssocList = | ||
opt record { | ||
record { | ||
Key; | ||
User; | ||
}; | ||
List; | ||
}; | ||
type Account = | ||
record { | ||
owner: principal; | ||
subaccount: opt Subaccount; | ||
}; | ||
service : { | ||
create: (User) -> (UserId); | ||
delete: (UserId) -> (bool); | ||
getAllUsers: () -> (Trie) query; | ||
getCanisterAddress: () -> (text); | ||
getCanisterBalance: () -> (text); | ||
getFundingAddress: () -> (text); | ||
getFundingBalance: () -> (text); | ||
getInvoice: () -> (Account); | ||
getTradingAddress: () -> (text); | ||
getTradingBalance: () -> (text); | ||
read: (UserId) -> (opt User) query; | ||
saveTransaction: (Transaction) -> (TransactionId); | ||
transactionsLength: () -> (text) query; | ||
transferFromCanistertoSubAccount: () -> (Result); | ||
transferFromSubAccountToSubAccount: (text, nat) -> (Result); | ||
update: (UserId, User) -> (bool); | ||
userLength: () -> (text) query; | ||
whoami: () -> (principal); | ||
} | ||
type Key = record { key : UserId; hash : Hash }; | ||
type Leaf = record { size : nat; keyvals : AssocList }; | ||
type List = opt record { record { Key; User }; List }; | ||
type Response = record { | ||
status : nat16; | ||
data : opt text; | ||
status_text : text; | ||
error_text : opt text; | ||
}; | ||
type Result = variant { ok : text; err : text }; | ||
type Subaccount = vec nat8; | ||
type Transaction = record { | ||
to : principal; | ||
from : principal; | ||
memo : text; | ||
created_at : int; | ||
amount : nat; | ||
}; | ||
type TransactionId = nat32; | ||
type Trie = variant { branch : Branch; leaf : Leaf; "empty" }; | ||
type User = record { | ||
id : nat; | ||
phone_notifications : bool; | ||
name : text; | ||
email_notifications : bool; | ||
created_at : int; | ||
email : text; | ||
wallet : text; | ||
phone : text; | ||
}; | ||
type UserId = nat32; | ||
service : Backend |
Oops, something went wrong.