REST API - Update file contents on protected branches

I’m developing a tool for changelog generation, tool automates the whole process, together with Github action can maintain the file automaticall.

To manipulate changelog file content I’m using API endpoint and it workes really good but recently I noticed that when the branch is protected by required status checks, it’s impossible to update file contents over API.

Is there any way to manipulate file content at protected branches over API? I would like to avoid force pushing commits, API seems to be a cleaner approach.