Pre- and Post-Processing Logic for CPQ APIs

Each of the CPQ APIs provide an option to write custom pre- and post-processing logic (hooks) to implement custom logic. Pre-hook logic is executed before the API is executed, while post-hook logic executes after the API executes.

Follow these steps to implement pre- and post-hook logic for CPQ APIs:

  1. Write the custom class to implement the pre and post hook.

    Below is a sample.

  2. Create the Interface Implementation.

    When invoking a CPQ API using a VIP, you must also create a custom setting with the same data as the interface implementation. The custom setting name should be the name of the interface implementation and the class should be the class name used in interface implementation.

    For information about creating an interface implementation, see:

    Interface Packages, Types, and Default Implementations

    Working with Implementations

    Add a New Interface Implementation

    For information about custom settings, see Vlocity Triggers.

  3. Make the interface implementation active. For information, see Working with Implementations.