The backend for this project was built as a serverless API using Azure Functions and .NET. All the data is stored in a Cosmos DB collection using the SQL API.
- Install the Azure Functions Core tools for your operating system
- Install the .NET Core SDK. This repo is pinned to use version 2.2.x of the SDK.
- Install Visual Studio Code or Visual Studio Community edition
- Install the C# extension for Visual Studio Code
- Install the Azure Functions for VS Code extension
- Install Postman
Navigate into backend folder
cd /src/LinkyLinkBuild the project
dotnet buildRename the local.settings.sample.json file to local.settings.json
Linux & MacOS
mv local.settings.sample.json local.settings.jsonWindows command line
REN local.settings.sample.json local.settings.jsonUpdate the local.settings.json file with your Application Insights key to the APPINSIGHTS_INSTRUMENTATIONKEY setting. You could also just remove this if you don't want to use Application Inisghts.
Create an a Cosmos DB instance in Azure using the SQL API. Update the local.settings.json file with your Cosmos DB connection string in the LinkLinkConnection settings. This database will initially be empty. If you try out the API with Postman (see below), the collection and sample documents will be created for you automatically. Otherwise it's structure will be created when you create your first list through the frontend.
Start the function via the command line
func startAlternatively, start a debuging session in Visual Studio or Visual Studio Code.
- Start up Postman and import the
theurlist_collection.jsonfile that's in thebackendfolder - Next import the
theurlist_localhost_env.jsonfile. That includes the Localhost environment settings. - Set your environment to
Localhost
- Run
Save Bundleto add some data to Cosmos DB. The structure (collection, documents, etc.) in the database will be created for you if it does not exsist yet. Next runGet bundle for vanity urlto retrieve the entry you just created.
If everything was setup correctly, your should see a response that resembles the following.


