def METHOD_NAME(
    notification: BaseNotification,
    recipients: Iterable[RpcActor],
    shared_context: Mapping[str, Any],
    extra_context_by_actor: Mapping[RpcActor, Mapping[str, Any]] | None,
):
    if not is_supported_notification_type(notification):
        logger.info(
            f"Unsupported notification type for Microsoft Teams {notification.__class__.__name__}"
        )
        return
    with sentry_sdk.start_span(
        op="notification.send_msteams", description="gen_channel_integration_map"
    ):
        data = get_integrations_by_channel_by_recipient(
            organization=notification.organization,
            recipients=recipients,
            provider=ExternalProviders.MSTEAMS,
        )
        for recipient, integrations_by_channel in data.items():
            with sentry_sdk.start_span(op="notification.send_msteams", description="send_one"):
                extra_context = (extra_context_by_actor or {}).get(recipient, {})
                context = get_context(notification, recipient, shared_context, extra_context)
                with sentry_sdk.start_span(
                    op="notification.send_msteams", description="gen_attachments"
                ):
                    card = get_notification_card(notification, context, recipient)
                for channel, integration in integrations_by_channel.items():
                    conversation_id = get_user_conversation_id(integration, channel)
                    client = MsTeamsClient(integration)
                    try:
                        with sentry_sdk.start_span(
                            op="notification.send_msteams", description="notify_recipient"
                        ):
                            client.send_card(conversation_id, card)
                        notification.record_notification_sent(recipient, ExternalProviders.MSTEAMS)
                    except Exception as e:
                        logger.error(
                            "Exception occured while trying to send the notification", exc_info=e
                        )
    metrics.incr(
        f"{notification.metrics_key}.notifications.sent",
        instance=f"msteams.{notification.metrics_key}.notification",
        skip_internal=False,
    )