I am calling an SOAP service from my Azure Function, and for that I need to add reference of System.ServiceModel assembly. I am able to add other dependencies using Nuget, but as this particular assembly is a framework assembly, so not sure how can I add reference of this assembly in my Azure function.
Currently I am getting following compilation error:
error CS0012: The type 'ClientBase<>' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.ServiceModel, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.
Copying that assembly to bin folder using Kudu would be the last thing I would want to try :)
Any suggestions on a better approach for this?
Thanks and Regards,
Nirman
https://learn.microsoft.com/en-us/azure/azure-functions/functions-reference-csharp
You can refer the system assemblies by #r "AssemblyName" directive
public static Task Run(HttpRequestMessage req, TraceWriter log)