@tool
extends TwitchData

# CLASS GOT AUTOGENERATED DON'T CHANGE MANUALLY. CHANGES CAN BE OVERWRITTEN EASILY.

class_name TwitchUpdateUserExtensions
	


## 
## #/components/schemas/UpdateUserExtensionsBody
class Body extends TwitchData:

	## The extensions to update. The `data` field is a dictionary of extension types. The dictionary’s possible keys are: panel, overlay, or component. The key’s value is a dictionary of extensions.  
	##   
	## For the extension’s dictionary, the key is a sequential number beginning with 1\. For panel and overlay extensions, the key’s value is an object that contains the following fields: `active` (true/false), `id` (the extension’s ID), and `version` (the extension’s version).  
	##   
	## For component extensions, the key’s value includes the above fields plus the `x` and `y` fields, which identify the coordinate where the extension is placed.
	@export var data: BodyData:
		set(val): 
			data = val
			track_data(&"data", val)
	var response: BufferedHTTPClient.ResponseData
	
	
	## Constructor with all required fields.
	static func create(_data: BodyData) -> Body:
		var body: Body = Body.new()
		body.data = _data
		return body
	
	
	static func from_json(d: Dictionary) -> Body:
		var result: Body = Body.new()
		if d.get("data", null) != null:
			result.data = BodyData.from_json(d["data"])
		return result
	


## The extensions to update. The `data` field is a dictionary of extension types. The dictionary’s possible keys are: panel, overlay, or component. The key’s value is a dictionary of extensions.  
##   
## For the extension’s dictionary, the key is a sequential number beginning with 1\. For panel and overlay extensions, the key’s value is an object that contains the following fields: `active` (true/false), `id` (the extension’s ID), and `version` (the extension’s version).  
##   
## For component extensions, the key’s value includes the above fields plus the `x` and `y` fields, which identify the coordinate where the extension is placed.
## #/components/schemas/UpdateUserExtensionsBody/Data
class BodyData extends TwitchData:

	## 
	@export var panel: Dictionary:
		set(val): 
			panel = val
			track_data(&"panel", val)
	
	## 
	@export var overlay: Dictionary:
		set(val): 
			overlay = val
			track_data(&"overlay", val)
	
	## 
	@export var component: Dictionary:
		set(val): 
			component = val
			track_data(&"component", val)
	
	
	
	## Constructor with all required fields.
	static func create() -> BodyData:
		var body_data: BodyData = BodyData.new()
		return body_data
	
	
	static func from_json(d: Dictionary) -> BodyData:
		var result: BodyData = BodyData.new()
		if d.get("panel", null) != null:
			result.panel = d["panel"]
		if d.get("overlay", null) != null:
			result.overlay = d["overlay"]
		if d.get("component", null) != null:
			result.component = d["component"]
		return result
	


## 
## #/components/schemas/UpdateUserExtensionsResponse
class Response extends TwitchData:

	## The extensions that the broadcaster updated.
	@export var data: ResponseData:
		set(val): 
			data = val
			track_data(&"data", val)
	var response: BufferedHTTPClient.ResponseData
	
	
	## Constructor with all required fields.
	static func create(_data: ResponseData) -> Response:
		var response: Response = Response.new()
		response.data = _data
		return response
	
	
	static func from_json(d: Dictionary) -> Response:
		var result: Response = Response.new()
		if d.get("data", null) != null:
			result.data = ResponseData.from_json(d["data"])
		return result
	


## The extensions that the broadcaster updated.
## #/components/schemas/UpdateUserExtensionsResponse/Data
class ResponseData extends TwitchData:

	## A dictionary that contains the data for a panel extension. The dictionary’s key is a sequential number beginning with 1\. The following fields contain the panel’s data for each key.
	@export var panel: Dictionary:
		set(val): 
			panel = val
			track_data(&"panel", val)
	
	## A dictionary that contains the data for a video-overlay extension. The dictionary’s key is a sequential number beginning with 1\. The following fields contain the overlay’s data for each key.
	@export var overlay: Dictionary:
		set(val): 
			overlay = val
			track_data(&"overlay", val)
	
	## A dictionary that contains the data for a video-component extension. The dictionary’s key is a sequential number beginning with 1\. The following fields contain the component’s data for each key.
	@export var component: Dictionary:
		set(val): 
			component = val
			track_data(&"component", val)
	
	
	
	## Constructor with all required fields.
	static func create(_panel: Dictionary, _overlay: Dictionary, _component: Dictionary) -> ResponseData:
		var response_data: ResponseData = ResponseData.new()
		response_data.panel = _panel
		response_data.overlay = _overlay
		response_data.component = _component
		return response_data
	
	
	static func from_json(d: Dictionary) -> ResponseData:
		var result: ResponseData = ResponseData.new()
		if d.get("panel", null) != null:
			result.panel = d["panel"]
		if d.get("overlay", null) != null:
			result.overlay = d["overlay"]
		if d.get("component", null) != null:
			result.component = d["component"]
		return result
	