Validation point. Callpoints are for external data providers. Not for validating configuration changes.
See ConfD 6.3.1 UG Chapter 9.7. Validating Data in C
If you are interested in the use-case for callpoints, see ConfD 6.3.1 UG Chapter 6.3. Callpoints and Callbacks.
While at it, to be aware of all your options, you may want to learn about the two-phase commit subscriber mechanism that ConfD support and can be used when you need to validated more than the configuration changes, e.g. some external resource such as a HW register. See examples.confd/cdb_subscription/twophase
However for your use-case, a validation point is likely the best solution.
maapi_get_bool_elem(maapi_socket, tctx->thandle, &b_val, "/filter");
validate() in examples.confd/validate/c/more_a_than_b.c
Since your leaf is in another YANG module, include its generated header file, i.e. the generated ns file, for that YANG module.