List of canisters a cycles wallet is associated?

Is there a way to get a list of all the canisters that have a specific cycles wallet associated with them?

I think this query is not possible, because if I understand it correctly, each canister has it‘s one cycle wallet canister.

I think you can use list_managed_canisters to figure that out

No, that’s not how it works. Typically every identity has a cycles wallet canister associated, but these can also be shared across multiple identities

Thanks @Severin

I’ve been trying to figure this out but I think I’m a bit lost at the moment!

dfx canister --network ic call tfx7v-vaaaa-aaaas-aaaaq-cai list_managed_canisters ‘(record {})’

WARN: Cannot fetch Candid interface for list_managed_canisters, sending arguments with inferred types.
Error: Failed update call.
Caused by: Failed update call.
The replica returned a replica error: reject code CanisterError, reject message Canister tfx7v-vaaaa-aaaas-aaaaq-cai has no update method ‘list_managed_canisters’, error code None

Could you give me a tip to overcome this step?

Also if I try to use a different dfx wallet command like:

dfx wallet --network ic addresses

I receive an error:

Error: Failed to call query function ‘list_addresses’ on wallet.
Caused by: Failed to call query function ‘list_addresses’ on wallet.
Failed to construct wallet canister caller: The replica returned a replica error: reject code CanisterError, reject message IC0536: Canister tfx7v-vaaaa-aaaas-aaaaq-cai has no query method ‘wallet_api_version’, error code Some(“IC0536”)

It seems that the documentation “Using a Cycles Wallet” describes a typographical error or an old format?

Check the cycles balance when deploying on the mainnet
If you have deployed a cycles wallet on the mainnet, you can use the dfx wallet balance --network ic command to check the current cycles balance on the network.

Must be: dfx wallet --network ic balance

That means you’re using a really old wallet version that doesn’t support these functions yet. dfx wallet upgrade should get you to the latest one