# Observability through Router

To move beyond connectivity, the AA ecosystem also needs **visibility**. Observability ensures that FIUs, AAs, FIPs, and Sahamati can measure performance, identify bottlenecks, and generate reliable metrics across the network.

#### Approaches for Passing Attributes to Router

There were two possible ways to capture and pass the required observability attributes:

1. **Directly by Entities**\
   Each entity (FIU, FIP, or AA) could add the required fields to the `x-request-meta` or `x-response-meta` headers while routing through the Router.

   * **Challenge**: Any addition or removal of fields would require **every entity** to update their implementation, leading to high coordination effort, delays, and resource overhead.

2. **Router Integration Helper (RIH) – Chosen Approach**\
   To avoid this complexity, Sahamati designed the **Router Integration Helper (RIH)**.

   * The RIH is a containerized service that each entity can deploy within their infrastructure.
   * Before making an API call to the Router, the entity makes an API call to the **RIH**, passing the following inputs:
     * `rebitAPIEndpoint`&#x20;
     * `rebitRequestBody`  or `rebitResponseBody`
     * `recipient-id`&#x20;
     * `customer-id`&#x20;
   * The RIH extracts the required header fields, enriches them, and returns an encrypted response. This enriched payload is then passed to the Router.
   * If the required fields ever change in the future, entities simply update their **RIH container** instead of modifying their own application code.

   ####

#### Integration with Central Registry (CR)

After a call is made to the RIH, it queries the **Central Registry (CR)** to fetch the **host URL**. This determines whether the recipient entity is on the Router network. The host URL returned by the CR is then used to forward the enriched request via the Router.

#### Deployment Model

* **MVP Phase**: Sahamati will host and manage the RIH centrally in its infrastructure.
* **Production Phase**: Each entity will deploy and maintain the RIH container in their own infrastructure

<figure><img src="https://2423266439-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FCKUjTKikPLYOjZEtClEd%2Fuploads%2FODQhXvVyFnSqicLFVUPW%2Fimage.png?alt=media&#x26;token=f7e560aa-9bca-49ce-ac9f-ae4b27b7e0d2" alt=""><figcaption></figcaption></figure>

For the complete list of captured fields and their mapping, see [Observability attributes](https://developer.sahamati.org.in/sahamatinet-mvp/integration-steps/integration-with-router/observability-through-router/observability-attributes)
