Fast answer
Bari Airport to Monopoli or Polignano by train is a two-part arrival decision: first reach Bari Centrale from the airport rail link, then continue on the Adriatic rail line toward the coastal town that should carry the first night. Monopoli is the steadier arrival base for luggage, dinner, and next-day flexibility; Polignano is the sharper choice only when the cliff-town stay is already the point of the trip.
If you only do one thing
Default to Monopoli for a first no-car arrival unless Polignano is already booked or central to the trip. The safer plan is to keep the airport transfer, onward train, check-in, and first dinner as simple as possible, then use Polignano as a focused rail day after the arrival friction is behind you.