The contract id of keyOrId — accepts both the bare id and the zfa:-prefixed key.
keyOrId
zfa:
static String contractIdOf(String keyOrId) => keyOrId.startsWith(prefix) ? keyOrId.substring(prefix.length) : keyOrId;