[Plugin] Http/s REST, blueprintable JSON and Parse REST API manager at once (VaRest)

Hi Minxies, I cannot verify iOS or HTML5, but I have just tested my project out on Android and confirm that it does work there.

Legend, I’ll try to commit once I have to skill set.

A belated Merry Christmas (if applicable :slight_smile:

Best,
James

> If you’re using plugins and want to package them you must switch you project to “C++ game”.

So this is a pretty vital piece of information I was not aware of since this is the one and only plugin I’ve used. I couldn’t get this working for a week :frowning: You should mention it on the github page.

Hi,
this plugin is awesome and thank you for developing it!
But I have a strange problem with Parse integration. It works on Windows but on Android no… Other JSON requests work good on Android… How can I resolve this problem?

Thank you.

It seems to occur only when I do HTTPS request… For example works but doesn’t work… So Parse.com (because only support HTTPS) doesn’t work on Android…

I’ve resolved above issue by setting FCurlHttpManager::CurlRequestOptions.bVerifyPeer=false.

I’ve found another problem with VaRest Parse implementation… SetField on Android doesn’t work… For Example SetField limit=2…
It can be repair by commenting 65 line in VaRestRequestJSON.cpp:
//OutText = OutText.Replace(TEXT(“=”), TEXT(“%3D”));

It now works…

Thanks for bug reports, guys! I’ve added them to issues list and will check it soon.

Does this work with the 4.7 preview?

So far i’m really liking the look of the plugin.

I had a go at installing on 4.7 preview 3 but couldn’t get it to run, so I switched back to 4.6 for now.

Edit: Seems to be working, server was playing up!

Thanks

I’m having a problem with the plugin please help, when I create a user on parse.com, it gives the error 400 {Code 201: Missing user password} However I’m already setting the password field in the json request, please help how can I fix this issue

Edit: Fixed: VaRest nodes don’t work in UMG Blueprints, I didn’t think that for what 6 hours of trying? Whatever, this plugin is amazing, cheering for .

How can I make request with “Construct Where Query”? I’ve create this node and on output is string… And where I should connect this value? “Set Field”? If yes with what “Field Name”?

Thank you,

Hi ,
I’ve found bug.
When I call multiple times “Process URL” on the same JSON Request Object I receive error:


2015.01.25-17.34.49:197][235]LogWindows: === Critical error: ===
Fatal error!

Unhandled Exception: EXCEPTION_ACCESS_VIOLATION reading address 0xffffffff

