03.03.2022, 08:41
(03.03.2022, 08:33)admin Wrote: Use this, adjust URL (including id parameters) as needed:
Code:123456789101112131415161718http = require('socket.http') json = require('json') url = 'https://exampleadr.com/pms_api/:subscription_id/:account_id/rooms/:room_id' body = json.encode({ room = { housekeeping_status = 'inspect' } }) res, code = http.request({ url = url, method = 'PUT', body = body }) log(res, code)
The API uses Digest Auth, would the example above work in that case or would the earlier example in this thread need to be adjusted?