Skip to content

Commit 0721f72

Browse files
docs: revise readme docs about nested params (#95)
1 parent b67753f commit 0721f72

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,24 @@ for session in first_page.sessions:
144144
# Remove `await` for non-async usage.
145145
```
146146

147+
## Nested params
148+
149+
Nested parameters are dictionaries, typed using `TypedDict`, for example:
150+
151+
```python
152+
from steel import Steel
153+
154+
client = Steel()
155+
156+
session = client.sessions.create(
157+
dimensions={
158+
"height": 0,
159+
"width": 0,
160+
},
161+
)
162+
print(session.dimensions)
163+
```
164+
147165
## Handling errors
148166

149167
When the library is unable to connect to the API (for example, due to network connection problems or a timeout), a subclass of `steel.APIConnectionError` is raised.

0 commit comments

Comments
 (0)