All URIs are relative to https://api-sandbox.sendpro360.pitneybowes.com/shipping
| Method | HTTP request | Description |
|---|---|---|
| cancelPickups | PUT /api/v1/pickups/cancel | Cancel Pickups |
| cancelledPickupDocument | POST /api/v1/pickups/document | Cancelled Pickup Document |
| getPickupDocument | GET /api/v1/pickups/{pickupId}/document | Get Pickup Document |
| getPickups | GET /api/v1/pickups | Get Pickups |
| schedulePickup | POST /api/v1/pickups | Schedule Pickup |
SchedulePickupCancelResponse cancelPickups(schedulePickupCancelRequest, xPBDeveloperPartnerID)
Cancel Pickups
This operation is used to Cancel the scheduled pickup.
// Import classes:
import com.pitneybowes.api360.ApiClient;
import com.pitneybowes.api360.ApiException;
import com.pitneybowes.api360.Configuration;
import com.pitneybowes.api360.auth.*;
import com.pitneybowes.api360.models.*;
import com.pitneybowes.api360.api.PickupsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api-sandbox.sendpro360.pitneybowes.com/shipping");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
PickupsApi apiInstance = new PickupsApi(defaultClient);
SchedulePickupCancelRequest schedulePickupCancelRequest = new SchedulePickupCancelRequest(); // SchedulePickupCancelRequest |
String xPBDeveloperPartnerID = "xPBDeveloperPartnerID_example"; // String | This is the Developer Partner ID. When the developer is the only partner, this field is not required.
try {
SchedulePickupCancelResponse result = apiInstance.cancelPickups(schedulePickupCancelRequest, xPBDeveloperPartnerID);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PickupsApi#cancelPickups");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| schedulePickupCancelRequest | SchedulePickupCancelRequest | ||
| xPBDeveloperPartnerID | String | This is the Developer Partner ID. When the developer is the only partner, this field is not required. | [optional] |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | Pick up cancelled successfully. | - |
| 400 | Invalid request. | - |
| 401 | The request could not be authorized. | - |
| 500 | The request could not be completed due to an internal error. | - |
GetPickupCancelledDocumentResponse cancelledPickupDocument(type, getPickupCancelledDocumentRequest, xPBDeveloperPartnerID)
Cancelled Pickup Document
This operation is used to get receipt for pickup cancellation. The receipt generated is in PDF format. <br> This operation can create receipt for multiple pickups which are cancelled.
// Import classes:
import com.pitneybowes.api360.ApiClient;
import com.pitneybowes.api360.ApiException;
import com.pitneybowes.api360.Configuration;
import com.pitneybowes.api360.auth.*;
import com.pitneybowes.api360.models.*;
import com.pitneybowes.api360.api.PickupsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api-sandbox.sendpro360.pitneybowes.com/shipping");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
PickupsApi apiInstance = new PickupsApi(defaultClient);
String type = "cancelled"; // String | Indicates type of pickup. Supported value is `cancelled`.
GetPickupCancelledDocumentRequest getPickupCancelledDocumentRequest = new GetPickupCancelledDocumentRequest(); // GetPickupCancelledDocumentRequest |
String xPBDeveloperPartnerID = "xPBDeveloperPartnerID_example"; // String | This is the Developer Partner ID. When the developer is the only partner, this field is not required.
try {
GetPickupCancelledDocumentResponse result = apiInstance.cancelledPickupDocument(type, getPickupCancelledDocumentRequest, xPBDeveloperPartnerID);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PickupsApi#cancelledPickupDocument");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| type | String | Indicates type of pickup. Supported value is `cancelled`. | [enum: cancelled] |
| getPickupCancelledDocumentRequest | GetPickupCancelledDocumentRequest | ||
| xPBDeveloperPartnerID | String | This is the Developer Partner ID. When the developer is the only partner, this field is not required. | [optional] |
GetPickupCancelledDocumentResponse
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | The pick up has been cancelled. | - |
| 400 | Invalid request. | - |
| 401 | The request could not be authorized. | - |
| 500 | The request could not be completed due to an internal error. | - |
GetPickupDocument getPickupDocument(pickupId, xPBDeveloperPartnerID)
Get Pickup Document
This operation returns the scheduled pickup or cancellation receipt in PDF format.
// Import classes:
import com.pitneybowes.api360.ApiClient;
import com.pitneybowes.api360.ApiException;
import com.pitneybowes.api360.Configuration;
import com.pitneybowes.api360.auth.*;
import com.pitneybowes.api360.models.*;
import com.pitneybowes.api360.api.PickupsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api-sandbox.sendpro360.pitneybowes.com/shipping");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
PickupsApi apiInstance = new PickupsApi(defaultClient);
String pickupId = "pickupId_example"; // String | It specified the pickupId for which PDF receipt is needed.
String xPBDeveloperPartnerID = "xPBDeveloperPartnerID_example"; // String | This is the Developer Partner ID. When the developer is the only partner, this field is not required.
try {
GetPickupDocument result = apiInstance.getPickupDocument(pickupId, xPBDeveloperPartnerID);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PickupsApi#getPickupDocument");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| pickupId | String | It specified the pickupId for which PDF receipt is needed. | |
| xPBDeveloperPartnerID | String | This is the Developer Partner ID. When the developer is the only partner, this field is not required. | [optional] |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | Pick up document have been fetched. | * X-Pb-Transactionid - The X-PB-TransactionId is unique id for this request. |
| 400 | Invalid request. | - |
| 401 | The request could not be authorized. | - |
| 500 | The request could not be completed due to an internal error. | - |
GetAllPickups getPickups(xPBDeveloperPartnerID, carrier, startDate, endDate, status, page, size)
Get Pickups
This operation is used to view the history of pickups scheduled or cancelled for your packages.
// Import classes:
import com.pitneybowes.api360.ApiClient;
import com.pitneybowes.api360.ApiException;
import com.pitneybowes.api360.Configuration;
import com.pitneybowes.api360.auth.*;
import com.pitneybowes.api360.models.*;
import com.pitneybowes.api360.api.PickupsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api-sandbox.sendpro360.pitneybowes.com/shipping");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
PickupsApi apiInstance = new PickupsApi(defaultClient);
String xPBDeveloperPartnerID = "xPBDeveloperPartnerID_example"; // String | This is the Developer Partner ID. When the developer is the only partner, this field is not required.
String carrier = "carrier_example"; // String | Indicates CarrierID. If not provided, it would show pickups for all the carriers.
String startDate = "startDate_example"; // String | Indicates start date from when you want to see the history. If not provided, it will take today's date.
String endDate = "endDate_example"; // String | Indicates end date till you want to see the pickups history. If not provide, it will take today's date.
String status = "scheduled"; // String | Indicates status of the pickup(schedule or cancel). If not provided, it will show the response for both status.
BigDecimal page = new BigDecimal(78); // BigDecimal | Indicates page number, if not provided page would be 1.
BigDecimal size = new BigDecimal(78); // BigDecimal | Indicates size of records, if not provided size would be 20
try {
GetAllPickups result = apiInstance.getPickups(xPBDeveloperPartnerID, carrier, startDate, endDate, status, page, size);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PickupsApi#getPickups");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| xPBDeveloperPartnerID | String | This is the Developer Partner ID. When the developer is the only partner, this field is not required. | [optional] |
| carrier | String | Indicates CarrierID. If not provided, it would show pickups for all the carriers. | [optional] |
| startDate | String | Indicates start date from when you want to see the history. If not provided, it will take today's date. | [optional] |
| endDate | String | Indicates end date till you want to see the pickups history. If not provide, it will take today's date. | [optional] |
| status | String | Indicates status of the pickup(schedule or cancel). If not provided, it will show the response for both status. | [optional] [enum: scheduled, cancelled] |
| page | BigDecimal | Indicates page number, if not provided page would be 1. | [optional] |
| size | BigDecimal | Indicates size of records, if not provided size would be 20 | [optional] |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | List of pickups. | - |
| 400 | Invalid request. | - |
| 401 | The request could not be authorized. | - |
| 500 | The request could not be completed due to an internal error. | - |
SchedulePickup200Response schedulePickup(schedulePickupRequest, xPBDeveloperPartnerID)
Schedule Pickup
This operation allows to schedule Pickups with USPS, UPS, FedEx and DHLExpress for eligible shipments. <br> Below are four possible combinations for scheduling pickup <br> <br> 1. When request does not specify `pickupSummary` and `shipmentIds`- The system would consider all eligible shipments created in a current day. <br> 2. When request specifies only `shipmentIds`- Pickup will be created for the shipmentIds mentioned <br> 3. When request specifies only `pickupSummary`- Pickup will be created for the pickup details mentioned in the pickupSummary <br> 4. When request specifies both `pickupSummary` and `shipmentIds`- Pickup will be created including details mentioned in both objects.
// Import classes:
import com.pitneybowes.api360.ApiClient;
import com.pitneybowes.api360.ApiException;
import com.pitneybowes.api360.Configuration;
import com.pitneybowes.api360.auth.*;
import com.pitneybowes.api360.models.*;
import com.pitneybowes.api360.api.PickupsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api-sandbox.sendpro360.pitneybowes.com/shipping");
// Configure HTTP bearer authorization: bearerAuth
HttpBearerAuth bearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("bearerAuth");
bearerAuth.setBearerToken("BEARER TOKEN");
PickupsApi apiInstance = new PickupsApi(defaultClient);
SchedulePickupRequest schedulePickupRequest = new SchedulePickupRequest(); // SchedulePickupRequest |
String xPBDeveloperPartnerID = "xPBDeveloperPartnerID_example"; // String | This is the Developer Partner ID. When the developer is the only partner, this field is not required.
try {
SchedulePickup200Response result = apiInstance.schedulePickup(schedulePickupRequest, xPBDeveloperPartnerID);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling PickupsApi#schedulePickup");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| schedulePickupRequest | SchedulePickupRequest | ||
| xPBDeveloperPartnerID | String | This is the Developer Partner ID. When the developer is the only partner, this field is not required. | [optional] |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | The Pick up has been created successfully. | - |
| 400 | Invalid request. | - |
| 401 | The request could not be authorized. | - |
| 500 | The request could not be completed due to an internal error. | - |