Home / Companies / Vonage / Blog / Post Details
Content Deep Dive

How to Send an SMS with .Net 6 Minimal API

Blog post from Vonage

Post Details
Company
Date Published
Author
Matt Hunt
Word Count
1,355
Language
English
Hacker News Points
-
Summary

The new .NET 6 Minimal APIs feature is an exciting addition to the ASP.NET Core framework, allowing for a more lightweight and entry-friendly approach to building web applications. The author of this tutorial demonstrates how to use Minimal APIs to send SMS messages using the Vonage API. The project starts with creating a new Minimal API project using the `dotnet new` command, then adds the necessary NuGet packages and configuration settings. The author shows how to create a simple endpoint that accepts an SMS model, uses the VonageClient to send an SMS message, and implements validation using FluentValidation. The final version of the code can be found on GitHub, along with additional resources for learning more about Minimal APIs.