Degree of finish is up to you. Minimum is strong wire brushing and rust treatment.
If there is pitting, some people apply bondo like auto body work and sand for a totally smooth surface, but IMO that's overkill for something like this.
Be sure you do that rust inhibitor treatment before painting. Don't rely on the primer to prevent rust.