From the course: The Freelance Stack: Real Project with Next.js and Strapi

Unlock this course with a free trial

Join today to access over 25,200 courses taught by industry experts.

Sign up for specific event

Sign up for specific event

So how are we going to use the camp id now to actually send off the data with the correct relationship, right? Because what we want to do is we need to have in here our relationship defined. And the way we can do that in Strapi is we can manage those relations through a REST API posting, right? We're going to send a request there and I'm first going to show you that in Postman again because maybe it's going to be a little bit easier to understand. But the the documentation on this here is actually pretty clear. So what we need to do is we need to set, we need to send some data and this here is a data that is connected, right, the restaurants here is connected to a category which is another data type in their Strapi backend. And the way they do it is just by saying connect here and then an array of all the elements it needs to be connected to. So how can we do that in our code, or how let's actually do it first in Postman? We had this participant signup here before. If I duplicate that…

Contents