UE4Editor-VaRestPlugin.dll!UVaRestJsonObject::Reset() (0x00007ffd357c1664) + 36 bytes [e:\biblioteka\dokumenty\unreal projects\gamednastudio\chasingrobbers\plugins\varest\source\varestplugin\private\json\varestjsonobject.cpp:23]
UE4Editor-VaRestPlugin.dll!UVaRestRequestJSON::ResetResponseData() (0x00007ffd357cf2d7) + 0 bytes [e:\biblioteka\dokumenty\unreal projects\gamednastudio\chasingrobbers\plugins\varest\source\varestplugin\private\json\varestrequestjson.cpp:109]
UE4Editor-VaRestPlugin.dll!UVaRestRequestJSON::OnProcessRequestComplete() (0x00007ffd357cd36d) + 0 bytes [e:\biblioteka\dokumenty\unreal projects\gamednastudio\chasingrobbers\plugins\varest\source\varestplugin\private\json\varestrequestjson.cpp:246]
UE4Editor-VaRestPlugin.dll!TBaseUObjectMethodDelegateInstance<0,UVaRestRequestJSON,TTypeWrapper<void> __cdecl(TSharedPtr<IHttpRequest,0>,TSharedPtr<IHttpResponse,1>,bool)>::Execute() (0x00007ffd357cc17a) + 73 bytes [d:\epic games\4.6.1\engine\source\runtime\core\public\delegates\delegateinstancesimpl_variadics.inl:656]
UE4Editor-VaRestPlugin.dll!TBaseUObjectMethodDelegateInstance<0,UVaRestRequestJSON,void __cdecl(TSharedPtr<IHttpRequest,0>,TSharedPtr<IHttpResponse,1>,bool)>::ExecuteIfSafe() (0x00007ffd357cc306) + 71 bytes [d:\epic games\4.6.1\engine\source\runtime\core\public\delegates\delegateinstancesimpl_variadics.inl:737]
UE4Editor-HTTP.dll!TBaseDelegate<void,TSharedPtr<IHttpRequest,0>,TSharedPtr<IHttpResponse,1>,bool>::ExecuteIfBound() (0x00007ffd3571ddee) + 72 bytes [d:\epic games\4.6.1\engine\source\runtime\core\public\delegates\delegatesignatureimpl_variadics.inl:507]
UE4Editor-HTTP.dll!FHttpRequestWinInet::FinishedRequest() (0x00007ffd3571efac) + 78 bytes [d:\epic games\4.6.1\engine\source\runtime\online\http\private\windows\httpwininet.cpp:666]
UE4Editor-HTTP.dll!FHttpRequestWinInet::Tick() (0x00007ffd3572d8cf) + 0 bytes [d:\epic games\4.6.1\engine\source\runtime\online\http\private\windows\httpwininet.cpp:783]
UE4Editor-HTTP.dll!FHttpManager::Tick() (0x00007ffd3572d48f) + 12 bytes [d:\epic games\4.6.1\engine\source\runtime\online\http\private\httpmodule.cpp:152]
UE4Editor.exe!FTicker::Tick() (0x00007ff7f6fee757) + 32 bytes [d:\epic games\4.6.1\engine\source\runtime\core\public\containers	icker.h:78]
UE4Editor.exe!FEngineLoop::Tick() (0x00007ff7f6fede8c) + 0 bytes [d:\epic games\4.6.1\engine\source\runtime\launch\private\launchengineloop.cpp:2307]
UE4Editor.exe!GuardedMain() (0x00007ff7f6fe1afe) + 0 bytes [d:\epic games\4.6.1\engine\source\runtime\launch\private\launch.cpp:131]
UE4Editor.exe!GuardedMainWrapper() (0x00007ff7f6fe1b6a) + 5 bytes [d:\epic games\4.6.1\engine\source\runtime\launch\private\windows\launchwindows.cpp:126]
UE4Editor.exe!WinMain() (0x00007ff7f6feecd9) + 17 bytes [d:\epic games\4.6.1\engine\source\runtime\launch\private\windows\launchwindows.cpp:202]
UE4Editor.exe!__tmainCRTStartup() (0x00007ff7f6fefca9) + 21 bytes [f:\dd\vctools\crt\crtw32\dllstuff\crtexe.c:618]
KERNEL32.DLL!UnknownFunction (0x00007ffd6b9416ad) + 0 bytes [UnknownFile:0]
ntdll.dll!UnknownFunction (0x00007ffd6d964409) + 0 bytes [UnknownFile:0]
ntdll.dll!UnknownFunction (0x00007ffd6d964409) + 0 bytes [UnknownFile:0]

It’s probably because of 102 line in VaRestRequestJSON.cpp:


void UVaRestRequestJSON::ResetResponseData()
{
	if (ResponseJsonObj != NULL)
	{
		ResponseJsonObj->Reset();
	}
	else
	{
		ResponseJsonObj = (UVaRestJsonObject*)StaticConstructObject(UVaRestJsonObject::StaticClass());
	}

	bIsValidJsonResponse = false;
}

When I change this to:


void UVaRestRequestJSON::ResetResponseData()
{
	ResponseJsonObj = (UVaRestJsonObject*)StaticConstructObject(UVaRestJsonObject::StaticClass());

	bIsValidJsonResponse = false;
}

it works but I don’t know if this is correct…

, what do you think about that?

It should be used instead “regular” query constructor when you’re using Parse Object quering with “where” condition. That’s all the difference from regular one :slight_smile:

