Created page with "{{#Invoke:ProtoFlux|GenerateUI |Name=GET String |Category=Network |Inputs= [ {"Name":"*", "Type":"IAsyncOperation"}, {"Name":"URL", "Type":"Uri"} ] |Outputs= [ {"Name":"OnSent", "Type":"AsyncCall"}, {"Name":"OnResponse", "Type":"Continuation"}, {"Name":"OnError", "Type":"Continuation"}, {"Name":"OnDenied", "Type":"Continuation"}, {"Name":"StatusCode", "Type":"StatusCode"}, {"Name":"Content", "Type":"String"} ] |}} GET String sends a HTTP request with GET method on call..." |
try to add info, and fix visual |
||
Line 4: | Line 4: | ||
|Inputs= | |Inputs= | ||
[ | [ | ||
{"Name":"*", "Type":" | {"Name":"*", "Type":"AsyncCall"}, | ||
{"Name":"URL", "Type":"Uri"} | {"Name":"URL", "Type":"Uri"} | ||
] | ] | ||
Line 19: | Line 19: | ||
GET String sends a HTTP request with GET method on call and decode its content as if the response has header of <code>Content-Type: plain/text; charset=utf-8</code>. So this is not suitable for binary-transmission. | GET String sends a HTTP request with GET method on call and decode its content as if the response has header of <code>Content-Type: plain/text; charset=utf-8</code>. So this is not suitable for binary-transmission. | ||
{{Note|This node is best used with an impulse from the client actually wanting to fulfill the data transfer task. See [[Connecting_Resonite_to_Other_Applications#Security / Consent|Security/Consent and surrounding info.]]|information}} | |||
== Inputs == | |||
=== * ([[Impulses|AsyncCall]]) === | |||
Trigger to send a get request with a header of <code>Content-Type: plain/text; charset=utf-8</code> to the URL ([[Type:Uri|Uri]]) server location | |||
=== URL ([[Type:Uri|Uri]]) === | |||
The server location to send the get request to. | |||
== Outputs == | |||
=== OnSent ([[Impulses|AsyncCall]]) === | |||
Fires immediately after the request is sent, so multiple async functions can happen in parallel. | |||
=== OnResponse ([[Impulses|Continuation]]) === | |||
Fires after the server has responded with either (TODO: Which responses are valid?) HTTP code and sent a string based response. The node will output these to their respective outputs during this pulse. | |||
=== OnError ([[Impulses|Continuation]]) === | |||
{{Stub}} | |||
=== OnDenied ([[Impulses|Continuation]]) === | |||
{{Stub}} | |||
=== StatusCode ([[Type:HttpStatusCode|HTTP Status Code]]) === | |||
The code that the server responded with, no matter if it failed, was denied, succeeded at a response, or returned an error. This only exists during the OnResponse ([[Impulses|Continuation]]), OnError ([[Impulses|Continuation]]), and OnDenied ([[Impulses|Continuation]]) impulses. | |||
=== Content ([[Type:String|String]]) === | |||
The response that the server gave if it was a string. This only exists during the OnResponse ([[Impulses|Continuation]]) impulse. | |||
[[Category:ProtoFlux:Networking]] |
Revision as of 16:22, 12 April 2024
GET String sends a HTTP request with GET method on call and decode its content as if the response has header of Content-Type: plain/text; charset=utf-8
. So this is not suitable for binary-transmission.
Inputs
* (AsyncCall)
Trigger to send a get request with a header of Content-Type: plain/text; charset=utf-8
to the URL (Uri) server location
URL (Uri)
The server location to send the get request to.
Outputs
OnSent (AsyncCall)
Fires immediately after the request is sent, so multiple async functions can happen in parallel.
OnResponse (Continuation)
Fires after the server has responded with either (TODO: Which responses are valid?) HTTP code and sent a string based response. The node will output these to their respective outputs during this pulse.
OnError (Continuation)
This article or section is a Stub. You can help the Resonite Wiki by expanding it.
OnDenied (Continuation)
This article or section is a Stub. You can help the Resonite Wiki by expanding it.
StatusCode (HTTP Status Code)
The code that the server responded with, no matter if it failed, was denied, succeeded at a response, or returned an error. This only exists during the OnResponse (Continuation), OnError (Continuation), and OnDenied (Continuation) impulses.
Content (String)
The response that the server gave if it was a string. This only exists during the OnResponse (Continuation) impulse.