Writing new json format, which specifies ports.