aboutsummaryrefslogtreecommitdiffstats
path: root/teal-src/net/http/errors.d.tl
diff options
context:
space:
mode:
Diffstat (limited to 'teal-src/net/http/errors.d.tl')
-rw-r--r--teal-src/net/http/errors.d.tl22
1 files changed, 22 insertions, 0 deletions
diff --git a/teal-src/net/http/errors.d.tl b/teal-src/net/http/errors.d.tl
new file mode 100644
index 00000000..a9b6ea6c
--- /dev/null
+++ b/teal-src/net/http/errors.d.tl
@@ -0,0 +1,22 @@
+local record http_errors
+ enum known_conditions
+ "cancelled"
+ "connection-closed"
+ "certificate-chain-invalid"
+ "certificate-verify-failed"
+ "connection failed"
+ "invalid-url"
+ "unable to resolve service"
+ end
+ type registry_keys = known_conditions | integer
+ record error
+ type : string
+ condition : string
+ code : integer
+ text : string
+ end
+ registry : { registry_keys : error }
+ new : function (integer, known_conditions, table)
+ new : function (integer, string, table)
+end
+return http_errors