Thanks for the bug report, I’ve put it here (https://github.com//VaRest/issues/21) and will check it soon.

So with this plugin i can sent GET requests to my server? Can i also get data from my server?

All of your answers are here.

https://camo.githubusercontent.com/f05dd0c57d39ff3c225ae9008d1a075574f70f6d/687474703a2f2f75666e612e72752f6769746875622f7661726573742f7661726573745f6578616d706c655f73696d706c656765742e6a7067

Hello , looking forward to the 4.7 version. Unfortunately, I cannot run the 4.6 version:(

Hey TechLord. You shouldn’t have to wait for an official 4.7 release. The current version, 1.1-rc7 runs just fine after you click “Rebuild” when the editor asks you to when you first launch after adding the plugin to your project folder.

HI , I have been working with Codespartan in his MMOKit, and I have a problem that he recommended I you over… It kinda resembles this quote… I have sent you a PM when you have time

@: Most of your examples are posting a “X Www Form Urlencoded” but I can’t find any using a JSON post. Do you have an example for me?

My web-service that I wrote requires a JSON object to be posted to it and not a Form. Do you have any examples for me?

This is an awesome plugin by the way and works right out of the box. Thanks. 8-}

EDIT: Never mind, got it working … thanks. 8-}

@: Didn’t want to do a seperate post, but I thought it prudent that I do so the post doesn’t get lost in the noise.

I am getting an Access violation on the code now when I try to re-trigger a call every 60 seconds.


MachineId:83E94F694A619D4FDC606593D8878EF9

Access violation - code c0000005 (first/second chance not available)

UE4Editor_VaRestPlugin!UVaRestJsonObject::Reset() + 84 bytes [c:\development\gobbo games\kaboom arena\kaboomarena\plugins\varest\source\varestplugin\private\json\varestjsonobject.cpp:23]
UE4Editor_VaRestPlugin!UVaRestRequestJSON::ResetResponseData() + 23 bytes [c:\development\gobbo games\kaboom arena\kaboomarena\plugins\varest\source\varestplugin\private\json\varestrequestjson.cpp:109]
UE4Editor_VaRestPlugin!UVaRestRequestJSON::OnProcessRequestComplete() + 61 bytes [c:\development\gobbo games\kaboom arena\kaboomarena\plugins\varest\source\varestplugin\private\json\varestrequestjson.cpp:242]
UE4Editor_VaRestPlugin!TBaseUObjectMethodDelegateInstance<0,UVaRestRequestJSON,TTypeWrapper<void> __cdecl(TSharedPtr<IHttpRequest,0>,TSharedPtr<IHttpResponse,1>,bool)>::Execute() + 328 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\core\public\delegates\delegateinstancesimpl_variadics.inl:681]
UE4Editor_VaRestPlugin!TBaseUObjectMethodDelegateInstance<0,UVaRestRequestJSON,void __cdecl(TSharedPtr<IHttpRequest,0>,TSharedPtr<IHttpResponse,1>,bool)>::ExecuteIfSafe() + 327 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\core\public\delegates\delegateinstancesimpl_variadics.inl:770]
UE4Editor_HTTP!TBaseDelegate<void,TSharedPtr<IHttpRequest,0>,TSharedPtr<IHttpResponse,1>,bool>::ExecuteIfBound() + 142 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\core\public\delegates\delegatesignatureimpl_variadics.inl:518]
UE4Editor_HTTP!FHttpRequestWinInet::FinishedRequest() + 1724 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\online\http\private\windows\httpwininet.cpp:666]
UE4Editor_HTTP!FHttpRequestWinInet::Tick() + 687 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\online\http\private\windows\httpwininet.cpp:783]
UE4Editor_HTTP!FHttpManager::Tick() + 143 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\online\http\private\httpmodule.cpp:152]
UE4Editor!FTicker::Tick() + 700 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\core\public\containers	icker.h:90]
UE4Editor!FEngineLoop::Tick() + 6356 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\launch\private\launchengineloop.cpp:2352]
UE4Editor!GuardedMain() + 1404 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\launch\private\launch.cpp:142]
UE4Editor!GuardedMainWrapper() + 26 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\launch\private\windows\launchwindows.cpp:126]
UE4Editor!WinMain() + 249 bytes [c:\development\epic games\source\unrealengine\engine\source\runtime\launch\private\windows\launchwindows.cpp:202]
UE4Editor!__tmainCRTStartup() + 329 bytes [f:\dd\vctools\crt\crtw32\dllstuff\crtexe.c:618]

I have tried this in various blueprints and even as a blueprint on the map … so I am not sure if I am missing something.