diff --git a/dotnet/SendMessage/Index.cs b/dotnet/SendMessage/Index.cs new file mode 100644 index 00000000..6ada015e --- /dev/null +++ b/dotnet/SendMessage/Index.cs @@ -0,0 +1,50 @@ +using Newtonsoft.Json; +using SendMessageFunction; + +public async Task Main(RuntimeRequest req, RuntimeResponse res) +{ + string? channel = "type"; + string? message = ""; + string? recipient = ""; + string? subject = ""; + object response = true; + object responsemessage = ""; + Dictionary result = new Dictionary(); + + if (string.IsNullOrEmpty(req.Payload)) + { + return res.Json(new() + { + {"success", false}, + {"message", req.Variables} + }); + } + + var payload = JsonConvert.DeserializeObject>(req.Payload); + payload.TryGetValue("type", out channel); + payload.TryGetValue("message", out message); + payload.TryGetValue("receiver", out recipient); + + if (channel == "Discord"){ + result = await DiscordWebhook.SendDiscordMessage(req.Variables, message); + } + else if(channel == "Email"){ + payload.TryGetValue("subject", out subject); + result = await Mail.SendMail(req.Variables, recipient, message, subject); + } + else if(channel == "Twitter"){ + result = await TwitterSender.SendTweet(req.Variables, message); + } + else if(channel == "SMS"){ + result = await SendSmsTwilio.SendSMS(req.Variables, recipient, message); + } + + result.TryGetValue("success", out response!); + result.TryGetValue("message", out responsemessage!); + + return res.Json(new() + { + {"success", response}, + {"message", responsemessage} + }); +} diff --git a/dotnet/SendMessage/README.md b/dotnet/SendMessage/README.md new file mode 100644 index 00000000..6e3e5586 --- /dev/null +++ b/dotnet/SendMessage/README.md @@ -0,0 +1,143 @@ +# 📬 Send Message using a specific channel + +A .NET Cloud Function for sending a message using a specific channel to a receiver. + +Supported channels include, `SMS`, `Email` ,`Disocrd` and `Twitter`. + +## Examples + +### Example input: (Discord) + +```json +{ + "type": "Discord", + "message": "Programming is fun!" +} +``` + +### Example input: (SMS) + +```json +{ + "type": "SMS", + "receiver": "+123456789", + "message": "Programming is fun!" +} +``` + +### Example input: (Email) + +```json +{ + "type": "Email", + "receiver": "user@example.app", + "subject": "Programming is fun!", + "message": "Programming is fun!" +} +``` + +### Example input: (Twitter) + +```json +{ + "type": "Twitter", + "message": "Programming is fun!" +} +``` + +### Example output: (Success) + +```json +{ + "success": true +} +``` + +### Example output: (Failure) + +```json +{ + "success": false, + "message": "Receiver is not a valid email." +} +``` + +## 📝 Variables + +List of variables used by this cloud function: + +### Twilio + +- **TWILIO_ACCOUNT_SID** - Acount SID from Twilio +- **TWILIO_AUTH_TOKEN** - Auth Token from Twilio +- **TWILIO_SENDER** - Sender Phone Number from Twilio + +### Discord + +- **DISCORD_WEBHOOK_URL** - Webhook URL for Discord + +### Mailgun + +- **MAILGUN_API_KEY** - API Key for Mailgun +- **MAILGUN_DOMAIN** - Domain Name from Mailgun + +### Twitter + +- **TWITTER_API_KEY** - API Key for Twitter +- **TWITTER_API_KEY_SECRET** - API Key Secret for Twitter +- **TWITTER_ACCESS_TOKEN** - Access Token from Twitter +- **TWITTER_ACCESS_KEY_SECRET** - Access Token Secret from Twitter + +## 🚀 Deployment + + + +There are two ways of deploying the Appwrite function, both having the same results, but each using a different process. + +### Using CLI + +Make sure you have [Appwrite CLI](https://appwrite.io/docs/command-line#installation) installed, and you have successfully logged into your Appwrite server. To make sure Appwrite CLI is ready, you can use the command `appwrite client --debug` and it should respond with green text `✓ Success`. + +Make sure you are in the same folder as your `appwrite.json` file and run `appwrite deploy function` to deploy your function. You will be prompted to select which functions you want to deploy. + +### Manual Deployment + +Manual deployment has no requirements and uses Appwrite Console to deploy the tag. First, enter the folder of your function. Then, create a tarball of the whole folder and gzip it using the following command. In order to create a tar ball. Enter this command to build the code. +``` +docker run --rm --interactive --tty \ + -e INTERNAL_RUNTIME_ENTRYPOINT=Index.cs \ + --volume $PWD:/usr/code \ + openruntimes/dotnet:v2-6.0 sh \ + /usr/local/src/build.sh +``` +Then +``` +tar -czf code.tar.gz --exclude code.tar.gz . +``` + +After creating `.tar.gz` file, visit Appwrite Console, click on the `Create deployment` button and switch to the `Manual` tab. There, set the `entrypoint` to `Index.cs`, and upload the file we just generated. + +### Executing the function without the Appwrite Console + +After you have built the code with the command above, run the following up command to start a server to listen to your request on your local host. +``` +docker run --rm --interactive --tty \ + -p 3000:3000 \ + -e INTERNAL_RUNTIME_KEY=secret-key \ + -e INTERNAL_RUNTIME_ENTRYPOINT=Index.cs \ + --volume $PWD/code.tar.gz:/tmp/code.tar.gz:ro \ + openruntimes/dotnet:v2-6.0 \ + sh /usr/local/src/start.sh +``` +Your function is now listening on port `3000`, and you can execute it by sending `POST` request with appropriate authorization headers. + +Sample execution using curl +``` +curl -X POST http://localhost:3000/ -d '{"variables": {"DISCORD_WEBHOOK_URL":"YOUR_DISCORD_WEBHOOK_URL"},"payload": "{\"type\": \"Discord\",\"message\": \"Programming is fun!\",}"}' -H "X-Internal-Challenge: secret-key" -H "Content-Type: application/json" +``` + +## 📝 Notes + +- This function is designed for use with Appwrite Cloud Functions. You can learn more about it in [Appwrite docs](https://appwrite.io/docs/functions). +- This example is compatible with C# and .NET. diff --git a/dotnet/SendMessage/SendMessageFunction.csproj b/dotnet/SendMessage/SendMessageFunction.csproj new file mode 100644 index 00000000..07ebcb73 --- /dev/null +++ b/dotnet/SendMessage/SendMessageFunction.csproj @@ -0,0 +1,13 @@ + + + + net7.0 + enable + enable + + + + + + + diff --git a/dotnet/SendMessage/appsettings.Development.json b/dotnet/SendMessage/appsettings.Development.json new file mode 100644 index 00000000..0c208ae9 --- /dev/null +++ b/dotnet/SendMessage/appsettings.Development.json @@ -0,0 +1,8 @@ +{ + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + } +} diff --git a/dotnet/SendMessage/appsettings.json b/dotnet/SendMessage/appsettings.json new file mode 100644 index 00000000..10f68b8c --- /dev/null +++ b/dotnet/SendMessage/appsettings.json @@ -0,0 +1,9 @@ +{ + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + }, + "AllowedHosts": "*" +} diff --git a/dotnet/SendMessage/src/SendDiscordMessage.cs b/dotnet/SendMessage/src/SendDiscordMessage.cs new file mode 100644 index 00000000..618290d4 --- /dev/null +++ b/dotnet/SendMessage/src/SendDiscordMessage.cs @@ -0,0 +1,43 @@ +using System.Text; + + +namespace SendMessageFunction +{ +public class DiscordWebhook{ + public static async Task> SendDiscordMessage(Dictionary variables, string? message) + { + if(message == null) + { + return new Dictionary {{"success", false}, {"message","Missing message"}}; + } + + string webhook = variables["DISCORD_WEBHOOK_URL"]; + + if(webhook == null) + { + return new Dictionary {{"success", false}, {"message","Missing webhook"}}; + } + + try{ + using (HttpClient httpclient = new HttpClient()){ + var contentofmessage = new StringContent( + "{\"content\": \"" + message + "\"}", + Encoding.UTF8, + "application/json" + ); + HttpResponseMessage response = await httpclient.PostAsync(webhook, contentofmessage); + response.EnsureSuccessStatusCode(); + return new Dictionary {{"success" , true}, {"message", "Your message was sent"}}; + } + + } + catch (Exception e) + { + Console.WriteLine(e); + return new Dictionary {{"success", false}, {"message", e.ToString()}}; + } + + +} +} +} \ No newline at end of file diff --git a/dotnet/SendMessage/src/SendMail.cs b/dotnet/SendMessage/src/SendMail.cs new file mode 100644 index 00000000..99418760 --- /dev/null +++ b/dotnet/SendMessage/src/SendMail.cs @@ -0,0 +1,58 @@ +using System.Text; +using System.Net.Http.Headers; + + +namespace SendMessageFunction +{ + +public class Mail +{ + public static async Task> SendMail(Dictionary variables, string? email, string? message, string? subject) + { + if(email == null || message == null || subject == null) + { + return new Dictionary {{"success", false}, {"message","Missing email, subject, or message"}}; + } + + string domain = variables["MAILGUN_DOMAIN"]; + string apiKey = variables["MAILGUN_API_KEY"]; + HttpResponseMessage? response; + + if(domain == null) + { + return new Dictionary {{"success", false}, {"message","Missing Mailgun domain"}}; + } + if(apiKey == null) + { + return new Dictionary {{"success", false}, {"message","Missing Mailgun API key"}}; + } + try + { + using (HttpClient client = new HttpClient()) + { + client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Basic", Convert.ToBase64String(Encoding.ASCII.GetBytes($"api:{apiKey}"))); + + var content = new FormUrlEncodedContent(new Dictionary + { + {"from", ""}, + {"to", email}, + {"subject", subject}, + {"text", message} + }); + + response = await client.PostAsync($"https://api.mailgun.net/v3/{domain}/messages", content); + response.EnsureSuccessStatusCode(); + var responseString = await response.Content.ReadAsStringAsync(); + return new Dictionary {{"success" , true}, {"message", "Your message was sent"}}; + } + + } + catch (Exception e) + { + return new Dictionary {{"success" , false}, {"message" , e.ToString()}}; + } + + + } +} +} \ No newline at end of file diff --git a/dotnet/SendMessage/src/SendSmsTwilio.cs b/dotnet/SendMessage/src/SendSmsTwilio.cs new file mode 100644 index 00000000..0daf0e93 --- /dev/null +++ b/dotnet/SendMessage/src/SendSmsTwilio.cs @@ -0,0 +1,70 @@ +using System.Text; + +namespace SendMessageFunction +{ +public class SendSmsTwilio +{ + public static async Task> SendSMS(Dictionary variables, string? phoneNumber, string? message) + { + if (string.IsNullOrEmpty(phoneNumber)) + { + return new Dictionary {{"success", false} , {"message","No phone number provided"}}; + } + + if (string.IsNullOrEmpty(message)) + { + return new Dictionary {{"success", false} , {"message","No message provided"}}; + } + + string? accountSID = variables.TryGetValue("TWILIO_ACCOUNT_SID", out string? accountSIDValue) ? accountSIDValue : null; + string? authToken = variables.TryGetValue("TWILIO_AUTH_TOKEN", out string? authTokenValue) ? authTokenValue : null; + string? sender = variables.TryGetValue("TWILIO_SENDER", out string? senderValue) ? senderValue : null; + + if (string.IsNullOrEmpty(accountSID)) + { + return new Dictionary {{"success", false}, {"message","Missing Twilio account SID"}}; + } + + if (string.IsNullOrEmpty(authToken)) + { + return new Dictionary {{"success", false}, {"message","Missing Twilio auth token"}}; + } + + if (string.IsNullOrEmpty(sender)) + { + return new Dictionary {{"success", false}, {"message","Missing Twilio sender"}}; + } + + + try + { + using (var httpClient = new HttpClient()) + { + httpClient.DefaultRequestHeaders.Authorization = new System.Net.Http.Headers.AuthenticationHeaderValue("Basic", Convert.ToBase64String(Encoding.ASCII.GetBytes($"{accountSID}:{authToken}"))); + + var values = new Dictionary + { + { "From", sender }, + { "To", phoneNumber }, + { "Body", message } + }; + + var content = new FormUrlEncodedContent(values); + + var response = await httpClient.PostAsync($"https://api.twilio.com/2010-04-01/Accounts/{accountSID}/Messages.json", content); + response.EnsureSuccessStatusCode(); + var responseString = await response.Content.ReadAsStringAsync(); + return new Dictionary {{ "success" , true }, {"message", "Your message was sent" }}; + + } + } + catch (Exception e) + { + Console.WriteLine(e); + return new Dictionary {{ "success", false}, {"message", e.ToString() }}; + } + + + } +} +} \ No newline at end of file diff --git a/dotnet/SendMessage/src/SendTweet.cs b/dotnet/SendMessage/src/SendTweet.cs new file mode 100644 index 00000000..7a28db76 --- /dev/null +++ b/dotnet/SendMessage/src/SendTweet.cs @@ -0,0 +1,61 @@ +using Tweetinvi; +using Tweetinvi.Exceptions; + +namespace SendMessageFunction +{ +public class TwitterSender +{ + public async static Task> SendTweet(Dictionary variables, string? message) + { + if (string.IsNullOrEmpty(message)) + { + return new Dictionary {{"success", false}, {"message","Missing message"}}; + } + + string consumerKey = variables["TWITTER_API_KEY"]; + string consumerSecret = variables["TWITTER_API_KEY_SECRET"]; + string accessToken = variables["TWITTER_ACCESS_TOKEN"]; + string accessTokenSecret = variables["TWITTER_ACCESS_TOKEN_SECRET"]; + + if (string.IsNullOrEmpty(consumerKey)) + { + return new Dictionary {{"success", false}, {"message","Missing Twitter consumer key"}}; + } + + if (string.IsNullOrEmpty(consumerSecret)) + { + return new Dictionary {{"success", false}, {"message","Missing Twitter consumer secret"}}; + } + + if (string.IsNullOrEmpty(accessToken)) + { + return new Dictionary {{"success", false}, {"message","Missing Twitter access token"}}; + } + + if (string.IsNullOrEmpty(accessTokenSecret)) + { + return new Dictionary {{"success", false}, {"message","Missing Twitter access token secret"}}; + } + var client = new TwitterClient(consumerKey, consumerSecret, accessToken, accessTokenSecret); + try { + + await client.Users.GetAuthenticatedUserAsync(); + } + catch (TwitterException e) + { + Console.WriteLine(e); + return new Dictionary {{"success", false}, {"message", e.ToString()}}; + } + try{ + await client.Tweets.PublishTweetAsync(message); + return new Dictionary {{"success", true}, {"message", "tweet was sent!"}}; + } + catch(TwitterException ex) + { + return new Dictionary {{"success", false}, {"message", ex.ToString()}}; + } + + + } +} +} diff --git a/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/.NETCoreApp,Version=v6.0.AssemblyAttributes.cs b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/.NETCoreApp,Version=v6.0.AssemblyAttributes.cs new file mode 100644 index 00000000..ed926950 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/.NETCoreApp,Version=v6.0.AssemblyAttributes.cs @@ -0,0 +1,4 @@ +// +using System; +using System.Reflection; +[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v6.0", FrameworkDisplayName = ".NET 6.0")] diff --git a/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.AssemblyInfo.cs b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.AssemblyInfo.cs new file mode 100644 index 00000000..7ca2aa07 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.AssemblyInfo.cs @@ -0,0 +1,22 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +using System; +using System.Reflection; + +[assembly: System.Reflection.AssemblyCompanyAttribute("wipeAppwriteCollection")] +[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")] +[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] +[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] +[assembly: System.Reflection.AssemblyProductAttribute("wipeAppwriteCollection")] +[assembly: System.Reflection.AssemblyTitleAttribute("wipeAppwriteCollection")] +[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")] + +// Generated by the MSBuild WriteCodeFragment class. + diff --git a/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.AssemblyInfoInputs.cache b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.AssemblyInfoInputs.cache new file mode 100644 index 00000000..918ff517 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.AssemblyInfoInputs.cache @@ -0,0 +1 @@ +de6538ec9db17302c574b743ada13cc8e60448bf diff --git a/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.GeneratedMSBuildEditorConfig.editorconfig b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.GeneratedMSBuildEditorConfig.editorconfig new file mode 100644 index 00000000..50b3a911 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.GeneratedMSBuildEditorConfig.editorconfig @@ -0,0 +1,17 @@ +is_global = true +build_property.TargetFramework = net6.0 +build_property.TargetPlatformMinVersion = +build_property.UsingMicrosoftNETSdkWeb = true +build_property.ProjectTypeGuids = +build_property.InvariantGlobalization = +build_property.PlatformNeutralAssembly = +build_property.EnforceExtendedAnalyzerRules = +build_property._SupportedPlatformList = Linux,macOS,Windows +build_property.RootNamespace = wipeAppwriteCollection +build_property.RootNamespace = wipeAppwriteCollection +build_property.ProjectDir = c:\Users\me\Documents\Code-Day\codeday-labs\dotnet\wipe_appwrite_collection\ +build_property.RazorLangVersion = 6.0 +build_property.SupportLocalizedComponentNames = +build_property.GenerateRazorMetadataSourceChecksumAttributes = +build_property.MSBuildProjectDirectory = c:\Users\me\Documents\Code-Day\codeday-labs\dotnet\wipe_appwrite_collection +build_property._RazorSourceGeneratorDebug = diff --git a/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.GlobalUsings.g.cs b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.GlobalUsings.g.cs new file mode 100644 index 00000000..025530a2 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.GlobalUsings.g.cs @@ -0,0 +1,17 @@ +// +global using global::Microsoft.AspNetCore.Builder; +global using global::Microsoft.AspNetCore.Hosting; +global using global::Microsoft.AspNetCore.Http; +global using global::Microsoft.AspNetCore.Routing; +global using global::Microsoft.Extensions.Configuration; +global using global::Microsoft.Extensions.DependencyInjection; +global using global::Microsoft.Extensions.Hosting; +global using global::Microsoft.Extensions.Logging; +global using global::System; +global using global::System.Collections.Generic; +global using global::System.IO; +global using global::System.Linq; +global using global::System.Net.Http; +global using global::System.Net.Http.Json; +global using global::System.Threading; +global using global::System.Threading.Tasks; diff --git a/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.assets.cache b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.assets.cache new file mode 100644 index 00000000..3b86a587 Binary files /dev/null and b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.assets.cache differ diff --git a/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.csproj.AssemblyReference.cache b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.csproj.AssemblyReference.cache new file mode 100644 index 00000000..6b6d10fd Binary files /dev/null and b/dotnet/wipe_appwrite_collection/obj/Debug/net6.0/wipeAppwriteCollection.csproj.AssemblyReference.cache differ diff --git a/dotnet/wipe_appwrite_collection/obj/project.assets.json b/dotnet/wipe_appwrite_collection/obj/project.assets.json new file mode 100644 index 00000000..94b38923 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/project.assets.json @@ -0,0 +1,138 @@ +{ + "version": 3, + "targets": { + "net6.0": { + "Newtonsoft.Json/13.0.1": { + "type": "package", + "compile": { + "lib/netstandard2.0/Newtonsoft.Json.dll": { + "related": ".xml" + } + }, + "runtime": { + "lib/netstandard2.0/Newtonsoft.Json.dll": { + "related": ".xml" + } + } + } + } + }, + "libraries": { + "Newtonsoft.Json/13.0.1": { + "sha512": "ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==", + "type": "package", + "path": "newtonsoft.json/13.0.1", + "files": [ + ".nupkg.metadata", + ".signature.p7s", + "LICENSE.md", + "lib/net20/Newtonsoft.Json.dll", + "lib/net20/Newtonsoft.Json.xml", + "lib/net35/Newtonsoft.Json.dll", + "lib/net35/Newtonsoft.Json.xml", + "lib/net40/Newtonsoft.Json.dll", + "lib/net40/Newtonsoft.Json.xml", + "lib/net45/Newtonsoft.Json.dll", + "lib/net45/Newtonsoft.Json.xml", + "lib/netstandard1.0/Newtonsoft.Json.dll", + "lib/netstandard1.0/Newtonsoft.Json.xml", + "lib/netstandard1.3/Newtonsoft.Json.dll", + "lib/netstandard1.3/Newtonsoft.Json.xml", + "lib/netstandard2.0/Newtonsoft.Json.dll", + "lib/netstandard2.0/Newtonsoft.Json.xml", + "newtonsoft.json.13.0.1.nupkg.sha512", + "newtonsoft.json.nuspec", + "packageIcon.png" + ] + } + }, + "projectFileDependencyGroups": { + "net6.0": [ + "Newtonsoft.Json >= 13.0.1" + ] + }, + "packageFolders": { + "C:\\Users\\me\\.nuget\\packages\\": {} + }, + "project": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "c:\\Users\\me\\Documents\\codeday-labs\\dotnet\\wipe_appwrite_collection\\wipeAppwriteCollection.csproj", + "projectName": "wipeAppwriteCollection", + "projectPath": "c:\\Users\\me\\Documents\\codeday-labs\\dotnet\\wipe_appwrite_collection\\wipeAppwriteCollection.csproj", + "packagesPath": "C:\\Users\\me\\.nuget\\packages\\", + "outputPath": "c:\\Users\\me\\Documents\\codeday-labs\\dotnet\\wipe_appwrite_collection\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\me\\AppData\\Roaming\\NuGet\\NuGet.Config" + ], + "originalTargetFrameworks": [ + "net6.0" + ], + "sources": { + "C:\\Program Files\\dotnet\\sdk\\7.0.305\\Sdks\\Microsoft.NET.Sdk.Web\\library-packs": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "net6.0": { + "targetAlias": "net6.0", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + } + }, + "frameworks": { + "net6.0": { + "targetAlias": "net6.0", + "dependencies": { + "Newtonsoft.Json": { + "target": "Package", + "version": "[13.0.1, )" + } + }, + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "downloadDependencies": [ + { + "name": "Microsoft.AspNetCore.App.Ref", + "version": "[6.0.19, 6.0.19]" + }, + { + "name": "Microsoft.NETCore.App.Host.win-x64", + "version": "[6.0.19, 6.0.19]" + }, + { + "name": "Microsoft.NETCore.App.Ref", + "version": "[6.0.19, 6.0.19]" + }, + { + "name": "Microsoft.WindowsDesktop.App.Ref", + "version": "[6.0.19, 6.0.19]" + } + ], + "frameworkReferences": { + "Microsoft.AspNetCore.App": { + "privateAssets": "none" + }, + "Microsoft.NETCore.App": { + "privateAssets": "all" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\7.0.305\\RuntimeIdentifierGraph.json" + } + } + } +} \ No newline at end of file diff --git a/dotnet/wipe_appwrite_collection/obj/project.nuget.cache b/dotnet/wipe_appwrite_collection/obj/project.nuget.cache new file mode 100644 index 00000000..b653d829 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/project.nuget.cache @@ -0,0 +1,14 @@ +{ + "version": 2, + "dgSpecHash": "rsnvItsqp/9/q1Vo4fQ5zhCRf/jCq/fGBRaWM3TnyieDMQF4FTatjjRvhN6T15YvY5mrEc586jJMU51gkauvJQ==", + "success": true, + "projectFilePath": "c:\\Users\\me\\Documents\\Code-Day\\codeday-labs\\dotnet\\wipe_appwrite_collection\\wipeAppwriteCollection.csproj", + "expectedPackageFiles": [ + "C:\\Users\\me\\.nuget\\packages\\newtonsoft.json\\13.0.1\\newtonsoft.json.13.0.1.nupkg.sha512", + "C:\\Users\\me\\.nuget\\packages\\microsoft.netcore.app.ref\\6.0.19\\microsoft.netcore.app.ref.6.0.19.nupkg.sha512", + "C:\\Users\\me\\.nuget\\packages\\microsoft.windowsdesktop.app.ref\\6.0.19\\microsoft.windowsdesktop.app.ref.6.0.19.nupkg.sha512", + "C:\\Users\\me\\.nuget\\packages\\microsoft.aspnetcore.app.ref\\6.0.19\\microsoft.aspnetcore.app.ref.6.0.19.nupkg.sha512", + "C:\\Users\\me\\.nuget\\packages\\microsoft.netcore.app.host.win-x64\\6.0.19\\microsoft.netcore.app.host.win-x64.6.0.19.nupkg.sha512" + ], + "logs": [] +} \ No newline at end of file diff --git a/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.dgspec.json b/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.dgspec.json new file mode 100644 index 00000000..f26b2dd6 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.dgspec.json @@ -0,0 +1,89 @@ +{ + "format": 1, + "restore": { + "c:\\Users\\me\\Documents\\Code-Day\\codeday-labs\\dotnet\\wipe_appwrite_collection\\wipeAppwriteCollection.csproj": {} + }, + "projects": { + "c:\\Users\\me\\Documents\\Code-Day\\codeday-labs\\dotnet\\wipe_appwrite_collection\\wipeAppwriteCollection.csproj": { + "version": "1.0.0", + "restore": { + "projectUniqueName": "c:\\Users\\me\\Documents\\Code-Day\\codeday-labs\\dotnet\\wipe_appwrite_collection\\wipeAppwriteCollection.csproj", + "projectName": "wipeAppwriteCollection", + "projectPath": "c:\\Users\\me\\Documents\\Code-Day\\codeday-labs\\dotnet\\wipe_appwrite_collection\\wipeAppwriteCollection.csproj", + "packagesPath": "C:\\Users\\me\\.nuget\\packages\\", + "outputPath": "c:\\Users\\me\\Documents\\Code-Day\\codeday-labs\\dotnet\\wipe_appwrite_collection\\obj\\", + "projectStyle": "PackageReference", + "configFilePaths": [ + "C:\\Users\\me\\AppData\\Roaming\\NuGet\\NuGet.Config" + ], + "originalTargetFrameworks": [ + "net6.0" + ], + "sources": { + "C:\\Program Files\\dotnet\\sdk\\7.0.305\\Sdks\\Microsoft.NET.Sdk.Web\\library-packs": {}, + "https://api.nuget.org/v3/index.json": {} + }, + "frameworks": { + "net6.0": { + "targetAlias": "net6.0", + "projectReferences": {} + } + }, + "warningProperties": { + "warnAsError": [ + "NU1605" + ] + } + }, + "frameworks": { + "net6.0": { + "targetAlias": "net6.0", + "dependencies": { + "Newtonsoft.Json": { + "target": "Package", + "version": "[13.0.1, )" + } + }, + "imports": [ + "net461", + "net462", + "net47", + "net471", + "net472", + "net48", + "net481" + ], + "assetTargetFallback": true, + "warn": true, + "downloadDependencies": [ + { + "name": "Microsoft.AspNetCore.App.Ref", + "version": "[6.0.19, 6.0.19]" + }, + { + "name": "Microsoft.NETCore.App.Host.win-x64", + "version": "[6.0.19, 6.0.19]" + }, + { + "name": "Microsoft.NETCore.App.Ref", + "version": "[6.0.19, 6.0.19]" + }, + { + "name": "Microsoft.WindowsDesktop.App.Ref", + "version": "[6.0.19, 6.0.19]" + } + ], + "frameworkReferences": { + "Microsoft.AspNetCore.App": { + "privateAssets": "none" + }, + "Microsoft.NETCore.App": { + "privateAssets": "all" + } + }, + "runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\7.0.305\\RuntimeIdentifierGraph.json" + } + } + } + } +} \ No newline at end of file diff --git a/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.g.props b/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.g.props new file mode 100644 index 00000000..59fe6cd1 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.g.props @@ -0,0 +1,15 @@ + + + + True + NuGet + $(MSBuildThisFileDirectory)project.assets.json + $(UserProfile)\.nuget\packages\ + C:\Users\me\.nuget\packages\ + PackageReference + 6.6.0 + + + + + \ No newline at end of file diff --git a/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.g.targets b/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.g.targets new file mode 100644 index 00000000..3dc06ef3 --- /dev/null +++ b/dotnet/wipe_appwrite_collection/obj/wipeAppwriteCollection.csproj.nuget.g.targets @@ -0,0 +1,2 @@ + + \ No newline at end of file