Skip to Content
🎉 New release with new features and improvements! V0.0.4 Release →
DocumentationsBsh EngineSDKInterceptorsOverview

Interceptors Overview

Interceptors allow you to modify requests and responses, or handle errors globally. They are executed in the order they are added.

There are three types of interceptors:

  1. Pre-Interceptors: Modify requests before they’re sent
  2. Post-Interceptors: Modify responses after they’re received
  3. Error Interceptors: Handle errors globally

Interceptors are useful for:

  • Adding custom headers to all requests
  • Logging requests and responses
  • Transforming data
  • Centralized error handling
  • …