UrgentOnlineAPI

API change history

Create shipping calculation

Creates shipping calculation

Try it

Request

Request URL

Request headers

  • string

    access token

  • (optional)
    string
    Media type of the body sent to the API.
  • string
    Subscription key which provides access to this API. Found in your Profile.

Request body

{
  "DeliveryPudoPoint": 0,
  "FromLocalityId": 0,
  "ToLocalityId": 0,
  "FromCountyName": "string",
  "FromLocalityName": "string",
  "ToCountyName": "string",
  "ToLocalityName": "string",
  "Parcels": 0,
  "Envelopes": 0,
  "TotalWeight": 0,
  "PriceTableId": 0,
  "ServiceId": 0,
  "ShipmentPayer": 0,
  "DeclaredValue": 0.0,
  "CashRepayment": 0.0,
  "BankRepayment": 0.0,
  "OtherRepayment": "string",
  "PaymentInstrumentId": 0,
  "PaymentInstrumentValue": 0.0,
  "OpenPackage": true,
  "SaturdayDelivery": true,
  "MorningDelivery": true,
  "ParcelCodes": [
    {
      "Type": 0,
      "Weight": 0.0,
      "Length": 0,
      "Width": 0,
      "Height": 0
    }
  ]
}
{
  "required": [
    "Parcels",
    "Envelopes",
    "TotalWeight",
    "ShipmentPayer",
    "DeclaredValue",
    "CashRepayment",
    "BankRepayment",
    "OpenPackage",
    "SaturdayDelivery",
    "MorningDelivery"
  ],
  "type": "object",
  "properties": {
    "DeliveryPudoPoint": {
      "format": "int32",
      "maximum": 9999999,
      "minimum": 0,
      "type": "integer"
    },
    "FromLocalityId": {
      "format": "int32",
      "maximum": 2147483647,
      "minimum": 0,
      "type": "integer"
    },
    "ToLocalityId": {
      "format": "int32",
      "maximum": 2147483647,
      "minimum": 0,
      "type": "integer"
    },
    "FromCountyName": {
      "type": "string"
    },
    "FromLocalityName": {
      "type": "string"
    },
    "ToCountyName": {
      "type": "string"
    },
    "ToLocalityName": {
      "type": "string"
    },
    "Parcels": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "Envelopes": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "TotalWeight": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "PriceTableId": {
      "format": "int32",
      "type": "integer"
    },
    "ServiceId": {
      "format": "int32",
      "type": "integer"
    },
    "ShipmentPayer": {
      "format": "int32",
      "type": "integer"
    },
    "DeclaredValue": {
      "format": "double",
      "maximum": 999999,
      "minimum": 0,
      "type": "number"
    },
    "CashRepayment": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "BankRepayment": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "OtherRepayment": {
      "type": "string"
    },
    "PaymentInstrumentId": {
      "format": "int32",
      "maximum": 5,
      "minimum": 0,
      "type": "integer"
    },
    "PaymentInstrumentValue": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "OpenPackage": {
      "type": "boolean"
    },
    "SaturdayDelivery": {
      "type": "boolean"
    },
    "MorningDelivery": {
      "type": "boolean"
    },
    "ParcelCodes": {
      "type": "array",
      "items": {
        "required": [
          "Type"
        ],
        "type": "object",
        "properties": {
          "Type": {
            "format": "int32",
            "type": "integer"
          },
          "Weight": {
            "format": "double",
            "maximum": 3000,
            "minimum": 0,
            "type": "number"
          },
          "Length": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          },
          "Width": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          },
          "Height": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          }
        }
      }
    }
  }
}
{
  "DeliveryPudoPoint": 0,
  "FromLocalityId": 0,
  "ToLocalityId": 0,
  "FromCountyName": "string",
  "FromLocalityName": "string",
  "ToCountyName": "string",
  "ToLocalityName": "string",
  "Parcels": 0,
  "Envelopes": 0,
  "TotalWeight": 0,
  "PriceTableId": 0,
  "ServiceId": 0,
  "ShipmentPayer": 0,
  "DeclaredValue": 0.0,
  "CashRepayment": 0.0,
  "BankRepayment": 0.0,
  "OtherRepayment": "string",
  "PaymentInstrumentId": 0,
  "PaymentInstrumentValue": 0.0,
  "OpenPackage": true,
  "SaturdayDelivery": true,
  "MorningDelivery": true,
  "ParcelCodes": [
    {
      "Type": 0,
      "Weight": 0.0,
      "Length": 0,
      "Width": 0,
      "Height": 0
    }
  ]
}
{
  "required": [
    "Parcels",
    "Envelopes",
    "TotalWeight",
    "ShipmentPayer",
    "DeclaredValue",
    "CashRepayment",
    "BankRepayment",
    "OpenPackage",
    "SaturdayDelivery",
    "MorningDelivery"
  ],
  "type": "object",
  "properties": {
    "DeliveryPudoPoint": {
      "format": "int32",
      "maximum": 9999999,
      "minimum": 0,
      "type": "integer"
    },
    "FromLocalityId": {
      "format": "int32",
      "maximum": 2147483647,
      "minimum": 0,
      "type": "integer"
    },
    "ToLocalityId": {
      "format": "int32",
      "maximum": 2147483647,
      "minimum": 0,
      "type": "integer"
    },
    "FromCountyName": {
      "type": "string"
    },
    "FromLocalityName": {
      "type": "string"
    },
    "ToCountyName": {
      "type": "string"
    },
    "ToLocalityName": {
      "type": "string"
    },
    "Parcels": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "Envelopes": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "TotalWeight": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "PriceTableId": {
      "format": "int32",
      "type": "integer"
    },
    "ServiceId": {
      "format": "int32",
      "type": "integer"
    },
    "ShipmentPayer": {
      "format": "int32",
      "type": "integer"
    },
    "DeclaredValue": {
      "format": "double",
      "maximum": 999999,
      "minimum": 0,
      "type": "number"
    },
    "CashRepayment": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "BankRepayment": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "OtherRepayment": {
      "type": "string"
    },
    "PaymentInstrumentId": {
      "format": "int32",
      "maximum": 5,
      "minimum": 0,
      "type": "integer"
    },
    "PaymentInstrumentValue": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "OpenPackage": {
      "type": "boolean"
    },
    "SaturdayDelivery": {
      "type": "boolean"
    },
    "MorningDelivery": {
      "type": "boolean"
    },
    "ParcelCodes": {
      "type": "array",
      "items": {
        "required": [
          "Type"
        ],
        "type": "object",
        "properties": {
          "Type": {
            "format": "int32",
            "type": "integer"
          },
          "Weight": {
            "format": "double",
            "maximum": 3000,
            "minimum": 0,
            "type": "number"
          },
          "Length": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          },
          "Width": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          },
          "Height": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          }
        }
      }
    }
  }
}
<UrgentOnlineEntities.Models.ShippingCalculationModel>
  <DeliveryPudoPoint>0</DeliveryPudoPoint>
  <FromLocalityId>0</FromLocalityId>
  <ToLocalityId>0</ToLocalityId>
  <FromCountyName>string</FromCountyName>
  <FromLocalityName>string</FromLocalityName>
  <ToCountyName>string</ToCountyName>
  <ToLocalityName>string</ToLocalityName>
  <Parcels>0</Parcels>
  <Envelopes>0</Envelopes>
  <TotalWeight>0</TotalWeight>
  <PriceTableId>0</PriceTableId>
  <ServiceId>0</ServiceId>
  <ShipmentPayer>0</ShipmentPayer>
  <DeclaredValue>0</DeclaredValue>
  <CashRepayment>0</CashRepayment>
  <BankRepayment>0</BankRepayment>
  <OtherRepayment>string</OtherRepayment>
  <PaymentInstrumentId>0</PaymentInstrumentId>
  <PaymentInstrumentValue>0</PaymentInstrumentValue>
  <OpenPackage>true</OpenPackage>
  <SaturdayDelivery>true</SaturdayDelivery>
  <MorningDelivery>true</MorningDelivery>
  <ParcelCodes>
    <Type>0</Type>
    <Weight>0</Weight>
    <Length>0</Length>
    <Width>0</Width>
    <Height>0</Height>
  </ParcelCodes>
