Skip to content

Latest commit

 

History

History
169 lines (124 loc) · 14.5 KB

README.md

File metadata and controls

169 lines (124 loc) · 14.5 KB

Manifests

(Manifests)

Overview

A manifest is a single-page document with a barcode that carriers can scan to accept all packages into transit without the need to scan each item individually. They are close-outs of shipping labels of a certain day. Some carriers require manifests to process the shipments.

Manifest Errors

The following codes and messages are the possible errors that may occur when creating Manifests.

Available Operations

  • List - List all manifests
  • Create - Create a new manifest
  • Get - Retrieve a manifest

List

Returns a list of all manifest objects.

Example Usage

using Shippo;
using Shippo.Models.Requests;
using Shippo.Models.Components;

var sdk = new ShippoSDK(
    apiKeyHeader: "<YOUR_API_KEY_HERE>",
    shippoApiVersion: "2018-02-08"
);

var res = await sdk.Manifests.ListAsync(
    page: 1,
    results: 5,
    shippoApiVersion: "2018-02-08"
);

// handle response

Parameters

Parameter Type Required Description Example
Page long The page number you want to select
Results long The number of results to return per page (max 100, default 5)
ShippoApiVersion string Optional string used to pick a non-default API version to use. See our API version guide. 2018-02-08

Response

ManifestPaginatedList

Errors

Error Type Status Code Content Type
Shippo.Models.Errors.SDKException 4XX, 5XX */*

Create

Creates a new manifest object.

Example Usage

using Shippo;
using Shippo.Models.Requests;
using Shippo.Models.Components;
using System.Collections.Generic;

var sdk = new ShippoSDK(
    apiKeyHeader: "<YOUR_API_KEY_HERE>",
    shippoApiVersion: "2018-02-08"
);

var res = await sdk.Manifests.CreateAsync(
    manifestCreateRequest: new ManifestCreateRequest() {
        CarrierAccount = "adcfdddf8ec64b84ad22772bce3ea37a",
        ShipmentDate = "2014-05-16T23:59:59Z",
        Transactions = new List<string>() {
            "adcfdddf8ec64b84ad22772bce3ea37a",
        },
        AddressFrom = ManifestCreateRequestAddressFrom.CreateAddressCreateRequest(
            new AddressCreateRequest() {
                Name = "Shwan Ippotle",
                Company = "Shippo",
                Street1 = "215 Clayton St.",
                Street3 = "",
                StreetNo = "",
                City = "San Francisco",
                State = "CA",
                Zip = "94117",
                Country = "US",
                Phone = "+1 555 341 9393",
                Email = "[email protected]",
                IsResidential = true,
                Metadata = "Customer ID 123456",
                Validate = true,
            }
        ),
    },
    shippoApiVersion: "2018-02-08"
);

// handle response

Parameters

Parameter Type Required Description Example
ManifestCreateRequest ManifestCreateRequest ✔️ Manifest details and contact info.
ShippoApiVersion string Optional string used to pick a non-default API version to use. See our API version guide. 2018-02-08

Response

Manifest

Errors

Error Type Status Code Content Type
Shippo.Models.Errors.SDKException 4XX, 5XX */*

Get

Returns an existing manifest using an object ID.

Example Usage

using Shippo;
using Shippo.Models.Requests;
using Shippo.Models.Components;

var sdk = new ShippoSDK(
    apiKeyHeader: "<YOUR_API_KEY_HERE>",
    shippoApiVersion: "2018-02-08"
);

var res = await sdk.Manifests.GetAsync(
    manifestId: "<id>",
    shippoApiVersion: "2018-02-08"
);

// handle response

Parameters

Parameter Type Required Description Example
ManifestId string ✔️ Object ID of the manifest to update
ShippoApiVersion string Optional string used to pick a non-default API version to use. See our API version guide. 2018-02-08

Response

Manifest

Errors

Error Type Status Code Content Type
Shippo.Models.Errors.SDKException 4XX, 5XX */*