From the Kingdom Hearts Wiki: A world of information not accessible by Gummiship
Vanitas is a Dimension Link for Ventus in Kingdom Hearts Birth by Sleep. Ventus obtains it once he reduces Vanitas to one HP during their battle in the Dive to the Heart, and must use its "Last Word" Finish Command to finish Vanitas off once and for all. The command gauge will only fill when Ventus wins a "clash" with Vanitas. Attacking regularly, as well as using one of the D-Link commands without Vanitas attempting to counter with the same one, will not charge the Command Guage. As it can only be used during this boss fight, it is impossible to level up.
The Vanitas D-Link enables fast, strong attacks using darkness, much like Vanitas's actual fighting style. It also changes Ventus's Shotlock Command to "Dark Link", and allows Ventus to hover in the void left in the Dive to the Heart when the Station was destroyed.