You must have got bruised which presents as black eye( in medical term Ecchymosis
). This purplish discoloration of skin is due to the spreading of blood in subcutaneous space around the eyes. It will take around 10-15 days for it to liquefy and recover.
If your vision is alright and you donot have any pain or sensitivity to light(photophobia
) ,then it's nothing to worry much. Still ruling out any intraocular trauma induced inflammation is always better in any injury
to eye and it's surrounding structures.
So take care.