1
1
# baby_buddy_homeassistant
2
2
3
3
[ ![ hacs_badge] ( https://img.shields.io/badge/HACS-Default-orange.svg )] ( https://github.com/custom-components/hacs )
4
- [ ![ Code style: black] ( https://img.shields.io/badge/code%20style-black-000000.svg )] ( https://github.com/psf/black )
5
- [ ![ Imports: isort] ( https://img.shields.io/badge/%20imports-isort-%231674b1?style=flat&labelColor=ef8336 )] ( https://pycqa.github.io/isort/ )
4
+ [ ![ Ruff] ( https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json )] ( https://github.com/astral-sh/ruff )
6
5
7
6
This custom integration allows you to monitor [ Baby Buddy] ( https://github.com/babybuddy/babybuddy ) data for your child within [ Home Assistant] ( https://github.com/home-assistant/core ) . It also allows you to start timers and add data entries from within Home Assistant.
8
7
@@ -22,12 +21,12 @@ Adding BabyBuddy to your Home Assistant instance can be done via the user interf
22
21
23
22
### Parameters
24
23
25
- | Name | Optional | Description |
26
- | ------| :----: | -------------|
27
- | address | no | Host URL for your instance of Baby Buddy, without sub path
28
- | port | no | Host port (default = 8000)
29
- | path | no | Sub path of your Baby Buddy instance (default = "")
30
- | api_key| no | The API key from the user settings page on your instance of Baby Buddy
24
+ | Name | Optional | Description |
25
+ | ------- | :------: | ---------------------------------------------------------------------- |
26
+ | address | no | Host URL for your instance of Baby Buddy, without sub path |
27
+ | port | no | Host port (default = 8000) |
28
+ | path | no | Sub path of your Baby Buddy instance (default = "") |
29
+ | api_key | no | The API key from the user settings page on your instance of Baby Buddy |
31
30
32
31
### Options
33
32
@@ -65,154 +64,154 @@ This integration provides the following entities.
65
64
66
65
This service adds a new child. At least one child should be added to start seeing the different sensors and switches.
67
66
68
- | Service data attribute | Optional | Description |
69
- | ------| :----: | -------------|
70
- | first_name | no | Baby's first name
71
- | last_name | no | Baby's last name
72
- | birth_date | no | Child's birth date in YYYY-MM-DD format
67
+ | Service data attribute | Optional | Description |
68
+ | ---------------------- | :------: | --------------------------------------- |
69
+ | first_name | no | Baby's first name |
70
+ | last_name | no | Baby's last name |
71
+ | birth_date | no | Child's birth date in YYYY-MM-DD format |
73
72
74
73
### SERVICE ADD_BMI
75
74
76
75
This service adds a BMI entry for your child.
77
76
78
- | Service data attribute | Optional | Description |
79
- | ------| :----: | -------------|
80
- | entity_id | no | entity_id for the child sensor
81
- | BMI | no | Specify BMI value (float)
82
- | date | yes | Specify BMI recording date (YYYY-MM-DD format, else today() will be used)
83
- | notes | yes | Add notes text to entry
77
+ | Service data attribute | Optional | Description |
78
+ | ---------------------- | :------: | ------------------------------------------------------------------------- |
79
+ | entity_id | no | entity_id for the child sensor |
80
+ | BMI | no | Specify BMI value (float) |
81
+ | date | yes | Specify BMI recording date (YYYY-MM-DD format, else today() will be used) |
82
+ | notes | yes | Add notes text to entry |
84
83
85
84
### SERVICE ADD_DIAPER_CHANGE
86
85
87
86
This service adds a diaper change entry for your child.
88
87
89
- | Service data attribute | Optional | Description |
90
- | ------| :----: | -------------|
91
- | entity_id | no | entity_id for the child sensor
92
- | type | yes | Specify type of diaper. This can be ` Wet ` , ` Solid ` , or ` Wet and Solid ` .
93
- | time | yes | Specify diaper change time (must be in the past, else now() will be used)
94
- | color | yes | Specify diaper color. This can be ` Black ` , ` Brown ` , ` Green ` , or ` Yellow ` .
95
- | amount | yes | Add number of diapers
96
- | notes | yes | Add notes text to entry
88
+ | Service data attribute | Optional | Description |
89
+ | ---------------------- | :------: | -------------------------------------------------------------------------- |
90
+ | entity_id | no | entity_id for the child sensor |
91
+ | type | yes | Specify type of diaper. This can be ` Wet ` , ` Solid ` , or ` Wet and Solid ` . |
92
+ | time | yes | Specify diaper change time (must be in the past, else now() will be used) |
93
+ | color | yes | Specify diaper color. This can be ` Black ` , ` Brown ` , ` Green ` , or ` Yellow ` . |
94
+ | amount | yes | Add number of diapers |
95
+ | notes | yes | Add notes text to entry |
97
96
98
97
### SERVICE ADD_FEEDING
99
98
100
99
This service adds a feeding entry for your child. Feeding start/end/child fields can be linked to an active timer.
101
100
102
- | Service data attribute | Optional | Description |
103
- | ------| :----: | -------------|
104
- | entity_id | no | entity_id for the timer switch linked to the child.
105
- | type | no | Specify type of feeding. Can be one of ` Breast milk ` , ` Formula ` , ` Fortified breast milk ` , or ` Solid food ` .
106
- | method | no | Specify method of feeding. Can be one of ` Bottle ` , ` Left breast ` , ` Right breast ` , ` Both breasts ` , ` Self fed ` , or ` Parent fed ` .
107
- | timer | yes | Set to True to use the currently active timer
108
- | start | yes | Specify start time (must be in the past, else now() will be used). This can be ignored if timer is used.
109
- | end | yes | Specify end time (must be in the past, else now() will be used). This can be ignored if timer is used.
110
- | amount | yes | Specify amount of feeding as an integer
111
- | notes | yes | Add notes text to entry
101
+ | Service data attribute | Optional | Description |
102
+ | ---------------------- | :------: | ------------------------------------------------------------------------------------------------------------------------------ |
103
+ | entity_id | no | entity_id for the timer switch linked to the child. |
104
+ | type | no | Specify type of feeding. Can be one of ` Breast milk ` , ` Formula ` , ` Fortified breast milk ` , or ` Solid food ` . |
105
+ | method | no | Specify method of feeding. Can be one of ` Bottle ` , ` Left breast ` , ` Right breast ` , ` Both breasts ` , ` Self fed ` , or ` Parent fed ` . |
106
+ | timer | yes | Set to True to use the currently active timer |
107
+ | start | yes | Specify start time (must be in the past, else now() will be used). This can be ignored if timer is used. |
108
+ | end | yes | Specify end time (must be in the past, else now() will be used). This can be ignored if timer is used. |
109
+ | amount | yes | Specify amount of feeding as an integer |
110
+ | notes | yes | Add notes text to entry |
112
111
113
112
### SERVICE ADD_HEAD_CIRCUMFERENCE
114
113
115
114
This service adds a head circumference entry for your child.
116
115
117
- | Service data attribute | Optional | Description |
118
- | ------| :----: | -------------|
119
- | entity_id | no | entity_id for the child sensor
120
- | head_circumference | no | Specify head circumference value (float)
121
- | date | yes | Specify head circumference recording date (YYYY-MM-DD format, else today() will be used)
122
- | notes | yes | Add notes text to entry
116
+ | Service data attribute | Optional | Description |
117
+ | ---------------------- | :------: | ---------------------------------------------------------------------------------------- |
118
+ | entity_id | no | entity_id for the child sensor |
119
+ | head_circumference | no | Specify head circumference value (float) |
120
+ | date | yes | Specify head circumference recording date (YYYY-MM-DD format, else today() will be used) |
121
+ | notes | yes | Add notes text to entry |
123
122
124
123
### SERVICE ADD_HEIGHT
125
124
126
125
This service adds a height entry for your child.
127
126
128
- | Service data attribute | Optional | Description |
129
- | ------| :----: | -------------|
130
- | entity_id | no | entity_id for the child sensor
131
- | height | no | Specify height value (float)
132
- | date | yes | Specify height recording date (YYYY-MM-DD format, else today() will be used)
133
- | notes | yes | Add notes text to entry
127
+ | Service data attribute | Optional | Description |
128
+ | ---------------------- | :------: | ---------------------------------------------------------------------------- |
129
+ | entity_id | no | entity_id for the child sensor |
130
+ | height | no | Specify height value (float) |
131
+ | date | yes | Specify height recording date (YYYY-MM-DD format, else today() will be used) |
132
+ | notes | yes | Add notes text to entry |
134
133
135
134
### SERVICE ADD_NOTE
136
135
137
136
This service adds a note entry for your child.
138
137
139
- | Service data attribute | Optional | Description |
140
- | ------| :----: | -------------|
141
- | entity_id | no | entity_id for the child sensor
142
- | notes | yes | Add notes text to entry
143
- | time | yes | Specify notes recording time (must be in the past, else now() will be used)
138
+ | Service data attribute | Optional | Description |
139
+ | ---------------------- | :------: | --------------------------------------------------------------------------- |
140
+ | entity_id | no | entity_id for the child sensor |
141
+ | notes | yes | Add notes text to entry |
142
+ | time | yes | Specify notes recording time (must be in the past, else now() will be used) |
144
143
145
144
### SERVICE ADD_PUMPING
146
145
147
146
This service adds a pumping entry for your child.
148
147
149
- | Service data attribute | Optional | Description |
150
- | ------| :----: | -------------|
151
- | entity_id | no | entity_id for the child sensor
152
- | amount | no | Specify amount of pumping as an integer
153
- | time | yes | Specify pumping recording time (must be in the past, else now() will be used)
154
- | notes | yes | Add notes text to entry
148
+ | Service data attribute | Optional | Description |
149
+ | ---------------------- | :------: | ----------------------------------------------------------------------------- |
150
+ | entity_id | no | entity_id for the child sensor |
151
+ | amount | no | Specify amount of pumping as an integer |
152
+ | time | yes | Specify pumping recording time (must be in the past, else now() will be used) |
153
+ | notes | yes | Add notes text to entry |
155
154
156
155
### SERVICE ADD_SLEEP
157
156
158
157
This service adds a sleep entry for your child. Sleep start/end/child fields can be linked to an active timer.
159
158
160
- | Service data attribute | Optional | Description |
161
- | ------| :----: | -------------|
162
- | entity_id | no | entity_id for the timer switch linked to the child
163
- | timer | yes | Set to True to use the currently active timer
164
- | start | yes | Specify start time (must be in the past, else now() will be used). This can be ignored if timer is used.
165
- | end | yes | Specify end time (must be in the past, else now() will be used). This can be ignored if timer is used.
166
- | notes | yes | Add notes text to entry
159
+ | Service data attribute | Optional | Description |
160
+ | ---------------------- | :------: | -------------------------------------------------------------------------------------------------------- |
161
+ | entity_id | no | entity_id for the timer switch linked to the child |
162
+ | timer | yes | Set to True to use the currently active timer |
163
+ | start | yes | Specify start time (must be in the past, else now() will be used). This can be ignored if timer is used. |
164
+ | end | yes | Specify end time (must be in the past, else now() will be used). This can be ignored if timer is used. |
165
+ | notes | yes | Add notes text to entry |
167
166
168
167
### SERVICE ADD_TEMPERATURE
169
168
170
169
This service adds a temperature entry for your child.
171
170
172
- | Service data attribute | Optional | Description |
173
- | ------| :----: | -------------|
174
- | entity_id | no | entity_id for the child sensor
175
- | temperature | no | Specify temperature value (float)
176
- | time | yes | Specify temperature recording time (must be in the past, else now() will be used)
177
- | notes | yes | Add notes text to entry
171
+ | Service data attribute | Optional | Description |
172
+ | ---------------------- | :------: | --------------------------------------------------------------------------------- |
173
+ | entity_id | no | entity_id for the child sensor |
174
+ | temperature | no | Specify temperature value (float) |
175
+ | time | yes | Specify temperature recording time (must be in the past, else now() will be used) |
176
+ | notes | yes | Add notes text to entry |
178
177
179
178
### SERVICE ADD_TUMMY_TIME
180
179
181
180
This service adds a tummy time entry for your child. Tummy time start/end/child fields can be linked to an active timer.
182
181
183
- | Service data attribute | Optional | Description |
184
- | ------| :----: | -------------|
185
- | entity_id | no | entity_id for the timer switch linked to the child
186
- | timer | yes | Set to True to use the currently active timer
187
- | start | yes | Specify start time (must be in the past, else now() will be used). This can be ignored if timer is used.
188
- | end | yes | Specify end time (must be in the past, else now() will be used). This can be ignored if timer is used.
189
- | milestone | yes | Add milestone text to entry
182
+ | Service data attribute | Optional | Description |
183
+ | ---------------------- | :------: | -------------------------------------------------------------------------------------------------------- |
184
+ | entity_id | no | entity_id for the timer switch linked to the child |
185
+ | timer | yes | Set to True to use the currently active timer |
186
+ | start | yes | Specify start time (must be in the past, else now() will be used). This can be ignored if timer is used. |
187
+ | end | yes | Specify end time (must be in the past, else now() will be used). This can be ignored if timer is used. |
188
+ | milestone | yes | Add milestone text to entry |
190
189
191
190
### SERVICE ADD_WEIGHT
192
191
193
192
This service adds a weight entry for your child.
194
193
195
- | Service data attribute | Optional | Description |
196
- | ------| :----: | -------------|
197
- | entity_id | no | entity_id for the child sensor
198
- | weight | no | Specify weight value (float)
199
- | date | yes | Specify weight recording date (YYYY-MM-DD format, else today() will be used)
200
- | notes | yes | Add notes text to entry
194
+ | Service data attribute | Optional | Description |
195
+ | ---------------------- | :------: | ---------------------------------------------------------------------------- |
196
+ | entity_id | no | entity_id for the child sensor |
197
+ | weight | no | Specify weight value (float) |
198
+ | date | yes | Specify weight recording date (YYYY-MM-DD format, else today() will be used) |
199
+ | notes | yes | Add notes text to entry |
201
200
202
201
### SERVICE DELETE_LAST_ENTRY
203
202
204
203
This service will delete the last entry for specified child.
205
204
206
- | Service data attribute | Optional | Description |
207
- | ------| :----: | -------------|
208
- | entity_id | no | entity_id for the child who's last entry will be deleted
205
+ | Service data attribute | Optional | Description |
206
+ | ---------------------- | :------: | -------------------------------------------------------- |
207
+ | entity_id | no | entity_id for the child who's last entry will be deleted |
209
208
210
209
### SERVICE START_TIMER
211
210
212
211
This service starts a new timer for specified child with optional starting time.
213
212
214
- | Service data attribute | Optional | Description |
215
- | ------| :----: | -------------|
216
- | entity_id | no | entity_id for the switch linked to the child
217
- | start | yes | Specify start time (must be in the past, else now() will be used)
218
- | name | yes | Optional name for new timer
213
+ | Service data attribute | Optional | Description |
214
+ | ---------------------- | :------: | ----------------------------------------------------------------- |
215
+ | entity_id | no | entity_id for the switch linked to the child |
216
+ | start | yes | Specify start time (must be in the past, else now() will be used) |
217
+ | name | yes | Optional name for new timer |
0 commit comments