Skip to content

Latest commit

 

History

History
160 lines (109 loc) · 5.53 KB

README.md

File metadata and controls

160 lines (109 loc) · 5.53 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

import shippo

s = shippo.Shippo(
    api_key_header='<YOUR_API_KEY_HERE>',
    shippo_api_version='2018-02-08',
)


res = s.manifests.list()

if res is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
page Optional[int] The page number you want to select
results Optional[int] The number of results to return per page (max 100, default 5)

Response

components.ManifestPaginatedList

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*

create

Creates a new manifest object.

Example Usage

import shippo
from shippo.models import components

s = shippo.Shippo(
    api_key_header='<YOUR_API_KEY_HERE>',
    shippo_api_version='2018-02-08',
)


res = s.manifests.create(request=components.ManifestCreateRequest(
    carrier_account='adcfdddf8ec64b84ad22772bce3ea37a',
    shipment_date='2014-05-16T23:59:59Z',
    address_from=components.AddressCreateRequest(
        country='US',
        name='Shwan Ippotle',
        company='Shippo',
        street1='215 Clayton St.',
        street3='',
        street_no='',
        city='San Francisco',
        state='CA',
        zip='94117',
        phone='+1 555 341 9393',
        email='[email protected]',
        is_residential=True,
        metadata='Customer ID 123456',
        validate=True,
    ),
    transactions=[
        'adcfdddf8ec64b84ad22772bce3ea37a',
    ],
))

if res is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
request components.ManifestCreateRequest ✔️ The request object to use for the request.

Response

components.Manifest

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*

get

Returns an existing manifest using an object ID.

Example Usage

import shippo

s = shippo.Shippo(
    api_key_header='<YOUR_API_KEY_HERE>',
    shippo_api_version='2018-02-08',
)


res = s.manifests.get(manifest_id='<value>')

if res is not None:
    # handle response
    pass

Parameters

Parameter Type Required Description
manifest_id str ✔️ Object ID of the manifest to update

Response

components.Manifest

Errors

Error Type Status Code Content Type
errors.SDKError 4XX, 5XX */*