cms functions