Record Class FeishuChannelProperties

java.lang.Object
java.lang.Record
io.agentscope.extensions.channel.feishu.FeishuChannelProperties
Record Components:
appId - Feishu custom-app id (cli_xxx)
appSecret - Feishu custom-app secret
encryptKey - optional Encrypt Key configured in the developer console; when non-blank the callback body is AES-256-CBC encrypted and must be decrypted before parsing
verificationToken - optional Verification Token configured in the developer console; when non-blank the token field of the URL verification challenge is matched against it
callbackPath - HTTP path Spring exposes the callback under; defaults to /api/channels/feishu/{channelId}/callback
apiBase - override for the Feishu Open API base URL; default https://open.feishu.cn

public record FeishuChannelProperties(String appId, String appSecret, String encryptKey, String verificationToken, String callbackPath, String apiBase) extends Record
Provider-specific configuration for a single Feishu (飞书 / Lark) channel instance, sourced from the properties block of channels.<id> in agentscope.json.
  • Constructor Details

    • FeishuChannelProperties

      public FeishuChannelProperties(String appId, String appSecret, String encryptKey, String verificationToken, String callbackPath, String apiBase)
      Creates an instance of a FeishuChannelProperties record class.
      Parameters:
      appId - the value for the appId record component
      appSecret - the value for the appSecret record component
      encryptKey - the value for the encryptKey record component
      verificationToken - the value for the verificationToken record component
      callbackPath - the value for the callbackPath record component
      apiBase - the value for the apiBase record component
  • Method Details

    • from

      public static FeishuChannelProperties from(String channelId, Map<String,Object> props)
      Reads a FeishuChannelProperties from an arbitrary properties map.
    • isEncrypted

      public boolean isEncrypted()
      Whether AES-256-CBC payload decryption is enabled for this channel.
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • appId

      public String appId()
      Returns the value of the appId record component.
      Returns:
      the value of the appId record component
    • appSecret

      public String appSecret()
      Returns the value of the appSecret record component.
      Returns:
      the value of the appSecret record component
    • encryptKey

      public String encryptKey()
      Returns the value of the encryptKey record component.
      Returns:
      the value of the encryptKey record component
    • verificationToken

      public String verificationToken()
      Returns the value of the verificationToken record component.
      Returns:
      the value of the verificationToken record component
    • callbackPath

      public String callbackPath()
      Returns the value of the callbackPath record component.
      Returns:
      the value of the callbackPath record component
    • apiBase

      public String apiBase()
      Returns the value of the apiBase record component.
      Returns:
      the value of the apiBase record component