HTTP PUT
HTTP PUT
Section titled “HTTP PUT”Type: http-put · Package: HTTP Activities v1.0.0 · Output: ZoanHttpResponse
Sends a PUT request, typically to completely replace an existing resource. You send the whole object with its new values; the API replaces the resource with what you send.
How it works
Section titled “How it works”Same as POST but with the PUT method: send the body to the url of a specific resource (which usually includes its id). Returns a ZoanHttpResponse. Fails if the server responds with an error — see error handling.
Required parameters
Section titled “Required parameters”| Parameter | Editor | Description |
|---|---|---|
url | expression | The URL of the resource to be replaced (usually includes its id). |
body | expression | The complete resource with its new values (object → JSON, or text). |
Optional parameters
Section titled “Optional parameters”| Parameter | Editor | Description |
|---|---|---|
contentType | text | Content type. Por defecto application/json. |
headers | JSON | Dictionary of extra headers (name → value). See headers. |
authorization | JSON | Authentication: bearer, basic or apikey. See authentication. |
Output
Section titled “Output”Returns a ZoanHttpResponse.
Example
Section titled “Example”HTTP PUT url = = "https://api.erp.com/clientes/" + clienteId body = { "nombre": = nuevoNombre, "nit": = nit, "activo": false } authorization = { "type": "bearer", "token": = credential("api-erp").ToPlainText() } → output: respRelated activities
Section titled “Related activities”- HTTP PATCH — partial update.
- HTTP POST — create a resource.