ICRC-Rosetta 1.0.0 Release

Thank you Nikolas, do you have ha chance to help me out here please?

Can you show me the command you used to start icrc rosetta?

Sure! That’s how I started the ICRC-Rosetta node from docker:

docker run -ti --detach --restart always --name rosetta-node-icrc-openchat -p 8082:8082 -v rosetta-data-icrc-openchat:/path/to/rosetta/data dfinity/ic-icrc-rosetta-api --network-type mainnet --ledger-id 2ouva-viaaa-aaaaq-aaamq-cai

Instead, this is how I started the other node (the one for ICP):

docker run --interactive --tty --publish 8081:8081 --detach --name rosetta-node -v rosetta-data:/path/to/rosetta/data --restart always dfinity/rosetta-api --mainnet --not-whitelisted

As I mentioned above, the ICP node can be contacted correctly from port 8081, but the ICRC node does not respond on port 8082.

Thank you!

You need to specify the port for rosetta too. the command -p 8082:8082 only specifies the port for docker not for rosetta. You can pass the port for rosetta by specifying it like so: --port 8082


Thank you! It works.

@NikolasHai this is amazing, thanks for releasing the Rosetta for ICRC tokens! Is it already considered production ready? Can we go into talks with CEXs about token listings using this rosetta version?

1 Like

Fetching CHAT token transaction blocks, I noticed that we have two address identifiers: account and sub_account.

As I understand it if the sub_account is empty (all zero values) it means the transaction was routed directly to the main account, otherwise if an address is present it means it was routed to the sub address. Am I correct?

Also, trying to get the account balance from the /account/balance endpoint in the case of sub_account address I cannot get a value, even if I combine sub_account with the main account. Instead with the main account address I can correctly get the balance from the endpoint.

So, how do I get the sub_accounts balance?

Thank you for your help.

I think I got it… it was necessary to add another parameter on request. As per Coinbase docs.

    "account_identifier" => array(
        "address" => $accountAddress,
        "sub_account" => array(
            "address" => $subAccountAddress

Thanks anyway… I would still like to have ha confirmation here: :slight_smile:


I’m confused whether Dfinity should proactively contact centralized CEXs to change the transfer addresses for ICP from Account ID to Principal ID. This would minimize resistance for all SNS projects to the maximum extent. Otherwise, traders transferring ICP and SNS tokens on CEXs may be misled because our ICP transfer addresses look very confusing.


Please see the docs on the difference between Accountidentifiers and Accounts here: Overview | Internet Computer

It is not possible to change Accountidentifiers to Accounts since you would need to break the hash function to do that.

Does this support any non SNS token with ICRC-1 and ICRC-2 standard. If not, what is the solution for migrating some token to use Rosetta API?

Depending on what library you are using it may or may not. I need to add a get_transactions endpoint into the motoko libraries and I have concerns about phash calls on the Rosetta verifier, but hopefully I can get it in in the next couple of weeks.