Tutorial to create an animated IK rig and import into Unity
In Maya: Select Create->Polygon Primitives->Cylinder-> Input Height divisions: 10 Input Cap divisions: 0
Scale the cylinder 4 units to elongate
Create a Skeleton Switch to the Rigging Module
Hit 4 to switch to Wireframe Shading
Select Skeleton->Create Joints Draw a skeleton over your cylinder
Select the cylinder and the parent of the joints in the Outliner (Windows->Outliner)
Select Skin->Bind Skin-> Change Max influences to 3 (default 5) The weighting will be spread across multiple joints. You will need to adjust this based on your geometry, keep it low, 5 is too much.

Animate the Rig Move the time slider over to frame 1 at the bottom of the screen.

Select a joint
Highlight Rotate Z in the Channel Box Use the right mouse key to bring up mini menu, choose Key Selected.
Move the time slider over to frame 120 at the bottom of the screen.
Rotate the joint
Highlight Rotate Z in the Channel Box Use the right mouse key choose Key Selected.
Hit the play arrow on the time slider. 
Note: Maya Tools such as IK Handles will not import into Unity.
Add your Maya File to your scene Select the Maya file in the Assets list Select the Model tab in the Inspector Change the Scale Factor to .3 Uncheck Import Cameras and Lights Hit Apply

Drag your Maya file from the Assets list over to the Hierarchy tab.
Loop the animation Select your Maya Model in Assets Switch to the Rig tab in the Inspector Change Animation Type to Legacy (default was Generic) Hit Apply Switch to the Animation tab Change Wrap Mode to Loop, near the top (default default) Select Add Loop Frame Change Wrap Mode to Loop, near the bottom (default default)
Select the Play arrow

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: Publish WebGL
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

|