Catalyzes both the synthesis of cyclic ADP-beta-D-ribose (cADPR) from NAD(+), and its hydrolysis to ADP-D-ribose (ADPR) (PubMed:7805847). Cyclic ADPR is known to serve as an endogenous second messenger that elicits calcium release from intracellular stores, and thus regulates the mobilization of intracellular calcium (Probable). May be involved in pre-B-cell growth (Probable). {ECO:0000269|PubMed:7805847, ECO:0000305|PubMed:11866528, ECO:0000305|PubMed:7805847, ECO:0000305|PubMed:8202488}. This is the function of ENSG00000109743 (BST1, bone marrow stromal cell antigen 1).