Skip to content

Commit 8079c0c

Browse files
committed
new: Add support for init script
1 parent ab3f59e commit 8079c0c

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

pylacus/api.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,7 @@ class CaptureSettings(TypedDict, total=False):
101101
with_favicon: bool
102102
allow_tracking: bool
103103
headless: bool
104+
init_script: str
104105

105106
force: bool | None
106107
recapture_interval: int | None
@@ -177,6 +178,7 @@ def enqueue(self, *,
177178
with_favicon: bool=False,
178179
allow_tracking: bool=False,
179180
headless: bool=True,
181+
init_script: str | None=None,
180182
rendered_hostname_only: bool=True,
181183
force: bool=False,
182184
recapture_interval: int=300,
@@ -210,6 +212,7 @@ def enqueue(self, *,
210212
with_favicon: bool=False,
211213
allow_tracking: bool=False,
212214
headless: bool=True,
215+
init_script: str | None=None,
213216
rendered_hostname_only: bool=True,
214217
force: bool=False,
215218
recapture_interval: int=300,
@@ -266,6 +269,8 @@ def enqueue(self, *,
266269
to_enqueue['max_retries'] = max_retries
267270
if uuid:
268271
to_enqueue['uuid'] = uuid
272+
if init_script:
273+
to_enqueue['init_script'] = init_script
269274

270275
r = self.session.post(urljoin(self.root_url, 'enqueue'), json=to_enqueue)
271276
return r.json()

0 commit comments

Comments
 (0)