res://addons/w4gd/rest-client/client.gd
Inherits: RefCounted
A generic REST client.
Properties
String |
||
Callable |
||
PackedStringArray |
||
TLSOptions |
|
|
Node |
Methods
DELETE ( Variant path, Variant data, Dictionary query, Dictionary extra_headers ) |
|
GET ( Variant path, Dictionary query, Dictionary extra_headers ) |
|
HEAD ( Variant path, Dictionary query, Dictionary extra_headers ) |
|
PATCH ( Variant path, Variant data, Dictionary query, Dictionary extra_headers ) |
|
POST ( Variant path, Variant data, Dictionary query, Dictionary extra_headers ) |
|
PUT ( Variant path, Variant data, Dictionary query, Dictionary extra_headers ) |
|
Dictionary |
dict_from_query ( String query ) |
void |
headers_from_dict ( Dictionary headers ) |
String |
query_from_dict ( Dictionary query ) |
void |
set_header ( String header, Variant value ) |
Property Descriptions
String base_url
The base URL.
Callable data_formatter
A callback for formatting request data.
PackedStringArray default_headers
The default request headers.
TLSOptions default_tls_options = null
The default TLSOptions.
Node node
A node in the scene tree that we can add HTTPRequests to.
Method Descriptions
res://addons/w4gd/rest-client/client_request.gd DELETE ( Variant path, Variant data, Dictionary query, Dictionary extra_headers )
Makes a DELETE request.
res://addons/w4gd/rest-client/client_request.gd GET ( Variant path, Dictionary query, Dictionary extra_headers )
Makes a GET request.
res://addons/w4gd/rest-client/client_request.gd HEAD ( Variant path, Dictionary query, Dictionary extra_headers )
Makes a HEAD request.
res://addons/w4gd/rest-client/client_request.gd PATCH ( Variant path, Variant data, Dictionary query, Dictionary extra_headers )
Makes a PATCH request.
res://addons/w4gd/rest-client/client_request.gd POST ( Variant path, Variant data, Dictionary query, Dictionary extra_headers )
Makes a POST request.
res://addons/w4gd/rest-client/client_request.gd PUT ( Variant path, Variant data, Dictionary query, Dictionary extra_headers )
Makes a PUT request.
Dictionary dict_from_query ( String query )
Parses an HTTP query string into a Dictionary.
void headers_from_dict ( Dictionary headers )
Makes a PackedStringArray combining the default HTTP headers with the given headers.
String query_from_dict ( Dictionary query )
Returns an HTTP query string from the given Dictionary.
void set_header ( String header, Variant value )
Sets a default HTTP header.