Class: McpAuthenticator::AuthResult

Inherits:
Struct
  • Object
show all
Includes:
ScopedServices
Defined in:
app/mcp/mcp_authenticator.rb

Overview

Result of successful authentication via ApiAuthentication token.
Service access is the token's permitted_services ∩ the account's own grant.

Instance Attribute Summary collapse

Delegated Instance Attributes collapse

Instance Method Summary collapse

Methods included from ScopedServices

#can_access_service?, #scoped_to_account

Instance Attribute Details

#accountObject

Returns the value of attribute account

Returns:

  • (Object)

    the current value of account



91
92
93
# File 'app/mcp/mcp_authenticator.rb', line 91

def 
  @account
end

#api_authenticationObject

Returns the value of attribute api_authentication

Returns:

  • (Object)

    the current value of api_authentication



91
92
93
# File 'app/mcp/mcp_authenticator.rb', line 91

def api_authentication
  @api_authentication
end

Instance Method Details

#account_nameObject



100
101
102
# File 'app/mcp/mcp_authenticator.rb', line 100

def 
  .full_name
end

#effective_servicesObject



96
97
98
# File 'app/mcp/mcp_authenticator.rb', line 96

def effective_services
  (api_authentication.effective_services)
end

#oauth?Boolean

Returns:

  • (Boolean)


104
105
106
# File 'app/mcp/mcp_authenticator.rb', line 104

def oauth?
  false
end

#permitted_servicesObject

Alias for Api_authentication#permitted_services

Returns:

  • (Object)

    Api_authentication#permitted_services

See Also:



94
# File 'app/mcp/mcp_authenticator.rb', line 94

delegate :permitted_services, to: :api_authentication