Symfony RESTful API: Errors (Course 2)
Offered By: SymfonyCasts
Course Description
Overview
In course 1, we added our basic endpoints with some nice tests (yes!).
Now, we turn to a huge part of APIs: handling and returning consistent errors. Seriously, this is more important than you might think - which is why we're covering this in episode 2.
So, let's handle errors, and let's do it gracefully:
- Handling Form Validation errors and response
- Disabling csrf_protection
- Introducing the api-problem JSON format
- Exception Listener!
- Consistent errors everywhere: 404's, 500's, oh my!
- Handling "extra fields" in your form
Syllabus
- Validation Errors Test
- Sending back Validation Errors
- PUT Validation and CSRF Tokens
- 99 api/problem+json(s)
- Modeling the Error: ApiProblem Class
- Keeping Problem types Consistent
- The All-Important HttpExceptionInterface
- Creating the Invalid JSON ApiProblem, and then...
- ApiProblemException
- Request Format: Why Exceptions Return HTML
- Global RESTful Exception Handling
- Handling 404's + other Errors
- The Helpful Detail Key
- Debugging and Cleanup
Taught by
Ryan Weaver and Leanna Pelham
Related Courses
MongoDB for DBAsMongoDB University MongoDB for Node.js Developers
MongoDB University Web Engineering II: Developing Mobile HTML5 Apps
Technische Hochschule Mittelhessen via iversity Programming Mobile Services for Android Handheld Systems: Communication
Vanderbilt University via Coursera HTML, CSS, and Javascript for Web Developers
Johns Hopkins University via Coursera