' REST/HTTP protocol constants independent of a transport DLL.
#IF NOT %DEF(PBX_REST_HTTP_PBI)
#DEFINE PBX_REST_HTTP_PBI

%EQUATE `HTTP_METHOD_GET = "GET"
%EQUATE `HTTP_METHOD_HEAD = "HEAD"
%EQUATE `HTTP_METHOD_POST = "POST"
%EQUATE `HTTP_METHOD_PUT = "PUT"
%EQUATE `HTTP_METHOD_PATCH = "PATCH"
%EQUATE `HTTP_METHOD_DELETE = "DELETE"
%EQUATE `HTTP_METHOD_OPTIONS = "OPTIONS"
%EQUATE `HTTP_METHOD_TRACE = "TRACE"
%EQUATE `HTTP_METHOD_CONNECT = "CONNECT"

%EQUATE `HTTP_HEADER_ACCEPT = "Accept"
%EQUATE `HTTP_HEADER_ACCEPT_ENCODING = "Accept-Encoding"
%EQUATE `HTTP_HEADER_AUTHORIZATION = "Authorization"
%EQUATE `HTTP_HEADER_CACHE_CONTROL = "Cache-Control"
%EQUATE `HTTP_HEADER_CONNECTION = "Connection"
%EQUATE `HTTP_HEADER_CONTENT_LENGTH = "Content-Length"
%EQUATE `HTTP_HEADER_CONTENT_TYPE = "Content-Type"
%EQUATE `HTTP_HEADER_DATE = "Date"
%EQUATE `HTTP_HEADER_ETAG = "ETag"
%EQUATE `HTTP_HEADER_HOST = "Host"
%EQUATE `HTTP_HEADER_LOCATION = "Location"
%EQUATE `HTTP_HEADER_USER_AGENT = "User-Agent"
%EQUATE `HTTP_HEADER_TRANSFER_ENCODING = "Transfer-Encoding"
%EQUATE `HTTP_HEADER_WWW_AUTHENTICATE = "WWW-Authenticate"
%EQUATE `HTTP_HEADER_X_REQUEST_ID = "X-Request-Id"

%EQUATE `HTTP_STATUS_CONTINUE = 100
%EQUATE `HTTP_STATUS_SWITCHING_PROTOCOLS = 101
%EQUATE `HTTP_STATUS_OK = 200
%EQUATE `HTTP_STATUS_CREATED = 201
%EQUATE `HTTP_STATUS_ACCEPTED = 202
%EQUATE `HTTP_STATUS_NO_CONTENT = 204
%EQUATE `HTTP_STATUS_MOVED_PERMANENTLY = 301
%EQUATE `HTTP_STATUS_FOUND = 302
%EQUATE `HTTP_STATUS_SEE_OTHER = 303
%EQUATE `HTTP_STATUS_NOT_MODIFIED = 304
%EQUATE `HTTP_STATUS_TEMPORARY_REDIRECT = 307
%EQUATE `HTTP_STATUS_PERMANENT_REDIRECT = 308
%EQUATE `HTTP_STATUS_BAD_REQUEST = 400
%EQUATE `HTTP_STATUS_UNAUTHORIZED = 401
%EQUATE `HTTP_STATUS_FORBIDDEN = 403
%EQUATE `HTTP_STATUS_NOT_FOUND = 404
%EQUATE `HTTP_STATUS_METHOD_NOT_ALLOWED = 405
%EQUATE `HTTP_STATUS_CONFLICT = 409
%EQUATE `HTTP_STATUS_TOO_MANY_REQUESTS = 429
%EQUATE `HTTP_STATUS_INTERNAL_SERVER_ERROR = 500
%EQUATE `HTTP_STATUS_NOT_IMPLEMENTED = 501
%EQUATE `HTTP_STATUS_BAD_GATEWAY = 502
%EQUATE `HTTP_STATUS_SERVICE_UNAVAILABLE = 503
%EQUATE `HTTP_STATUS_GATEWAY_TIMEOUT = 504

%EQUATE `HTTP_MIME_JSON = "application/json"
%EQUATE `HTTP_MIME_FORM_URLENCODED = "application/x-www-form-urlencoded"
%EQUATE `HTTP_MIME_MULTIPART_FORM_DATA = "multipart/form-data"
%EQUATE `HTTP_MIME_TEXT_PLAIN = "text/plain"
%EQUATE `HTTP_MIME_TEXT_HTML = "text/html"
%EQUATE `HTTP_MIME_OCTET_STREAM = "application/octet-stream"

#ENDIF
