getting “Object of class WP_Post could not be converted to string” – when it is a string
Magenta is actually correct. $post_ID is a WP_Post object. Your exec code should effectively be using $post_ID->ID. function save_new_post($post_ID) { print_r($post_ID); die(); Returns WP_Post Object ( [ID] => …