Franck Nijhof c464056402
Making our website faster, cleaner and prettier (#9853)
* 🔥 Removes octopress.js

* 🔥 Removes use of root_url var

* 🔥 Removes Octopress generator reference from feed

* 🔥 Removes delicious support

* 🔥 Removes support for Pinboard

* 🔥 Removes support for Disqus

* 🔥 Removes support for Google Plus

* ↩️ Migrate custom after_footer to default template

* ↩️ Migrate custom footer to default template

* ↩️ Migrate custom header to default template

* 🔥 Removes unused template files

* 🚀 Places time to read directly in post template

* 🚀 Removes unneeded capture from archive_post.html template

* 🔥 🚀 Removes unused, but heaving sorting call in component page

* 🚀 Merged javascripts into a single file

* 🔥 Removes more uses of root_url

* 🚀 Removal of unneeded captures from head

* 🔥 🚀 Removal of expensive liquid HTML compressor

* 🔥 Removes unneeded templates

* 🚀 Replaces kramdown with GitHub's CommonMark 🚀

* 💄 Adds Prism code syntax highlighting

*  Adds support for redirect in Netlify

* ↩️ 🔥 Let Netlify handle all developer doc redirects

* ✏️ Fixes typo in redirects file: Netify -> Netlify

* 🔥 Removes unused .themes folder

* 🔥 Removes unused aside.html template

* 🔥 Removes Disqus config leftover

* 🔥 Removes rouge highlighter config

* 🔥 Removes Octopress 🎉

* 💄 Adjust code block font size and adds soft wraps

* 💄 Adds styling for inline code blocks

* 💄 Improve styling of note/warning/info boxes + div support

* 🔨 Rewrites all note/warning/info boxes
2019-07-15 22:17:54 +02:00

4.4 KiB

title, description, logo, ha_category, ha_release, ha_iot_class, redirect_from
title description logo ha_category ha_release ha_iot_class redirect_from
USPS Interface USPS mail and package information to Home Assistant. usps.png
Postal Service
Camera
Sensor
0.52 Cloud Polling
/components/camera.usps/
/components/sensor.usps/

The usps platform allows one to track deliveries and inbound mail from the US Postal Service (USPS). In addition to having a USPS account, you will need to complete the "Opt-In" process for packages by clicking "Get Started Now" on this page. You must also "Opt-In" to Informed Delivery to see inbound mail.

There is currently support for the following device types within Home Assistant:

Prerequisites

This integration requires that a headless-capable web browser is installed on your system - either PhantomJS or Google Chrome. Preferably use Chrome if your operating system supports it, since PhantomJS is deprecated.

If you are using a Raspberry Pi, you must use PhantomJS.
Hass.io containers are based on Alpine Linux. PhantomJS is not available for Alpine Linux. Therefore it is currently not possible to use this integration on Hass.io.

PhantomJS

Install the latest version of PhantomJS. Ensure the executable is on your PATH. phantomjs --version should work and report the correct version. This is the default option and requires no further configuration.

Don't use apt-get to install PhantomJS. This version is not compatible.

If you use the PhantomJS option, specify driver: phantomjs in your usps configuration.

Chrome

Install Chrome 59 or greater (preferably the most recent). Install the latest Chromedriver. Ensure both executables are on your PATH. google-chrome --version and chromedriver --version should work and report the correct version.

OS-specific instructions:

If you use the Chrome option, specify driver: chrome in your usps configuration.

Configuration

To enable this component, add the following lines to your configuration.yaml:

# Example configuration.yaml entry
usps:
    username: YOUR_USERNAME
    password: YOUR_PASSWORD

You will see two new sensors, one for packages and one for mail and a camera to rotate through images of incoming mail for the current day.

{% configuration %} username: description: The username to access the MyUSPS service. required: true type: string password: description: The password for the given username. required: true type: string driver: description: Specify if you're using phantomjs or chrome. required: false type: string default: phantomjs name: description: The prefix for sensor names. required: false type: string default: usps {% endconfiguration %}

The USPS sensor logs into the MyUSPS website to scrape package data. It does not use an API.

Camera

The usps camera integration allows you to view the mail piece images made available through USPS via the Informed Delivery service. You must "Opt-In" to Informed Delivery to see mail images. This works in concert with USPS sensors.

Configuration

To customize the interval that mail images are rotated in the mail camera you can edit your configuration.yaml file with the following settings:

# Example configuration.yaml entry
camera:
  - platform: usps
    scan_interval: 5

To enable this camera in your installation, set up the USPS integration first.

Sensor

The usps sensor integration allows you to view statistics on incoming mail and packages made available through USPS via the Informed Delivery service. You must "Opt-In" to Informed Delivery to see mail images. This works in concert with USPS camera.

To enable this sensor in your installation, set up the USPS integration first.