skillworkspaceError Handlingintermediate

MuleSoft Error Handling Scaffold

Scaffolds a global error handler configuration for a Mule application with standard HTTP error mappings.

(0 reviews)
0 forks
MC
by MuleSoft Community
Name
mulesoft-error-handling
Description
Scaffold global error handler with HTTP error mappings for Mule apps
Scope
workspace
Activates when
When the user asks to add error handling to a Mule project

Skill Instructions

When the user asks about error handling in a Mule project:

  1. Create a global-error-handler.xml in src/main/mule/
  2. Map common Mule errors to HTTP status codes:
    • APIKIT:BAD_REQUEST → 400
    • APIKIT:NOT_FOUND → 404
    • APIKIT:METHOD_NOT_ALLOWED → 405
    • HTTP:UNAUTHORIZED → 401
    • HTTP:TIMEOUT → 504
    • ANY → 500
  3. Include correlation ID in all error responses
  4. Add structured JSON error response body
  5. Reference the handler in all flow files

Community Results

0 people tried this

Sign in to share your experience with this prompt.

Tags

error-handlingscaffoldglobal-handler

Reviews (0)

Sign in to leave a review.

No reviews yet. Be the first to share your experience!

Comments (0)

Sign in to leave a comment.

No comments yet. Be the first to share your thoughts!