For rotating equipment I do not know of any US code requirements such as API.
The equipment manufactuer usually specifies the hot oil flush requirements for the piping external to the unit.
By the way, I would recommend that you get a speciality contractor to do the work. They have the equipment to do the flushing and the meters necessary to measure the cleaness level.