ll.HTTPResponse

ll.HTTPResponse(HTTPRequestID: uuid, Status: number, Body: string) : ()

Responds to an incoming HTTP request which was triggerd by an http_request event within the script. HTTPRequestID specifies the request to respond to (this ID is supplied in the http_request event handler). Status and Body specify the status code and message to respond with.

Example

ll.HTTPResponse(uuid(<key>), 7, 'test')
{
  "def": "func",
  "desc": "Responds to an incoming HTTP request which was triggerd by an http_request event within the script. HTTPRequestID specifies the request to respond to (this ID is supplied in the http_request event handler). Status and Body specify the status code and message to respond with.",
  "energy": 10,
  "sleep": 0,
  "pure": true,
  "link": "https://wiki.secondlife.com/wiki/LlHTTPResponse",
  "name": "HTTPResponse",
  "signatures": [
    {
      "result": [
        {
          "name": "",
          "def": "result",
          "desc": "",
          "variadic": false,
          "type": [
            "()"
          ],
          "optional": false
        }
      ],
      "args": [
        {
          "def": "arg",
          "name": "HTTPRequestID",
          "desc": "A valid HTTP request key.",
          "type": [
            "uuid",
            "string"
          ],
          "variadic": false,
          "optional": false
        },
        {
          "def": "arg",
          "name": "Status",
          "desc": "HTTP Status (200, 400, 404, etc.).",
          "type": [
            "integer",
            "number"
          ],
          "variadic": false,
          "optional": false
        },
        {
          "def": "arg",
          "name": "Body",
          "desc": "Contents of the response.",
          "type": [
            "string"
          ],
          "variadic": false,
          "optional": false
        }
      ]
    }
  ]
}

< Back to ll