Hold For Pickup Facility Information API
USPS Web Tools™
Application Programming Interface
Guía del usuario
Version 6.1 (7/13/2023)
Índice
2.0 Hold for Pickup Facility Information API
This document contains a Reference Guide to the Hold for Pickup Facility Information API. See the Developer's Guide to learn the administrative process for gaining access to the Web Tools APIs as well as the basic mechanism for calling the APIs and processing the results.
Nota: The Request Parameter sections present the XML input tags for generating live requests along with the restrictions on the values allowed. An error message will be returned if an incorrect value is entered. Also, be aware of the maximum character amounts allowed for some tags. If the user enters more than those amounts, an error will not be generated. The Web Tool will simply pass in the characters up to the maximum amount allowed and disregard the rest. This is important since the resulting value could prevent a correct response.
When building the XML request, pay particular attention to the order and case for tags. An error message will be returned if an incorrect value is entered. Remember that all data and attribute values in this document are for illustration purposes and are to be replaced by your actual values. For instance, a line of sample code may be:
<TrackID> EJ123456780US </TrackID>
In this instance, you will replace “EJ123456780US” with the tracking ID for the package.
For information on registering and getting started with Web Tools, please refer to the Step-By-Step guide found on the Technical Documentation. If you need further assistance, please contact the USPS Internet Customer Care Center (ICCC) https://Emailus.usps.com/.
Hold For Pickup service is available at approximately 31,000 USPS locations. This API will list US Postal Service Facilities where Hold-For-Pickup service is available. The response includes facilities based on ZIP code (five or nine digit) or City/State up to a maximum number of locations. Shipments are available for pickup by the recipient or a designee at the designated Hold For Pickup location by either 10 a.m., noon, or 3 p.m., based on the service standard associated with the mail class. Hold For Pickup shipments are sent to a designated Hold For Pickup location, such as a Post Office, where the shipment can be picked up within five calendar days. Hold For Pickup service lets customers pick up shipments when it is convenient for them, with the assurance that their shipments are held safely and securely.
Nota: Hold For Pickup is not available for International or APO/FPO destinations.
Nota: This API offers the ability to lookup Hold For Pickup Facilities, not create Hold For Pickup labels themselves.
Scheme |
Host |
Path |
API |
XML |
https:// |
secure.shippingapis.com |
/ShippingAPI.dll? |
API=HFPFacilityInfo |
&XML=(see below) |
Tag Name |
Occurs |
Descripción |
Tipo |
Validation |
HFPFacilityInfoRequest |
Obligatorio |
API=HFPFacilityInfo |
(Alias) |
|
HFPFacilityInfoRequest / USERID |
Obligatorio |
This attribute specifies your Web Tools user ID. See the Developer's Guide for information on obtaining your USERID. Por Ejemplo: USERID="XXXXXXX" |
NMTOKEN |
|
HFPFacilityInfoRequest / PASSWORD |
Optional |
This attribute specifies your Web Tools password. See the Developer's Guide for information on your Password. Por Ejemplo: PASSWORD="XXXXXXX" |
NMTOKEN |
|
HFPFacilityInfoRequest / PickupCity |
Obligatorio |
Either City/State or ZIP code must be specified. When only city and state are provided, all pickup facilities with addresses within that city and state will be returned.
|
String |
minLength=1 |
HFPFacilityInfoRequest / PickupState |
Obligatorio |
Either City/State or ZIP code must be specified.
|
String |
minLength=2 maxLength=2 |
HFPFacilityInfoRequest / PickupZIP |
Obligatorio |
Either City/State or ZIP code must be specified. When PickupZIP provided without PickupZIP4, all pickup facilities that service that ZIP code are returned.
|
String |
minLength=0 |
HFPFacilityInfoRequest / PickupZIP4 |
Obligatorio |
If PickupZIP is specified, then PickupZIP4 may also be specified. This will match to a single pickup facility with the given nine-digit ZIP code.
|
String |
minLength=0 |
HFPFacilityInfoRequest / Service |
Optional |
For future use. May be omitted. |
String |
default=EXPRESS |
HFPFacilityInfoRequest |
Obligatorio |
|
(Alias) |
|
Request: HFPFacilityInfo <HFPFacilityInfoRequest USERID="XXXXXXXXX" PASSWORD=""> <PickupCity /> <PickupState/> <PickupZIP>33952</PickupZIP> <PickupZIP4 /> <Service /> </HFPFacilityInfoRequest> |
Tag Name |
Occurs |
Descripción |
Tipo |
Validation |
HFPFacilityInfoResponse |
Obligatorio |
|
(Alias) |
|
HFPFacilityInfoResponse / PickupCity |
Obligatorio |
The criteria used to obtain the facility list is echoed back here. Either City/State or ZIP code (five or nine digit). |
String |
|
HFPFacilityInfoResponse / PickupState |
Obligatorio |
The criteria used to obtain the facility list is echoed back here. Either City/State or ZIP code (five or nine digit). |
String |
|
HFPFacilityInfoResponse / PickupZIP |
Obligatorio |
The criteria used to obtain the facility list is echoed back here. Either City/State or ZIP code (five or nine digit). |
String |
|
HFPFacilityInfoResponse / PickupZIP4 |
Obligatorio |
The criteria used to obtain the facility list is echoed back here. Either City/State or ZIP code (five or nine digit). |
String |
|
HFPFacilityInfoResponse / Service |
Optional |
Echoed back from request. |
String |
|
HFPFacilityInfoResponse / Facility |
Optional repeating up to 50 times |
Facility addresses are returned in no specific order. If none are returned, then no facilities matched the criteria given in the request. If there are more than 50 facilities found, the first 50 will be returned along with a maximum-exceeded advisory in the LogMessage tag. |
(Group) |
|
HFPFacilityInfoResponse / Facility / FacilityID |
Obligatorio |
ID of Pickup Facility. |
String |
|
HFPFacilityInfoResponse / Facility / FacilityName |
Obligatorio |
Name of Pickup Facility |
String |
|
HFPFacilityInfoResponse / Facility / FacilityAddress |
Obligatorio |
Pickup Facility Address |
String |
|
HFPFacilityInfoResponse / Facility / FacilityCity |
Obligatorio |
Pickup Facility City |
String |
|
HFPFacilityInfoResponse / Facility / FacilityState |
Obligatorio |
Pickup Facility State |
String |
|
HFPFacilityInfoResponse / Facility / FacilityZIP |
Obligatorio |
Pickup Facility ZIP Code |
String |
|
HFPFacilityInfoResponse / Facility / FacilityZIP4 |
Obligatorio |
Pickup Facility ZIP Code+4 |
String |
|
HFPFacilityInfoResponse / Facility / Has10amCommitment |
Obligatorio |
Indicative of facility's hold-for-pickup availability. A value of "true" indicates packages can be available for pickup at 10:00 a.m. local time.
|
Boolean |
|
HFPFacilityInfoResponse / LogMessage |
Optional |
A text message for integrators of this API. It may contain additional information about this particular request/response, or general information about the API. With typical implementations, whenever this tag is encountered, the message is written to the console log file for later analysis. |
String |
|
HFPFacilityInfoResponse |
Obligatorio |
|
(Alias) |
|
Response: HFPFacilityInfo <HFPFacilityInfoResponse> <PickupCity/> <PickupState/> <PickupZIP>33952</PickupZIP> <PickupZIP4/> <Facility> <FacilityID>1438805</FacilityID> <FacilityName>PORT CHARLOTTE BRANCH</FacilityName> <FacilityAddress>3740 TAMIAMI TRL</FacilityAddress> <FacilityCity>PORT CHARLOTTE</FacilityCity> <FacilityState>FL</FacilityState> <FacilityZIP>33952</FacilityZIP> <FacilityZIP4>9998</FacilityZIP4> <Has10amCommitment>falso</Has10amCommitment> </Facility> <Facility> <FacilityID>1378061</FacilityID> <FacilityName>PORT CHARLOTTE ANNEX</FacilityName> <FacilityAddress>18100 PAULSON DR</FacilityAddress> <FacilityCity>PORT CHARLOTTE</FacilityCity> <FacilityState>FL</FacilityState> <FacilityZIP>33954</FacilityZIP> <FacilityZIP4>9998</FacilityZIP4> <Has10amCommitment>falso</Has10amCommitment> </Facility> /HFPFacilityInfoResponse> |