Skip to main content
Besides client.get(), the SDK exposes client.post() and client.put() for targets that expect a form submission or a data payload. Both accept the same params and headers arguments as get, plus a data argument for the request body.

Basic usage

client.put() works identically, replacing .post with .put:

When to use POST or PUT

  • POST: submitting a form on the target site, triggering a search or filter that requires a form submission, or calling a write endpoint on a target API.
  • PUT: updating a resource on a target API that expects PUT semantics.
  • Neither: most scraping tasks (reading page content) only need client.get(). Reach for POST/PUT specifically when the target requires it, not by default.

Combining with request parameters

params still works the same way it does for GET requests, so you can enable premium_proxy, or other Fetch parameters alongside data:
js_render only works with GET requests (client.get()). It is not supported on POST or PUT requests.
In case you need to send a JSON body instead of form-encoded data, pass json={...} as an extra keyword argument. It’s forwarded straight to the underlying requests call: client.post(url, json={"key1": "value1"}).
post and put also have async counterparts, post_async and put_async. See Async Requests and Concurrency.

Troubleshooting

  • Target site doesn’t reflect the submitted data: Some forms require specific headers (like Content-Type or a Referer) to accept the submission. See Custom Headers.
  • Getting REQS005 Method Not Allowed: The target endpoint doesn’t accept the HTTP verb you’re using. Zenrows only supports GET, POST, and PUT; confirm the target expects one of these.
  • data isn’t being sent as expected: data is form-encoded by default (like an HTML form submit). If the target expects JSON, use the json= keyword argument instead, not data=.

Pricing

POST and PUT requests are billed the same way as GET requests. Cost depends on the params you use, not the HTTP method: See Zenrows Pricing for plan-specific rates.
js_render only works with GET requests (client.get()). It is not supported on POST or PUT requests.

FAQ (Frequently Asked Questions)

Yes. params (Zenrows/API options like premium_proxy) and data (the payload sent to the target) are independent arguments and can be combined.
No. Only GET, POST, and PUT are supported by Fetch and this SDK.
Pass files={...} as an extra keyword argument, forwarded directly to requests: client.post(url, files={"file": open("photo.jpg", "rb")}).