Add robust JSON parsing and type checking for GITHUB_CREDENTIALS environment variable, including handling missing, empty, or malformed input before attempting to extract token and user fields.