Make sure the object follows the AddPlanet ID and not the API ID, I got this mistake at first, having my planet virtually market-less upon start-up.
From a World file.
PlanetAPI nemv2 = system.addPlanet("mytoselle", star, "Mytoselle", "terran", 0, 400, 7000, 365);
Then an Economy file.
{
"starSystem":"Nemvis",
"markets":[
{
"entities":["mytoselle"],
"faction":"PTech",
"size":7,
"startingConditions":[
"terran",
"headquarters",
"military_base",
"military_base",
"population_6",
"organics_complex",
"organics_complex",
"aquaculture",
"aquaculture",
"ore_complex",
"ore_complex",
"ore_complex",
"ore_complex",
"ore_complex",
"ore_refining_complex",
"ore_refining_complex",
"ore_refining_complex",
"ore_refining_complex",
"ore_refining_complex",
"volturnian_lobster_pens",
"light_industrial_complex",
"light_industrial_complex",
"light_industrial_complex",
"light_industrial_complex",
"autofac_heavy_industry",
"autofac_heavy_industry",
"autofac_heavy_industry",
"autofac_heavy_industry",
"cottage_industry",
"shipbreaking_center",
"free_market",
],
},
],
}