Retrieve Mail Piece Status
Retrieves information about the delivery status of a Sepire mail piece
Endpoint URL | SDK Method |
---|---|
https://api.inkit.com/v1/mail-piece/{mailPieceId} (GET) | N/A |
Request properties
Property | Type | Required | Description |
---|---|---|---|
mailPieceId | String | Yes | The ID of a Sepire mail piece that was previously created. |
Response properties
Property | Type | Description |
---|---|---|
address_city | String | The recipient's city. |
address_country | String | The recipient's country. |
address_line_1 | String | The first line of the recipient's address. |
address_line_2 | String | The second line of the recipient's address. |
address_placement | String | Whether the placement of the address is top_first_page or insert_blank_page . |
address_state | String | The recipient's state. |
address_verification_failed_at | String | The date and time the address verification failed. |
address_zip | String | The recipient's zip code. |
color | Boolean | Whether output should be in color. |
company | String | |
created_at | String | The date and time when the mail piece was created. |
double_sided | Boolean | Whether output should be double-sided. |
first_name | String | The recipient's first name. |
height | Float | The height of the document. |
id | String | The ID of the mail piece. |
imb | String | The USPS IMb tracking code. |
in_local_area_at | String | The date and time the mail piece arrived in the local area. |
in_transit_at | String | The date and time the mail piece entered transit. |
last_name | String | The recipient's last name. |
latest_delivery_status | String | The latest delivery status of the mail piece. |
mail_product_name | String | Whether the product is a letter or a postcard . |
mail_type | String | Whether delivery is usps_first_class or usps_standard . |
mailed_at | String | The date and time the mail piece was mailed. |
perforated | Integer | Whether perforated (1 ) or not (0 ). |
processed_for_delivery_at | String | The date and time the mail piece was processed for delivery. |
render_id | String | The Render ID of the document. |
rerouted_at | String | The date and time the mail piece was rerouted. |
return_envelope | Boolean | Whether to include a return envelope. |
returned_to_sender_at | String | The date and time the mail piece was returned to sender. |
size | String | The postcard size. |
status | String | The overall status of the mail piece. |
template_id | String | The ID of the template used to generate the document. |
template_name | String | The name of the template used to generate the document. |
template_version | Integer | The version of the template used to generate the document. |
unit | String | The unit of measurement for documents generated by the template. Valid values are in and cm . |
verify_address | Boolean | Whether to verify the address. |
width | Float | The width of the document. |
latest_delivery_status
latest_delivery_status
String | Description |
---|---|
mailed | The mail piece was sent to Sepire. |
address_verification_failed | Address verification of the mail piece failed. |
in_transit | The mail piece is in transit. |
in_local_area | The mail piece is in the local area. |
rerouted | The mail piece was rerouted. |
processed_for_delivery | The mail piece was processed for delivery. |
returned_to_sender | The mail piece was returned to sender. |
Example request and response
curl --request GET \
--url https://api.inkit.com/v1/mail-piece/ENTER_YOUR_MAIL_PIECE_ID \
--header 'X-Inkit-API-Token: ENTER YOUR API KEY' \
--header 'accept: application/json'
{
"address_city":"New York",
"address_country":"US",
"address_line_1":"1234 Main St.",
"address_line_2":"#1",
"address_placement":"top_first_page",
"address_state":"NY",
"address_verification_failed_at":null,
"address_zip":"10001",
"color":false,
"company":"",
"created_at":"2023-08-31T16:59:16.639084Z",
"double_sided":false,
"first_name":"John",
"height":11.0,
"id":"mp_4IDk1YbLznzMiMjaXlXbCS",
"imb":null,
"in_local_area_at":null,
"in_transit_at":null,
"last_name":"Doe",
"latest_delivery_status":null,
"mail_product_name":"letter",
"mail_type":"usps_first_class",
"mailed_at":null,
"perforated":0,
"processed_for_delivery_at":null,
"render_id":"rend_7pGnot4dhBUm2Re0EVQgso",
"rerouted_at":null,
"return_envelope":false,
"returned_to_sender_at":null,
"size":null,
"status":"failed",
"template_id":"tmpl_4UDp3vSa3z3ithp6qgyFtj",
"template_name":"Mail Merge",
"template_version":8,
"unit":"in",
"verify_address":false,
"width":8.5
}
Updated 9 months ago