Hey @paulinablaszk! Unfortunately it is not possible to do that currently: zos.network.json gets updated by the CLI when it creates a new proxy via
zos create, but since in this case the proxy is being created out-of-band, the CLI has no way to track it and add it to the file.
You could handle that manually by scanning all
ProxyCreated events emitted by the App and adding the proxy entry to the zos.network.json file.
Update: actually, what you want to do could be handled via the
status --fix command, which will attempt to reconstruct your zos.network.json file based on events scanned from the network. However, that command is deprecated and may introduce potential issues. I’d suggest taking a look at it to see if works for your specific scenario, or borrowing some pieces of code from it.
We plan on having better support for the use case of creating on-chain proxies, but the integration from lib back to CLI is currently lacking, specially since there are a few cases that are rather difficult to handle.