anchor.diff:  %% @end
   %%--------------------------------------------------------------------
   -spec fetch_service_configuration(onezone | {oneprovider, Domain :: binary(), Hostname :: binary()}) ->
  -    {ok, PeerVersion :: binary(), CompatibleOpVersions :: [binary()]} |
  +    {ok, json_utils:json_term()} |
       {error, {bad_response, Code :: integer(), Body :: binary()}} |
       {error, term()}.
   fetch_service_configuration(onezone) ->
  
positive.code: -spec zone_get_offline_access_idps() -> {ok, [IdP :: binary()]} | {error, term()}.
  zone_get_offline_access_idps() ->
      case fetch_service_configuration(onezone) of
          {ok, JsonMap} ->
              SupportedIdPs = maps:get(<<"supportedIdPs">>, JsonMap, []),
              {ok, lists:filtermap(fun(IdPConfig) ->
                  case maps:get(<<"offlineAccess">>, IdPConfig, false) of
                      false -> false;
  
negative.code:             {error, _} = Error ->
                  Error
          end
      catch Type:Reason ->
          ?debug_stacktrace("Cannot verify nonce for provider ~ts - nonce was '~s' - ~p:~p", [
              to_string(ProviderId), Nonce, Type, Reason
          ]),
          ?ERROR_UNAUTHORIZED
      end.
  
  