If you don't have any way to manage these servers in bulk, as in with host groups or with other tools like Ansible to help you automate it, you can use the autoupdate configuration on a host API to trigger updates on OneAgents. You can use the entities API and fetch your hosts first, then call the update API for each host individually with setting as DISABLED (so autoupdates are still disabled) but with the field version populated (so the OneAgent updates to said version).
You can get a list of available OneAgent versions with available OneAgent versions API.
@AntonPineiro PaaS OneAgents are not a subject of auto-update. Those are lightweight OneAgents (in fact code modules) and have to be manually updated. OneAgent in kubernetes is managed by the Dynatrace Operator and thus you manage the updates by configuring the operator - or in the default setting it upgrades OneAgents as soon as it sees a newer default OneAgetn version for the environment.