Skip to content

Commit

Permalink
Merge pull request #28 from dfinity/icrc7-permit-icrc2
Browse files Browse the repository at this point in the history
Update ICRC-7 to use ICRC-2 semantics
  • Loading branch information
benjizhai authored Jul 13, 2023
2 parents 4cc8b0d + ef34fdf commit 9a8f583
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions ICRCs/ICRC-7/ICRC-7.md
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,8 @@ Transfers one or more tokens from account to the `to` account.

```candid "Type definitions" +=
type TransferArgs = record {
from : opt Account; /* if supplied and is not caller then is permit transfer, if not supplied defaults to subaccount 0 of the caller principal */
spender_subaccount: opt blob; // the subaccount of the caller (used to identify the spender)
from : Account;
to : Account;
token_ids : vec nat;
// type: leave open for now
Expand Down Expand Up @@ -189,11 +190,11 @@ The result is either the transaction index of the transfer or an error.
```candid "Type definitions" +=
type ApprovalArgs = record {
from_subaccount : opt blob;
to : principal;
tokenIds : opt vec nat; // if no tokenIds given then approve entire collection
spender : Account; // Approval is given to an ICRC Account
token_ids : opt vec nat; // TBD: change into variant?
expires_at : opt nat64;
memo : opt blob;
created_at : opt nat64;
created_at_time : opt nat64;
};
type ApprovalError = variant {
Expand All @@ -207,6 +208,8 @@ type ApprovalError = variant {
```candid "Methods" +=
icrc7_approve : (ApprovalArgs) -> (variant { Ok: nat; Err: ApprovalError; });
```
### icrc7_approve
TBD

### icrc7_supported_standards

Expand Down

0 comments on commit 9a8f583

Please sign in to comment.