add debug to api header
internally resolve as necessary