The cheap and easy option is to drop the derailleur off the bike, and take it to a big-box hardware store, and in the paint section will be hundreds of colour swatches. Compare until you find something close enough, and ask for a "test pot" that will cost less than a 4 or 10 litre and even a 100 or 200 mL test pot is going to be heaps.
If you want a colour match, there are automotive paint companies that will mix paint to precisely match your sample. I paid $90 for some paint in aerosol cans, 15 years ago. Its not cheap, a new mech would be cheaper.
Personally and honestly? Paint it all one colour and you're sorted. Its not a valuable antique, exact colour doesn't really match.
You have two main options -
- Full disassemble, clean, sand/key, prime, ( sand, paint, wait) ^2, (light-sand, clear-coat, wait) ^2, and finish with some buffing compound, then reassemble and refit. OR
- Drop the chain out, wipe it clean, sand it, mask behind with some cloth/newspaper/cardboard, and put a light coat on from a rattlecan. Remember to spin the jockey wheels so they get coated all round.
As for colour choice, you could go with plain options like:
- Plain flat matt black
- High gloss black
- some mid grey vaguely similar to the original
Or you could get creative
- Paint it the same colour as your frame, bars, saddle, pedals
- ...chrome (actually very hard to do well)
- ...bright white, because I've never seen a white derailleur
- ...mud-coloured so it doesn't ever need cleaning (maybe not)
- ...artistically random - alien acid, blood splatter, or icecream ripple
A third option is a wrap - these tend to work better with large flat areas. You might find book wrap (coverseal) works, or perhaps coloured heatshrink.
Lastly, a water transfer might suit you, putting darn near anything on it. Takes practice to do well and then you have to clearcoat it.
Oh and the null case is do nothing There's little chance of the paint chips causing problems - rust is your biggest danger and that will take years to do anything more than cosmetic.
Good luck and have fun personalising your bike.
Most likely, the derailleur is made of aluminum.
Aluminum parts are typically anodized whenever they have a coating, with the exception of bicycle rims that have to endure such great forces in so rapid manners (one force occurrence per every wheel rotation) that anodizing would be a good place for cracks to start, thus reducing the fatigue life of the component. For this reasons, good rims are not anodized but powder coated. Powder coating is like paint but consists of tiny electrically charged particles that are attracted to the rim and then melted in a hot oven to cause a uniform coating to form on the rim.
Your derailleur doesn't have to endure as great and rapidly occurring forces as bicycle rims, so anodizing works well there.
It is impossible to match the surface look and feel of an anodized part by any paint, either a liquid paint or a powder coating.
I think you will be disappointed by the result.