</UrgentOnlineEntities.Models.ShippingCalculationModel>
{
  "required": [
    "Parcels",
    "Envelopes",
    "TotalWeight",
    "ShipmentPayer",
    "DeclaredValue",
    "CashRepayment",
    "BankRepayment",
    "OpenPackage",
    "SaturdayDelivery",
    "MorningDelivery"
  ],
  "type": "object",
  "properties": {
    "DeliveryPudoPoint": {
      "format": "int32",
      "maximum": 9999999,
      "minimum": 0,
      "type": "integer"
    },
    "FromLocalityId": {
      "format": "int32",
      "maximum": 2147483647,
      "minimum": 0,
      "type": "integer"
    },
    "ToLocalityId": {
      "format": "int32",
      "maximum": 2147483647,
      "minimum": 0,
      "type": "integer"
    },
    "FromCountyName": {
      "type": "string"
    },
    "FromLocalityName": {
      "type": "string"
    },
    "ToCountyName": {
      "type": "string"
    },
    "ToLocalityName": {
      "type": "string"
    },
    "Parcels": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "Envelopes": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "TotalWeight": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "PriceTableId": {
      "format": "int32",
      "type": "integer"
    },
    "ServiceId": {
      "format": "int32",
      "type": "integer"
    },
    "ShipmentPayer": {
      "format": "int32",
      "type": "integer"
    },
    "DeclaredValue": {
      "format": "double",
      "maximum": 999999,
      "minimum": 0,
      "type": "number"
    },
    "CashRepayment": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "BankRepayment": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "OtherRepayment": {
      "type": "string"
    },
    "PaymentInstrumentId": {
      "format": "int32",
      "maximum": 5,
      "minimum": 0,
      "type": "integer"
    },
    "PaymentInstrumentValue": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "OpenPackage": {
      "type": "boolean"
    },
    "SaturdayDelivery": {
      "type": "boolean"
    },
    "MorningDelivery": {
      "type": "boolean"
    },
    "ParcelCodes": {
      "type": "array",
      "items": {
        "required": [
          "Type"
        ],
        "type": "object",
        "properties": {
          "Type": {
            "format": "int32",
            "type": "integer"
          },
          "Weight": {
            "format": "double",
            "maximum": 3000,
            "minimum": 0,
            "type": "number"
          },
          "Length": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          },
          "Width": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          },
          "Height": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          }
        }
      }
    }
  }
}
<UrgentOnlineEntities.Models.ShippingCalculationModel>
  <DeliveryPudoPoint>0</DeliveryPudoPoint>
  <FromLocalityId>0</FromLocalityId>
  <ToLocalityId>0</ToLocalityId>
  <FromCountyName>string</FromCountyName>
  <FromLocalityName>string</FromLocalityName>
  <ToCountyName>string</ToCountyName>
  <ToLocalityName>string</ToLocalityName>
  <Parcels>0</Parcels>
  <Envelopes>0</Envelopes>
  <TotalWeight>0</TotalWeight>
  <PriceTableId>0</PriceTableId>
  <ServiceId>0</ServiceId>
  <ShipmentPayer>0</ShipmentPayer>
  <DeclaredValue>0</DeclaredValue>
  <CashRepayment>0</CashRepayment>
  <BankRepayment>0</BankRepayment>
  <OtherRepayment>string</OtherRepayment>
  <PaymentInstrumentId>0</PaymentInstrumentId>
  <PaymentInstrumentValue>0</PaymentInstrumentValue>
  <OpenPackage>true</OpenPackage>
  <SaturdayDelivery>true</SaturdayDelivery>
  <MorningDelivery>true</MorningDelivery>
  <ParcelCodes>
    <Type>0</Type>
    <Weight>0</Weight>
    <Length>0</Length>
    <Width>0</Width>
    <Height>0</Height>
  </ParcelCodes>
