edit apiagentActive