# Enoki Token Standard

The Enoki Wrapped Token is a proof of concept for a scalable fungible token on the Internet Computer. It implements sharding by account in order to run transactions in parallel.

It was created specifically for use in Enoki Exchange. It is very minimalistic (ex: does not keep transaction history) and subject to many modifications pending community consensus on a token standard.

It is loosely based on the DIP-20 Token Standard. It contains all DIP-20 methods, with some caveats:

* `name`, `symbol`, `getLogo`, `balanceOf`, etc, work as expected.
* `balanceOf` works as expected, except it is an `update` call, which takes longer and consumes cycles.
* `transfer` is slow because it involves several canister calls.
  * `shardTransfer` should be used instead, which is called at the shard contract (and not the main contract).
* `approve` and `transferFrom` will always fail, since this token standard uses subscriptions (aka notifications), and not approvals, for inter-contract calls.
  * `transferAndCall` (slow) and `shardTransferAndCall` (preferred) should be used instead.

<https://github.com/enoki-dex/enoki_wrapped_token>

### Pending Features

* Use tokens collected by this contract in fees in some sort of auction to have users refill cycles.
* Scale up and down automatically.
* To further optimize performance, create a function users can use to move to less utilised (and therefore faster) shards.
* Change hashmap of all user accounts to big-maps to scale data storage.
* Keep transaction history is kept by an archive canister (using a big-map) that listens (PubSub) to all transactions from all shards.
* Establish paid priority shards, for example for the exchange and liquidity pools.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.enoki.ooo/smart-contracts/enoki-token-standard.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
