v0.0.3
This commit is contained in:
parent
b9328ffd76
commit
8cbe00a889
16 changed files with 4723 additions and 125 deletions
3
go.mod
Normal file
3
go.mod
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
module whiteboxsystems.nl/okapi
|
||||
|
||||
go 1.19
|
||||
275
okapi-errors.pb.go
Normal file
275
okapi-errors.pb.go
Normal file
|
|
@ -0,0 +1,275 @@
|
|||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.30.0
|
||||
// protoc v3.21.12
|
||||
// source: okapi-errors.proto
|
||||
|
||||
package okapi
|
||||
|
||||
import (
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
)
|
||||
|
||||
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)
|
||||
)
|
||||
|
||||
type OKAPIErrorCode int32
|
||||
|
||||
const (
|
||||
OKAPIErrorCode_None OKAPIErrorCode = 0
|
||||
// Invalide configuratie voor de gekozen methode
|
||||
OKAPIErrorCode_InvalidXISAuthConfiguration OKAPIErrorCode = 1
|
||||
// Onbekende reference meegegeven
|
||||
OKAPIErrorCode_UnkownReference OKAPIErrorCode = 2
|
||||
// Invalide autorisatietoken voor deze reference
|
||||
OKAPIErrorCode_InvalidAuthorizationToken OKAPIErrorCode = 3
|
||||
// Onbekende service
|
||||
OKAPIErrorCode_UnknownService OKAPIErrorCode = 4
|
||||
// Onbekende protocol
|
||||
OKAPIErrorCode_UnknownProtocol OKAPIErrorCode = 5
|
||||
// Invalide procotol configuratie voor het aangegeven protocol
|
||||
OKAPIErrorCode_InvalidProcotolConfig OKAPIErrorCode = 6
|
||||
// Authenticatie methode onbekend
|
||||
OKAPIErrorCode_UnknownAuthMethod OKAPIErrorCode = 7
|
||||
// Invalide authorisatie configuratie voor het aangegeven protocol
|
||||
OKAPIErrorCode_InvalidProcotolAuthConfig OKAPIErrorCode = 8
|
||||
// Er zijn niet genoeg events om deze pagina te bereiken
|
||||
OKAPIErrorCode_InvalidPage OKAPIErrorCode = 9
|
||||
// Er wordt geprobeerd een patient af te melden die niet is ingeschreven
|
||||
OKAPIErrorCode_AlreadyUnsubscribed OKAPIErrorCode = 10
|
||||
// De service is al actief
|
||||
OKAPIErrorCode_ServiceAlreadyActivated OKAPIErrorCode = 11
|
||||
// De service is niet actief
|
||||
OKAPIErrorCode_ServiceNotActive OKAPIErrorCode = 12
|
||||
// Een generieke error code die terug wordt gegeven met en omschrijving die
|
||||
// meer informatie geeft over wat er fout is gegaan
|
||||
OKAPIErrorCode_GenericException OKAPIErrorCode = 999
|
||||
)
|
||||
|
||||
// Enum value maps for OKAPIErrorCode.
|
||||
var (
|
||||
OKAPIErrorCode_name = map[int32]string{
|
||||
0: "None",
|
||||
1: "InvalidXISAuthConfiguration",
|
||||
2: "UnkownReference",
|
||||
3: "InvalidAuthorizationToken",
|
||||
4: "UnknownService",
|
||||
5: "UnknownProtocol",
|
||||
6: "InvalidProcotolConfig",
|
||||
7: "UnknownAuthMethod",
|
||||
8: "InvalidProcotolAuthConfig",
|
||||
9: "InvalidPage",
|
||||
10: "AlreadyUnsubscribed",
|
||||
11: "ServiceAlreadyActivated",
|
||||
12: "ServiceNotActive",
|
||||
999: "GenericException",
|
||||
}
|
||||
OKAPIErrorCode_value = map[string]int32{
|
||||
"None": 0,
|
||||
"InvalidXISAuthConfiguration": 1,
|
||||
"UnkownReference": 2,
|
||||
"InvalidAuthorizationToken": 3,
|
||||
"UnknownService": 4,
|
||||
"UnknownProtocol": 5,
|
||||
"InvalidProcotolConfig": 6,
|
||||
"UnknownAuthMethod": 7,
|
||||
"InvalidProcotolAuthConfig": 8,
|
||||
"InvalidPage": 9,
|
||||
"AlreadyUnsubscribed": 10,
|
||||
"ServiceAlreadyActivated": 11,
|
||||
"ServiceNotActive": 12,
|
||||
"GenericException": 999,
|
||||
}
|
||||
)
|
||||
|
||||
func (x OKAPIErrorCode) Enum() *OKAPIErrorCode {
|
||||
p := new(OKAPIErrorCode)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x OKAPIErrorCode) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (OKAPIErrorCode) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_okapi_errors_proto_enumTypes[0].Descriptor()
|
||||
}
|
||||
|
||||
func (OKAPIErrorCode) Type() protoreflect.EnumType {
|
||||
return &file_okapi_errors_proto_enumTypes[0]
|
||||
}
|
||||
|
||||
func (x OKAPIErrorCode) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use OKAPIErrorCode.Descriptor instead.
|
||||
func (OKAPIErrorCode) EnumDescriptor() ([]byte, []int) {
|
||||
return file_okapi_errors_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
type OKAPIError struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Code OKAPIErrorCode `protobuf:"varint,1,opt,name=code,proto3,enum=OKAPIErrorCode" json:"code,omitempty"`
|
||||
Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
|
||||
}
|
||||
|
||||
func (x *OKAPIError) Reset() {
|
||||
*x = OKAPIError{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_errors_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *OKAPIError) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*OKAPIError) ProtoMessage() {}
|
||||
|
||||
func (x *OKAPIError) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_errors_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use OKAPIError.ProtoReflect.Descriptor instead.
|
||||
func (*OKAPIError) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_errors_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *OKAPIError) GetCode() OKAPIErrorCode {
|
||||
if x != nil {
|
||||
return x.Code
|
||||
}
|
||||
return OKAPIErrorCode_None
|
||||
}
|
||||
|
||||
func (x *OKAPIError) GetMessage() string {
|
||||
if x != nil {
|
||||
return x.Message
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
var File_okapi_errors_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_okapi_errors_proto_rawDesc = []byte{
|
||||
0x0a, 0x12, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x2d, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x73, 0x2e, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x22, 0x4b, 0x0a, 0x0a, 0x4f, 0x4b, 0x41, 0x50, 0x49, 0x45, 0x72, 0x72,
|
||||
0x6f, 0x72, 0x12, 0x23, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e,
|
||||
0x32, 0x0f, 0x2e, 0x4f, 0x4b, 0x41, 0x50, 0x49, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64,
|
||||
0x65, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61,
|
||||
0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67,
|
||||
0x65, 0x2a, 0xdd, 0x02, 0x0a, 0x0e, 0x4f, 0x4b, 0x41, 0x50, 0x49, 0x45, 0x72, 0x72, 0x6f, 0x72,
|
||||
0x43, 0x6f, 0x64, 0x65, 0x12, 0x08, 0x0a, 0x04, 0x4e, 0x6f, 0x6e, 0x65, 0x10, 0x00, 0x12, 0x1f,
|
||||
0x0a, 0x1b, 0x49, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x58, 0x49, 0x53, 0x41, 0x75, 0x74, 0x68,
|
||||
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x10, 0x01, 0x12,
|
||||
0x13, 0x0a, 0x0f, 0x55, 0x6e, 0x6b, 0x6f, 0x77, 0x6e, 0x52, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e,
|
||||
0x63, 0x65, 0x10, 0x02, 0x12, 0x1d, 0x0a, 0x19, 0x49, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x41,
|
||||
0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65,
|
||||
0x6e, 0x10, 0x03, 0x12, 0x12, 0x0a, 0x0e, 0x55, 0x6e, 0x6b, 0x6e, 0x6f, 0x77, 0x6e, 0x53, 0x65,
|
||||
0x72, 0x76, 0x69, 0x63, 0x65, 0x10, 0x04, 0x12, 0x13, 0x0a, 0x0f, 0x55, 0x6e, 0x6b, 0x6e, 0x6f,
|
||||
0x77, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x10, 0x05, 0x12, 0x19, 0x0a, 0x15,
|
||||
0x49, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x50, 0x72, 0x6f, 0x63, 0x6f, 0x74, 0x6f, 0x6c, 0x43,
|
||||
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x10, 0x06, 0x12, 0x15, 0x0a, 0x11, 0x55, 0x6e, 0x6b, 0x6e, 0x6f,
|
||||
0x77, 0x6e, 0x41, 0x75, 0x74, 0x68, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x10, 0x07, 0x12, 0x1d,
|
||||
0x0a, 0x19, 0x49, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x50, 0x72, 0x6f, 0x63, 0x6f, 0x74, 0x6f,
|
||||
0x6c, 0x41, 0x75, 0x74, 0x68, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x10, 0x08, 0x12, 0x0f, 0x0a,
|
||||
0x0b, 0x49, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x50, 0x61, 0x67, 0x65, 0x10, 0x09, 0x12, 0x17,
|
||||
0x0a, 0x13, 0x41, 0x6c, 0x72, 0x65, 0x61, 0x64, 0x79, 0x55, 0x6e, 0x73, 0x75, 0x62, 0x73, 0x63,
|
||||
0x72, 0x69, 0x62, 0x65, 0x64, 0x10, 0x0a, 0x12, 0x1b, 0x0a, 0x17, 0x53, 0x65, 0x72, 0x76, 0x69,
|
||||
0x63, 0x65, 0x41, 0x6c, 0x72, 0x65, 0x61, 0x64, 0x79, 0x41, 0x63, 0x74, 0x69, 0x76, 0x61, 0x74,
|
||||
0x65, 0x64, 0x10, 0x0b, 0x12, 0x14, 0x0a, 0x10, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4e,
|
||||
0x6f, 0x74, 0x41, 0x63, 0x74, 0x69, 0x76, 0x65, 0x10, 0x0c, 0x12, 0x15, 0x0a, 0x10, 0x47, 0x65,
|
||||
0x6e, 0x65, 0x72, 0x69, 0x63, 0x45, 0x78, 0x63, 0x65, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x10, 0xe7,
|
||||
0x07, 0x42, 0x1a, 0x5a, 0x18, 0x77, 0x68, 0x69, 0x74, 0x65, 0x62, 0x6f, 0x78, 0x73, 0x79, 0x73,
|
||||
0x74, 0x65, 0x6d, 0x73, 0x2e, 0x6e, 0x6c, 0x2f, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_okapi_errors_proto_rawDescOnce sync.Once
|
||||
file_okapi_errors_proto_rawDescData = file_okapi_errors_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_okapi_errors_proto_rawDescGZIP() []byte {
|
||||
file_okapi_errors_proto_rawDescOnce.Do(func() {
|
||||
file_okapi_errors_proto_rawDescData = protoimpl.X.CompressGZIP(file_okapi_errors_proto_rawDescData)
|
||||
})
|
||||
return file_okapi_errors_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_okapi_errors_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_okapi_errors_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
|
||||
var file_okapi_errors_proto_goTypes = []interface{}{
|
||||
(OKAPIErrorCode)(0), // 0: OKAPIErrorCode
|
||||
(*OKAPIError)(nil), // 1: OKAPIError
|
||||
}
|
||||
var file_okapi_errors_proto_depIdxs = []int32{
|
||||
0, // 0: OKAPIError.code:type_name -> OKAPIErrorCode
|
||||
1, // [1:1] is the sub-list for method output_type
|
||||
1, // [1:1] is the sub-list for method input_type
|
||||
1, // [1:1] is the sub-list for extension type_name
|
||||
1, // [1:1] is the sub-list for extension extendee
|
||||
0, // [0:1] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_okapi_errors_proto_init() }
|
||||
func file_okapi_errors_proto_init() {
|
||||
if File_okapi_errors_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_okapi_errors_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*OKAPIError); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_okapi_errors_proto_rawDesc,
|
||||
NumEnums: 1,
|
||||
NumMessages: 1,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_okapi_errors_proto_goTypes,
|
||||
DependencyIndexes: file_okapi_errors_proto_depIdxs,
|
||||
EnumInfos: file_okapi_errors_proto_enumTypes,
|
||||
MessageInfos: file_okapi_errors_proto_msgTypes,
|
||||
}.Build()
|
||||
File_okapi_errors_proto = out.File
|
||||
file_okapi_errors_proto_rawDesc = nil
|
||||
file_okapi_errors_proto_goTypes = nil
|
||||
file_okapi_errors_proto_depIdxs = nil
|
||||
}
|
||||
519
okapi-events.pb.go
Normal file
519
okapi-events.pb.go
Normal file
|
|
@ -0,0 +1,519 @@
|
|||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.30.0
|
||||
// protoc v3.21.12
|
||||
// source: okapi-events.proto
|
||||
|
||||
package okapi
|
||||
|
||||
import (
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
structpb "google.golang.org/protobuf/types/known/structpb"
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
)
|
||||
|
||||
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)
|
||||
)
|
||||
|
||||
// Should events payloads be documented by for example json schema?
|
||||
type Event struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
|
||||
Type string `protobuf:"bytes,2,opt,name=type,proto3" json:"type,omitempty"`
|
||||
ServiceId string `protobuf:"bytes,3,opt,name=serviceId,proto3" json:"serviceId,omitempty"`
|
||||
PatientId string `protobuf:"bytes,4,opt,name=patientId,proto3" json:"patientId,omitempty"`
|
||||
Payload *structpb.Struct `protobuf:"bytes,5,opt,name=payload,proto3" json:"payload,omitempty"` // string schema = 6; // ? do we need a schema in the event itself
|
||||
}
|
||||
|
||||
func (x *Event) Reset() {
|
||||
*x = Event{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_events_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *Event) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Event) ProtoMessage() {}
|
||||
|
||||
func (x *Event) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_events_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Event.ProtoReflect.Descriptor instead.
|
||||
func (*Event) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_events_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *Event) GetTimestamp() uint64 {
|
||||
if x != nil {
|
||||
return x.Timestamp
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *Event) GetType() string {
|
||||
if x != nil {
|
||||
return x.Type
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Event) GetServiceId() string {
|
||||
if x != nil {
|
||||
return x.ServiceId
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Event) GetPatientId() string {
|
||||
if x != nil {
|
||||
return x.PatientId
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Event) GetPayload() *structpb.Struct {
|
||||
if x != nil {
|
||||
return x.Payload
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type Query struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Start uint64 `protobuf:"varint,1,opt,name=start,proto3" json:"start,omitempty"`
|
||||
End uint64 `protobuf:"varint,2,opt,name=end,proto3" json:"end,omitempty"`
|
||||
Type string `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"`
|
||||
ServiceId string `protobuf:"bytes,4,opt,name=serviceId,proto3" json:"serviceId,omitempty"`
|
||||
PatientId string `protobuf:"bytes,5,opt,name=patientId,proto3" json:"patientId,omitempty"`
|
||||
}
|
||||
|
||||
func (x *Query) Reset() {
|
||||
*x = Query{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_events_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *Query) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Query) ProtoMessage() {}
|
||||
|
||||
func (x *Query) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_events_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Query.ProtoReflect.Descriptor instead.
|
||||
func (*Query) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_events_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *Query) GetStart() uint64 {
|
||||
if x != nil {
|
||||
return x.Start
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *Query) GetEnd() uint64 {
|
||||
if x != nil {
|
||||
return x.End
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *Query) GetType() string {
|
||||
if x != nil {
|
||||
return x.Type
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Query) GetServiceId() string {
|
||||
if x != nil {
|
||||
return x.ServiceId
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Query) GetPatientId() string {
|
||||
if x != nil {
|
||||
return x.PatientId
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type GetEventsRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Page int32 `protobuf:"varint,2,opt,name=page,proto3" json:"page,omitempty"`
|
||||
PerPage int32 `protobuf:"varint,3,opt,name=perPage,proto3" json:"perPage,omitempty"`
|
||||
Query []*Query `protobuf:"bytes,4,rep,name=query,proto3" json:"query,omitempty"`
|
||||
}
|
||||
|
||||
func (x *GetEventsRequest) Reset() {
|
||||
*x = GetEventsRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_events_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *GetEventsRequest) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*GetEventsRequest) ProtoMessage() {}
|
||||
|
||||
func (x *GetEventsRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_events_proto_msgTypes[2]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use GetEventsRequest.ProtoReflect.Descriptor instead.
|
||||
func (*GetEventsRequest) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_events_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
func (x *GetEventsRequest) GetPage() int32 {
|
||||
if x != nil {
|
||||
return x.Page
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *GetEventsRequest) GetPerPage() int32 {
|
||||
if x != nil {
|
||||
return x.PerPage
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *GetEventsRequest) GetQuery() []*Query {
|
||||
if x != nil {
|
||||
return x.Query
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type GetEventsResponse struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Page int32 `protobuf:"varint,2,opt,name=page,proto3" json:"page,omitempty"`
|
||||
PerPage int32 `protobuf:"varint,3,opt,name=perPage,proto3" json:"perPage,omitempty"`
|
||||
Events []*Event `protobuf:"bytes,4,rep,name=events,proto3" json:"events,omitempty"`
|
||||
}
|
||||
|
||||
func (x *GetEventsResponse) Reset() {
|
||||
*x = GetEventsResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_events_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *GetEventsResponse) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*GetEventsResponse) ProtoMessage() {}
|
||||
|
||||
func (x *GetEventsResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_events_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use GetEventsResponse.ProtoReflect.Descriptor instead.
|
||||
func (*GetEventsResponse) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_events_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *GetEventsResponse) GetPage() int32 {
|
||||
if x != nil {
|
||||
return x.Page
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *GetEventsResponse) GetPerPage() int32 {
|
||||
if x != nil {
|
||||
return x.PerPage
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *GetEventsResponse) GetEvents() []*Event {
|
||||
if x != nil {
|
||||
return x.Events
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type GetEventsStreamRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Query []*Query `protobuf:"bytes,2,rep,name=query,proto3" json:"query,omitempty"`
|
||||
}
|
||||
|
||||
func (x *GetEventsStreamRequest) Reset() {
|
||||
*x = GetEventsStreamRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_events_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *GetEventsStreamRequest) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*GetEventsStreamRequest) ProtoMessage() {}
|
||||
|
||||
func (x *GetEventsStreamRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_events_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use GetEventsStreamRequest.ProtoReflect.Descriptor instead.
|
||||
func (*GetEventsStreamRequest) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_events_proto_rawDescGZIP(), []int{4}
|
||||
}
|
||||
|
||||
func (x *GetEventsStreamRequest) GetQuery() []*Query {
|
||||
if x != nil {
|
||||
return x.Query
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_okapi_events_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_okapi_events_proto_rawDesc = []byte{
|
||||
0x0a, 0x12, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x2d, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x70,
|
||||
0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x22, 0xa8, 0x01, 0x0a, 0x05, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x09,
|
||||
0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52,
|
||||
0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79,
|
||||
0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1c,
|
||||
0x0a, 0x09, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||
0x09, 0x52, 0x09, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09,
|
||||
0x70, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
0x09, 0x70, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x31, 0x0a, 0x07, 0x70, 0x61,
|
||||
0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f,
|
||||
0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74,
|
||||
0x72, 0x75, 0x63, 0x74, 0x52, 0x07, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x22, 0x7f, 0x0a,
|
||||
0x05, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x18,
|
||||
0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x73, 0x74, 0x61, 0x72, 0x74, 0x12, 0x10, 0x0a, 0x03,
|
||||
0x65, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x03, 0x65, 0x6e, 0x64, 0x12, 0x12,
|
||||
0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79,
|
||||
0x70, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64, 0x18,
|
||||
0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x49, 0x64,
|
||||
0x12, 0x1c, 0x0a, 0x09, 0x70, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x05, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x09, 0x70, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x22, 0x5e,
|
||||
0x0a, 0x10, 0x47, 0x65, 0x74, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05,
|
||||
0x52, 0x04, 0x70, 0x61, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x65, 0x72, 0x50, 0x61, 0x67,
|
||||
0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x70, 0x65, 0x72, 0x50, 0x61, 0x67, 0x65,
|
||||
0x12, 0x1c, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32,
|
||||
0x06, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x22, 0x61,
|
||||
0x0a, 0x11, 0x47, 0x65, 0x74, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f,
|
||||
0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||||
0x05, 0x52, 0x04, 0x70, 0x61, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x65, 0x72, 0x50, 0x61,
|
||||
0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x70, 0x65, 0x72, 0x50, 0x61, 0x67,
|
||||
0x65, 0x12, 0x1e, 0x0a, 0x06, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28,
|
||||
0x0b, 0x32, 0x06, 0x2e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x52, 0x06, 0x65, 0x76, 0x65, 0x6e, 0x74,
|
||||
0x73, 0x22, 0x36, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x53, 0x74,
|
||||
0x72, 0x65, 0x61, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x05, 0x71,
|
||||
0x75, 0x65, 0x72, 0x79, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x06, 0x2e, 0x51, 0x75, 0x65,
|
||||
0x72, 0x79, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x42, 0x1a, 0x5a, 0x18, 0x77, 0x68, 0x69,
|
||||
0x74, 0x65, 0x62, 0x6f, 0x78, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x73, 0x2e, 0x6e, 0x6c, 0x2f,
|
||||
0x6f, 0x6b, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_okapi_events_proto_rawDescOnce sync.Once
|
||||
file_okapi_events_proto_rawDescData = file_okapi_events_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_okapi_events_proto_rawDescGZIP() []byte {
|
||||
file_okapi_events_proto_rawDescOnce.Do(func() {
|
||||
file_okapi_events_proto_rawDescData = protoimpl.X.CompressGZIP(file_okapi_events_proto_rawDescData)
|
||||
})
|
||||
return file_okapi_events_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_okapi_events_proto_msgTypes = make([]protoimpl.MessageInfo, 5)
|
||||
var file_okapi_events_proto_goTypes = []interface{}{
|
||||
(*Event)(nil), // 0: Event
|
||||
(*Query)(nil), // 1: Query
|
||||
(*GetEventsRequest)(nil), // 2: GetEventsRequest
|
||||
(*GetEventsResponse)(nil), // 3: GetEventsResponse
|
||||
(*GetEventsStreamRequest)(nil), // 4: GetEventsStreamRequest
|
||||
(*structpb.Struct)(nil), // 5: google.protobuf.Struct
|
||||
}
|
||||
var file_okapi_events_proto_depIdxs = []int32{
|
||||
5, // 0: Event.payload:type_name -> google.protobuf.Struct
|
||||
1, // 1: GetEventsRequest.query:type_name -> Query
|
||||
0, // 2: GetEventsResponse.events:type_name -> Event
|
||||
1, // 3: GetEventsStreamRequest.query:type_name -> Query
|
||||
4, // [4:4] is the sub-list for method output_type
|
||||
4, // [4:4] is the sub-list for method input_type
|
||||
4, // [4:4] is the sub-list for extension type_name
|
||||
4, // [4:4] is the sub-list for extension extendee
|
||||
0, // [0:4] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_okapi_events_proto_init() }
|
||||
func file_okapi_events_proto_init() {
|
||||
if File_okapi_events_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_okapi_events_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Event); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_events_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Query); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_events_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetEventsRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_events_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetEventsResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_events_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetEventsStreamRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_okapi_events_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 5,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_okapi_events_proto_goTypes,
|
||||
DependencyIndexes: file_okapi_events_proto_depIdxs,
|
||||
MessageInfos: file_okapi_events_proto_msgTypes,
|
||||
}.Build()
|
||||
File_okapi_events_proto = out.File
|
||||
file_okapi_events_proto_rawDesc = nil
|
||||
file_okapi_events_proto_goTypes = nil
|
||||
file_okapi_events_proto_depIdxs = nil
|
||||
}
|
||||
|
|
@ -1,34 +0,0 @@
|
|||
syntax = "proto3";
|
||||
import "google/protobuf/struct.proto";
|
||||
option go_package = "whiteboxsystems.nl/okapi";
|
||||
|
||||
message Event {
|
||||
uint64 timestamp = 1;
|
||||
string type = 2;
|
||||
string serviceId = 3;
|
||||
string patientId = 4;
|
||||
google.protobuf.Struct payload = 5;
|
||||
}
|
||||
message Query {
|
||||
uint64 start = 1;
|
||||
uint64 end = 2;
|
||||
string type = 3;
|
||||
string serviceId = 4;
|
||||
string patientId = 5;
|
||||
}
|
||||
|
||||
message GetEventsRequest {
|
||||
int32 page = 2;
|
||||
int32 perPage = 3;
|
||||
repeated Query query = 4;
|
||||
}
|
||||
|
||||
message GetEventsResponse {
|
||||
int32 page = 2;
|
||||
int32 perPage = 3;
|
||||
repeated Event events = 4;
|
||||
}
|
||||
|
||||
message GetEventsStreamRequest {
|
||||
repeated Query query = 2;
|
||||
}
|
||||
748
okapi-onboarding.pb.go
Normal file
748
okapi-onboarding.pb.go
Normal file
|
|
@ -0,0 +1,748 @@
|
|||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.30.0
|
||||
// protoc v3.21.12
|
||||
// source: okapi-onboarding.proto
|
||||
|
||||
package okapi
|
||||
|
||||
import (
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
)
|
||||
|
||||
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)
|
||||
)
|
||||
|
||||
type XISAuthMethod int32
|
||||
|
||||
const (
|
||||
XISAuthMethod_mTLS XISAuthMethod = 0
|
||||
)
|
||||
|
||||
// Enum value maps for XISAuthMethod.
|
||||
var (
|
||||
XISAuthMethod_name = map[int32]string{
|
||||
0: "mTLS",
|
||||
}
|
||||
XISAuthMethod_value = map[string]int32{
|
||||
"mTLS": 0,
|
||||
}
|
||||
)
|
||||
|
||||
func (x XISAuthMethod) Enum() *XISAuthMethod {
|
||||
p := new(XISAuthMethod)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x XISAuthMethod) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (XISAuthMethod) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_okapi_onboarding_proto_enumTypes[0].Descriptor()
|
||||
}
|
||||
|
||||
func (XISAuthMethod) Type() protoreflect.EnumType {
|
||||
return &file_okapi_onboarding_proto_enumTypes[0]
|
||||
}
|
||||
|
||||
func (x XISAuthMethod) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use XISAuthMethod.Descriptor instead.
|
||||
func (XISAuthMethod) EnumDescriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
type MTLSConfigurationParams struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
// JWK (RFC 7517) presentatie van publieke sleutel van het
|
||||
// client certificaat dat gebruikt gaat worden voor het opzetten
|
||||
// van de verbinding.
|
||||
// Voorbeeld: "{\"crv\":\"P-256\",\"kty\":\"EC\",\"x\":\"PZlyqX3X...\", \"y\":\"AawwPSKBt...\"}"
|
||||
PublicKey string `protobuf:"bytes,1,opt,name=publicKey,proto3" json:"publicKey,omitempty"`
|
||||
}
|
||||
|
||||
func (x *MTLSConfigurationParams) Reset() {
|
||||
*x = MTLSConfigurationParams{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *MTLSConfigurationParams) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MTLSConfigurationParams) ProtoMessage() {}
|
||||
|
||||
func (x *MTLSConfigurationParams) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use MTLSConfigurationParams.ProtoReflect.Descriptor instead.
|
||||
func (*MTLSConfigurationParams) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *MTLSConfigurationParams) GetPublicKey() string {
|
||||
if x != nil {
|
||||
return x.PublicKey
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type XISAuthConfiguration struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Method XISAuthMethod `protobuf:"varint,1,opt,name=method,proto3,enum=XISAuthMethod" json:"method,omitempty"`
|
||||
// Types that are assignable to Configuration:
|
||||
//
|
||||
// *XISAuthConfiguration_MtlsConfiguration
|
||||
Configuration isXISAuthConfiguration_Configuration `protobuf_oneof:"configuration"`
|
||||
}
|
||||
|
||||
func (x *XISAuthConfiguration) Reset() {
|
||||
*x = XISAuthConfiguration{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *XISAuthConfiguration) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*XISAuthConfiguration) ProtoMessage() {}
|
||||
|
||||
func (x *XISAuthConfiguration) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use XISAuthConfiguration.ProtoReflect.Descriptor instead.
|
||||
func (*XISAuthConfiguration) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *XISAuthConfiguration) GetMethod() XISAuthMethod {
|
||||
if x != nil {
|
||||
return x.Method
|
||||
}
|
||||
return XISAuthMethod_mTLS
|
||||
}
|
||||
|
||||
func (m *XISAuthConfiguration) GetConfiguration() isXISAuthConfiguration_Configuration {
|
||||
if m != nil {
|
||||
return m.Configuration
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *XISAuthConfiguration) GetMtlsConfiguration() *MTLSConfigurationParams {
|
||||
if x, ok := x.GetConfiguration().(*XISAuthConfiguration_MtlsConfiguration); ok {
|
||||
return x.MtlsConfiguration
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type isXISAuthConfiguration_Configuration interface {
|
||||
isXISAuthConfiguration_Configuration()
|
||||
}
|
||||
|
||||
type XISAuthConfiguration_MtlsConfiguration struct {
|
||||
MtlsConfiguration *MTLSConfigurationParams `protobuf:"bytes,2,opt,name=mtlsConfiguration,proto3,oneof"`
|
||||
}
|
||||
|
||||
func (*XISAuthConfiguration_MtlsConfiguration) isXISAuthConfiguration_Configuration() {}
|
||||
|
||||
type GetMetadataRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
}
|
||||
|
||||
func (x *GetMetadataRequest) Reset() {
|
||||
*x = GetMetadataRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *GetMetadataRequest) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*GetMetadataRequest) ProtoMessage() {}
|
||||
|
||||
func (x *GetMetadataRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[2]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use GetMetadataRequest.ProtoReflect.Descriptor instead.
|
||||
func (*GetMetadataRequest) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
type GetMetadataResponse struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
SupplierFormalName string `protobuf:"bytes,1,opt,name=supplierFormalName,proto3" json:"supplierFormalName,omitempty"`
|
||||
SupplierDisplayName string `protobuf:"bytes,2,opt,name=supplierDisplayName,proto3" json:"supplierDisplayName,omitempty"`
|
||||
ProductName string `protobuf:"bytes,3,opt,name=productName,proto3" json:"productName,omitempty"`
|
||||
Version string `protobuf:"bytes,4,opt,name=version,proto3" json:"version,omitempty"`
|
||||
}
|
||||
|
||||
func (x *GetMetadataResponse) Reset() {
|
||||
*x = GetMetadataResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *GetMetadataResponse) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*GetMetadataResponse) ProtoMessage() {}
|
||||
|
||||
func (x *GetMetadataResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use GetMetadataResponse.ProtoReflect.Descriptor instead.
|
||||
func (*GetMetadataResponse) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *GetMetadataResponse) GetSupplierFormalName() string {
|
||||
if x != nil {
|
||||
return x.SupplierFormalName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *GetMetadataResponse) GetSupplierDisplayName() string {
|
||||
if x != nil {
|
||||
return x.SupplierDisplayName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *GetMetadataResponse) GetProductName() string {
|
||||
if x != nil {
|
||||
return x.ProductName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *GetMetadataResponse) GetVersion() string {
|
||||
if x != nil {
|
||||
return x.Version
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type RegisterRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
OrganisationFormalName string `protobuf:"bytes,1,opt,name=organisationFormalName,proto3" json:"organisationFormalName,omitempty"`
|
||||
OrganisationDisplayName string `protobuf:"bytes,2,opt,name=organisationDisplayName,proto3" json:"organisationDisplayName,omitempty"`
|
||||
OrganisationIdentifier string `protobuf:"bytes,3,opt,name=organisationIdentifier,proto3" json:"organisationIdentifier,omitempty"`
|
||||
OrganisationIdentifierType string `protobuf:"bytes,4,opt,name=organisationIdentifierType,proto3" json:"organisationIdentifierType,omitempty"` // Type bijv. AGB, BIG registratie of KvK
|
||||
Auth *XISAuthConfiguration `protobuf:"bytes,5,opt,name=auth,proto3" json:"auth,omitempty"`
|
||||
}
|
||||
|
||||
func (x *RegisterRequest) Reset() {
|
||||
*x = RegisterRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *RegisterRequest) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*RegisterRequest) ProtoMessage() {}
|
||||
|
||||
func (x *RegisterRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use RegisterRequest.ProtoReflect.Descriptor instead.
|
||||
func (*RegisterRequest) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{4}
|
||||
}
|
||||
|
||||
func (x *RegisterRequest) GetOrganisationFormalName() string {
|
||||
if x != nil {
|
||||
return x.OrganisationFormalName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *RegisterRequest) GetOrganisationDisplayName() string {
|
||||
if x != nil {
|
||||
return x.OrganisationDisplayName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *RegisterRequest) GetOrganisationIdentifier() string {
|
||||
if x != nil {
|
||||
return x.OrganisationIdentifier
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *RegisterRequest) GetOrganisationIdentifierType() string {
|
||||
if x != nil {
|
||||
return x.OrganisationIdentifierType
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *RegisterRequest) GetAuth() *XISAuthConfiguration {
|
||||
if x != nil {
|
||||
return x.Auth
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type RegisterResponse struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Reference string `protobuf:"bytes,1,opt,name=reference,proto3" json:"reference,omitempty"`
|
||||
}
|
||||
|
||||
func (x *RegisterResponse) Reset() {
|
||||
*x = RegisterResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *RegisterResponse) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*RegisterResponse) ProtoMessage() {}
|
||||
|
||||
func (x *RegisterResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[5]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use RegisterResponse.ProtoReflect.Descriptor instead.
|
||||
func (*RegisterResponse) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{5}
|
||||
}
|
||||
|
||||
func (x *RegisterResponse) GetReference() string {
|
||||
if x != nil {
|
||||
return x.Reference
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type CompleteRegistrationRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Reference string `protobuf:"bytes,1,opt,name=reference,proto3" json:"reference,omitempty"`
|
||||
AuthorizationToken string `protobuf:"bytes,2,opt,name=AuthorizationToken,proto3" json:"AuthorizationToken,omitempty"`
|
||||
}
|
||||
|
||||
func (x *CompleteRegistrationRequest) Reset() {
|
||||
*x = CompleteRegistrationRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[6]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *CompleteRegistrationRequest) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*CompleteRegistrationRequest) ProtoMessage() {}
|
||||
|
||||
func (x *CompleteRegistrationRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[6]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use CompleteRegistrationRequest.ProtoReflect.Descriptor instead.
|
||||
func (*CompleteRegistrationRequest) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{6}
|
||||
}
|
||||
|
||||
func (x *CompleteRegistrationRequest) GetReference() string {
|
||||
if x != nil {
|
||||
return x.Reference
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *CompleteRegistrationRequest) GetAuthorizationToken() string {
|
||||
if x != nil {
|
||||
return x.AuthorizationToken
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type CompleteRegistrationResponse struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
}
|
||||
|
||||
func (x *CompleteRegistrationResponse) Reset() {
|
||||
*x = CompleteRegistrationResponse{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[7]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *CompleteRegistrationResponse) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*CompleteRegistrationResponse) ProtoMessage() {}
|
||||
|
||||
func (x *CompleteRegistrationResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_okapi_onboarding_proto_msgTypes[7]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use CompleteRegistrationResponse.ProtoReflect.Descriptor instead.
|
||||
func (*CompleteRegistrationResponse) Descriptor() ([]byte, []int) {
|
||||
return file_okapi_onboarding_proto_rawDescGZIP(), []int{7}
|
||||
}
|
||||
|
||||
var File_okapi_onboarding_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_okapi_onboarding_proto_rawDesc = []byte{
|
||||
0x0a, 0x16, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x2d, 0x6f, 0x6e, 0x62, 0x6f, 0x61, 0x72, 0x64, 0x69,
|
||||
0x6e, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x37, 0x0a, 0x17, 0x4d, 0x54, 0x4c, 0x53,
|
||||
0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x61, 0x72,
|
||||
0x61, 0x6d, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65,
|
||||
0x79, 0x22, 0x99, 0x01, 0x0a, 0x14, 0x58, 0x49, 0x53, 0x41, 0x75, 0x74, 0x68, 0x43, 0x6f, 0x6e,
|
||||
0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x26, 0x0a, 0x06, 0x6d, 0x65,
|
||||
0x74, 0x68, 0x6f, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0e, 0x2e, 0x58, 0x49, 0x53,
|
||||
0x41, 0x75, 0x74, 0x68, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x52, 0x06, 0x6d, 0x65, 0x74, 0x68,
|
||||
0x6f, 0x64, 0x12, 0x48, 0x0a, 0x11, 0x6d, 0x74, 0x6c, 0x73, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67,
|
||||
0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e,
|
||||
0x4d, 0x54, 0x4c, 0x53, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f,
|
||||
0x6e, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x48, 0x00, 0x52, 0x11, 0x6d, 0x74, 0x6c, 0x73, 0x43,
|
||||
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x0f, 0x0a, 0x0d,
|
||||
0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x14, 0x0a,
|
||||
0x12, 0x47, 0x65, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75,
|
||||
0x65, 0x73, 0x74, 0x22, 0xb3, 0x01, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x64,
|
||||
0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2e, 0x0a, 0x12, 0x73,
|
||||
0x75, 0x70, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x4e, 0x61, 0x6d,
|
||||
0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x12, 0x73, 0x75, 0x70, 0x70, 0x6c, 0x69, 0x65,
|
||||
0x72, 0x46, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x30, 0x0a, 0x13, 0x73,
|
||||
0x75, 0x70, 0x70, 0x6c, 0x69, 0x65, 0x72, 0x44, 0x69, 0x73, 0x70, 0x6c, 0x61, 0x79, 0x4e, 0x61,
|
||||
0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x73, 0x75, 0x70, 0x70, 0x6c, 0x69,
|
||||
0x65, 0x72, 0x44, 0x69, 0x73, 0x70, 0x6c, 0x61, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x20, 0x0a,
|
||||
0x0b, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12,
|
||||
0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0xa6, 0x02, 0x0a, 0x0f, 0x52, 0x65,
|
||||
0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x36, 0x0a,
|
||||
0x16, 0x6f, 0x72, 0x67, 0x61, 0x6e, 0x69, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x46, 0x6f, 0x72,
|
||||
0x6d, 0x61, 0x6c, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x16, 0x6f,
|
||||
0x72, 0x67, 0x61, 0x6e, 0x69, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x46, 0x6f, 0x72, 0x6d, 0x61,
|
||||
0x6c, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x38, 0x0a, 0x17, 0x6f, 0x72, 0x67, 0x61, 0x6e, 0x69, 0x73,
|
||||
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x44, 0x69, 0x73, 0x70, 0x6c, 0x61, 0x79, 0x4e, 0x61, 0x6d, 0x65,
|
||||
0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x17, 0x6f, 0x72, 0x67, 0x61, 0x6e, 0x69, 0x73, 0x61,
|
||||
0x74, 0x69, 0x6f, 0x6e, 0x44, 0x69, 0x73, 0x70, 0x6c, 0x61, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12,
|
||||
0x36, 0x0a, 0x16, 0x6f, 0x72, 0x67, 0x61, 0x6e, 0x69, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49,
|
||||
0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
0x16, 0x6f, 0x72, 0x67, 0x61, 0x6e, 0x69, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x65,
|
||||
0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x12, 0x3e, 0x0a, 0x1a, 0x6f, 0x72, 0x67, 0x61, 0x6e,
|
||||
0x69, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65,
|
||||
0x72, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x1a, 0x6f, 0x72, 0x67,
|
||||
0x61, 0x6e, 0x69, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66,
|
||||
0x69, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x12, 0x29, 0x0a, 0x04, 0x61, 0x75, 0x74, 0x68, 0x18,
|
||||
0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x58, 0x49, 0x53, 0x41, 0x75, 0x74, 0x68, 0x43,
|
||||
0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x04, 0x61, 0x75,
|
||||
0x74, 0x68, 0x22, 0x30, 0x0a, 0x10, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x52, 0x65,
|
||||
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65,
|
||||
0x6e, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x72, 0x65, 0x66, 0x65, 0x72,
|
||||
0x65, 0x6e, 0x63, 0x65, 0x22, 0x6b, 0x0a, 0x1b, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65,
|
||||
0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x75,
|
||||
0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63,
|
||||
0x65, 0x12, 0x2e, 0x0a, 0x12, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x12, 0x41,
|
||||
0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x6f, 0x6b, 0x65,
|
||||
0x6e, 0x22, 0x1e, 0x0a, 0x1c, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x67,
|
||||
0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
|
||||
0x65, 0x2a, 0x19, 0x0a, 0x0d, 0x58, 0x49, 0x53, 0x41, 0x75, 0x74, 0x68, 0x4d, 0x65, 0x74, 0x68,
|
||||
0x6f, 0x64, 0x12, 0x08, 0x0a, 0x04, 0x6d, 0x54, 0x4c, 0x53, 0x10, 0x00, 0x42, 0x1a, 0x5a, 0x18,
|
||||
0x77, 0x68, 0x69, 0x74, 0x65, 0x62, 0x6f, 0x78, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x73, 0x2e,
|
||||
0x6e, 0x6c, 0x2f, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
file_okapi_onboarding_proto_rawDescOnce sync.Once
|
||||
file_okapi_onboarding_proto_rawDescData = file_okapi_onboarding_proto_rawDesc
|
||||
)
|
||||
|
||||
func file_okapi_onboarding_proto_rawDescGZIP() []byte {
|
||||
file_okapi_onboarding_proto_rawDescOnce.Do(func() {
|
||||
file_okapi_onboarding_proto_rawDescData = protoimpl.X.CompressGZIP(file_okapi_onboarding_proto_rawDescData)
|
||||
})
|
||||
return file_okapi_onboarding_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_okapi_onboarding_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_okapi_onboarding_proto_msgTypes = make([]protoimpl.MessageInfo, 8)
|
||||
var file_okapi_onboarding_proto_goTypes = []interface{}{
|
||||
(XISAuthMethod)(0), // 0: XISAuthMethod
|
||||
(*MTLSConfigurationParams)(nil), // 1: MTLSConfigurationParams
|
||||
(*XISAuthConfiguration)(nil), // 2: XISAuthConfiguration
|
||||
(*GetMetadataRequest)(nil), // 3: GetMetadataRequest
|
||||
(*GetMetadataResponse)(nil), // 4: GetMetadataResponse
|
||||
(*RegisterRequest)(nil), // 5: RegisterRequest
|
||||
(*RegisterResponse)(nil), // 6: RegisterResponse
|
||||
(*CompleteRegistrationRequest)(nil), // 7: CompleteRegistrationRequest
|
||||
(*CompleteRegistrationResponse)(nil), // 8: CompleteRegistrationResponse
|
||||
}
|
||||
var file_okapi_onboarding_proto_depIdxs = []int32{
|
||||
0, // 0: XISAuthConfiguration.method:type_name -> XISAuthMethod
|
||||
1, // 1: XISAuthConfiguration.mtlsConfiguration:type_name -> MTLSConfigurationParams
|
||||
2, // 2: RegisterRequest.auth:type_name -> XISAuthConfiguration
|
||||
3, // [3:3] is the sub-list for method output_type
|
||||
3, // [3:3] is the sub-list for method input_type
|
||||
3, // [3:3] is the sub-list for extension type_name
|
||||
3, // [3:3] is the sub-list for extension extendee
|
||||
0, // [0:3] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_okapi_onboarding_proto_init() }
|
||||
func file_okapi_onboarding_proto_init() {
|
||||
if File_okapi_onboarding_proto != nil {
|
||||
return
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_okapi_onboarding_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*MTLSConfigurationParams); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_onboarding_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*XISAuthConfiguration); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_onboarding_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetMetadataRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_onboarding_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetMetadataResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_onboarding_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*RegisterRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_onboarding_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*RegisterResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_onboarding_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*CompleteRegistrationRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_okapi_onboarding_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*CompleteRegistrationResponse); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
file_okapi_onboarding_proto_msgTypes[1].OneofWrappers = []interface{}{
|
||||
(*XISAuthConfiguration_MtlsConfiguration)(nil),
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_okapi_onboarding_proto_rawDesc,
|
||||
NumEnums: 1,
|
||||
NumMessages: 8,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_okapi_onboarding_proto_goTypes,
|
||||
DependencyIndexes: file_okapi_onboarding_proto_depIdxs,
|
||||
EnumInfos: file_okapi_onboarding_proto_enumTypes,
|
||||
MessageInfos: file_okapi_onboarding_proto_msgTypes,
|
||||
}.Build()
|
||||
File_okapi_onboarding_proto = out.File
|
||||
file_okapi_onboarding_proto_rawDesc = nil
|
||||
file_okapi_onboarding_proto_goTypes = nil
|
||||
file_okapi_onboarding_proto_depIdxs = nil
|
||||
}
|
||||
1293
okapi-patient-registration.pb.go
Normal file
1293
okapi-patient-registration.pb.go
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -1,56 +0,0 @@
|
|||
syntax = "proto3";
|
||||
import "google/protobuf/struct.proto";
|
||||
import "okapi-errors.proto";
|
||||
option go_package = "whiteboxsystems.nl/okapi";
|
||||
|
||||
message Identifier {
|
||||
string type = 1;
|
||||
string value = 2;
|
||||
}
|
||||
|
||||
message PatientRegistrationData {
|
||||
PatientMeta subject = 1;
|
||||
bool registered = 2;
|
||||
string id = 3;
|
||||
google.protobuf.Struct callbackProtocolData = 4;
|
||||
}
|
||||
|
||||
message PatientMeta {
|
||||
repeated Identifier identifier = 1;
|
||||
string firstname = 2;
|
||||
string surname = 3;
|
||||
string surnamePrefix = 4;
|
||||
string birthdate = 5;
|
||||
string street = 6;
|
||||
string streetNumber = 7;
|
||||
string streetNumberExtension = 8;
|
||||
string postalCode = 9;
|
||||
string city = 10;
|
||||
string country = 11;
|
||||
google.protobuf.Struct extra = 12;
|
||||
}
|
||||
|
||||
message PatientRegistrationError {
|
||||
int32 index = 1;
|
||||
OKAPIError error = 2;
|
||||
}
|
||||
|
||||
// Probably do this steaming (also)?
|
||||
|
||||
message UpdatePatientRegistrationRequest {
|
||||
string serviceId = 1;
|
||||
repeated PatientRegistrationData PatientRegistrationData = 2;
|
||||
bool atomicUpdate = 3;
|
||||
}
|
||||
|
||||
message UpdatePatientRegistrationResponse {
|
||||
repeated PatientRegistrationError errors = 1;
|
||||
}
|
||||
|
||||
message ListPatientRegistrationRequest {
|
||||
string serviceId = 1;
|
||||
}
|
||||
|
||||
message ListPatientRegistrationResponse {
|
||||
repeated PatientRegistrationData PatientRegistrationData = 1;
|
||||
}
|
||||
1008
okapi-service-config.pb.go
Normal file
1008
okapi-service-config.pb.go
Normal file
File diff suppressed because it is too large
Load diff
170
okapi.pb.go
Normal file
170
okapi.pb.go
Normal file
|
|
@ -0,0 +1,170 @@
|
|||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.30.0
|
||||
// protoc v3.21.12
|
||||
// source: okapi.proto
|
||||
|
||||
package okapi
|
||||
|
||||
import (
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
reflect "reflect"
|
||||
)
|
||||
|
||||
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)
|
||||
)
|
||||
|
||||
var File_okapi_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_okapi_proto_rawDesc = []byte{
|
||||
0x0a, 0x0b, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x16, 0x6f,
|
||||
0x6b, 0x61, 0x70, 0x69, 0x2d, 0x6f, 0x6e, 0x62, 0x6f, 0x61, 0x72, 0x64, 0x69, 0x6e, 0x67, 0x2e,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1a, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x2d, 0x73, 0x65, 0x72,
|
||||
0x76, 0x69, 0x63, 0x65, 0x2d, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x1a, 0x20, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x2d, 0x70, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x2d, 0x72, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72,
|
||||
0x6f, 0x74, 0x6f, 0x1a, 0x12, 0x6f, 0x6b, 0x61, 0x70, 0x69, 0x2d, 0x65, 0x76, 0x65, 0x6e, 0x74,
|
||||
0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x32, 0xce, 0x06, 0x0a, 0x05, 0x4f, 0x6b, 0x41, 0x50,
|
||||
0x49, 0x12, 0x3a, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61,
|
||||
0x12, 0x13, 0x2e, 0x47, 0x65, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65,
|
||||
0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, 0x47, 0x65, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x64,
|
||||
0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x31, 0x0a,
|
||||
0x08, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x12, 0x10, 0x2e, 0x52, 0x65, 0x67, 0x69,
|
||||
0x73, 0x74, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x11, 0x2e, 0x52, 0x65,
|
||||
0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00,
|
||||
0x12, 0x55, 0x0a, 0x14, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x67, 0x69,
|
||||
0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6c,
|
||||
0x65, 0x74, 0x65, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52,
|
||||
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74,
|
||||
0x65, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73,
|
||||
0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3d, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x53,
|
||||
0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x12, 0x14, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x53, 0x65,
|
||||
0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e,
|
||||
0x4c, 0x69, 0x73, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70,
|
||||
0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x40, 0x0a, 0x0d, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65,
|
||||
0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x15, 0x2e, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65,
|
||||
0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16,
|
||||
0x2e, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x52, 0x65,
|
||||
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x43, 0x0a, 0x0e, 0x44, 0x69, 0x73, 0x61,
|
||||
0x62, 0x6c, 0x65, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x16, 0x2e, 0x44, 0x69, 0x73,
|
||||
0x61, 0x62, 0x6c, 0x65, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x1a, 0x17, 0x2e, 0x44, 0x69, 0x73, 0x61, 0x62, 0x6c, 0x65, 0x53, 0x65, 0x72, 0x76,
|
||||
0x69, 0x63, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x7f, 0x0a,
|
||||
0x22, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x4f, 0x72, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50,
|
||||
0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x73, 0x12, 0x2a, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x4f, 0x72, 0x55, 0x70,
|
||||
0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x67, 0x69, 0x73,
|
||||
0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
|
||||
0x2b, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x4f, 0x72, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65,
|
||||
0x50, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74,
|
||||
0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x67,
|
||||
0x0a, 0x1a, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x50, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x52,
|
||||
0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x22, 0x2e, 0x52,
|
||||
0x65, 0x6d, 0x6f, 0x76, 0x65, 0x50, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x67, 0x69,
|
||||
0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
|
||||
0x1a, 0x23, 0x2e, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x50, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74,
|
||||
0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73,
|
||||
0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x61, 0x0a, 0x18, 0x4c, 0x69, 0x73, 0x74, 0x50,
|
||||
0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69,
|
||||
0x6f, 0x6e, 0x73, 0x12, 0x20, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x74, 0x69, 0x65, 0x6e,
|
||||
0x74, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65,
|
||||
0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x21, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x61, 0x74, 0x69,
|
||||
0x65, 0x6e, 0x74, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73,
|
||||
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x34, 0x0a, 0x09, 0x47, 0x65,
|
||||
0x74, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x11, 0x2e, 0x47, 0x65, 0x74, 0x45, 0x76, 0x65,
|
||||
0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x12, 0x2e, 0x47, 0x65, 0x74,
|
||||
0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00,
|
||||
0x12, 0x36, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x53, 0x74, 0x72,
|
||||
0x65, 0x61, 0x6d, 0x12, 0x17, 0x2e, 0x47, 0x65, 0x74, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x73, 0x53,
|
||||
0x74, 0x72, 0x65, 0x61, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x06, 0x2e, 0x45,
|
||||
0x76, 0x65, 0x6e, 0x74, 0x22, 0x00, 0x30, 0x01, 0x42, 0x1a, 0x5a, 0x18, 0x77, 0x68, 0x69, 0x74,
|
||||
0x65, 0x62, 0x6f, 0x78, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x73, 0x2e, 0x6e, 0x6c, 0x2f, 0x6f,
|
||||
0x6b, 0x61, 0x70, 0x69, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var file_okapi_proto_goTypes = []interface{}{
|
||||
(*GetMetadataRequest)(nil), // 0: GetMetadataRequest
|
||||
(*RegisterRequest)(nil), // 1: RegisterRequest
|
||||
(*CompleteRegistrationRequest)(nil), // 2: CompleteRegistrationRequest
|
||||
(*ListServicesRequest)(nil), // 3: ListServicesRequest
|
||||
(*EnableServiceRequest)(nil), // 4: EnableServiceRequest
|
||||
(*DisableServiceRequest)(nil), // 5: DisableServiceRequest
|
||||
(*CreateOrUpdatePatientRegistrationsRequest)(nil), // 6: CreateOrUpdatePatientRegistrationsRequest
|
||||
(*RemovePatientRegistrationsRequest)(nil), // 7: RemovePatientRegistrationsRequest
|
||||
(*ListPatientRegistrationsRequest)(nil), // 8: ListPatientRegistrationsRequest
|
||||
(*GetEventsRequest)(nil), // 9: GetEventsRequest
|
||||
(*GetEventsStreamRequest)(nil), // 10: GetEventsStreamRequest
|
||||
(*GetMetadataResponse)(nil), // 11: GetMetadataResponse
|
||||
(*RegisterResponse)(nil), // 12: RegisterResponse
|
||||
(*CompleteRegistrationResponse)(nil), // 13: CompleteRegistrationResponse
|
||||
(*ListServicesResponse)(nil), // 14: ListServicesResponse
|
||||
(*EnableServiceResponse)(nil), // 15: EnableServiceResponse
|
||||
(*DisableServiceResponse)(nil), // 16: DisableServiceResponse
|
||||
(*CreateOrUpdatePatientRegistrationsResponse)(nil), // 17: CreateOrUpdatePatientRegistrationsResponse
|
||||
(*RemovePatientRegistrationsResponse)(nil), // 18: RemovePatientRegistrationsResponse
|
||||
(*ListPatientRegistrationsResponse)(nil), // 19: ListPatientRegistrationsResponse
|
||||
(*GetEventsResponse)(nil), // 20: GetEventsResponse
|
||||
(*Event)(nil), // 21: Event
|
||||
}
|
||||
var file_okapi_proto_depIdxs = []int32{
|
||||
0, // 0: OkAPI.GetMetadata:input_type -> GetMetadataRequest
|
||||
1, // 1: OkAPI.Register:input_type -> RegisterRequest
|
||||
2, // 2: OkAPI.CompleteRegistration:input_type -> CompleteRegistrationRequest
|
||||
3, // 3: OkAPI.ListServices:input_type -> ListServicesRequest
|
||||
4, // 4: OkAPI.EnableService:input_type -> EnableServiceRequest
|
||||
5, // 5: OkAPI.DisableService:input_type -> DisableServiceRequest
|
||||
6, // 6: OkAPI.CreateOrUpdatePatientRegistrations:input_type -> CreateOrUpdatePatientRegistrationsRequest
|
||||
7, // 7: OkAPI.RemovePatientRegistrations:input_type -> RemovePatientRegistrationsRequest
|
||||
8, // 8: OkAPI.ListPatientRegistrations:input_type -> ListPatientRegistrationsRequest
|
||||
9, // 9: OkAPI.GetEvents:input_type -> GetEventsRequest
|
||||
10, // 10: OkAPI.GetEventsStream:input_type -> GetEventsStreamRequest
|
||||
11, // 11: OkAPI.GetMetadata:output_type -> GetMetadataResponse
|
||||
12, // 12: OkAPI.Register:output_type -> RegisterResponse
|
||||
13, // 13: OkAPI.CompleteRegistration:output_type -> CompleteRegistrationResponse
|
||||
14, // 14: OkAPI.ListServices:output_type -> ListServicesResponse
|
||||
15, // 15: OkAPI.EnableService:output_type -> EnableServiceResponse
|
||||
16, // 16: OkAPI.DisableService:output_type -> DisableServiceResponse
|
||||
17, // 17: OkAPI.CreateOrUpdatePatientRegistrations:output_type -> CreateOrUpdatePatientRegistrationsResponse
|
||||
18, // 18: OkAPI.RemovePatientRegistrations:output_type -> RemovePatientRegistrationsResponse
|
||||
19, // 19: OkAPI.ListPatientRegistrations:output_type -> ListPatientRegistrationsResponse
|
||||
20, // 20: OkAPI.GetEvents:output_type -> GetEventsResponse
|
||||
21, // 21: OkAPI.GetEventsStream:output_type -> Event
|
||||
11, // [11:22] is the sub-list for method output_type
|
||||
0, // [0:11] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
0, // [0:0] is the sub-list for extension extendee
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_okapi_proto_init() }
|
||||
func file_okapi_proto_init() {
|
||||
if File_okapi_proto != nil {
|
||||
return
|
||||
}
|
||||
file_okapi_onboarding_proto_init()
|
||||
file_okapi_service_config_proto_init()
|
||||
file_okapi_patient_registration_proto_init()
|
||||
file_okapi_events_proto_init()
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_okapi_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 0,
|
||||
NumExtensions: 0,
|
||||
NumServices: 1,
|
||||
},
|
||||
GoTypes: file_okapi_proto_goTypes,
|
||||
DependencyIndexes: file_okapi_proto_depIdxs,
|
||||
}.Build()
|
||||
File_okapi_proto = out.File
|
||||
file_okapi_proto_rawDesc = nil
|
||||
file_okapi_proto_goTypes = nil
|
||||
file_okapi_proto_depIdxs = nil
|
||||
}
|
||||
513
okapi_grpc.pb.go
Normal file
513
okapi_grpc.pb.go
Normal file
|
|
@ -0,0 +1,513 @@
|
|||
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
|
||||
// versions:
|
||||
// - protoc-gen-go-grpc v1.3.0
|
||||
// - protoc v3.21.12
|
||||
// source: okapi.proto
|
||||
|
||||
package okapi
|
||||
|
||||
import (
|
||||
context "context"
|
||||
grpc "google.golang.org/grpc"
|
||||
codes "google.golang.org/grpc/codes"
|
||||
status "google.golang.org/grpc/status"
|
||||
)
|
||||
|
||||
// This is a compile-time assertion to ensure that this generated file
|
||||
// is compatible with the grpc package it is being compiled against.
|
||||
// Requires gRPC-Go v1.32.0 or later.
|
||||
const _ = grpc.SupportPackageIsVersion7
|
||||
|
||||
const (
|
||||
OkAPI_GetMetadata_FullMethodName = "/OkAPI/GetMetadata"
|
||||
OkAPI_Register_FullMethodName = "/OkAPI/Register"
|
||||
OkAPI_CompleteRegistration_FullMethodName = "/OkAPI/CompleteRegistration"
|
||||
OkAPI_ListServices_FullMethodName = "/OkAPI/ListServices"
|
||||
OkAPI_EnableService_FullMethodName = "/OkAPI/EnableService"
|
||||
OkAPI_DisableService_FullMethodName = "/OkAPI/DisableService"
|
||||
OkAPI_CreateOrUpdatePatientRegistrations_FullMethodName = "/OkAPI/CreateOrUpdatePatientRegistrations"
|
||||
OkAPI_RemovePatientRegistrations_FullMethodName = "/OkAPI/RemovePatientRegistrations"
|
||||
OkAPI_ListPatientRegistrations_FullMethodName = "/OkAPI/ListPatientRegistrations"
|
||||
OkAPI_GetEvents_FullMethodName = "/OkAPI/GetEvents"
|
||||
OkAPI_GetEventsStream_FullMethodName = "/OkAPI/GetEventsStream"
|
||||
)
|
||||
|
||||
// OkAPIClient is the client API for OkAPI service.
|
||||
//
|
||||
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
|
||||
type OkAPIClient interface {
|
||||
// Onboarding
|
||||
GetMetadata(ctx context.Context, in *GetMetadataRequest, opts ...grpc.CallOption) (*GetMetadataResponse, error)
|
||||
Register(ctx context.Context, in *RegisterRequest, opts ...grpc.CallOption) (*RegisterResponse, error)
|
||||
CompleteRegistration(ctx context.Context, in *CompleteRegistrationRequest, opts ...grpc.CallOption) (*CompleteRegistrationResponse, error)
|
||||
// Configuration
|
||||
ListServices(ctx context.Context, in *ListServicesRequest, opts ...grpc.CallOption) (*ListServicesResponse, error)
|
||||
EnableService(ctx context.Context, in *EnableServiceRequest, opts ...grpc.CallOption) (*EnableServiceResponse, error)
|
||||
DisableService(ctx context.Context, in *DisableServiceRequest, opts ...grpc.CallOption) (*DisableServiceResponse, error)
|
||||
CreateOrUpdatePatientRegistrations(ctx context.Context, in *CreateOrUpdatePatientRegistrationsRequest, opts ...grpc.CallOption) (*CreateOrUpdatePatientRegistrationsResponse, error)
|
||||
RemovePatientRegistrations(ctx context.Context, in *RemovePatientRegistrationsRequest, opts ...grpc.CallOption) (*RemovePatientRegistrationsResponse, error)
|
||||
ListPatientRegistrations(ctx context.Context, in *ListPatientRegistrationsRequest, opts ...grpc.CallOption) (*ListPatientRegistrationsResponse, error)
|
||||
// Events
|
||||
GetEvents(ctx context.Context, in *GetEventsRequest, opts ...grpc.CallOption) (*GetEventsResponse, error)
|
||||
GetEventsStream(ctx context.Context, in *GetEventsStreamRequest, opts ...grpc.CallOption) (OkAPI_GetEventsStreamClient, error)
|
||||
}
|
||||
|
||||
type okAPIClient struct {
|
||||
cc grpc.ClientConnInterface
|
||||
}
|
||||
|
||||
func NewOkAPIClient(cc grpc.ClientConnInterface) OkAPIClient {
|
||||
return &okAPIClient{cc}
|
||||
}
|
||||
|
||||
func (c *okAPIClient) GetMetadata(ctx context.Context, in *GetMetadataRequest, opts ...grpc.CallOption) (*GetMetadataResponse, error) {
|
||||
out := new(GetMetadataResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_GetMetadata_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) Register(ctx context.Context, in *RegisterRequest, opts ...grpc.CallOption) (*RegisterResponse, error) {
|
||||
out := new(RegisterResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_Register_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) CompleteRegistration(ctx context.Context, in *CompleteRegistrationRequest, opts ...grpc.CallOption) (*CompleteRegistrationResponse, error) {
|
||||
out := new(CompleteRegistrationResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_CompleteRegistration_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) ListServices(ctx context.Context, in *ListServicesRequest, opts ...grpc.CallOption) (*ListServicesResponse, error) {
|
||||
out := new(ListServicesResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_ListServices_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) EnableService(ctx context.Context, in *EnableServiceRequest, opts ...grpc.CallOption) (*EnableServiceResponse, error) {
|
||||
out := new(EnableServiceResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_EnableService_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) DisableService(ctx context.Context, in *DisableServiceRequest, opts ...grpc.CallOption) (*DisableServiceResponse, error) {
|
||||
out := new(DisableServiceResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_DisableService_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) CreateOrUpdatePatientRegistrations(ctx context.Context, in *CreateOrUpdatePatientRegistrationsRequest, opts ...grpc.CallOption) (*CreateOrUpdatePatientRegistrationsResponse, error) {
|
||||
out := new(CreateOrUpdatePatientRegistrationsResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_CreateOrUpdatePatientRegistrations_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) RemovePatientRegistrations(ctx context.Context, in *RemovePatientRegistrationsRequest, opts ...grpc.CallOption) (*RemovePatientRegistrationsResponse, error) {
|
||||
out := new(RemovePatientRegistrationsResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_RemovePatientRegistrations_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) ListPatientRegistrations(ctx context.Context, in *ListPatientRegistrationsRequest, opts ...grpc.CallOption) (*ListPatientRegistrationsResponse, error) {
|
||||
out := new(ListPatientRegistrationsResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_ListPatientRegistrations_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) GetEvents(ctx context.Context, in *GetEventsRequest, opts ...grpc.CallOption) (*GetEventsResponse, error) {
|
||||
out := new(GetEventsResponse)
|
||||
err := c.cc.Invoke(ctx, OkAPI_GetEvents_FullMethodName, in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *okAPIClient) GetEventsStream(ctx context.Context, in *GetEventsStreamRequest, opts ...grpc.CallOption) (OkAPI_GetEventsStreamClient, error) {
|
||||
stream, err := c.cc.NewStream(ctx, &OkAPI_ServiceDesc.Streams[0], OkAPI_GetEventsStream_FullMethodName, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
x := &okAPIGetEventsStreamClient{stream}
|
||||
if err := x.ClientStream.SendMsg(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if err := x.ClientStream.CloseSend(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return x, nil
|
||||
}
|
||||
|
||||
type OkAPI_GetEventsStreamClient interface {
|
||||
Recv() (*Event, error)
|
||||
grpc.ClientStream
|
||||
}
|
||||
|
||||
type okAPIGetEventsStreamClient struct {
|
||||
grpc.ClientStream
|
||||
}
|
||||
|
||||
func (x *okAPIGetEventsStreamClient) Recv() (*Event, error) {
|
||||
m := new(Event)
|
||||
if err := x.ClientStream.RecvMsg(m); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return m, nil
|
||||
}
|
||||
|
||||
// OkAPIServer is the server API for OkAPI service.
|
||||
// All implementations must embed UnimplementedOkAPIServer
|
||||
// for forward compatibility
|
||||
type OkAPIServer interface {
|
||||
// Onboarding
|
||||
GetMetadata(context.Context, *GetMetadataRequest) (*GetMetadataResponse, error)
|
||||
Register(context.Context, *RegisterRequest) (*RegisterResponse, error)
|
||||
CompleteRegistration(context.Context, *CompleteRegistrationRequest) (*CompleteRegistrationResponse, error)
|
||||
// Configuration
|
||||
ListServices(context.Context, *ListServicesRequest) (*ListServicesResponse, error)
|
||||
EnableService(context.Context, *EnableServiceRequest) (*EnableServiceResponse, error)
|
||||
DisableService(context.Context, *DisableServiceRequest) (*DisableServiceResponse, error)
|
||||
CreateOrUpdatePatientRegistrations(context.Context, *CreateOrUpdatePatientRegistrationsRequest) (*CreateOrUpdatePatientRegistrationsResponse, error)
|
||||
RemovePatientRegistrations(context.Context, *RemovePatientRegistrationsRequest) (*RemovePatientRegistrationsResponse, error)
|
||||
ListPatientRegistrations(context.Context, *ListPatientRegistrationsRequest) (*ListPatientRegistrationsResponse, error)
|
||||
// Events
|
||||
GetEvents(context.Context, *GetEventsRequest) (*GetEventsResponse, error)
|
||||
GetEventsStream(*GetEventsStreamRequest, OkAPI_GetEventsStreamServer) error
|
||||
mustEmbedUnimplementedOkAPIServer()
|
||||
}
|
||||
|
||||
// UnimplementedOkAPIServer must be embedded to have forward compatible implementations.
|
||||
type UnimplementedOkAPIServer struct {
|
||||
}
|
||||
|
||||
func (UnimplementedOkAPIServer) GetMetadata(context.Context, *GetMetadataRequest) (*GetMetadataResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method GetMetadata not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) Register(context.Context, *RegisterRequest) (*RegisterResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method Register not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) CompleteRegistration(context.Context, *CompleteRegistrationRequest) (*CompleteRegistrationResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method CompleteRegistration not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) ListServices(context.Context, *ListServicesRequest) (*ListServicesResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method ListServices not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) EnableService(context.Context, *EnableServiceRequest) (*EnableServiceResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method EnableService not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) DisableService(context.Context, *DisableServiceRequest) (*DisableServiceResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method DisableService not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) CreateOrUpdatePatientRegistrations(context.Context, *CreateOrUpdatePatientRegistrationsRequest) (*CreateOrUpdatePatientRegistrationsResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method CreateOrUpdatePatientRegistrations not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) RemovePatientRegistrations(context.Context, *RemovePatientRegistrationsRequest) (*RemovePatientRegistrationsResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method RemovePatientRegistrations not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) ListPatientRegistrations(context.Context, *ListPatientRegistrationsRequest) (*ListPatientRegistrationsResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method ListPatientRegistrations not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) GetEvents(context.Context, *GetEventsRequest) (*GetEventsResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method GetEvents not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) GetEventsStream(*GetEventsStreamRequest, OkAPI_GetEventsStreamServer) error {
|
||||
return status.Errorf(codes.Unimplemented, "method GetEventsStream not implemented")
|
||||
}
|
||||
func (UnimplementedOkAPIServer) mustEmbedUnimplementedOkAPIServer() {}
|
||||
|
||||
// UnsafeOkAPIServer may be embedded to opt out of forward compatibility for this service.
|
||||
// Use of this interface is not recommended, as added methods to OkAPIServer will
|
||||
// result in compilation errors.
|
||||
type UnsafeOkAPIServer interface {
|
||||
mustEmbedUnimplementedOkAPIServer()
|
||||
}
|
||||
|
||||
func RegisterOkAPIServer(s grpc.ServiceRegistrar, srv OkAPIServer) {
|
||||
s.RegisterService(&OkAPI_ServiceDesc, srv)
|
||||
}
|
||||
|
||||
func _OkAPI_GetMetadata_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(GetMetadataRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).GetMetadata(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_GetMetadata_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).GetMetadata(ctx, req.(*GetMetadataRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_Register_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(RegisterRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).Register(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_Register_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).Register(ctx, req.(*RegisterRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_CompleteRegistration_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(CompleteRegistrationRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).CompleteRegistration(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_CompleteRegistration_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).CompleteRegistration(ctx, req.(*CompleteRegistrationRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_ListServices_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(ListServicesRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).ListServices(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_ListServices_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).ListServices(ctx, req.(*ListServicesRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_EnableService_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(EnableServiceRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).EnableService(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_EnableService_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).EnableService(ctx, req.(*EnableServiceRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_DisableService_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(DisableServiceRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).DisableService(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_DisableService_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).DisableService(ctx, req.(*DisableServiceRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_CreateOrUpdatePatientRegistrations_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(CreateOrUpdatePatientRegistrationsRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).CreateOrUpdatePatientRegistrations(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_CreateOrUpdatePatientRegistrations_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).CreateOrUpdatePatientRegistrations(ctx, req.(*CreateOrUpdatePatientRegistrationsRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_RemovePatientRegistrations_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(RemovePatientRegistrationsRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).RemovePatientRegistrations(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_RemovePatientRegistrations_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).RemovePatientRegistrations(ctx, req.(*RemovePatientRegistrationsRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_ListPatientRegistrations_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(ListPatientRegistrationsRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).ListPatientRegistrations(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_ListPatientRegistrations_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).ListPatientRegistrations(ctx, req.(*ListPatientRegistrationsRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_GetEvents_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(GetEventsRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(OkAPIServer).GetEvents(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: OkAPI_GetEvents_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(OkAPIServer).GetEvents(ctx, req.(*GetEventsRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _OkAPI_GetEventsStream_Handler(srv interface{}, stream grpc.ServerStream) error {
|
||||
m := new(GetEventsStreamRequest)
|
||||
if err := stream.RecvMsg(m); err != nil {
|
||||
return err
|
||||
}
|
||||
return srv.(OkAPIServer).GetEventsStream(m, &okAPIGetEventsStreamServer{stream})
|
||||
}
|
||||
|
||||
type OkAPI_GetEventsStreamServer interface {
|
||||
Send(*Event) error
|
||||
grpc.ServerStream
|
||||
}
|
||||
|
||||
type okAPIGetEventsStreamServer struct {
|
||||
grpc.ServerStream
|
||||
}
|
||||
|
||||
func (x *okAPIGetEventsStreamServer) Send(m *Event) error {
|
||||
return x.ServerStream.SendMsg(m)
|
||||
}
|
||||
|
||||
// OkAPI_ServiceDesc is the grpc.ServiceDesc for OkAPI service.
|
||||
// It's only intended for direct use with grpc.RegisterService,
|
||||
// and not to be introspected or modified (even as a copy)
|
||||
var OkAPI_ServiceDesc = grpc.ServiceDesc{
|
||||
ServiceName: "OkAPI",
|
||||
HandlerType: (*OkAPIServer)(nil),
|
||||
Methods: []grpc.MethodDesc{
|
||||
{
|
||||
MethodName: "GetMetadata",
|
||||
Handler: _OkAPI_GetMetadata_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "Register",
|
||||
Handler: _OkAPI_Register_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "CompleteRegistration",
|
||||
Handler: _OkAPI_CompleteRegistration_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "ListServices",
|
||||
Handler: _OkAPI_ListServices_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "EnableService",
|
||||
Handler: _OkAPI_EnableService_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "DisableService",
|
||||
Handler: _OkAPI_DisableService_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "CreateOrUpdatePatientRegistrations",
|
||||
Handler: _OkAPI_CreateOrUpdatePatientRegistrations_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "RemovePatientRegistrations",
|
||||
Handler: _OkAPI_RemovePatientRegistrations_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "ListPatientRegistrations",
|
||||
Handler: _OkAPI_ListPatientRegistrations_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "GetEvents",
|
||||
Handler: _OkAPI_GetEvents_Handler,
|
||||
},
|
||||
},
|
||||
Streams: []grpc.StreamDesc{
|
||||
{
|
||||
StreamName: "GetEventsStream",
|
||||
Handler: _OkAPI_GetEventsStream_Handler,
|
||||
ServerStreams: true,
|
||||
},
|
||||
},
|
||||
Metadata: "okapi.proto",
|
||||
}
|
||||
|
|
@ -8,7 +8,7 @@ enum OKAPIErrorCode {
|
|||
// Onbekende reference meegegeven
|
||||
UnkownReference = 2;
|
||||
// Invalide autorisatietoken voor deze reference
|
||||
InvalidAuthorisationToken = 3;
|
||||
InvalidAuthorizationToken = 3;
|
||||
// Onbekende service
|
||||
UnknownService = 4;
|
||||
// Onbekende protocol
|
||||
|
|
@ -21,6 +21,15 @@ enum OKAPIErrorCode {
|
|||
InvalidProcotolAuthConfig = 8;
|
||||
// Er zijn niet genoeg events om deze pagina te bereiken
|
||||
InvalidPage = 9;
|
||||
// Er wordt geprobeerd een patient af te melden die niet is ingeschreven
|
||||
AlreadyUnsubscribed = 10;
|
||||
// De service is al actief
|
||||
ServiceAlreadyActivated = 11;
|
||||
// De service is niet actief
|
||||
ServiceNotActive = 12;
|
||||
// Een generieke error code die terug wordt gegeven met en omschrijving die
|
||||
// meer informatie geeft over wat er fout is gegaan
|
||||
GenericException = 999;
|
||||
}
|
||||
|
||||
message OKAPIError {
|
||||
65
protobuf/okapi-events.proto
Normal file
65
protobuf/okapi-events.proto
Normal file
|
|
@ -0,0 +1,65 @@
|
|||
syntax = "proto3";
|
||||
import "google/protobuf/struct.proto";
|
||||
option go_package = "whiteboxsystems.nl/okapi";
|
||||
|
||||
// idea:
|
||||
// query:
|
||||
// /:type[/:subtype+]/:service/:patient with wildcard
|
||||
|
||||
// Should events payloads be documented by for example json schema?
|
||||
message Event {
|
||||
uint64 timestamp = 1;
|
||||
string type = 2;
|
||||
string serviceId = 3;
|
||||
string patientId = 4;
|
||||
google.protobuf.Struct payload = 5;
|
||||
// string schema = 6; // ? do we need a schema in the event itself
|
||||
}
|
||||
message Query {
|
||||
uint64 start = 1;
|
||||
uint64 end = 2;
|
||||
string type = 3;
|
||||
string serviceId = 4;
|
||||
string patientId = 5;
|
||||
}
|
||||
|
||||
message GetEventsRequest {
|
||||
int32 page = 2;
|
||||
int32 perPage = 3;
|
||||
repeated Query query = 4;
|
||||
}
|
||||
|
||||
message GetEventsResponse {
|
||||
int32 page = 2;
|
||||
int32 perPage = 3;
|
||||
repeated Event events = 4;
|
||||
}
|
||||
|
||||
message GetEventsStreamRequest {
|
||||
repeated Query query = 2;
|
||||
}
|
||||
|
||||
// enum EventCallbackMethod {
|
||||
// none = 0;
|
||||
// webhook = 1;
|
||||
// }
|
||||
|
||||
// message EventCallback {
|
||||
// string id = 1; // who fills this
|
||||
// bool active = 2;
|
||||
// EventCallbackMethod method = 3;
|
||||
// repeated Query query = 4;
|
||||
// }
|
||||
|
||||
// message RegisterEventCallbackRequest {
|
||||
// repeated EventCallback callbacks = 1;
|
||||
// }
|
||||
|
||||
// message RegisterEventCallbackResponse {}
|
||||
|
||||
// message ListEventCallbacksRequest {
|
||||
// }
|
||||
|
||||
// message ListEventCallbacksResponse {
|
||||
// repeated EventCallback callbacks = 1;
|
||||
// }
|
||||
|
|
@ -3,22 +3,20 @@ option go_package = "whiteboxsystems.nl/okapi";
|
|||
|
||||
enum XISAuthMethod {
|
||||
mTLS = 0;
|
||||
BearerToken = 1;
|
||||
}
|
||||
|
||||
message MTLSConfigurationParams {
|
||||
// JWK (RFC 7517) presentatie van publieke sleutel van het
|
||||
// client certificaat dat gebruikt gaat worden voor het opzetten
|
||||
// van de verbinding.
|
||||
// Voorbeeld: "{\"crv\":\"P-256\",\"kty\":\"EC\",\"x\":\"PZlyqX3X...\", \"y\":\"AawwPSKBt...\"}"
|
||||
string publicKey = 1;
|
||||
}
|
||||
|
||||
message BearerTokenConfigurationParams {
|
||||
string token = 1;
|
||||
}
|
||||
|
||||
message XISAuthConfiguration {
|
||||
XISAuthMethod method = 1;
|
||||
oneof configuration {
|
||||
MTLSConfigurationParams mtlsConfiguration = 2;
|
||||
BearerTokenConfigurationParams apiTokenConfiguration = 3;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -45,7 +43,7 @@ message RegisterResponse {
|
|||
|
||||
message CompleteRegistrationRequest {
|
||||
string reference = 1;
|
||||
string authorisationToken = 2;
|
||||
string AuthorizationToken = 2;
|
||||
}
|
||||
|
||||
message CompleteRegistrationResponse {}
|
||||
90
protobuf/okapi-patient-registration.proto
Normal file
90
protobuf/okapi-patient-registration.proto
Normal file
|
|
@ -0,0 +1,90 @@
|
|||
syntax = "proto3";
|
||||
import "google/protobuf/struct.proto";
|
||||
import "okapi-errors.proto";
|
||||
option go_package = "whiteboxsystems.nl/okapi";
|
||||
|
||||
message Identifier {
|
||||
string type = 1;
|
||||
string value = 2;
|
||||
}
|
||||
|
||||
message PatientRegistrationData {
|
||||
string id = 1;
|
||||
PatientMeta subject = 2;
|
||||
google.protobuf.Struct callbackProtocolData = 3;
|
||||
|
||||
// Aangeven van extra data voor dienst specifieke zaken, bijv policy oid,
|
||||
google.protobuf.Struct serviceInput = 4;
|
||||
google.protobuf.Struct serviceOutput = 5;
|
||||
}
|
||||
|
||||
message Name {
|
||||
string display = 1;
|
||||
repeated string given = 2;
|
||||
string ownName = 3;
|
||||
string ownNamePrefix = 4;
|
||||
string partnerName = 5;
|
||||
string partnerNamePrefix = 6;
|
||||
}
|
||||
|
||||
message Address {
|
||||
string street = 1;
|
||||
string streetNumber = 2;
|
||||
string postalCode = 3;
|
||||
string city = 4;
|
||||
string country = 5;
|
||||
}
|
||||
|
||||
message PatientMeta {
|
||||
Identifier identifier = 1;
|
||||
Name name = 2;
|
||||
Address address = 3;
|
||||
string birthdate = 4; // Date in format yyyy-mm-dd
|
||||
google.protobuf.Struct extra = 5;
|
||||
}
|
||||
|
||||
message PatientRegistrationCreateOrUpdateData {
|
||||
string id = 1;
|
||||
PatientMeta subject = 2;
|
||||
google.protobuf.Struct callbackProtocolData = 3;
|
||||
google.protobuf.Struct serviceInput = 4;
|
||||
}
|
||||
|
||||
message PatientRegistrationResult {
|
||||
string id = 1;
|
||||
google.protobuf.Struct serviceOuput = 2;
|
||||
OKAPIError error = 3;
|
||||
}
|
||||
|
||||
// Probably do this streaming (also)?
|
||||
message CreateOrUpdatePatientRegistrationsRequest {
|
||||
string serviceId = 1;
|
||||
repeated PatientRegistrationCreateOrUpdateData registrations = 2;
|
||||
}
|
||||
|
||||
message CreateOrUpdatePatientRegistrationsResponse {
|
||||
repeated PatientRegistrationResult results = 1;
|
||||
}
|
||||
|
||||
message RemovePatientRegistrationsRequest {
|
||||
string serviceId = 1;
|
||||
repeated string registrations = 2;
|
||||
}
|
||||
|
||||
message RemovePatientRegistrationsResponse {
|
||||
repeated PatientRegistrationResult results = 1;
|
||||
}
|
||||
|
||||
message ListPatientRegistrationQuery {
|
||||
repeated string id = 1;
|
||||
repeated Identifier identifier = 2;
|
||||
}
|
||||
|
||||
message ListPatientRegistrationsRequest {
|
||||
string serviceId = 1;
|
||||
ListPatientRegistrationQuery query = 2;
|
||||
}
|
||||
|
||||
message ListPatientRegistrationsResponse {
|
||||
repeated PatientRegistrationData patientRegistrationData = 1;
|
||||
}
|
||||
|
|
@ -26,7 +26,7 @@ message ProtocolDefinition {
|
|||
repeated string authMethods = 2;
|
||||
}
|
||||
|
||||
message ServiceDefinition {
|
||||
message Service {
|
||||
string id = 1;
|
||||
string name = 2;
|
||||
string description = 3;
|
||||
|
|
@ -34,6 +34,9 @@ message ServiceDefinition {
|
|||
ConsentPolicy consentPolicy = 5;
|
||||
repeated ProtocolDefinition fetchProtocols = 6;
|
||||
repeated ProtocolDefinition pushProtocols = 7;
|
||||
CallbackConfiguration fetchConfiguration = 8;
|
||||
CallbackConfiguration pushConfiguration = 9;
|
||||
bool enabled = 10;
|
||||
}
|
||||
|
||||
message CallbackConfiguration {
|
||||
|
|
@ -42,37 +45,28 @@ message CallbackConfiguration {
|
|||
ProtocolAuthConfiguration auth = 3;
|
||||
}
|
||||
|
||||
message ConfigureCallbackRequest {
|
||||
message EnableServiceRequest {
|
||||
string serviceId = 1;
|
||||
bool enabled = 2;
|
||||
CallbackConfiguration fetch = 3;
|
||||
CallbackConfiguration push = 4;
|
||||
CallbackConfiguration fetch = 2;
|
||||
CallbackConfiguration push = 3;
|
||||
}
|
||||
|
||||
message ConfigureCallbackResponse {
|
||||
message EnableServiceResponse {
|
||||
string serviceId = 1;
|
||||
bool enabled = 2;
|
||||
CallbackConfiguration fetch = 3;
|
||||
CallbackConfiguration push = 4;
|
||||
CallbackConfiguration fetch = 2;
|
||||
CallbackConfiguration push = 3;
|
||||
}
|
||||
|
||||
message DisableServiceRequest {
|
||||
string serviceId = 1;
|
||||
}
|
||||
|
||||
message DisableServiceResponse {}
|
||||
|
||||
// ListServices
|
||||
|
||||
message ServiceConfiguration {
|
||||
string serviceId = 1;
|
||||
bool enabled = 2;
|
||||
CallbackConfiguration fetch = 3;
|
||||
CallbackConfiguration push = 4;
|
||||
}
|
||||
|
||||
message ListServicesRequest {}
|
||||
|
||||
message ListServicesResponse {
|
||||
repeated ServiceDefinition availableServices = 1;
|
||||
}
|
||||
|
||||
message ListServiceConfigurationsRequest {}
|
||||
|
||||
message ListServiceConfigurationsResponse {
|
||||
repeated ServiceConfiguration configurations = 2;
|
||||
repeated Service services = 1;
|
||||
}
|
||||
|
|
@ -12,15 +12,18 @@ service OkAPI {
|
|||
rpc CompleteRegistration (CompleteRegistrationRequest) returns (CompleteRegistrationResponse) {}
|
||||
|
||||
// Configuration
|
||||
rpc ConfigureCallback (ConfigureCallbackRequest) returns (ConfigureCallbackResponse) {}
|
||||
rpc ListServices (ListServicesRequest) returns (ListServicesResponse) {}
|
||||
rpc ListServiceConfigurations (ListServiceConfigurationsRequest) returns (ListServiceConfigurationsResponse) {}
|
||||
rpc EnableService (EnableServiceRequest) returns (EnableServiceResponse) {}
|
||||
rpc DisableService (DisableServiceRequest) returns (DisableServiceResponse) {}
|
||||
|
||||
rpc UpdatePatientRegistration (UpdatePatientRegistrationRequest) returns (UpdatePatientRegistrationResponse) {}
|
||||
rpc ListPatientRegistration (ListPatientRegistrationRequest) returns (ListPatientRegistrationResponse) {}
|
||||
rpc ListPatientRegistrations (ListPatientRegistrationsRequest) returns (ListPatientRegistrationsResponse) {}
|
||||
rpc CreateOrUpdatePatientRegistrations (CreateOrUpdatePatientRegistrationsRequest) returns (CreateOrUpdatePatientRegistrationsResponse) {}
|
||||
rpc RemovePatientRegistrations (RemovePatientRegistrationsRequest) returns (RemovePatientRegistrationsResponse) {}
|
||||
|
||||
// Events
|
||||
rpc GetEvents (GetEventsRequest) returns (GetEventsResponse) {}
|
||||
rpc GetEventsStream (GetEventsStreamRequest) returns (stream Event) {}
|
||||
// rpc RegisterEventCallback (RegisterEventCallbackRequest) returns (RegisterEventCallbackResponse) {}
|
||||
// rpc ListEventCallbacks (ListEventCallbacksRequest) returns (ListEventCallbacksResponse) {}
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue