At this point our stream form is just about complete.
We've got the necessary fields of title and description and we are doing some validation around the
inputs that the user enters in.
So now we need to think about what we're going to do when a user finally successfully submits the form.
So we've got the on Smick callback right here.
But the question is all right we've got the form values how do we actually create a stream.
So in this video I want to focus a little bit more on the high level architecture of our overall project.
OK so you've taken a look at this diagram right here before remember.
The idea here is that we've got our application running inside the viewers browser.
We're going to have this API server over here that tells the browser what streams exist inside of our
application.
And then at some point in time the user's browser is going to reach out to this RCMP server thing and
attempt to get some video feed from someone who is currently streaming video.
So the real question here around this entire application around what we're doing with the form submission
is really how do we communicate from our re-act application up to this API server and tell the API server
that there is now a new stream that is available for viewing.
So we're really trying to do.
We're trying to take the title and description and put it up to this API server so that other users
can fetch a list of all the different available streams.
Now to give you a better idea of what this API server is doing let's check out one other diagram here.
All right so are our API server is essentially going to have a plain list of records.
Each record is going to represent one individual stream and each stream is going to have in ID a title
of the stream and a description.
So we're going to take the list of streams right from the API server and send them down to our re-act
application and show them on the screen.
Then whenever a user selects say stream 2 we're going to make sure that our re-act application reaches
out to the RCMP server and says Hey I'm trying to see a stream with the idea of two.
And so the RCMP server is going to take whatever stream with I.T. to come in and stream that video over
to our re-act application.
Now again we don't really need to worry too much about the streaming side of things here.
Don't let the streaming stuff throw you off at all at the end of the day.
All we are really doing is trying to take that title and description and post those records via a network
request.
Up to this API server.
So now the question really turns into.
All right.
Yeah we get it.
We're going to take the title in description from our form and try to create some new record on that
API server.
But what exactly is the API server.
Well to be honest the API server is going to be extremely easy for us to put together.
Let's take a quick pause right here and when we come back next section I'll tell you exactly how we're
going to put the server together and show you exactly how easy and simple it's going to be.