</UrgentOnlineEntities.Models.ShippingCalculationModel>
{
  "required": [
    "Parcels",
    "Envelopes",
    "TotalWeight",
    "ShipmentPayer",
    "DeclaredValue",
    "CashRepayment",
    "BankRepayment",
    "OpenPackage",
    "SaturdayDelivery",
    "MorningDelivery"
  ],
  "type": "object",
  "properties": {
    "DeliveryPudoPoint": {
      "format": "int32",
      "maximum": 9999999,
      "minimum": 0,
      "type": "integer"
    },
    "FromLocalityId": {
      "format": "int32",
      "maximum": 2147483647,
      "minimum": 0,
      "type": "integer"
    },
    "ToLocalityId": {
      "format": "int32",
      "maximum": 2147483647,
      "minimum": 0,
      "type": "integer"
    },
    "FromCountyName": {
      "type": "string"
    },
    "FromLocalityName": {
      "type": "string"
    },
    "ToCountyName": {
      "type": "string"
    },
    "ToLocalityName": {
      "type": "string"
    },
    "Parcels": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "Envelopes": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "TotalWeight": {
      "format": "int32",
      "maximum": 9999,
      "minimum": 0,
      "type": "integer"
    },
    "PriceTableId": {
      "format": "int32",
      "type": "integer"
    },
    "ServiceId": {
      "format": "int32",
      "type": "integer"
    },
    "ShipmentPayer": {
      "format": "int32",
      "type": "integer"
    },
    "DeclaredValue": {
      "format": "double",
      "maximum": 999999,
      "minimum": 0,
      "type": "number"
    },
    "CashRepayment": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "BankRepayment": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "OtherRepayment": {
      "type": "string"
    },
    "PaymentInstrumentId": {
      "format": "int32",
      "maximum": 5,
      "minimum": 0,
      "type": "integer"
    },
    "PaymentInstrumentValue": {
      "format": "double",
      "maximum": 9999999,
      "minimum": 0,
      "type": "number"
    },
    "OpenPackage": {
      "type": "boolean"
    },
    "SaturdayDelivery": {
      "type": "boolean"
    },
    "MorningDelivery": {
      "type": "boolean"
    },
    "ParcelCodes": {
      "type": "array",
      "items": {
        "required": [
          "Type"
        ],
        "type": "object",
        "properties": {
          "Type": {
            "format": "int32",
            "type": "integer"
          },
          "Weight": {
            "format": "double",
            "maximum": 3000,
            "minimum": 0,
            "type": "number"
          },
          "Length": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          },
          "Width": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          },
          "Height": {
            "format": "int32",
            "maximum": 600,
            "minimum": 0,
            "type": "integer"
          }
        }
      }
    }
  }
}

