Learning UBUS need help with custom methods and objects

I am currently learning UBUS and I need an activity to do, but I don't know how to start it. After passing a value to a custom method, it just echoes back. what I need to do in order to accomplish this task.

https://lxr.openwrt.org/source/ubus/examples/server.c
https://lxr.openwrt.org/source/ubus/lua/test.lua

Where i need to place these files and how to process ?