class_docstr: Authentication context within the scope of a single request.
  
  Auth providers are keyed within an `AuthContext` by arbitrary
  unique keys. It may often make sense for the key used for an
  auth provider to simply be that provider's type object.
docstr: Get an auth token from the auth provider with the given key.
  
  If successful, the result will be cached on this auth context.
  If unsuccessful, nothing will be cached, so a future call will
  invoke the underlying `AuthProvider.authenticate` method again.
  
  This method is not thread-safe. If multiple threads share an
  auth context for a single request, then they must synchronize
  externally when calling this method.
  
  Returns:
    The result of `provider.authenticate(...)` for the auth
    provider specified by `provider_key`.
  
  Raises:
    KeyError: If the given `provider_key` does not correspond to
      any registered `AuthProvider`.
    Exception: As raised by the underlying `AuthProvider`.
docstr_tok: ["Get","an","auth","token","from","the","auth","provider","with","the","given","key",".","If","successful",",","the","result","will","be","cached","on","this","auth","context",".","If","unsuccessful",",","nothing","will","be","cached",",","so","a","future","call","will","invoke","the","underlying","`","AuthProvider.authenticate","`","method","again",".","This","method","is","not","thread-safe",".","If","multiple","threads","share","an","auth","context","for","a","single","request",",","then","they","must","synchronize","externally","when","calling","this","method",".","Returns",":","The","result","of","`","provider.authenticate","(","...",")","`","for","the","auth","provider","specified","by","`","provider_key","`",".","Raises",":","KeyError",":","If","the","given","`","provider_key","`","does","not","correspond","to","any","registered","`","AuthProvider","`",".","Exception",":","As","raised","by","the","underlying","`","AuthProvider","`","."]
code: def get(self, provider_key):
      """Get an auth token from the auth provider with the given key.
  
      If successful, the result will be cached on this auth context.
      If unsuccessful, nothing will be cached, so a future call will
      invoke the underlying `AuthProvider.authenticate` method again.
  
      This method is not thread-safe. If multiple threads share an
      auth context for a single request, then they must synchronize
      externally when calling this method.
  
      Returns:
        The result of `provider.authenticate(...)` for the auth
        provider specified by `provider_key`.
  
      Raises:
        KeyError: If the given `provider_key` does not correspond to
          any registered `AuthProvider`.
        Exception: As raised by the underlying `AuthProvider`.
      """
      provider = self._providers[provider_key]
      sentinel = object()
      value = self._cache.get(provider_key, sentinel)
      if value is not sentinel:
          return value
      value = provider.authenticate(self._environ)
      self._cache[provider_key] = value
      return value
  
imports: import abc
label_desc: Use image node_id 3 for calling the AuthContext obj's underlying member method code with example usage: obj.get(provider_key) and returns: value, value