you can only do this in diamond, pearl and platinum buy running into the roaming mespiret after you've been to lake verity north of twinleaf town after you have been to the distortion world and captured or defeated giritina in platinum or in diamond and pearl once you've been to speer pillar and caught either dialga or palkia. Once your'e in the cave in lake verity, talk to mespiret, mespiret will roam in random places across the sinnoh region run into one in a random patch of grass it is a 1 out of 8000 chance that when you run into mespiret it will be shiny, so you are better off using action replay to get a shiny mespirit, for heartgold, soulsilver, black and white you can only get a shiny mespiret through action replay or trading with someone who has one.
Chat with our AI personalities
jiroxy ball...
After you beat the elite four and the galactic biulding
You have two chances to catch Mesprit. If you accidentally make it faint both times, you can't catch it anymore. If you made Mesprit faint once, find it, trap it, lower its hp to 1 using false swipe (you should have gotten the TM), let it escape, then encounter it again and use a quick ball.
A Master Ball
You can't catch shiny legendary Pokemon without cheats... sorry