the main API of lpmd