ExampleWebServices_03
ExampleWebServices

Purpose

Shows how to send GET, PUT, POST, and web requests through RIDE’s common web services system.

How to Use

Run the scene, enter any input on the left-hand side, click the Send button, and see any output on the right-hand side.

Clicking the Examples button cycles through various pre-filled examples. Clicking Get, Put, or Post resets the input fields.

Scene Location & Name

\Assets\Ride\Examples\Services\WebServices\ExampleWebServices.unity

Setup Requirements 

The main script is ExampleWebServices.cs in the same folder.

SetRequestType() contains SetUIContent() with parameters to fill in the fields.

SendRequest() contains the main code for setting up and sending the request. It uses one of various functions in RideIO.cs (e.g., Post(), Put(), etc.), part of RideUtils. Most of these have overrides.

Note that RideUtils also provides a connection check: RideUtils.IsInternetConnectionAvailable()