marshaller/net/http.py

8 lines
572 B
Python
Raw Normal View History

2023-10-23 15:43:36 -04:00
okResponse = 'HTTP/1.1 200 OK\r\ncontent-type: text/html\r\n\r\n'.encode('ascii')
okTextResponse = 'HTTP/1.1 200 OK\r\ncontent-type: text/plain\r\n\r\n'.encode('ascii')
okJsonResponse = 'HTTP/1.1 200 OK\r\ncontent-type: application/json\r\n\r\n'.encode('ascii')
okIconResponse = 'HTTP/1.1 200 OK\r\ncontent-type: image/x-icon\r\n\r\n'.encode('ascii')
2023-10-27 17:39:58 -04:00
noContentResponse = 'HTTP/1.1 204 No Content\r\n\r\n'.encode('ascii')
2023-10-23 15:43:36 -04:00
notFoundResponse = 'HTTP/1.1 404 Not Found\r\n\r\n'.encode('ascii')
serverErrorResponse = 'HTTP/1.1 500 Internal Server Error\r\n\r\n'.encode('ascii')