class Discorb::Application
Represents a Discord application.
Attributes
@return [Boolean] Whether the application's bot is public.
@return [Boolean] Whether the application's bot is public.
@return [Boolean] Whether the application's bot requires a code grant.
@return [Boolean] Whether the application's bot requires a code grant.
@return [String] The application's description.
@return [Discorb::Asset] The application's icon.
@return [Discorb::Snowflake] The application's ID.
@return [String] The application's name.
@return [Discorb::User] The application's owner.
@return [Boolean] Whether the application's bot is public.
@return [Boolean] Whether the application's bot requires a code grant.
@return [String] The application's summary.
@return [Discorb::Application::Team] The application's team.
@return [String] The application's public key.
Public Class Methods
@!visibility private
# File lib/discorb/application.rb, line 32 def initialize(client, data) @client = client @data = data @id = Snowflake.new(data[:id]) @name = data[:name] @icon = Asset.new(self, data[:icon]) @description = data[:description] @summary = data[:summary] @bot_public = data[:bot_public] @bot_require_code_grant = data[:bot_require_code_grant] @verify_key = data[:verify_key] @owner = @client.users[data[:owner][:id]] || User.new(@client, data[:owner]) @team = data[:team] && Team.new(@client, data[:team]) end
Public Instance Methods
# File lib/discorb/application.rb, line 47 def inspect "#<#{self.class} id=#{@id}>" end