Responses

200 OK

Ok

Representations

{
  "BaseCost": 0.0,
  "ExtraKmCost": 0.0,
  "WeightCost": 0.0,
  "InsuranceCost": 0.0,
  "SpecialCost": 0.0,
  "RepaymentCost": 0.0,
  "Subtotal": 0.0,
  "Tax": 0.0,
  "GrandTotal": 0.0
}
{
  "type": "object",
  "properties": {
    "BaseCost": {
      "format": "double",
      "type": "number"
    },
    "ExtraKmCost": {
      "format": "double",
      "type": "number"
    },
    "WeightCost": {
      "format": "double",
      "type": "number"
    },
    "InsuranceCost": {
      "format": "double",
      "type": "number"
    },
    "SpecialCost": {
      "format": "double",
      "type": "number"
    },
    "RepaymentCost": {
      "format": "double",
      "type": "number"
    },
    "Subtotal": {
      "format": "double",
      "type": "number"
    },
    "Tax": {
      "format": "double",
      "type": "number"
    },
    "GrandTotal": {
      "format": "double",
      "type": "number"
    }
  }
}
{
  "BaseCost": 0.0,
  "ExtraKmCost": 0.0,
  "WeightCost": 0.0,
  "InsuranceCost": 0.0,
  "SpecialCost": 0.0,
  "RepaymentCost": 0.0,
  "Subtotal": 0.0,
  "Tax": 0.0,
  "GrandTotal": 0.0
}
{
  "type": "object",
  "properties": {
    "BaseCost": {
      "format": "double",
      "type": "number"
    },
    "ExtraKmCost": {
      "format": "double",
      "type": "number"
    },
    "WeightCost": {
      "format": "double",
      "type": "number"
    },
    "InsuranceCost": {
      "format": "double",
      "type": "number"
    },
    "SpecialCost": {
      "format": "double",
      "type": "number"
    },
    "RepaymentCost": {
      "format": "double",
      "type": "number"
    },
    "Subtotal": {
      "format": "double",
      "type": "number"
    },
    "Tax": {
      "format": "double",
      "type": "number"
    },
    "GrandTotal": {
      "format": "double",
      "type": "number"
    }
  }
}
<UrgentOnlineEntities.SubEntities.ShippingCost>
  <BaseCost>0</BaseCost>
  <ExtraKmCost>0</ExtraKmCost>
  <WeightCost>0</WeightCost>
  <InsuranceCost>0</InsuranceCost>
  <SpecialCost>0</SpecialCost>
  <RepaymentCost>0</RepaymentCost>
  <Subtotal>0</Subtotal>
  <Tax>0</Tax>
  <GrandTotal>0</GrandTotal>
