bitScry

  • Home
  • About
  • Blog
  • Contact

API

About this site

This is a blog to help me remember some of the coding challenges I’ve faced and hopefully help others out if they’re suffering the same problems.

Recent Posts
  • Cloning a Private Repository in a GitHub Workflow
  • Installing Multiple .NET Versions in GitHub Actions
  • Serving Images from Blob Storage in an Azure Function
  • Redis Caching in .NET
  • Passing Environment Variables From Docker to .NET Web App
Tag Cloud

.NET .NET Core AAD API ASP.NET Core Authentication Azure Azure Active Directory Azure Function Azure Storage Blob Bootstrap C# Console Application CSS DataTable Dependency Injection Dictionary Entity Framework Enum Extension Google GZip HTML Image JavaScript jQuery JSON List Middleware MVC Newtonsoft RestSharp Serilog SQL SSDT SSIS Stored Procedure Stream Table Table Storage Test Web App Web Application WordPress

Programming

Using IdentityServer4 for API Authentication

IdentityServer4 is an OpenID Connect and OAuth 2.0 framework for ASP.NET Core 2 which can be used to manage authentication for web applications. In my case I wanted to set up OAuth 2.0 authentication using a SQL backend for an API, this isn’t too tricky when you know what you’re Read more…

By Shinigami, 5 years13 December 2018 ago
Azure

Accessing the Bing Ads API in a Console Application

Although there’s plenty of documentation by Microsoft on how to use their Bing Ads API the documentation on how to initially connect to it seems a bit fragmented so this is an attempt to summarize all the steps required to grant a console application access to the API. Most of Read more…

By Shinigami, 5 years5 December 2018 ago
Programming

Bing Image Search API

Bing Image Search API The Image Search API lets you query the Bing search engine for a list of relevant images, in order to access it you need a cognitive services API key obtained from the Azure portal. The API endpoint can be accessed directly by structuring queries using the Read more…

By Shinigami, 5 years2 July 2018 ago
Programming

ASP.NET Core API Routing

When creating a new API controller in a Web Application the template code created if you choose to include read/write actions provides a good overview of how to pass values through to the API methods and return results. The template assumes that the controller only has one action per HTTP Read more…

By Shinigami, 5 years21 June 2018 ago
Programming

Single or Array JSON Converter

Often APIs will have actions where one of the parameters can be either a single object or an array of objects, in order to correctly serialize objects to JSON which can be accepted by the API a custom JsonConverter is needed. This code is borrowed from this stack overflow article. Read more…

By Shinigami, 6 years31 August 2017 ago
Programming

Calling APIs and Stored Procedures From SSIS

The script tasks in SSIS can be a bit limited in what they allow you to do as NuGet packages can’t be used and not all class libraries seem to be available. Given that, below is my code for calling an external API and logging it’s results to a SQL Read more…

By Shinigami, 6 years6 July 2017 ago
Programming

ASP.NET 5 Middleware

The ability to create your own middleware comes in pretty handy when creating MVC 6 APIs as it allows the inspection and processing of the requests/responses flowing into and out of the application. A few of the most useful ones I’ve used are below, a good guide to using middleware Read more…

By Shinigami, 7 years22 February 2017 ago
Programming

API .Net Core XML Ingestion

What I need to do here is to create an API that can authenticate and ingest an XML POST request, saving the provided data into a SQL database and returning a relevant HTML status code. Unfortunately this wasn’t quite as easy as I’d anticipated as the XML data will be Read more…

By Shinigami, 7 years20 October 2016 ago

Posts navigation

Previous 1 2
  • Facebook
  • Twitter
  • Instagram
  • Email
Hestia | Developed by ThemeIsle