Apple also offers a battery replacement for the new Magic Keyboard with Touch ID: for $29.
However, as with its predecessors, you can assume that the battery will last as long as the keyboard’s lifespan. If you assume that the battery can be recharged 1000 times and a recharge is necessary every three months – so four times a year – you get 250 years.
Thus, it can be assumed that the battery service is rather supposed to cover special cases, such as defective batteries outside of the warranty, and not necessarily normal wear and tear.
The price is on par with other Apple input products that have integrated batteries. Replacing the internal power storage costs the same for all of them.