Skip to content

Commit

Permalink
Update nft-collections.mdx
Browse files Browse the repository at this point in the history
  • Loading branch information
jessiemongeon1 authored Jun 27, 2024
1 parent a57ac04 commit f1b0f09
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docs/developer-docs/defi/nfts/nft-collections.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ dfx canister call icrc7 icrc37_transfer_from "(vec{record {
  created_at_time = null;}})"
```

### Step 9: Use the `approve` functionality from ICRC-37.
### Step 10: Use the `approve` functionality from ICRC-37.

Next, use the `icrc37_approve_tokens` canister method to approve the `alice` identity to spend token `0`:

Expand All @@ -322,7 +322,7 @@ dfx canister call icrc7 icrc37_is_approved "(vec { record {spender= record { own

This should return `(vec { true })`.

### Step 10: Create a new identity for `alice` to transfer the token to.
### Step 11: Create a new identity for `alice` to transfer the token to.

Create a `bob` identity for `alice` to transfer token `0` to:

Expand All @@ -345,7 +345,7 @@ dfx canister call icrc7 icrc37_transfer_from "(vec {record {
  created_at_time = null;}})"
```

### Step 11: Confirm the transfer was successful.
### Step 12: Confirm the transfer was successful.

Confirm that the token transfer was successful by echoing `bob`'s principal, then viewing the principal that owns token `0`:

Expand All @@ -356,7 +356,7 @@ dfx canister call icrc7 icrc7_owner_of '(vec {0})' --query

The two principal IDs should match.

### Step 12: Revoke the approval.
### Step 13: Revoke the approval.

You can revoke the approval with the command:

Expand All @@ -377,7 +377,7 @@ dfx canister call icrc7 icrc37_get_token_approvals "(vec { 0;},null,null)" --que

This should return `(vec {})`.

### Step 13: Get the full transaction log.
### Step 14: Get the full transaction log.

To view all transactions with the NFT collection, run the command:

Expand Down

0 comments on commit f1b0f09

Please sign in to comment.