How to calculate Real time Shipping charges Using API

Shopify Partner
37 0 3


I am working on Shopify's shipping charges calculation. I do not want to use the app so I tried Shopify's default shipping zone settings
In Shopify's default shipping zone settings. The UK is present but Northern Ireland is not present and I want to add $10 if a user is placing an order for the Northern Ireland location and not for the entire UK or outside of Northern Ireland. But I am unable to do this here so I decided to move with the code and API.

Can anyone please let me know which API I can use and how may I achieve this functionality. I do not want to use any app.

How the shipping charges can be added on the basis of the location via API?

I am stuck on it. can anyone please help or advise what can be done?

Thanks for your help.