Class: LLM::A2A::Card::Interface

Inherits:
Object
  • Object
show all
Defined in:
lib/llm/a2a/card/interface.rb

Overview

Represents a protocol interface supported by the agent.

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ Interface

Returns a new instance of Interface.

Parameters:

  • data (Hash)


9
10
11
# File 'lib/llm/a2a/card/interface.rb', line 9

def initialize(data)
  @data = LLM::Object.from(data)
end

Instance Method Details

#urlString

Returns the interface URL.

Returns:

  • (String)


16
17
18
# File 'lib/llm/a2a/card/interface.rb', line 16

def url
  @data.url
end

#protocol_bindingString

Returns the protocol binding name.

Returns:

  • (String)


23
24
25
# File 'lib/llm/a2a/card/interface.rb', line 23

def protocol_binding
  @data.protocolBinding || @data.protocol_binding
end

#protocol_versionString

Returns the A2A protocol version.

Returns:

  • (String)


30
31
32
# File 'lib/llm/a2a/card/interface.rb', line 30

def protocol_version
  @data.protocolVersion || @data.protocol_version
end