Blender bone rotation to unreal bone rotation value

I am working on a python script that parses through a Skeleton mesh animation within Blender.

I am trying to get, from Blender, the rotation values that would work in Unreal. I was able to do this for the bone location correctly (it did involve some minor transposing and negating of the x,y,z).

The animation is correct and loads to and from Unreal and Blender (via FBX). But I am unable to make heads or tails of the rotations shown in Blender. Their rendering in 3d space looks the same but the reported values look completely different. I have tried to convert to eular in different ways or use local space vs global space differently to no avail.

Any ideas for the math to turn a Blender rotation into the rotation value shown in Unreal Engine?