You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+99-34Lines changed: 99 additions & 34 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@
4
4
5
5
**If you want to know why interacting with Picnic is getting harder than ever, check out their blogpost about architectural changes: [https://blog.picnic.nl/adding-write-functionality-to-pages-with-self-service-apis-d09aa7dbc9c0](https://jobs.picnic.app/en/blogs/adding-write-functionality-to-pages-with-self-service-apis)**
6
6
7
-
Fork of the Unofficial Python wrapper for the [Picnic](https://picnic.app) API. While not all API methods have been implemented yet, you'll find most of what you need to build a working application are available.
7
+
Fork of the Unofficial Python wrapper for the [Picnic](https://picnic.app) API. While not all API methods have been implemented yet, you'll find most of what you need to build a working application is available.
8
8
9
9
This library is not affiliated with Picnic and retrieves data from the endpoints of the mobile application. **Use at your own risk.**
10
10
@@ -53,45 +53,90 @@ except Picnic2FARequired:
53
53
54
54
After successful verification, the session is authenticated and you can use the API normally. If the code is invalid, `Picnic2FAError` is raised.
55
55
56
-
## Searching for an article
56
+
## Typed models (2.x)
57
57
58
-
```python
59
-
picnic.search('coffee')
60
-
```
58
+
As of 2.x the API returns typed [pydantic](https://docs.pydantic.dev) models
59
+
instead of raw dicts. This covers both the "page" endpoints Picnic serves as a
60
+
layout tree of widgets (`search`, `get_article`, `get_category_by_ids`) and the
0 commit comments