</UrgentOnlineEntities.SubEntities.ShippingCost>
{
  "type": "object",
  "properties": {
    "BaseCost": {
      "format": "double",
      "type": "number"
    },
    "ExtraKmCost": {
      "format": "double",
      "type": "number"
    },
    "WeightCost": {
      "format": "double",
      "type": "number"
    },
    "InsuranceCost": {
      "format": "double",
      "type": "number"
    },
    "SpecialCost": {
      "format": "double",
      "type": "number"
    },
    "RepaymentCost": {
      "format": "double",
      "type": "number"
    },
    "Subtotal": {
      "format": "double",
      "type": "number"
    },
    "Tax": {
      "format": "double",
      "type": "number"
    },
    "GrandTotal": {
      "format": "double",
      "type": "number"
    }
  }
}
<UrgentOnlineEntities.SubEntities.ShippingCost>
  <BaseCost>0</BaseCost>
  <ExtraKmCost>0</ExtraKmCost>
  <WeightCost>0</WeightCost>
  <InsuranceCost>0</InsuranceCost>
  <SpecialCost>0</SpecialCost>
  <RepaymentCost>0</RepaymentCost>
  <Subtotal>0</Subtotal>
  <Tax>0</Tax>
  <GrandTotal>0</GrandTotal>
</UrgentOnlineEntities.SubEntities.ShippingCost>
{
  "type": "object",
  "properties": {
    "BaseCost": {
      "format": "double",
      "type": "number"
    },
    "ExtraKmCost": {
      "format": "double",
      "type": "number"
    },
    "WeightCost": {
      "format": "double",
      "type": "number"
    },
    "InsuranceCost": {
      "format": "double",
      "type": "number"
    },
    "SpecialCost": {
      "format": "double",
      "type": "number"
    },
    "RepaymentCost": {
      "format": "double",
      "type": "number"
    },
    "Subtotal": {
      "format": "double",
      "type": "number"
    },
    "Tax": {
      "format": "double",
      "type": "number"
    },
    "GrandTotal": {
      "format": "double",
      "type": "number"
    }
  }
}

409 Conflict

Conflict

500 Internal Server Error

Internal Server Error

Code samples

