Skip to content

Latest commit

 

History

History
28 lines (18 loc) · 844 Bytes

README.md

File metadata and controls

28 lines (18 loc) · 844 Bytes

project icon: syntax-highlighted text reading 'await http dot request'

AwaitableHTTPRequest Node for Godot 4

This addon makes HTTP requests much more convenient to use by introducing the await-syntax and removing the need for signals.

Usage

extends AwaitableHTTPRequest

func _ready() -> void:
	var resp := await async_request("https://api.github.com/users/swarkin")
	if resp.success() and resp.status_ok():
		print(resp.status)                   # 200
		print(resp.headers["content-type"])  # application/json

		var json = resp.body_as_json()
		print(json["login"])                 # Swarkin

See examples.tscn for more.


Available on the Godot Asset Library

Requires Godot 4.1