PIM-1179 : switch locale and scope position in key
PIM-1179 : add some checks and throw new exceptions