-
Notifications
You must be signed in to change notification settings - Fork 0
/
ha-configuration.yaml
37 lines (37 loc) · 1.05 KB
/
ha-configuration.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
rest:
- authentication: basic
scan_interval: 3600
resource: https://api.api-ninjas.com/v1/dadjokes/
# resource: https://api.api-ninjas.com/v1/jokes/ #Normal jokes
method: GET
headers:
X-Api-Key: 'YOUR_SECRET_KEY_FROM_API_NINJAS'
sensor:
- name: "API Ninja - Dad Jokes"
value_template: "OK"
json_attributes:
- "joke"
- authentication: basic
scan_interval: 3600
resource: https://api.api-ninjas.com/v1/chucknorris
method: GET
headers:
X-Api-Key: 'YOUR_SECRET_KEY_FROM_API_NINJAS'
sensor:
- name: "API Ninja - Chuck Norris"
value_template: "OK"
json_attributes:
- "joke"
- authentication: basic
scan_interval: 3600
resource: https://api.api-ninjas.com/v1/trivia
method: GET
headers:
X-Api-Key: 'YOUR_SECRET_KEY_FROM_API_NINJAS'
sensor:
- name: "API Ninja - Trivia"
value_template: "OK"
json_attributes:
- "category"
- "question"
- "answer"