Suppose you have written a script that creates extra attributes on an object, but they are not being displayed in the Channel Box. Also, their keyframes don’t show up in the Time Slider.
To get the extra attributes displayed in the Channel Box, you need to use the following command on the attributes in your script:
setAttr -edit -keyable true