I want my canister to receive icp was informed

I see a white list inform canister in the code。

I want to know what should I do to make my canister to join white list, and have been told to get icp。
Tank you~

Hi there,

There no white list for this feature. Did you try using it and get an error?

See: Canisters cannot send ICP to a wallet? - #2 by roman-kashitsyn

Hi @cwb2819259! I think Diego was a bit too quick with his reply.

what should I do to make my canister to join white list, and have been told to get icp

The notify() interface isn’t really “public” now. It might disappear or change significantly in the near future. Its main purpose is communication with the Cycles Minting Canisters.

It also probably doesn’t do what you think it does: the Ledger doesn’t send notifications automatically when a canister receives a payment (the Ledger can’t even tell if the receiver of the tokens is a canister). If you have a client who makes payments to your canister, the client should just notify your canister directly when the payment succeeds. I’ll try to cover these topics in more detail in the “ICP on Canisters” community conversations talk next week (The DFINITY Foundation).


Thanks for your reply.I will focus on your “ICP on Canisters” community conversations.
There is a problem, if transfer notice my canister, I should realize what method to get his notice.

Thank you for correcting me, I was too careles, @roman-kashitsyn . Much appreciated, man.

yes. I try to inform me of the canister receives the icp, but error.

I realize that I did not read your original question too closely, so I think @roman-kashitsyn is the expert in this case.

That’s correct, your canister needs to expose a method to accept notifications. Note however, that if anybody was allowed to call ledger notify method, you’d still need such a method: Ledger’s notify just calls transaction_notification method on the destination canister, just as the original caller might have done. The main difference between calling transaction_notification directly or doing this through the ledger’s notify call is the receiver of the notification will see a different values of the caller attribute.

It’s indeed easier to validate transactions if the notification comes directly from the ledger, but this mechanism was never intended for the general use: it scales poorly and it has security risks for the ledger canister. The notify mechanism is likely to be removed from the ledger interface in future.

Im my recent community conversations talk, I described a way to validate transactions on the Ledger without relying on Ledger notifications. @kpeacock is also working on a service that will provide a simplified payment validation mechanism: Payments - Invoice Canister Design Review


I feel like notifying a canister of a transfer (whether by calling the ledger notify method or a canister’s transaction_notification method) is too simple for most use cases involving canisters and DeFi.

That’s why ERC-20 added approve and transferFrom instead of relying on a simple transfer.

They let a third-party smart contract safely send tokens on your behalf.

Or do you intend for community developers to wrap the ICP ledger canister in a more general ERC-20-like interface?