Level up your Twilio API skills in TwilioQuest, an educational game for Mac, Windows, and Linux. Download Now
Build the future of communications.
Start building for free

"net" posts

  • By Layla Porter
    Rainy with a chance of Azure Cloud Rainy with a chance of cloud

    We all have good days and bad days. On a good day, we may be filled with positive thoughts and on a bad day, we may forget that anything was ever positive!

    gif of cartoon animal crying in the rain

    In this post, we will use Twilio to text your positive thoughts and affirmations to an Azure Function and save them in Azure Table Storage. We will then create a timer-based function that will send a random happy thought from the table storage via SMS to your friends.

    This post assumes some basic knowledge of C# and RESTful APIs.

    To get started, we will need:

    Read More
  • By Bryan Hogan
    Polly Fallbacks: The Last Line of Defense in .NET Service-to-Service Communication Polly Fallbacks for Building Resilient .NET Service-to-Service Communication

    Using Polly, the resilience framework for .NET, you can gracefully handle lost packets, thrown exceptions, and failed requests which inevitably make their way into service-to-service communications on the web. Polly provides resilience strategies for your apps through policies such as Retry, WaitAndRetry, and CircuitBreaker, enabling you to implement fault tolerance in your distributed systems in a fluent fashion.

    This post will introduce you to the Fallback policy and demonstrate its use in a straightforward ASP.NET Core 2.1 example. It will guide you in using the Fallback policy to handle failures you cannot recover from: when all else fails, fallback to this last line of defense.

    If you’re not already familiar with Polly, the first post in this series on the Twilio blog introduced Polly, the .NET resilience framework. The second post build on the first and introduced the HttpClientFactory.


    To follow along with this post you need: …

    Read More
  • By AJ Saulsberry
    A New ASP.NET Core School Year A New ASP.NET Core School Year

    As the Labor Day weekend dwindles in the rear-view mirror we’re forced to confront reality: we’ll have to bid farewell to the felicities of summer and gear up for a new school year. It’s a bittersweet ritual of the season.

    For .NET web developers there’s a significant new entry in the course catalog: Microsoft is moving ASP.NET Core 3.0 to general availability. The big announcement is set for September 23rd at .NET Conf 2019.

    Haven’t bought your tickets yet?

    No problem! .NET Conf is virtual this year, so everyone will be attending in the same class of service: no terrorizing cab rides, no standing in long lines, and no taking off your shoes unless you want to get comfortable.

    If you feel the need to share the experience with your fellow techies in meatspace there are local events scheduled around the world. For UK developers, Twilio’s own Layla Porter …

    Read More
  • By Dustin Ewers
    Building A Cloud Native ASP.NET Core Application and Deploying it to Azure Kubernetes Service with Docker 7EUCzPY9JgIdXMFYmG1BWkow-WFFrnyLHtoiBRhdFWRzMC4rqJ1afaZqAR6VyBd8pB9s_XzO9AmmcJMjDeW8j7Zimys2HbbxY5qh5q27hBHVd3o2zJbHw450LnCGAZp3u2gMMVus

    As developers, we mostly focus on building applications. However, building the app is only half the story. To consider things “done,” we need to get that app deployed into the wild where people can use it. In the .NET world, there’s no shortage of ways we can host our apps, but today, I’d like to focus on building cloud native .NET applications.

    In this post, you’ll learn about building cloud native applications in ASP.NET Core. You’ll learn how to design for the cloud, spin up an Azure Kubernetes Service instance, and deploy your application into the cloud. By the end of this post, you’ll have the tools to build and deploy your own cloud native ASP.NET applications.

    What do you mean by “cloud native”?

    “Cloud native” is one of those terms that sounds obvious, but there’s a more specific definition.

    The Cloud Native Computing Foundation defines the term as follows: …

    Read More
  • By Layla Porter
    Test Driven AutoMapper with .NET Core VNcMVOXYfSc2DCoiaq5heVIF6fTmdIPVXG81WxYpM5QG06S-df8fuYYbNjgavC69zPz6U9afsp2RIjnxL0VA0T3M5TwyCqdIpmgXGStZp7NvzSP0utazOyORagpt1LutXk1m21bH

    If you use data in a project then you have most likely had to map one model to another.  Whether you've done that in the constructor, a dedicated method, or used a mapper of some sort, it can be repetitive and tedious.

    AutoMapper, a library for .NET written by Jimmy Bogard, has been around for a while.  It had a revamp to work with .NET Core and Dependency Injection but can still feel a little bit like magic.

    I use AutoMapper for an internal Twilio tool.  I struggled to create valid maps that work without requiring me to map everything manually.

    I found the best way to configure AutoMapper is by writing tests and lettingAutoMapper tell me exactly what I need to configure. Let me show you how that works.

    I have created a solution in this repository that has the AutoMapper NuGet package already installed and all …

    Read More
  • By Thomas Ardal
    Get Real-Time SMS Error Messages from ASP.NET Core Web Apps with elmah.io and Twilio 7z3YSw1j6d2sMHB1qoex_03nAFDteK2w837uLuCbalj-pX_AmNw1glIMHESuyKFzjdLDS5yTAhTpCtNIupPG32mKayiokwgVw2jWAG9MwDDpsB-R68Fsoyk5cC7_8jghr2nhw6TC

    Getting instant notifications when an error happens on a website can mean life and death for a business. The faster developers fix the bug, the fewer users get frustrated with your website. Using elmah.io and Twilio, getting SMS notifications when your ASP.NET Core application starts failing requires nothing more than a few lines of code. In this post, you will learn how.

    elmah.io is a cloud-based error logging and uptime monitoring service for .NET web developers. elmah.io monitors your websites for crashes and outages and alerts you in real time when an event happens.

    You can receive elmah.io alerts through a variety of channels, including Slack and Microsoft Teams, using integrations provided for those and other products. You can also receive alerts by SMS using the elmah.io integration for Twilio. With a Twilio Phone Number you can receive text notifications about your website wherever you have cellular coverage.

    This post …

    Read More
  • By Luce Carter
    Deploying and Running Your First C# Xamarin Mobile App Deploying and Running Your First C# Xamarin Mobile App

    Creating mobile apps with Xamarin involves more than just coding and pressing F5. Since your apps will be running on a mobile operating system like Android or iOS, testing and debugging them requires running them on a device running one of those operating systems or a simulation of a device.

    The first post in this series showed how to get set up and build your first app in Xamarin with C# .NET. This post will show you how to deploy and run your Xamarin app on an iPhone or Android device. You’ll also learn how to deploy and run on iOS and Android emulators. With these techniques you’ll be able to test and debug a single app on a variety of devices and OS versions without needing a stack of phones.


    Visual Studio 2017/2019 for Windows or Visual Studio for Mac

    Mobile development with .NET workload for Visual Studio …

    Read More
  • By Luce Carter
    Building Your First Mobile App with C# .NET and Xamarin Building Your First Mobile App with C# .NET and Xamarin

    Nearly everyone these days has a mobile phone, and most of these are smartphones. Everyone downloads apps, from social media to games to fitness.

    As developers, a lot of you probably think about making an app for your phones. Whether it's just for a laugh, or to solve an actual problem, our curious minds get us thinking.

    In this post you will get an introduction to how you can create mobile apps using C# and Visual Studio, taking advantage of the awesome Xamarin mobile tooling built into Visual Studio.

    Today you will cover the following set of topics:

    • What is Xamarin?
    • What tools will I need?
    • Getting started with the Visual Studio tools for Xamarin
    • Creating a simple counter app
    • Learning more

    What is Xamarin?

    Xamarin is a cross-platform mobile development framework that now ships with Visual Studio 2019 for Windows and Visual Studio for Mac.

    It is a thin …

    Read More
  • By Andrew Lock
    Verifying Phone Number Ownership in ASP.NET Core Identity with Twilio Verify v2 and Razor Pages Copy of Product Template - Verify.png

    ASP.NET Core Identity is a membership system that adds user sign in and user management functionality to ASP.NET Core apps. It includes many features out of the box and has basic support for storing a phone number for a user. By default, ASP.NET Core Identity doesn't try to verify ownership of phone numbers, but you can add that functionality yourself by integrating Twilio’s identity verification features into your application.

    In this post you'll learn how you can prove ownership of a phone number provided by a user using Twilio Verify in an ASP.NET Core application using Razor Pages. This involves sending a code in an SMS message to the provided phone number. The user enters the code received and Twilio confirms whether it is correct. If so, you can be confident the user has control of the provided phone number.

    You typically only confirm phone number ownership once for a …

    Read More
  • By Bryan Hogan
    More Resilient Service-to-Service Communication with Polly and .NET HttpClientFactory Copy of Generic Blog Header 4.png

    Using Polly, the resilience framework for .NET, you can gracefully handle the lost packets, thrown exceptions, and failed requests which inevitably make their way into service-to-service communications on the web. A previous post on the Twilio blog introduced Polly, the .NET resilience framework. This post builds on that knowledge to strengthen your application's interaction with API endpoints.

    The original .NET HttpClient was a convenient way to send and receive HTTP requests and responses on the web, but unless HttpClient was carefully implemented its use could result in socket exhaustion. The release of .NET Core 2.1 introduced HttpClientFactory, which can be instantiated once and used throughout the life of an application.

    This post will show you how to combine HttpClientFactory with Polly to achieve efficient and resilient service-to-service communications. You'll see how you can do it more reliably, conveniently, and with less code than using HttpClient.


    To …

    Read More
  • Newer
    Sign up and start building
    Not ready yet? Talk to an expert.