if my pr get merged, the easiest way is to configure it via the device page.
https://github.com/home-assistant/core/pull/32108
this is how the event will look like.
(CONF_ROTATE_FROM_SIDE_1, CONF_SIDE_2): {CONF_EVENT: 2001},
(CONF_ROTATE_FROM_SIDE_1, CONF_SIDE_3): {CONF_EVENT: 3001},
(CONF_ROTATE_FROM_SIDE_1, CONF_SIDE_4): {CONF_EVENT: 4001},
(CONF_ROTATE_FROM_SIDE_1, CONF_SIDE_5): {CONF_EVENT: 5001},
(CONF_ROTATE_FROM_SIDE_1, CONF_SIDE_6): {CONF_EVENT: 6001},
(CONF_ROTATE_FROM_SIDE_2, CONF_SIDE_1): {CONF_EVENT: 1002},
(CONF_ROTATE_FROM_SIDE_2, CONF_SIDE_3): {CONF_EVENT: 3002},
(CONF_ROTATE_FROM_SIDE_2, CONF_SIDE_4): {CONF_EVENT: 4002},
(CONF_ROTATE_FROM_SIDE_2, CONF_SIDE_5): {CONF_EVENT: 5002},
(CONF_ROTATE_FROM_SIDE_2, CONF_SIDE_6): {CONF_EVENT: 6002},
(CONF_ROTATE_FROM_SIDE_3, CONF_SIDE_1): {CONF_EVENT: 1003},
(CONF_ROTATE_FROM_SIDE_3, CONF_SIDE_2): {CONF_EVENT: 2003},
(CONF_ROTATE_FROM_SIDE_3, CONF_SIDE_4): {CONF_EVENT: 4003},
(CONF_ROTATE_FROM_SIDE_3, CONF_SIDE_5): {CONF_EVENT: 5003},
(CONF_ROTATE_FROM_SIDE_3, CONF_SIDE_6): {CONF_EVENT: 6003},
(CONF_ROTATE_FROM_SIDE_4, CONF_SIDE_1): {CONF_EVENT: 1004},
(CONF_ROTATE_FROM_SIDE_4, CONF_SIDE_2): {CONF_EVENT: 2004},
(CONF_ROTATE_FROM_SIDE_4, CONF_SIDE_3): {CONF_EVENT: 3004},
(CONF_ROTATE_FROM_SIDE_4, CONF_SIDE_5): {CONF_EVENT: 5004},
(CONF_ROTATE_FROM_SIDE_4, CONF_SIDE_6): {CONF_EVENT: 6004},
(CONF_ROTATE_FROM_SIDE_5, CONF_SIDE_1): {CONF_EVENT: 1005},
(CONF_ROTATE_FROM_SIDE_5, CONF_SIDE_2): {CONF_EVENT: 2005},
(CONF_ROTATE_FROM_SIDE_5, CONF_SIDE_3): {CONF_EVENT: 3005},
(CONF_ROTATE_FROM_SIDE_5, CONF_SIDE_4): {CONF_EVENT: 4005},
(CONF_ROTATE_FROM_SIDE_5, CONF_SIDE_6): {CONF_EVENT: 6005},
(CONF_ROTATE_FROM_SIDE_6, CONF_SIDE_1): {CONF_EVENT: 1006},
(CONF_ROTATE_FROM_SIDE_6, CONF_SIDE_2): {CONF_EVENT: 2006},
(CONF_ROTATE_FROM_SIDE_6, CONF_SIDE_3): {CONF_EVENT: 3006},
(CONF_ROTATE_FROM_SIDE_6, CONF_SIDE_4): {CONF_EVENT: 4006},
(CONF_ROTATE_FROM_SIDE_6, CONF_SIDE_5): {CONF_EVENT: 5006},
(CONF_MOVE, CONF_SIDE_1): {CONF_EVENT: 1000},
(CONF_MOVE, CONF_SIDE_2): {CONF_EVENT: 2000},
(CONF_MOVE, CONF_SIDE_3): {CONF_EVENT: 3000},
(CONF_MOVE, CONF_SIDE_4): {CONF_EVENT: 4000},
(CONF_MOVE, CONF_SIDE_5): {CONF_EVENT: 5000},
(CONF_MOVE, CONF_SIDE_6): {CONF_EVENT: 6000},
(CONF_DOUBLE_TAP, CONF_SIDE_1): {CONF_EVENT: 1001},
(CONF_DOUBLE_TAP, CONF_SIDE_2): {CONF_EVENT: 2002},
(CONF_DOUBLE_TAP, CONF_SIDE_3): {CONF_EVENT: 3003},
(CONF_DOUBLE_TAP, CONF_SIDE_4): {CONF_EVENT: 4004},
(CONF_DOUBLE_TAP, CONF_SIDE_5): {CONF_EVENT: 5005},
(CONF_DOUBLE_TAP, CONF_SIDE_6): {CONF_EVENT: 6006},
(CONF_AWAKE, ""): {CONF_GESTURE: 0},
(CONF_SHAKE, ""): {CONF_GESTURE: 1},
(CONF_FREE_FALL, ""): {CONF_GESTURE: 2},
(CONF_FLIP_90, ""): {CONF_GESTURE: 3},
(CONF_FLIP_180, ""): {CONF_GESTURE: 4},
(CONF_MOVE_ANY, ""): {CONF_GESTURE: 5},
(CONF_DOUBLE_TAP_ANY, ""): {CONF_GESTURE: 6},
(CONF_TURN_CW, ""): {CONF_GESTURE: 7},
(CONF_TURN_CCW, ""): {CONF_GESTURE: 8},