I guess you could try using:
No guarantees it would work but I don't see why it should not if you make sure to add 1024 to the event.type before emitting it.
Then in the event evaluation, subtract 1024 from the type again if it's > 1024.
e.g. if you want to emit an ALLEGRO_EVENT_KEY_DOWN, you fill an ALLEGRO_KEYBOARD_EVENT and set the type to (ALLEGRO_EVENT_KEY_DOWN + 1024) and then emit that.
see also (snippet from the allegro source):
/* Function: ALLEGRO_EVENT_TYPE_IS_USER
* 1 <= n < 512 - builtin events
* 512 <= n < 1024 - reserved user events (for addons)
* 1024 <= n - unreserved user events
#define ALLEGRO_EVENT_TYPE_IS_USER(t) ((t) >= 512)
It uses that in the emit user event function.
Of course, you won't be able to fire the key to other applications that way, only your own code will be able to see/use it.