API Designer Http exceptions (and reference files)

We're working with the API designer to set up custom endpoints and we would like to send exceptions with HTTP codes.

In the samples there is a file that talks about it  (Modules\QBM\dvd\AddOn\ApiSamples\Sdk05_Misc\HttpStatusCodes.cs)  and it uses the HttpException from System.web. 

However, I am unable to use that class via the API designer. The compiler gives me "does not exist in the namespace" and so far I have been unable to determine how to include a reference to the dll in a way that will allow me to compile. 

My next thought was to use the imxclient tool to try to include the dll vial the /apidll parameter but I am not able to form a connection it likes. 

Any chance you can help point me in the right direction?

-Aaron H

  • Hello! Thank you for your question.                                                                                                                                                                                                                                                                      Please perform the following steps:

    Open the affected API project in API Designer. You will have to create an Assembly Reference here. Please go on Compilation Settings > Object in Extension > Add new extension in module “CCC” > Assembly reference. In the filed “Referenced assembly” add the Assembly-Reference “System.Web.dll”. Please save your project.                                                                                                               

    Hope it helps!