Request():options()
Gửi một yêu cầu OPTIONS để hỏi máy chủ xem nó cho phép những phương thức và header nào.
Khai báo
options(): Response
Trả về
Response - Câu trả lời của máy chủ, thường có header Allow.
Ví dụ
local response = Request("https://api.example.com/users"):options()
toast("Allowed: " .. (response:getHeader("Allow") or "unknown"))
Phiên bản tương thích: 1.0.0.37 trở lên