@ECHO OFF

curl -v -X POST "https://urgentcargus.azure-api.net/api/ShippingCalculation"
-H "Authorization: "
-H "Content-Type: application/json"
-H "Ocp-Apim-Subscription-Key: {subscription key}"

--data-ascii "{body}" 
using System;
using System.Net.Http.Headers;
using System.Text;
using System.Net.Http;
using System.Web;

namespace CSHttpClientSample
{
    static class Program
    {
        static void Main()
        {
            MakeRequest();
            Console.WriteLine("Hit ENTER to exit...");
            Console.ReadLine();
        }
        
        static async void MakeRequest()
        {
            var client = new HttpClient();
            var queryString = HttpUtility.ParseQueryString(string.Empty);

            // Request headers
            client.DefaultRequestHeaders.Add("Authorization", "");
            client.DefaultRequestHeaders.Add("Ocp-Apim-Subscription-Key", "{subscription key}");

            var uri = "https://urgentcargus.azure-api.net/api/ShippingCalculation?" + queryString;

            HttpResponseMessage response;

            // Request body
            byte[] byteData = Encoding.UTF8.GetBytes("{body}");

            using (var content = new ByteArrayContent(byteData))
            {
               content.Headers.ContentType = new MediaTypeHeaderValue("< your content type, i.e. application/json >");
               response = await client.PostAsync(uri, content);
            }

        }
    }
}	
// // This sample uses the Apache HTTP client from HTTP Components (http://hc.apache.org/httpcomponents-client-ga/)
import java.net.URI;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.client.utils.URIBuilder;
import org.apache.http.impl.client.HttpClients;
import org.apache.http.util.EntityUtils;

public class JavaSample 
{
    public static void main(String[] args) 
    {
        HttpClient httpclient = HttpClients.createDefault();

        try
        {
            URIBuilder builder = new URIBuilder("https://urgentcargus.azure-api.net/api/ShippingCalculation");


            URI uri = builder.build();
            HttpPost request = new HttpPost(uri);
            request.setHeader("Authorization", "");
            request.setHeader("Content-Type", "application/json");
            request.setHeader("Ocp-Apim-Subscription-Key", "{subscription key}");


            // Request body
            StringEntity reqEntity = new StringEntity("{body}");
            request.setEntity(reqEntity);

            HttpResponse response = httpclient.execute(request);
            HttpEntity entity = response.getEntity();

            if (entity != null) 
            {
                System.out.println(EntityUtils.toString(entity));
            }
        }
        catch (Exception e)
        {
            System.out.println(e.getMessage());
        }
    }
}

<!DOCTYPE html>
<html>
<head>
    <title>JSSample</title>
    <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>
</head>
<body>

<script type="text/javascript">
    $(function() {
        var params = {
            // Request parameters
        };
      
        $.ajax({
            url: "https://urgentcargus.azure-api.net/api/ShippingCalculation?" + $.param(params),
            beforeSend: function(xhrObj){
                // Request headers
                xhrObj.setRequestHeader("Authorization","");
                xhrObj.setRequestHeader("Content-Type","application/json");
                xhrObj.setRequestHeader("Ocp-Apim-Subscription-Key","{subscription key}");
            },
            type: "POST",
            // Request body
            data: "{body}",
        })
        .done(function(data) {
            alert("success");
        })
        .fail(function() {
            alert("error");
        });
    });
</script>
</body>
</html>
#import <Foundation/Foundation.h>

