1423 lines
44 KiB
Go
1423 lines
44 KiB
Go
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
// versions:
|
|
// protoc-gen-go v1.36.11
|
|
// protoc v7.35.1
|
|
// source: chat.proto
|
|
|
|
package proto
|
|
|
|
import (
|
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
|
|
reflect "reflect"
|
|
sync "sync"
|
|
unsafe "unsafe"
|
|
)
|
|
|
|
const (
|
|
// Verify that this generated code is sufficiently up-to-date.
|
|
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
|
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
|
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
)
|
|
|
|
// AuthorType is the kind of identity a message author has. HUMAN covers
|
|
// internal users (the same author_id across Web and Telegram), AGENT covers
|
|
// l-ai agents, SYSTEM covers service-internal messages, INTEGRATION covers
|
|
// bridge/external systems.
|
|
type AuthorType int32
|
|
|
|
const (
|
|
AuthorType_AUTHOR_TYPE_UNSPECIFIED AuthorType = 0
|
|
AuthorType_AUTHOR_TYPE_HUMAN AuthorType = 1
|
|
AuthorType_AUTHOR_TYPE_AGENT AuthorType = 2
|
|
AuthorType_AUTHOR_TYPE_SYSTEM AuthorType = 3
|
|
AuthorType_AUTHOR_TYPE_INTEGRATION AuthorType = 4
|
|
)
|
|
|
|
// Enum value maps for AuthorType.
|
|
var (
|
|
AuthorType_name = map[int32]string{
|
|
0: "AUTHOR_TYPE_UNSPECIFIED",
|
|
1: "AUTHOR_TYPE_HUMAN",
|
|
2: "AUTHOR_TYPE_AGENT",
|
|
3: "AUTHOR_TYPE_SYSTEM",
|
|
4: "AUTHOR_TYPE_INTEGRATION",
|
|
}
|
|
AuthorType_value = map[string]int32{
|
|
"AUTHOR_TYPE_UNSPECIFIED": 0,
|
|
"AUTHOR_TYPE_HUMAN": 1,
|
|
"AUTHOR_TYPE_AGENT": 2,
|
|
"AUTHOR_TYPE_SYSTEM": 3,
|
|
"AUTHOR_TYPE_INTEGRATION": 4,
|
|
}
|
|
)
|
|
|
|
func (x AuthorType) Enum() *AuthorType {
|
|
p := new(AuthorType)
|
|
*p = x
|
|
return p
|
|
}
|
|
|
|
func (x AuthorType) String() string {
|
|
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
|
}
|
|
|
|
func (AuthorType) Descriptor() protoreflect.EnumDescriptor {
|
|
return file_chat_proto_enumTypes[0].Descriptor()
|
|
}
|
|
|
|
func (AuthorType) Type() protoreflect.EnumType {
|
|
return &file_chat_proto_enumTypes[0]
|
|
}
|
|
|
|
func (x AuthorType) Number() protoreflect.EnumNumber {
|
|
return protoreflect.EnumNumber(x)
|
|
}
|
|
|
|
// Deprecated: Use AuthorType.Descriptor instead.
|
|
func (AuthorType) EnumDescriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{0}
|
|
}
|
|
|
|
// MessageSource is the channel through which a message entered the system.
|
|
type MessageSource int32
|
|
|
|
const (
|
|
MessageSource_MESSAGE_SOURCE_UNSPECIFIED MessageSource = 0
|
|
MessageSource_MESSAGE_SOURCE_WEB MessageSource = 1
|
|
MessageSource_MESSAGE_SOURCE_TELEGRAM MessageSource = 2
|
|
MessageSource_MESSAGE_SOURCE_AGENT MessageSource = 3
|
|
MessageSource_MESSAGE_SOURCE_SYSTEM MessageSource = 4
|
|
)
|
|
|
|
// Enum value maps for MessageSource.
|
|
var (
|
|
MessageSource_name = map[int32]string{
|
|
0: "MESSAGE_SOURCE_UNSPECIFIED",
|
|
1: "MESSAGE_SOURCE_WEB",
|
|
2: "MESSAGE_SOURCE_TELEGRAM",
|
|
3: "MESSAGE_SOURCE_AGENT",
|
|
4: "MESSAGE_SOURCE_SYSTEM",
|
|
}
|
|
MessageSource_value = map[string]int32{
|
|
"MESSAGE_SOURCE_UNSPECIFIED": 0,
|
|
"MESSAGE_SOURCE_WEB": 1,
|
|
"MESSAGE_SOURCE_TELEGRAM": 2,
|
|
"MESSAGE_SOURCE_AGENT": 3,
|
|
"MESSAGE_SOURCE_SYSTEM": 4,
|
|
}
|
|
)
|
|
|
|
func (x MessageSource) Enum() *MessageSource {
|
|
p := new(MessageSource)
|
|
*p = x
|
|
return p
|
|
}
|
|
|
|
func (x MessageSource) String() string {
|
|
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
|
}
|
|
|
|
func (MessageSource) Descriptor() protoreflect.EnumDescriptor {
|
|
return file_chat_proto_enumTypes[1].Descriptor()
|
|
}
|
|
|
|
func (MessageSource) Type() protoreflect.EnumType {
|
|
return &file_chat_proto_enumTypes[1]
|
|
}
|
|
|
|
func (x MessageSource) Number() protoreflect.EnumNumber {
|
|
return protoreflect.EnumNumber(x)
|
|
}
|
|
|
|
// Deprecated: Use MessageSource.Descriptor instead.
|
|
func (MessageSource) EnumDescriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{1}
|
|
}
|
|
|
|
type Topic struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // UUID
|
|
Slug string `protobuf:"bytes,2,opt,name=slug,proto3" json:"slug,omitempty"` // stable, unique, e.g. "security"
|
|
DisplayName string `protobuf:"bytes,3,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"` // e.g. "Security"
|
|
CreatedAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *Topic) Reset() {
|
|
*x = Topic{}
|
|
mi := &file_chat_proto_msgTypes[0]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *Topic) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*Topic) ProtoMessage() {}
|
|
|
|
func (x *Topic) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[0]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use Topic.ProtoReflect.Descriptor instead.
|
|
func (*Topic) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{0}
|
|
}
|
|
|
|
func (x *Topic) GetId() string {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Topic) GetSlug() string {
|
|
if x != nil {
|
|
return x.Slug
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Topic) GetDisplayName() string {
|
|
if x != nil {
|
|
return x.DisplayName
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Topic) GetCreatedAt() *timestamppb.Timestamp {
|
|
if x != nil {
|
|
return x.CreatedAt
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type Message struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // UUID, canonical message id
|
|
Sequence int64 `protobuf:"varint,2,opt,name=sequence,proto3" json:"sequence,omitempty"` // server-assigned monotonic sequence (ordering + durable cursor)
|
|
TopicId string `protobuf:"bytes,3,opt,name=topic_id,json=topicId,proto3" json:"topic_id,omitempty"` // UUID
|
|
AuthorId string `protobuf:"bytes,4,opt,name=author_id,json=authorId,proto3" json:"author_id,omitempty"` // stable identity of the author (UUID)
|
|
AuthorType AuthorType `protobuf:"varint,5,opt,name=author_type,json=authorType,proto3,enum=chat.AuthorType" json:"author_type,omitempty"`
|
|
Source MessageSource `protobuf:"varint,6,opt,name=source,proto3,enum=chat.MessageSource" json:"source,omitempty"`
|
|
Content string `protobuf:"bytes,7,opt,name=content,proto3" json:"content,omitempty"`
|
|
ReplyToMessageId *string `protobuf:"bytes,8,opt,name=reply_to_message_id,json=replyToMessageId,proto3,oneof" json:"reply_to_message_id,omitempty"` // parent message when this is a reply
|
|
RootMessageId string `protobuf:"bytes,9,opt,name=root_message_id,json=rootMessageId,proto3" json:"root_message_id,omitempty"` // root of the reply chain (== id for non-replies)
|
|
ReplyDepth int32 `protobuf:"varint,10,opt,name=reply_depth,json=replyDepth,proto3" json:"reply_depth,omitempty"` // 0 for non-replies, parent depth + 1 for replies; hard max 20
|
|
CreatedAt *timestamppb.Timestamp `protobuf:"bytes,11,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` // original creation time; age = now - created_at
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *Message) Reset() {
|
|
*x = Message{}
|
|
mi := &file_chat_proto_msgTypes[1]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *Message) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*Message) ProtoMessage() {}
|
|
|
|
func (x *Message) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[1]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use Message.ProtoReflect.Descriptor instead.
|
|
func (*Message) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{1}
|
|
}
|
|
|
|
func (x *Message) GetId() string {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Message) GetSequence() int64 {
|
|
if x != nil {
|
|
return x.Sequence
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Message) GetTopicId() string {
|
|
if x != nil {
|
|
return x.TopicId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Message) GetAuthorId() string {
|
|
if x != nil {
|
|
return x.AuthorId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Message) GetAuthorType() AuthorType {
|
|
if x != nil {
|
|
return x.AuthorType
|
|
}
|
|
return AuthorType_AUTHOR_TYPE_UNSPECIFIED
|
|
}
|
|
|
|
func (x *Message) GetSource() MessageSource {
|
|
if x != nil {
|
|
return x.Source
|
|
}
|
|
return MessageSource_MESSAGE_SOURCE_UNSPECIFIED
|
|
}
|
|
|
|
func (x *Message) GetContent() string {
|
|
if x != nil {
|
|
return x.Content
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Message) GetReplyToMessageId() string {
|
|
if x != nil && x.ReplyToMessageId != nil {
|
|
return *x.ReplyToMessageId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Message) GetRootMessageId() string {
|
|
if x != nil {
|
|
return x.RootMessageId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *Message) GetReplyDepth() int32 {
|
|
if x != nil {
|
|
return x.ReplyDepth
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *Message) GetCreatedAt() *timestamppb.Timestamp {
|
|
if x != nil {
|
|
return x.CreatedAt
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type ListTopicsRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ListTopicsRequest) Reset() {
|
|
*x = ListTopicsRequest{}
|
|
mi := &file_chat_proto_msgTypes[2]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ListTopicsRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ListTopicsRequest) ProtoMessage() {}
|
|
|
|
func (x *ListTopicsRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[2]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ListTopicsRequest.ProtoReflect.Descriptor instead.
|
|
func (*ListTopicsRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{2}
|
|
}
|
|
|
|
type ListTopicsResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Topics []*Topic `protobuf:"bytes,1,rep,name=topics,proto3" json:"topics,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ListTopicsResponse) Reset() {
|
|
*x = ListTopicsResponse{}
|
|
mi := &file_chat_proto_msgTypes[3]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ListTopicsResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ListTopicsResponse) ProtoMessage() {}
|
|
|
|
func (x *ListTopicsResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[3]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use ListTopicsResponse.ProtoReflect.Descriptor instead.
|
|
func (*ListTopicsResponse) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{3}
|
|
}
|
|
|
|
func (x *ListTopicsResponse) GetTopics() []*Topic {
|
|
if x != nil {
|
|
return x.Topics
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type GetTopicRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
// Types that are valid to be assigned to Selector:
|
|
//
|
|
// *GetTopicRequest_Id
|
|
// *GetTopicRequest_Slug
|
|
Selector isGetTopicRequest_Selector `protobuf_oneof:"selector"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *GetTopicRequest) Reset() {
|
|
*x = GetTopicRequest{}
|
|
mi := &file_chat_proto_msgTypes[4]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *GetTopicRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*GetTopicRequest) ProtoMessage() {}
|
|
|
|
func (x *GetTopicRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[4]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use GetTopicRequest.ProtoReflect.Descriptor instead.
|
|
func (*GetTopicRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{4}
|
|
}
|
|
|
|
func (x *GetTopicRequest) GetSelector() isGetTopicRequest_Selector {
|
|
if x != nil {
|
|
return x.Selector
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *GetTopicRequest) GetId() string {
|
|
if x != nil {
|
|
if x, ok := x.Selector.(*GetTopicRequest_Id); ok {
|
|
return x.Id
|
|
}
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *GetTopicRequest) GetSlug() string {
|
|
if x != nil {
|
|
if x, ok := x.Selector.(*GetTopicRequest_Slug); ok {
|
|
return x.Slug
|
|
}
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type isGetTopicRequest_Selector interface {
|
|
isGetTopicRequest_Selector()
|
|
}
|
|
|
|
type GetTopicRequest_Id struct {
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3,oneof"`
|
|
}
|
|
|
|
type GetTopicRequest_Slug struct {
|
|
Slug string `protobuf:"bytes,2,opt,name=slug,proto3,oneof"`
|
|
}
|
|
|
|
func (*GetTopicRequest_Id) isGetTopicRequest_Selector() {}
|
|
|
|
func (*GetTopicRequest_Slug) isGetTopicRequest_Selector() {}
|
|
|
|
type CreateTopicRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Slug string `protobuf:"bytes,1,opt,name=slug,proto3" json:"slug,omitempty"`
|
|
DisplayName string `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *CreateTopicRequest) Reset() {
|
|
*x = CreateTopicRequest{}
|
|
mi := &file_chat_proto_msgTypes[5]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *CreateTopicRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CreateTopicRequest) ProtoMessage() {}
|
|
|
|
func (x *CreateTopicRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[5]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use CreateTopicRequest.ProtoReflect.Descriptor instead.
|
|
func (*CreateTopicRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{5}
|
|
}
|
|
|
|
func (x *CreateTopicRequest) GetSlug() string {
|
|
if x != nil {
|
|
return x.Slug
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *CreateTopicRequest) GetDisplayName() string {
|
|
if x != nil {
|
|
return x.DisplayName
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type UpdateTopicRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // UUID
|
|
DisplayName string `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"` // new display name (required, full replace)
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *UpdateTopicRequest) Reset() {
|
|
*x = UpdateTopicRequest{}
|
|
mi := &file_chat_proto_msgTypes[6]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *UpdateTopicRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*UpdateTopicRequest) ProtoMessage() {}
|
|
|
|
func (x *UpdateTopicRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[6]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use UpdateTopicRequest.ProtoReflect.Descriptor instead.
|
|
func (*UpdateTopicRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{6}
|
|
}
|
|
|
|
func (x *UpdateTopicRequest) GetId() string {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *UpdateTopicRequest) GetDisplayName() string {
|
|
if x != nil {
|
|
return x.DisplayName
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type PostMessageRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
TopicId string `protobuf:"bytes,1,opt,name=topic_id,json=topicId,proto3" json:"topic_id,omitempty"`
|
|
AuthorId string `protobuf:"bytes,2,opt,name=author_id,json=authorId,proto3" json:"author_id,omitempty"`
|
|
AuthorType AuthorType `protobuf:"varint,3,opt,name=author_type,json=authorType,proto3,enum=chat.AuthorType" json:"author_type,omitempty"`
|
|
Source MessageSource `protobuf:"varint,4,opt,name=source,proto3,enum=chat.MessageSource" json:"source,omitempty"`
|
|
Content string `protobuf:"bytes,5,opt,name=content,proto3" json:"content,omitempty"`
|
|
ReplyToMessageId *string `protobuf:"bytes,6,opt,name=reply_to_message_id,json=replyToMessageId,proto3,oneof" json:"reply_to_message_id,omitempty"`
|
|
// Idempotency key: retrying PostMessage with the same author_id and key
|
|
// returns the original message instead of creating a duplicate.
|
|
IdempotencyKey string `protobuf:"bytes,7,opt,name=idempotency_key,json=idempotencyKey,proto3" json:"idempotency_key,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *PostMessageRequest) Reset() {
|
|
*x = PostMessageRequest{}
|
|
mi := &file_chat_proto_msgTypes[7]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *PostMessageRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*PostMessageRequest) ProtoMessage() {}
|
|
|
|
func (x *PostMessageRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[7]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use PostMessageRequest.ProtoReflect.Descriptor instead.
|
|
func (*PostMessageRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{7}
|
|
}
|
|
|
|
func (x *PostMessageRequest) GetTopicId() string {
|
|
if x != nil {
|
|
return x.TopicId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *PostMessageRequest) GetAuthorId() string {
|
|
if x != nil {
|
|
return x.AuthorId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *PostMessageRequest) GetAuthorType() AuthorType {
|
|
if x != nil {
|
|
return x.AuthorType
|
|
}
|
|
return AuthorType_AUTHOR_TYPE_UNSPECIFIED
|
|
}
|
|
|
|
func (x *PostMessageRequest) GetSource() MessageSource {
|
|
if x != nil {
|
|
return x.Source
|
|
}
|
|
return MessageSource_MESSAGE_SOURCE_UNSPECIFIED
|
|
}
|
|
|
|
func (x *PostMessageRequest) GetContent() string {
|
|
if x != nil {
|
|
return x.Content
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *PostMessageRequest) GetReplyToMessageId() string {
|
|
if x != nil && x.ReplyToMessageId != nil {
|
|
return *x.ReplyToMessageId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *PostMessageRequest) GetIdempotencyKey() string {
|
|
if x != nil {
|
|
return x.IdempotencyKey
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type AgentPostMessageRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
TopicId string `protobuf:"bytes,1,opt,name=topic_id,json=topicId,proto3" json:"topic_id,omitempty"`
|
|
Content string `protobuf:"bytes,2,opt,name=content,proto3" json:"content,omitempty"`
|
|
ReplyToMessageId *string `protobuf:"bytes,3,opt,name=reply_to_message_id,json=replyToMessageId,proto3,oneof" json:"reply_to_message_id,omitempty"`
|
|
// Mandatory: retrying with the same key returns the original message
|
|
// (duplicated=true) instead of creating a duplicate.
|
|
IdempotencyKey string `protobuf:"bytes,4,opt,name=idempotency_key,json=idempotencyKey,proto3" json:"idempotency_key,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *AgentPostMessageRequest) Reset() {
|
|
*x = AgentPostMessageRequest{}
|
|
mi := &file_chat_proto_msgTypes[8]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *AgentPostMessageRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*AgentPostMessageRequest) ProtoMessage() {}
|
|
|
|
func (x *AgentPostMessageRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[8]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use AgentPostMessageRequest.ProtoReflect.Descriptor instead.
|
|
func (*AgentPostMessageRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{8}
|
|
}
|
|
|
|
func (x *AgentPostMessageRequest) GetTopicId() string {
|
|
if x != nil {
|
|
return x.TopicId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *AgentPostMessageRequest) GetContent() string {
|
|
if x != nil {
|
|
return x.Content
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *AgentPostMessageRequest) GetReplyToMessageId() string {
|
|
if x != nil && x.ReplyToMessageId != nil {
|
|
return *x.ReplyToMessageId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *AgentPostMessageRequest) GetIdempotencyKey() string {
|
|
if x != nil {
|
|
return x.IdempotencyKey
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type PostMessageResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Message *Message `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
|
|
Duplicated bool `protobuf:"varint,2,opt,name=duplicated,proto3" json:"duplicated,omitempty"` // true when an idempotent replay returned an existing message
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *PostMessageResponse) Reset() {
|
|
*x = PostMessageResponse{}
|
|
mi := &file_chat_proto_msgTypes[9]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *PostMessageResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*PostMessageResponse) ProtoMessage() {}
|
|
|
|
func (x *PostMessageResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[9]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use PostMessageResponse.ProtoReflect.Descriptor instead.
|
|
func (*PostMessageResponse) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{9}
|
|
}
|
|
|
|
func (x *PostMessageResponse) GetMessage() *Message {
|
|
if x != nil {
|
|
return x.Message
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *PostMessageResponse) GetDuplicated() bool {
|
|
if x != nil {
|
|
return x.Duplicated
|
|
}
|
|
return false
|
|
}
|
|
|
|
type GetMessageRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
MessageId string `protobuf:"bytes,1,opt,name=message_id,json=messageId,proto3" json:"message_id,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *GetMessageRequest) Reset() {
|
|
*x = GetMessageRequest{}
|
|
mi := &file_chat_proto_msgTypes[10]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *GetMessageRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*GetMessageRequest) ProtoMessage() {}
|
|
|
|
func (x *GetMessageRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[10]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use GetMessageRequest.ProtoReflect.Descriptor instead.
|
|
func (*GetMessageRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{10}
|
|
}
|
|
|
|
func (x *GetMessageRequest) GetMessageId() string {
|
|
if x != nil {
|
|
return x.MessageId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type HistoryRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
TopicId string `protobuf:"bytes,1,opt,name=topic_id,json=topicId,proto3" json:"topic_id,omitempty"`
|
|
// Backward paging: return messages with sequence < before_sequence,
|
|
// newest first. Mutually exclusive with after_sequence.
|
|
BeforeSequence int64 `protobuf:"varint,2,opt,name=before_sequence,json=beforeSequence,proto3" json:"before_sequence,omitempty"`
|
|
// Forward paging: return messages with sequence > after_sequence,
|
|
// oldest first. Mutually exclusive with before_sequence.
|
|
AfterSequence int64 `protobuf:"varint,3,opt,name=after_sequence,json=afterSequence,proto3" json:"after_sequence,omitempty"`
|
|
// Maximum number of messages to return (server may cap it).
|
|
Limit int32 `protobuf:"varint,4,opt,name=limit,proto3" json:"limit,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *HistoryRequest) Reset() {
|
|
*x = HistoryRequest{}
|
|
mi := &file_chat_proto_msgTypes[11]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *HistoryRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*HistoryRequest) ProtoMessage() {}
|
|
|
|
func (x *HistoryRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[11]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use HistoryRequest.ProtoReflect.Descriptor instead.
|
|
func (*HistoryRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{11}
|
|
}
|
|
|
|
func (x *HistoryRequest) GetTopicId() string {
|
|
if x != nil {
|
|
return x.TopicId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *HistoryRequest) GetBeforeSequence() int64 {
|
|
if x != nil {
|
|
return x.BeforeSequence
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *HistoryRequest) GetAfterSequence() int64 {
|
|
if x != nil {
|
|
return x.AfterSequence
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *HistoryRequest) GetLimit() int32 {
|
|
if x != nil {
|
|
return x.Limit
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type HistoryResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Messages []*Message `protobuf:"bytes,1,rep,name=messages,proto3" json:"messages,omitempty"`
|
|
// true when more messages exist in the requested direction.
|
|
HasMore bool `protobuf:"varint,2,opt,name=has_more,json=hasMore,proto3" json:"has_more,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *HistoryResponse) Reset() {
|
|
*x = HistoryResponse{}
|
|
mi := &file_chat_proto_msgTypes[12]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *HistoryResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*HistoryResponse) ProtoMessage() {}
|
|
|
|
func (x *HistoryResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[12]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use HistoryResponse.ProtoReflect.Descriptor instead.
|
|
func (*HistoryResponse) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{12}
|
|
}
|
|
|
|
func (x *HistoryResponse) GetMessages() []*Message {
|
|
if x != nil {
|
|
return x.Messages
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *HistoryResponse) GetHasMore() bool {
|
|
if x != nil {
|
|
return x.HasMore
|
|
}
|
|
return false
|
|
}
|
|
|
|
type SubscribeRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
TopicId string `protobuf:"bytes,1,opt,name=topic_id,json=topicId,proto3" json:"topic_id,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *SubscribeRequest) Reset() {
|
|
*x = SubscribeRequest{}
|
|
mi := &file_chat_proto_msgTypes[13]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *SubscribeRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*SubscribeRequest) ProtoMessage() {}
|
|
|
|
func (x *SubscribeRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[13]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use SubscribeRequest.ProtoReflect.Descriptor instead.
|
|
func (*SubscribeRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{13}
|
|
}
|
|
|
|
func (x *SubscribeRequest) GetTopicId() string {
|
|
if x != nil {
|
|
return x.TopicId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
// DeliveryMessage wraps one delivered message with delivery metadata.
|
|
// message.created_at is always the original creation time; replay + the
|
|
// timestamp let the SDK decide how to treat a delivery.
|
|
type DeliveryMessage struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Message *Message `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
|
|
// true when the message was committed BEFORE this subscription started
|
|
// (backlog catch-up after connect/reconnect); false for messages committed
|
|
// while this subscription is live.
|
|
Replay bool `protobuf:"varint,2,opt,name=replay,proto3" json:"replay,omitempty"`
|
|
// Opaque id of the current subscription, generated by the server per
|
|
// Subscribe stream. MUST be echoed in Acknowledge; a stale id (from a
|
|
// replaced/closed stream) is rejected.
|
|
SubscriptionId string `protobuf:"bytes,3,opt,name=subscription_id,json=subscriptionId,proto3" json:"subscription_id,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *DeliveryMessage) Reset() {
|
|
*x = DeliveryMessage{}
|
|
mi := &file_chat_proto_msgTypes[14]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *DeliveryMessage) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*DeliveryMessage) ProtoMessage() {}
|
|
|
|
func (x *DeliveryMessage) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[14]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use DeliveryMessage.ProtoReflect.Descriptor instead.
|
|
func (*DeliveryMessage) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{14}
|
|
}
|
|
|
|
func (x *DeliveryMessage) GetMessage() *Message {
|
|
if x != nil {
|
|
return x.Message
|
|
}
|
|
return nil
|
|
}
|
|
|
|
func (x *DeliveryMessage) GetReplay() bool {
|
|
if x != nil {
|
|
return x.Replay
|
|
}
|
|
return false
|
|
}
|
|
|
|
func (x *DeliveryMessage) GetSubscriptionId() string {
|
|
if x != nil {
|
|
return x.SubscriptionId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type AcknowledgeRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
TopicId string `protobuf:"bytes,1,opt,name=topic_id,json=topicId,proto3" json:"topic_id,omitempty"`
|
|
// Highest sequence fully processed by the consumer (cumulative ack).
|
|
LastAckSequence int64 `protobuf:"varint,2,opt,name=last_ack_sequence,json=lastAckSequence,proto3" json:"last_ack_sequence,omitempty"`
|
|
// The subscription_id of the stream that delivered the message. Must be
|
|
// the CURRENT active subscription of this consumer in this topic.
|
|
SubscriptionId string `protobuf:"bytes,3,opt,name=subscription_id,json=subscriptionId,proto3" json:"subscription_id,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *AcknowledgeRequest) Reset() {
|
|
*x = AcknowledgeRequest{}
|
|
mi := &file_chat_proto_msgTypes[15]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *AcknowledgeRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*AcknowledgeRequest) ProtoMessage() {}
|
|
|
|
func (x *AcknowledgeRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[15]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use AcknowledgeRequest.ProtoReflect.Descriptor instead.
|
|
func (*AcknowledgeRequest) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{15}
|
|
}
|
|
|
|
func (x *AcknowledgeRequest) GetTopicId() string {
|
|
if x != nil {
|
|
return x.TopicId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *AcknowledgeRequest) GetLastAckSequence() int64 {
|
|
if x != nil {
|
|
return x.LastAckSequence
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *AcknowledgeRequest) GetSubscriptionId() string {
|
|
if x != nil {
|
|
return x.SubscriptionId
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type AcknowledgeResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
LastAckSequence int64 `protobuf:"varint,1,opt,name=last_ack_sequence,json=lastAckSequence,proto3" json:"last_ack_sequence,omitempty"` // the cursor as stored (never lower than before)
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *AcknowledgeResponse) Reset() {
|
|
*x = AcknowledgeResponse{}
|
|
mi := &file_chat_proto_msgTypes[16]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *AcknowledgeResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*AcknowledgeResponse) ProtoMessage() {}
|
|
|
|
func (x *AcknowledgeResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_chat_proto_msgTypes[16]
|
|
if x != nil {
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
if ms.LoadMessageInfo() == nil {
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
return ms
|
|
}
|
|
return mi.MessageOf(x)
|
|
}
|
|
|
|
// Deprecated: Use AcknowledgeResponse.ProtoReflect.Descriptor instead.
|
|
func (*AcknowledgeResponse) Descriptor() ([]byte, []int) {
|
|
return file_chat_proto_rawDescGZIP(), []int{16}
|
|
}
|
|
|
|
func (x *AcknowledgeResponse) GetLastAckSequence() int64 {
|
|
if x != nil {
|
|
return x.LastAckSequence
|
|
}
|
|
return 0
|
|
}
|
|
|
|
var File_chat_proto protoreflect.FileDescriptor
|
|
|
|
const file_chat_proto_rawDesc = "" +
|
|
"\n" +
|
|
"\n" +
|
|
"chat.proto\x12\x04chat\x1a\x1fgoogle/protobuf/timestamp.proto\"\x89\x01\n" +
|
|
"\x05Topic\x12\x0e\n" +
|
|
"\x02id\x18\x01 \x01(\tR\x02id\x12\x12\n" +
|
|
"\x04slug\x18\x02 \x01(\tR\x04slug\x12!\n" +
|
|
"\fdisplay_name\x18\x03 \x01(\tR\vdisplayName\x129\n" +
|
|
"\n" +
|
|
"created_at\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\tcreatedAt\"\xb7\x03\n" +
|
|
"\aMessage\x12\x0e\n" +
|
|
"\x02id\x18\x01 \x01(\tR\x02id\x12\x1a\n" +
|
|
"\bsequence\x18\x02 \x01(\x03R\bsequence\x12\x19\n" +
|
|
"\btopic_id\x18\x03 \x01(\tR\atopicId\x12\x1b\n" +
|
|
"\tauthor_id\x18\x04 \x01(\tR\bauthorId\x121\n" +
|
|
"\vauthor_type\x18\x05 \x01(\x0e2\x10.chat.AuthorTypeR\n" +
|
|
"authorType\x12+\n" +
|
|
"\x06source\x18\x06 \x01(\x0e2\x13.chat.MessageSourceR\x06source\x12\x18\n" +
|
|
"\acontent\x18\a \x01(\tR\acontent\x122\n" +
|
|
"\x13reply_to_message_id\x18\b \x01(\tH\x00R\x10replyToMessageId\x88\x01\x01\x12&\n" +
|
|
"\x0froot_message_id\x18\t \x01(\tR\rrootMessageId\x12\x1f\n" +
|
|
"\vreply_depth\x18\n" +
|
|
" \x01(\x05R\n" +
|
|
"replyDepth\x129\n" +
|
|
"\n" +
|
|
"created_at\x18\v \x01(\v2\x1a.google.protobuf.TimestampR\tcreatedAtB\x16\n" +
|
|
"\x14_reply_to_message_id\"\x13\n" +
|
|
"\x11ListTopicsRequest\"9\n" +
|
|
"\x12ListTopicsResponse\x12#\n" +
|
|
"\x06topics\x18\x01 \x03(\v2\v.chat.TopicR\x06topics\"E\n" +
|
|
"\x0fGetTopicRequest\x12\x10\n" +
|
|
"\x02id\x18\x01 \x01(\tH\x00R\x02id\x12\x14\n" +
|
|
"\x04slug\x18\x02 \x01(\tH\x00R\x04slugB\n" +
|
|
"\n" +
|
|
"\bselector\"K\n" +
|
|
"\x12CreateTopicRequest\x12\x12\n" +
|
|
"\x04slug\x18\x01 \x01(\tR\x04slug\x12!\n" +
|
|
"\fdisplay_name\x18\x02 \x01(\tR\vdisplayName\"G\n" +
|
|
"\x12UpdateTopicRequest\x12\x0e\n" +
|
|
"\x02id\x18\x01 \x01(\tR\x02id\x12!\n" +
|
|
"\fdisplay_name\x18\x02 \x01(\tR\vdisplayName\"\xbb\x02\n" +
|
|
"\x12PostMessageRequest\x12\x19\n" +
|
|
"\btopic_id\x18\x01 \x01(\tR\atopicId\x12\x1b\n" +
|
|
"\tauthor_id\x18\x02 \x01(\tR\bauthorId\x121\n" +
|
|
"\vauthor_type\x18\x03 \x01(\x0e2\x10.chat.AuthorTypeR\n" +
|
|
"authorType\x12+\n" +
|
|
"\x06source\x18\x04 \x01(\x0e2\x13.chat.MessageSourceR\x06source\x12\x18\n" +
|
|
"\acontent\x18\x05 \x01(\tR\acontent\x122\n" +
|
|
"\x13reply_to_message_id\x18\x06 \x01(\tH\x00R\x10replyToMessageId\x88\x01\x01\x12'\n" +
|
|
"\x0fidempotency_key\x18\a \x01(\tR\x0eidempotencyKeyB\x16\n" +
|
|
"\x14_reply_to_message_id\"\xc3\x01\n" +
|
|
"\x17AgentPostMessageRequest\x12\x19\n" +
|
|
"\btopic_id\x18\x01 \x01(\tR\atopicId\x12\x18\n" +
|
|
"\acontent\x18\x02 \x01(\tR\acontent\x122\n" +
|
|
"\x13reply_to_message_id\x18\x03 \x01(\tH\x00R\x10replyToMessageId\x88\x01\x01\x12'\n" +
|
|
"\x0fidempotency_key\x18\x04 \x01(\tR\x0eidempotencyKeyB\x16\n" +
|
|
"\x14_reply_to_message_id\"^\n" +
|
|
"\x13PostMessageResponse\x12'\n" +
|
|
"\amessage\x18\x01 \x01(\v2\r.chat.MessageR\amessage\x12\x1e\n" +
|
|
"\n" +
|
|
"duplicated\x18\x02 \x01(\bR\n" +
|
|
"duplicated\"2\n" +
|
|
"\x11GetMessageRequest\x12\x1d\n" +
|
|
"\n" +
|
|
"message_id\x18\x01 \x01(\tR\tmessageId\"\x91\x01\n" +
|
|
"\x0eHistoryRequest\x12\x19\n" +
|
|
"\btopic_id\x18\x01 \x01(\tR\atopicId\x12'\n" +
|
|
"\x0fbefore_sequence\x18\x02 \x01(\x03R\x0ebeforeSequence\x12%\n" +
|
|
"\x0eafter_sequence\x18\x03 \x01(\x03R\rafterSequence\x12\x14\n" +
|
|
"\x05limit\x18\x04 \x01(\x05R\x05limit\"W\n" +
|
|
"\x0fHistoryResponse\x12)\n" +
|
|
"\bmessages\x18\x01 \x03(\v2\r.chat.MessageR\bmessages\x12\x19\n" +
|
|
"\bhas_more\x18\x02 \x01(\bR\ahasMore\"-\n" +
|
|
"\x10SubscribeRequest\x12\x19\n" +
|
|
"\btopic_id\x18\x01 \x01(\tR\atopicId\"{\n" +
|
|
"\x0fDeliveryMessage\x12'\n" +
|
|
"\amessage\x18\x01 \x01(\v2\r.chat.MessageR\amessage\x12\x16\n" +
|
|
"\x06replay\x18\x02 \x01(\bR\x06replay\x12'\n" +
|
|
"\x0fsubscription_id\x18\x03 \x01(\tR\x0esubscriptionId\"\x84\x01\n" +
|
|
"\x12AcknowledgeRequest\x12\x19\n" +
|
|
"\btopic_id\x18\x01 \x01(\tR\atopicId\x12*\n" +
|
|
"\x11last_ack_sequence\x18\x02 \x01(\x03R\x0flastAckSequence\x12'\n" +
|
|
"\x0fsubscription_id\x18\x03 \x01(\tR\x0esubscriptionId\"A\n" +
|
|
"\x13AcknowledgeResponse\x12*\n" +
|
|
"\x11last_ack_sequence\x18\x01 \x01(\x03R\x0flastAckSequence*\x8c\x01\n" +
|
|
"\n" +
|
|
"AuthorType\x12\x1b\n" +
|
|
"\x17AUTHOR_TYPE_UNSPECIFIED\x10\x00\x12\x15\n" +
|
|
"\x11AUTHOR_TYPE_HUMAN\x10\x01\x12\x15\n" +
|
|
"\x11AUTHOR_TYPE_AGENT\x10\x02\x12\x16\n" +
|
|
"\x12AUTHOR_TYPE_SYSTEM\x10\x03\x12\x1b\n" +
|
|
"\x17AUTHOR_TYPE_INTEGRATION\x10\x04*\x99\x01\n" +
|
|
"\rMessageSource\x12\x1e\n" +
|
|
"\x1aMESSAGE_SOURCE_UNSPECIFIED\x10\x00\x12\x16\n" +
|
|
"\x12MESSAGE_SOURCE_WEB\x10\x01\x12\x1b\n" +
|
|
"\x17MESSAGE_SOURCE_TELEGRAM\x10\x02\x12\x18\n" +
|
|
"\x14MESSAGE_SOURCE_AGENT\x10\x03\x12\x19\n" +
|
|
"\x15MESSAGE_SOURCE_SYSTEM\x10\x042\xec\x04\n" +
|
|
"\vChatService\x12?\n" +
|
|
"\n" +
|
|
"ListTopics\x12\x17.chat.ListTopicsRequest\x1a\x18.chat.ListTopicsResponse\x12.\n" +
|
|
"\bGetTopic\x12\x15.chat.GetTopicRequest\x1a\v.chat.Topic\x124\n" +
|
|
"\vCreateTopic\x12\x18.chat.CreateTopicRequest\x1a\v.chat.Topic\x124\n" +
|
|
"\vUpdateTopic\x12\x18.chat.UpdateTopicRequest\x1a\v.chat.Topic\x12B\n" +
|
|
"\vPostMessage\x12\x18.chat.PostMessageRequest\x1a\x19.chat.PostMessageResponse\x12L\n" +
|
|
"\x10AgentPostMessage\x12\x1d.chat.AgentPostMessageRequest\x1a\x19.chat.PostMessageResponse\x124\n" +
|
|
"\n" +
|
|
"GetMessage\x12\x17.chat.GetMessageRequest\x1a\r.chat.Message\x126\n" +
|
|
"\aHistory\x12\x14.chat.HistoryRequest\x1a\x15.chat.HistoryResponse\x12<\n" +
|
|
"\tSubscribe\x12\x16.chat.SubscribeRequest\x1a\x15.chat.DeliveryMessage0\x01\x12B\n" +
|
|
"\vAcknowledge\x12\x18.chat.AcknowledgeRequest\x1a\x19.chat.AcknowledgeResponseB,Z*git.be.kaien.ru/l-ai/l-ai-chat-proto/protob\x06proto3"
|
|
|
|
var (
|
|
file_chat_proto_rawDescOnce sync.Once
|
|
file_chat_proto_rawDescData []byte
|
|
)
|
|
|
|
func file_chat_proto_rawDescGZIP() []byte {
|
|
file_chat_proto_rawDescOnce.Do(func() {
|
|
file_chat_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_chat_proto_rawDesc), len(file_chat_proto_rawDesc)))
|
|
})
|
|
return file_chat_proto_rawDescData
|
|
}
|
|
|
|
var file_chat_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
|
|
var file_chat_proto_msgTypes = make([]protoimpl.MessageInfo, 17)
|
|
var file_chat_proto_goTypes = []any{
|
|
(AuthorType)(0), // 0: chat.AuthorType
|
|
(MessageSource)(0), // 1: chat.MessageSource
|
|
(*Topic)(nil), // 2: chat.Topic
|
|
(*Message)(nil), // 3: chat.Message
|
|
(*ListTopicsRequest)(nil), // 4: chat.ListTopicsRequest
|
|
(*ListTopicsResponse)(nil), // 5: chat.ListTopicsResponse
|
|
(*GetTopicRequest)(nil), // 6: chat.GetTopicRequest
|
|
(*CreateTopicRequest)(nil), // 7: chat.CreateTopicRequest
|
|
(*UpdateTopicRequest)(nil), // 8: chat.UpdateTopicRequest
|
|
(*PostMessageRequest)(nil), // 9: chat.PostMessageRequest
|
|
(*AgentPostMessageRequest)(nil), // 10: chat.AgentPostMessageRequest
|
|
(*PostMessageResponse)(nil), // 11: chat.PostMessageResponse
|
|
(*GetMessageRequest)(nil), // 12: chat.GetMessageRequest
|
|
(*HistoryRequest)(nil), // 13: chat.HistoryRequest
|
|
(*HistoryResponse)(nil), // 14: chat.HistoryResponse
|
|
(*SubscribeRequest)(nil), // 15: chat.SubscribeRequest
|
|
(*DeliveryMessage)(nil), // 16: chat.DeliveryMessage
|
|
(*AcknowledgeRequest)(nil), // 17: chat.AcknowledgeRequest
|
|
(*AcknowledgeResponse)(nil), // 18: chat.AcknowledgeResponse
|
|
(*timestamppb.Timestamp)(nil), // 19: google.protobuf.Timestamp
|
|
}
|
|
var file_chat_proto_depIdxs = []int32{
|
|
19, // 0: chat.Topic.created_at:type_name -> google.protobuf.Timestamp
|
|
0, // 1: chat.Message.author_type:type_name -> chat.AuthorType
|
|
1, // 2: chat.Message.source:type_name -> chat.MessageSource
|
|
19, // 3: chat.Message.created_at:type_name -> google.protobuf.Timestamp
|
|
2, // 4: chat.ListTopicsResponse.topics:type_name -> chat.Topic
|
|
0, // 5: chat.PostMessageRequest.author_type:type_name -> chat.AuthorType
|
|
1, // 6: chat.PostMessageRequest.source:type_name -> chat.MessageSource
|
|
3, // 7: chat.PostMessageResponse.message:type_name -> chat.Message
|
|
3, // 8: chat.HistoryResponse.messages:type_name -> chat.Message
|
|
3, // 9: chat.DeliveryMessage.message:type_name -> chat.Message
|
|
4, // 10: chat.ChatService.ListTopics:input_type -> chat.ListTopicsRequest
|
|
6, // 11: chat.ChatService.GetTopic:input_type -> chat.GetTopicRequest
|
|
7, // 12: chat.ChatService.CreateTopic:input_type -> chat.CreateTopicRequest
|
|
8, // 13: chat.ChatService.UpdateTopic:input_type -> chat.UpdateTopicRequest
|
|
9, // 14: chat.ChatService.PostMessage:input_type -> chat.PostMessageRequest
|
|
10, // 15: chat.ChatService.AgentPostMessage:input_type -> chat.AgentPostMessageRequest
|
|
12, // 16: chat.ChatService.GetMessage:input_type -> chat.GetMessageRequest
|
|
13, // 17: chat.ChatService.History:input_type -> chat.HistoryRequest
|
|
15, // 18: chat.ChatService.Subscribe:input_type -> chat.SubscribeRequest
|
|
17, // 19: chat.ChatService.Acknowledge:input_type -> chat.AcknowledgeRequest
|
|
5, // 20: chat.ChatService.ListTopics:output_type -> chat.ListTopicsResponse
|
|
2, // 21: chat.ChatService.GetTopic:output_type -> chat.Topic
|
|
2, // 22: chat.ChatService.CreateTopic:output_type -> chat.Topic
|
|
2, // 23: chat.ChatService.UpdateTopic:output_type -> chat.Topic
|
|
11, // 24: chat.ChatService.PostMessage:output_type -> chat.PostMessageResponse
|
|
11, // 25: chat.ChatService.AgentPostMessage:output_type -> chat.PostMessageResponse
|
|
3, // 26: chat.ChatService.GetMessage:output_type -> chat.Message
|
|
14, // 27: chat.ChatService.History:output_type -> chat.HistoryResponse
|
|
16, // 28: chat.ChatService.Subscribe:output_type -> chat.DeliveryMessage
|
|
18, // 29: chat.ChatService.Acknowledge:output_type -> chat.AcknowledgeResponse
|
|
20, // [20:30] is the sub-list for method output_type
|
|
10, // [10:20] is the sub-list for method input_type
|
|
10, // [10:10] is the sub-list for extension type_name
|
|
10, // [10:10] is the sub-list for extension extendee
|
|
0, // [0:10] is the sub-list for field type_name
|
|
}
|
|
|
|
func init() { file_chat_proto_init() }
|
|
func file_chat_proto_init() {
|
|
if File_chat_proto != nil {
|
|
return
|
|
}
|
|
file_chat_proto_msgTypes[1].OneofWrappers = []any{}
|
|
file_chat_proto_msgTypes[4].OneofWrappers = []any{
|
|
(*GetTopicRequest_Id)(nil),
|
|
(*GetTopicRequest_Slug)(nil),
|
|
}
|
|
file_chat_proto_msgTypes[7].OneofWrappers = []any{}
|
|
file_chat_proto_msgTypes[8].OneofWrappers = []any{}
|
|
type x struct{}
|
|
out := protoimpl.TypeBuilder{
|
|
File: protoimpl.DescBuilder{
|
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
RawDescriptor: unsafe.Slice(unsafe.StringData(file_chat_proto_rawDesc), len(file_chat_proto_rawDesc)),
|
|
NumEnums: 2,
|
|
NumMessages: 17,
|
|
NumExtensions: 0,
|
|
NumServices: 1,
|
|
},
|
|
GoTypes: file_chat_proto_goTypes,
|
|
DependencyIndexes: file_chat_proto_depIdxs,
|
|
EnumInfos: file_chat_proto_enumTypes,
|
|
MessageInfos: file_chat_proto_msgTypes,
|
|
}.Build()
|
|
File_chat_proto = out.File
|
|
file_chat_proto_goTypes = nil
|
|
file_chat_proto_depIdxs = nil
|
|
}
|