How to use the curve property on addon?

It is not currently possible to create curve mapping properties in the Python API.

However, I have just submitted a patch for that: ⚙ D15824 Python API: support creating Curve Mapping properties (thread here). It may take a while to have this approved and merged in Blender.

In the meantime, you can create a hidden shader or texture which uses a node with a curve mapping (like an RGB or Vector Curve node) and use the curve mapping property from there, e.g. you can display the node’s curve mapping property wherever you want. There is some example in this thread: How can we implement a CurveMapping widget in a script using python api?