int main(int argc, const char * argv[])
{
    NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
    
    NSString* path = @"https://urgentcargus.azure-api.net/api/ShippingCalculation";
    NSArray* array = @[
                         // Request parameters
                         @"entities=true",
                      ];
    
    NSString* string = [array componentsJoinedByString:@"&"];
    path = [path stringByAppendingFormat:@"?%@", string];

    NSLog(@"%@", path);

    NSMutableURLRequest* _request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:path]];
    [_request setHTTPMethod:@"POST"];
    // Request headers
    [_request setValue:@"" forHTTPHeaderField:@"Authorization"];
    [_request setValue:@"application/json" forHTTPHeaderField:@"Content-Type"];
    [_request setValue:@"{subscription key}" forHTTPHeaderField:@"Ocp-Apim-Subscription-Key"];
    // Request body
    [_request setHTTPBody:[@"{body}" dataUsingEncoding:NSUTF8StringEncoding]];
    
    NSURLResponse *response = nil;
    NSError *error = nil;
    NSData* _connectionData = [NSURLConnection sendSynchronousRequest:_request returningResponse:&response error:&error];

    if (nil != error)
    {
        NSLog(@"Error: %@", error);
    }
    else
    {
        NSError* error = nil;
        NSMutableDictionary* json = nil;
        NSString* dataString = [[NSString alloc] initWithData:_connectionData encoding:NSUTF8StringEncoding];
        NSLog(@"%@", dataString);
        
        if (nil != _connectionData)
        {
            json = [NSJSONSerialization JSONObjectWithData:_connectionData options:NSJSONReadingMutableContainers error:&error];
        }
        
        if (error || !json)
        {
            NSLog(@"Could not parse loaded json with error:%@", error);
        }
        
        NSLog(@"%@", json);
        _connectionData = nil;
    }
    
    [pool drain];

    return 0;
}
<?php
// This sample uses the Apache HTTP client from HTTP Components (http://hc.apache.org/httpcomponents-client-ga/)
require_once 'HTTP/Request2.php';

$request = new Http_Request2('https://urgentcargus.azure-api.net/api/ShippingCalculation');
$url = $request->getUrl();

$headers = array(
    // Request headers
    'Authorization' => '',
    'Content-Type' => 'application/json',
    'Ocp-Apim-Subscription-Key' => '{subscription key}',
);

$request->setHeader($headers);

$parameters = array(
    // Request parameters
);

$url->setQueryVariables($parameters);

$request->setMethod(HTTP_Request2::METHOD_POST);

// Request body
$request->setBody("{body}");

try
{
    $response = $request->send();
    echo $response->getBody();
}
catch (HttpException $ex)
{
    echo $ex;
}

?>
########### Python 2.7 #############
import httplib, urllib, base64

headers = {
    # Request headers
    'Authorization': '',
    'Content-Type': 'application/json',
    'Ocp-Apim-Subscription-Key': '{subscription key}',
}

params = urllib.urlencode({
})

try:
    conn = httplib.HTTPSConnection('urgentcargus.azure-api.net')
    conn.request("POST", "/api/ShippingCalculation?%s" % params, "{body}", headers)
    response = conn.getresponse()
    data = response.read()
    print(data)
    conn.close()
except Exception as e:
    print("[Errno {0}] {1}".format(e.errno, e.strerror))

####################################

########### Python 3.2 #############
import http.client, urllib.request, urllib.parse, urllib.error, base64

headers = {
    # Request headers
    'Authorization': '',
    'Content-Type': 'application/json',
    'Ocp-Apim-Subscription-Key': '{subscription key}',
}

params = urllib.parse.urlencode({
})

try:
    conn = http.client.HTTPSConnection('urgentcargus.azure-api.net')
    conn.request("POST", "/api/ShippingCalculation?%s" % params, "{body}", headers)
    response = conn.getresponse()
    data = response.read()
    print(data)
    conn.close()
except Exception as e:
    print("[Errno {0}] {1}".format(e.errno, e.strerror))

####################################
require 'net/http'

uri = URI('https://urgentcargus.azure-api.net/api/ShippingCalculation')

request = Net::HTTP::Post.new(uri.request_uri)
# Request headers
request['Authorization'] = ''
# Request headers
request['Content-Type'] = 'application/json'
# Request headers
request['Ocp-Apim-Subscription-Key'] = '{subscription key}'
# Request body
request.body = "{body}"

response = Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http|
    http.request(request)
end

puts response.body