Let's create a CRUD Rest API in C# (or C sharp), using:
.NET 7
ASP.NET (Framework for building web apps)
Entity Framework (ORM)
Postgres (Databa...
For further actions, you may consider blocking this person and/or reporting abuse
Is there expected
PostUser
?return CreatedAtAction(nameof(PostUser), new { id = user.Id }, user);
Check your code formatting. On iOS Chrome at least it’s garbled.
do you mean the brackts?
We see:
oh there was a trailing backtick. solved thanks.
Thanks for the cool tutorial, also watched your video thanks very much!
Not sure if anyone else picked this up from the walkthrough guide on this page above, at the section where we get users? Its pointing to port 8000 which is invalid and the users only return on port 8080, which is correct in accordance with our configs...
The guide here on this page just says otherwise...
📝 Get all users
To get all users, make a GET request to localhost:8000/api/users.
The output should be something like that:
oh I will check that, thank you! maybe I was using a different port on that specific part!
You could also add validation for User type to prevent incorrect data and reject request on start, not during writing to database. Obviously that will give you ability to check other things such as e.g. format of e-mail addresses.
that would probably be a good idea
Very nice - just a question of if it is on purpose that you skipped the explanation of your docker files?
fixed, thanks
I repeated all steps this awesome guide, but face the problem with creating a user:
MessageText: relation "users" does not exist
I fixed it renaming all colums and table to lower case, and it works.
you are correct. I adapted the c# code for a better readability but left the old SQL file. nice catch.
Super helpful, really helped launch my app. Thank you!
you are welcome Joe
Can you do a part 2 using entity migrations?
that's actually a good idea
Awesome article @francescoxx I really enjoyed the read.
Please keep it up.
you are welcome Lionel!
👍
🔥🔥
I want to purchase
a Web application complete source code to send WhatsApp Bulk Message.
Preferred technology : Asp.net C# MVC or Core
Please message me if you have .
Whatsapp: 9125474034