
I generated client code with swagger from the appwrite openapi specs. I've bee using it since without issues.
Now i wrote a simple function which creates documents in the database and therefore the code uses the swagger client code which is integrated using a reference to the IO.Swagger.dll.
So I put the .dll in the root directory of the project and edited the reference path in the .csproj file accordingly. Then I put the function files with the .dll in a tarball and tried to deploy it.
Unfortunately it throws an error (type or namespace could not be found) and I dont know how to resolve it after checking paths and doing some trial and error. I had the same problem with Newtonsoft which was also getting referenced locally but since there is a nuget package I could specify that one from the .csproj file and then it was working.
Maybe someone can help I am quite new to such topics and there is very little information out there..

@ilikechicken77 did you add the DLL to the project as a reference through Visual Studio?
Also, can you share your function code once and the function directory's complete file structure?

@Jake I created and tested a sample myself and there is a legitimate issue here.

Can you please share the function archive and I'll see what I can see

Here's the function sample I created to try this: https://github.com/adityaoberai/DllTest-AppwriteFunction

In my function sample, src/TestClassLibrary.dll
just contains the following class:
namespace TestClassLibrary
{
public class Calculation
{
public int Add(int x, int y)
{
return x + y;
}
}
}

I see the problem - we're only processing PackageReference
s at the moment. Please open an issue and we can try include a fix in the next release 👌

Will do in the OpenRuntimes repo 👍

cc: @ilikechicken77

@Jake I've created an issue here: https://github.com/open-runtimes/open-runtimes/issues/168

thx guys I forgot that i posted.. I bypassed the issue by packing my DLL as a nuget package btw.

[SOLVED]Deploying function with .dll reference C#
Recommended threads
- Domain Verification failed
I think i did the step by step well but just not work. When I enter the page I have this error: `Requested host does not match any Subject Alternative Names (S...
- Adding custom domain to Appwrite project
My app is hosted on Vercel on domain todo.velleb.com. On PC, the OAuth logins like GitHub, Discord and Google work and create the account and log in. On mobile ...
- Auth ( OTP Session )
Hi, i would like to ask about OTP session login, may i know is it doable for dynamic/variable for sender,reply-to or not?
