Press the tilde key ( ~ or \ depending on keyboard layout). Enter Command: Type the command and hit Enter.
add_ship Attack_Moon_Standard
Before executing any commands, you must open the developer console in-game. stellaris gigastructural engineering console commands link