Shippo 5.0.0-beta.3
See the version list below for details.
dotnet add package Shippo --version 5.0.0-beta.3
NuGet\Install-Package Shippo -Version 5.0.0-beta.3
<PackageReference Include="Shippo" Version="5.0.0-beta.3" />
paket add Shippo --version 5.0.0-beta.3
#r "nuget: Shippo, 5.0.0-beta.3"
// Install Shippo as a Cake Addin #addin nuget:?package=Shippo&version=5.0.0-beta.3&prerelease // Install Shippo as a Cake Tool #tool nuget:?package=Shippo&version=5.0.0-beta.3&prerelease
Shippo
SDK Example Usage
Example
using Shippo;
using Shippo.Models.Components;
using Shippo.Models.Requests;
var sdk = new ShippoSDK(
apiKeyHeader: "<YOUR_API_KEY_HERE>",
shippoApiVersion: "2018-02-08");
var res = await sdk.Addresses.ListAsync(
page: 1,
results: 5,
shippoApiVersion: "2018-02-08");
// handle response
Global Parameters
Global Parameters
A parameter is configured globally. This parameter may be set on the SDK client instance itself during initialization. When configured as an option during SDK initialization, This global value will be used as the default on the operations that use it. When such operations are called, there is a place in each to override the global value, if needed.
For example, you can set SHIPPO-API-VERSION
to "2018-02-08"
at SDK initialization and then you do not have to pass the same value on calls to operations like List
. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration.
Available Globals
The following global parameter is available.
Name | Type | Required | Description |
---|---|---|---|
shippoApiVersion | string | String used to pick a non-default API version to use |
Example
using Shippo;
using Shippo.Models.Components;
using Shippo.Models.Requests;
var sdk = new ShippoSDK(
apiKeyHeader: "<YOUR_API_KEY_HERE>",
shippoApiVersion: "2018-02-08");
var res = await sdk.Addresses.ListAsync(
page: 1,
results: 5,
shippoApiVersion: "2018-02-08");
// handle response
Error Handling
Handling errors in this SDK should largely match your expectations. All operations return a response object or thow an exception. If Error objects are specified in your OpenAPI Spec, the SDK will raise the appropriate type.
Error Object | Status Code | Content Type |
---|---|---|
Shippo.Models.Errors.InitiateOauth2SigninResponseBody | 400 | application/json |
Shippo.Models.Errors.InitiateOauth2SigninCarrierAccountsResponseBody | 401 | application/json |
Shippo.Models.Errors.InitiateOauth2SigninCarrierAccountsResponseResponseBody | 404 | application/json |
Shippo.Models.Errors.SDKException | 4xx-5xx | / |
Example
using Shippo;
using Shippo.Models.Components;
using System;
using Shippo.Models.Errors;
using Shippo.Models.Requests;
var sdk = new ShippoSDK(
apiKeyHeader: "<YOUR_API_KEY_HERE>",
shippoApiVersion: "2018-02-08");
InitiateOauth2SigninRequest req = new InitiateOauth2SigninRequest() {
CarrierAccountObjectId = "<value>",
RedirectUri = "http://fine-cummerbund.biz",
};
try
{
var res = await sdk.CarrierAccounts.InitiateOauth2SigninAsync(req);
// handle response
}
catch (Exception ex)
{
if (ex is InitiateOauth2SigninResponseBody)
{
// handle exception
}
else if (ex is InitiateOauth2SigninCarrierAccountsResponseBody)
{
// handle exception
}
else if (ex is InitiateOauth2SigninCarrierAccountsResponseResponseBody)
{
// handle exception
}
else if (ex is Shippo.Models.Errors.SDKException)
{
// handle exception
}
}
Server Selection
Select Server by Index
You can override the default server globally by passing a server index to the serverIndex: number
optional parameter when initializing the SDK client instance. The selected server will then be used as the default on the operations that use it. This table lists the indexes associated with the available servers:
# | Server | Variables |
---|---|---|
0 | https://api.goshippo.com |
None |
Override Server URL Per-Client
The default server can also be overridden globally by passing a URL to the serverUrl: str
optional parameter when initializing the SDK client instance. For example:
Authentication
Per-Client Security Schemes
This SDK supports the following security scheme globally:
Name | Type | Scheme |
---|---|---|
APIKeyHeader |
apiKey | API key |
To authenticate with the API the APIKeyHeader
parameter must be set when initializing the SDK client instance. For example:
using Shippo;
using Shippo.Models.Components;
using Shippo.Models.Requests;
var sdk = new ShippoSDK(
apiKeyHeader: "<YOUR_API_KEY_HERE>",
shippoApiVersion: "2018-02-08");
var res = await sdk.Addresses.ListAsync(
page: 1,
results: 5,
shippoApiVersion: "2018-02-08");
// handle response
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net6.0
- newtonsoft.json (>= 13.0.3)
- nodatime (>= 3.1.9)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Shippo:
Package | Downloads |
---|---|
FenixAlliance.ABS.Integrations.Shippo
Application Component for the Alliance Business Suite. |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated | |
---|---|---|---|
5.0.0-beta.7 | 107 | 10/10/2024 | |
5.0.0-beta.4 | 462 | 7/15/2024 | |
5.0.0-beta.3 | 40 | 7/8/2024 | |
5.0.0-beta.2 | 109 | 6/26/2024 | |
5.0.0-beta.1 | 54 | 6/17/2024 | |
4.0.2 | 2,371 | 6/21/2024 | |
4.0.1 | 133 | 6/17/2024 | |
4.0.0 | 218 | 6/7/2024 | |
4.0.0-beta.1 | 57 | 6/7/2024 | |
3.3.0 | 49,499 | 2/1/2022 | |
3.2.0 | 5,916 | 4/26/2021 | |
3.1.1 | 848 | 4/9/2021 | |
3.1.0 | 450 | 3/29/2021 | |
3.0.0 | 903 | 1/20/2021 | |
2.1.15 | 6,967 | 7/30/2020 | |
2.1.14 | 1,172 | 4/17/2020 | |
2.1.13 | 12,040 | 10/29/2018 | |
2.1.12 | 833 | 10/23/2018 | |
2.1.11 | 806 | 10/23/2018 | |
2.1.10 | 1,973 | 9/7/2018 | |
2.1.8 | 2,411 | 9/7/2018 | |
2.1.2 | 16,850 | 10/9/2017 | |
2.1.1 | 1,194 | 9/13/2017 | |
2.1.0 | 1,369 | 9/7/2017 | |
2.0.2 | 11,256 | 5/24/2017 | |
1.5.7 | 2,569 | 11/17/2016 | |
1.5.6 | 1,195 | 11/17/2016 | |
1.5.5 | 1,284 | 11/11/2016 | |
1.5.4 | 3,306 | 11/3/2016 | |
1.5.3 | 1,735 | 11/2/2016 | |
1.5.0 | 1,238 | 10/26/2016 | |
1.4.4 | 15,232 | 9/16/2015 | |
1.4.3 | 1,143 | 9/16/2015 | |
1.4.2 | 1,176 | 7/8/2015 | |
1.4.0 | 1,180 | 3/26/2015 | |
1.0.3 | 1,097 | 3/26/2015 | |
1.0.2 | 1,101 | 3/26/2015 | |
1.0.1 | 1,088 | 3/26/2015 | |
1.0.0 | 1,359 | 3/26/2015 |