mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-23 09:17:06 +00:00
Update USPS configuration (#7023)
Using new config vars Add linkable titles Remove trailing spaces
This commit is contained in:
parent
0db5a68df7
commit
c466e7b556
@ -16,7 +16,7 @@ ha_iot_class: "Cloud Polling"
|
||||
The `usps` platform allows one to track deliveries and inbound mail from the [US Postal Service (USPS)](https://www.usps.com/).
|
||||
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](https://my.usps.com/mobileWeb/pages/intro/start.action). You must also "Opt-In" to [Informed Delivery](https://informeddelivery.usps.com/box/pages/intro/start.action) to see inbound mail.
|
||||
|
||||
## Prerequisites
|
||||
## {% linkable_title Prerequisites %}
|
||||
|
||||
This component 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.
|
||||
|
||||
@ -28,7 +28,7 @@ This component requires that a headless-capable web browser is installed on your
|
||||
Hass.io containers are based on Alpine Linux. PhanthomJS is not available for Alpine Linux. Therefore it is currently not possible to use this component on Hass.io.
|
||||
</p>
|
||||
|
||||
### PhantomJS
|
||||
### {% linkable_title PhantomJS %}
|
||||
|
||||
Install the latest version of [PhantomJS]( http://phantomjs.org/download.html). 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.
|
||||
|
||||
@ -38,8 +38,7 @@ Install the latest version of [PhantomJS]( http://phantomjs.org/download.html).
|
||||
|
||||
If you use the PhantomJS option, specify `driver: phantomjs` in your `usps` configuration.
|
||||
|
||||
|
||||
### Chrome
|
||||
### {% linkable_title Chrome %}
|
||||
|
||||
Install Chrome 59 or greater (preferably the most recent). Install the latest [Chromedriver](https://sites.google.com/a/chromium.org/chromedriver/downloads). Ensure both executables are on your `PATH`. `google-chrome --version` and `chromedriver --version` should work and report the correct version.
|
||||
|
||||
@ -49,7 +48,7 @@ OS-specific instructions:
|
||||
|
||||
If you use the Chrome option, specify `driver: chrome` in your `usps` configuration.
|
||||
|
||||
## Configuration
|
||||
## {% linkable_title Configuration %}
|
||||
|
||||
To enable this component, add the following lines to your `configuration.yaml`:
|
||||
|
||||
@ -62,12 +61,26 @@ usps:
|
||||
|
||||
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 options for the USPS component:
|
||||
|
||||
- **username** (*Required*): The username to access the MyUSPS service.
|
||||
- **password** (*Required*): The password for the given username.
|
||||
- **driver** (*Required*): Specify if you're using `phantomjs` or `chrome`.
|
||||
- **name** (*Optional*): Prefix for sensor names (defaults to "USPS")
|
||||
{% 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 %}
|
||||
|
||||
<p class='note warning'>
|
||||
The USPS sensor logs into the MyUSPS website to scrape package data. It does not use an API.
|
||||
|
Loading…
x
Reference in New Issue
Block a user