Management Pack Builder

 View Only
  • 1.  Manually Build an Object?

    Posted Sep 16, 2024 12:54 PM

    I have requests with empty responses (i.e., { "items":[], "totalCount":0 } ).  I know what attributes from these requests I want to use.  I is there a way to manually create an object for an empty request?

    Provided guidance regarding creating unique id(s) is given, I suspect it is possible via the design's JSON file.

    TY



  • 2.  RE: Manually Build an Object?

    Broadcom Employee
    Posted Sep 17, 2024 08:16 AM

    Hi @deanphelps,

    To ensure the security and legitimacy of MPs created with MP Builder, we don't support manual modification of the design's JSON file. A couple ideas:

    1. Ideally, the reference environment should be configured to return the data you need.
    2. If that is not possible, one option would be to create a fake reference environment by writing a custom REST server or using a tool like Wiremock to mimic a real environment and add the attributes you want to the mocked response. You can then change the Source to point at your fake environment to set up your requests and select the desired attributes.

    Best regards,

    Mark