helpers to import and beautify API scripts
finalize import script