
Image from Pexels
Tagged articles - API
Found 18 articles tagged with API
19
Apr
2020
Combining multiple Swagger API endpoints in a single UI
.NET229 titlesMultiple REST API microservices endpoints in a single Swagger UI
0
Shifting from traditional monolithic application architecture to micorservices can solve bunch of problems and issues monolith application application design approach introduces, but on the other hand it has it's own drawbacks, although number of drawbacks compared to number of problems it solves is a lot greater so it makes sense to take a path in process of moving from monolithic to micorservices. On of the steps to move to micorservices is to physically have your services running as individual processes...read more
08
Jan
2020
Generation Java client libraries for REST service with swagger-gen Azure DevOps
PowerShell24 titlesCompiling and serving MAVEN packages for Java with Azure DevOps using PowerShell
0
Generating client libraries for REST API which are documented with Swagger can significantly reduce product development time, especially on the front-end side. Well documented API can be easily interpreted by various tools to generate language specific libraries which can be then just easily integrated in in the API service consuming application.
Some time ago I wrote an article Stop writing clients in C# for your Web APIs which explains how to use NSwag to generate NuGet packages for Swagger documented Web API REST services and to push them to Azure DevOps Artifact Feed...read more
26
Oct
2019
Ignoring properties from controller action model in Swagger using JsonIgnore
.NET229 titlesExcluding properties from Swagger in controller action input model using Newtonsoft.Json package
0
While designing the REST API, quite often you may find yourself in a situation where the data can be provided from multiple sources, like route, query string or POST/PUT payload. While that might not be a big problem, it may force you to redesign your models and most likely you will end up with keeping your original DTOs but then designing a new model in your application services layer just to have all your data from different sources in one place when you are passing it to the service method.
Resolving multiple sources custom binding
...read more
15
Oct
2019
Increase service resilience using Polly and retry pattern in ASP.NET Core
.NET229 titlesRetry pattern in ASP.NET Core with Polly
0
Whether you are doing micro-services or mid-size monolith applications that do not have to be too distributed, there is a big chance that you will depend on some external HTTP service. Whether it is REST, SOAP or any other type of the response, your application flow depends on it's response.
Sure using queues and event-based communication between services or components will definitely increase the resilience of the application and make more error-proof, it adds additional complexity to the whole solution and sometimes that can be an overhead depending on the application type or the infrastructure you might be limited with.
...read more
27
Aug
2018
Get most visited pages of your website from Google Analytics using C#
.NET229 titlesList most visited website pages from Google analytics in your .NET application code
0
If you have a website like this one with articles and you would like to suggest most visited articles to your visitors, there are few ways to do this. One of them is definitely a custom solution that can track and store count of every visit per page you have, or without any re-inventing of wheel you can just hook to Google Analytics API to pull the data...read more
24
Apr
2017
Google Service Account authentication in .NET
.NET229 titlesAuthenticate app with service account for working with Google services
0
In case you are a .NET developer and you are using Google Cloud platform, eventually your apps or services will have to interact with Google Cloud (GCE) services. Good thing is that complete GCE is exposed through REST API.
Whole authentication is done through OAuth 2.0, but the authentication of website applications and your services which might be running in background on your server is not the same...read more
30
Mar
2015
Recognize links in text content with jQuery
JavaScript31 titlesFind and replace URLs with anchor tags inside the text
0
Very often when you are dealing with content from 3rd party like tweets from Twitter of Facebook posts and comments you might end up with some URL inside the content.
On both Twitter or Facebook or any other social network, links inside text comments are replaces with anchor tags to those URLs. In order to keep the same user experience and make it more useful o your side where you are serving the content from the other party it is recommended that you do the same.
...read more
22
Nov
2014
Testing Facebook apps with special permissions
JavaScript31 titlesHow to make test-able Facebook apps which require special persmissions
0
Social networks are in an expansion and more and more they are becoming part of the applications, especially online applications. Even .NET framework included authentication with social networks built in as an out of the box feature of .NET platform.
However as social networks evolve they are changing mostly in the area of security and user data privacy.
...read more
09
Oct
2014
Getting social network access token from C# backend
.NET229 titlesAcquire Facebook or Google+ access token from C# code
0
Most popular social networks such is Facebook and Google+ are providing authentication for web applications with fancy javascript pop-ups. However this approach might not work in all browsers and most likely not on every device.
For example this approach does not work on iPhone or iPad because browser itself does not allow pop-ups...read more
14
Aug
2014
Using GoogleMaps Directions API to get accurate distance
.NET229 titlesExample of using GoogleMaps Directions API for calculating the distance
0
In situations where distance between two geo coordinates needs to be found most of the people are using mathematical function to do this. However there is a major disadvantage in using this method...read more
31
Jul
2014
Testing mobile website client side functionality on desktop
JavaScript31 titlesDevelopment and testing of mobile websites on desktop
0
Recently I have posted an article about new HTML5 features for mobile devices where some of the new JavaScript APIs are described.
If you decide to apply any of these new cool features on your mobile website you would first want to test them before you publish them on the real website. You can always expose the website to you mobile device and navigate, but it really takes additional time and after 10th time you would really get annoyed by doing this.
...read more
30
Jul
2014
HTML5 JavaScript API for mobile devices
JavaScript31 titlesEmpower website with new HTML5 JavaScript API
0
HTML5 is awesome for desktop websites and believe it or not, even more awesome for mobile devices. In the following article, I'll show you few HTML5 APIs which can be invoked from JavaScript which directly interact with your mobile device, so let's start.
Geolocation API
...read more
11
Jun
2014
Optimized usage of GoogleMaps API
JavaScript31 titlesReferencing GoogleMap API safely on your page
0
GoogleMaps are very useful to show location on your page. It is not a big problem if you have only one map, but in some cases you might have to add few maps on the page.
As many maps you want to display you only need to reference API once...read more
06
Jun
2014
Serving embedded resources through WebAPI in Umbraco
Umbraco CMS25 titlesMake package deployment easy with single file deployment
0
Recently I've deploying GoogleMap Editor package to Umbraco community.
During development I realized that package will have to include script, some html templates, images... I had no problem with that but when it came to actual package build I realized that I will have to deal with bunch of files and even during development, so se some changes which were not dll related I had to restart app by touching web.config.
...read more
22
May
2014
Exposing richtext property from content in Umbraco Web Api
Umbraco CMS25 titlesProblem when exposing richtext property from Umbraco through Web Api
0
Almost every content page in your website will have one richtext property for adding rich content for the page.
This allows you to add Macros so you can render dynamic content inside page content at custom places in the page itself.
...read more
.NET
5
Jun
2022
Using dotnet nuget package vulnerability scan in Azure DevOps build
Listing nuget vulnerabilities and controlling build in Azure DevOps
5
May
2022
Protecting static files in ASP.NET Core using custom middleware
Restricting access to specific static content with middleware in ASP.NET Core
20
Dec
2021
Supporting multiple authentication schemes in asp.net core webapi
Using more than one authentication schemes in webapi projects
12
Dec
2021
Controlling the flow of migrations in EF Core
Altering EF Core migrations execution order
28
Nov
2021
Unit of work pattern with Dapper
Implementing unit of work pattern with Dapper in .NET 5
21
Sep
2021
Adding display name to Enum values
Implementing additional values for Enum items in C#
JavaScript
28
Oct
2018
HTML5 localStorage with expiry with vanilla JavaScript
Using HTML5 localStorage with expiry
8
May
2018
Monitoring DOM changes with JavaScript
Handling DOM changes with plain JavaScript
9
May
2017
Non blocking CSS load on the page
Load external CSS files in an async manner
16
Mar
2017
Serialize html form to JSON without using JQuery
Transform user input from HTML form fields to JSON
17
Jan
2016
Copy text value to clipboard using jQuery
Simple sample of using jQuery to copy value to clipboard
11
Jan
2016
Resize image on the client side with JQuery
Reducing the upload sie by resizing image on the client side
SQL/T-SQL
22
Feb
2022
Select column names with values from SQL Server database
Fetching column names with its value in T-SQL using built in JSON methods
23
May
2020
Identifying opened connections for the specific application in SQL Server
Connection listing queries in SQL Server
3
May
2018
Reading JSON data in T-SQL on SQL Server
Extracting values from JSON string on SQL Server using T-SQL
28
Apr
2016
Create XML/HTML with T-SQL
Generating XML/HTML output in SQL Server
24
Nov
2015
IP address to octets split in TSQL
Split IP addresse into octets in SQL Server
20
Jul
2015
Getting first and last second of the current year, month and day
Using minimum and maximum date time in SQL query
Umbraco CMS
2
Mar
2018
Minify HTML output of your pages
Minification of HTML output using ASP.NET IHttpModule
18
Apr
2015
Generate sitemap.xml on the fly in Umbraco CMS
Simple sitemap.xml Umbraco handler
2
Mar
2015
Accessing UmbracoHelper in HttpHandler request
Working with UmbracoHelper and IPublishedContent in HttpHandler
14
Sep
2014
Same page language switching in Umbraco
Land on the same page in different language in Umbraco using Relations
4
Sep
2014
Getting cropped image the smart way
The way to get cropped image URL with option to load original image too
27
Aug
2014
Fastest way to return JSON result from a controller
Resturn JSON in MVC controller action