get https://example.com/api/instrument//credit-ratings
Get credit ratings for an instrument.
Returns historical credit ratings from all rating agencies or a specific provider. Ratings are sorted by rating_date descending (most recent first).
Args: instrument_id: ID of the instrument provider: Optional rating agency code (case-insensitive, e.g., "ICRA", "CRISIL") latest: If true, return only the most recent rating per agency session: Database session
Returns: List of credit rating items sorted by rating_date descending
Raises: HTTPException: 404 if instrument not found or no ratings available