The last time I was at work I left early because I was bored.
I can't understand why someone would do this. Who could possibly be bored doing a job?
I have been in this job for a long time. I have been through all possible events.
It is wrong to abandon your job because of boredom. You should make sure your shift is covered before abandoning others working their jobs.
It's fine, I'm planning on explaining it to my boss.
Good, you should let your boss know that you left early and hope that he doesn't fire you. What you're doing is pretty bad, and you shouldn't leave early again.