bilkatogo
Track your BilkaToGo grocery orders: an async Python library, a command line tool and a Home Assistant integration that follow your order from the moment it is placed until you pick it up, including which products Bilka substituted.
Unofficial. This project is not affiliated with or endorsed by Bilka or Salling Group. It uses the same private web API as the bilkatogo.dk website, logging in with your email and password. That API can change or break at any time.
The library, the CLI and the Home Assistant integration are released together and always share the same version.
- Library: an async Python client for your orders, Pickup Points, product search and Cart.
- Home Assistant: sensors, a calendar, actions and events for your Current Order.
- Command line: the library from your terminal or a script.
Library
pip install bilkatogo
import asyncio
from bilkatogo import BilkaToGoClient, FileTokenStorage
async def main() -> None:
async with BilkaToGoClient(
"you@example.com",
"your-password",
token_storage=FileTokenStorage("session.json"),
) as client:
current = await client.get_current_order()
if current:
print(current.order_number, current.status, current.pickup_slot)
asyncio.run(main())
The full library documentation, covering orders, the Cart, product search, the models and the errors, is in docs/library.md.
Home Assistant
The integration follows your Current Order in Home Assistant: its Order Status, Pickup Slot, Pickup Code and Order Total, which products Bilka substituted or left out, and a calendar of your Pickup Slots. Actions search Bilka's products, add them to your Cart and choose its Pickup Slot. It needs Home Assistant 2026.10 or later.
-
Install BilkaToGo from the Home Assistant Marketplace (HACS): open HACS, search for BilkaToGo and download it, or open it straight away:
Restart Home Assistant afterwards.
-
Go to Settings > Devices & services > Add integration, pick BilkaToGo and sign in with your bilkatogo.dk email and password.
An automation that sends the Pickup Code once the order is packed (replace the entity IDs with yours):
automation:
- alias: BilkaToGo ready for pickup
triggers:
- trigger: state
entity_id: binary_sensor.me_example_com_ready_for_pickup
to: "on"
actions:
- action: notify.notify
data:
message: >
Your groceries are packed. Pickup Code:
{{ states('sensor.me_example_com_pickup_code') }}.
The full integration documentation, covering the entities, actions, events, known limitations, troubleshooting and removal, is in docs/home-assistant.md.
Command line
pip install 'bilkatogo[cli]'
Or run it without installing:
uvx --from 'bilkatogo[cli]' bilkatogo --help
bilkatogo login # log in and store the session
bilkatogo order # show the Current Order with its details
bilkatogo search skyr # Products with Article Number, Price, stock and Offer
bilkatogo cart add 18381 # add a Product to the Cart by Article Number
The full command line documentation, covering every command, credentials and capturing a fixture for an issue, is in docs/cli.md.
Development
Library and CLI:
uv run ruff format --check . && uv run ruff check . && uv run ty check && uv run pytest
Home Assistant tests use their own dependency group, because pytest-homeassistant pins
Home Assistant and its own pytest. Keep them in a separate virtual environment so the
library environment stays untouched:
UV_PROJECT_ENVIRONMENT=.venv-ha uv run --no-default-groups --group ha pytest tests/ha
UV_PROJECT_ENVIRONMENT=.venv-ha uv run --no-default-groups --group ha ty check custom_components tests/ha
Home Assistant does not run on Windows. There, scripts/ha-test.sh runs both commands in WSL:
wsl.exe -e bash scripts/ha-test.sh
The Home Assistant tests run the real library against the fake Bilka backend in
tests/fake_bilka.py. The integration creates its httpx client with Home Assistant's
create_async_httpx_client, and tests/ha/conftest.py routes every request at the
transport level to the fake backend with respx, so nothing in the integration is patched.
Releasing is described in AGENTS.md.
License
MIT
Metadata
Release files for bilkatogo 0.13.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| bilkatogo-0.13.1.tar.gz | 45.8 kB | With provenance | Details for bilkatogo-0.13.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| bilkatogo-0.13.1-py3-none-any.whl | Python 3 | none | any | Details for bilkatogo-0.13.1-py3-none-any.whl |
Total release size: 99.0 kB
Release files / bilkatogo-0.13.1.tar.gz
| Download URL | bilkatogo-0.13.1.tar.gz |
|---|---|
| Size | 45.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
28c4dfa8f0efbe8dd3214d5101ddcd5e5b857c7415fcd477c4632effadae2f67
|
|
BLAKE2b-256 checksum How to use checksums |
fef3acdbe68a3fa2292778cbcc379559986b0166c804d0ebda9be9461655e3cd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 9, 2026.
Transparency logRelease files / bilkatogo-0.13.1-py3-none-any.whl
| Download URL | bilkatogo-0.13.1-py3-none-any.whl |
|---|---|
| Size | 53.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
077d3a16537f7ae88f7fbd3d338bf85ec395b7b1c672938486b304716d062572
|
|
BLAKE2b-256 checksum How to use checksums |
21d3dbf015aced57b4cd64f6f4e17227ff4847bea8b43d99b4300760d417c3a1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 9, 2026.
Transparency logSecurity for bilkatogo 0.13.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for bilkatogo-0.13.1.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 9, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.