diff --git a/.gitignore b/.gitignore index dce443e7..f2601fff 100644 --- a/.gitignore +++ b/.gitignore @@ -23,5 +23,11 @@ swift/message_api swift/message_contents swift/mls swift/mls_validation + +## Working plan docs docs/plans + +## AI Tools .omx/ +.claude/* +!.claude/skills diff --git a/buf.gen.yaml b/buf.gen.yaml index ce8193db..60271026 100644 --- a/buf.gen.yaml +++ b/buf.gen.yaml @@ -12,14 +12,6 @@ managed: - buf.build/googleapis/googleapis - buf.build/grpc-ecosystem/grpc-gateway plugins: - - plugin: buf.build/grpc/go:v1.3.0 - out: pkg/proto - opt: - - paths=source_relative - - plugin: buf.build/protocolbuffers/go - out: pkg/proto - opt: - - paths=source_relative - plugin: buf.build/connectrpc/swift opt: - GenerateAsyncMethods=true diff --git a/go.mod b/go.mod index ad72b547..0c29958d 100644 --- a/go.mod +++ b/go.mod @@ -6,18 +6,16 @@ require ( connectrpc.com/connect v1.19.1 firebase.google.com/go/v4 v4.15.2 github.com/golang-migrate/migrate/v4 v4.19.0 - github.com/grpc-ecosystem/grpc-gateway/v2 v2.28.0 github.com/jackc/pgx/v5 v5.9.1 github.com/jessevdk/go-flags v1.6.1 github.com/lib/pq v1.12.0 github.com/pkg/errors v0.9.1 github.com/sideshow/apns2 v0.25.0 github.com/stretchr/testify v1.11.1 - github.com/xmtp/xmtpd v1.3.0 + github.com/xmtp/xmtpd v1.3.1-0.20260402033823-6ae509c61de3 go.uber.org/zap v1.27.1 golang.org/x/net v0.52.0 google.golang.org/api v0.231.0 - google.golang.org/genproto/googleapis/api v0.0.0-20260209200024-4cfbd4190f57 google.golang.org/grpc v1.79.3 google.golang.org/protobuf v1.36.11 ) @@ -37,30 +35,49 @@ require ( github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.51.0 // indirect github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.51.0 // indirect github.com/MicahParks/keyfunc v1.9.0 // indirect + github.com/Microsoft/go-winio v0.6.2 // indirect + github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20251001021608-1fe7b43fc4d6 // indirect + github.com/StackExchange/wmi v1.2.1 // indirect + github.com/bits-and-blooms/bitset v1.20.0 // indirect + github.com/cenkalti/backoff/v4 v4.3.0 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/cncf/xds/go v0.0.0-20251210132809-ee656c7534f5 // indirect + github.com/consensys/gnark-crypto v0.18.1 // indirect + github.com/crate-crypto/go-eth-kzg v1.4.0 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect + github.com/deckarep/golang-set/v2 v2.6.0 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect github.com/envoyproxy/go-control-plane/envoy v1.36.0 // indirect github.com/envoyproxy/protoc-gen-validate v1.3.0 // indirect + github.com/ethereum/c-kzg-4844/v2 v2.1.5 // indirect + github.com/ethereum/go-ethereum v1.17.0 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect github.com/go-jose/go-jose/v4 v4.1.3 // indirect github.com/go-logr/logr v1.4.3 // indirect github.com/go-logr/stdr v1.2.2 // indirect + github.com/go-ole/go-ole v1.3.0 // indirect github.com/golang-jwt/jwt/v4 v4.5.2 // indirect github.com/golang/protobuf v1.5.4 // indirect github.com/google/s2a-go v0.1.9 // indirect github.com/google/uuid v1.6.0 // indirect github.com/googleapis/enterprise-certificate-proxy v0.3.6 // indirect github.com/googleapis/gax-go/v2 v2.14.1 // indirect + github.com/gorilla/websocket v1.5.0 // indirect + github.com/grpc-ecosystem/grpc-gateway/v2 v2.28.0 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect + github.com/holiman/uint256 v1.3.2 // indirect github.com/jackc/pgpassfile v1.0.0 // indirect github.com/jackc/pgservicefile v0.0.0-20240606120523-5a60cdf6a761 // indirect github.com/jackc/puddle/v2 v2.2.2 // indirect github.com/planetscale/vtprotobuf v0.6.1-0.20240319094008-0393e58bdf10 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect + github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect github.com/spiffe/go-spiffe/v2 v2.6.0 // indirect github.com/stretchr/objx v0.5.2 // indirect + github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe // indirect + github.com/tklauser/go-sysconf v0.3.16 // indirect + github.com/tklauser/numcpus v0.11.0 // indirect go.opentelemetry.io/auto/sdk v1.2.1 // indirect go.opentelemetry.io/contrib/detectors/gcp v1.39.0 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0 // indirect @@ -79,6 +96,7 @@ require ( golang.org/x/time v0.14.0 // indirect google.golang.org/appengine/v2 v2.0.6 // indirect google.golang.org/genproto v0.0.0-20250428153025-10db94c68c34 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20260209200024-4cfbd4190f57 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20260209200024-4cfbd4190f57 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/go.sum b/go.sum index c0c0501b..1e295eb4 100644 --- a/go.sum +++ b/go.sum @@ -72,6 +72,8 @@ github.com/DataDog/go-tuf v1.1.1-0.5.2 h1:YWvghV4ZvrQsPcUw8IOUMSDpqc3W5ruOIC+KJx github.com/DataDog/go-tuf v1.1.1-0.5.2/go.mod h1:zBcq6f654iVqmkk8n2Cx81E1JnNTMOAx1UEO/wZR+P0= github.com/DataDog/sketches-go v1.4.7 h1:eHs5/0i2Sdf20Zkj0udVFWuCrXGRFig2Dcfm5rtcTxc= github.com/DataDog/sketches-go v1.4.7/go.mod h1:eAmQ/EBmtSO+nQp7IZMZVRPT4BQTmIc5RZQ+deGlTPM= +github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ= +github.com/DataDog/zstd v1.4.5/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.30.0 h1:sBEjpZlNHzK1voKq9695PJSX2o5NEXl7/OL3coiIY0c= github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.30.0/go.mod h1:P4WPRUkOhJC13W//jWpyfJNDAIpvRbAUIYLX/4jtlE0= github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.51.0 h1:fYE9p3esPxA/C0rQ0AHhP0drtPXDRhaWiwg1DPqO7IU= @@ -90,6 +92,8 @@ github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20251001021608 github.com/ProjectZKM/Ziren/crates/go-runtime/zkvm_runtime v0.0.0-20251001021608-1fe7b43fc4d6/go.mod h1:ioLG6R+5bUSO1oeGSDxOV3FADARuMoytZCSX6MEMQkI= github.com/StackExchange/wmi v1.2.1 h1:VIkavFPXSjcnS+O8yTq7NI32k0R5Aj+v39y29VYDOSA= github.com/StackExchange/wmi v1.2.1/go.mod h1:rcmrprowKIVzvc+NUiLncP2uuArMWLCbu9SBzvHz7e8= +github.com/VictoriaMetrics/fastcache v1.13.0 h1:AW4mheMR5Vd9FkAPUv+NH6Nhw+fmbTMGMsNAoA/+4G0= +github.com/VictoriaMetrics/fastcache v1.13.0/go.mod h1:hHXhl4DA2fTL2HTZDJFXWgW0LNjo6B+4aj2Wmng3TjU= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20201120081800-1786d5ef83d4/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -104,19 +108,37 @@ github.com/cihub/seelog v0.0.0-20170130134532-f561c5e57575 h1:kHaBemcxl8o/pQ5VM1 github.com/cihub/seelog v0.0.0-20170130134532-f561c5e57575/go.mod h1:9d6lWj8KzO/fd/NrVaLscBKmPigpZpn5YawRPw+e3Yo= github.com/cncf/xds/go v0.0.0-20251210132809-ee656c7534f5 h1:6xNmx7iTtyBRev0+D/Tv1FZd4SCg8axKApyNyRsAt/w= github.com/cncf/xds/go v0.0.0-20251210132809-ee656c7534f5/go.mod h1:KdCmV+x/BuvyMxRnYBlmVaq4OLiKW6iRQfvC62cvdkI= +github.com/cockroachdb/errors v1.11.3 h1:5bA+k2Y6r+oz/6Z/RFlNeVCesGARKuC6YymtcDrbC/I= +github.com/cockroachdb/errors v1.11.3/go.mod h1:m4UIW4CDjx+R5cybPsNrRbreomiFqt8o1h1wUVazSd8= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce h1:giXvy4KSc/6g/esnpM7Geqxka4WSqI1SZc7sMJFd3y4= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce/go.mod h1:9/y3cnZ5GKakj/H4y9r9GTjCvAFta7KLgSHPJJYc52M= +github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= +github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= +github.com/cockroachdb/pebble v1.1.5 h1:5AAWCBWbat0uE0blr8qzufZP5tBjkRyy/jWe1QWLnvw= +github.com/cockroachdb/pebble v1.1.5/go.mod h1:17wO9el1YEigxkP/YtV8NtCivQDgoCyBg5c4VR/eOWo= +github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= +github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= +github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= +github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/consensys/gnark-crypto v0.18.1 h1:RyLV6UhPRoYYzaFnPQA4qK3DyuDgkTgskDdoGqFt3fI= github.com/consensys/gnark-crypto v0.18.1/go.mod h1:L3mXGFTe1ZN+RSJ+CLjUt9x7PNdx8ubaYfDROyp2Z8c= github.com/containerd/errdefs v1.0.0 h1:tg5yIfIlQIrxYtu9ajqY42W3lpS19XqdxRQeEwYG8PI= github.com/containerd/errdefs v1.0.0/go.mod h1:+YBYIdtsnF4Iw6nWZhJcqGSg/dwvV7tyJ/kCkyJ2k+M= github.com/containerd/errdefs/pkg v0.3.0 h1:9IKJ06FvyNlexW690DXuQNx2KA2cUJXx151Xdx3ZPPE= github.com/containerd/errdefs/pkg v0.3.0/go.mod h1:NJw6s9HwNuRhnjJhM7pylWwMyAkmCQvQ4GpJHEqRLVk= +github.com/cpuguy83/go-md2man/v2 v2.0.5 h1:ZtcqGrnekaHpVLArFSe4HK5DoKx1T0rq2DwVB0alcyc= +github.com/cpuguy83/go-md2man/v2 v2.0.5/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/crate-crypto/go-eth-kzg v1.4.0 h1:WzDGjHk4gFg6YzV0rJOAsTK4z3Qkz5jd4RE3DAvPFkg= github.com/crate-crypto/go-eth-kzg v1.4.0/go.mod h1:J9/u5sWfznSObptgfa92Jq8rTswn6ahQWEuiLHOjCUI= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/dchest/siphash v1.2.3 h1:QXwFc8cFOR2dSa/gE6o/HokBMWtLUaNDVd+22aKHeEA= +github.com/dchest/siphash v1.2.3/go.mod h1:0NvQU092bT0ipiFN++/rXm69QG9tVxLAlQHIXMPAkHc= github.com/deckarep/golang-set/v2 v2.6.0 h1:XfcQbWM1LlMB8BsJ8N9vW5ehnnPVIw0je80NsVHagjM= github.com/deckarep/golang-set/v2 v2.6.0/go.mod h1:VAky9rY/yGXJOLEDv3OMci+7wtDpOF4IN+y82NBOac4= +github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5ilcvdfma9wOH6Y= +github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 h1:8UrgZ3GkP4i/CLijOJx79Yu+etlyjdBU4sfcs2WYQMs= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/dhui/dktest v0.4.6 h1:+DPKyScKSEp3VLtbMDHcUq6V5Lm5zfZZVb0Sk7Ahom4= @@ -135,6 +157,8 @@ github.com/eapache/queue/v2 v2.0.0-20230407133247-75960ed334e4 h1:8EXxF+tCLqaVk8 github.com/eapache/queue/v2 v2.0.0-20230407133247-75960ed334e4/go.mod h1:I5sHm0Y0T1u5YjlyqC5GVArM7aNZRUYtTjmJ8mPJFds= github.com/ebitengine/purego v0.10.0 h1:QIw4xfpWT6GWTzaW5XEKy3HXoqrJGx1ijYHzTF0/ISU= github.com/ebitengine/purego v0.10.0/go.mod h1:iIjxzd6CiRiOG0UyXP+V1+jWqUXVjPKLAI0mRfJZTmQ= +github.com/emicklei/dot v1.6.2 h1:08GN+DD79cy/tzN6uLCT84+2Wk9u+wvqP+Hkx/dIR8A= +github.com/emicklei/dot v1.6.2/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= github.com/envoyproxy/go-control-plane v0.14.0 h1:hbG2kr4RuFj222B6+7T83thSPqLjwBIfQawTkC++2HA= github.com/envoyproxy/go-control-plane v0.14.0/go.mod h1:NcS5X47pLl/hfqxU70yPwL9ZMkUlwlKxtAohpi2wBEU= github.com/envoyproxy/go-control-plane/envoy v1.36.0 h1:yg/JjO5E7ubRyKX3m07GF3reDNEnfOboJ0QySbH736g= @@ -145,14 +169,20 @@ github.com/envoyproxy/protoc-gen-validate v1.3.0 h1:TvGH1wof4H33rezVKWSpqKz5NXWg github.com/envoyproxy/protoc-gen-validate v1.3.0/go.mod h1:HvYl7zwPa5mffgyeTUHA9zHIH36nmrm7oCbo4YKoSWA= github.com/ethereum/c-kzg-4844/v2 v2.1.5 h1:aVtoLK5xwJ6c5RiqO8g8ptJ5KU+2Hdquf6G3aXiHh5s= github.com/ethereum/c-kzg-4844/v2 v2.1.5/go.mod h1:u59hRTTah4Co6i9fDWtiCjTrblJv0UwsqZKCc0GfgUs= +github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab h1:rvv6MJhy07IMfEKuARQ9TKojGqLVNxQajaXEp/BoqSk= +github.com/ethereum/go-bigmodexpfix v0.0.0-20250911101455-f9e208c548ab/go.mod h1:IuLm4IsPipXKF7CW5Lzf68PIbZ5yl7FFd74l/E0o9A8= github.com/ethereum/go-ethereum v1.17.0 h1:2D+1Fe23CwZ5tQoAS5DfwKFNI1HGcTwi65/kRlAVxes= github.com/ethereum/go-ethereum v1.17.0/go.mod h1:2W3msvdosS/MCWytpqTcqgFiRYbTH59FxDJzqah120o= github.com/exaring/otelpgx v0.10.0 h1:NGGegdoBQM3jNZDKG8ENhigUcgBN7d7943L0YlcIpZc= github.com/exaring/otelpgx v0.10.0/go.mod h1:R5/M5LWsPPBZc1SrRE5e0DiU48bI78C1/GPTWs6I66U= github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/ferranbt/fastssz v0.1.4 h1:OCDB+dYDEQDvAgtAGnTSidK1Pe2tW3nFV40XyMkTeDY= +github.com/ferranbt/fastssz v0.1.4/go.mod h1:Ea3+oeoRGGLGm5shYAeDgu6PGUlcvQhE2fILyD9+tGg= github.com/fsnotify/fsnotify v1.9.0 h1:2Ml+OJNzbYCTzsxtv8vKSFD9PbJjmhYF14k/jKC7S9k= github.com/fsnotify/fsnotify v1.9.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0= +github.com/getsentry/sentry-go v0.27.0 h1:Pv98CIbtB3LkMWmXi4Joa5OOcwbmnX88sF5qbK3r3Ps= +github.com/getsentry/sentry-go v0.27.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= github.com/go-jose/go-jose/v4 v4.1.3 h1:CVLmWDhDVRa6Mi/IgCgaopNosCaHz7zrMeF9MlZRkrs= github.com/go-jose/go-jose/v4 v4.1.3/go.mod h1:x4oUasVrzR7071A4TnHLGSPpNOm2a21K9Kf04k1rs08= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= @@ -160,10 +190,15 @@ github.com/go-logr/logr v1.4.3 h1:CjnDlHq8ikf6E492q6eKboGOC0T8CDaOvkHCIg8idEI= github.com/go-logr/logr v1.4.3/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= +github.com/go-ole/go-ole v1.2.5/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= github.com/go-ole/go-ole v1.3.0 h1:Dt6ye7+vXGIKZ7Xtk4s6/xVdGDQynvom7xCFEdWr6uE= github.com/go-ole/go-ole v1.3.0/go.mod h1:5LS6F96DhAwUc7C+1HLexzMXY1xGRSryjyPPKW6zv78= github.com/go-viper/mapstructure/v2 v2.4.0 h1:EBsztssimR/CONLSZZ04E8qAkxNYq4Qp9LvH92wZUgs= github.com/go-viper/mapstructure/v2 v2.4.0/go.mod h1:oJDH3BJKyqBA2TXFhDsKDGDTlndYOZ6rGS0BRZIxGhM= +github.com/gofrs/flock v0.13.0 h1:95JolYOvGMqeH31+FC7D2+uULf6mG61mEZ/A8dRYMzw= +github.com/gofrs/flock v0.13.0/go.mod h1:jxeyy9R1auM5S6JYDBhDt+E2TCo7DkratH4Pgi8P+Z0= +github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= +github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang-jwt/jwt/v4 v4.4.1/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang-jwt/jwt/v4 v4.4.2/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang-jwt/jwt/v4 v4.5.2 h1:YtQM7lnr8iZ+j5q71MGKkNw9Mn7AjHM68uc9g5fXeUI= @@ -173,9 +208,13 @@ github.com/golang-migrate/migrate/v4 v4.19.0/go.mod h1:9dyEcu+hO+G9hPSw8AIg50yg6 github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= +github.com/golang/snappy v1.0.0 h1:Oy607GVXHs7RtbggtPBnr2RmDArIsAefDwvrdWvRhGs= +github.com/golang/snappy v1.0.0/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= +github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= +github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/martian/v3 v3.3.3 h1:DIhPTQrbPkgs2yJYdXU/eNACCG5DVQjySNRNlflZ9Fc= github.com/google/martian/v3 v3.3.3/go.mod h1:iEPrYcgCF7jA9OtScMFQyAlZZ4YXTKEtJ1E6RWzmBA0= github.com/google/s2a-go v0.1.9 h1:LGD7gtMgezd8a/Xak7mEWL0PjoTQFvpRudN895yqKW0= @@ -188,17 +227,29 @@ github.com/googleapis/gax-go/v2 v2.14.1 h1:hb0FFeiPaQskmvakKu5EbCbpntQn48jyHuvrk github.com/googleapis/gax-go/v2 v2.14.1/go.mod h1:Hb/NubMaVM88SrNkvl8X/o8XWwDJEPqouaLeN2IUxoA= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= +github.com/grafana/pyroscope-go v1.2.7 h1:VWBBlqxjyR0Cwk2W6UrE8CdcdD80GOFNutj0Kb1T8ac= +github.com/grafana/pyroscope-go v1.2.7/go.mod h1:o/bpSLiJYYP6HQtvcoVKiE9s5RiNgjYTj1DhiddP2Pc= +github.com/grafana/pyroscope-go/godeltaprof v0.1.9 h1:c1Us8i6eSmkW+Ez05d3co8kasnuOY813tbMN8i/a3Og= +github.com/grafana/pyroscope-go/godeltaprof v0.1.9/go.mod h1:2+l7K7twW49Ct4wFluZD3tZ6e0SjanjcUUBPVD/UuGU= github.com/grpc-ecosystem/grpc-gateway/v2 v2.28.0 h1:HWRh5R2+9EifMyIHV7ZV+MIZqgz+PMpZ14Jynv3O2Zs= github.com/grpc-ecosystem/grpc-gateway/v2 v2.28.0/go.mod h1:JfhWUomR1baixubs02l85lZYYOm7LV6om4ceouMv45c= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY2I= github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= +github.com/hashicorp/go-bexpr v0.1.10 h1:9kuI5PFotCboP3dkDYFr/wi0gg0QVbSNz5oFRpxn4uE= +github.com/hashicorp/go-bexpr v0.1.10/go.mod h1:oxlubA2vC/gFVfX1A6JGp7ls7uCDlfJn732ehYYg+g0= github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo= github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= github.com/hashicorp/go-version v1.8.0 h1:KAkNb1HAiZd1ukkxDFGmokVZe1Xy9HG6NUp+bPle2i4= github.com/hashicorp/go-version v1.8.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= +github.com/holiman/billy v0.0.0-20250707135307-f2f9b9aae7db h1:IZUYC/xb3giYwBLMnr8d0TGTzPKFGNTCGgGLoyeX330= +github.com/holiman/billy v0.0.0-20250707135307-f2f9b9aae7db/go.mod h1:xTEYN9KCHxuYHs+NmrmzFcnvHMzLLNiGFafCb1n3Mfg= +github.com/holiman/bloomfilter/v2 v2.0.3 h1:73e0e/V0tCydx14a0SCYS/EWCxgwLZ18CZcZKVu0fao= +github.com/holiman/bloomfilter/v2 v2.0.3/go.mod h1:zpoh+gs7qcpqrHr3dB55AMiJwo0iURXE7ZOP9L9hSkA= github.com/holiman/uint256 v1.3.2 h1:a9EgMPSC1AAaj1SZL5zIQD3WbwTuHrMGOerLjGmM/TA= github.com/holiman/uint256 v1.3.2/go.mod h1:EOMSn4q6Nyt9P6efbI3bueV4e1b3dGlUCXeiRV4ng7E= +github.com/huin/goupnp v1.3.0 h1:UvLUlWDNpoUdYzb2TCn+MuTWtcjXKSza2n6CBdQ0xXc= +github.com/huin/goupnp v1.3.0/go.mod h1:gnGPsThkYa7bFi/KWmEysQRf48l2dvR5bxr2OFckNX8= github.com/jackc/pgpassfile v1.0.0 h1:/6Hmqy13Ss2zCq62VdNG8tM1wchn8zjSGOBJ6icpsIM= github.com/jackc/pgpassfile v1.0.0/go.mod h1:CEx0iS5ambNFdcRtxPj5JhEz+xB6uRky5eyVu/W2HEg= github.com/jackc/pgservicefile v0.0.0-20240606120523-5a60cdf6a761 h1:iCEnooe7UlwOQYpKFhBabPMi4aNAfoODPEFNiAnClxo= @@ -207,18 +258,38 @@ github.com/jackc/pgx/v5 v5.9.1 h1:uwrxJXBnx76nyISkhr33kQLlUqjv7et7b9FjCen/tdc= github.com/jackc/pgx/v5 v5.9.1/go.mod h1:mal1tBGAFfLHvZzaYh77YS/eC6IX9OWbRV1QIIM0Jn4= github.com/jackc/puddle/v2 v2.2.2 h1:PR8nw+E/1w0GLuRFSmiioY6UooMp6KJv0/61nB7icHo= github.com/jackc/puddle/v2 v2.2.2/go.mod h1:vriiEXHvEE654aYKXXjOvZM39qJ0q+azkZFrfEOc3H4= +github.com/jackpal/go-nat-pmp v1.0.2 h1:KzKSgb7qkJvOUTqYl9/Hg/me3pWgBmERKrTGD7BdWus= +github.com/jackpal/go-nat-pmp v1.0.2/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc= github.com/jessevdk/go-flags v1.6.1 h1:Cvu5U8UGrLay1rZfv/zP7iLpSHGUZ/Ou68T0iX1bBK4= github.com/jessevdk/go-flags v1.6.1/go.mod h1:Mk8T1hIAWpOiJiHa9rJASDK2UGWji0EuPGBnNLMooyc= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= +github.com/klauspost/compress v1.18.2 h1:iiPHWW0YrcFgpBYhsA6D1+fqHssJscY/Tm/y2Uqnapk= +github.com/klauspost/compress v1.18.2/go.mod h1:R0h/fSBs8DE4ENlcrlib3PsXS61voFxhIs2DeRhCvJ4= +github.com/klauspost/cpuid/v2 v2.2.5 h1:0E5MSMDEoAulmXNFquVs//DdoomxaoTY1kUhbc/qbZg= +github.com/klauspost/cpuid/v2 v2.2.5/go.mod h1:Lcz8mBdAVJIBVzewtcLocK12l3Y+JytZYpaMropDUws= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= +github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= +github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= +github.com/leanovate/gopter v0.2.11 h1:vRjThO1EKPb/1NsDXuDrzldR28RLkBflWYcU9CvzWu4= +github.com/leanovate/gopter v0.2.11/go.mod h1:aK3tzZP/C+p1m3SPRE4SYZFGP7jjkuSI4f7Xvpt0S9c= github.com/lib/pq v1.12.0 h1:mC1zeiNamwKBecjHarAr26c/+d8V5w/u4J0I/yASbJo= github.com/lib/pq v1.12.0/go.mod h1:/p+8NSbOcwzAEI7wiMXFlgydTwcgTr3OSKMsD2BitpA= github.com/lufia/plan9stats v0.0.0-20251013123823-9fd1530e3ec3 h1:PwQumkgq4/acIiZhtifTV5OUqqiP82UAl0h87xj/l9k= github.com/lufia/plan9stats v0.0.0-20251013123823-9fd1530e3ec3/go.mod h1:autxFIvghDt3jPTLoqZ9OZ7s9qTGNAWmYCjVFWPX/zg= +github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= +github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= +github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= +github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= +github.com/minio/sha256-simd v1.0.0 h1:v1ta+49hkWZyvaKwrQB8elexRqm6Y0aMLjCNsrYxo6g= +github.com/minio/sha256-simd v1.0.0/go.mod h1:OuYzVNI5vcoYIAmbIvHPl3N3jUzVedXbKy5RFepssQM= +github.com/mitchellh/mapstructure v1.5.1-0.20231216201459-8508981c8b6c h1:cqn374mizHuIWj+OSJCajGr/phAmuMug9qIX3l9CflE= +github.com/mitchellh/mapstructure v1.5.1-0.20231216201459-8508981c8b6c/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/mitchellh/pointerstructure v1.2.0 h1:O+i9nHnXS3l/9Wu7r4NrEdwA2VFTicjUEN1uBnDo34A= +github.com/mitchellh/pointerstructure v1.2.0/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8ohIXc3tViBH44KcwB2g4= github.com/moby/docker-image-spec v1.3.1 h1:jMKff3w6PgbfSa69GfNg+zN/XLhfXJGnEx3Nl2EsFP0= github.com/moby/docker-image-spec v1.3.1/go.mod h1:eKmb5VW8vQEh/BAr2yvVNvuiJuY6UIocYsFu/DxxRpo= github.com/moby/term v0.5.2 h1:6qk3FJAFDs6i/q3W/pQ97SX192qKfZgGjCQqfCJkgzQ= @@ -239,6 +310,16 @@ github.com/outcaste-io/ristretto v0.2.3 h1:AK4zt/fJ76kjlYObOeNwh4T3asEuaCmp26pOv github.com/outcaste-io/ristretto v0.2.3/go.mod h1:W8HywhmtlopSB1jeMg3JtdIhf+DYkLAr0VN/s4+MHac= github.com/philhofer/fwd v1.2.0 h1:e6DnBTl7vGY+Gz322/ASL4Gyp1FspeMvx1RNDoToZuM= github.com/philhofer/fwd v1.2.0/go.mod h1:RqIHx9QI14HlwKwm98g9Re5prTQ6LdeRQn+gXJFxsJM= +github.com/pion/dtls/v2 v2.2.7 h1:cSUBsETxepsCSFSxC3mc/aDo14qQLMSL+O6IjG28yV8= +github.com/pion/dtls/v2 v2.2.7/go.mod h1:8WiMkebSHFD0T+dIU+UeBaoV7kDhOW5oDCzZ7WZ/F9s= +github.com/pion/logging v0.2.2 h1:M9+AIj/+pxNsDfAT64+MAVgJO0rsyLnoJKCqf//DoeY= +github.com/pion/logging v0.2.2/go.mod h1:k0/tDVsRCX2Mb2ZEmTqNa7CWsQPc+YYCB7Q+5pahoms= +github.com/pion/stun/v2 v2.0.0 h1:A5+wXKLAypxQri59+tmQKVs7+l6mMM+3d+eER9ifRU0= +github.com/pion/stun/v2 v2.0.0/go.mod h1:22qRSh08fSEttYUmJZGlriq9+03jtVmXNODgLccj8GQ= +github.com/pion/transport/v2 v2.2.1 h1:7qYnCBlpgSJNYMbLCKuSY9KbQdBFoETvPNETv0y4N7c= +github.com/pion/transport/v2 v2.2.1/go.mod h1:cXXWavvCnFF6McHTft3DWS9iic2Mftcz1Aq29pGcU5g= +github.com/pion/transport/v3 v3.0.1 h1:gDTlPJwROfSfz6QfSi0ZmeCSkFcnWWiiR9ES0ouANiM= +github.com/pion/transport/v3 v3.0.1/go.mod h1:UY7kiITrlMv7/IKgd5eTUcaahZx5oUN3l9SzK5f5xE0= github.com/pires/go-proxyproto v0.11.0 h1:gUQpS85X/VJMdUsYyEgyn59uLJvGqPhJV5YvG68wXH4= github.com/pires/go-proxyproto v0.11.0/go.mod h1:ZKAAyp3cgy5Y5Mo4n9AlScrkCZwUy0g3Jf+slqQVcuU= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= @@ -264,6 +345,10 @@ github.com/puzpuzpuz/xsync/v3 v3.5.1 h1:GJYJZwO6IdxN/IKbneznS6yPkVC+c3zyY/j19c++ github.com/puzpuzpuz/xsync/v3 v3.5.1/go.mod h1:VjzYrABPabuM4KyBh1Ftq6u8nhwY5tBPKP9jpmh0nnA= github.com/rogpeppe/go-internal v1.14.1 h1:UQB4HGPB6osV0SQTLymcB4TgvyWu6ZyliaW0tI/otEQ= github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7so1lCWt35ZSgc= +github.com/rs/cors v1.11.1 h1:eU3gRzXLRK57F5rKMGMZURNdIG4EoAmX8k94r9wXWHA= +github.com/rs/cors v1.11.1/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= +github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= +github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/secure-systems-lab/go-securesystemslib v0.9.0 h1:rf1HIbL64nUpEIZnjLZ3mcNEL9NBPB0iuVjyxvq3LZc= github.com/secure-systems-lab/go-securesystemslib v0.9.0/go.mod h1:DVHKMcZ+V4/woA/peqr+L0joiRXbPpQ042GgJckkFgw= github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible h1:Bn1aCHHRnjv4Bl16T8rcaFjYSrGrIZvpiGO6P3Q4GpU= @@ -284,14 +369,20 @@ github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U= github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe h1:nbdqkIGOGfUAD54q1s2YBcBz/WcsxCO9HUQ4aGV5hUw= github.com/supranational/blst v0.3.16-0.20250831170142-f48500c1fdbe/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= +github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= +github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/tinylib/msgp v1.6.3 h1:bCSxiTz386UTgyT1i0MSCvdbWjVW+8sG3PjkGsZQt4s= github.com/tinylib/msgp v1.6.3/go.mod h1:RSp0LW9oSxFut3KzESt5Voq4GVWyS+PSulT77roAqEA= github.com/tklauser/go-sysconf v0.3.16 h1:frioLaCQSsF5Cy1jgRBrzr6t502KIIwQ0MArYICU0nA= github.com/tklauser/go-sysconf v0.3.16/go.mod h1:/qNL9xxDhc7tx3HSRsLWNnuzbVfh3e7gh/BmM179nYI= github.com/tklauser/numcpus v0.11.0 h1:nSTwhKH5e1dMNsCdVBukSZrURJRoHbSEQjdEbY+9RXw= github.com/tklauser/numcpus v0.11.0/go.mod h1:z+LwcLq54uWZTX0u/bGobaV34u6V7KNlTZejzM6/3MQ= -github.com/xmtp/xmtpd v1.3.0 h1:yeiwbgB+y77y+q1+xqwH46SAYr1FXX2puTVldSGTBKc= -github.com/xmtp/xmtpd v1.3.0/go.mod h1:e4SHxnHr9v58tL4mdez6UzVSbi250YXF9Pu0tY+l3PU= +github.com/urfave/cli/v2 v2.27.5 h1:WoHEJLdsXr6dDWoJgMq/CboDmyY/8HMMH1fTECbih+w= +github.com/urfave/cli/v2 v2.27.5/go.mod h1:3Sevf16NykTbInEnD0yKkjDAeZDS0A6bzhBH5hrMvTQ= +github.com/xmtp/xmtpd v1.3.1-0.20260402033823-6ae509c61de3 h1:eLNLc2iDqnosgm7gdkucxXjpq7hMoG4S69WIWJ60wNM= +github.com/xmtp/xmtpd v1.3.1-0.20260402033823-6ae509c61de3/go.mod h1:e4SHxnHr9v58tL4mdez6UzVSbi250YXF9Pu0tY+l3PU= +github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 h1:gEOO8jv9F4OT7lGCjxCBTO/36wtF6j2nSip77qHd4x4= +github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1/go.mod h1:Ohn+xnUBiLI6FVj/9LpzZWtj1/D6lUovWYBkxHVV3aM= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.4 h1:zFUKzehAFReQwLys1b/iSMl+JQGSCSjtVqQn9bBrPo0= github.com/yusufpapurcu/wmi v1.2.4/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= @@ -358,11 +449,13 @@ golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.20.0 h1:e0PTpb7pjO8GAtTs2dQ6jYa5BWYlMuX047Dco/pItO4= golang.org/x/sync v0.20.0/go.mod h1:9xrNwdLfx4jkKbNva9FpL6vEN7evnE43NNNJQ2LF3+0= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.42.0 h1:omrd2nAlyT5ESRdCLYdm3+fMfNFE/+Rf4bDIQImRJeo= golang.org/x/sys v0.42.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= @@ -408,7 +501,11 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntN gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= +gopkg.in/natefinch/lumberjack.v2 v2.2.1 h1:bBRl1b0OH9s/DuPhuXpNl+VtCaJXFZ5/uEFST95x9zc= +gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYskCTPBJVb9jqSc= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= +gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/pkg/delivery/apns_test.go b/pkg/delivery/apns_test.go index 112be501..1bd5c5cf 100644 --- a/pkg/delivery/apns_test.go +++ b/pkg/delivery/apns_test.go @@ -8,7 +8,7 @@ import ( "github.com/stretchr/testify/require" "github.com/xmtp/example-notification-server-go/pkg/interfaces" "github.com/xmtp/example-notification-server-go/pkg/options" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + v1 "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" "github.com/xmtp/example-notification-server-go/pkg/topics" ) diff --git a/pkg/delivery/fcm_test.go b/pkg/delivery/fcm_test.go index 8713c978..29441005 100644 --- a/pkg/delivery/fcm_test.go +++ b/pkg/delivery/fcm_test.go @@ -6,7 +6,7 @@ import ( "github.com/stretchr/testify/require" "github.com/xmtp/example-notification-server-go/pkg/interfaces" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + v1 "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" "github.com/xmtp/example-notification-server-go/pkg/topics" ) diff --git a/pkg/interfaces/interfaces.go b/pkg/interfaces/interfaces.go index eb073ab9..db71d6ae 100644 --- a/pkg/interfaces/interfaces.go +++ b/pkg/interfaces/interfaces.go @@ -6,7 +6,7 @@ import ( "crypto/sha256" "time" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + v1 "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" "github.com/xmtp/example-notification-server-go/pkg/topics" "github.com/xmtp/xmtpd/pkg/topic" ) diff --git a/pkg/proto/device_sync/consent_backup.pb.go b/pkg/proto/device_sync/consent_backup.pb.go deleted file mode 100644 index 6fa6810f..00000000 --- a/pkg/proto/device_sync/consent_backup.pb.go +++ /dev/null @@ -1,277 +0,0 @@ -// Definitions for backups - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: device_sync/consent_backup.proto - -package device_sync - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Consent record type -type ConsentTypeSave int32 - -const ( - ConsentTypeSave_CONSENT_TYPE_SAVE_UNSPECIFIED ConsentTypeSave = 0 - ConsentTypeSave_CONSENT_TYPE_SAVE_CONVERSATION_ID ConsentTypeSave = 1 - ConsentTypeSave_CONSENT_TYPE_SAVE_INBOX_ID ConsentTypeSave = 2 - // Deprecated: Marked as deprecated in device_sync/consent_backup.proto. - ConsentTypeSave_CONSENT_TYPE_SAVE_ADDRESS ConsentTypeSave = 3 -) - -// Enum value maps for ConsentTypeSave. -var ( - ConsentTypeSave_name = map[int32]string{ - 0: "CONSENT_TYPE_SAVE_UNSPECIFIED", - 1: "CONSENT_TYPE_SAVE_CONVERSATION_ID", - 2: "CONSENT_TYPE_SAVE_INBOX_ID", - 3: "CONSENT_TYPE_SAVE_ADDRESS", - } - ConsentTypeSave_value = map[string]int32{ - "CONSENT_TYPE_SAVE_UNSPECIFIED": 0, - "CONSENT_TYPE_SAVE_CONVERSATION_ID": 1, - "CONSENT_TYPE_SAVE_INBOX_ID": 2, - "CONSENT_TYPE_SAVE_ADDRESS": 3, - } -) - -func (x ConsentTypeSave) Enum() *ConsentTypeSave { - p := new(ConsentTypeSave) - *p = x - return p -} - -func (x ConsentTypeSave) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ConsentTypeSave) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_consent_backup_proto_enumTypes[0].Descriptor() -} - -func (ConsentTypeSave) Type() protoreflect.EnumType { - return &file_device_sync_consent_backup_proto_enumTypes[0] -} - -func (x ConsentTypeSave) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ConsentTypeSave.Descriptor instead. -func (ConsentTypeSave) EnumDescriptor() ([]byte, []int) { - return file_device_sync_consent_backup_proto_rawDescGZIP(), []int{0} -} - -// Consent record state -type ConsentStateSave int32 - -const ( - ConsentStateSave_CONSENT_STATE_SAVE_UNSPECIFIED ConsentStateSave = 0 - ConsentStateSave_CONSENT_STATE_SAVE_UNKNOWN ConsentStateSave = 1 - ConsentStateSave_CONSENT_STATE_SAVE_ALLOWED ConsentStateSave = 2 - ConsentStateSave_CONSENT_STATE_SAVE_DENIED ConsentStateSave = 3 -) - -// Enum value maps for ConsentStateSave. -var ( - ConsentStateSave_name = map[int32]string{ - 0: "CONSENT_STATE_SAVE_UNSPECIFIED", - 1: "CONSENT_STATE_SAVE_UNKNOWN", - 2: "CONSENT_STATE_SAVE_ALLOWED", - 3: "CONSENT_STATE_SAVE_DENIED", - } - ConsentStateSave_value = map[string]int32{ - "CONSENT_STATE_SAVE_UNSPECIFIED": 0, - "CONSENT_STATE_SAVE_UNKNOWN": 1, - "CONSENT_STATE_SAVE_ALLOWED": 2, - "CONSENT_STATE_SAVE_DENIED": 3, - } -) - -func (x ConsentStateSave) Enum() *ConsentStateSave { - p := new(ConsentStateSave) - *p = x - return p -} - -func (x ConsentStateSave) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ConsentStateSave) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_consent_backup_proto_enumTypes[1].Descriptor() -} - -func (ConsentStateSave) Type() protoreflect.EnumType { - return &file_device_sync_consent_backup_proto_enumTypes[1] -} - -func (x ConsentStateSave) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ConsentStateSave.Descriptor instead. -func (ConsentStateSave) EnumDescriptor() ([]byte, []int) { - return file_device_sync_consent_backup_proto_rawDescGZIP(), []int{1} -} - -// Proto representation of a consent record save -type ConsentSave struct { - state protoimpl.MessageState `protogen:"open.v1"` - EntityType ConsentTypeSave `protobuf:"varint,1,opt,name=entity_type,json=entityType,proto3,enum=xmtp.device_sync.consent_backup.ConsentTypeSave" json:"entity_type,omitempty"` - State ConsentStateSave `protobuf:"varint,2,opt,name=state,proto3,enum=xmtp.device_sync.consent_backup.ConsentStateSave" json:"state,omitempty"` - Entity string `protobuf:"bytes,3,opt,name=entity,proto3" json:"entity,omitempty"` - ConsentedAtNs int64 `protobuf:"varint,4,opt,name=consented_at_ns,json=consentedAtNs,proto3" json:"consented_at_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ConsentSave) Reset() { - *x = ConsentSave{} - mi := &file_device_sync_consent_backup_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ConsentSave) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ConsentSave) ProtoMessage() {} - -func (x *ConsentSave) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_consent_backup_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ConsentSave.ProtoReflect.Descriptor instead. -func (*ConsentSave) Descriptor() ([]byte, []int) { - return file_device_sync_consent_backup_proto_rawDescGZIP(), []int{0} -} - -func (x *ConsentSave) GetEntityType() ConsentTypeSave { - if x != nil { - return x.EntityType - } - return ConsentTypeSave_CONSENT_TYPE_SAVE_UNSPECIFIED -} - -func (x *ConsentSave) GetState() ConsentStateSave { - if x != nil { - return x.State - } - return ConsentStateSave_CONSENT_STATE_SAVE_UNSPECIFIED -} - -func (x *ConsentSave) GetEntity() string { - if x != nil { - return x.Entity - } - return "" -} - -func (x *ConsentSave) GetConsentedAtNs() int64 { - if x != nil { - return x.ConsentedAtNs - } - return 0 -} - -var File_device_sync_consent_backup_proto protoreflect.FileDescriptor - -const file_device_sync_consent_backup_proto_rawDesc = "" + - "\n" + - " device_sync/consent_backup.proto\x12\x1fxmtp.device_sync.consent_backup\"\xe9\x01\n" + - "\vConsentSave\x12Q\n" + - "\ventity_type\x18\x01 \x01(\x0e20.xmtp.device_sync.consent_backup.ConsentTypeSaveR\n" + - "entityType\x12G\n" + - "\x05state\x18\x02 \x01(\x0e21.xmtp.device_sync.consent_backup.ConsentStateSaveR\x05state\x12\x16\n" + - "\x06entity\x18\x03 \x01(\tR\x06entity\x12&\n" + - "\x0fconsented_at_ns\x18\x04 \x01(\x03R\rconsentedAtNs*\x9e\x01\n" + - "\x0fConsentTypeSave\x12!\n" + - "\x1dCONSENT_TYPE_SAVE_UNSPECIFIED\x10\x00\x12%\n" + - "!CONSENT_TYPE_SAVE_CONVERSATION_ID\x10\x01\x12\x1e\n" + - "\x1aCONSENT_TYPE_SAVE_INBOX_ID\x10\x02\x12!\n" + - "\x19CONSENT_TYPE_SAVE_ADDRESS\x10\x03\x1a\x02\b\x01*\x95\x01\n" + - "\x10ConsentStateSave\x12\"\n" + - "\x1eCONSENT_STATE_SAVE_UNSPECIFIED\x10\x00\x12\x1e\n" + - "\x1aCONSENT_STATE_SAVE_UNKNOWN\x10\x01\x12\x1e\n" + - "\x1aCONSENT_STATE_SAVE_ALLOWED\x10\x02\x12\x1d\n" + - "\x19CONSENT_STATE_SAVE_DENIED\x10\x03B\xaf\x02\n" + - "=org.xmtp.android.library.push.xmtp.device_sync.consent_backupB\x12ConsentBackupProtoP\x01ZDgithub.com/xmtp/example-notification-server-go/pkg/proto/device_sync\xa2\x02\x03XDC\xaa\x02\x1dXmtp.DeviceSync.ConsentBackup\xca\x02\x1dXmtp\\DeviceSync\\ConsentBackup\xe2\x02)Xmtp\\DeviceSync\\ConsentBackup\\GPBMetadata\xea\x02\x1fXmtp::DeviceSync::ConsentBackupb\x06proto3" - -var ( - file_device_sync_consent_backup_proto_rawDescOnce sync.Once - file_device_sync_consent_backup_proto_rawDescData []byte -) - -func file_device_sync_consent_backup_proto_rawDescGZIP() []byte { - file_device_sync_consent_backup_proto_rawDescOnce.Do(func() { - file_device_sync_consent_backup_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_device_sync_consent_backup_proto_rawDesc), len(file_device_sync_consent_backup_proto_rawDesc))) - }) - return file_device_sync_consent_backup_proto_rawDescData -} - -var file_device_sync_consent_backup_proto_enumTypes = make([]protoimpl.EnumInfo, 2) -var file_device_sync_consent_backup_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_device_sync_consent_backup_proto_goTypes = []any{ - (ConsentTypeSave)(0), // 0: xmtp.device_sync.consent_backup.ConsentTypeSave - (ConsentStateSave)(0), // 1: xmtp.device_sync.consent_backup.ConsentStateSave - (*ConsentSave)(nil), // 2: xmtp.device_sync.consent_backup.ConsentSave -} -var file_device_sync_consent_backup_proto_depIdxs = []int32{ - 0, // 0: xmtp.device_sync.consent_backup.ConsentSave.entity_type:type_name -> xmtp.device_sync.consent_backup.ConsentTypeSave - 1, // 1: xmtp.device_sync.consent_backup.ConsentSave.state:type_name -> xmtp.device_sync.consent_backup.ConsentStateSave - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_device_sync_consent_backup_proto_init() } -func file_device_sync_consent_backup_proto_init() { - if File_device_sync_consent_backup_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_device_sync_consent_backup_proto_rawDesc), len(file_device_sync_consent_backup_proto_rawDesc)), - NumEnums: 2, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_device_sync_consent_backup_proto_goTypes, - DependencyIndexes: file_device_sync_consent_backup_proto_depIdxs, - EnumInfos: file_device_sync_consent_backup_proto_enumTypes, - MessageInfos: file_device_sync_consent_backup_proto_msgTypes, - }.Build() - File_device_sync_consent_backup_proto = out.File - file_device_sync_consent_backup_proto_goTypes = nil - file_device_sync_consent_backup_proto_depIdxs = nil -} diff --git a/pkg/proto/device_sync/content.pb.go b/pkg/proto/device_sync/content.pb.go deleted file mode 100644 index f00b585e..00000000 --- a/pkg/proto/device_sync/content.pb.go +++ /dev/null @@ -1,776 +0,0 @@ -// Sync group messages - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: device_sync/content.proto - -package device_sync - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// All potential device sync group messages -type DeviceSyncContent struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Content: - // - // *DeviceSyncContent_Request - // *DeviceSyncContent_Acknowledge - // *DeviceSyncContent_Reply - // *DeviceSyncContent_PreferenceUpdates - Content isDeviceSyncContent_Content `protobuf_oneof:"content"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DeviceSyncContent) Reset() { - *x = DeviceSyncContent{} - mi := &file_device_sync_content_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DeviceSyncContent) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DeviceSyncContent) ProtoMessage() {} - -func (x *DeviceSyncContent) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DeviceSyncContent.ProtoReflect.Descriptor instead. -func (*DeviceSyncContent) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{0} -} - -func (x *DeviceSyncContent) GetContent() isDeviceSyncContent_Content { - if x != nil { - return x.Content - } - return nil -} - -func (x *DeviceSyncContent) GetRequest() *DeviceSyncRequest { - if x != nil { - if x, ok := x.Content.(*DeviceSyncContent_Request); ok { - return x.Request - } - } - return nil -} - -func (x *DeviceSyncContent) GetAcknowledge() *DeviceSyncAcknowledge { - if x != nil { - if x, ok := x.Content.(*DeviceSyncContent_Acknowledge); ok { - return x.Acknowledge - } - } - return nil -} - -func (x *DeviceSyncContent) GetReply() *DeviceSyncReply { - if x != nil { - if x, ok := x.Content.(*DeviceSyncContent_Reply); ok { - return x.Reply - } - } - return nil -} - -func (x *DeviceSyncContent) GetPreferenceUpdates() *PreferenceUpdates { - if x != nil { - if x, ok := x.Content.(*DeviceSyncContent_PreferenceUpdates); ok { - return x.PreferenceUpdates - } - } - return nil -} - -type isDeviceSyncContent_Content interface { - isDeviceSyncContent_Content() -} - -type DeviceSyncContent_Request struct { - Request *DeviceSyncRequest `protobuf:"bytes,1,opt,name=request,proto3,oneof"` -} - -type DeviceSyncContent_Acknowledge struct { - Acknowledge *DeviceSyncAcknowledge `protobuf:"bytes,2,opt,name=acknowledge,proto3,oneof"` -} - -type DeviceSyncContent_Reply struct { - Reply *DeviceSyncReply `protobuf:"bytes,3,opt,name=reply,proto3,oneof"` -} - -type DeviceSyncContent_PreferenceUpdates struct { - PreferenceUpdates *PreferenceUpdates `protobuf:"bytes,4,opt,name=preference_updates,json=preferenceUpdates,proto3,oneof"` -} - -func (*DeviceSyncContent_Request) isDeviceSyncContent_Content() {} - -func (*DeviceSyncContent_Acknowledge) isDeviceSyncContent_Content() {} - -func (*DeviceSyncContent_Reply) isDeviceSyncContent_Content() {} - -func (*DeviceSyncContent_PreferenceUpdates) isDeviceSyncContent_Content() {} - -// Acknowledges a request -type DeviceSyncAcknowledge struct { - state protoimpl.MessageState `protogen:"open.v1"` - RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DeviceSyncAcknowledge) Reset() { - *x = DeviceSyncAcknowledge{} - mi := &file_device_sync_content_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DeviceSyncAcknowledge) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DeviceSyncAcknowledge) ProtoMessage() {} - -func (x *DeviceSyncAcknowledge) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DeviceSyncAcknowledge.ProtoReflect.Descriptor instead. -func (*DeviceSyncAcknowledge) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{1} -} - -func (x *DeviceSyncAcknowledge) GetRequestId() string { - if x != nil { - return x.RequestId - } - return "" -} - -// Preference updates -type PreferenceUpdates struct { - state protoimpl.MessageState `protogen:"open.v1"` - Updates []*PreferenceUpdate `protobuf:"bytes,1,rep,name=updates,proto3" json:"updates,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PreferenceUpdates) Reset() { - *x = PreferenceUpdates{} - mi := &file_device_sync_content_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PreferenceUpdates) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PreferenceUpdates) ProtoMessage() {} - -func (x *PreferenceUpdates) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PreferenceUpdates.ProtoReflect.Descriptor instead. -func (*PreferenceUpdates) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{2} -} - -func (x *PreferenceUpdates) GetUpdates() []*PreferenceUpdate { - if x != nil { - return x.Updates - } - return nil -} - -// Preference update -type PreferenceUpdate struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Update: - // - // *PreferenceUpdate_Consent - // *PreferenceUpdate_Hmac - Update isPreferenceUpdate_Update `protobuf_oneof:"update"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PreferenceUpdate) Reset() { - *x = PreferenceUpdate{} - mi := &file_device_sync_content_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PreferenceUpdate) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PreferenceUpdate) ProtoMessage() {} - -func (x *PreferenceUpdate) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PreferenceUpdate.ProtoReflect.Descriptor instead. -func (*PreferenceUpdate) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{3} -} - -func (x *PreferenceUpdate) GetUpdate() isPreferenceUpdate_Update { - if x != nil { - return x.Update - } - return nil -} - -func (x *PreferenceUpdate) GetConsent() *ConsentSave { - if x != nil { - if x, ok := x.Update.(*PreferenceUpdate_Consent); ok { - return x.Consent - } - } - return nil -} - -func (x *PreferenceUpdate) GetHmac() *HmacKeyUpdate { - if x != nil { - if x, ok := x.Update.(*PreferenceUpdate_Hmac); ok { - return x.Hmac - } - } - return nil -} - -type isPreferenceUpdate_Update interface { - isPreferenceUpdate_Update() -} - -type PreferenceUpdate_Consent struct { - Consent *ConsentSave `protobuf:"bytes,1,opt,name=consent,proto3,oneof"` -} - -type PreferenceUpdate_Hmac struct { - Hmac *HmacKeyUpdate `protobuf:"bytes,2,opt,name=hmac,proto3,oneof"` -} - -func (*PreferenceUpdate_Consent) isPreferenceUpdate_Update() {} - -func (*PreferenceUpdate_Hmac) isPreferenceUpdate_Update() {} - -type V1UserPreferenceUpdate struct { - state protoimpl.MessageState `protogen:"open.v1"` - Contents [][]byte `protobuf:"bytes,1,rep,name=contents,proto3" json:"contents,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *V1UserPreferenceUpdate) Reset() { - *x = V1UserPreferenceUpdate{} - mi := &file_device_sync_content_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *V1UserPreferenceUpdate) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*V1UserPreferenceUpdate) ProtoMessage() {} - -func (x *V1UserPreferenceUpdate) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use V1UserPreferenceUpdate.ProtoReflect.Descriptor instead. -func (*V1UserPreferenceUpdate) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{4} -} - -func (x *V1UserPreferenceUpdate) GetContents() [][]byte { - if x != nil { - return x.Contents - } - return nil -} - -// Hmac key update -type HmacKeyUpdate struct { - state protoimpl.MessageState `protogen:"open.v1"` - Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` - CycledAtNs int64 `protobuf:"varint,2,opt,name=cycled_at_ns,json=cycledAtNs,proto3" json:"cycled_at_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *HmacKeyUpdate) Reset() { - *x = HmacKeyUpdate{} - mi := &file_device_sync_content_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *HmacKeyUpdate) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*HmacKeyUpdate) ProtoMessage() {} - -func (x *HmacKeyUpdate) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use HmacKeyUpdate.ProtoReflect.Descriptor instead. -func (*HmacKeyUpdate) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{5} -} - -func (x *HmacKeyUpdate) GetKey() []byte { - if x != nil { - return x.Key - } - return nil -} - -func (x *HmacKeyUpdate) GetCycledAtNs() int64 { - if x != nil { - return x.CycledAtNs - } - return 0 -} - -// Initiator or new installation id requesting a sync payload send a request -type DeviceSyncRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Pin string `protobuf:"bytes,1,opt,name=pin,proto3" json:"pin,omitempty"` - ServerUrl string `protobuf:"bytes,2,opt,name=server_url,json=serverUrl,proto3" json:"server_url,omitempty"` - // Deprecated: Marked as deprecated in device_sync/content.proto. - DeprecatedKind BackupElementSelection `protobuf:"varint,3,opt,name=deprecated_kind,json=deprecatedKind,proto3,enum=xmtp.device_sync.BackupElementSelection" json:"deprecated_kind,omitempty"` - Options *ArchiveOptions `protobuf:"bytes,4,opt,name=options,proto3" json:"options,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DeviceSyncRequest) Reset() { - *x = DeviceSyncRequest{} - mi := &file_device_sync_content_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DeviceSyncRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DeviceSyncRequest) ProtoMessage() {} - -func (x *DeviceSyncRequest) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DeviceSyncRequest.ProtoReflect.Descriptor instead. -func (*DeviceSyncRequest) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{6} -} - -func (x *DeviceSyncRequest) GetPin() string { - if x != nil { - return x.Pin - } - return "" -} - -func (x *DeviceSyncRequest) GetServerUrl() string { - if x != nil { - return x.ServerUrl - } - return "" -} - -// Deprecated: Marked as deprecated in device_sync/content.proto. -func (x *DeviceSyncRequest) GetDeprecatedKind() BackupElementSelection { - if x != nil { - return x.DeprecatedKind - } - return BackupElementSelection_BACKUP_ELEMENT_SELECTION_UNSPECIFIED -} - -func (x *DeviceSyncRequest) GetOptions() *ArchiveOptions { - if x != nil { - return x.Options - } - return nil -} - -// Pre-existing installation id capable of supplying a sync payload sends this reply -type DeviceSyncReply struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Must match an existing request_id from a message history request - RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` - // Where the messages can be retrieved from - Url string `protobuf:"bytes,2,opt,name=url,proto3" json:"url,omitempty"` - // Encryption key - EncryptionKey *DeviceSyncKeyType `protobuf:"bytes,3,opt,name=encryption_key,json=encryptionKey,proto3" json:"encryption_key,omitempty"` - // ns unix timestamp of when the reply was sent - // - // Deprecated: Marked as deprecated in device_sync/content.proto. - TimestampNs uint64 `protobuf:"varint,4,opt,name=timestamp_ns,json=timestampNs,proto3" json:"timestamp_ns,omitempty"` - // request kind - // - // Deprecated: Marked as deprecated in device_sync/content.proto. - Kind BackupElementSelection `protobuf:"varint,5,opt,name=kind,proto3,enum=xmtp.device_sync.BackupElementSelection" json:"kind,omitempty"` - // Metadata about the backup - Metadata *BackupMetadataSave `protobuf:"bytes,6,opt,name=metadata,proto3" json:"metadata,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DeviceSyncReply) Reset() { - *x = DeviceSyncReply{} - mi := &file_device_sync_content_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DeviceSyncReply) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DeviceSyncReply) ProtoMessage() {} - -func (x *DeviceSyncReply) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DeviceSyncReply.ProtoReflect.Descriptor instead. -func (*DeviceSyncReply) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{7} -} - -func (x *DeviceSyncReply) GetRequestId() string { - if x != nil { - return x.RequestId - } - return "" -} - -func (x *DeviceSyncReply) GetUrl() string { - if x != nil { - return x.Url - } - return "" -} - -func (x *DeviceSyncReply) GetEncryptionKey() *DeviceSyncKeyType { - if x != nil { - return x.EncryptionKey - } - return nil -} - -// Deprecated: Marked as deprecated in device_sync/content.proto. -func (x *DeviceSyncReply) GetTimestampNs() uint64 { - if x != nil { - return x.TimestampNs - } - return 0 -} - -// Deprecated: Marked as deprecated in device_sync/content.proto. -func (x *DeviceSyncReply) GetKind() BackupElementSelection { - if x != nil { - return x.Kind - } - return BackupElementSelection_BACKUP_ELEMENT_SELECTION_UNSPECIFIED -} - -func (x *DeviceSyncReply) GetMetadata() *BackupMetadataSave { - if x != nil { - return x.Metadata - } - return nil -} - -// Key used to encrypt the message-bundle -type DeviceSyncKeyType struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Key: - // - // *DeviceSyncKeyType_Aes_256Gcm - Key isDeviceSyncKeyType_Key `protobuf_oneof:"key"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DeviceSyncKeyType) Reset() { - *x = DeviceSyncKeyType{} - mi := &file_device_sync_content_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DeviceSyncKeyType) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DeviceSyncKeyType) ProtoMessage() {} - -func (x *DeviceSyncKeyType) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_content_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DeviceSyncKeyType.ProtoReflect.Descriptor instead. -func (*DeviceSyncKeyType) Descriptor() ([]byte, []int) { - return file_device_sync_content_proto_rawDescGZIP(), []int{8} -} - -func (x *DeviceSyncKeyType) GetKey() isDeviceSyncKeyType_Key { - if x != nil { - return x.Key - } - return nil -} - -func (x *DeviceSyncKeyType) GetAes_256Gcm() []byte { - if x != nil { - if x, ok := x.Key.(*DeviceSyncKeyType_Aes_256Gcm); ok { - return x.Aes_256Gcm - } - } - return nil -} - -type isDeviceSyncKeyType_Key interface { - isDeviceSyncKeyType_Key() -} - -type DeviceSyncKeyType_Aes_256Gcm struct { - Aes_256Gcm []byte `protobuf:"bytes,1,opt,name=aes_256_gcm,json=aes256Gcm,proto3,oneof"` -} - -func (*DeviceSyncKeyType_Aes_256Gcm) isDeviceSyncKeyType_Key() {} - -var File_device_sync_content_proto protoreflect.FileDescriptor - -const file_device_sync_content_proto_rawDesc = "" + - "\n" + - "\x19device_sync/content.proto\x12\x18xmtp.device_sync.content\x1a device_sync/consent_backup.proto\x1a\x1ddevice_sync/device_sync.proto\"\xdd\x02\n" + - "\x11DeviceSyncContent\x12G\n" + - "\arequest\x18\x01 \x01(\v2+.xmtp.device_sync.content.DeviceSyncRequestH\x00R\arequest\x12S\n" + - "\vacknowledge\x18\x02 \x01(\v2/.xmtp.device_sync.content.DeviceSyncAcknowledgeH\x00R\vacknowledge\x12A\n" + - "\x05reply\x18\x03 \x01(\v2).xmtp.device_sync.content.DeviceSyncReplyH\x00R\x05reply\x12\\\n" + - "\x12preference_updates\x18\x04 \x01(\v2+.xmtp.device_sync.content.PreferenceUpdatesH\x00R\x11preferenceUpdatesB\t\n" + - "\acontent\"6\n" + - "\x15DeviceSyncAcknowledge\x12\x1d\n" + - "\n" + - "request_id\x18\x01 \x01(\tR\trequestId\"Y\n" + - "\x11PreferenceUpdates\x12D\n" + - "\aupdates\x18\x01 \x03(\v2*.xmtp.device_sync.content.PreferenceUpdateR\aupdates\"\xa5\x01\n" + - "\x10PreferenceUpdate\x12H\n" + - "\aconsent\x18\x01 \x01(\v2,.xmtp.device_sync.consent_backup.ConsentSaveH\x00R\aconsent\x12=\n" + - "\x04hmac\x18\x02 \x01(\v2'.xmtp.device_sync.content.HmacKeyUpdateH\x00R\x04hmacB\b\n" + - "\x06update\"4\n" + - "\x16V1UserPreferenceUpdate\x12\x1a\n" + - "\bcontents\x18\x01 \x03(\fR\bcontents\"C\n" + - "\rHmacKeyUpdate\x12\x10\n" + - "\x03key\x18\x01 \x01(\fR\x03key\x12 \n" + - "\fcycled_at_ns\x18\x02 \x01(\x03R\n" + - "cycledAtNs\"\xd7\x01\n" + - "\x11DeviceSyncRequest\x12\x10\n" + - "\x03pin\x18\x01 \x01(\tR\x03pin\x12\x1d\n" + - "\n" + - "server_url\x18\x02 \x01(\tR\tserverUrl\x12U\n" + - "\x0fdeprecated_kind\x18\x03 \x01(\x0e2(.xmtp.device_sync.BackupElementSelectionB\x02\x18\x01R\x0edeprecatedKind\x12:\n" + - "\aoptions\x18\x04 \x01(\v2 .xmtp.device_sync.ArchiveOptionsR\aoptions\"\xc1\x02\n" + - "\x0fDeviceSyncReply\x12\x1d\n" + - "\n" + - "request_id\x18\x01 \x01(\tR\trequestId\x12\x10\n" + - "\x03url\x18\x02 \x01(\tR\x03url\x12R\n" + - "\x0eencryption_key\x18\x03 \x01(\v2+.xmtp.device_sync.content.DeviceSyncKeyTypeR\rencryptionKey\x12%\n" + - "\ftimestamp_ns\x18\x04 \x01(\x04B\x02\x18\x01R\vtimestampNs\x12@\n" + - "\x04kind\x18\x05 \x01(\x0e2(.xmtp.device_sync.BackupElementSelectionB\x02\x18\x01R\x04kind\x12@\n" + - "\bmetadata\x18\x06 \x01(\v2$.xmtp.device_sync.BackupMetadataSaveR\bmetadata\"<\n" + - "\x11DeviceSyncKeyType\x12 \n" + - "\vaes_256_gcm\x18\x01 \x01(\fH\x00R\taes256GcmB\x05\n" + - "\x03keyB\x8a\x02\n" + - "6org.xmtp.android.library.push.xmtp.device_sync.contentB\fContentProtoP\x01ZDgithub.com/xmtp/example-notification-server-go/pkg/proto/device_sync\xa2\x02\x03XDC\xaa\x02\x17Xmtp.DeviceSync.Content\xca\x02\x17Xmtp\\DeviceSync\\Content\xe2\x02#Xmtp\\DeviceSync\\Content\\GPBMetadata\xea\x02\x19Xmtp::DeviceSync::Contentb\x06proto3" - -var ( - file_device_sync_content_proto_rawDescOnce sync.Once - file_device_sync_content_proto_rawDescData []byte -) - -func file_device_sync_content_proto_rawDescGZIP() []byte { - file_device_sync_content_proto_rawDescOnce.Do(func() { - file_device_sync_content_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_device_sync_content_proto_rawDesc), len(file_device_sync_content_proto_rawDesc))) - }) - return file_device_sync_content_proto_rawDescData -} - -var file_device_sync_content_proto_msgTypes = make([]protoimpl.MessageInfo, 9) -var file_device_sync_content_proto_goTypes = []any{ - (*DeviceSyncContent)(nil), // 0: xmtp.device_sync.content.DeviceSyncContent - (*DeviceSyncAcknowledge)(nil), // 1: xmtp.device_sync.content.DeviceSyncAcknowledge - (*PreferenceUpdates)(nil), // 2: xmtp.device_sync.content.PreferenceUpdates - (*PreferenceUpdate)(nil), // 3: xmtp.device_sync.content.PreferenceUpdate - (*V1UserPreferenceUpdate)(nil), // 4: xmtp.device_sync.content.V1UserPreferenceUpdate - (*HmacKeyUpdate)(nil), // 5: xmtp.device_sync.content.HmacKeyUpdate - (*DeviceSyncRequest)(nil), // 6: xmtp.device_sync.content.DeviceSyncRequest - (*DeviceSyncReply)(nil), // 7: xmtp.device_sync.content.DeviceSyncReply - (*DeviceSyncKeyType)(nil), // 8: xmtp.device_sync.content.DeviceSyncKeyType - (*ConsentSave)(nil), // 9: xmtp.device_sync.consent_backup.ConsentSave - (BackupElementSelection)(0), // 10: xmtp.device_sync.BackupElementSelection - (*ArchiveOptions)(nil), // 11: xmtp.device_sync.ArchiveOptions - (*BackupMetadataSave)(nil), // 12: xmtp.device_sync.BackupMetadataSave -} -var file_device_sync_content_proto_depIdxs = []int32{ - 6, // 0: xmtp.device_sync.content.DeviceSyncContent.request:type_name -> xmtp.device_sync.content.DeviceSyncRequest - 1, // 1: xmtp.device_sync.content.DeviceSyncContent.acknowledge:type_name -> xmtp.device_sync.content.DeviceSyncAcknowledge - 7, // 2: xmtp.device_sync.content.DeviceSyncContent.reply:type_name -> xmtp.device_sync.content.DeviceSyncReply - 2, // 3: xmtp.device_sync.content.DeviceSyncContent.preference_updates:type_name -> xmtp.device_sync.content.PreferenceUpdates - 3, // 4: xmtp.device_sync.content.PreferenceUpdates.updates:type_name -> xmtp.device_sync.content.PreferenceUpdate - 9, // 5: xmtp.device_sync.content.PreferenceUpdate.consent:type_name -> xmtp.device_sync.consent_backup.ConsentSave - 5, // 6: xmtp.device_sync.content.PreferenceUpdate.hmac:type_name -> xmtp.device_sync.content.HmacKeyUpdate - 10, // 7: xmtp.device_sync.content.DeviceSyncRequest.deprecated_kind:type_name -> xmtp.device_sync.BackupElementSelection - 11, // 8: xmtp.device_sync.content.DeviceSyncRequest.options:type_name -> xmtp.device_sync.ArchiveOptions - 8, // 9: xmtp.device_sync.content.DeviceSyncReply.encryption_key:type_name -> xmtp.device_sync.content.DeviceSyncKeyType - 10, // 10: xmtp.device_sync.content.DeviceSyncReply.kind:type_name -> xmtp.device_sync.BackupElementSelection - 12, // 11: xmtp.device_sync.content.DeviceSyncReply.metadata:type_name -> xmtp.device_sync.BackupMetadataSave - 12, // [12:12] is the sub-list for method output_type - 12, // [12:12] is the sub-list for method input_type - 12, // [12:12] is the sub-list for extension type_name - 12, // [12:12] is the sub-list for extension extendee - 0, // [0:12] is the sub-list for field type_name -} - -func init() { file_device_sync_content_proto_init() } -func file_device_sync_content_proto_init() { - if File_device_sync_content_proto != nil { - return - } - file_device_sync_consent_backup_proto_init() - file_device_sync_device_sync_proto_init() - file_device_sync_content_proto_msgTypes[0].OneofWrappers = []any{ - (*DeviceSyncContent_Request)(nil), - (*DeviceSyncContent_Acknowledge)(nil), - (*DeviceSyncContent_Reply)(nil), - (*DeviceSyncContent_PreferenceUpdates)(nil), - } - file_device_sync_content_proto_msgTypes[3].OneofWrappers = []any{ - (*PreferenceUpdate_Consent)(nil), - (*PreferenceUpdate_Hmac)(nil), - } - file_device_sync_content_proto_msgTypes[8].OneofWrappers = []any{ - (*DeviceSyncKeyType_Aes_256Gcm)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_device_sync_content_proto_rawDesc), len(file_device_sync_content_proto_rawDesc)), - NumEnums: 0, - NumMessages: 9, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_device_sync_content_proto_goTypes, - DependencyIndexes: file_device_sync_content_proto_depIdxs, - MessageInfos: file_device_sync_content_proto_msgTypes, - }.Build() - File_device_sync_content_proto = out.File - file_device_sync_content_proto_goTypes = nil - file_device_sync_content_proto_depIdxs = nil -} diff --git a/pkg/proto/device_sync/device_sync.pb.go b/pkg/proto/device_sync/device_sync.pb.go deleted file mode 100644 index 41f68e55..00000000 --- a/pkg/proto/device_sync/device_sync.pb.go +++ /dev/null @@ -1,460 +0,0 @@ -// Definitions for backups - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: device_sync/device_sync.proto - -package device_sync - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Elements selected for backup -type BackupElementSelection int32 - -const ( - BackupElementSelection_BACKUP_ELEMENT_SELECTION_UNSPECIFIED BackupElementSelection = 0 - BackupElementSelection_BACKUP_ELEMENT_SELECTION_MESSAGES BackupElementSelection = 1 - BackupElementSelection_BACKUP_ELEMENT_SELECTION_CONSENT BackupElementSelection = 2 - // Deprecated: Marked as deprecated in device_sync/device_sync.proto. - BackupElementSelection_BACKUP_ELEMENT_SELECTION_EVENT BackupElementSelection = 3 -) - -// Enum value maps for BackupElementSelection. -var ( - BackupElementSelection_name = map[int32]string{ - 0: "BACKUP_ELEMENT_SELECTION_UNSPECIFIED", - 1: "BACKUP_ELEMENT_SELECTION_MESSAGES", - 2: "BACKUP_ELEMENT_SELECTION_CONSENT", - 3: "BACKUP_ELEMENT_SELECTION_EVENT", - } - BackupElementSelection_value = map[string]int32{ - "BACKUP_ELEMENT_SELECTION_UNSPECIFIED": 0, - "BACKUP_ELEMENT_SELECTION_MESSAGES": 1, - "BACKUP_ELEMENT_SELECTION_CONSENT": 2, - "BACKUP_ELEMENT_SELECTION_EVENT": 3, - } -) - -func (x BackupElementSelection) Enum() *BackupElementSelection { - p := new(BackupElementSelection) - *p = x - return p -} - -func (x BackupElementSelection) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (BackupElementSelection) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_device_sync_proto_enumTypes[0].Descriptor() -} - -func (BackupElementSelection) Type() protoreflect.EnumType { - return &file_device_sync_device_sync_proto_enumTypes[0] -} - -func (x BackupElementSelection) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use BackupElementSelection.Descriptor instead. -func (BackupElementSelection) EnumDescriptor() ([]byte, []int) { - return file_device_sync_device_sync_proto_rawDescGZIP(), []int{0} -} - -// Union type representing everything that can be serialied and saved in a backup archive. -type BackupElement struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Element: - // - // *BackupElement_Metadata - // *BackupElement_Group - // *BackupElement_GroupMessage - // *BackupElement_Consent - // *BackupElement_Event - Element isBackupElement_Element `protobuf_oneof:"element"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BackupElement) Reset() { - *x = BackupElement{} - mi := &file_device_sync_device_sync_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BackupElement) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BackupElement) ProtoMessage() {} - -func (x *BackupElement) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_device_sync_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BackupElement.ProtoReflect.Descriptor instead. -func (*BackupElement) Descriptor() ([]byte, []int) { - return file_device_sync_device_sync_proto_rawDescGZIP(), []int{0} -} - -func (x *BackupElement) GetElement() isBackupElement_Element { - if x != nil { - return x.Element - } - return nil -} - -func (x *BackupElement) GetMetadata() *BackupMetadataSave { - if x != nil { - if x, ok := x.Element.(*BackupElement_Metadata); ok { - return x.Metadata - } - } - return nil -} - -func (x *BackupElement) GetGroup() *GroupSave { - if x != nil { - if x, ok := x.Element.(*BackupElement_Group); ok { - return x.Group - } - } - return nil -} - -func (x *BackupElement) GetGroupMessage() *GroupMessageSave { - if x != nil { - if x, ok := x.Element.(*BackupElement_GroupMessage); ok { - return x.GroupMessage - } - } - return nil -} - -func (x *BackupElement) GetConsent() *ConsentSave { - if x != nil { - if x, ok := x.Element.(*BackupElement_Consent); ok { - return x.Consent - } - } - return nil -} - -// Deprecated: Marked as deprecated in device_sync/device_sync.proto. -func (x *BackupElement) GetEvent() *EventSave { - if x != nil { - if x, ok := x.Element.(*BackupElement_Event); ok { - return x.Event - } - } - return nil -} - -type isBackupElement_Element interface { - isBackupElement_Element() -} - -type BackupElement_Metadata struct { - Metadata *BackupMetadataSave `protobuf:"bytes,1,opt,name=metadata,proto3,oneof"` -} - -type BackupElement_Group struct { - Group *GroupSave `protobuf:"bytes,2,opt,name=group,proto3,oneof"` -} - -type BackupElement_GroupMessage struct { - GroupMessage *GroupMessageSave `protobuf:"bytes,3,opt,name=group_message,json=groupMessage,proto3,oneof"` -} - -type BackupElement_Consent struct { - Consent *ConsentSave `protobuf:"bytes,4,opt,name=consent,proto3,oneof"` -} - -type BackupElement_Event struct { - // Deprecated: Marked as deprecated in device_sync/device_sync.proto. - Event *EventSave `protobuf:"bytes,5,opt,name=event,proto3,oneof"` -} - -func (*BackupElement_Metadata) isBackupElement_Element() {} - -func (*BackupElement_Group) isBackupElement_Element() {} - -func (*BackupElement_GroupMessage) isBackupElement_Element() {} - -func (*BackupElement_Consent) isBackupElement_Element() {} - -func (*BackupElement_Event) isBackupElement_Element() {} - -// Proto representation of backup metadata -// (Backup version is explicitly missing - it's stored as a header.) -type BackupMetadataSave struct { - state protoimpl.MessageState `protogen:"open.v1"` - Elements []BackupElementSelection `protobuf:"varint,2,rep,packed,name=elements,proto3,enum=xmtp.device_sync.BackupElementSelection" json:"elements,omitempty"` - ExportedAtNs int64 `protobuf:"varint,3,opt,name=exported_at_ns,json=exportedAtNs,proto3" json:"exported_at_ns,omitempty"` - StartNs *int64 `protobuf:"varint,4,opt,name=start_ns,json=startNs,proto3,oneof" json:"start_ns,omitempty"` - EndNs *int64 `protobuf:"varint,5,opt,name=end_ns,json=endNs,proto3,oneof" json:"end_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BackupMetadataSave) Reset() { - *x = BackupMetadataSave{} - mi := &file_device_sync_device_sync_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BackupMetadataSave) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BackupMetadataSave) ProtoMessage() {} - -func (x *BackupMetadataSave) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_device_sync_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BackupMetadataSave.ProtoReflect.Descriptor instead. -func (*BackupMetadataSave) Descriptor() ([]byte, []int) { - return file_device_sync_device_sync_proto_rawDescGZIP(), []int{1} -} - -func (x *BackupMetadataSave) GetElements() []BackupElementSelection { - if x != nil { - return x.Elements - } - return nil -} - -func (x *BackupMetadataSave) GetExportedAtNs() int64 { - if x != nil { - return x.ExportedAtNs - } - return 0 -} - -func (x *BackupMetadataSave) GetStartNs() int64 { - if x != nil && x.StartNs != nil { - return *x.StartNs - } - return 0 -} - -func (x *BackupMetadataSave) GetEndNs() int64 { - if x != nil && x.EndNs != nil { - return *x.EndNs - } - return 0 -} - -// Backup Options -type ArchiveOptions struct { - state protoimpl.MessageState `protogen:"open.v1"` - Elements []BackupElementSelection `protobuf:"varint,1,rep,packed,name=elements,proto3,enum=xmtp.device_sync.BackupElementSelection" json:"elements,omitempty"` - StartNs *int64 `protobuf:"varint,2,opt,name=start_ns,json=startNs,proto3,oneof" json:"start_ns,omitempty"` - EndNs *int64 `protobuf:"varint,3,opt,name=end_ns,json=endNs,proto3,oneof" json:"end_ns,omitempty"` - ExcludeDisappearingMessages bool `protobuf:"varint,4,opt,name=exclude_disappearing_messages,json=excludeDisappearingMessages,proto3" json:"exclude_disappearing_messages,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ArchiveOptions) Reset() { - *x = ArchiveOptions{} - mi := &file_device_sync_device_sync_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ArchiveOptions) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ArchiveOptions) ProtoMessage() {} - -func (x *ArchiveOptions) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_device_sync_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ArchiveOptions.ProtoReflect.Descriptor instead. -func (*ArchiveOptions) Descriptor() ([]byte, []int) { - return file_device_sync_device_sync_proto_rawDescGZIP(), []int{2} -} - -func (x *ArchiveOptions) GetElements() []BackupElementSelection { - if x != nil { - return x.Elements - } - return nil -} - -func (x *ArchiveOptions) GetStartNs() int64 { - if x != nil && x.StartNs != nil { - return *x.StartNs - } - return 0 -} - -func (x *ArchiveOptions) GetEndNs() int64 { - if x != nil && x.EndNs != nil { - return *x.EndNs - } - return 0 -} - -func (x *ArchiveOptions) GetExcludeDisappearingMessages() bool { - if x != nil { - return x.ExcludeDisappearingMessages - } - return false -} - -var File_device_sync_device_sync_proto protoreflect.FileDescriptor - -const file_device_sync_device_sync_proto_rawDesc = "" + - "\n" + - "\x1ddevice_sync/device_sync.proto\x12\x10xmtp.device_sync\x1a device_sync/consent_backup.proto\x1a\x1edevice_sync/event_backup.proto\x1a\x1edevice_sync/group_backup.proto\x1a device_sync/message_backup.proto\"\x8a\x03\n" + - "\rBackupElement\x12B\n" + - "\bmetadata\x18\x01 \x01(\v2$.xmtp.device_sync.BackupMetadataSaveH\x00R\bmetadata\x12@\n" + - "\x05group\x18\x02 \x01(\v2(.xmtp.device_sync.group_backup.GroupSaveH\x00R\x05group\x12X\n" + - "\rgroup_message\x18\x03 \x01(\v21.xmtp.device_sync.message_backup.GroupMessageSaveH\x00R\fgroupMessage\x12H\n" + - "\aconsent\x18\x04 \x01(\v2,.xmtp.device_sync.consent_backup.ConsentSaveH\x00R\aconsent\x12D\n" + - "\x05event\x18\x05 \x01(\v2(.xmtp.device_sync.event_backup.EventSaveB\x02\x18\x01H\x00R\x05eventB\t\n" + - "\aelement\"\xd4\x01\n" + - "\x12BackupMetadataSave\x12D\n" + - "\belements\x18\x02 \x03(\x0e2(.xmtp.device_sync.BackupElementSelectionR\belements\x12$\n" + - "\x0eexported_at_ns\x18\x03 \x01(\x03R\fexportedAtNs\x12\x1e\n" + - "\bstart_ns\x18\x04 \x01(\x03H\x00R\astartNs\x88\x01\x01\x12\x1a\n" + - "\x06end_ns\x18\x05 \x01(\x03H\x01R\x05endNs\x88\x01\x01B\v\n" + - "\t_start_nsB\t\n" + - "\a_end_ns\"\xee\x01\n" + - "\x0eArchiveOptions\x12D\n" + - "\belements\x18\x01 \x03(\x0e2(.xmtp.device_sync.BackupElementSelectionR\belements\x12\x1e\n" + - "\bstart_ns\x18\x02 \x01(\x03H\x00R\astartNs\x88\x01\x01\x12\x1a\n" + - "\x06end_ns\x18\x03 \x01(\x03H\x01R\x05endNs\x88\x01\x01\x12B\n" + - "\x1dexclude_disappearing_messages\x18\x04 \x01(\bR\x1bexcludeDisappearingMessagesB\v\n" + - "\t_start_nsB\t\n" + - "\a_end_ns*\xb7\x01\n" + - "\x16BackupElementSelection\x12(\n" + - "$BACKUP_ELEMENT_SELECTION_UNSPECIFIED\x10\x00\x12%\n" + - "!BACKUP_ELEMENT_SELECTION_MESSAGES\x10\x01\x12$\n" + - " BACKUP_ELEMENT_SELECTION_CONSENT\x10\x02\x12&\n" + - "\x1eBACKUP_ELEMENT_SELECTION_EVENT\x10\x03\x1a\x02\b\x01B\xe4\x01\n" + - ".org.xmtp.android.library.push.xmtp.device_syncB\x0fDeviceSyncProtoP\x01ZDgithub.com/xmtp/example-notification-server-go/pkg/proto/device_sync\xa2\x02\x03XDX\xaa\x02\x0fXmtp.DeviceSync\xca\x02\x0fXmtp\\DeviceSync\xe2\x02\x1bXmtp\\DeviceSync\\GPBMetadata\xea\x02\x10Xmtp::DeviceSyncb\x06proto3" - -var ( - file_device_sync_device_sync_proto_rawDescOnce sync.Once - file_device_sync_device_sync_proto_rawDescData []byte -) - -func file_device_sync_device_sync_proto_rawDescGZIP() []byte { - file_device_sync_device_sync_proto_rawDescOnce.Do(func() { - file_device_sync_device_sync_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_device_sync_device_sync_proto_rawDesc), len(file_device_sync_device_sync_proto_rawDesc))) - }) - return file_device_sync_device_sync_proto_rawDescData -} - -var file_device_sync_device_sync_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_device_sync_device_sync_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_device_sync_device_sync_proto_goTypes = []any{ - (BackupElementSelection)(0), // 0: xmtp.device_sync.BackupElementSelection - (*BackupElement)(nil), // 1: xmtp.device_sync.BackupElement - (*BackupMetadataSave)(nil), // 2: xmtp.device_sync.BackupMetadataSave - (*ArchiveOptions)(nil), // 3: xmtp.device_sync.ArchiveOptions - (*GroupSave)(nil), // 4: xmtp.device_sync.group_backup.GroupSave - (*GroupMessageSave)(nil), // 5: xmtp.device_sync.message_backup.GroupMessageSave - (*ConsentSave)(nil), // 6: xmtp.device_sync.consent_backup.ConsentSave - (*EventSave)(nil), // 7: xmtp.device_sync.event_backup.EventSave -} -var file_device_sync_device_sync_proto_depIdxs = []int32{ - 2, // 0: xmtp.device_sync.BackupElement.metadata:type_name -> xmtp.device_sync.BackupMetadataSave - 4, // 1: xmtp.device_sync.BackupElement.group:type_name -> xmtp.device_sync.group_backup.GroupSave - 5, // 2: xmtp.device_sync.BackupElement.group_message:type_name -> xmtp.device_sync.message_backup.GroupMessageSave - 6, // 3: xmtp.device_sync.BackupElement.consent:type_name -> xmtp.device_sync.consent_backup.ConsentSave - 7, // 4: xmtp.device_sync.BackupElement.event:type_name -> xmtp.device_sync.event_backup.EventSave - 0, // 5: xmtp.device_sync.BackupMetadataSave.elements:type_name -> xmtp.device_sync.BackupElementSelection - 0, // 6: xmtp.device_sync.ArchiveOptions.elements:type_name -> xmtp.device_sync.BackupElementSelection - 7, // [7:7] is the sub-list for method output_type - 7, // [7:7] is the sub-list for method input_type - 7, // [7:7] is the sub-list for extension type_name - 7, // [7:7] is the sub-list for extension extendee - 0, // [0:7] is the sub-list for field type_name -} - -func init() { file_device_sync_device_sync_proto_init() } -func file_device_sync_device_sync_proto_init() { - if File_device_sync_device_sync_proto != nil { - return - } - file_device_sync_consent_backup_proto_init() - file_device_sync_event_backup_proto_init() - file_device_sync_group_backup_proto_init() - file_device_sync_message_backup_proto_init() - file_device_sync_device_sync_proto_msgTypes[0].OneofWrappers = []any{ - (*BackupElement_Metadata)(nil), - (*BackupElement_Group)(nil), - (*BackupElement_GroupMessage)(nil), - (*BackupElement_Consent)(nil), - (*BackupElement_Event)(nil), - } - file_device_sync_device_sync_proto_msgTypes[1].OneofWrappers = []any{} - file_device_sync_device_sync_proto_msgTypes[2].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_device_sync_device_sync_proto_rawDesc), len(file_device_sync_device_sync_proto_rawDesc)), - NumEnums: 1, - NumMessages: 3, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_device_sync_device_sync_proto_goTypes, - DependencyIndexes: file_device_sync_device_sync_proto_depIdxs, - EnumInfos: file_device_sync_device_sync_proto_enumTypes, - MessageInfos: file_device_sync_device_sync_proto_msgTypes, - }.Build() - File_device_sync_device_sync_proto = out.File - file_device_sync_device_sync_proto_goTypes = nil - file_device_sync_device_sync_proto_depIdxs = nil -} diff --git a/pkg/proto/device_sync/event_backup.pb.go b/pkg/proto/device_sync/event_backup.pb.go deleted file mode 100644 index 6186abd6..00000000 --- a/pkg/proto/device_sync/event_backup.pb.go +++ /dev/null @@ -1,246 +0,0 @@ -// Definitions for backups - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: device_sync/event_backup.proto - -package device_sync - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Deprecated: Marked as deprecated in device_sync/event_backup.proto. -type EventLevelSave int32 - -const ( - EventLevelSave_EVENT_LEVEL_SAVE_UNSPECIFIED EventLevelSave = 0 - EventLevelSave_EVENT_LEVEL_SAVE_NONE EventLevelSave = 1 - EventLevelSave_EVENT_LEVEL_SAVE_SUCCESS EventLevelSave = 2 - EventLevelSave_EVENT_LEVEL_SAVE_WARN EventLevelSave = 3 - EventLevelSave_EVENT_LEVEL_SAVE_ERROR EventLevelSave = 4 - EventLevelSave_EVENT_LEVEL_SAVE_FAULT EventLevelSave = 5 -) - -// Enum value maps for EventLevelSave. -var ( - EventLevelSave_name = map[int32]string{ - 0: "EVENT_LEVEL_SAVE_UNSPECIFIED", - 1: "EVENT_LEVEL_SAVE_NONE", - 2: "EVENT_LEVEL_SAVE_SUCCESS", - 3: "EVENT_LEVEL_SAVE_WARN", - 4: "EVENT_LEVEL_SAVE_ERROR", - 5: "EVENT_LEVEL_SAVE_FAULT", - } - EventLevelSave_value = map[string]int32{ - "EVENT_LEVEL_SAVE_UNSPECIFIED": 0, - "EVENT_LEVEL_SAVE_NONE": 1, - "EVENT_LEVEL_SAVE_SUCCESS": 2, - "EVENT_LEVEL_SAVE_WARN": 3, - "EVENT_LEVEL_SAVE_ERROR": 4, - "EVENT_LEVEL_SAVE_FAULT": 5, - } -) - -func (x EventLevelSave) Enum() *EventLevelSave { - p := new(EventLevelSave) - *p = x - return p -} - -func (x EventLevelSave) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (EventLevelSave) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_event_backup_proto_enumTypes[0].Descriptor() -} - -func (EventLevelSave) Type() protoreflect.EnumType { - return &file_device_sync_event_backup_proto_enumTypes[0] -} - -func (x EventLevelSave) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use EventLevelSave.Descriptor instead. -func (EventLevelSave) EnumDescriptor() ([]byte, []int) { - return file_device_sync_event_backup_proto_rawDescGZIP(), []int{0} -} - -// Proto representation of a client record save -// -// Deprecated: Marked as deprecated in device_sync/event_backup.proto. -type EventSave struct { - state protoimpl.MessageState `protogen:"open.v1"` - CreatedAtNs int64 `protobuf:"varint,1,opt,name=created_at_ns,json=createdAtNs,proto3" json:"created_at_ns,omitempty"` - Event string `protobuf:"bytes,2,opt,name=event,proto3" json:"event,omitempty"` - Details []byte `protobuf:"bytes,3,opt,name=details,proto3" json:"details,omitempty"` - GroupId []byte `protobuf:"bytes,4,opt,name=group_id,json=groupId,proto3,oneof" json:"group_id,omitempty"` - Level EventLevelSave `protobuf:"varint,5,opt,name=level,proto3,enum=xmtp.device_sync.event_backup.EventLevelSave" json:"level,omitempty"` - Icon *string `protobuf:"bytes,6,opt,name=icon,proto3,oneof" json:"icon,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EventSave) Reset() { - *x = EventSave{} - mi := &file_device_sync_event_backup_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EventSave) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EventSave) ProtoMessage() {} - -func (x *EventSave) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_event_backup_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EventSave.ProtoReflect.Descriptor instead. -func (*EventSave) Descriptor() ([]byte, []int) { - return file_device_sync_event_backup_proto_rawDescGZIP(), []int{0} -} - -func (x *EventSave) GetCreatedAtNs() int64 { - if x != nil { - return x.CreatedAtNs - } - return 0 -} - -func (x *EventSave) GetEvent() string { - if x != nil { - return x.Event - } - return "" -} - -func (x *EventSave) GetDetails() []byte { - if x != nil { - return x.Details - } - return nil -} - -func (x *EventSave) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *EventSave) GetLevel() EventLevelSave { - if x != nil { - return x.Level - } - return EventLevelSave_EVENT_LEVEL_SAVE_UNSPECIFIED -} - -func (x *EventSave) GetIcon() string { - if x != nil && x.Icon != nil { - return *x.Icon - } - return "" -} - -var File_device_sync_event_backup_proto protoreflect.FileDescriptor - -const file_device_sync_event_backup_proto_rawDesc = "" + - "\n" + - "\x1edevice_sync/event_backup.proto\x12\x1dxmtp.device_sync.event_backup\"\xf7\x01\n" + - "\tEventSave\x12\"\n" + - "\rcreated_at_ns\x18\x01 \x01(\x03R\vcreatedAtNs\x12\x14\n" + - "\x05event\x18\x02 \x01(\tR\x05event\x12\x18\n" + - "\adetails\x18\x03 \x01(\fR\adetails\x12\x1e\n" + - "\bgroup_id\x18\x04 \x01(\fH\x00R\agroupId\x88\x01\x01\x12C\n" + - "\x05level\x18\x05 \x01(\x0e2-.xmtp.device_sync.event_backup.EventLevelSaveR\x05level\x12\x17\n" + - "\x04icon\x18\x06 \x01(\tH\x01R\x04icon\x88\x01\x01:\x02\x18\x01B\v\n" + - "\t_group_idB\a\n" + - "\x05_icon*\xc2\x01\n" + - "\x0eEventLevelSave\x12 \n" + - "\x1cEVENT_LEVEL_SAVE_UNSPECIFIED\x10\x00\x12\x19\n" + - "\x15EVENT_LEVEL_SAVE_NONE\x10\x01\x12\x1c\n" + - "\x18EVENT_LEVEL_SAVE_SUCCESS\x10\x02\x12\x19\n" + - "\x15EVENT_LEVEL_SAVE_WARN\x10\x03\x12\x1a\n" + - "\x16EVENT_LEVEL_SAVE_ERROR\x10\x04\x12\x1a\n" + - "\x16EVENT_LEVEL_SAVE_FAULT\x10\x05\x1a\x02\x18\x01B\xa3\x02\n" + - ";org.xmtp.android.library.push.xmtp.device_sync.event_backupB\x10EventBackupProtoP\x01ZDgithub.com/xmtp/example-notification-server-go/pkg/proto/device_sync\xa2\x02\x03XDE\xaa\x02\x1bXmtp.DeviceSync.EventBackup\xca\x02\x1bXmtp\\DeviceSync\\EventBackup\xe2\x02'Xmtp\\DeviceSync\\EventBackup\\GPBMetadata\xea\x02\x1dXmtp::DeviceSync::EventBackupb\x06proto3" - -var ( - file_device_sync_event_backup_proto_rawDescOnce sync.Once - file_device_sync_event_backup_proto_rawDescData []byte -) - -func file_device_sync_event_backup_proto_rawDescGZIP() []byte { - file_device_sync_event_backup_proto_rawDescOnce.Do(func() { - file_device_sync_event_backup_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_device_sync_event_backup_proto_rawDesc), len(file_device_sync_event_backup_proto_rawDesc))) - }) - return file_device_sync_event_backup_proto_rawDescData -} - -var file_device_sync_event_backup_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_device_sync_event_backup_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_device_sync_event_backup_proto_goTypes = []any{ - (EventLevelSave)(0), // 0: xmtp.device_sync.event_backup.EventLevelSave - (*EventSave)(nil), // 1: xmtp.device_sync.event_backup.EventSave -} -var file_device_sync_event_backup_proto_depIdxs = []int32{ - 0, // 0: xmtp.device_sync.event_backup.EventSave.level:type_name -> xmtp.device_sync.event_backup.EventLevelSave - 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_device_sync_event_backup_proto_init() } -func file_device_sync_event_backup_proto_init() { - if File_device_sync_event_backup_proto != nil { - return - } - file_device_sync_event_backup_proto_msgTypes[0].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_device_sync_event_backup_proto_rawDesc), len(file_device_sync_event_backup_proto_rawDesc)), - NumEnums: 1, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_device_sync_event_backup_proto_goTypes, - DependencyIndexes: file_device_sync_event_backup_proto_depIdxs, - EnumInfos: file_device_sync_event_backup_proto_enumTypes, - MessageInfos: file_device_sync_event_backup_proto_msgTypes, - }.Build() - File_device_sync_event_backup_proto = out.File - file_device_sync_event_backup_proto_goTypes = nil - file_device_sync_event_backup_proto_depIdxs = nil -} diff --git a/pkg/proto/device_sync/group_backup.pb.go b/pkg/proto/device_sync/group_backup.pb.go deleted file mode 100644 index e910c233..00000000 --- a/pkg/proto/device_sync/group_backup.pb.go +++ /dev/null @@ -1,520 +0,0 @@ -// Definitions for backups - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: device_sync/group_backup.proto - -package device_sync - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Group membership state -type GroupMembershipStateSave int32 - -const ( - GroupMembershipStateSave_GROUP_MEMBERSHIP_STATE_SAVE_UNSPECIFIED GroupMembershipStateSave = 0 - GroupMembershipStateSave_GROUP_MEMBERSHIP_STATE_SAVE_ALLOWED GroupMembershipStateSave = 1 - GroupMembershipStateSave_GROUP_MEMBERSHIP_STATE_SAVE_REJECTED GroupMembershipStateSave = 2 - GroupMembershipStateSave_GROUP_MEMBERSHIP_STATE_SAVE_PENDING GroupMembershipStateSave = 3 - // A group is marked as this state when it is restored - // from a backup. This is a non-functional archive state - // that can be reactivated when the user is re-added to - // the group. - GroupMembershipStateSave_GROUP_MEMBERSHIP_STATE_SAVE_RESTORED GroupMembershipStateSave = 4 - GroupMembershipStateSave_GROUP_MEMBERSHIP_STATE_SAVE_PENDING_REMOVE GroupMembershipStateSave = 5 -) - -// Enum value maps for GroupMembershipStateSave. -var ( - GroupMembershipStateSave_name = map[int32]string{ - 0: "GROUP_MEMBERSHIP_STATE_SAVE_UNSPECIFIED", - 1: "GROUP_MEMBERSHIP_STATE_SAVE_ALLOWED", - 2: "GROUP_MEMBERSHIP_STATE_SAVE_REJECTED", - 3: "GROUP_MEMBERSHIP_STATE_SAVE_PENDING", - 4: "GROUP_MEMBERSHIP_STATE_SAVE_RESTORED", - 5: "GROUP_MEMBERSHIP_STATE_SAVE_PENDING_REMOVE", - } - GroupMembershipStateSave_value = map[string]int32{ - "GROUP_MEMBERSHIP_STATE_SAVE_UNSPECIFIED": 0, - "GROUP_MEMBERSHIP_STATE_SAVE_ALLOWED": 1, - "GROUP_MEMBERSHIP_STATE_SAVE_REJECTED": 2, - "GROUP_MEMBERSHIP_STATE_SAVE_PENDING": 3, - "GROUP_MEMBERSHIP_STATE_SAVE_RESTORED": 4, - "GROUP_MEMBERSHIP_STATE_SAVE_PENDING_REMOVE": 5, - } -) - -func (x GroupMembershipStateSave) Enum() *GroupMembershipStateSave { - p := new(GroupMembershipStateSave) - *p = x - return p -} - -func (x GroupMembershipStateSave) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (GroupMembershipStateSave) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_group_backup_proto_enumTypes[0].Descriptor() -} - -func (GroupMembershipStateSave) Type() protoreflect.EnumType { - return &file_device_sync_group_backup_proto_enumTypes[0] -} - -func (x GroupMembershipStateSave) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use GroupMembershipStateSave.Descriptor instead. -func (GroupMembershipStateSave) EnumDescriptor() ([]byte, []int) { - return file_device_sync_group_backup_proto_rawDescGZIP(), []int{0} -} - -// Conversation type -type ConversationTypeSave int32 - -const ( - ConversationTypeSave_CONVERSATION_TYPE_SAVE_UNSPECIFIED ConversationTypeSave = 0 - ConversationTypeSave_CONVERSATION_TYPE_SAVE_GROUP ConversationTypeSave = 1 - ConversationTypeSave_CONVERSATION_TYPE_SAVE_DM ConversationTypeSave = 2 - ConversationTypeSave_CONVERSATION_TYPE_SAVE_SYNC ConversationTypeSave = 3 -) - -// Enum value maps for ConversationTypeSave. -var ( - ConversationTypeSave_name = map[int32]string{ - 0: "CONVERSATION_TYPE_SAVE_UNSPECIFIED", - 1: "CONVERSATION_TYPE_SAVE_GROUP", - 2: "CONVERSATION_TYPE_SAVE_DM", - 3: "CONVERSATION_TYPE_SAVE_SYNC", - } - ConversationTypeSave_value = map[string]int32{ - "CONVERSATION_TYPE_SAVE_UNSPECIFIED": 0, - "CONVERSATION_TYPE_SAVE_GROUP": 1, - "CONVERSATION_TYPE_SAVE_DM": 2, - "CONVERSATION_TYPE_SAVE_SYNC": 3, - } -) - -func (x ConversationTypeSave) Enum() *ConversationTypeSave { - p := new(ConversationTypeSave) - *p = x - return p -} - -func (x ConversationTypeSave) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ConversationTypeSave) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_group_backup_proto_enumTypes[1].Descriptor() -} - -func (ConversationTypeSave) Type() protoreflect.EnumType { - return &file_device_sync_group_backup_proto_enumTypes[1] -} - -func (x ConversationTypeSave) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ConversationTypeSave.Descriptor instead. -func (ConversationTypeSave) EnumDescriptor() ([]byte, []int) { - return file_device_sync_group_backup_proto_rawDescGZIP(), []int{1} -} - -// Proto representation of a stored group -type GroupSave struct { - state protoimpl.MessageState `protogen:"open.v1"` - Id []byte `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` - CreatedAtNs int64 `protobuf:"varint,2,opt,name=created_at_ns,json=createdAtNs,proto3" json:"created_at_ns,omitempty"` - MembershipState GroupMembershipStateSave `protobuf:"varint,3,opt,name=membership_state,json=membershipState,proto3,enum=xmtp.device_sync.group_backup.GroupMembershipStateSave" json:"membership_state,omitempty"` - InstallationsLastChecked int64 `protobuf:"varint,4,opt,name=installations_last_checked,json=installationsLastChecked,proto3" json:"installations_last_checked,omitempty"` - AddedByInboxId string `protobuf:"bytes,5,opt,name=added_by_inbox_id,json=addedByInboxId,proto3" json:"added_by_inbox_id,omitempty"` - WelcomeId *int64 `protobuf:"varint,6,opt,name=welcome_id,json=welcomeId,proto3,oneof" json:"welcome_id,omitempty"` - RotatedAtNs int64 `protobuf:"varint,7,opt,name=rotated_at_ns,json=rotatedAtNs,proto3" json:"rotated_at_ns,omitempty"` - ConversationType ConversationTypeSave `protobuf:"varint,8,opt,name=conversation_type,json=conversationType,proto3,enum=xmtp.device_sync.group_backup.ConversationTypeSave" json:"conversation_type,omitempty"` - DmId *string `protobuf:"bytes,9,opt,name=dm_id,json=dmId,proto3,oneof" json:"dm_id,omitempty"` - LastMessageNs *int64 `protobuf:"varint,10,opt,name=last_message_ns,json=lastMessageNs,proto3,oneof" json:"last_message_ns,omitempty"` - MessageDisappearFromNs *int64 `protobuf:"varint,11,opt,name=message_disappear_from_ns,json=messageDisappearFromNs,proto3,oneof" json:"message_disappear_from_ns,omitempty"` - MessageDisappearInNs *int64 `protobuf:"varint,12,opt,name=message_disappear_in_ns,json=messageDisappearInNs,proto3,oneof" json:"message_disappear_in_ns,omitempty"` - // metadata fields - Metadata *ImmutableMetadataSave `protobuf:"bytes,13,opt,name=metadata,proto3" json:"metadata,omitempty"` - MutableMetadata *MutableMetadataSave `protobuf:"bytes,14,opt,name=mutable_metadata,json=mutableMetadata,proto3" json:"mutable_metadata,omitempty"` - PausedForVersion *string `protobuf:"bytes,15,opt,name=paused_for_version,json=pausedForVersion,proto3,oneof" json:"paused_for_version,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupSave) Reset() { - *x = GroupSave{} - mi := &file_device_sync_group_backup_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupSave) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupSave) ProtoMessage() {} - -func (x *GroupSave) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_group_backup_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupSave.ProtoReflect.Descriptor instead. -func (*GroupSave) Descriptor() ([]byte, []int) { - return file_device_sync_group_backup_proto_rawDescGZIP(), []int{0} -} - -func (x *GroupSave) GetId() []byte { - if x != nil { - return x.Id - } - return nil -} - -func (x *GroupSave) GetCreatedAtNs() int64 { - if x != nil { - return x.CreatedAtNs - } - return 0 -} - -func (x *GroupSave) GetMembershipState() GroupMembershipStateSave { - if x != nil { - return x.MembershipState - } - return GroupMembershipStateSave_GROUP_MEMBERSHIP_STATE_SAVE_UNSPECIFIED -} - -func (x *GroupSave) GetInstallationsLastChecked() int64 { - if x != nil { - return x.InstallationsLastChecked - } - return 0 -} - -func (x *GroupSave) GetAddedByInboxId() string { - if x != nil { - return x.AddedByInboxId - } - return "" -} - -func (x *GroupSave) GetWelcomeId() int64 { - if x != nil && x.WelcomeId != nil { - return *x.WelcomeId - } - return 0 -} - -func (x *GroupSave) GetRotatedAtNs() int64 { - if x != nil { - return x.RotatedAtNs - } - return 0 -} - -func (x *GroupSave) GetConversationType() ConversationTypeSave { - if x != nil { - return x.ConversationType - } - return ConversationTypeSave_CONVERSATION_TYPE_SAVE_UNSPECIFIED -} - -func (x *GroupSave) GetDmId() string { - if x != nil && x.DmId != nil { - return *x.DmId - } - return "" -} - -func (x *GroupSave) GetLastMessageNs() int64 { - if x != nil && x.LastMessageNs != nil { - return *x.LastMessageNs - } - return 0 -} - -func (x *GroupSave) GetMessageDisappearFromNs() int64 { - if x != nil && x.MessageDisappearFromNs != nil { - return *x.MessageDisappearFromNs - } - return 0 -} - -func (x *GroupSave) GetMessageDisappearInNs() int64 { - if x != nil && x.MessageDisappearInNs != nil { - return *x.MessageDisappearInNs - } - return 0 -} - -func (x *GroupSave) GetMetadata() *ImmutableMetadataSave { - if x != nil { - return x.Metadata - } - return nil -} - -func (x *GroupSave) GetMutableMetadata() *MutableMetadataSave { - if x != nil { - return x.MutableMetadata - } - return nil -} - -func (x *GroupSave) GetPausedForVersion() string { - if x != nil && x.PausedForVersion != nil { - return *x.PausedForVersion - } - return "" -} - -// A Groups's mutable metadata -type MutableMetadataSave struct { - state protoimpl.MessageState `protogen:"open.v1"` - Attributes map[string]string `protobuf:"bytes,1,rep,name=attributes,proto3" json:"attributes,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - AdminList []string `protobuf:"bytes,2,rep,name=admin_list,json=adminList,proto3" json:"admin_list,omitempty"` - SuperAdminList []string `protobuf:"bytes,3,rep,name=super_admin_list,json=superAdminList,proto3" json:"super_admin_list,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MutableMetadataSave) Reset() { - *x = MutableMetadataSave{} - mi := &file_device_sync_group_backup_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MutableMetadataSave) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MutableMetadataSave) ProtoMessage() {} - -func (x *MutableMetadataSave) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_group_backup_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MutableMetadataSave.ProtoReflect.Descriptor instead. -func (*MutableMetadataSave) Descriptor() ([]byte, []int) { - return file_device_sync_group_backup_proto_rawDescGZIP(), []int{1} -} - -func (x *MutableMetadataSave) GetAttributes() map[string]string { - if x != nil { - return x.Attributes - } - return nil -} - -func (x *MutableMetadataSave) GetAdminList() []string { - if x != nil { - return x.AdminList - } - return nil -} - -func (x *MutableMetadataSave) GetSuperAdminList() []string { - if x != nil { - return x.SuperAdminList - } - return nil -} - -// A Group's immutable metadata -type ImmutableMetadataSave struct { - state protoimpl.MessageState `protogen:"open.v1"` - CreatorInboxId string `protobuf:"bytes,1,opt,name=creator_inbox_id,json=creatorInboxId,proto3" json:"creator_inbox_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ImmutableMetadataSave) Reset() { - *x = ImmutableMetadataSave{} - mi := &file_device_sync_group_backup_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ImmutableMetadataSave) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ImmutableMetadataSave) ProtoMessage() {} - -func (x *ImmutableMetadataSave) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_group_backup_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ImmutableMetadataSave.ProtoReflect.Descriptor instead. -func (*ImmutableMetadataSave) Descriptor() ([]byte, []int) { - return file_device_sync_group_backup_proto_rawDescGZIP(), []int{2} -} - -func (x *ImmutableMetadataSave) GetCreatorInboxId() string { - if x != nil { - return x.CreatorInboxId - } - return "" -} - -var File_device_sync_group_backup_proto protoreflect.FileDescriptor - -const file_device_sync_group_backup_proto_rawDesc = "" + - "\n" + - "\x1edevice_sync/group_backup.proto\x12\x1dxmtp.device_sync.group_backup\"\xdb\a\n" + - "\tGroupSave\x12\x0e\n" + - "\x02id\x18\x01 \x01(\fR\x02id\x12\"\n" + - "\rcreated_at_ns\x18\x02 \x01(\x03R\vcreatedAtNs\x12b\n" + - "\x10membership_state\x18\x03 \x01(\x0e27.xmtp.device_sync.group_backup.GroupMembershipStateSaveR\x0fmembershipState\x12<\n" + - "\x1ainstallations_last_checked\x18\x04 \x01(\x03R\x18installationsLastChecked\x12)\n" + - "\x11added_by_inbox_id\x18\x05 \x01(\tR\x0eaddedByInboxId\x12\"\n" + - "\n" + - "welcome_id\x18\x06 \x01(\x03H\x00R\twelcomeId\x88\x01\x01\x12\"\n" + - "\rrotated_at_ns\x18\a \x01(\x03R\vrotatedAtNs\x12`\n" + - "\x11conversation_type\x18\b \x01(\x0e23.xmtp.device_sync.group_backup.ConversationTypeSaveR\x10conversationType\x12\x18\n" + - "\x05dm_id\x18\t \x01(\tH\x01R\x04dmId\x88\x01\x01\x12+\n" + - "\x0flast_message_ns\x18\n" + - " \x01(\x03H\x02R\rlastMessageNs\x88\x01\x01\x12>\n" + - "\x19message_disappear_from_ns\x18\v \x01(\x03H\x03R\x16messageDisappearFromNs\x88\x01\x01\x12:\n" + - "\x17message_disappear_in_ns\x18\f \x01(\x03H\x04R\x14messageDisappearInNs\x88\x01\x01\x12P\n" + - "\bmetadata\x18\r \x01(\v24.xmtp.device_sync.group_backup.ImmutableMetadataSaveR\bmetadata\x12]\n" + - "\x10mutable_metadata\x18\x0e \x01(\v22.xmtp.device_sync.group_backup.MutableMetadataSaveR\x0fmutableMetadata\x121\n" + - "\x12paused_for_version\x18\x0f \x01(\tH\x05R\x10pausedForVersion\x88\x01\x01B\r\n" + - "\v_welcome_idB\b\n" + - "\x06_dm_idB\x12\n" + - "\x10_last_message_nsB\x1c\n" + - "\x1a_message_disappear_from_nsB\x1a\n" + - "\x18_message_disappear_in_nsB\x15\n" + - "\x13_paused_for_version\"\x81\x02\n" + - "\x13MutableMetadataSave\x12b\n" + - "\n" + - "attributes\x18\x01 \x03(\v2B.xmtp.device_sync.group_backup.MutableMetadataSave.AttributesEntryR\n" + - "attributes\x12\x1d\n" + - "\n" + - "admin_list\x18\x02 \x03(\tR\tadminList\x12(\n" + - "\x10super_admin_list\x18\x03 \x03(\tR\x0esuperAdminList\x1a=\n" + - "\x0fAttributesEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\"A\n" + - "\x15ImmutableMetadataSave\x12(\n" + - "\x10creator_inbox_id\x18\x01 \x01(\tR\x0ecreatorInboxId*\x9d\x02\n" + - "\x18GroupMembershipStateSave\x12+\n" + - "'GROUP_MEMBERSHIP_STATE_SAVE_UNSPECIFIED\x10\x00\x12'\n" + - "#GROUP_MEMBERSHIP_STATE_SAVE_ALLOWED\x10\x01\x12(\n" + - "$GROUP_MEMBERSHIP_STATE_SAVE_REJECTED\x10\x02\x12'\n" + - "#GROUP_MEMBERSHIP_STATE_SAVE_PENDING\x10\x03\x12(\n" + - "$GROUP_MEMBERSHIP_STATE_SAVE_RESTORED\x10\x04\x12.\n" + - "*GROUP_MEMBERSHIP_STATE_SAVE_PENDING_REMOVE\x10\x05*\xa0\x01\n" + - "\x14ConversationTypeSave\x12&\n" + - "\"CONVERSATION_TYPE_SAVE_UNSPECIFIED\x10\x00\x12 \n" + - "\x1cCONVERSATION_TYPE_SAVE_GROUP\x10\x01\x12\x1d\n" + - "\x19CONVERSATION_TYPE_SAVE_DM\x10\x02\x12\x1f\n" + - "\x1bCONVERSATION_TYPE_SAVE_SYNC\x10\x03B\xa3\x02\n" + - ";org.xmtp.android.library.push.xmtp.device_sync.group_backupB\x10GroupBackupProtoP\x01ZDgithub.com/xmtp/example-notification-server-go/pkg/proto/device_sync\xa2\x02\x03XDG\xaa\x02\x1bXmtp.DeviceSync.GroupBackup\xca\x02\x1bXmtp\\DeviceSync\\GroupBackup\xe2\x02'Xmtp\\DeviceSync\\GroupBackup\\GPBMetadata\xea\x02\x1dXmtp::DeviceSync::GroupBackupb\x06proto3" - -var ( - file_device_sync_group_backup_proto_rawDescOnce sync.Once - file_device_sync_group_backup_proto_rawDescData []byte -) - -func file_device_sync_group_backup_proto_rawDescGZIP() []byte { - file_device_sync_group_backup_proto_rawDescOnce.Do(func() { - file_device_sync_group_backup_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_device_sync_group_backup_proto_rawDesc), len(file_device_sync_group_backup_proto_rawDesc))) - }) - return file_device_sync_group_backup_proto_rawDescData -} - -var file_device_sync_group_backup_proto_enumTypes = make([]protoimpl.EnumInfo, 2) -var file_device_sync_group_backup_proto_msgTypes = make([]protoimpl.MessageInfo, 4) -var file_device_sync_group_backup_proto_goTypes = []any{ - (GroupMembershipStateSave)(0), // 0: xmtp.device_sync.group_backup.GroupMembershipStateSave - (ConversationTypeSave)(0), // 1: xmtp.device_sync.group_backup.ConversationTypeSave - (*GroupSave)(nil), // 2: xmtp.device_sync.group_backup.GroupSave - (*MutableMetadataSave)(nil), // 3: xmtp.device_sync.group_backup.MutableMetadataSave - (*ImmutableMetadataSave)(nil), // 4: xmtp.device_sync.group_backup.ImmutableMetadataSave - nil, // 5: xmtp.device_sync.group_backup.MutableMetadataSave.AttributesEntry -} -var file_device_sync_group_backup_proto_depIdxs = []int32{ - 0, // 0: xmtp.device_sync.group_backup.GroupSave.membership_state:type_name -> xmtp.device_sync.group_backup.GroupMembershipStateSave - 1, // 1: xmtp.device_sync.group_backup.GroupSave.conversation_type:type_name -> xmtp.device_sync.group_backup.ConversationTypeSave - 4, // 2: xmtp.device_sync.group_backup.GroupSave.metadata:type_name -> xmtp.device_sync.group_backup.ImmutableMetadataSave - 3, // 3: xmtp.device_sync.group_backup.GroupSave.mutable_metadata:type_name -> xmtp.device_sync.group_backup.MutableMetadataSave - 5, // 4: xmtp.device_sync.group_backup.MutableMetadataSave.attributes:type_name -> xmtp.device_sync.group_backup.MutableMetadataSave.AttributesEntry - 5, // [5:5] is the sub-list for method output_type - 5, // [5:5] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name -} - -func init() { file_device_sync_group_backup_proto_init() } -func file_device_sync_group_backup_proto_init() { - if File_device_sync_group_backup_proto != nil { - return - } - file_device_sync_group_backup_proto_msgTypes[0].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_device_sync_group_backup_proto_rawDesc), len(file_device_sync_group_backup_proto_rawDesc)), - NumEnums: 2, - NumMessages: 4, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_device_sync_group_backup_proto_goTypes, - DependencyIndexes: file_device_sync_group_backup_proto_depIdxs, - EnumInfos: file_device_sync_group_backup_proto_enumTypes, - MessageInfos: file_device_sync_group_backup_proto_msgTypes, - }.Build() - File_device_sync_group_backup_proto = out.File - file_device_sync_group_backup_proto_goTypes = nil - file_device_sync_group_backup_proto_depIdxs = nil -} diff --git a/pkg/proto/device_sync/message_backup.pb.go b/pkg/proto/device_sync/message_backup.pb.go deleted file mode 100644 index f6dfdb89..00000000 --- a/pkg/proto/device_sync/message_backup.pb.go +++ /dev/null @@ -1,479 +0,0 @@ -// Definitions for backups - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: device_sync/message_backup.proto - -package device_sync - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Group message kind -type GroupMessageKindSave int32 - -const ( - GroupMessageKindSave_GROUP_MESSAGE_KIND_SAVE_UNSPECIFIED GroupMessageKindSave = 0 - GroupMessageKindSave_GROUP_MESSAGE_KIND_SAVE_APPLICATION GroupMessageKindSave = 1 - GroupMessageKindSave_GROUP_MESSAGE_KIND_SAVE_MEMBERSHIP_CHANGE GroupMessageKindSave = 2 -) - -// Enum value maps for GroupMessageKindSave. -var ( - GroupMessageKindSave_name = map[int32]string{ - 0: "GROUP_MESSAGE_KIND_SAVE_UNSPECIFIED", - 1: "GROUP_MESSAGE_KIND_SAVE_APPLICATION", - 2: "GROUP_MESSAGE_KIND_SAVE_MEMBERSHIP_CHANGE", - } - GroupMessageKindSave_value = map[string]int32{ - "GROUP_MESSAGE_KIND_SAVE_UNSPECIFIED": 0, - "GROUP_MESSAGE_KIND_SAVE_APPLICATION": 1, - "GROUP_MESSAGE_KIND_SAVE_MEMBERSHIP_CHANGE": 2, - } -) - -func (x GroupMessageKindSave) Enum() *GroupMessageKindSave { - p := new(GroupMessageKindSave) - *p = x - return p -} - -func (x GroupMessageKindSave) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (GroupMessageKindSave) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_message_backup_proto_enumTypes[0].Descriptor() -} - -func (GroupMessageKindSave) Type() protoreflect.EnumType { - return &file_device_sync_message_backup_proto_enumTypes[0] -} - -func (x GroupMessageKindSave) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use GroupMessageKindSave.Descriptor instead. -func (GroupMessageKindSave) EnumDescriptor() ([]byte, []int) { - return file_device_sync_message_backup_proto_rawDescGZIP(), []int{0} -} - -// Group message delivery status -type DeliveryStatusSave int32 - -const ( - DeliveryStatusSave_DELIVERY_STATUS_SAVE_UNSPECIFIED DeliveryStatusSave = 0 - DeliveryStatusSave_DELIVERY_STATUS_SAVE_UNPUBLISHED DeliveryStatusSave = 1 - DeliveryStatusSave_DELIVERY_STATUS_SAVE_PUBLISHED DeliveryStatusSave = 2 - DeliveryStatusSave_DELIVERY_STATUS_SAVE_FAILED DeliveryStatusSave = 3 -) - -// Enum value maps for DeliveryStatusSave. -var ( - DeliveryStatusSave_name = map[int32]string{ - 0: "DELIVERY_STATUS_SAVE_UNSPECIFIED", - 1: "DELIVERY_STATUS_SAVE_UNPUBLISHED", - 2: "DELIVERY_STATUS_SAVE_PUBLISHED", - 3: "DELIVERY_STATUS_SAVE_FAILED", - } - DeliveryStatusSave_value = map[string]int32{ - "DELIVERY_STATUS_SAVE_UNSPECIFIED": 0, - "DELIVERY_STATUS_SAVE_UNPUBLISHED": 1, - "DELIVERY_STATUS_SAVE_PUBLISHED": 2, - "DELIVERY_STATUS_SAVE_FAILED": 3, - } -) - -func (x DeliveryStatusSave) Enum() *DeliveryStatusSave { - p := new(DeliveryStatusSave) - *p = x - return p -} - -func (x DeliveryStatusSave) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (DeliveryStatusSave) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_message_backup_proto_enumTypes[1].Descriptor() -} - -func (DeliveryStatusSave) Type() protoreflect.EnumType { - return &file_device_sync_message_backup_proto_enumTypes[1] -} - -func (x DeliveryStatusSave) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use DeliveryStatusSave.Descriptor instead. -func (DeliveryStatusSave) EnumDescriptor() ([]byte, []int) { - return file_device_sync_message_backup_proto_rawDescGZIP(), []int{1} -} - -// Group message content type -// -// Deprecated: Marked as deprecated in device_sync/message_backup.proto. -type ContentTypeSave int32 - -const ( - ContentTypeSave_CONTENT_TYPE_SAVE_UNSPECIFIED ContentTypeSave = 0 - ContentTypeSave_CONTENT_TYPE_SAVE_UNKNOWN ContentTypeSave = 1 - ContentTypeSave_CONTENT_TYPE_SAVE_TEXT ContentTypeSave = 2 - ContentTypeSave_CONTENT_TYPE_SAVE_GROUP_MEMBERSHIP_CHANGE ContentTypeSave = 3 - ContentTypeSave_CONTENT_TYPE_SAVE_GROUP_UPDATED ContentTypeSave = 4 - ContentTypeSave_CONTENT_TYPE_SAVE_REACTION ContentTypeSave = 5 - ContentTypeSave_CONTENT_TYPE_SAVE_READ_RECEIPT ContentTypeSave = 6 - ContentTypeSave_CONTENT_TYPE_SAVE_REPLY ContentTypeSave = 7 - ContentTypeSave_CONTENT_TYPE_SAVE_ATTACHMENT ContentTypeSave = 8 - ContentTypeSave_CONTENT_TYPE_SAVE_REMOTE_ATTACHMENT ContentTypeSave = 9 - ContentTypeSave_CONTENT_TYPE_SAVE_TRANSACTION_REFERENCE ContentTypeSave = 10 -) - -// Enum value maps for ContentTypeSave. -var ( - ContentTypeSave_name = map[int32]string{ - 0: "CONTENT_TYPE_SAVE_UNSPECIFIED", - 1: "CONTENT_TYPE_SAVE_UNKNOWN", - 2: "CONTENT_TYPE_SAVE_TEXT", - 3: "CONTENT_TYPE_SAVE_GROUP_MEMBERSHIP_CHANGE", - 4: "CONTENT_TYPE_SAVE_GROUP_UPDATED", - 5: "CONTENT_TYPE_SAVE_REACTION", - 6: "CONTENT_TYPE_SAVE_READ_RECEIPT", - 7: "CONTENT_TYPE_SAVE_REPLY", - 8: "CONTENT_TYPE_SAVE_ATTACHMENT", - 9: "CONTENT_TYPE_SAVE_REMOTE_ATTACHMENT", - 10: "CONTENT_TYPE_SAVE_TRANSACTION_REFERENCE", - } - ContentTypeSave_value = map[string]int32{ - "CONTENT_TYPE_SAVE_UNSPECIFIED": 0, - "CONTENT_TYPE_SAVE_UNKNOWN": 1, - "CONTENT_TYPE_SAVE_TEXT": 2, - "CONTENT_TYPE_SAVE_GROUP_MEMBERSHIP_CHANGE": 3, - "CONTENT_TYPE_SAVE_GROUP_UPDATED": 4, - "CONTENT_TYPE_SAVE_REACTION": 5, - "CONTENT_TYPE_SAVE_READ_RECEIPT": 6, - "CONTENT_TYPE_SAVE_REPLY": 7, - "CONTENT_TYPE_SAVE_ATTACHMENT": 8, - "CONTENT_TYPE_SAVE_REMOTE_ATTACHMENT": 9, - "CONTENT_TYPE_SAVE_TRANSACTION_REFERENCE": 10, - } -) - -func (x ContentTypeSave) Enum() *ContentTypeSave { - p := new(ContentTypeSave) - *p = x - return p -} - -func (x ContentTypeSave) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ContentTypeSave) Descriptor() protoreflect.EnumDescriptor { - return file_device_sync_message_backup_proto_enumTypes[2].Descriptor() -} - -func (ContentTypeSave) Type() protoreflect.EnumType { - return &file_device_sync_message_backup_proto_enumTypes[2] -} - -func (x ContentTypeSave) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ContentTypeSave.Descriptor instead. -func (ContentTypeSave) EnumDescriptor() ([]byte, []int) { - return file_device_sync_message_backup_proto_rawDescGZIP(), []int{2} -} - -// Proto representation of a stored group message -type GroupMessageSave struct { - state protoimpl.MessageState `protogen:"open.v1"` - Id []byte `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` - GroupId []byte `protobuf:"bytes,2,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - DecryptedMessageBytes []byte `protobuf:"bytes,3,opt,name=decrypted_message_bytes,json=decryptedMessageBytes,proto3" json:"decrypted_message_bytes,omitempty"` - SentAtNs int64 `protobuf:"varint,4,opt,name=sent_at_ns,json=sentAtNs,proto3" json:"sent_at_ns,omitempty"` - Kind GroupMessageKindSave `protobuf:"varint,5,opt,name=kind,proto3,enum=xmtp.device_sync.message_backup.GroupMessageKindSave" json:"kind,omitempty"` - SenderInstallationId []byte `protobuf:"bytes,6,opt,name=sender_installation_id,json=senderInstallationId,proto3" json:"sender_installation_id,omitempty"` - SenderInboxId string `protobuf:"bytes,7,opt,name=sender_inbox_id,json=senderInboxId,proto3" json:"sender_inbox_id,omitempty"` - DeliveryStatus DeliveryStatusSave `protobuf:"varint,8,opt,name=delivery_status,json=deliveryStatus,proto3,enum=xmtp.device_sync.message_backup.DeliveryStatusSave" json:"delivery_status,omitempty"` - // Deprecated: Marked as deprecated in device_sync/message_backup.proto. - ContentTypeSave ContentTypeSave `protobuf:"varint,9,opt,name=content_type_save,json=contentTypeSave,proto3,enum=xmtp.device_sync.message_backup.ContentTypeSave" json:"content_type_save,omitempty"` - VersionMajor int32 `protobuf:"varint,10,opt,name=version_major,json=versionMajor,proto3" json:"version_major,omitempty"` - VersionMinor int32 `protobuf:"varint,11,opt,name=version_minor,json=versionMinor,proto3" json:"version_minor,omitempty"` - AuthorityId string `protobuf:"bytes,12,opt,name=authority_id,json=authorityId,proto3" json:"authority_id,omitempty"` - ReferenceId []byte `protobuf:"bytes,13,opt,name=reference_id,json=referenceId,proto3,oneof" json:"reference_id,omitempty"` - SequenceId *int64 `protobuf:"varint,14,opt,name=sequence_id,json=sequenceId,proto3,oneof" json:"sequence_id,omitempty"` - OriginatorId *int64 `protobuf:"varint,15,opt,name=originator_id,json=originatorId,proto3,oneof" json:"originator_id,omitempty"` - ContentType string `protobuf:"bytes,16,opt,name=content_type,json=contentType,proto3" json:"content_type,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMessageSave) Reset() { - *x = GroupMessageSave{} - mi := &file_device_sync_message_backup_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMessageSave) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMessageSave) ProtoMessage() {} - -func (x *GroupMessageSave) ProtoReflect() protoreflect.Message { - mi := &file_device_sync_message_backup_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMessageSave.ProtoReflect.Descriptor instead. -func (*GroupMessageSave) Descriptor() ([]byte, []int) { - return file_device_sync_message_backup_proto_rawDescGZIP(), []int{0} -} - -func (x *GroupMessageSave) GetId() []byte { - if x != nil { - return x.Id - } - return nil -} - -func (x *GroupMessageSave) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *GroupMessageSave) GetDecryptedMessageBytes() []byte { - if x != nil { - return x.DecryptedMessageBytes - } - return nil -} - -func (x *GroupMessageSave) GetSentAtNs() int64 { - if x != nil { - return x.SentAtNs - } - return 0 -} - -func (x *GroupMessageSave) GetKind() GroupMessageKindSave { - if x != nil { - return x.Kind - } - return GroupMessageKindSave_GROUP_MESSAGE_KIND_SAVE_UNSPECIFIED -} - -func (x *GroupMessageSave) GetSenderInstallationId() []byte { - if x != nil { - return x.SenderInstallationId - } - return nil -} - -func (x *GroupMessageSave) GetSenderInboxId() string { - if x != nil { - return x.SenderInboxId - } - return "" -} - -func (x *GroupMessageSave) GetDeliveryStatus() DeliveryStatusSave { - if x != nil { - return x.DeliveryStatus - } - return DeliveryStatusSave_DELIVERY_STATUS_SAVE_UNSPECIFIED -} - -// Deprecated: Marked as deprecated in device_sync/message_backup.proto. -func (x *GroupMessageSave) GetContentTypeSave() ContentTypeSave { - if x != nil { - return x.ContentTypeSave - } - return ContentTypeSave_CONTENT_TYPE_SAVE_UNSPECIFIED -} - -func (x *GroupMessageSave) GetVersionMajor() int32 { - if x != nil { - return x.VersionMajor - } - return 0 -} - -func (x *GroupMessageSave) GetVersionMinor() int32 { - if x != nil { - return x.VersionMinor - } - return 0 -} - -func (x *GroupMessageSave) GetAuthorityId() string { - if x != nil { - return x.AuthorityId - } - return "" -} - -func (x *GroupMessageSave) GetReferenceId() []byte { - if x != nil { - return x.ReferenceId - } - return nil -} - -func (x *GroupMessageSave) GetSequenceId() int64 { - if x != nil && x.SequenceId != nil { - return *x.SequenceId - } - return 0 -} - -func (x *GroupMessageSave) GetOriginatorId() int64 { - if x != nil && x.OriginatorId != nil { - return *x.OriginatorId - } - return 0 -} - -func (x *GroupMessageSave) GetContentType() string { - if x != nil { - return x.ContentType - } - return "" -} - -var File_device_sync_message_backup_proto protoreflect.FileDescriptor - -const file_device_sync_message_backup_proto_rawDesc = "" + - "\n" + - " device_sync/message_backup.proto\x12\x1fxmtp.device_sync.message_backup\"\xb7\x06\n" + - "\x10GroupMessageSave\x12\x0e\n" + - "\x02id\x18\x01 \x01(\fR\x02id\x12\x19\n" + - "\bgroup_id\x18\x02 \x01(\fR\agroupId\x126\n" + - "\x17decrypted_message_bytes\x18\x03 \x01(\fR\x15decryptedMessageBytes\x12\x1c\n" + - "\n" + - "sent_at_ns\x18\x04 \x01(\x03R\bsentAtNs\x12I\n" + - "\x04kind\x18\x05 \x01(\x0e25.xmtp.device_sync.message_backup.GroupMessageKindSaveR\x04kind\x124\n" + - "\x16sender_installation_id\x18\x06 \x01(\fR\x14senderInstallationId\x12&\n" + - "\x0fsender_inbox_id\x18\a \x01(\tR\rsenderInboxId\x12\\\n" + - "\x0fdelivery_status\x18\b \x01(\x0e23.xmtp.device_sync.message_backup.DeliveryStatusSaveR\x0edeliveryStatus\x12`\n" + - "\x11content_type_save\x18\t \x01(\x0e20.xmtp.device_sync.message_backup.ContentTypeSaveB\x02\x18\x01R\x0fcontentTypeSave\x12#\n" + - "\rversion_major\x18\n" + - " \x01(\x05R\fversionMajor\x12#\n" + - "\rversion_minor\x18\v \x01(\x05R\fversionMinor\x12!\n" + - "\fauthority_id\x18\f \x01(\tR\vauthorityId\x12&\n" + - "\freference_id\x18\r \x01(\fH\x00R\vreferenceId\x88\x01\x01\x12$\n" + - "\vsequence_id\x18\x0e \x01(\x03H\x01R\n" + - "sequenceId\x88\x01\x01\x12(\n" + - "\roriginator_id\x18\x0f \x01(\x03H\x02R\foriginatorId\x88\x01\x01\x12!\n" + - "\fcontent_type\x18\x10 \x01(\tR\vcontentTypeB\x0f\n" + - "\r_reference_idB\x0e\n" + - "\f_sequence_idB\x10\n" + - "\x0e_originator_id*\x97\x01\n" + - "\x14GroupMessageKindSave\x12'\n" + - "#GROUP_MESSAGE_KIND_SAVE_UNSPECIFIED\x10\x00\x12'\n" + - "#GROUP_MESSAGE_KIND_SAVE_APPLICATION\x10\x01\x12-\n" + - ")GROUP_MESSAGE_KIND_SAVE_MEMBERSHIP_CHANGE\x10\x02*\xa5\x01\n" + - "\x12DeliveryStatusSave\x12$\n" + - " DELIVERY_STATUS_SAVE_UNSPECIFIED\x10\x00\x12$\n" + - " DELIVERY_STATUS_SAVE_UNPUBLISHED\x10\x01\x12\"\n" + - "\x1eDELIVERY_STATUS_SAVE_PUBLISHED\x10\x02\x12\x1f\n" + - "\x1bDELIVERY_STATUS_SAVE_FAILED\x10\x03*\xa0\x03\n" + - "\x0fContentTypeSave\x12!\n" + - "\x1dCONTENT_TYPE_SAVE_UNSPECIFIED\x10\x00\x12\x1d\n" + - "\x19CONTENT_TYPE_SAVE_UNKNOWN\x10\x01\x12\x1a\n" + - "\x16CONTENT_TYPE_SAVE_TEXT\x10\x02\x12-\n" + - ")CONTENT_TYPE_SAVE_GROUP_MEMBERSHIP_CHANGE\x10\x03\x12#\n" + - "\x1fCONTENT_TYPE_SAVE_GROUP_UPDATED\x10\x04\x12\x1e\n" + - "\x1aCONTENT_TYPE_SAVE_REACTION\x10\x05\x12\"\n" + - "\x1eCONTENT_TYPE_SAVE_READ_RECEIPT\x10\x06\x12\x1b\n" + - "\x17CONTENT_TYPE_SAVE_REPLY\x10\a\x12 \n" + - "\x1cCONTENT_TYPE_SAVE_ATTACHMENT\x10\b\x12'\n" + - "#CONTENT_TYPE_SAVE_REMOTE_ATTACHMENT\x10\t\x12+\n" + - "'CONTENT_TYPE_SAVE_TRANSACTION_REFERENCE\x10\n" + - "\x1a\x02\x18\x01B\xaf\x02\n" + - "=org.xmtp.android.library.push.xmtp.device_sync.message_backupB\x12MessageBackupProtoP\x01ZDgithub.com/xmtp/example-notification-server-go/pkg/proto/device_sync\xa2\x02\x03XDM\xaa\x02\x1dXmtp.DeviceSync.MessageBackup\xca\x02\x1dXmtp\\DeviceSync\\MessageBackup\xe2\x02)Xmtp\\DeviceSync\\MessageBackup\\GPBMetadata\xea\x02\x1fXmtp::DeviceSync::MessageBackupb\x06proto3" - -var ( - file_device_sync_message_backup_proto_rawDescOnce sync.Once - file_device_sync_message_backup_proto_rawDescData []byte -) - -func file_device_sync_message_backup_proto_rawDescGZIP() []byte { - file_device_sync_message_backup_proto_rawDescOnce.Do(func() { - file_device_sync_message_backup_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_device_sync_message_backup_proto_rawDesc), len(file_device_sync_message_backup_proto_rawDesc))) - }) - return file_device_sync_message_backup_proto_rawDescData -} - -var file_device_sync_message_backup_proto_enumTypes = make([]protoimpl.EnumInfo, 3) -var file_device_sync_message_backup_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_device_sync_message_backup_proto_goTypes = []any{ - (GroupMessageKindSave)(0), // 0: xmtp.device_sync.message_backup.GroupMessageKindSave - (DeliveryStatusSave)(0), // 1: xmtp.device_sync.message_backup.DeliveryStatusSave - (ContentTypeSave)(0), // 2: xmtp.device_sync.message_backup.ContentTypeSave - (*GroupMessageSave)(nil), // 3: xmtp.device_sync.message_backup.GroupMessageSave -} -var file_device_sync_message_backup_proto_depIdxs = []int32{ - 0, // 0: xmtp.device_sync.message_backup.GroupMessageSave.kind:type_name -> xmtp.device_sync.message_backup.GroupMessageKindSave - 1, // 1: xmtp.device_sync.message_backup.GroupMessageSave.delivery_status:type_name -> xmtp.device_sync.message_backup.DeliveryStatusSave - 2, // 2: xmtp.device_sync.message_backup.GroupMessageSave.content_type_save:type_name -> xmtp.device_sync.message_backup.ContentTypeSave - 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_device_sync_message_backup_proto_init() } -func file_device_sync_message_backup_proto_init() { - if File_device_sync_message_backup_proto != nil { - return - } - file_device_sync_message_backup_proto_msgTypes[0].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_device_sync_message_backup_proto_rawDesc), len(file_device_sync_message_backup_proto_rawDesc)), - NumEnums: 3, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_device_sync_message_backup_proto_goTypes, - DependencyIndexes: file_device_sync_message_backup_proto_depIdxs, - EnumInfos: file_device_sync_message_backup_proto_enumTypes, - MessageInfos: file_device_sync_message_backup_proto_msgTypes, - }.Build() - File_device_sync_message_backup_proto = out.File - file_device_sync_message_backup_proto_goTypes = nil - file_device_sync_message_backup_proto_depIdxs = nil -} diff --git a/pkg/proto/identity/api/v1/identity.pb.go b/pkg/proto/identity/api/v1/identity.pb.go deleted file mode 100644 index 2e2cdc32..00000000 --- a/pkg/proto/identity/api/v1/identity.pb.go +++ /dev/null @@ -1,944 +0,0 @@ -// Message API - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: identity/api/v1/identity.proto - -package apiv1 - -import ( - _ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options" - associations "github.com/xmtp/example-notification-server-go/pkg/proto/identity/associations" - _ "google.golang.org/genproto/googleapis/api/annotations" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type VerifySmartContractWalletSignaturesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Signatures []*VerifySmartContractWalletSignatureRequestSignature `protobuf:"bytes,1,rep,name=signatures,proto3" json:"signatures,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *VerifySmartContractWalletSignaturesRequest) Reset() { - *x = VerifySmartContractWalletSignaturesRequest{} - mi := &file_identity_api_v1_identity_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *VerifySmartContractWalletSignaturesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*VerifySmartContractWalletSignaturesRequest) ProtoMessage() {} - -func (x *VerifySmartContractWalletSignaturesRequest) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use VerifySmartContractWalletSignaturesRequest.ProtoReflect.Descriptor instead. -func (*VerifySmartContractWalletSignaturesRequest) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{0} -} - -func (x *VerifySmartContractWalletSignaturesRequest) GetSignatures() []*VerifySmartContractWalletSignatureRequestSignature { - if x != nil { - return x.Signatures - } - return nil -} - -type VerifySmartContractWalletSignatureRequestSignature struct { - state protoimpl.MessageState `protogen:"open.v1"` - // CAIP-10 string - // https://github.com/ChainAgnostic/CAIPs/blob/main/CAIPs/caip-10.md - AccountId string `protobuf:"bytes,1,opt,name=account_id,json=accountId,proto3" json:"account_id,omitempty"` - // Specify the block number to verify the signature against - BlockNumber *uint64 `protobuf:"varint,2,opt,name=block_number,json=blockNumber,proto3,oneof" json:"block_number,omitempty"` - // The signature bytes - Signature []byte `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` - Hash []byte `protobuf:"bytes,4,opt,name=hash,proto3" json:"hash,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *VerifySmartContractWalletSignatureRequestSignature) Reset() { - *x = VerifySmartContractWalletSignatureRequestSignature{} - mi := &file_identity_api_v1_identity_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *VerifySmartContractWalletSignatureRequestSignature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*VerifySmartContractWalletSignatureRequestSignature) ProtoMessage() {} - -func (x *VerifySmartContractWalletSignatureRequestSignature) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use VerifySmartContractWalletSignatureRequestSignature.ProtoReflect.Descriptor instead. -func (*VerifySmartContractWalletSignatureRequestSignature) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{1} -} - -func (x *VerifySmartContractWalletSignatureRequestSignature) GetAccountId() string { - if x != nil { - return x.AccountId - } - return "" -} - -func (x *VerifySmartContractWalletSignatureRequestSignature) GetBlockNumber() uint64 { - if x != nil && x.BlockNumber != nil { - return *x.BlockNumber - } - return 0 -} - -func (x *VerifySmartContractWalletSignatureRequestSignature) GetSignature() []byte { - if x != nil { - return x.Signature - } - return nil -} - -func (x *VerifySmartContractWalletSignatureRequestSignature) GetHash() []byte { - if x != nil { - return x.Hash - } - return nil -} - -type VerifySmartContractWalletSignaturesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*VerifySmartContractWalletSignaturesResponse_ValidationResponse `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *VerifySmartContractWalletSignaturesResponse) Reset() { - *x = VerifySmartContractWalletSignaturesResponse{} - mi := &file_identity_api_v1_identity_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *VerifySmartContractWalletSignaturesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*VerifySmartContractWalletSignaturesResponse) ProtoMessage() {} - -func (x *VerifySmartContractWalletSignaturesResponse) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use VerifySmartContractWalletSignaturesResponse.ProtoReflect.Descriptor instead. -func (*VerifySmartContractWalletSignaturesResponse) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{2} -} - -func (x *VerifySmartContractWalletSignaturesResponse) GetResponses() []*VerifySmartContractWalletSignaturesResponse_ValidationResponse { - if x != nil { - return x.Responses - } - return nil -} - -// Publishes an identity update to the network -type PublishIdentityUpdateRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - IdentityUpdate *associations.IdentityUpdate `protobuf:"bytes,1,opt,name=identity_update,json=identityUpdate,proto3" json:"identity_update,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishIdentityUpdateRequest) Reset() { - *x = PublishIdentityUpdateRequest{} - mi := &file_identity_api_v1_identity_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishIdentityUpdateRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishIdentityUpdateRequest) ProtoMessage() {} - -func (x *PublishIdentityUpdateRequest) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishIdentityUpdateRequest.ProtoReflect.Descriptor instead. -func (*PublishIdentityUpdateRequest) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{3} -} - -func (x *PublishIdentityUpdateRequest) GetIdentityUpdate() *associations.IdentityUpdate { - if x != nil { - return x.IdentityUpdate - } - return nil -} - -// The response when an identity update is published -type PublishIdentityUpdateResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishIdentityUpdateResponse) Reset() { - *x = PublishIdentityUpdateResponse{} - mi := &file_identity_api_v1_identity_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishIdentityUpdateResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishIdentityUpdateResponse) ProtoMessage() {} - -func (x *PublishIdentityUpdateResponse) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishIdentityUpdateResponse.ProtoReflect.Descriptor instead. -func (*PublishIdentityUpdateResponse) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{4} -} - -// Get all updates for an identity since the specified time -type GetIdentityUpdatesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*GetIdentityUpdatesRequest_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesRequest) Reset() { - *x = GetIdentityUpdatesRequest{} - mi := &file_identity_api_v1_identity_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesRequest) ProtoMessage() {} - -func (x *GetIdentityUpdatesRequest) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesRequest.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesRequest) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{5} -} - -func (x *GetIdentityUpdatesRequest) GetRequests() []*GetIdentityUpdatesRequest_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Returns all log entries for the requested identities -type GetIdentityUpdatesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*GetIdentityUpdatesResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesResponse) Reset() { - *x = GetIdentityUpdatesResponse{} - mi := &file_identity_api_v1_identity_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesResponse) ProtoMessage() {} - -func (x *GetIdentityUpdatesResponse) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesResponse.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesResponse) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{6} -} - -func (x *GetIdentityUpdatesResponse) GetResponses() []*GetIdentityUpdatesResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -// Request to retrieve the XIDs for the given addresses -type GetInboxIdsRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*GetInboxIdsRequest_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetInboxIdsRequest) Reset() { - *x = GetInboxIdsRequest{} - mi := &file_identity_api_v1_identity_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetInboxIdsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetInboxIdsRequest) ProtoMessage() {} - -func (x *GetInboxIdsRequest) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetInboxIdsRequest.ProtoReflect.Descriptor instead. -func (*GetInboxIdsRequest) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{7} -} - -func (x *GetInboxIdsRequest) GetRequests() []*GetInboxIdsRequest_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Response with the XIDs for the requested addresses -type GetInboxIdsResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*GetInboxIdsResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetInboxIdsResponse) Reset() { - *x = GetInboxIdsResponse{} - mi := &file_identity_api_v1_identity_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetInboxIdsResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetInboxIdsResponse) ProtoMessage() {} - -func (x *GetInboxIdsResponse) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetInboxIdsResponse.ProtoReflect.Descriptor instead. -func (*GetInboxIdsResponse) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{8} -} - -func (x *GetInboxIdsResponse) GetResponses() []*GetInboxIdsResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -type VerifySmartContractWalletSignaturesResponse_ValidationResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - IsValid bool `protobuf:"varint,1,opt,name=is_valid,json=isValid,proto3" json:"is_valid,omitempty"` - BlockNumber *uint64 `protobuf:"varint,2,opt,name=block_number,json=blockNumber,proto3,oneof" json:"block_number,omitempty"` - Error *string `protobuf:"bytes,3,opt,name=error,proto3,oneof" json:"error,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *VerifySmartContractWalletSignaturesResponse_ValidationResponse) Reset() { - *x = VerifySmartContractWalletSignaturesResponse_ValidationResponse{} - mi := &file_identity_api_v1_identity_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *VerifySmartContractWalletSignaturesResponse_ValidationResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*VerifySmartContractWalletSignaturesResponse_ValidationResponse) ProtoMessage() {} - -func (x *VerifySmartContractWalletSignaturesResponse_ValidationResponse) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use VerifySmartContractWalletSignaturesResponse_ValidationResponse.ProtoReflect.Descriptor instead. -func (*VerifySmartContractWalletSignaturesResponse_ValidationResponse) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{2, 0} -} - -func (x *VerifySmartContractWalletSignaturesResponse_ValidationResponse) GetIsValid() bool { - if x != nil { - return x.IsValid - } - return false -} - -func (x *VerifySmartContractWalletSignaturesResponse_ValidationResponse) GetBlockNumber() uint64 { - if x != nil && x.BlockNumber != nil { - return *x.BlockNumber - } - return 0 -} - -func (x *VerifySmartContractWalletSignaturesResponse_ValidationResponse) GetError() string { - if x != nil && x.Error != nil { - return *x.Error - } - return "" -} - -// Points to the last entry the client has received. The sequence_id should be -// set to 0 if the client has not received anything. -type GetIdentityUpdatesRequest_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - InboxId string `protobuf:"bytes,1,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - SequenceId uint64 `protobuf:"varint,2,opt,name=sequence_id,json=sequenceId,proto3" json:"sequence_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesRequest_Request) Reset() { - *x = GetIdentityUpdatesRequest_Request{} - mi := &file_identity_api_v1_identity_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesRequest_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesRequest_Request) ProtoMessage() {} - -func (x *GetIdentityUpdatesRequest_Request) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesRequest_Request.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesRequest_Request) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{5, 0} -} - -func (x *GetIdentityUpdatesRequest_Request) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -func (x *GetIdentityUpdatesRequest_Request) GetSequenceId() uint64 { - if x != nil { - return x.SequenceId - } - return 0 -} - -// A single entry in the XID log on the server. -type GetIdentityUpdatesResponse_IdentityUpdateLog struct { - state protoimpl.MessageState `protogen:"open.v1"` - SequenceId uint64 `protobuf:"varint,1,opt,name=sequence_id,json=sequenceId,proto3" json:"sequence_id,omitempty"` - ServerTimestampNs uint64 `protobuf:"varint,2,opt,name=server_timestamp_ns,json=serverTimestampNs,proto3" json:"server_timestamp_ns,omitempty"` - Update *associations.IdentityUpdate `protobuf:"bytes,3,opt,name=update,proto3" json:"update,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesResponse_IdentityUpdateLog) Reset() { - *x = GetIdentityUpdatesResponse_IdentityUpdateLog{} - mi := &file_identity_api_v1_identity_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesResponse_IdentityUpdateLog) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesResponse_IdentityUpdateLog) ProtoMessage() {} - -func (x *GetIdentityUpdatesResponse_IdentityUpdateLog) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesResponse_IdentityUpdateLog.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesResponse_IdentityUpdateLog) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{6, 0} -} - -func (x *GetIdentityUpdatesResponse_IdentityUpdateLog) GetSequenceId() uint64 { - if x != nil { - return x.SequenceId - } - return 0 -} - -func (x *GetIdentityUpdatesResponse_IdentityUpdateLog) GetServerTimestampNs() uint64 { - if x != nil { - return x.ServerTimestampNs - } - return 0 -} - -func (x *GetIdentityUpdatesResponse_IdentityUpdateLog) GetUpdate() *associations.IdentityUpdate { - if x != nil { - return x.Update - } - return nil -} - -// The update log for a single identity, starting after the last cursor -type GetIdentityUpdatesResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - InboxId string `protobuf:"bytes,1,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - Updates []*GetIdentityUpdatesResponse_IdentityUpdateLog `protobuf:"bytes,2,rep,name=updates,proto3" json:"updates,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesResponse_Response) Reset() { - *x = GetIdentityUpdatesResponse_Response{} - mi := &file_identity_api_v1_identity_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesResponse_Response) ProtoMessage() {} - -func (x *GetIdentityUpdatesResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[12] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesResponse_Response.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesResponse_Response) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{6, 1} -} - -func (x *GetIdentityUpdatesResponse_Response) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -func (x *GetIdentityUpdatesResponse_Response) GetUpdates() []*GetIdentityUpdatesResponse_IdentityUpdateLog { - if x != nil { - return x.Updates - } - return nil -} - -// A single request for a given address -type GetInboxIdsRequest_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"` - IdentifierKind associations.IdentifierKind `protobuf:"varint,2,opt,name=identifier_kind,json=identifierKind,proto3,enum=xmtp.identity.associations.IdentifierKind" json:"identifier_kind,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetInboxIdsRequest_Request) Reset() { - *x = GetInboxIdsRequest_Request{} - mi := &file_identity_api_v1_identity_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetInboxIdsRequest_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetInboxIdsRequest_Request) ProtoMessage() {} - -func (x *GetInboxIdsRequest_Request) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[13] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetInboxIdsRequest_Request.ProtoReflect.Descriptor instead. -func (*GetInboxIdsRequest_Request) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{7, 0} -} - -func (x *GetInboxIdsRequest_Request) GetIdentifier() string { - if x != nil { - return x.Identifier - } - return "" -} - -func (x *GetInboxIdsRequest_Request) GetIdentifierKind() associations.IdentifierKind { - if x != nil { - return x.IdentifierKind - } - return associations.IdentifierKind(0) -} - -// A single response for a given address -type GetInboxIdsResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"` - InboxId *string `protobuf:"bytes,2,opt,name=inbox_id,json=inboxId,proto3,oneof" json:"inbox_id,omitempty"` - IdentifierKind associations.IdentifierKind `protobuf:"varint,3,opt,name=identifier_kind,json=identifierKind,proto3,enum=xmtp.identity.associations.IdentifierKind" json:"identifier_kind,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetInboxIdsResponse_Response) Reset() { - *x = GetInboxIdsResponse_Response{} - mi := &file_identity_api_v1_identity_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetInboxIdsResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetInboxIdsResponse_Response) ProtoMessage() {} - -func (x *GetInboxIdsResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_identity_api_v1_identity_proto_msgTypes[14] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetInboxIdsResponse_Response.ProtoReflect.Descriptor instead. -func (*GetInboxIdsResponse_Response) Descriptor() ([]byte, []int) { - return file_identity_api_v1_identity_proto_rawDescGZIP(), []int{8, 0} -} - -func (x *GetInboxIdsResponse_Response) GetIdentifier() string { - if x != nil { - return x.Identifier - } - return "" -} - -func (x *GetInboxIdsResponse_Response) GetInboxId() string { - if x != nil && x.InboxId != nil { - return *x.InboxId - } - return "" -} - -func (x *GetInboxIdsResponse_Response) GetIdentifierKind() associations.IdentifierKind { - if x != nil { - return x.IdentifierKind - } - return associations.IdentifierKind(0) -} - -var File_identity_api_v1_identity_proto protoreflect.FileDescriptor - -const file_identity_api_v1_identity_proto_rawDesc = "" + - "\n" + - "\x1eidentity/api/v1/identity.proto\x12\x14xmtp.identity.api.v1\x1a\x1cgoogle/api/annotations.proto\x1a'identity/associations/association.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\"\x96\x01\n" + - "*VerifySmartContractWalletSignaturesRequest\x12h\n" + - "\n" + - "signatures\x18\x01 \x03(\v2H.xmtp.identity.api.v1.VerifySmartContractWalletSignatureRequestSignatureR\n" + - "signatures\"\xbe\x01\n" + - "2VerifySmartContractWalletSignatureRequestSignature\x12\x1d\n" + - "\n" + - "account_id\x18\x01 \x01(\tR\taccountId\x12&\n" + - "\fblock_number\x18\x02 \x01(\x04H\x00R\vblockNumber\x88\x01\x01\x12\x1c\n" + - "\tsignature\x18\x03 \x01(\fR\tsignature\x12\x12\n" + - "\x04hash\x18\x04 \x01(\fR\x04hashB\x0f\n" + - "\r_block_number\"\xb1\x02\n" + - "+VerifySmartContractWalletSignaturesResponse\x12r\n" + - "\tresponses\x18\x01 \x03(\v2T.xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse.ValidationResponseR\tresponses\x1a\x8d\x01\n" + - "\x12ValidationResponse\x12\x19\n" + - "\bis_valid\x18\x01 \x01(\bR\aisValid\x12&\n" + - "\fblock_number\x18\x02 \x01(\x04H\x00R\vblockNumber\x88\x01\x01\x12\x19\n" + - "\x05error\x18\x03 \x01(\tH\x01R\x05error\x88\x01\x01B\x0f\n" + - "\r_block_numberB\b\n" + - "\x06_error\"s\n" + - "\x1cPublishIdentityUpdateRequest\x12S\n" + - "\x0fidentity_update\x18\x01 \x01(\v2*.xmtp.identity.associations.IdentityUpdateR\x0eidentityUpdate\"\x1f\n" + - "\x1dPublishIdentityUpdateResponse\"\xb7\x01\n" + - "\x19GetIdentityUpdatesRequest\x12S\n" + - "\brequests\x18\x01 \x03(\v27.xmtp.identity.api.v1.GetIdentityUpdatesRequest.RequestR\brequests\x1aE\n" + - "\aRequest\x12\x19\n" + - "\binbox_id\x18\x01 \x01(\tR\ainboxId\x12\x1f\n" + - "\vsequence_id\x18\x02 \x01(\x04R\n" + - "sequenceId\"\xa6\x03\n" + - "\x1aGetIdentityUpdatesResponse\x12W\n" + - "\tresponses\x18\x01 \x03(\v29.xmtp.identity.api.v1.GetIdentityUpdatesResponse.ResponseR\tresponses\x1a\xa8\x01\n" + - "\x11IdentityUpdateLog\x12\x1f\n" + - "\vsequence_id\x18\x01 \x01(\x04R\n" + - "sequenceId\x12.\n" + - "\x13server_timestamp_ns\x18\x02 \x01(\x04R\x11serverTimestampNs\x12B\n" + - "\x06update\x18\x03 \x01(\v2*.xmtp.identity.associations.IdentityUpdateR\x06update\x1a\x83\x01\n" + - "\bResponse\x12\x19\n" + - "\binbox_id\x18\x01 \x01(\tR\ainboxId\x12\\\n" + - "\aupdates\x18\x02 \x03(\v2B.xmtp.identity.api.v1.GetIdentityUpdatesResponse.IdentityUpdateLogR\aupdates\"\xe2\x01\n" + - "\x12GetInboxIdsRequest\x12L\n" + - "\brequests\x18\x01 \x03(\v20.xmtp.identity.api.v1.GetInboxIdsRequest.RequestR\brequests\x1a~\n" + - "\aRequest\x12\x1e\n" + - "\n" + - "identifier\x18\x01 \x01(\tR\n" + - "identifier\x12S\n" + - "\x0fidentifier_kind\x18\x02 \x01(\x0e2*.xmtp.identity.associations.IdentifierKindR\x0eidentifierKind\"\x96\x02\n" + - "\x13GetInboxIdsResponse\x12P\n" + - "\tresponses\x18\x01 \x03(\v22.xmtp.identity.api.v1.GetInboxIdsResponse.ResponseR\tresponses\x1a\xac\x01\n" + - "\bResponse\x12\x1e\n" + - "\n" + - "identifier\x18\x01 \x01(\tR\n" + - "identifier\x12\x1e\n" + - "\binbox_id\x18\x02 \x01(\tH\x00R\ainboxId\x88\x01\x01\x12S\n" + - "\x0fidentifier_kind\x18\x03 \x01(\x0e2*.xmtp.identity.associations.IdentifierKindR\x0eidentifierKindB\v\n" + - "\t_inbox_id2\xe3\x05\n" + - "\vIdentityApi\x12\xb1\x01\n" + - "\x15PublishIdentityUpdate\x122.xmtp.identity.api.v1.PublishIdentityUpdateRequest\x1a3.xmtp.identity.api.v1.PublishIdentityUpdateResponse\"/\x82\xd3\xe4\x93\x02):\x01*\"$/identity/v1/publish-identity-update\x12\xa5\x01\n" + - "\x12GetIdentityUpdates\x12/.xmtp.identity.api.v1.GetIdentityUpdatesRequest\x1a0.xmtp.identity.api.v1.GetIdentityUpdatesResponse\",\x82\xd3\xe4\x93\x02&:\x01*\"!/identity/v1/get-identity-updates\x12\x89\x01\n" + - "\vGetInboxIds\x12(.xmtp.identity.api.v1.GetInboxIdsRequest\x1a).xmtp.identity.api.v1.GetInboxIdsResponse\"%\x82\xd3\xe4\x93\x02\x1f:\x01*\"\x1a/identity/v1/get-inbox-ids\x12\xeb\x01\n" + - "#VerifySmartContractWalletSignatures\x12@.xmtp.identity.api.v1.VerifySmartContractWalletSignaturesRequest\x1aA.xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse\"?\x82\xd3\xe4\x93\x029:\x01*\"4/identity/v1/verify-smart-contract-wallet-signaturesB\x9d\x02\x92A\x14\x12\x12\n" + - "\vIdentityApi2\x031.0\n" + - "2org.xmtp.android.library.push.xmtp.identity.api.v1B\rIdentityProtoP\x01ZNgithub.com/xmtp/example-notification-server-go/pkg/proto/identity/api/v1;apiv1\xa2\x02\x03XIA\xaa\x02\x14Xmtp.Identity.Api.V1\xca\x02\x14Xmtp\\Identity\\Api\\V1\xe2\x02 Xmtp\\Identity\\Api\\V1\\GPBMetadata\xea\x02\x17Xmtp::Identity::Api::V1b\x06proto3" - -var ( - file_identity_api_v1_identity_proto_rawDescOnce sync.Once - file_identity_api_v1_identity_proto_rawDescData []byte -) - -func file_identity_api_v1_identity_proto_rawDescGZIP() []byte { - file_identity_api_v1_identity_proto_rawDescOnce.Do(func() { - file_identity_api_v1_identity_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_identity_api_v1_identity_proto_rawDesc), len(file_identity_api_v1_identity_proto_rawDesc))) - }) - return file_identity_api_v1_identity_proto_rawDescData -} - -var file_identity_api_v1_identity_proto_msgTypes = make([]protoimpl.MessageInfo, 15) -var file_identity_api_v1_identity_proto_goTypes = []any{ - (*VerifySmartContractWalletSignaturesRequest)(nil), // 0: xmtp.identity.api.v1.VerifySmartContractWalletSignaturesRequest - (*VerifySmartContractWalletSignatureRequestSignature)(nil), // 1: xmtp.identity.api.v1.VerifySmartContractWalletSignatureRequestSignature - (*VerifySmartContractWalletSignaturesResponse)(nil), // 2: xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse - (*PublishIdentityUpdateRequest)(nil), // 3: xmtp.identity.api.v1.PublishIdentityUpdateRequest - (*PublishIdentityUpdateResponse)(nil), // 4: xmtp.identity.api.v1.PublishIdentityUpdateResponse - (*GetIdentityUpdatesRequest)(nil), // 5: xmtp.identity.api.v1.GetIdentityUpdatesRequest - (*GetIdentityUpdatesResponse)(nil), // 6: xmtp.identity.api.v1.GetIdentityUpdatesResponse - (*GetInboxIdsRequest)(nil), // 7: xmtp.identity.api.v1.GetInboxIdsRequest - (*GetInboxIdsResponse)(nil), // 8: xmtp.identity.api.v1.GetInboxIdsResponse - (*VerifySmartContractWalletSignaturesResponse_ValidationResponse)(nil), // 9: xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse.ValidationResponse - (*GetIdentityUpdatesRequest_Request)(nil), // 10: xmtp.identity.api.v1.GetIdentityUpdatesRequest.Request - (*GetIdentityUpdatesResponse_IdentityUpdateLog)(nil), // 11: xmtp.identity.api.v1.GetIdentityUpdatesResponse.IdentityUpdateLog - (*GetIdentityUpdatesResponse_Response)(nil), // 12: xmtp.identity.api.v1.GetIdentityUpdatesResponse.Response - (*GetInboxIdsRequest_Request)(nil), // 13: xmtp.identity.api.v1.GetInboxIdsRequest.Request - (*GetInboxIdsResponse_Response)(nil), // 14: xmtp.identity.api.v1.GetInboxIdsResponse.Response - (*associations.IdentityUpdate)(nil), // 15: xmtp.identity.associations.IdentityUpdate - (associations.IdentifierKind)(0), // 16: xmtp.identity.associations.IdentifierKind -} -var file_identity_api_v1_identity_proto_depIdxs = []int32{ - 1, // 0: xmtp.identity.api.v1.VerifySmartContractWalletSignaturesRequest.signatures:type_name -> xmtp.identity.api.v1.VerifySmartContractWalletSignatureRequestSignature - 9, // 1: xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse.responses:type_name -> xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse.ValidationResponse - 15, // 2: xmtp.identity.api.v1.PublishIdentityUpdateRequest.identity_update:type_name -> xmtp.identity.associations.IdentityUpdate - 10, // 3: xmtp.identity.api.v1.GetIdentityUpdatesRequest.requests:type_name -> xmtp.identity.api.v1.GetIdentityUpdatesRequest.Request - 12, // 4: xmtp.identity.api.v1.GetIdentityUpdatesResponse.responses:type_name -> xmtp.identity.api.v1.GetIdentityUpdatesResponse.Response - 13, // 5: xmtp.identity.api.v1.GetInboxIdsRequest.requests:type_name -> xmtp.identity.api.v1.GetInboxIdsRequest.Request - 14, // 6: xmtp.identity.api.v1.GetInboxIdsResponse.responses:type_name -> xmtp.identity.api.v1.GetInboxIdsResponse.Response - 15, // 7: xmtp.identity.api.v1.GetIdentityUpdatesResponse.IdentityUpdateLog.update:type_name -> xmtp.identity.associations.IdentityUpdate - 11, // 8: xmtp.identity.api.v1.GetIdentityUpdatesResponse.Response.updates:type_name -> xmtp.identity.api.v1.GetIdentityUpdatesResponse.IdentityUpdateLog - 16, // 9: xmtp.identity.api.v1.GetInboxIdsRequest.Request.identifier_kind:type_name -> xmtp.identity.associations.IdentifierKind - 16, // 10: xmtp.identity.api.v1.GetInboxIdsResponse.Response.identifier_kind:type_name -> xmtp.identity.associations.IdentifierKind - 3, // 11: xmtp.identity.api.v1.IdentityApi.PublishIdentityUpdate:input_type -> xmtp.identity.api.v1.PublishIdentityUpdateRequest - 5, // 12: xmtp.identity.api.v1.IdentityApi.GetIdentityUpdates:input_type -> xmtp.identity.api.v1.GetIdentityUpdatesRequest - 7, // 13: xmtp.identity.api.v1.IdentityApi.GetInboxIds:input_type -> xmtp.identity.api.v1.GetInboxIdsRequest - 0, // 14: xmtp.identity.api.v1.IdentityApi.VerifySmartContractWalletSignatures:input_type -> xmtp.identity.api.v1.VerifySmartContractWalletSignaturesRequest - 4, // 15: xmtp.identity.api.v1.IdentityApi.PublishIdentityUpdate:output_type -> xmtp.identity.api.v1.PublishIdentityUpdateResponse - 6, // 16: xmtp.identity.api.v1.IdentityApi.GetIdentityUpdates:output_type -> xmtp.identity.api.v1.GetIdentityUpdatesResponse - 8, // 17: xmtp.identity.api.v1.IdentityApi.GetInboxIds:output_type -> xmtp.identity.api.v1.GetInboxIdsResponse - 2, // 18: xmtp.identity.api.v1.IdentityApi.VerifySmartContractWalletSignatures:output_type -> xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse - 15, // [15:19] is the sub-list for method output_type - 11, // [11:15] is the sub-list for method input_type - 11, // [11:11] is the sub-list for extension type_name - 11, // [11:11] is the sub-list for extension extendee - 0, // [0:11] is the sub-list for field type_name -} - -func init() { file_identity_api_v1_identity_proto_init() } -func file_identity_api_v1_identity_proto_init() { - if File_identity_api_v1_identity_proto != nil { - return - } - file_identity_api_v1_identity_proto_msgTypes[1].OneofWrappers = []any{} - file_identity_api_v1_identity_proto_msgTypes[9].OneofWrappers = []any{} - file_identity_api_v1_identity_proto_msgTypes[14].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_identity_api_v1_identity_proto_rawDesc), len(file_identity_api_v1_identity_proto_rawDesc)), - NumEnums: 0, - NumMessages: 15, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_identity_api_v1_identity_proto_goTypes, - DependencyIndexes: file_identity_api_v1_identity_proto_depIdxs, - MessageInfos: file_identity_api_v1_identity_proto_msgTypes, - }.Build() - File_identity_api_v1_identity_proto = out.File - file_identity_api_v1_identity_proto_goTypes = nil - file_identity_api_v1_identity_proto_depIdxs = nil -} diff --git a/pkg/proto/identity/api/v1/identity_grpc.pb.go b/pkg/proto/identity/api/v1/identity_grpc.pb.go deleted file mode 100644 index 6b12b8db..00000000 --- a/pkg/proto/identity/api/v1/identity_grpc.pb.go +++ /dev/null @@ -1,236 +0,0 @@ -// Message API - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: identity/api/v1/identity.proto - -package apiv1 - -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 ( - IdentityApi_PublishIdentityUpdate_FullMethodName = "/xmtp.identity.api.v1.IdentityApi/PublishIdentityUpdate" - IdentityApi_GetIdentityUpdates_FullMethodName = "/xmtp.identity.api.v1.IdentityApi/GetIdentityUpdates" - IdentityApi_GetInboxIds_FullMethodName = "/xmtp.identity.api.v1.IdentityApi/GetInboxIds" - IdentityApi_VerifySmartContractWalletSignatures_FullMethodName = "/xmtp.identity.api.v1.IdentityApi/VerifySmartContractWalletSignatures" -) - -// IdentityApiClient is the client API for IdentityApi 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 IdentityApiClient interface { - // Publishes an identity update for an XID or wallet. An identity update may - // consist of multiple identity actions that have been batch signed. - PublishIdentityUpdate(ctx context.Context, in *PublishIdentityUpdateRequest, opts ...grpc.CallOption) (*PublishIdentityUpdateResponse, error) - // Used to check for changes related to members of a group. - // Would return an array of any new installations associated with the wallet - // address, and any revocations that have happened. - GetIdentityUpdates(ctx context.Context, in *GetIdentityUpdatesRequest, opts ...grpc.CallOption) (*GetIdentityUpdatesResponse, error) - // Retrieve the XIDs for the given addresses - GetInboxIds(ctx context.Context, in *GetInboxIdsRequest, opts ...grpc.CallOption) (*GetInboxIdsResponse, error) - // Verify an unverified smart contract wallet signature - VerifySmartContractWalletSignatures(ctx context.Context, in *VerifySmartContractWalletSignaturesRequest, opts ...grpc.CallOption) (*VerifySmartContractWalletSignaturesResponse, error) -} - -type identityApiClient struct { - cc grpc.ClientConnInterface -} - -func NewIdentityApiClient(cc grpc.ClientConnInterface) IdentityApiClient { - return &identityApiClient{cc} -} - -func (c *identityApiClient) PublishIdentityUpdate(ctx context.Context, in *PublishIdentityUpdateRequest, opts ...grpc.CallOption) (*PublishIdentityUpdateResponse, error) { - out := new(PublishIdentityUpdateResponse) - err := c.cc.Invoke(ctx, IdentityApi_PublishIdentityUpdate_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *identityApiClient) GetIdentityUpdates(ctx context.Context, in *GetIdentityUpdatesRequest, opts ...grpc.CallOption) (*GetIdentityUpdatesResponse, error) { - out := new(GetIdentityUpdatesResponse) - err := c.cc.Invoke(ctx, IdentityApi_GetIdentityUpdates_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *identityApiClient) GetInboxIds(ctx context.Context, in *GetInboxIdsRequest, opts ...grpc.CallOption) (*GetInboxIdsResponse, error) { - out := new(GetInboxIdsResponse) - err := c.cc.Invoke(ctx, IdentityApi_GetInboxIds_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *identityApiClient) VerifySmartContractWalletSignatures(ctx context.Context, in *VerifySmartContractWalletSignaturesRequest, opts ...grpc.CallOption) (*VerifySmartContractWalletSignaturesResponse, error) { - out := new(VerifySmartContractWalletSignaturesResponse) - err := c.cc.Invoke(ctx, IdentityApi_VerifySmartContractWalletSignatures_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// IdentityApiServer is the server API for IdentityApi service. -// All implementations must embed UnimplementedIdentityApiServer -// for forward compatibility -type IdentityApiServer interface { - // Publishes an identity update for an XID or wallet. An identity update may - // consist of multiple identity actions that have been batch signed. - PublishIdentityUpdate(context.Context, *PublishIdentityUpdateRequest) (*PublishIdentityUpdateResponse, error) - // Used to check for changes related to members of a group. - // Would return an array of any new installations associated with the wallet - // address, and any revocations that have happened. - GetIdentityUpdates(context.Context, *GetIdentityUpdatesRequest) (*GetIdentityUpdatesResponse, error) - // Retrieve the XIDs for the given addresses - GetInboxIds(context.Context, *GetInboxIdsRequest) (*GetInboxIdsResponse, error) - // Verify an unverified smart contract wallet signature - VerifySmartContractWalletSignatures(context.Context, *VerifySmartContractWalletSignaturesRequest) (*VerifySmartContractWalletSignaturesResponse, error) - mustEmbedUnimplementedIdentityApiServer() -} - -// UnimplementedIdentityApiServer must be embedded to have forward compatible implementations. -type UnimplementedIdentityApiServer struct { -} - -func (UnimplementedIdentityApiServer) PublishIdentityUpdate(context.Context, *PublishIdentityUpdateRequest) (*PublishIdentityUpdateResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method PublishIdentityUpdate not implemented") -} -func (UnimplementedIdentityApiServer) GetIdentityUpdates(context.Context, *GetIdentityUpdatesRequest) (*GetIdentityUpdatesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetIdentityUpdates not implemented") -} -func (UnimplementedIdentityApiServer) GetInboxIds(context.Context, *GetInboxIdsRequest) (*GetInboxIdsResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetInboxIds not implemented") -} -func (UnimplementedIdentityApiServer) VerifySmartContractWalletSignatures(context.Context, *VerifySmartContractWalletSignaturesRequest) (*VerifySmartContractWalletSignaturesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method VerifySmartContractWalletSignatures not implemented") -} -func (UnimplementedIdentityApiServer) mustEmbedUnimplementedIdentityApiServer() {} - -// UnsafeIdentityApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to IdentityApiServer will -// result in compilation errors. -type UnsafeIdentityApiServer interface { - mustEmbedUnimplementedIdentityApiServer() -} - -func RegisterIdentityApiServer(s grpc.ServiceRegistrar, srv IdentityApiServer) { - s.RegisterService(&IdentityApi_ServiceDesc, srv) -} - -func _IdentityApi_PublishIdentityUpdate_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(PublishIdentityUpdateRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IdentityApiServer).PublishIdentityUpdate(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: IdentityApi_PublishIdentityUpdate_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IdentityApiServer).PublishIdentityUpdate(ctx, req.(*PublishIdentityUpdateRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _IdentityApi_GetIdentityUpdates_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetIdentityUpdatesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IdentityApiServer).GetIdentityUpdates(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: IdentityApi_GetIdentityUpdates_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IdentityApiServer).GetIdentityUpdates(ctx, req.(*GetIdentityUpdatesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _IdentityApi_GetInboxIds_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetInboxIdsRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IdentityApiServer).GetInboxIds(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: IdentityApi_GetInboxIds_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IdentityApiServer).GetInboxIds(ctx, req.(*GetInboxIdsRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _IdentityApi_VerifySmartContractWalletSignatures_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(VerifySmartContractWalletSignaturesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(IdentityApiServer).VerifySmartContractWalletSignatures(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: IdentityApi_VerifySmartContractWalletSignatures_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(IdentityApiServer).VerifySmartContractWalletSignatures(ctx, req.(*VerifySmartContractWalletSignaturesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// IdentityApi_ServiceDesc is the grpc.ServiceDesc for IdentityApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var IdentityApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.identity.api.v1.IdentityApi", - HandlerType: (*IdentityApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "PublishIdentityUpdate", - Handler: _IdentityApi_PublishIdentityUpdate_Handler, - }, - { - MethodName: "GetIdentityUpdates", - Handler: _IdentityApi_GetIdentityUpdates_Handler, - }, - { - MethodName: "GetInboxIds", - Handler: _IdentityApi_GetInboxIds_Handler, - }, - { - MethodName: "VerifySmartContractWalletSignatures", - Handler: _IdentityApi_VerifySmartContractWalletSignatures_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "identity/api/v1/identity.proto", -} diff --git a/pkg/proto/identity/associations/association.pb.go b/pkg/proto/identity/associations/association.pb.go deleted file mode 100644 index f34308be..00000000 --- a/pkg/proto/identity/associations/association.pb.go +++ /dev/null @@ -1,1129 +0,0 @@ -// Payloads to be signed for identity associations - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: identity/associations/association.proto - -package associations - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// List of identity kinds -type IdentifierKind int32 - -const ( - IdentifierKind_IDENTIFIER_KIND_UNSPECIFIED IdentifierKind = 0 // Ethereum on old clients - IdentifierKind_IDENTIFIER_KIND_ETHEREUM IdentifierKind = 1 - IdentifierKind_IDENTIFIER_KIND_PASSKEY IdentifierKind = 2 -) - -// Enum value maps for IdentifierKind. -var ( - IdentifierKind_name = map[int32]string{ - 0: "IDENTIFIER_KIND_UNSPECIFIED", - 1: "IDENTIFIER_KIND_ETHEREUM", - 2: "IDENTIFIER_KIND_PASSKEY", - } - IdentifierKind_value = map[string]int32{ - "IDENTIFIER_KIND_UNSPECIFIED": 0, - "IDENTIFIER_KIND_ETHEREUM": 1, - "IDENTIFIER_KIND_PASSKEY": 2, - } -) - -func (x IdentifierKind) Enum() *IdentifierKind { - p := new(IdentifierKind) - *p = x - return p -} - -func (x IdentifierKind) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (IdentifierKind) Descriptor() protoreflect.EnumDescriptor { - return file_identity_associations_association_proto_enumTypes[0].Descriptor() -} - -func (IdentifierKind) Type() protoreflect.EnumType { - return &file_identity_associations_association_proto_enumTypes[0] -} - -func (x IdentifierKind) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use IdentifierKind.Descriptor instead. -func (IdentifierKind) EnumDescriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{0} -} - -// The identifier for a member of an XID -type MemberIdentifier struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Kind: - // - // *MemberIdentifier_EthereumAddress - // *MemberIdentifier_InstallationPublicKey - // *MemberIdentifier_Passkey - Kind isMemberIdentifier_Kind `protobuf_oneof:"kind"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MemberIdentifier) Reset() { - *x = MemberIdentifier{} - mi := &file_identity_associations_association_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MemberIdentifier) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MemberIdentifier) ProtoMessage() {} - -func (x *MemberIdentifier) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MemberIdentifier.ProtoReflect.Descriptor instead. -func (*MemberIdentifier) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{0} -} - -func (x *MemberIdentifier) GetKind() isMemberIdentifier_Kind { - if x != nil { - return x.Kind - } - return nil -} - -func (x *MemberIdentifier) GetEthereumAddress() string { - if x != nil { - if x, ok := x.Kind.(*MemberIdentifier_EthereumAddress); ok { - return x.EthereumAddress - } - } - return "" -} - -func (x *MemberIdentifier) GetInstallationPublicKey() []byte { - if x != nil { - if x, ok := x.Kind.(*MemberIdentifier_InstallationPublicKey); ok { - return x.InstallationPublicKey - } - } - return nil -} - -func (x *MemberIdentifier) GetPasskey() *Passkey { - if x != nil { - if x, ok := x.Kind.(*MemberIdentifier_Passkey); ok { - return x.Passkey - } - } - return nil -} - -type isMemberIdentifier_Kind interface { - isMemberIdentifier_Kind() -} - -type MemberIdentifier_EthereumAddress struct { - EthereumAddress string `protobuf:"bytes,1,opt,name=ethereum_address,json=ethereumAddress,proto3,oneof"` -} - -type MemberIdentifier_InstallationPublicKey struct { - InstallationPublicKey []byte `protobuf:"bytes,2,opt,name=installation_public_key,json=installationPublicKey,proto3,oneof"` -} - -type MemberIdentifier_Passkey struct { - Passkey *Passkey `protobuf:"bytes,3,opt,name=passkey,proto3,oneof"` -} - -func (*MemberIdentifier_EthereumAddress) isMemberIdentifier_Kind() {} - -func (*MemberIdentifier_InstallationPublicKey) isMemberIdentifier_Kind() {} - -func (*MemberIdentifier_Passkey) isMemberIdentifier_Kind() {} - -// Passkey identifier -type Passkey struct { - state protoimpl.MessageState `protogen:"open.v1"` - Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` - RelyingParty *string `protobuf:"bytes,2,opt,name=relying_party,json=relyingParty,proto3,oneof" json:"relying_party,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Passkey) Reset() { - *x = Passkey{} - mi := &file_identity_associations_association_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Passkey) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Passkey) ProtoMessage() {} - -func (x *Passkey) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Passkey.ProtoReflect.Descriptor instead. -func (*Passkey) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{1} -} - -func (x *Passkey) GetKey() []byte { - if x != nil { - return x.Key - } - return nil -} - -func (x *Passkey) GetRelyingParty() string { - if x != nil && x.RelyingParty != nil { - return *x.RelyingParty - } - return "" -} - -// single member that optionally indicates the member that added them -type Member struct { - state protoimpl.MessageState `protogen:"open.v1"` - Identifier *MemberIdentifier `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"` - AddedByEntity *MemberIdentifier `protobuf:"bytes,2,opt,name=added_by_entity,json=addedByEntity,proto3,oneof" json:"added_by_entity,omitempty"` - ClientTimestampNs *uint64 `protobuf:"varint,3,opt,name=client_timestamp_ns,json=clientTimestampNs,proto3,oneof" json:"client_timestamp_ns,omitempty"` - AddedOnChainId *uint64 `protobuf:"varint,4,opt,name=added_on_chain_id,json=addedOnChainId,proto3,oneof" json:"added_on_chain_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Member) Reset() { - *x = Member{} - mi := &file_identity_associations_association_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Member) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Member) ProtoMessage() {} - -func (x *Member) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Member.ProtoReflect.Descriptor instead. -func (*Member) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{2} -} - -func (x *Member) GetIdentifier() *MemberIdentifier { - if x != nil { - return x.Identifier - } - return nil -} - -func (x *Member) GetAddedByEntity() *MemberIdentifier { - if x != nil { - return x.AddedByEntity - } - return nil -} - -func (x *Member) GetClientTimestampNs() uint64 { - if x != nil && x.ClientTimestampNs != nil { - return *x.ClientTimestampNs - } - return 0 -} - -func (x *Member) GetAddedOnChainId() uint64 { - if x != nil && x.AddedOnChainId != nil { - return *x.AddedOnChainId - } - return 0 -} - -// The first entry of any XID log. The XID must be deterministically derivable -// from the address and nonce. -// The recovery address defaults to the initial associated_address unless -// there is a subsequent ChangeRecoveryAddress in the log. -type CreateInbox struct { - state protoimpl.MessageState `protogen:"open.v1"` - InitialIdentifier string `protobuf:"bytes,1,opt,name=initial_identifier,json=initialIdentifier,proto3" json:"initial_identifier,omitempty"` - Nonce uint64 `protobuf:"varint,2,opt,name=nonce,proto3" json:"nonce,omitempty"` - InitialIdentifierSignature *Signature `protobuf:"bytes,3,opt,name=initial_identifier_signature,json=initialIdentifierSignature,proto3" json:"initial_identifier_signature,omitempty"` // Must be an addressable member - InitialIdentifierKind IdentifierKind `protobuf:"varint,4,opt,name=initial_identifier_kind,json=initialIdentifierKind,proto3,enum=xmtp.identity.associations.IdentifierKind" json:"initial_identifier_kind,omitempty"` - // Should be provided if identifier kind is passkey - RelyingParty *string `protobuf:"bytes,5,opt,name=relying_party,json=relyingParty,proto3,oneof" json:"relying_party,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *CreateInbox) Reset() { - *x = CreateInbox{} - mi := &file_identity_associations_association_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *CreateInbox) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CreateInbox) ProtoMessage() {} - -func (x *CreateInbox) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CreateInbox.ProtoReflect.Descriptor instead. -func (*CreateInbox) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{3} -} - -func (x *CreateInbox) GetInitialIdentifier() string { - if x != nil { - return x.InitialIdentifier - } - return "" -} - -func (x *CreateInbox) GetNonce() uint64 { - if x != nil { - return x.Nonce - } - return 0 -} - -func (x *CreateInbox) GetInitialIdentifierSignature() *Signature { - if x != nil { - return x.InitialIdentifierSignature - } - return nil -} - -func (x *CreateInbox) GetInitialIdentifierKind() IdentifierKind { - if x != nil { - return x.InitialIdentifierKind - } - return IdentifierKind_IDENTIFIER_KIND_UNSPECIFIED -} - -func (x *CreateInbox) GetRelyingParty() string { - if x != nil && x.RelyingParty != nil { - return *x.RelyingParty - } - return "" -} - -// Adds a new member for an XID - either an addressable member such as a -// wallet, or an installation acting on behalf of an address. -// A key-pair that has been associated with one role MUST not be permitted to be -// associated with a different role. -type AddAssociation struct { - state protoimpl.MessageState `protogen:"open.v1"` - NewMemberIdentifier *MemberIdentifier `protobuf:"bytes,1,opt,name=new_member_identifier,json=newMemberIdentifier,proto3" json:"new_member_identifier,omitempty"` - ExistingMemberSignature *Signature `protobuf:"bytes,2,opt,name=existing_member_signature,json=existingMemberSignature,proto3" json:"existing_member_signature,omitempty"` - NewMemberSignature *Signature `protobuf:"bytes,3,opt,name=new_member_signature,json=newMemberSignature,proto3" json:"new_member_signature,omitempty"` - // Should be provided if identifier kind is passkey - RelyingParty *string `protobuf:"bytes,4,opt,name=relying_party,json=relyingParty,proto3,oneof" json:"relying_party,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AddAssociation) Reset() { - *x = AddAssociation{} - mi := &file_identity_associations_association_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AddAssociation) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AddAssociation) ProtoMessage() {} - -func (x *AddAssociation) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AddAssociation.ProtoReflect.Descriptor instead. -func (*AddAssociation) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{4} -} - -func (x *AddAssociation) GetNewMemberIdentifier() *MemberIdentifier { - if x != nil { - return x.NewMemberIdentifier - } - return nil -} - -func (x *AddAssociation) GetExistingMemberSignature() *Signature { - if x != nil { - return x.ExistingMemberSignature - } - return nil -} - -func (x *AddAssociation) GetNewMemberSignature() *Signature { - if x != nil { - return x.NewMemberSignature - } - return nil -} - -func (x *AddAssociation) GetRelyingParty() string { - if x != nil && x.RelyingParty != nil { - return *x.RelyingParty - } - return "" -} - -// Revokes a member from an XID. The recovery address must sign the revocation. -type RevokeAssociation struct { - state protoimpl.MessageState `protogen:"open.v1"` - MemberToRevoke *MemberIdentifier `protobuf:"bytes,1,opt,name=member_to_revoke,json=memberToRevoke,proto3" json:"member_to_revoke,omitempty"` - RecoveryIdentifierSignature *Signature `protobuf:"bytes,2,opt,name=recovery_identifier_signature,json=recoveryIdentifierSignature,proto3" json:"recovery_identifier_signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RevokeAssociation) Reset() { - *x = RevokeAssociation{} - mi := &file_identity_associations_association_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RevokeAssociation) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RevokeAssociation) ProtoMessage() {} - -func (x *RevokeAssociation) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RevokeAssociation.ProtoReflect.Descriptor instead. -func (*RevokeAssociation) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{5} -} - -func (x *RevokeAssociation) GetMemberToRevoke() *MemberIdentifier { - if x != nil { - return x.MemberToRevoke - } - return nil -} - -func (x *RevokeAssociation) GetRecoveryIdentifierSignature() *Signature { - if x != nil { - return x.RecoveryIdentifierSignature - } - return nil -} - -// Changes the recovery identifier for an XID. The recovery identifier is not required -// to be a member of the XID. In addition to being able to add members, the -// recovery identifier can also revoke members. -type ChangeRecoveryAddress struct { - state protoimpl.MessageState `protogen:"open.v1"` - NewRecoveryIdentifier string `protobuf:"bytes,1,opt,name=new_recovery_identifier,json=newRecoveryIdentifier,proto3" json:"new_recovery_identifier,omitempty"` - ExistingRecoveryIdentifierSignature *Signature `protobuf:"bytes,2,opt,name=existing_recovery_identifier_signature,json=existingRecoveryIdentifierSignature,proto3" json:"existing_recovery_identifier_signature,omitempty"` - NewRecoveryIdentifierKind IdentifierKind `protobuf:"varint,3,opt,name=new_recovery_identifier_kind,json=newRecoveryIdentifierKind,proto3,enum=xmtp.identity.associations.IdentifierKind" json:"new_recovery_identifier_kind,omitempty"` - // Should be provided if identifier kind is passkey - RelyingParty *string `protobuf:"bytes,4,opt,name=relying_party,json=relyingParty,proto3,oneof" json:"relying_party,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ChangeRecoveryAddress) Reset() { - *x = ChangeRecoveryAddress{} - mi := &file_identity_associations_association_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ChangeRecoveryAddress) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ChangeRecoveryAddress) ProtoMessage() {} - -func (x *ChangeRecoveryAddress) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ChangeRecoveryAddress.ProtoReflect.Descriptor instead. -func (*ChangeRecoveryAddress) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{6} -} - -func (x *ChangeRecoveryAddress) GetNewRecoveryIdentifier() string { - if x != nil { - return x.NewRecoveryIdentifier - } - return "" -} - -func (x *ChangeRecoveryAddress) GetExistingRecoveryIdentifierSignature() *Signature { - if x != nil { - return x.ExistingRecoveryIdentifierSignature - } - return nil -} - -func (x *ChangeRecoveryAddress) GetNewRecoveryIdentifierKind() IdentifierKind { - if x != nil { - return x.NewRecoveryIdentifierKind - } - return IdentifierKind_IDENTIFIER_KIND_UNSPECIFIED -} - -func (x *ChangeRecoveryAddress) GetRelyingParty() string { - if x != nil && x.RelyingParty != nil { - return *x.RelyingParty - } - return "" -} - -// A single identity operation -type IdentityAction struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Kind: - // - // *IdentityAction_CreateInbox - // *IdentityAction_Add - // *IdentityAction_Revoke - // *IdentityAction_ChangeRecoveryAddress - Kind isIdentityAction_Kind `protobuf_oneof:"kind"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *IdentityAction) Reset() { - *x = IdentityAction{} - mi := &file_identity_associations_association_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *IdentityAction) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*IdentityAction) ProtoMessage() {} - -func (x *IdentityAction) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use IdentityAction.ProtoReflect.Descriptor instead. -func (*IdentityAction) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{7} -} - -func (x *IdentityAction) GetKind() isIdentityAction_Kind { - if x != nil { - return x.Kind - } - return nil -} - -func (x *IdentityAction) GetCreateInbox() *CreateInbox { - if x != nil { - if x, ok := x.Kind.(*IdentityAction_CreateInbox); ok { - return x.CreateInbox - } - } - return nil -} - -func (x *IdentityAction) GetAdd() *AddAssociation { - if x != nil { - if x, ok := x.Kind.(*IdentityAction_Add); ok { - return x.Add - } - } - return nil -} - -func (x *IdentityAction) GetRevoke() *RevokeAssociation { - if x != nil { - if x, ok := x.Kind.(*IdentityAction_Revoke); ok { - return x.Revoke - } - } - return nil -} - -func (x *IdentityAction) GetChangeRecoveryAddress() *ChangeRecoveryAddress { - if x != nil { - if x, ok := x.Kind.(*IdentityAction_ChangeRecoveryAddress); ok { - return x.ChangeRecoveryAddress - } - } - return nil -} - -type isIdentityAction_Kind interface { - isIdentityAction_Kind() -} - -type IdentityAction_CreateInbox struct { - CreateInbox *CreateInbox `protobuf:"bytes,1,opt,name=create_inbox,json=createInbox,proto3,oneof"` -} - -type IdentityAction_Add struct { - Add *AddAssociation `protobuf:"bytes,2,opt,name=add,proto3,oneof"` -} - -type IdentityAction_Revoke struct { - Revoke *RevokeAssociation `protobuf:"bytes,3,opt,name=revoke,proto3,oneof"` -} - -type IdentityAction_ChangeRecoveryAddress struct { - ChangeRecoveryAddress *ChangeRecoveryAddress `protobuf:"bytes,4,opt,name=change_recovery_address,json=changeRecoveryAddress,proto3,oneof"` -} - -func (*IdentityAction_CreateInbox) isIdentityAction_Kind() {} - -func (*IdentityAction_Add) isIdentityAction_Kind() {} - -func (*IdentityAction_Revoke) isIdentityAction_Kind() {} - -func (*IdentityAction_ChangeRecoveryAddress) isIdentityAction_Kind() {} - -// One or more identity actions that were signed together. -// Example: [CreateXid, AddAssociation, ChangeRecoveryAddress] -// 1. The batched signature text is created by concatenating the signature text -// of each association together with a separator, '\n\n\n'. -// 2. The user signs this concatenated result. -// 3. The resulting signature is added to each association proto where relevant. -// The same signature may be used for multiple associations in the array. -type IdentityUpdate struct { - state protoimpl.MessageState `protogen:"open.v1"` - Actions []*IdentityAction `protobuf:"bytes,1,rep,name=actions,proto3" json:"actions,omitempty"` - ClientTimestampNs uint64 `protobuf:"varint,2,opt,name=client_timestamp_ns,json=clientTimestampNs,proto3" json:"client_timestamp_ns,omitempty"` - InboxId string `protobuf:"bytes,3,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *IdentityUpdate) Reset() { - *x = IdentityUpdate{} - mi := &file_identity_associations_association_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *IdentityUpdate) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*IdentityUpdate) ProtoMessage() {} - -func (x *IdentityUpdate) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use IdentityUpdate.ProtoReflect.Descriptor instead. -func (*IdentityUpdate) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{8} -} - -func (x *IdentityUpdate) GetActions() []*IdentityAction { - if x != nil { - return x.Actions - } - return nil -} - -func (x *IdentityUpdate) GetClientTimestampNs() uint64 { - if x != nil { - return x.ClientTimestampNs - } - return 0 -} - -func (x *IdentityUpdate) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -// Map of members belonging to an inbox_id -type MemberMap struct { - state protoimpl.MessageState `protogen:"open.v1"` - Key *MemberIdentifier `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` - Value *Member `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MemberMap) Reset() { - *x = MemberMap{} - mi := &file_identity_associations_association_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MemberMap) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MemberMap) ProtoMessage() {} - -func (x *MemberMap) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MemberMap.ProtoReflect.Descriptor instead. -func (*MemberMap) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{9} -} - -func (x *MemberMap) GetKey() *MemberIdentifier { - if x != nil { - return x.Key - } - return nil -} - -func (x *MemberMap) GetValue() *Member { - if x != nil { - return x.Value - } - return nil -} - -// A final association state resulting from multiple `IdentityUpdates` -type AssociationState struct { - state protoimpl.MessageState `protogen:"open.v1"` - InboxId string `protobuf:"bytes,1,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - Members []*MemberMap `protobuf:"bytes,2,rep,name=members,proto3" json:"members,omitempty"` - RecoveryIdentifier string `protobuf:"bytes,3,opt,name=recovery_identifier,json=recoveryIdentifier,proto3" json:"recovery_identifier,omitempty"` - SeenSignatures [][]byte `protobuf:"bytes,4,rep,name=seen_signatures,json=seenSignatures,proto3" json:"seen_signatures,omitempty"` - RecoveryIdentifierKind IdentifierKind `protobuf:"varint,5,opt,name=recovery_identifier_kind,json=recoveryIdentifierKind,proto3,enum=xmtp.identity.associations.IdentifierKind" json:"recovery_identifier_kind,omitempty"` - // Should be provided if identifier kind is passkey - RelyingParty *string `protobuf:"bytes,6,opt,name=relying_party,json=relyingParty,proto3,oneof" json:"relying_party,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AssociationState) Reset() { - *x = AssociationState{} - mi := &file_identity_associations_association_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AssociationState) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AssociationState) ProtoMessage() {} - -func (x *AssociationState) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AssociationState.ProtoReflect.Descriptor instead. -func (*AssociationState) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{10} -} - -func (x *AssociationState) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -func (x *AssociationState) GetMembers() []*MemberMap { - if x != nil { - return x.Members - } - return nil -} - -func (x *AssociationState) GetRecoveryIdentifier() string { - if x != nil { - return x.RecoveryIdentifier - } - return "" -} - -func (x *AssociationState) GetSeenSignatures() [][]byte { - if x != nil { - return x.SeenSignatures - } - return nil -} - -func (x *AssociationState) GetRecoveryIdentifierKind() IdentifierKind { - if x != nil { - return x.RecoveryIdentifierKind - } - return IdentifierKind_IDENTIFIER_KIND_UNSPECIFIED -} - -func (x *AssociationState) GetRelyingParty() string { - if x != nil && x.RelyingParty != nil { - return *x.RelyingParty - } - return "" -} - -// / state diff between two final AssociationStates -type AssociationStateDiff struct { - state protoimpl.MessageState `protogen:"open.v1"` - NewMembers []*MemberIdentifier `protobuf:"bytes,1,rep,name=new_members,json=newMembers,proto3" json:"new_members,omitempty"` - RemovedMembers []*MemberIdentifier `protobuf:"bytes,2,rep,name=removed_members,json=removedMembers,proto3" json:"removed_members,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AssociationStateDiff) Reset() { - *x = AssociationStateDiff{} - mi := &file_identity_associations_association_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AssociationStateDiff) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AssociationStateDiff) ProtoMessage() {} - -func (x *AssociationStateDiff) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_association_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AssociationStateDiff.ProtoReflect.Descriptor instead. -func (*AssociationStateDiff) Descriptor() ([]byte, []int) { - return file_identity_associations_association_proto_rawDescGZIP(), []int{11} -} - -func (x *AssociationStateDiff) GetNewMembers() []*MemberIdentifier { - if x != nil { - return x.NewMembers - } - return nil -} - -func (x *AssociationStateDiff) GetRemovedMembers() []*MemberIdentifier { - if x != nil { - return x.RemovedMembers - } - return nil -} - -var File_identity_associations_association_proto protoreflect.FileDescriptor - -const file_identity_associations_association_proto_rawDesc = "" + - "\n" + - "'identity/associations/association.proto\x12\x1axmtp.identity.associations\x1a%identity/associations/signature.proto\"\xc2\x01\n" + - "\x10MemberIdentifier\x12+\n" + - "\x10ethereum_address\x18\x01 \x01(\tH\x00R\x0fethereumAddress\x128\n" + - "\x17installation_public_key\x18\x02 \x01(\fH\x00R\x15installationPublicKey\x12?\n" + - "\apasskey\x18\x03 \x01(\v2#.xmtp.identity.associations.PasskeyH\x00R\apasskeyB\x06\n" + - "\x04kind\"W\n" + - "\aPasskey\x12\x10\n" + - "\x03key\x18\x01 \x01(\fR\x03key\x12(\n" + - "\rrelying_party\x18\x02 \x01(\tH\x00R\frelyingParty\x88\x01\x01B\x10\n" + - "\x0e_relying_party\"\xd8\x02\n" + - "\x06Member\x12L\n" + - "\n" + - "identifier\x18\x01 \x01(\v2,.xmtp.identity.associations.MemberIdentifierR\n" + - "identifier\x12Y\n" + - "\x0fadded_by_entity\x18\x02 \x01(\v2,.xmtp.identity.associations.MemberIdentifierH\x00R\raddedByEntity\x88\x01\x01\x123\n" + - "\x13client_timestamp_ns\x18\x03 \x01(\x04H\x01R\x11clientTimestampNs\x88\x01\x01\x12.\n" + - "\x11added_on_chain_id\x18\x04 \x01(\x04H\x02R\x0eaddedOnChainId\x88\x01\x01B\x12\n" + - "\x10_added_by_entityB\x16\n" + - "\x14_client_timestamp_nsB\x14\n" + - "\x12_added_on_chain_id\"\xdb\x02\n" + - "\vCreateInbox\x12-\n" + - "\x12initial_identifier\x18\x01 \x01(\tR\x11initialIdentifier\x12\x14\n" + - "\x05nonce\x18\x02 \x01(\x04R\x05nonce\x12g\n" + - "\x1cinitial_identifier_signature\x18\x03 \x01(\v2%.xmtp.identity.associations.SignatureR\x1ainitialIdentifierSignature\x12b\n" + - "\x17initial_identifier_kind\x18\x04 \x01(\x0e2*.xmtp.identity.associations.IdentifierKindR\x15initialIdentifierKind\x12(\n" + - "\rrelying_party\x18\x05 \x01(\tH\x00R\frelyingParty\x88\x01\x01B\x10\n" + - "\x0e_relying_party\"\xea\x02\n" + - "\x0eAddAssociation\x12`\n" + - "\x15new_member_identifier\x18\x01 \x01(\v2,.xmtp.identity.associations.MemberIdentifierR\x13newMemberIdentifier\x12a\n" + - "\x19existing_member_signature\x18\x02 \x01(\v2%.xmtp.identity.associations.SignatureR\x17existingMemberSignature\x12W\n" + - "\x14new_member_signature\x18\x03 \x01(\v2%.xmtp.identity.associations.SignatureR\x12newMemberSignature\x12(\n" + - "\rrelying_party\x18\x04 \x01(\tH\x00R\frelyingParty\x88\x01\x01B\x10\n" + - "\x0e_relying_party\"\xd6\x01\n" + - "\x11RevokeAssociation\x12V\n" + - "\x10member_to_revoke\x18\x01 \x01(\v2,.xmtp.identity.associations.MemberIdentifierR\x0ememberToRevoke\x12i\n" + - "\x1drecovery_identifier_signature\x18\x02 \x01(\v2%.xmtp.identity.associations.SignatureR\x1brecoveryIdentifierSignature\"\xf4\x02\n" + - "\x15ChangeRecoveryAddress\x126\n" + - "\x17new_recovery_identifier\x18\x01 \x01(\tR\x15newRecoveryIdentifier\x12z\n" + - "&existing_recovery_identifier_signature\x18\x02 \x01(\v2%.xmtp.identity.associations.SignatureR#existingRecoveryIdentifierSignature\x12k\n" + - "\x1cnew_recovery_identifier_kind\x18\x03 \x01(\x0e2*.xmtp.identity.associations.IdentifierKindR\x19newRecoveryIdentifierKind\x12(\n" + - "\rrelying_party\x18\x04 \x01(\tH\x00R\frelyingParty\x88\x01\x01B\x10\n" + - "\x0e_relying_party\"\xdc\x02\n" + - "\x0eIdentityAction\x12L\n" + - "\fcreate_inbox\x18\x01 \x01(\v2'.xmtp.identity.associations.CreateInboxH\x00R\vcreateInbox\x12>\n" + - "\x03add\x18\x02 \x01(\v2*.xmtp.identity.associations.AddAssociationH\x00R\x03add\x12G\n" + - "\x06revoke\x18\x03 \x01(\v2-.xmtp.identity.associations.RevokeAssociationH\x00R\x06revoke\x12k\n" + - "\x17change_recovery_address\x18\x04 \x01(\v21.xmtp.identity.associations.ChangeRecoveryAddressH\x00R\x15changeRecoveryAddressB\x06\n" + - "\x04kind\"\xa1\x01\n" + - "\x0eIdentityUpdate\x12D\n" + - "\aactions\x18\x01 \x03(\v2*.xmtp.identity.associations.IdentityActionR\aactions\x12.\n" + - "\x13client_timestamp_ns\x18\x02 \x01(\x04R\x11clientTimestampNs\x12\x19\n" + - "\binbox_id\x18\x03 \x01(\tR\ainboxId\"\x85\x01\n" + - "\tMemberMap\x12>\n" + - "\x03key\x18\x01 \x01(\v2,.xmtp.identity.associations.MemberIdentifierR\x03key\x128\n" + - "\x05value\x18\x02 \x01(\v2\".xmtp.identity.associations.MemberR\x05value\"\xea\x02\n" + - "\x10AssociationState\x12\x19\n" + - "\binbox_id\x18\x01 \x01(\tR\ainboxId\x12?\n" + - "\amembers\x18\x02 \x03(\v2%.xmtp.identity.associations.MemberMapR\amembers\x12/\n" + - "\x13recovery_identifier\x18\x03 \x01(\tR\x12recoveryIdentifier\x12'\n" + - "\x0fseen_signatures\x18\x04 \x03(\fR\x0eseenSignatures\x12d\n" + - "\x18recovery_identifier_kind\x18\x05 \x01(\x0e2*.xmtp.identity.associations.IdentifierKindR\x16recoveryIdentifierKind\x12(\n" + - "\rrelying_party\x18\x06 \x01(\tH\x00R\frelyingParty\x88\x01\x01B\x10\n" + - "\x0e_relying_party\"\xbc\x01\n" + - "\x14AssociationStateDiff\x12M\n" + - "\vnew_members\x18\x01 \x03(\v2,.xmtp.identity.associations.MemberIdentifierR\n" + - "newMembers\x12U\n" + - "\x0fremoved_members\x18\x02 \x03(\v2,.xmtp.identity.associations.MemberIdentifierR\x0eremovedMembers*l\n" + - "\x0eIdentifierKind\x12\x1f\n" + - "\x1bIDENTIFIER_KIND_UNSPECIFIED\x10\x00\x12\x1c\n" + - "\x18IDENTIFIER_KIND_ETHEREUM\x10\x01\x12\x1b\n" + - "\x17IDENTIFIER_KIND_PASSKEY\x10\x02B\xa6\x02\n" + - "8org.xmtp.android.library.push.xmtp.identity.associationsB\x10AssociationProtoP\x01ZNgithub.com/xmtp/example-notification-server-go/pkg/proto/identity/associations\xa2\x02\x03XIA\xaa\x02\x1aXmtp.Identity.Associations\xca\x02\x1aXmtp\\Identity\\Associations\xe2\x02&Xmtp\\Identity\\Associations\\GPBMetadata\xea\x02\x1cXmtp::Identity::Associationsb\x06proto3" - -var ( - file_identity_associations_association_proto_rawDescOnce sync.Once - file_identity_associations_association_proto_rawDescData []byte -) - -func file_identity_associations_association_proto_rawDescGZIP() []byte { - file_identity_associations_association_proto_rawDescOnce.Do(func() { - file_identity_associations_association_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_identity_associations_association_proto_rawDesc), len(file_identity_associations_association_proto_rawDesc))) - }) - return file_identity_associations_association_proto_rawDescData -} - -var file_identity_associations_association_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_identity_associations_association_proto_msgTypes = make([]protoimpl.MessageInfo, 12) -var file_identity_associations_association_proto_goTypes = []any{ - (IdentifierKind)(0), // 0: xmtp.identity.associations.IdentifierKind - (*MemberIdentifier)(nil), // 1: xmtp.identity.associations.MemberIdentifier - (*Passkey)(nil), // 2: xmtp.identity.associations.Passkey - (*Member)(nil), // 3: xmtp.identity.associations.Member - (*CreateInbox)(nil), // 4: xmtp.identity.associations.CreateInbox - (*AddAssociation)(nil), // 5: xmtp.identity.associations.AddAssociation - (*RevokeAssociation)(nil), // 6: xmtp.identity.associations.RevokeAssociation - (*ChangeRecoveryAddress)(nil), // 7: xmtp.identity.associations.ChangeRecoveryAddress - (*IdentityAction)(nil), // 8: xmtp.identity.associations.IdentityAction - (*IdentityUpdate)(nil), // 9: xmtp.identity.associations.IdentityUpdate - (*MemberMap)(nil), // 10: xmtp.identity.associations.MemberMap - (*AssociationState)(nil), // 11: xmtp.identity.associations.AssociationState - (*AssociationStateDiff)(nil), // 12: xmtp.identity.associations.AssociationStateDiff - (*Signature)(nil), // 13: xmtp.identity.associations.Signature -} -var file_identity_associations_association_proto_depIdxs = []int32{ - 2, // 0: xmtp.identity.associations.MemberIdentifier.passkey:type_name -> xmtp.identity.associations.Passkey - 1, // 1: xmtp.identity.associations.Member.identifier:type_name -> xmtp.identity.associations.MemberIdentifier - 1, // 2: xmtp.identity.associations.Member.added_by_entity:type_name -> xmtp.identity.associations.MemberIdentifier - 13, // 3: xmtp.identity.associations.CreateInbox.initial_identifier_signature:type_name -> xmtp.identity.associations.Signature - 0, // 4: xmtp.identity.associations.CreateInbox.initial_identifier_kind:type_name -> xmtp.identity.associations.IdentifierKind - 1, // 5: xmtp.identity.associations.AddAssociation.new_member_identifier:type_name -> xmtp.identity.associations.MemberIdentifier - 13, // 6: xmtp.identity.associations.AddAssociation.existing_member_signature:type_name -> xmtp.identity.associations.Signature - 13, // 7: xmtp.identity.associations.AddAssociation.new_member_signature:type_name -> xmtp.identity.associations.Signature - 1, // 8: xmtp.identity.associations.RevokeAssociation.member_to_revoke:type_name -> xmtp.identity.associations.MemberIdentifier - 13, // 9: xmtp.identity.associations.RevokeAssociation.recovery_identifier_signature:type_name -> xmtp.identity.associations.Signature - 13, // 10: xmtp.identity.associations.ChangeRecoveryAddress.existing_recovery_identifier_signature:type_name -> xmtp.identity.associations.Signature - 0, // 11: xmtp.identity.associations.ChangeRecoveryAddress.new_recovery_identifier_kind:type_name -> xmtp.identity.associations.IdentifierKind - 4, // 12: xmtp.identity.associations.IdentityAction.create_inbox:type_name -> xmtp.identity.associations.CreateInbox - 5, // 13: xmtp.identity.associations.IdentityAction.add:type_name -> xmtp.identity.associations.AddAssociation - 6, // 14: xmtp.identity.associations.IdentityAction.revoke:type_name -> xmtp.identity.associations.RevokeAssociation - 7, // 15: xmtp.identity.associations.IdentityAction.change_recovery_address:type_name -> xmtp.identity.associations.ChangeRecoveryAddress - 8, // 16: xmtp.identity.associations.IdentityUpdate.actions:type_name -> xmtp.identity.associations.IdentityAction - 1, // 17: xmtp.identity.associations.MemberMap.key:type_name -> xmtp.identity.associations.MemberIdentifier - 3, // 18: xmtp.identity.associations.MemberMap.value:type_name -> xmtp.identity.associations.Member - 10, // 19: xmtp.identity.associations.AssociationState.members:type_name -> xmtp.identity.associations.MemberMap - 0, // 20: xmtp.identity.associations.AssociationState.recovery_identifier_kind:type_name -> xmtp.identity.associations.IdentifierKind - 1, // 21: xmtp.identity.associations.AssociationStateDiff.new_members:type_name -> xmtp.identity.associations.MemberIdentifier - 1, // 22: xmtp.identity.associations.AssociationStateDiff.removed_members:type_name -> xmtp.identity.associations.MemberIdentifier - 23, // [23:23] is the sub-list for method output_type - 23, // [23:23] is the sub-list for method input_type - 23, // [23:23] is the sub-list for extension type_name - 23, // [23:23] is the sub-list for extension extendee - 0, // [0:23] is the sub-list for field type_name -} - -func init() { file_identity_associations_association_proto_init() } -func file_identity_associations_association_proto_init() { - if File_identity_associations_association_proto != nil { - return - } - file_identity_associations_signature_proto_init() - file_identity_associations_association_proto_msgTypes[0].OneofWrappers = []any{ - (*MemberIdentifier_EthereumAddress)(nil), - (*MemberIdentifier_InstallationPublicKey)(nil), - (*MemberIdentifier_Passkey)(nil), - } - file_identity_associations_association_proto_msgTypes[1].OneofWrappers = []any{} - file_identity_associations_association_proto_msgTypes[2].OneofWrappers = []any{} - file_identity_associations_association_proto_msgTypes[3].OneofWrappers = []any{} - file_identity_associations_association_proto_msgTypes[4].OneofWrappers = []any{} - file_identity_associations_association_proto_msgTypes[6].OneofWrappers = []any{} - file_identity_associations_association_proto_msgTypes[7].OneofWrappers = []any{ - (*IdentityAction_CreateInbox)(nil), - (*IdentityAction_Add)(nil), - (*IdentityAction_Revoke)(nil), - (*IdentityAction_ChangeRecoveryAddress)(nil), - } - file_identity_associations_association_proto_msgTypes[10].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_identity_associations_association_proto_rawDesc), len(file_identity_associations_association_proto_rawDesc)), - NumEnums: 1, - NumMessages: 12, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_identity_associations_association_proto_goTypes, - DependencyIndexes: file_identity_associations_association_proto_depIdxs, - EnumInfos: file_identity_associations_association_proto_enumTypes, - MessageInfos: file_identity_associations_association_proto_msgTypes, - }.Build() - File_identity_associations_association_proto = out.File - file_identity_associations_association_proto_goTypes = nil - file_identity_associations_association_proto_depIdxs = nil -} diff --git a/pkg/proto/identity/associations/signature.pb.go b/pkg/proto/identity/associations/signature.pb.go deleted file mode 100644 index 36c04ecc..00000000 --- a/pkg/proto/identity/associations/signature.pb.go +++ /dev/null @@ -1,557 +0,0 @@ -// Signing methods for identity associations - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: identity/associations/signature.proto - -package associations - -import ( - message_contents "github.com/xmtp/example-notification-server-go/pkg/proto/message_contents" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// RecoverableEcdsaSignature for EIP-191 and V2 signatures -type RecoverableEcdsaSignature struct { - state protoimpl.MessageState `protogen:"open.v1"` - // 65-bytes [ R || S || V ], with recovery id as the last byte - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RecoverableEcdsaSignature) Reset() { - *x = RecoverableEcdsaSignature{} - mi := &file_identity_associations_signature_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RecoverableEcdsaSignature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RecoverableEcdsaSignature) ProtoMessage() {} - -func (x *RecoverableEcdsaSignature) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_signature_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RecoverableEcdsaSignature.ProtoReflect.Descriptor instead. -func (*RecoverableEcdsaSignature) Descriptor() ([]byte, []int) { - return file_identity_associations_signature_proto_rawDescGZIP(), []int{0} -} - -func (x *RecoverableEcdsaSignature) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -// EdDSA signature for 25519 -type RecoverableEd25519Signature struct { - state protoimpl.MessageState `protogen:"open.v1"` - // 64 bytes [R(32 bytes) || S(32 bytes)] - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` - // 32 bytes - PublicKey []byte `protobuf:"bytes,2,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RecoverableEd25519Signature) Reset() { - *x = RecoverableEd25519Signature{} - mi := &file_identity_associations_signature_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RecoverableEd25519Signature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RecoverableEd25519Signature) ProtoMessage() {} - -func (x *RecoverableEd25519Signature) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_signature_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RecoverableEd25519Signature.ProtoReflect.Descriptor instead. -func (*RecoverableEd25519Signature) Descriptor() ([]byte, []int) { - return file_identity_associations_signature_proto_rawDescGZIP(), []int{1} -} - -func (x *RecoverableEd25519Signature) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -func (x *RecoverableEd25519Signature) GetPublicKey() []byte { - if x != nil { - return x.PublicKey - } - return nil -} - -// Smart Contract Wallet signature -type SmartContractWalletSignature struct { - state protoimpl.MessageState `protogen:"open.v1"` - // CAIP-10 string - // https://github.com/ChainAgnostic/CAIPs/blob/main/CAIPs/caip-10.md - AccountId string `protobuf:"bytes,1,opt,name=account_id,json=accountId,proto3" json:"account_id,omitempty"` - // Specify the block number to verify the signature against - BlockNumber uint64 `protobuf:"varint,2,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"` - // The actual signature bytes - Signature []byte `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SmartContractWalletSignature) Reset() { - *x = SmartContractWalletSignature{} - mi := &file_identity_associations_signature_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SmartContractWalletSignature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SmartContractWalletSignature) ProtoMessage() {} - -func (x *SmartContractWalletSignature) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_signature_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SmartContractWalletSignature.ProtoReflect.Descriptor instead. -func (*SmartContractWalletSignature) Descriptor() ([]byte, []int) { - return file_identity_associations_signature_proto_rawDescGZIP(), []int{2} -} - -func (x *SmartContractWalletSignature) GetAccountId() string { - if x != nil { - return x.AccountId - } - return "" -} - -func (x *SmartContractWalletSignature) GetBlockNumber() uint64 { - if x != nil { - return x.BlockNumber - } - return 0 -} - -func (x *SmartContractWalletSignature) GetSignature() []byte { - if x != nil { - return x.Signature - } - return nil -} - -// Passkey signature -type RecoverablePasskeySignature struct { - state protoimpl.MessageState `protogen:"open.v1"` - PublicKey []byte `protobuf:"bytes,1,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"` - Signature []byte `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` - AuthenticatorData []byte `protobuf:"bytes,3,opt,name=authenticator_data,json=authenticatorData,proto3" json:"authenticator_data,omitempty"` - ClientDataJson []byte `protobuf:"bytes,4,opt,name=client_data_json,json=clientDataJson,proto3" json:"client_data_json,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RecoverablePasskeySignature) Reset() { - *x = RecoverablePasskeySignature{} - mi := &file_identity_associations_signature_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RecoverablePasskeySignature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RecoverablePasskeySignature) ProtoMessage() {} - -func (x *RecoverablePasskeySignature) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_signature_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RecoverablePasskeySignature.ProtoReflect.Descriptor instead. -func (*RecoverablePasskeySignature) Descriptor() ([]byte, []int) { - return file_identity_associations_signature_proto_rawDescGZIP(), []int{3} -} - -func (x *RecoverablePasskeySignature) GetPublicKey() []byte { - if x != nil { - return x.PublicKey - } - return nil -} - -func (x *RecoverablePasskeySignature) GetSignature() []byte { - if x != nil { - return x.Signature - } - return nil -} - -func (x *RecoverablePasskeySignature) GetAuthenticatorData() []byte { - if x != nil { - return x.AuthenticatorData - } - return nil -} - -func (x *RecoverablePasskeySignature) GetClientDataJson() []byte { - if x != nil { - return x.ClientDataJson - } - return nil -} - -// An existing address on xmtpv2 may have already signed a legacy identity key -// of type SignedPublicKey via the 'Create Identity' signature. -// For migration to xmtpv3, the legacy key is permitted to sign on behalf of the -// address to create a matching xmtpv3 installation key. -// This signature type can ONLY be used for CreateXid and AddAssociation -// payloads, and can only be used once in xmtpv3. -type LegacyDelegatedSignature struct { - state protoimpl.MessageState `protogen:"open.v1"` - DelegatedKey *message_contents.SignedPublicKey `protobuf:"bytes,1,opt,name=delegated_key,json=delegatedKey,proto3" json:"delegated_key,omitempty"` - Signature *RecoverableEcdsaSignature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *LegacyDelegatedSignature) Reset() { - *x = LegacyDelegatedSignature{} - mi := &file_identity_associations_signature_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *LegacyDelegatedSignature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*LegacyDelegatedSignature) ProtoMessage() {} - -func (x *LegacyDelegatedSignature) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_signature_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use LegacyDelegatedSignature.ProtoReflect.Descriptor instead. -func (*LegacyDelegatedSignature) Descriptor() ([]byte, []int) { - return file_identity_associations_signature_proto_rawDescGZIP(), []int{4} -} - -func (x *LegacyDelegatedSignature) GetDelegatedKey() *message_contents.SignedPublicKey { - if x != nil { - return x.DelegatedKey - } - return nil -} - -func (x *LegacyDelegatedSignature) GetSignature() *RecoverableEcdsaSignature { - if x != nil { - return x.Signature - } - return nil -} - -// A wrapper for all possible signature types -type Signature struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Must have two properties: - // 1. An identifier (address or public key) for the signer must either be - // recoverable, or specified as a field. - // 2. The signer certifies that the signing payload is correct. The payload - // must be inferred from the context in which the signature is provided. - // - // Types that are valid to be assigned to Signature: - // - // *Signature_Erc_191 - // *Signature_Erc_6492 - // *Signature_InstallationKey - // *Signature_DelegatedErc_191 - // *Signature_Passkey - Signature isSignature_Signature `protobuf_oneof:"signature"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Signature) Reset() { - *x = Signature{} - mi := &file_identity_associations_signature_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Signature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Signature) ProtoMessage() {} - -func (x *Signature) ProtoReflect() protoreflect.Message { - mi := &file_identity_associations_signature_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Signature.ProtoReflect.Descriptor instead. -func (*Signature) Descriptor() ([]byte, []int) { - return file_identity_associations_signature_proto_rawDescGZIP(), []int{5} -} - -func (x *Signature) GetSignature() isSignature_Signature { - if x != nil { - return x.Signature - } - return nil -} - -func (x *Signature) GetErc_191() *RecoverableEcdsaSignature { - if x != nil { - if x, ok := x.Signature.(*Signature_Erc_191); ok { - return x.Erc_191 - } - } - return nil -} - -func (x *Signature) GetErc_6492() *SmartContractWalletSignature { - if x != nil { - if x, ok := x.Signature.(*Signature_Erc_6492); ok { - return x.Erc_6492 - } - } - return nil -} - -func (x *Signature) GetInstallationKey() *RecoverableEd25519Signature { - if x != nil { - if x, ok := x.Signature.(*Signature_InstallationKey); ok { - return x.InstallationKey - } - } - return nil -} - -func (x *Signature) GetDelegatedErc_191() *LegacyDelegatedSignature { - if x != nil { - if x, ok := x.Signature.(*Signature_DelegatedErc_191); ok { - return x.DelegatedErc_191 - } - } - return nil -} - -func (x *Signature) GetPasskey() *RecoverablePasskeySignature { - if x != nil { - if x, ok := x.Signature.(*Signature_Passkey); ok { - return x.Passkey - } - } - return nil -} - -type isSignature_Signature interface { - isSignature_Signature() -} - -type Signature_Erc_191 struct { - Erc_191 *RecoverableEcdsaSignature `protobuf:"bytes,1,opt,name=erc_191,json=erc191,proto3,oneof"` -} - -type Signature_Erc_6492 struct { - Erc_6492 *SmartContractWalletSignature `protobuf:"bytes,2,opt,name=erc_6492,json=erc6492,proto3,oneof"` -} - -type Signature_InstallationKey struct { - InstallationKey *RecoverableEd25519Signature `protobuf:"bytes,3,opt,name=installation_key,json=installationKey,proto3,oneof"` -} - -type Signature_DelegatedErc_191 struct { - DelegatedErc_191 *LegacyDelegatedSignature `protobuf:"bytes,4,opt,name=delegated_erc_191,json=delegatedErc191,proto3,oneof"` -} - -type Signature_Passkey struct { - Passkey *RecoverablePasskeySignature `protobuf:"bytes,5,opt,name=passkey,proto3,oneof"` -} - -func (*Signature_Erc_191) isSignature_Signature() {} - -func (*Signature_Erc_6492) isSignature_Signature() {} - -func (*Signature_InstallationKey) isSignature_Signature() {} - -func (*Signature_DelegatedErc_191) isSignature_Signature() {} - -func (*Signature_Passkey) isSignature_Signature() {} - -var File_identity_associations_signature_proto protoreflect.FileDescriptor - -const file_identity_associations_signature_proto_rawDesc = "" + - "\n" + - "%identity/associations/signature.proto\x12\x1axmtp.identity.associations\x1a!message_contents/public_key.proto\"1\n" + - "\x19RecoverableEcdsaSignature\x12\x14\n" + - "\x05bytes\x18\x01 \x01(\fR\x05bytes\"R\n" + - "\x1bRecoverableEd25519Signature\x12\x14\n" + - "\x05bytes\x18\x01 \x01(\fR\x05bytes\x12\x1d\n" + - "\n" + - "public_key\x18\x02 \x01(\fR\tpublicKey\"~\n" + - "\x1cSmartContractWalletSignature\x12\x1d\n" + - "\n" + - "account_id\x18\x01 \x01(\tR\taccountId\x12!\n" + - "\fblock_number\x18\x02 \x01(\x04R\vblockNumber\x12\x1c\n" + - "\tsignature\x18\x03 \x01(\fR\tsignature\"\xb3\x01\n" + - "\x1bRecoverablePasskeySignature\x12\x1d\n" + - "\n" + - "public_key\x18\x01 \x01(\fR\tpublicKey\x12\x1c\n" + - "\tsignature\x18\x02 \x01(\fR\tsignature\x12-\n" + - "\x12authenticator_data\x18\x03 \x01(\fR\x11authenticatorData\x12(\n" + - "\x10client_data_json\x18\x04 \x01(\fR\x0eclientDataJson\"\xbc\x01\n" + - "\x18LegacyDelegatedSignature\x12K\n" + - "\rdelegated_key\x18\x01 \x01(\v2&.xmtp.message_contents.SignedPublicKeyR\fdelegatedKey\x12S\n" + - "\tsignature\x18\x02 \x01(\v25.xmtp.identity.associations.RecoverableEcdsaSignatureR\tsignature\"\xe0\x03\n" + - "\tSignature\x12P\n" + - "\aerc_191\x18\x01 \x01(\v25.xmtp.identity.associations.RecoverableEcdsaSignatureH\x00R\x06erc191\x12U\n" + - "\berc_6492\x18\x02 \x01(\v28.xmtp.identity.associations.SmartContractWalletSignatureH\x00R\aerc6492\x12d\n" + - "\x10installation_key\x18\x03 \x01(\v27.xmtp.identity.associations.RecoverableEd25519SignatureH\x00R\x0finstallationKey\x12b\n" + - "\x11delegated_erc_191\x18\x04 \x01(\v24.xmtp.identity.associations.LegacyDelegatedSignatureH\x00R\x0fdelegatedErc191\x12S\n" + - "\apasskey\x18\x05 \x01(\v27.xmtp.identity.associations.RecoverablePasskeySignatureH\x00R\apasskeyB\v\n" + - "\tsignatureB\xa4\x02\n" + - "8org.xmtp.android.library.push.xmtp.identity.associationsB\x0eSignatureProtoP\x01ZNgithub.com/xmtp/example-notification-server-go/pkg/proto/identity/associations\xa2\x02\x03XIA\xaa\x02\x1aXmtp.Identity.Associations\xca\x02\x1aXmtp\\Identity\\Associations\xe2\x02&Xmtp\\Identity\\Associations\\GPBMetadata\xea\x02\x1cXmtp::Identity::Associationsb\x06proto3" - -var ( - file_identity_associations_signature_proto_rawDescOnce sync.Once - file_identity_associations_signature_proto_rawDescData []byte -) - -func file_identity_associations_signature_proto_rawDescGZIP() []byte { - file_identity_associations_signature_proto_rawDescOnce.Do(func() { - file_identity_associations_signature_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_identity_associations_signature_proto_rawDesc), len(file_identity_associations_signature_proto_rawDesc))) - }) - return file_identity_associations_signature_proto_rawDescData -} - -var file_identity_associations_signature_proto_msgTypes = make([]protoimpl.MessageInfo, 6) -var file_identity_associations_signature_proto_goTypes = []any{ - (*RecoverableEcdsaSignature)(nil), // 0: xmtp.identity.associations.RecoverableEcdsaSignature - (*RecoverableEd25519Signature)(nil), // 1: xmtp.identity.associations.RecoverableEd25519Signature - (*SmartContractWalletSignature)(nil), // 2: xmtp.identity.associations.SmartContractWalletSignature - (*RecoverablePasskeySignature)(nil), // 3: xmtp.identity.associations.RecoverablePasskeySignature - (*LegacyDelegatedSignature)(nil), // 4: xmtp.identity.associations.LegacyDelegatedSignature - (*Signature)(nil), // 5: xmtp.identity.associations.Signature - (*message_contents.SignedPublicKey)(nil), // 6: xmtp.message_contents.SignedPublicKey -} -var file_identity_associations_signature_proto_depIdxs = []int32{ - 6, // 0: xmtp.identity.associations.LegacyDelegatedSignature.delegated_key:type_name -> xmtp.message_contents.SignedPublicKey - 0, // 1: xmtp.identity.associations.LegacyDelegatedSignature.signature:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature - 0, // 2: xmtp.identity.associations.Signature.erc_191:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature - 2, // 3: xmtp.identity.associations.Signature.erc_6492:type_name -> xmtp.identity.associations.SmartContractWalletSignature - 1, // 4: xmtp.identity.associations.Signature.installation_key:type_name -> xmtp.identity.associations.RecoverableEd25519Signature - 4, // 5: xmtp.identity.associations.Signature.delegated_erc_191:type_name -> xmtp.identity.associations.LegacyDelegatedSignature - 3, // 6: xmtp.identity.associations.Signature.passkey:type_name -> xmtp.identity.associations.RecoverablePasskeySignature - 7, // [7:7] is the sub-list for method output_type - 7, // [7:7] is the sub-list for method input_type - 7, // [7:7] is the sub-list for extension type_name - 7, // [7:7] is the sub-list for extension extendee - 0, // [0:7] is the sub-list for field type_name -} - -func init() { file_identity_associations_signature_proto_init() } -func file_identity_associations_signature_proto_init() { - if File_identity_associations_signature_proto != nil { - return - } - file_identity_associations_signature_proto_msgTypes[5].OneofWrappers = []any{ - (*Signature_Erc_191)(nil), - (*Signature_Erc_6492)(nil), - (*Signature_InstallationKey)(nil), - (*Signature_DelegatedErc_191)(nil), - (*Signature_Passkey)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_identity_associations_signature_proto_rawDesc), len(file_identity_associations_signature_proto_rawDesc)), - NumEnums: 0, - NumMessages: 6, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_identity_associations_signature_proto_goTypes, - DependencyIndexes: file_identity_associations_signature_proto_depIdxs, - MessageInfos: file_identity_associations_signature_proto_msgTypes, - }.Build() - File_identity_associations_signature_proto = out.File - file_identity_associations_signature_proto_goTypes = nil - file_identity_associations_signature_proto_depIdxs = nil -} diff --git a/pkg/proto/identity/credential.pb.go b/pkg/proto/identity/credential.pb.go deleted file mode 100644 index ffac4549..00000000 --- a/pkg/proto/identity/credential.pb.go +++ /dev/null @@ -1,126 +0,0 @@ -// Credentials - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: identity/credential.proto - -package identity - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// A credential that can be used in MLS leaf nodes -type MlsCredential struct { - state protoimpl.MessageState `protogen:"open.v1"` - InboxId string `protobuf:"bytes,1,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MlsCredential) Reset() { - *x = MlsCredential{} - mi := &file_identity_credential_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MlsCredential) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MlsCredential) ProtoMessage() {} - -func (x *MlsCredential) ProtoReflect() protoreflect.Message { - mi := &file_identity_credential_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MlsCredential.ProtoReflect.Descriptor instead. -func (*MlsCredential) Descriptor() ([]byte, []int) { - return file_identity_credential_proto_rawDescGZIP(), []int{0} -} - -func (x *MlsCredential) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -var File_identity_credential_proto protoreflect.FileDescriptor - -const file_identity_credential_proto_rawDesc = "" + - "\n" + - "\x19identity/credential.proto\x12\rxmtp.identity\"*\n" + - "\rMlsCredential\x12\x19\n" + - "\binbox_id\x18\x01 \x01(\tR\ainboxIdB\xd6\x01\n" + - "+org.xmtp.android.library.push.xmtp.identityB\x0fCredentialProtoP\x01ZAgithub.com/xmtp/example-notification-server-go/pkg/proto/identity\xa2\x02\x03XIX\xaa\x02\rXmtp.Identity\xca\x02\rXmtp\\Identity\xe2\x02\x19Xmtp\\Identity\\GPBMetadata\xea\x02\x0eXmtp::Identityb\x06proto3" - -var ( - file_identity_credential_proto_rawDescOnce sync.Once - file_identity_credential_proto_rawDescData []byte -) - -func file_identity_credential_proto_rawDescGZIP() []byte { - file_identity_credential_proto_rawDescOnce.Do(func() { - file_identity_credential_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_identity_credential_proto_rawDesc), len(file_identity_credential_proto_rawDesc))) - }) - return file_identity_credential_proto_rawDescData -} - -var file_identity_credential_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_identity_credential_proto_goTypes = []any{ - (*MlsCredential)(nil), // 0: xmtp.identity.MlsCredential -} -var file_identity_credential_proto_depIdxs = []int32{ - 0, // [0:0] is the sub-list for method output_type - 0, // [0:0] 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_identity_credential_proto_init() } -func file_identity_credential_proto_init() { - if File_identity_credential_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_identity_credential_proto_rawDesc), len(file_identity_credential_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_identity_credential_proto_goTypes, - DependencyIndexes: file_identity_credential_proto_depIdxs, - MessageInfos: file_identity_credential_proto_msgTypes, - }.Build() - File_identity_credential_proto = out.File - file_identity_credential_proto_goTypes = nil - file_identity_credential_proto_depIdxs = nil -} diff --git a/pkg/proto/keystore_api/v1/keystore.pb.go b/pkg/proto/keystore_api/v1/keystore.pb.go deleted file mode 100644 index c85c8cec..00000000 --- a/pkg/proto/keystore_api/v1/keystore.pb.go +++ /dev/null @@ -1,3159 +0,0 @@ -// Message content encoding structures - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: keystore_api/v1/keystore.proto - -package keystore_apiv1 - -import ( - message_contents "github.com/xmtp/example-notification-server-go/pkg/proto/message_contents" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Application-specific error codes for the Keystore API. -type ErrorCode int32 - -const ( - ErrorCode_ERROR_CODE_UNSPECIFIED ErrorCode = 0 - ErrorCode_ERROR_CODE_INVALID_INPUT ErrorCode = 1 - ErrorCode_ERROR_CODE_NO_MATCHING_PREKEY ErrorCode = 2 -) - -// Enum value maps for ErrorCode. -var ( - ErrorCode_name = map[int32]string{ - 0: "ERROR_CODE_UNSPECIFIED", - 1: "ERROR_CODE_INVALID_INPUT", - 2: "ERROR_CODE_NO_MATCHING_PREKEY", - } - ErrorCode_value = map[string]int32{ - "ERROR_CODE_UNSPECIFIED": 0, - "ERROR_CODE_INVALID_INPUT": 1, - "ERROR_CODE_NO_MATCHING_PREKEY": 2, - } -) - -func (x ErrorCode) Enum() *ErrorCode { - p := new(ErrorCode) - *p = x - return p -} - -func (x ErrorCode) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ErrorCode) Descriptor() protoreflect.EnumDescriptor { - return file_keystore_api_v1_keystore_proto_enumTypes[0].Descriptor() -} - -func (ErrorCode) Type() protoreflect.EnumType { - return &file_keystore_api_v1_keystore_proto_enumTypes[0] -} - -func (x ErrorCode) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ErrorCode.Descriptor instead. -func (ErrorCode) EnumDescriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{0} -} - -// JobType is used to specify the type of job the caller would like info on -type JobType int32 - -const ( - JobType_JOB_TYPE_UNSPECIFIED JobType = 0 - JobType_JOB_TYPE_REFRESH_V1 JobType = 1 - JobType_JOB_TYPE_REFRESH_V2 JobType = 2 - JobType_JOB_TYPE_REFRESH_PPPP JobType = 3 -) - -// Enum value maps for JobType. -var ( - JobType_name = map[int32]string{ - 0: "JOB_TYPE_UNSPECIFIED", - 1: "JOB_TYPE_REFRESH_V1", - 2: "JOB_TYPE_REFRESH_V2", - 3: "JOB_TYPE_REFRESH_PPPP", - } - JobType_value = map[string]int32{ - "JOB_TYPE_UNSPECIFIED": 0, - "JOB_TYPE_REFRESH_V1": 1, - "JOB_TYPE_REFRESH_V2": 2, - "JOB_TYPE_REFRESH_PPPP": 3, - } -) - -func (x JobType) Enum() *JobType { - p := new(JobType) - *p = x - return p -} - -func (x JobType) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (JobType) Descriptor() protoreflect.EnumDescriptor { - return file_keystore_api_v1_keystore_proto_enumTypes[1].Descriptor() -} - -func (JobType) Type() protoreflect.EnumType { - return &file_keystore_api_v1_keystore_proto_enumTypes[1] -} - -func (x JobType) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use JobType.Descriptor instead. -func (JobType) EnumDescriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{1} -} - -// Status of the Keystore for the specified wallet address -type GetKeystoreStatusResponse_KeystoreStatus int32 - -const ( - GetKeystoreStatusResponse_KEYSTORE_STATUS_UNSPECIFIED GetKeystoreStatusResponse_KeystoreStatus = 0 - GetKeystoreStatusResponse_KEYSTORE_STATUS_UNINITIALIZED GetKeystoreStatusResponse_KeystoreStatus = 1 - GetKeystoreStatusResponse_KEYSTORE_STATUS_INITIALIZED GetKeystoreStatusResponse_KeystoreStatus = 2 -) - -// Enum value maps for GetKeystoreStatusResponse_KeystoreStatus. -var ( - GetKeystoreStatusResponse_KeystoreStatus_name = map[int32]string{ - 0: "KEYSTORE_STATUS_UNSPECIFIED", - 1: "KEYSTORE_STATUS_UNINITIALIZED", - 2: "KEYSTORE_STATUS_INITIALIZED", - } - GetKeystoreStatusResponse_KeystoreStatus_value = map[string]int32{ - "KEYSTORE_STATUS_UNSPECIFIED": 0, - "KEYSTORE_STATUS_UNINITIALIZED": 1, - "KEYSTORE_STATUS_INITIALIZED": 2, - } -) - -func (x GetKeystoreStatusResponse_KeystoreStatus) Enum() *GetKeystoreStatusResponse_KeystoreStatus { - p := new(GetKeystoreStatusResponse_KeystoreStatus) - *p = x - return p -} - -func (x GetKeystoreStatusResponse_KeystoreStatus) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (GetKeystoreStatusResponse_KeystoreStatus) Descriptor() protoreflect.EnumDescriptor { - return file_keystore_api_v1_keystore_proto_enumTypes[2].Descriptor() -} - -func (GetKeystoreStatusResponse_KeystoreStatus) Type() protoreflect.EnumType { - return &file_keystore_api_v1_keystore_proto_enumTypes[2] -} - -func (x GetKeystoreStatusResponse_KeystoreStatus) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use GetKeystoreStatusResponse_KeystoreStatus.Descriptor instead. -func (GetKeystoreStatusResponse_KeystoreStatus) EnumDescriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{20, 0} -} - -// Wrapper class for errors from the Keystore API -type KeystoreError struct { - state protoimpl.MessageState `protogen:"open.v1"` - Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` - Code ErrorCode `protobuf:"varint,2,opt,name=code,proto3,enum=xmtp.keystore_api.v1.ErrorCode" json:"code,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *KeystoreError) Reset() { - *x = KeystoreError{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *KeystoreError) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*KeystoreError) ProtoMessage() {} - -func (x *KeystoreError) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use KeystoreError.ProtoReflect.Descriptor instead. -func (*KeystoreError) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{0} -} - -func (x *KeystoreError) GetMessage() string { - if x != nil { - return x.Message - } - return "" -} - -func (x *KeystoreError) GetCode() ErrorCode { - if x != nil { - return x.Code - } - return ErrorCode_ERROR_CODE_UNSPECIFIED -} - -// Decrypt a batch of messages using X3DH key agreement -type DecryptV1Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*DecryptV1Request_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DecryptV1Request) Reset() { - *x = DecryptV1Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DecryptV1Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DecryptV1Request) ProtoMessage() {} - -func (x *DecryptV1Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DecryptV1Request.ProtoReflect.Descriptor instead. -func (*DecryptV1Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{1} -} - -func (x *DecryptV1Request) GetRequests() []*DecryptV1Request_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Response type for both V1 and V2 decryption requests -type DecryptResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*DecryptResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DecryptResponse) Reset() { - *x = DecryptResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DecryptResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DecryptResponse) ProtoMessage() {} - -func (x *DecryptResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DecryptResponse.ProtoReflect.Descriptor instead. -func (*DecryptResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{2} -} - -func (x *DecryptResponse) GetResponses() []*DecryptResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -// Decrypt a batch of messages using the appropriate topic keys -type DecryptV2Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*DecryptV2Request_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DecryptV2Request) Reset() { - *x = DecryptV2Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DecryptV2Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DecryptV2Request) ProtoMessage() {} - -func (x *DecryptV2Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DecryptV2Request.ProtoReflect.Descriptor instead. -func (*DecryptV2Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{3} -} - -func (x *DecryptV2Request) GetRequests() []*DecryptV2Request_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Encrypt a batch of messages using X3DH key agreement -type EncryptV1Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*EncryptV1Request_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptV1Request) Reset() { - *x = EncryptV1Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptV1Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptV1Request) ProtoMessage() {} - -func (x *EncryptV1Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptV1Request.ProtoReflect.Descriptor instead. -func (*EncryptV1Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{4} -} - -func (x *EncryptV1Request) GetRequests() []*EncryptV1Request_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Response type for both V1 and V2 encryption requests -type EncryptResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*EncryptResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptResponse) Reset() { - *x = EncryptResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptResponse) ProtoMessage() {} - -func (x *EncryptResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptResponse.ProtoReflect.Descriptor instead. -func (*EncryptResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{5} -} - -func (x *EncryptResponse) GetResponses() []*EncryptResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -// Encrypt a batch of messages using the appropriate topic keys -type EncryptV2Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*EncryptV2Request_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptV2Request) Reset() { - *x = EncryptV2Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptV2Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptV2Request) ProtoMessage() {} - -func (x *EncryptV2Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptV2Request.ProtoReflect.Descriptor instead. -func (*EncryptV2Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{6} -} - -func (x *EncryptV2Request) GetRequests() []*EncryptV2Request_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Encrypt a message for yourself -type SelfEncryptRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*SelfEncryptRequest_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SelfEncryptRequest) Reset() { - *x = SelfEncryptRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SelfEncryptRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SelfEncryptRequest) ProtoMessage() {} - -func (x *SelfEncryptRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SelfEncryptRequest.ProtoReflect.Descriptor instead. -func (*SelfEncryptRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{7} -} - -func (x *SelfEncryptRequest) GetRequests() []*SelfEncryptRequest_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Response type for SelfEncryptRequest -type SelfEncryptResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*SelfEncryptResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SelfEncryptResponse) Reset() { - *x = SelfEncryptResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SelfEncryptResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SelfEncryptResponse) ProtoMessage() {} - -func (x *SelfEncryptResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SelfEncryptResponse.ProtoReflect.Descriptor instead. -func (*SelfEncryptResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{8} -} - -func (x *SelfEncryptResponse) GetResponses() []*SelfEncryptResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -// SelfDecryptRequest -type SelfDecryptRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*SelfDecryptRequest_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SelfDecryptRequest) Reset() { - *x = SelfDecryptRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SelfDecryptRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SelfDecryptRequest) ProtoMessage() {} - -func (x *SelfDecryptRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SelfDecryptRequest.ProtoReflect.Descriptor instead. -func (*SelfDecryptRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{9} -} - -func (x *SelfDecryptRequest) GetRequests() []*SelfDecryptRequest_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Get the private preferences topic identifier -type GetPrivatePreferencesTopicIdentifierResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetPrivatePreferencesTopicIdentifierResponse) Reset() { - *x = GetPrivatePreferencesTopicIdentifierResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetPrivatePreferencesTopicIdentifierResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetPrivatePreferencesTopicIdentifierResponse) ProtoMessage() {} - -func (x *GetPrivatePreferencesTopicIdentifierResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetPrivatePreferencesTopicIdentifierResponse.ProtoReflect.Descriptor instead. -func (*GetPrivatePreferencesTopicIdentifierResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{10} -} - -func (x *GetPrivatePreferencesTopicIdentifierResponse) GetIdentifier() string { - if x != nil { - return x.Identifier - } - return "" -} - -// Request to create an invite payload, and store the topic keys in the Keystore -type CreateInviteRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Context *message_contents.InvitationV1_Context `protobuf:"bytes,1,opt,name=context,proto3" json:"context,omitempty"` - Recipient *message_contents.SignedPublicKeyBundle `protobuf:"bytes,2,opt,name=recipient,proto3" json:"recipient,omitempty"` - CreatedNs uint64 `protobuf:"varint,3,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - ConsentProof *message_contents.ConsentProofPayload `protobuf:"bytes,4,opt,name=consent_proof,json=consentProof,proto3" json:"consent_proof,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *CreateInviteRequest) Reset() { - *x = CreateInviteRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *CreateInviteRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CreateInviteRequest) ProtoMessage() {} - -func (x *CreateInviteRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CreateInviteRequest.ProtoReflect.Descriptor instead. -func (*CreateInviteRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{11} -} - -func (x *CreateInviteRequest) GetContext() *message_contents.InvitationV1_Context { - if x != nil { - return x.Context - } - return nil -} - -func (x *CreateInviteRequest) GetRecipient() *message_contents.SignedPublicKeyBundle { - if x != nil { - return x.Recipient - } - return nil -} - -func (x *CreateInviteRequest) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *CreateInviteRequest) GetConsentProof() *message_contents.ConsentProofPayload { - if x != nil { - return x.ConsentProof - } - return nil -} - -// Response to a CreateInviteRequest -type CreateInviteResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Conversation *message_contents.ConversationReference `protobuf:"bytes,1,opt,name=conversation,proto3" json:"conversation,omitempty"` - Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *CreateInviteResponse) Reset() { - *x = CreateInviteResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *CreateInviteResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CreateInviteResponse) ProtoMessage() {} - -func (x *CreateInviteResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[12] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CreateInviteResponse.ProtoReflect.Descriptor instead. -func (*CreateInviteResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{12} -} - -func (x *CreateInviteResponse) GetConversation() *message_contents.ConversationReference { - if x != nil { - return x.Conversation - } - return nil -} - -func (x *CreateInviteResponse) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -// Request to save a batch of invite messages to the Keystore -type SaveInvitesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*SaveInvitesRequest_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SaveInvitesRequest) Reset() { - *x = SaveInvitesRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SaveInvitesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SaveInvitesRequest) ProtoMessage() {} - -func (x *SaveInvitesRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[13] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SaveInvitesRequest.ProtoReflect.Descriptor instead. -func (*SaveInvitesRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{13} -} - -func (x *SaveInvitesRequest) GetRequests() []*SaveInvitesRequest_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Response to a SaveInvitesRequest -type SaveInvitesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*SaveInvitesResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SaveInvitesResponse) Reset() { - *x = SaveInvitesResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SaveInvitesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SaveInvitesResponse) ProtoMessage() {} - -func (x *SaveInvitesResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[14] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SaveInvitesResponse.ProtoReflect.Descriptor instead. -func (*SaveInvitesResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{14} -} - -func (x *SaveInvitesResponse) GetResponses() []*SaveInvitesResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -// CreateAuthTokenRequest is used to create an auth token for the XMTP API -type CreateAuthTokenRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - TimestampNs *uint64 `protobuf:"varint,1,opt,name=timestamp_ns,json=timestampNs,proto3,oneof" json:"timestamp_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *CreateAuthTokenRequest) Reset() { - *x = CreateAuthTokenRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *CreateAuthTokenRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CreateAuthTokenRequest) ProtoMessage() {} - -func (x *CreateAuthTokenRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[15] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CreateAuthTokenRequest.ProtoReflect.Descriptor instead. -func (*CreateAuthTokenRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{15} -} - -func (x *CreateAuthTokenRequest) GetTimestampNs() uint64 { - if x != nil && x.TimestampNs != nil { - return *x.TimestampNs - } - return 0 -} - -// SaveV1ConversationsRequest is used to save a batch of conversations to the -// built in persistence -type SaveV1ConversationsRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Conversations []*message_contents.ConversationReference `protobuf:"bytes,1,rep,name=conversations,proto3" json:"conversations,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SaveV1ConversationsRequest) Reset() { - *x = SaveV1ConversationsRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SaveV1ConversationsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SaveV1ConversationsRequest) ProtoMessage() {} - -func (x *SaveV1ConversationsRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[16] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SaveV1ConversationsRequest.ProtoReflect.Descriptor instead. -func (*SaveV1ConversationsRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{16} -} - -func (x *SaveV1ConversationsRequest) GetConversations() []*message_contents.ConversationReference { - if x != nil { - return x.Conversations - } - return nil -} - -// Placeholder response type for SaveV1Conversations -type SaveV1ConversationsResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SaveV1ConversationsResponse) Reset() { - *x = SaveV1ConversationsResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SaveV1ConversationsResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SaveV1ConversationsResponse) ProtoMessage() {} - -func (x *SaveV1ConversationsResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[17] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SaveV1ConversationsResponse.ProtoReflect.Descriptor instead. -func (*SaveV1ConversationsResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{17} -} - -// Response for GetV2Conversations -type GetConversationsResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Conversations []*message_contents.ConversationReference `protobuf:"bytes,1,rep,name=conversations,proto3" json:"conversations,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetConversationsResponse) Reset() { - *x = GetConversationsResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetConversationsResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetConversationsResponse) ProtoMessage() {} - -func (x *GetConversationsResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[18] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetConversationsResponse.ProtoReflect.Descriptor instead. -func (*GetConversationsResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{18} -} - -func (x *GetConversationsResponse) GetConversations() []*message_contents.ConversationReference { - if x != nil { - return x.Conversations - } - return nil -} - -// Used to check if the Keystore implementation has been setup for the given -// wallet address Only used for MM Snap Keystore currently -type GetKeystoreStatusRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - WalletAddress string `protobuf:"bytes,1,opt,name=wallet_address,json=walletAddress,proto3" json:"wallet_address,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetKeystoreStatusRequest) Reset() { - *x = GetKeystoreStatusRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetKeystoreStatusRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetKeystoreStatusRequest) ProtoMessage() {} - -func (x *GetKeystoreStatusRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[19] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetKeystoreStatusRequest.ProtoReflect.Descriptor instead. -func (*GetKeystoreStatusRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{19} -} - -func (x *GetKeystoreStatusRequest) GetWalletAddress() string { - if x != nil { - return x.WalletAddress - } - return "" -} - -// Response to GetKeystoreStatusRequest -type GetKeystoreStatusResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Status GetKeystoreStatusResponse_KeystoreStatus `protobuf:"varint,1,opt,name=status,proto3,enum=xmtp.keystore_api.v1.GetKeystoreStatusResponse_KeystoreStatus" json:"status,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetKeystoreStatusResponse) Reset() { - *x = GetKeystoreStatusResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetKeystoreStatusResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetKeystoreStatusResponse) ProtoMessage() {} - -func (x *GetKeystoreStatusResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[20] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetKeystoreStatusResponse.ProtoReflect.Descriptor instead. -func (*GetKeystoreStatusResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{20} -} - -func (x *GetKeystoreStatusResponse) GetStatus() GetKeystoreStatusResponse_KeystoreStatus { - if x != nil { - return x.Status - } - return GetKeystoreStatusResponse_KEYSTORE_STATUS_UNSPECIFIED -} - -// Used to initialize the Keystore with a private key bundle retrieved from the -// client -type InitKeystoreRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Bundle: - // - // *InitKeystoreRequest_V1 - Bundle isInitKeystoreRequest_Bundle `protobuf_oneof:"bundle"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *InitKeystoreRequest) Reset() { - *x = InitKeystoreRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *InitKeystoreRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*InitKeystoreRequest) ProtoMessage() {} - -func (x *InitKeystoreRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[21] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use InitKeystoreRequest.ProtoReflect.Descriptor instead. -func (*InitKeystoreRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{21} -} - -func (x *InitKeystoreRequest) GetBundle() isInitKeystoreRequest_Bundle { - if x != nil { - return x.Bundle - } - return nil -} - -func (x *InitKeystoreRequest) GetV1() *message_contents.PrivateKeyBundleV1 { - if x != nil { - if x, ok := x.Bundle.(*InitKeystoreRequest_V1); ok { - return x.V1 - } - } - return nil -} - -type isInitKeystoreRequest_Bundle interface { - isInitKeystoreRequest_Bundle() -} - -type InitKeystoreRequest_V1 struct { - V1 *message_contents.PrivateKeyBundleV1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*InitKeystoreRequest_V1) isInitKeystoreRequest_Bundle() {} - -// Response to the request to initialize the Keystore -type InitKeystoreResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Error *KeystoreError `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *InitKeystoreResponse) Reset() { - *x = InitKeystoreResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *InitKeystoreResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*InitKeystoreResponse) ProtoMessage() {} - -func (x *InitKeystoreResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[22] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use InitKeystoreResponse.ProtoReflect.Descriptor instead. -func (*InitKeystoreResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{22} -} - -func (x *InitKeystoreResponse) GetError() *KeystoreError { - if x != nil { - return x.Error - } - return nil -} - -// SignDigestRequest is used to sign a digest with either the identity key -// or a prekey -type SignDigestRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Digest []byte `protobuf:"bytes,1,opt,name=digest,proto3" json:"digest,omitempty"` - // Types that are valid to be assigned to Signer: - // - // *SignDigestRequest_IdentityKey - // *SignDigestRequest_PrekeyIndex - Signer isSignDigestRequest_Signer `protobuf_oneof:"signer"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignDigestRequest) Reset() { - *x = SignDigestRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignDigestRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignDigestRequest) ProtoMessage() {} - -func (x *SignDigestRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[23] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignDigestRequest.ProtoReflect.Descriptor instead. -func (*SignDigestRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{23} -} - -func (x *SignDigestRequest) GetDigest() []byte { - if x != nil { - return x.Digest - } - return nil -} - -func (x *SignDigestRequest) GetSigner() isSignDigestRequest_Signer { - if x != nil { - return x.Signer - } - return nil -} - -func (x *SignDigestRequest) GetIdentityKey() bool { - if x != nil { - if x, ok := x.Signer.(*SignDigestRequest_IdentityKey); ok { - return x.IdentityKey - } - } - return false -} - -func (x *SignDigestRequest) GetPrekeyIndex() uint32 { - if x != nil { - if x, ok := x.Signer.(*SignDigestRequest_PrekeyIndex); ok { - return x.PrekeyIndex - } - } - return 0 -} - -type isSignDigestRequest_Signer interface { - isSignDigestRequest_Signer() -} - -type SignDigestRequest_IdentityKey struct { - IdentityKey bool `protobuf:"varint,2,opt,name=identity_key,json=identityKey,proto3,oneof"` -} - -type SignDigestRequest_PrekeyIndex struct { - PrekeyIndex uint32 `protobuf:"varint,3,opt,name=prekey_index,json=prekeyIndex,proto3,oneof"` -} - -func (*SignDigestRequest_IdentityKey) isSignDigestRequest_Signer() {} - -func (*SignDigestRequest_PrekeyIndex) isSignDigestRequest_Signer() {} - -// GetRefreshJobRequest is used to get the last run time of a refresh job -type GetRefreshJobRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - JobType JobType `protobuf:"varint,1,opt,name=job_type,json=jobType,proto3,enum=xmtp.keystore_api.v1.JobType" json:"job_type,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetRefreshJobRequest) Reset() { - *x = GetRefreshJobRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetRefreshJobRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetRefreshJobRequest) ProtoMessage() {} - -func (x *GetRefreshJobRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[24] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetRefreshJobRequest.ProtoReflect.Descriptor instead. -func (*GetRefreshJobRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{24} -} - -func (x *GetRefreshJobRequest) GetJobType() JobType { - if x != nil { - return x.JobType - } - return JobType_JOB_TYPE_UNSPECIFIED -} - -// GetRefreshJobResponse is used to return the last run time of a refresh job -type GetRefreshJobResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - LastRunNs int64 `protobuf:"varint,1,opt,name=last_run_ns,json=lastRunNs,proto3" json:"last_run_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetRefreshJobResponse) Reset() { - *x = GetRefreshJobResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetRefreshJobResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetRefreshJobResponse) ProtoMessage() {} - -func (x *GetRefreshJobResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[25] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetRefreshJobResponse.ProtoReflect.Descriptor instead. -func (*GetRefreshJobResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{25} -} - -func (x *GetRefreshJobResponse) GetLastRunNs() int64 { - if x != nil { - return x.LastRunNs - } - return 0 -} - -// SetRefreshJobRequest is used to set the last run time of a refresh job -type SetRefeshJobRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - JobType JobType `protobuf:"varint,1,opt,name=job_type,json=jobType,proto3,enum=xmtp.keystore_api.v1.JobType" json:"job_type,omitempty"` - LastRunNs int64 `protobuf:"varint,2,opt,name=last_run_ns,json=lastRunNs,proto3" json:"last_run_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SetRefeshJobRequest) Reset() { - *x = SetRefeshJobRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SetRefeshJobRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetRefeshJobRequest) ProtoMessage() {} - -func (x *SetRefeshJobRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[26] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetRefeshJobRequest.ProtoReflect.Descriptor instead. -func (*SetRefeshJobRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{26} -} - -func (x *SetRefeshJobRequest) GetJobType() JobType { - if x != nil { - return x.JobType - } - return JobType_JOB_TYPE_UNSPECIFIED -} - -func (x *SetRefeshJobRequest) GetLastRunNs() int64 { - if x != nil { - return x.LastRunNs - } - return 0 -} - -// SetRefreshJobResponse is an empty response type -type SetRefreshJobResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SetRefreshJobResponse) Reset() { - *x = SetRefreshJobResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SetRefreshJobResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetRefreshJobResponse) ProtoMessage() {} - -func (x *SetRefreshJobResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[27] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetRefreshJobResponse.ProtoReflect.Descriptor instead. -func (*SetRefreshJobResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{27} -} - -// A mapping of topics to their decrypted invitations -type TopicMap struct { - state protoimpl.MessageState `protogen:"open.v1"` - Topics map[string]*TopicMap_TopicData `protobuf:"bytes,1,rep,name=topics,proto3" json:"topics,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *TopicMap) Reset() { - *x = TopicMap{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *TopicMap) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TopicMap) ProtoMessage() {} - -func (x *TopicMap) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[28] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TopicMap.ProtoReflect.Descriptor instead. -func (*TopicMap) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{28} -} - -func (x *TopicMap) GetTopics() map[string]*TopicMap_TopicData { - if x != nil { - return x.Topics - } - return nil -} - -// Used to get a mapping of conversation topics to their HMAC keys -type GetConversationHmacKeysRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Topics []string `protobuf:"bytes,1,rep,name=topics,proto3" json:"topics,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetConversationHmacKeysRequest) Reset() { - *x = GetConversationHmacKeysRequest{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetConversationHmacKeysRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetConversationHmacKeysRequest) ProtoMessage() {} - -func (x *GetConversationHmacKeysRequest) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[29] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetConversationHmacKeysRequest.ProtoReflect.Descriptor instead. -func (*GetConversationHmacKeysRequest) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{29} -} - -func (x *GetConversationHmacKeysRequest) GetTopics() []string { - if x != nil { - return x.Topics - } - return nil -} - -// A mapping of topics to their HMAC keys -type GetConversationHmacKeysResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - HmacKeys map[string]*GetConversationHmacKeysResponse_HmacKeys `protobuf:"bytes,1,rep,name=hmac_keys,json=hmacKeys,proto3" json:"hmac_keys,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetConversationHmacKeysResponse) Reset() { - *x = GetConversationHmacKeysResponse{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetConversationHmacKeysResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetConversationHmacKeysResponse) ProtoMessage() {} - -func (x *GetConversationHmacKeysResponse) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[30] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetConversationHmacKeysResponse.ProtoReflect.Descriptor instead. -func (*GetConversationHmacKeysResponse) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{30} -} - -func (x *GetConversationHmacKeysResponse) GetHmacKeys() map[string]*GetConversationHmacKeysResponse_HmacKeys { - if x != nil { - return x.HmacKeys - } - return nil -} - -// A mapping of message hashes to their private preferences action -type PrivatePreferencesActionMap struct { - state protoimpl.MessageState `protogen:"open.v1"` - Actions map[string]*message_contents.PrivatePreferencesAction `protobuf:"bytes,1,rep,name=actions,proto3" json:"actions,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesActionMap) Reset() { - *x = PrivatePreferencesActionMap{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesActionMap) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesActionMap) ProtoMessage() {} - -func (x *PrivatePreferencesActionMap) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[31] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesActionMap.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesActionMap) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{31} -} - -func (x *PrivatePreferencesActionMap) GetActions() map[string]*message_contents.PrivatePreferencesAction { - if x != nil { - return x.Actions - } - return nil -} - -// A single decryption request -type DecryptV1Request_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Payload *message_contents.Ciphertext `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"` - PeerKeys *message_contents.PublicKeyBundle `protobuf:"bytes,2,opt,name=peer_keys,json=peerKeys,proto3" json:"peer_keys,omitempty"` - HeaderBytes []byte `protobuf:"bytes,3,opt,name=header_bytes,json=headerBytes,proto3" json:"header_bytes,omitempty"` - IsSender bool `protobuf:"varint,4,opt,name=is_sender,json=isSender,proto3" json:"is_sender,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DecryptV1Request_Request) Reset() { - *x = DecryptV1Request_Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DecryptV1Request_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DecryptV1Request_Request) ProtoMessage() {} - -func (x *DecryptV1Request_Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[32] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DecryptV1Request_Request.ProtoReflect.Descriptor instead. -func (*DecryptV1Request_Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{1, 0} -} - -func (x *DecryptV1Request_Request) GetPayload() *message_contents.Ciphertext { - if x != nil { - return x.Payload - } - return nil -} - -func (x *DecryptV1Request_Request) GetPeerKeys() *message_contents.PublicKeyBundle { - if x != nil { - return x.PeerKeys - } - return nil -} - -func (x *DecryptV1Request_Request) GetHeaderBytes() []byte { - if x != nil { - return x.HeaderBytes - } - return nil -} - -func (x *DecryptV1Request_Request) GetIsSender() bool { - if x != nil { - return x.IsSender - } - return false -} - -// A single decryption response -type DecryptResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Response: - // - // *DecryptResponse_Response_Result - // *DecryptResponse_Response_Error - Response isDecryptResponse_Response_Response `protobuf_oneof:"response"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DecryptResponse_Response) Reset() { - *x = DecryptResponse_Response{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DecryptResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DecryptResponse_Response) ProtoMessage() {} - -func (x *DecryptResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[33] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DecryptResponse_Response.ProtoReflect.Descriptor instead. -func (*DecryptResponse_Response) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{2, 0} -} - -func (x *DecryptResponse_Response) GetResponse() isDecryptResponse_Response_Response { - if x != nil { - return x.Response - } - return nil -} - -func (x *DecryptResponse_Response) GetResult() *DecryptResponse_Response_Success { - if x != nil { - if x, ok := x.Response.(*DecryptResponse_Response_Result); ok { - return x.Result - } - } - return nil -} - -func (x *DecryptResponse_Response) GetError() *KeystoreError { - if x != nil { - if x, ok := x.Response.(*DecryptResponse_Response_Error); ok { - return x.Error - } - } - return nil -} - -type isDecryptResponse_Response_Response interface { - isDecryptResponse_Response_Response() -} - -type DecryptResponse_Response_Result struct { - Result *DecryptResponse_Response_Success `protobuf:"bytes,1,opt,name=result,proto3,oneof"` -} - -type DecryptResponse_Response_Error struct { - Error *KeystoreError `protobuf:"bytes,2,opt,name=error,proto3,oneof"` -} - -func (*DecryptResponse_Response_Result) isDecryptResponse_Response_Response() {} - -func (*DecryptResponse_Response_Error) isDecryptResponse_Response_Response() {} - -// Wrapper object for success response -type DecryptResponse_Response_Success struct { - state protoimpl.MessageState `protogen:"open.v1"` - Decrypted []byte `protobuf:"bytes,1,opt,name=decrypted,proto3" json:"decrypted,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DecryptResponse_Response_Success) Reset() { - *x = DecryptResponse_Response_Success{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[34] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DecryptResponse_Response_Success) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DecryptResponse_Response_Success) ProtoMessage() {} - -func (x *DecryptResponse_Response_Success) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[34] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DecryptResponse_Response_Success.ProtoReflect.Descriptor instead. -func (*DecryptResponse_Response_Success) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{2, 0, 0} -} - -func (x *DecryptResponse_Response_Success) GetDecrypted() []byte { - if x != nil { - return x.Decrypted - } - return nil -} - -// A single decryption request -type DecryptV2Request_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Payload *message_contents.Ciphertext `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"` - HeaderBytes []byte `protobuf:"bytes,2,opt,name=header_bytes,json=headerBytes,proto3" json:"header_bytes,omitempty"` - ContentTopic string `protobuf:"bytes,3,opt,name=content_topic,json=contentTopic,proto3" json:"content_topic,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DecryptV2Request_Request) Reset() { - *x = DecryptV2Request_Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[35] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DecryptV2Request_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DecryptV2Request_Request) ProtoMessage() {} - -func (x *DecryptV2Request_Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[35] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DecryptV2Request_Request.ProtoReflect.Descriptor instead. -func (*DecryptV2Request_Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{3, 0} -} - -func (x *DecryptV2Request_Request) GetPayload() *message_contents.Ciphertext { - if x != nil { - return x.Payload - } - return nil -} - -func (x *DecryptV2Request_Request) GetHeaderBytes() []byte { - if x != nil { - return x.HeaderBytes - } - return nil -} - -func (x *DecryptV2Request_Request) GetContentTopic() string { - if x != nil { - return x.ContentTopic - } - return "" -} - -// A single encryption request -type EncryptV1Request_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Recipient *message_contents.PublicKeyBundle `protobuf:"bytes,1,opt,name=recipient,proto3" json:"recipient,omitempty"` - Payload []byte `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"` - HeaderBytes []byte `protobuf:"bytes,3,opt,name=header_bytes,json=headerBytes,proto3" json:"header_bytes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptV1Request_Request) Reset() { - *x = EncryptV1Request_Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[36] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptV1Request_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptV1Request_Request) ProtoMessage() {} - -func (x *EncryptV1Request_Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[36] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptV1Request_Request.ProtoReflect.Descriptor instead. -func (*EncryptV1Request_Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{4, 0} -} - -func (x *EncryptV1Request_Request) GetRecipient() *message_contents.PublicKeyBundle { - if x != nil { - return x.Recipient - } - return nil -} - -func (x *EncryptV1Request_Request) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -func (x *EncryptV1Request_Request) GetHeaderBytes() []byte { - if x != nil { - return x.HeaderBytes - } - return nil -} - -// A single encryption response -type EncryptResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Response: - // - // *EncryptResponse_Response_Result - // *EncryptResponse_Response_Error - Response isEncryptResponse_Response_Response `protobuf_oneof:"response"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptResponse_Response) Reset() { - *x = EncryptResponse_Response{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[37] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptResponse_Response) ProtoMessage() {} - -func (x *EncryptResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[37] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptResponse_Response.ProtoReflect.Descriptor instead. -func (*EncryptResponse_Response) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{5, 0} -} - -func (x *EncryptResponse_Response) GetResponse() isEncryptResponse_Response_Response { - if x != nil { - return x.Response - } - return nil -} - -func (x *EncryptResponse_Response) GetResult() *EncryptResponse_Response_Success { - if x != nil { - if x, ok := x.Response.(*EncryptResponse_Response_Result); ok { - return x.Result - } - } - return nil -} - -func (x *EncryptResponse_Response) GetError() *KeystoreError { - if x != nil { - if x, ok := x.Response.(*EncryptResponse_Response_Error); ok { - return x.Error - } - } - return nil -} - -type isEncryptResponse_Response_Response interface { - isEncryptResponse_Response_Response() -} - -type EncryptResponse_Response_Result struct { - Result *EncryptResponse_Response_Success `protobuf:"bytes,1,opt,name=result,proto3,oneof"` -} - -type EncryptResponse_Response_Error struct { - Error *KeystoreError `protobuf:"bytes,2,opt,name=error,proto3,oneof"` -} - -func (*EncryptResponse_Response_Result) isEncryptResponse_Response_Response() {} - -func (*EncryptResponse_Response_Error) isEncryptResponse_Response_Response() {} - -// Wrapper object for success response -type EncryptResponse_Response_Success struct { - state protoimpl.MessageState `protogen:"open.v1"` - Encrypted *message_contents.Ciphertext `protobuf:"bytes,1,opt,name=encrypted,proto3" json:"encrypted,omitempty"` - SenderHmac []byte `protobuf:"bytes,2,opt,name=sender_hmac,json=senderHmac,proto3" json:"sender_hmac,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptResponse_Response_Success) Reset() { - *x = EncryptResponse_Response_Success{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[38] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptResponse_Response_Success) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptResponse_Response_Success) ProtoMessage() {} - -func (x *EncryptResponse_Response_Success) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[38] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptResponse_Response_Success.ProtoReflect.Descriptor instead. -func (*EncryptResponse_Response_Success) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{5, 0, 0} -} - -func (x *EncryptResponse_Response_Success) GetEncrypted() *message_contents.Ciphertext { - if x != nil { - return x.Encrypted - } - return nil -} - -func (x *EncryptResponse_Response_Success) GetSenderHmac() []byte { - if x != nil { - return x.SenderHmac - } - return nil -} - -// A single encryption request -type EncryptV2Request_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Payload []byte `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"` - HeaderBytes []byte `protobuf:"bytes,2,opt,name=header_bytes,json=headerBytes,proto3" json:"header_bytes,omitempty"` - ContentTopic string `protobuf:"bytes,3,opt,name=content_topic,json=contentTopic,proto3" json:"content_topic,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptV2Request_Request) Reset() { - *x = EncryptV2Request_Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[39] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptV2Request_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptV2Request_Request) ProtoMessage() {} - -func (x *EncryptV2Request_Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[39] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptV2Request_Request.ProtoReflect.Descriptor instead. -func (*EncryptV2Request_Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{6, 0} -} - -func (x *EncryptV2Request_Request) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -func (x *EncryptV2Request_Request) GetHeaderBytes() []byte { - if x != nil { - return x.HeaderBytes - } - return nil -} - -func (x *EncryptV2Request_Request) GetContentTopic() string { - if x != nil { - return x.ContentTopic - } - return "" -} - -// Request type -type SelfEncryptRequest_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Payload []byte `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SelfEncryptRequest_Request) Reset() { - *x = SelfEncryptRequest_Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[40] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SelfEncryptRequest_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SelfEncryptRequest_Request) ProtoMessage() {} - -func (x *SelfEncryptRequest_Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[40] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SelfEncryptRequest_Request.ProtoReflect.Descriptor instead. -func (*SelfEncryptRequest_Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{7, 0} -} - -func (x *SelfEncryptRequest_Request) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -// Response type -type SelfEncryptResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Response: - // - // *SelfEncryptResponse_Response_Result - // *SelfEncryptResponse_Response_Error - Response isSelfEncryptResponse_Response_Response `protobuf_oneof:"response"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SelfEncryptResponse_Response) Reset() { - *x = SelfEncryptResponse_Response{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[41] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SelfEncryptResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SelfEncryptResponse_Response) ProtoMessage() {} - -func (x *SelfEncryptResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[41] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SelfEncryptResponse_Response.ProtoReflect.Descriptor instead. -func (*SelfEncryptResponse_Response) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{8, 0} -} - -func (x *SelfEncryptResponse_Response) GetResponse() isSelfEncryptResponse_Response_Response { - if x != nil { - return x.Response - } - return nil -} - -func (x *SelfEncryptResponse_Response) GetResult() *SelfEncryptResponse_Response_Success { - if x != nil { - if x, ok := x.Response.(*SelfEncryptResponse_Response_Result); ok { - return x.Result - } - } - return nil -} - -func (x *SelfEncryptResponse_Response) GetError() *KeystoreError { - if x != nil { - if x, ok := x.Response.(*SelfEncryptResponse_Response_Error); ok { - return x.Error - } - } - return nil -} - -type isSelfEncryptResponse_Response_Response interface { - isSelfEncryptResponse_Response_Response() -} - -type SelfEncryptResponse_Response_Result struct { - Result *SelfEncryptResponse_Response_Success `protobuf:"bytes,1,opt,name=result,proto3,oneof"` -} - -type SelfEncryptResponse_Response_Error struct { - Error *KeystoreError `protobuf:"bytes,2,opt,name=error,proto3,oneof"` -} - -func (*SelfEncryptResponse_Response_Result) isSelfEncryptResponse_Response_Response() {} - -func (*SelfEncryptResponse_Response_Error) isSelfEncryptResponse_Response_Response() {} - -// Success response -type SelfEncryptResponse_Response_Success struct { - state protoimpl.MessageState `protogen:"open.v1"` - Encrypted []byte `protobuf:"bytes,1,opt,name=encrypted,proto3" json:"encrypted,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SelfEncryptResponse_Response_Success) Reset() { - *x = SelfEncryptResponse_Response_Success{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[42] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SelfEncryptResponse_Response_Success) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SelfEncryptResponse_Response_Success) ProtoMessage() {} - -func (x *SelfEncryptResponse_Response_Success) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[42] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SelfEncryptResponse_Response_Success.ProtoReflect.Descriptor instead. -func (*SelfEncryptResponse_Response_Success) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{8, 0, 0} -} - -func (x *SelfEncryptResponse_Response_Success) GetEncrypted() []byte { - if x != nil { - return x.Encrypted - } - return nil -} - -// Request type -type SelfDecryptRequest_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Payload []byte `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SelfDecryptRequest_Request) Reset() { - *x = SelfDecryptRequest_Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[43] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SelfDecryptRequest_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SelfDecryptRequest_Request) ProtoMessage() {} - -func (x *SelfDecryptRequest_Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[43] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SelfDecryptRequest_Request.ProtoReflect.Descriptor instead. -func (*SelfDecryptRequest_Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{9, 0} -} - -func (x *SelfDecryptRequest_Request) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -// Mirrors xmtp.envelope schema -type SaveInvitesRequest_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - ContentTopic string `protobuf:"bytes,1,opt,name=content_topic,json=contentTopic,proto3" json:"content_topic,omitempty"` - TimestampNs uint64 `protobuf:"varint,2,opt,name=timestamp_ns,json=timestampNs,proto3" json:"timestamp_ns,omitempty"` - Payload []byte `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SaveInvitesRequest_Request) Reset() { - *x = SaveInvitesRequest_Request{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[44] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SaveInvitesRequest_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SaveInvitesRequest_Request) ProtoMessage() {} - -func (x *SaveInvitesRequest_Request) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[44] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SaveInvitesRequest_Request.ProtoReflect.Descriptor instead. -func (*SaveInvitesRequest_Request) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{13, 0} -} - -func (x *SaveInvitesRequest_Request) GetContentTopic() string { - if x != nil { - return x.ContentTopic - } - return "" -} - -func (x *SaveInvitesRequest_Request) GetTimestampNs() uint64 { - if x != nil { - return x.TimestampNs - } - return 0 -} - -func (x *SaveInvitesRequest_Request) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -// A single response -type SaveInvitesResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Response: - // - // *SaveInvitesResponse_Response_Result - // *SaveInvitesResponse_Response_Error - Response isSaveInvitesResponse_Response_Response `protobuf_oneof:"response"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SaveInvitesResponse_Response) Reset() { - *x = SaveInvitesResponse_Response{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[45] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SaveInvitesResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SaveInvitesResponse_Response) ProtoMessage() {} - -func (x *SaveInvitesResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[45] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SaveInvitesResponse_Response.ProtoReflect.Descriptor instead. -func (*SaveInvitesResponse_Response) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{14, 0} -} - -func (x *SaveInvitesResponse_Response) GetResponse() isSaveInvitesResponse_Response_Response { - if x != nil { - return x.Response - } - return nil -} - -func (x *SaveInvitesResponse_Response) GetResult() *SaveInvitesResponse_Response_Success { - if x != nil { - if x, ok := x.Response.(*SaveInvitesResponse_Response_Result); ok { - return x.Result - } - } - return nil -} - -func (x *SaveInvitesResponse_Response) GetError() *KeystoreError { - if x != nil { - if x, ok := x.Response.(*SaveInvitesResponse_Response_Error); ok { - return x.Error - } - } - return nil -} - -type isSaveInvitesResponse_Response_Response interface { - isSaveInvitesResponse_Response_Response() -} - -type SaveInvitesResponse_Response_Result struct { - Result *SaveInvitesResponse_Response_Success `protobuf:"bytes,1,opt,name=result,proto3,oneof"` -} - -type SaveInvitesResponse_Response_Error struct { - Error *KeystoreError `protobuf:"bytes,2,opt,name=error,proto3,oneof"` -} - -func (*SaveInvitesResponse_Response_Result) isSaveInvitesResponse_Response_Response() {} - -func (*SaveInvitesResponse_Response_Error) isSaveInvitesResponse_Response_Response() {} - -// Wrapper object for success response -type SaveInvitesResponse_Response_Success struct { - state protoimpl.MessageState `protogen:"open.v1"` - Conversation *message_contents.ConversationReference `protobuf:"bytes,1,opt,name=conversation,proto3" json:"conversation,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SaveInvitesResponse_Response_Success) Reset() { - *x = SaveInvitesResponse_Response_Success{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[46] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SaveInvitesResponse_Response_Success) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SaveInvitesResponse_Response_Success) ProtoMessage() {} - -func (x *SaveInvitesResponse_Response_Success) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[46] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SaveInvitesResponse_Response_Success.ProtoReflect.Descriptor instead. -func (*SaveInvitesResponse_Response_Success) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{14, 0, 0} -} - -func (x *SaveInvitesResponse_Response_Success) GetConversation() *message_contents.ConversationReference { - if x != nil { - return x.Conversation - } - return nil -} - -// TopicData wraps the invitation and the timestamp it was created -type TopicMap_TopicData struct { - state protoimpl.MessageState `protogen:"open.v1"` - CreatedNs uint64 `protobuf:"varint,1,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - PeerAddress string `protobuf:"bytes,2,opt,name=peer_address,json=peerAddress,proto3" json:"peer_address,omitempty"` - Invitation *message_contents.InvitationV1 `protobuf:"bytes,3,opt,name=invitation,proto3" json:"invitation,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *TopicMap_TopicData) Reset() { - *x = TopicMap_TopicData{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[47] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *TopicMap_TopicData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TopicMap_TopicData) ProtoMessage() {} - -func (x *TopicMap_TopicData) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[47] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TopicMap_TopicData.ProtoReflect.Descriptor instead. -func (*TopicMap_TopicData) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{28, 0} -} - -func (x *TopicMap_TopicData) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *TopicMap_TopicData) GetPeerAddress() string { - if x != nil { - return x.PeerAddress - } - return "" -} - -func (x *TopicMap_TopicData) GetInvitation() *message_contents.InvitationV1 { - if x != nil { - return x.Invitation - } - return nil -} - -// HmacKeyData wraps the HMAC key and the number of 30 day periods since epoch -type GetConversationHmacKeysResponse_HmacKeyData struct { - state protoimpl.MessageState `protogen:"open.v1"` - ThirtyDayPeriodsSinceEpoch int32 `protobuf:"varint,1,opt,name=thirty_day_periods_since_epoch,json=thirtyDayPeriodsSinceEpoch,proto3" json:"thirty_day_periods_since_epoch,omitempty"` - HmacKey []byte `protobuf:"bytes,2,opt,name=hmac_key,json=hmacKey,proto3" json:"hmac_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetConversationHmacKeysResponse_HmacKeyData) Reset() { - *x = GetConversationHmacKeysResponse_HmacKeyData{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[49] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetConversationHmacKeysResponse_HmacKeyData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetConversationHmacKeysResponse_HmacKeyData) ProtoMessage() {} - -func (x *GetConversationHmacKeysResponse_HmacKeyData) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[49] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetConversationHmacKeysResponse_HmacKeyData.ProtoReflect.Descriptor instead. -func (*GetConversationHmacKeysResponse_HmacKeyData) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{30, 0} -} - -func (x *GetConversationHmacKeysResponse_HmacKeyData) GetThirtyDayPeriodsSinceEpoch() int32 { - if x != nil { - return x.ThirtyDayPeriodsSinceEpoch - } - return 0 -} - -func (x *GetConversationHmacKeysResponse_HmacKeyData) GetHmacKey() []byte { - if x != nil { - return x.HmacKey - } - return nil -} - -// HmacKeys represents multiple HmacKeyData objects -type GetConversationHmacKeysResponse_HmacKeys struct { - state protoimpl.MessageState `protogen:"open.v1"` - Values []*GetConversationHmacKeysResponse_HmacKeyData `protobuf:"bytes,1,rep,name=values,proto3" json:"values,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetConversationHmacKeysResponse_HmacKeys) Reset() { - *x = GetConversationHmacKeysResponse_HmacKeys{} - mi := &file_keystore_api_v1_keystore_proto_msgTypes[50] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetConversationHmacKeysResponse_HmacKeys) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetConversationHmacKeysResponse_HmacKeys) ProtoMessage() {} - -func (x *GetConversationHmacKeysResponse_HmacKeys) ProtoReflect() protoreflect.Message { - mi := &file_keystore_api_v1_keystore_proto_msgTypes[50] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetConversationHmacKeysResponse_HmacKeys.ProtoReflect.Descriptor instead. -func (*GetConversationHmacKeysResponse_HmacKeys) Descriptor() ([]byte, []int) { - return file_keystore_api_v1_keystore_proto_rawDescGZIP(), []int{30, 1} -} - -func (x *GetConversationHmacKeysResponse_HmacKeys) GetValues() []*GetConversationHmacKeysResponse_HmacKeyData { - if x != nil { - return x.Values - } - return nil -} - -var File_keystore_api_v1_keystore_proto protoreflect.FileDescriptor - -const file_keystore_api_v1_keystore_proto_rawDesc = "" + - "\n" + - "\x1ekeystore_api/v1/keystore.proto\x12\x14xmtp.keystore_api.v1\x1a!message_contents/ciphertext.proto\x1a-message_contents/conversation_reference.proto\x1a!message_contents/invitation.proto\x1a\"message_contents/private_key.proto\x1a*message_contents/private_preferences.proto\x1a!message_contents/public_key.proto\"^\n" + - "\rKeystoreError\x12\x18\n" + - "\amessage\x18\x01 \x01(\tR\amessage\x123\n" + - "\x04code\x18\x02 \x01(\x0e2\x1f.xmtp.keystore_api.v1.ErrorCodeR\x04code\"\xac\x02\n" + - "\x10DecryptV1Request\x12J\n" + - "\brequests\x18\x01 \x03(\v2..xmtp.keystore_api.v1.DecryptV1Request.RequestR\brequests\x1a\xcb\x01\n" + - "\aRequest\x12;\n" + - "\apayload\x18\x01 \x01(\v2!.xmtp.message_contents.CiphertextR\apayload\x12C\n" + - "\tpeer_keys\x18\x02 \x01(\v2&.xmtp.message_contents.PublicKeyBundleR\bpeerKeys\x12!\n" + - "\fheader_bytes\x18\x03 \x01(\fR\vheaderBytes\x12\x1b\n" + - "\tis_sender\x18\x04 \x01(\bR\bisSender\"\xb0\x02\n" + - "\x0fDecryptResponse\x12L\n" + - "\tresponses\x18\x01 \x03(\v2..xmtp.keystore_api.v1.DecryptResponse.ResponseR\tresponses\x1a\xce\x01\n" + - "\bResponse\x12P\n" + - "\x06result\x18\x01 \x01(\v26.xmtp.keystore_api.v1.DecryptResponse.Response.SuccessH\x00R\x06result\x12;\n" + - "\x05error\x18\x02 \x01(\v2#.xmtp.keystore_api.v1.KeystoreErrorH\x00R\x05error\x1a'\n" + - "\aSuccess\x12\x1c\n" + - "\tdecrypted\x18\x01 \x01(\fR\tdecryptedB\n" + - "\n" + - "\bresponse\"\xef\x01\n" + - "\x10DecryptV2Request\x12J\n" + - "\brequests\x18\x01 \x03(\v2..xmtp.keystore_api.v1.DecryptV2Request.RequestR\brequests\x1a\x8e\x01\n" + - "\aRequest\x12;\n" + - "\apayload\x18\x01 \x01(\v2!.xmtp.message_contents.CiphertextR\apayload\x12!\n" + - "\fheader_bytes\x18\x02 \x01(\fR\vheaderBytes\x12#\n" + - "\rcontent_topic\x18\x03 \x01(\tR\fcontentTopic\"\xed\x01\n" + - "\x10EncryptV1Request\x12J\n" + - "\brequests\x18\x01 \x03(\v2..xmtp.keystore_api.v1.EncryptV1Request.RequestR\brequests\x1a\x8c\x01\n" + - "\aRequest\x12D\n" + - "\trecipient\x18\x01 \x01(\v2&.xmtp.message_contents.PublicKeyBundleR\trecipient\x12\x18\n" + - "\apayload\x18\x02 \x01(\fR\apayload\x12!\n" + - "\fheader_bytes\x18\x03 \x01(\fR\vheaderBytes\"\xf4\x02\n" + - "\x0fEncryptResponse\x12L\n" + - "\tresponses\x18\x01 \x03(\v2..xmtp.keystore_api.v1.EncryptResponse.ResponseR\tresponses\x1a\x92\x02\n" + - "\bResponse\x12P\n" + - "\x06result\x18\x01 \x01(\v26.xmtp.keystore_api.v1.EncryptResponse.Response.SuccessH\x00R\x06result\x12;\n" + - "\x05error\x18\x02 \x01(\v2#.xmtp.keystore_api.v1.KeystoreErrorH\x00R\x05error\x1ak\n" + - "\aSuccess\x12?\n" + - "\tencrypted\x18\x01 \x01(\v2!.xmtp.message_contents.CiphertextR\tencrypted\x12\x1f\n" + - "\vsender_hmac\x18\x02 \x01(\fR\n" + - "senderHmacB\n" + - "\n" + - "\bresponse\"\xcb\x01\n" + - "\x10EncryptV2Request\x12J\n" + - "\brequests\x18\x01 \x03(\v2..xmtp.keystore_api.v1.EncryptV2Request.RequestR\brequests\x1ak\n" + - "\aRequest\x12\x18\n" + - "\apayload\x18\x01 \x01(\fR\apayload\x12!\n" + - "\fheader_bytes\x18\x02 \x01(\fR\vheaderBytes\x12#\n" + - "\rcontent_topic\x18\x03 \x01(\tR\fcontentTopic\"\x87\x01\n" + - "\x12SelfEncryptRequest\x12L\n" + - "\brequests\x18\x01 \x03(\v20.xmtp.keystore_api.v1.SelfEncryptRequest.RequestR\brequests\x1a#\n" + - "\aRequest\x12\x18\n" + - "\apayload\x18\x01 \x01(\fR\apayload\"\xbc\x02\n" + - "\x13SelfEncryptResponse\x12P\n" + - "\tresponses\x18\x01 \x03(\v22.xmtp.keystore_api.v1.SelfEncryptResponse.ResponseR\tresponses\x1a\xd2\x01\n" + - "\bResponse\x12T\n" + - "\x06result\x18\x01 \x01(\v2:.xmtp.keystore_api.v1.SelfEncryptResponse.Response.SuccessH\x00R\x06result\x12;\n" + - "\x05error\x18\x02 \x01(\v2#.xmtp.keystore_api.v1.KeystoreErrorH\x00R\x05error\x1a'\n" + - "\aSuccess\x12\x1c\n" + - "\tencrypted\x18\x01 \x01(\fR\tencryptedB\n" + - "\n" + - "\bresponse\"\x87\x01\n" + - "\x12SelfDecryptRequest\x12L\n" + - "\brequests\x18\x01 \x03(\v20.xmtp.keystore_api.v1.SelfDecryptRequest.RequestR\brequests\x1a#\n" + - "\aRequest\x12\x18\n" + - "\apayload\x18\x01 \x01(\fR\apayload\"N\n" + - ",GetPrivatePreferencesTopicIdentifierResponse\x12\x1e\n" + - "\n" + - "identifier\x18\x01 \x01(\tR\n" + - "identifier\"\x98\x02\n" + - "\x13CreateInviteRequest\x12E\n" + - "\acontext\x18\x01 \x01(\v2+.xmtp.message_contents.InvitationV1.ContextR\acontext\x12J\n" + - "\trecipient\x18\x02 \x01(\v2,.xmtp.message_contents.SignedPublicKeyBundleR\trecipient\x12\x1d\n" + - "\n" + - "created_ns\x18\x03 \x01(\x04R\tcreatedNs\x12O\n" + - "\rconsent_proof\x18\x04 \x01(\v2*.xmtp.message_contents.ConsentProofPayloadR\fconsentProof\"\x82\x01\n" + - "\x14CreateInviteResponse\x12P\n" + - "\fconversation\x18\x01 \x01(\v2,.xmtp.message_contents.ConversationReferenceR\fconversation\x12\x18\n" + - "\apayload\x18\x02 \x01(\fR\apayload\"\xcf\x01\n" + - "\x12SaveInvitesRequest\x12L\n" + - "\brequests\x18\x01 \x03(\v20.xmtp.keystore_api.v1.SaveInvitesRequest.RequestR\brequests\x1ak\n" + - "\aRequest\x12#\n" + - "\rcontent_topic\x18\x01 \x01(\tR\fcontentTopic\x12!\n" + - "\ftimestamp_ns\x18\x02 \x01(\x04R\vtimestampNs\x12\x18\n" + - "\apayload\x18\x03 \x01(\fR\apayload\"\xf0\x02\n" + - "\x13SaveInvitesResponse\x12P\n" + - "\tresponses\x18\x01 \x03(\v22.xmtp.keystore_api.v1.SaveInvitesResponse.ResponseR\tresponses\x1a\x86\x02\n" + - "\bResponse\x12T\n" + - "\x06result\x18\x01 \x01(\v2:.xmtp.keystore_api.v1.SaveInvitesResponse.Response.SuccessH\x00R\x06result\x12;\n" + - "\x05error\x18\x02 \x01(\v2#.xmtp.keystore_api.v1.KeystoreErrorH\x00R\x05error\x1a[\n" + - "\aSuccess\x12P\n" + - "\fconversation\x18\x01 \x01(\v2,.xmtp.message_contents.ConversationReferenceR\fconversationB\n" + - "\n" + - "\bresponse\"Q\n" + - "\x16CreateAuthTokenRequest\x12&\n" + - "\ftimestamp_ns\x18\x01 \x01(\x04H\x00R\vtimestampNs\x88\x01\x01B\x0f\n" + - "\r_timestamp_ns\"p\n" + - "\x1aSaveV1ConversationsRequest\x12R\n" + - "\rconversations\x18\x01 \x03(\v2,.xmtp.message_contents.ConversationReferenceR\rconversations\"\x1d\n" + - "\x1bSaveV1ConversationsResponse\"n\n" + - "\x18GetConversationsResponse\x12R\n" + - "\rconversations\x18\x01 \x03(\v2,.xmtp.message_contents.ConversationReferenceR\rconversations\"A\n" + - "\x18GetKeystoreStatusRequest\x12%\n" + - "\x0ewallet_address\x18\x01 \x01(\tR\rwalletAddress\"\xea\x01\n" + - "\x19GetKeystoreStatusResponse\x12V\n" + - "\x06status\x18\x01 \x01(\x0e2>.xmtp.keystore_api.v1.GetKeystoreStatusResponse.KeystoreStatusR\x06status\"u\n" + - "\x0eKeystoreStatus\x12\x1f\n" + - "\x1bKEYSTORE_STATUS_UNSPECIFIED\x10\x00\x12!\n" + - "\x1dKEYSTORE_STATUS_UNINITIALIZED\x10\x01\x12\x1f\n" + - "\x1bKEYSTORE_STATUS_INITIALIZED\x10\x02\"\\\n" + - "\x13InitKeystoreRequest\x12;\n" + - "\x02v1\x18\x01 \x01(\v2).xmtp.message_contents.PrivateKeyBundleV1H\x00R\x02v1B\b\n" + - "\x06bundle\"Q\n" + - "\x14InitKeystoreResponse\x129\n" + - "\x05error\x18\x01 \x01(\v2#.xmtp.keystore_api.v1.KeystoreErrorR\x05error\"\x7f\n" + - "\x11SignDigestRequest\x12\x16\n" + - "\x06digest\x18\x01 \x01(\fR\x06digest\x12#\n" + - "\fidentity_key\x18\x02 \x01(\bH\x00R\videntityKey\x12#\n" + - "\fprekey_index\x18\x03 \x01(\rH\x00R\vprekeyIndexB\b\n" + - "\x06signer\"P\n" + - "\x14GetRefreshJobRequest\x128\n" + - "\bjob_type\x18\x01 \x01(\x0e2\x1d.xmtp.keystore_api.v1.JobTypeR\ajobType\"7\n" + - "\x15GetRefreshJobResponse\x12\x1e\n" + - "\vlast_run_ns\x18\x01 \x01(\x03R\tlastRunNs\"o\n" + - "\x13SetRefeshJobRequest\x128\n" + - "\bjob_type\x18\x01 \x01(\x0e2\x1d.xmtp.keystore_api.v1.JobTypeR\ajobType\x12\x1e\n" + - "\vlast_run_ns\x18\x02 \x01(\x03R\tlastRunNs\"\x17\n" + - "\x15SetRefreshJobResponse\"\xc8\x02\n" + - "\bTopicMap\x12B\n" + - "\x06topics\x18\x01 \x03(\v2*.xmtp.keystore_api.v1.TopicMap.TopicsEntryR\x06topics\x1a\x92\x01\n" + - "\tTopicData\x12\x1d\n" + - "\n" + - "created_ns\x18\x01 \x01(\x04R\tcreatedNs\x12!\n" + - "\fpeer_address\x18\x02 \x01(\tR\vpeerAddress\x12C\n" + - "\n" + - "invitation\x18\x03 \x01(\v2#.xmtp.message_contents.InvitationV1R\n" + - "invitation\x1ac\n" + - "\vTopicsEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12>\n" + - "\x05value\x18\x02 \x01(\v2(.xmtp.keystore_api.v1.TopicMap.TopicDataR\x05value:\x028\x01\"8\n" + - "\x1eGetConversationHmacKeysRequest\x12\x16\n" + - "\x06topics\x18\x01 \x03(\tR\x06topics\"\xd5\x03\n" + - "\x1fGetConversationHmacKeysResponse\x12`\n" + - "\thmac_keys\x18\x01 \x03(\v2C.xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeysEntryR\bhmacKeys\x1al\n" + - "\vHmacKeyData\x12B\n" + - "\x1ethirty_day_periods_since_epoch\x18\x01 \x01(\x05R\x1athirtyDayPeriodsSinceEpoch\x12\x19\n" + - "\bhmac_key\x18\x02 \x01(\fR\ahmacKey\x1ae\n" + - "\bHmacKeys\x12Y\n" + - "\x06values\x18\x01 \x03(\v2A.xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeyDataR\x06values\x1a{\n" + - "\rHmacKeysEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12T\n" + - "\x05value\x18\x02 \x01(\v2>.xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeysR\x05value:\x028\x01\"\xe4\x01\n" + - "\x1bPrivatePreferencesActionMap\x12X\n" + - "\aactions\x18\x01 \x03(\v2>.xmtp.keystore_api.v1.PrivatePreferencesActionMap.ActionsEntryR\aactions\x1ak\n" + - "\fActionsEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12E\n" + - "\x05value\x18\x02 \x01(\v2/.xmtp.message_contents.PrivatePreferencesActionR\x05value:\x028\x01*h\n" + - "\tErrorCode\x12\x1a\n" + - "\x16ERROR_CODE_UNSPECIFIED\x10\x00\x12\x1c\n" + - "\x18ERROR_CODE_INVALID_INPUT\x10\x01\x12!\n" + - "\x1dERROR_CODE_NO_MATCHING_PREKEY\x10\x02*p\n" + - "\aJobType\x12\x18\n" + - "\x14JOB_TYPE_UNSPECIFIED\x10\x00\x12\x17\n" + - "\x13JOB_TYPE_REFRESH_V1\x10\x01\x12\x17\n" + - "\x13JOB_TYPE_REFRESH_V2\x10\x02\x12\x19\n" + - "\x15JOB_TYPE_REFRESH_PPPP\x10\x03B\x8a\x02\n" + - "2org.xmtp.android.library.push.xmtp.keystore_api.v1B\rKeystoreProtoP\x01ZWgithub.com/xmtp/example-notification-server-go/pkg/proto/keystore_api/v1;keystore_apiv1\xa2\x02\x03XKX\xaa\x02\x13Xmtp.KeystoreApi.V1\xca\x02\x13Xmtp\\KeystoreApi\\V1\xe2\x02\x1fXmtp\\KeystoreApi\\V1\\GPBMetadata\xea\x02\x15Xmtp::KeystoreApi::V1b\x06proto3" - -var ( - file_keystore_api_v1_keystore_proto_rawDescOnce sync.Once - file_keystore_api_v1_keystore_proto_rawDescData []byte -) - -func file_keystore_api_v1_keystore_proto_rawDescGZIP() []byte { - file_keystore_api_v1_keystore_proto_rawDescOnce.Do(func() { - file_keystore_api_v1_keystore_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_keystore_api_v1_keystore_proto_rawDesc), len(file_keystore_api_v1_keystore_proto_rawDesc))) - }) - return file_keystore_api_v1_keystore_proto_rawDescData -} - -var file_keystore_api_v1_keystore_proto_enumTypes = make([]protoimpl.EnumInfo, 3) -var file_keystore_api_v1_keystore_proto_msgTypes = make([]protoimpl.MessageInfo, 53) -var file_keystore_api_v1_keystore_proto_goTypes = []any{ - (ErrorCode)(0), // 0: xmtp.keystore_api.v1.ErrorCode - (JobType)(0), // 1: xmtp.keystore_api.v1.JobType - (GetKeystoreStatusResponse_KeystoreStatus)(0), // 2: xmtp.keystore_api.v1.GetKeystoreStatusResponse.KeystoreStatus - (*KeystoreError)(nil), // 3: xmtp.keystore_api.v1.KeystoreError - (*DecryptV1Request)(nil), // 4: xmtp.keystore_api.v1.DecryptV1Request - (*DecryptResponse)(nil), // 5: xmtp.keystore_api.v1.DecryptResponse - (*DecryptV2Request)(nil), // 6: xmtp.keystore_api.v1.DecryptV2Request - (*EncryptV1Request)(nil), // 7: xmtp.keystore_api.v1.EncryptV1Request - (*EncryptResponse)(nil), // 8: xmtp.keystore_api.v1.EncryptResponse - (*EncryptV2Request)(nil), // 9: xmtp.keystore_api.v1.EncryptV2Request - (*SelfEncryptRequest)(nil), // 10: xmtp.keystore_api.v1.SelfEncryptRequest - (*SelfEncryptResponse)(nil), // 11: xmtp.keystore_api.v1.SelfEncryptResponse - (*SelfDecryptRequest)(nil), // 12: xmtp.keystore_api.v1.SelfDecryptRequest - (*GetPrivatePreferencesTopicIdentifierResponse)(nil), // 13: xmtp.keystore_api.v1.GetPrivatePreferencesTopicIdentifierResponse - (*CreateInviteRequest)(nil), // 14: xmtp.keystore_api.v1.CreateInviteRequest - (*CreateInviteResponse)(nil), // 15: xmtp.keystore_api.v1.CreateInviteResponse - (*SaveInvitesRequest)(nil), // 16: xmtp.keystore_api.v1.SaveInvitesRequest - (*SaveInvitesResponse)(nil), // 17: xmtp.keystore_api.v1.SaveInvitesResponse - (*CreateAuthTokenRequest)(nil), // 18: xmtp.keystore_api.v1.CreateAuthTokenRequest - (*SaveV1ConversationsRequest)(nil), // 19: xmtp.keystore_api.v1.SaveV1ConversationsRequest - (*SaveV1ConversationsResponse)(nil), // 20: xmtp.keystore_api.v1.SaveV1ConversationsResponse - (*GetConversationsResponse)(nil), // 21: xmtp.keystore_api.v1.GetConversationsResponse - (*GetKeystoreStatusRequest)(nil), // 22: xmtp.keystore_api.v1.GetKeystoreStatusRequest - (*GetKeystoreStatusResponse)(nil), // 23: xmtp.keystore_api.v1.GetKeystoreStatusResponse - (*InitKeystoreRequest)(nil), // 24: xmtp.keystore_api.v1.InitKeystoreRequest - (*InitKeystoreResponse)(nil), // 25: xmtp.keystore_api.v1.InitKeystoreResponse - (*SignDigestRequest)(nil), // 26: xmtp.keystore_api.v1.SignDigestRequest - (*GetRefreshJobRequest)(nil), // 27: xmtp.keystore_api.v1.GetRefreshJobRequest - (*GetRefreshJobResponse)(nil), // 28: xmtp.keystore_api.v1.GetRefreshJobResponse - (*SetRefeshJobRequest)(nil), // 29: xmtp.keystore_api.v1.SetRefeshJobRequest - (*SetRefreshJobResponse)(nil), // 30: xmtp.keystore_api.v1.SetRefreshJobResponse - (*TopicMap)(nil), // 31: xmtp.keystore_api.v1.TopicMap - (*GetConversationHmacKeysRequest)(nil), // 32: xmtp.keystore_api.v1.GetConversationHmacKeysRequest - (*GetConversationHmacKeysResponse)(nil), // 33: xmtp.keystore_api.v1.GetConversationHmacKeysResponse - (*PrivatePreferencesActionMap)(nil), // 34: xmtp.keystore_api.v1.PrivatePreferencesActionMap - (*DecryptV1Request_Request)(nil), // 35: xmtp.keystore_api.v1.DecryptV1Request.Request - (*DecryptResponse_Response)(nil), // 36: xmtp.keystore_api.v1.DecryptResponse.Response - (*DecryptResponse_Response_Success)(nil), // 37: xmtp.keystore_api.v1.DecryptResponse.Response.Success - (*DecryptV2Request_Request)(nil), // 38: xmtp.keystore_api.v1.DecryptV2Request.Request - (*EncryptV1Request_Request)(nil), // 39: xmtp.keystore_api.v1.EncryptV1Request.Request - (*EncryptResponse_Response)(nil), // 40: xmtp.keystore_api.v1.EncryptResponse.Response - (*EncryptResponse_Response_Success)(nil), // 41: xmtp.keystore_api.v1.EncryptResponse.Response.Success - (*EncryptV2Request_Request)(nil), // 42: xmtp.keystore_api.v1.EncryptV2Request.Request - (*SelfEncryptRequest_Request)(nil), // 43: xmtp.keystore_api.v1.SelfEncryptRequest.Request - (*SelfEncryptResponse_Response)(nil), // 44: xmtp.keystore_api.v1.SelfEncryptResponse.Response - (*SelfEncryptResponse_Response_Success)(nil), // 45: xmtp.keystore_api.v1.SelfEncryptResponse.Response.Success - (*SelfDecryptRequest_Request)(nil), // 46: xmtp.keystore_api.v1.SelfDecryptRequest.Request - (*SaveInvitesRequest_Request)(nil), // 47: xmtp.keystore_api.v1.SaveInvitesRequest.Request - (*SaveInvitesResponse_Response)(nil), // 48: xmtp.keystore_api.v1.SaveInvitesResponse.Response - (*SaveInvitesResponse_Response_Success)(nil), // 49: xmtp.keystore_api.v1.SaveInvitesResponse.Response.Success - (*TopicMap_TopicData)(nil), // 50: xmtp.keystore_api.v1.TopicMap.TopicData - nil, // 51: xmtp.keystore_api.v1.TopicMap.TopicsEntry - (*GetConversationHmacKeysResponse_HmacKeyData)(nil), // 52: xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeyData - (*GetConversationHmacKeysResponse_HmacKeys)(nil), // 53: xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeys - nil, // 54: xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeysEntry - nil, // 55: xmtp.keystore_api.v1.PrivatePreferencesActionMap.ActionsEntry - (*message_contents.InvitationV1_Context)(nil), // 56: xmtp.message_contents.InvitationV1.Context - (*message_contents.SignedPublicKeyBundle)(nil), // 57: xmtp.message_contents.SignedPublicKeyBundle - (*message_contents.ConsentProofPayload)(nil), // 58: xmtp.message_contents.ConsentProofPayload - (*message_contents.ConversationReference)(nil), // 59: xmtp.message_contents.ConversationReference - (*message_contents.PrivateKeyBundleV1)(nil), // 60: xmtp.message_contents.PrivateKeyBundleV1 - (*message_contents.Ciphertext)(nil), // 61: xmtp.message_contents.Ciphertext - (*message_contents.PublicKeyBundle)(nil), // 62: xmtp.message_contents.PublicKeyBundle - (*message_contents.InvitationV1)(nil), // 63: xmtp.message_contents.InvitationV1 - (*message_contents.PrivatePreferencesAction)(nil), // 64: xmtp.message_contents.PrivatePreferencesAction -} -var file_keystore_api_v1_keystore_proto_depIdxs = []int32{ - 0, // 0: xmtp.keystore_api.v1.KeystoreError.code:type_name -> xmtp.keystore_api.v1.ErrorCode - 35, // 1: xmtp.keystore_api.v1.DecryptV1Request.requests:type_name -> xmtp.keystore_api.v1.DecryptV1Request.Request - 36, // 2: xmtp.keystore_api.v1.DecryptResponse.responses:type_name -> xmtp.keystore_api.v1.DecryptResponse.Response - 38, // 3: xmtp.keystore_api.v1.DecryptV2Request.requests:type_name -> xmtp.keystore_api.v1.DecryptV2Request.Request - 39, // 4: xmtp.keystore_api.v1.EncryptV1Request.requests:type_name -> xmtp.keystore_api.v1.EncryptV1Request.Request - 40, // 5: xmtp.keystore_api.v1.EncryptResponse.responses:type_name -> xmtp.keystore_api.v1.EncryptResponse.Response - 42, // 6: xmtp.keystore_api.v1.EncryptV2Request.requests:type_name -> xmtp.keystore_api.v1.EncryptV2Request.Request - 43, // 7: xmtp.keystore_api.v1.SelfEncryptRequest.requests:type_name -> xmtp.keystore_api.v1.SelfEncryptRequest.Request - 44, // 8: xmtp.keystore_api.v1.SelfEncryptResponse.responses:type_name -> xmtp.keystore_api.v1.SelfEncryptResponse.Response - 46, // 9: xmtp.keystore_api.v1.SelfDecryptRequest.requests:type_name -> xmtp.keystore_api.v1.SelfDecryptRequest.Request - 56, // 10: xmtp.keystore_api.v1.CreateInviteRequest.context:type_name -> xmtp.message_contents.InvitationV1.Context - 57, // 11: xmtp.keystore_api.v1.CreateInviteRequest.recipient:type_name -> xmtp.message_contents.SignedPublicKeyBundle - 58, // 12: xmtp.keystore_api.v1.CreateInviteRequest.consent_proof:type_name -> xmtp.message_contents.ConsentProofPayload - 59, // 13: xmtp.keystore_api.v1.CreateInviteResponse.conversation:type_name -> xmtp.message_contents.ConversationReference - 47, // 14: xmtp.keystore_api.v1.SaveInvitesRequest.requests:type_name -> xmtp.keystore_api.v1.SaveInvitesRequest.Request - 48, // 15: xmtp.keystore_api.v1.SaveInvitesResponse.responses:type_name -> xmtp.keystore_api.v1.SaveInvitesResponse.Response - 59, // 16: xmtp.keystore_api.v1.SaveV1ConversationsRequest.conversations:type_name -> xmtp.message_contents.ConversationReference - 59, // 17: xmtp.keystore_api.v1.GetConversationsResponse.conversations:type_name -> xmtp.message_contents.ConversationReference - 2, // 18: xmtp.keystore_api.v1.GetKeystoreStatusResponse.status:type_name -> xmtp.keystore_api.v1.GetKeystoreStatusResponse.KeystoreStatus - 60, // 19: xmtp.keystore_api.v1.InitKeystoreRequest.v1:type_name -> xmtp.message_contents.PrivateKeyBundleV1 - 3, // 20: xmtp.keystore_api.v1.InitKeystoreResponse.error:type_name -> xmtp.keystore_api.v1.KeystoreError - 1, // 21: xmtp.keystore_api.v1.GetRefreshJobRequest.job_type:type_name -> xmtp.keystore_api.v1.JobType - 1, // 22: xmtp.keystore_api.v1.SetRefeshJobRequest.job_type:type_name -> xmtp.keystore_api.v1.JobType - 51, // 23: xmtp.keystore_api.v1.TopicMap.topics:type_name -> xmtp.keystore_api.v1.TopicMap.TopicsEntry - 54, // 24: xmtp.keystore_api.v1.GetConversationHmacKeysResponse.hmac_keys:type_name -> xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeysEntry - 55, // 25: xmtp.keystore_api.v1.PrivatePreferencesActionMap.actions:type_name -> xmtp.keystore_api.v1.PrivatePreferencesActionMap.ActionsEntry - 61, // 26: xmtp.keystore_api.v1.DecryptV1Request.Request.payload:type_name -> xmtp.message_contents.Ciphertext - 62, // 27: xmtp.keystore_api.v1.DecryptV1Request.Request.peer_keys:type_name -> xmtp.message_contents.PublicKeyBundle - 37, // 28: xmtp.keystore_api.v1.DecryptResponse.Response.result:type_name -> xmtp.keystore_api.v1.DecryptResponse.Response.Success - 3, // 29: xmtp.keystore_api.v1.DecryptResponse.Response.error:type_name -> xmtp.keystore_api.v1.KeystoreError - 61, // 30: xmtp.keystore_api.v1.DecryptV2Request.Request.payload:type_name -> xmtp.message_contents.Ciphertext - 62, // 31: xmtp.keystore_api.v1.EncryptV1Request.Request.recipient:type_name -> xmtp.message_contents.PublicKeyBundle - 41, // 32: xmtp.keystore_api.v1.EncryptResponse.Response.result:type_name -> xmtp.keystore_api.v1.EncryptResponse.Response.Success - 3, // 33: xmtp.keystore_api.v1.EncryptResponse.Response.error:type_name -> xmtp.keystore_api.v1.KeystoreError - 61, // 34: xmtp.keystore_api.v1.EncryptResponse.Response.Success.encrypted:type_name -> xmtp.message_contents.Ciphertext - 45, // 35: xmtp.keystore_api.v1.SelfEncryptResponse.Response.result:type_name -> xmtp.keystore_api.v1.SelfEncryptResponse.Response.Success - 3, // 36: xmtp.keystore_api.v1.SelfEncryptResponse.Response.error:type_name -> xmtp.keystore_api.v1.KeystoreError - 49, // 37: xmtp.keystore_api.v1.SaveInvitesResponse.Response.result:type_name -> xmtp.keystore_api.v1.SaveInvitesResponse.Response.Success - 3, // 38: xmtp.keystore_api.v1.SaveInvitesResponse.Response.error:type_name -> xmtp.keystore_api.v1.KeystoreError - 59, // 39: xmtp.keystore_api.v1.SaveInvitesResponse.Response.Success.conversation:type_name -> xmtp.message_contents.ConversationReference - 63, // 40: xmtp.keystore_api.v1.TopicMap.TopicData.invitation:type_name -> xmtp.message_contents.InvitationV1 - 50, // 41: xmtp.keystore_api.v1.TopicMap.TopicsEntry.value:type_name -> xmtp.keystore_api.v1.TopicMap.TopicData - 52, // 42: xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeys.values:type_name -> xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeyData - 53, // 43: xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeysEntry.value:type_name -> xmtp.keystore_api.v1.GetConversationHmacKeysResponse.HmacKeys - 64, // 44: xmtp.keystore_api.v1.PrivatePreferencesActionMap.ActionsEntry.value:type_name -> xmtp.message_contents.PrivatePreferencesAction - 45, // [45:45] is the sub-list for method output_type - 45, // [45:45] is the sub-list for method input_type - 45, // [45:45] is the sub-list for extension type_name - 45, // [45:45] is the sub-list for extension extendee - 0, // [0:45] is the sub-list for field type_name -} - -func init() { file_keystore_api_v1_keystore_proto_init() } -func file_keystore_api_v1_keystore_proto_init() { - if File_keystore_api_v1_keystore_proto != nil { - return - } - file_keystore_api_v1_keystore_proto_msgTypes[15].OneofWrappers = []any{} - file_keystore_api_v1_keystore_proto_msgTypes[21].OneofWrappers = []any{ - (*InitKeystoreRequest_V1)(nil), - } - file_keystore_api_v1_keystore_proto_msgTypes[23].OneofWrappers = []any{ - (*SignDigestRequest_IdentityKey)(nil), - (*SignDigestRequest_PrekeyIndex)(nil), - } - file_keystore_api_v1_keystore_proto_msgTypes[33].OneofWrappers = []any{ - (*DecryptResponse_Response_Result)(nil), - (*DecryptResponse_Response_Error)(nil), - } - file_keystore_api_v1_keystore_proto_msgTypes[37].OneofWrappers = []any{ - (*EncryptResponse_Response_Result)(nil), - (*EncryptResponse_Response_Error)(nil), - } - file_keystore_api_v1_keystore_proto_msgTypes[41].OneofWrappers = []any{ - (*SelfEncryptResponse_Response_Result)(nil), - (*SelfEncryptResponse_Response_Error)(nil), - } - file_keystore_api_v1_keystore_proto_msgTypes[45].OneofWrappers = []any{ - (*SaveInvitesResponse_Response_Result)(nil), - (*SaveInvitesResponse_Response_Error)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_keystore_api_v1_keystore_proto_rawDesc), len(file_keystore_api_v1_keystore_proto_rawDesc)), - NumEnums: 3, - NumMessages: 53, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_keystore_api_v1_keystore_proto_goTypes, - DependencyIndexes: file_keystore_api_v1_keystore_proto_depIdxs, - EnumInfos: file_keystore_api_v1_keystore_proto_enumTypes, - MessageInfos: file_keystore_api_v1_keystore_proto_msgTypes, - }.Build() - File_keystore_api_v1_keystore_proto = out.File - file_keystore_api_v1_keystore_proto_goTypes = nil - file_keystore_api_v1_keystore_proto_depIdxs = nil -} diff --git a/pkg/proto/message_api/v1/authn.pb.go b/pkg/proto/message_api/v1/authn.pb.go deleted file mode 100644 index d1c7cc26..00000000 --- a/pkg/proto/message_api/v1/authn.pb.go +++ /dev/null @@ -1,219 +0,0 @@ -// Client authentication protocol - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_api/v1/authn.proto - -package message_apiv1 - -import ( - message_contents "github.com/xmtp/example-notification-server-go/pkg/proto/message_contents" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Token is used by clients to prove to the nodes -// that they are serving a specific wallet. -type Token struct { - state protoimpl.MessageState `protogen:"open.v1"` - // identity key signed by a wallet - IdentityKey *message_contents.PublicKey `protobuf:"bytes,1,opt,name=identity_key,json=identityKey,proto3" json:"identity_key,omitempty"` - // encoded bytes of AuthData - AuthDataBytes []byte `protobuf:"bytes,2,opt,name=auth_data_bytes,json=authDataBytes,proto3" json:"auth_data_bytes,omitempty"` - // identity key signature of AuthData bytes - AuthDataSignature *message_contents.Signature `protobuf:"bytes,3,opt,name=auth_data_signature,json=authDataSignature,proto3" json:"auth_data_signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Token) Reset() { - *x = Token{} - mi := &file_message_api_v1_authn_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Token) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Token) ProtoMessage() {} - -func (x *Token) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_authn_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Token.ProtoReflect.Descriptor instead. -func (*Token) Descriptor() ([]byte, []int) { - return file_message_api_v1_authn_proto_rawDescGZIP(), []int{0} -} - -func (x *Token) GetIdentityKey() *message_contents.PublicKey { - if x != nil { - return x.IdentityKey - } - return nil -} - -func (x *Token) GetAuthDataBytes() []byte { - if x != nil { - return x.AuthDataBytes - } - return nil -} - -func (x *Token) GetAuthDataSignature() *message_contents.Signature { - if x != nil { - return x.AuthDataSignature - } - return nil -} - -// AuthData carries token parameters that are authenticated -// by the identity key signature. -// It is embedded in the Token structure as bytes -// so that the bytes don't need to be reconstructed -// to verify the token signature. -type AuthData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // address of the wallet - WalletAddr string `protobuf:"bytes,1,opt,name=wallet_addr,json=walletAddr,proto3" json:"wallet_addr,omitempty"` - // time when the token was generated/signed - CreatedNs uint64 `protobuf:"varint,2,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AuthData) Reset() { - *x = AuthData{} - mi := &file_message_api_v1_authn_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AuthData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AuthData) ProtoMessage() {} - -func (x *AuthData) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_authn_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AuthData.ProtoReflect.Descriptor instead. -func (*AuthData) Descriptor() ([]byte, []int) { - return file_message_api_v1_authn_proto_rawDescGZIP(), []int{1} -} - -func (x *AuthData) GetWalletAddr() string { - if x != nil { - return x.WalletAddr - } - return "" -} - -func (x *AuthData) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -var File_message_api_v1_authn_proto protoreflect.FileDescriptor - -const file_message_api_v1_authn_proto_rawDesc = "" + - "\n" + - "\x1amessage_api/v1/authn.proto\x12\x13xmtp.message_api.v1\x1a!message_contents/public_key.proto\x1a message_contents/signature.proto\"\xc6\x01\n" + - "\x05Token\x12C\n" + - "\fidentity_key\x18\x01 \x01(\v2 .xmtp.message_contents.PublicKeyR\videntityKey\x12&\n" + - "\x0fauth_data_bytes\x18\x02 \x01(\fR\rauthDataBytes\x12P\n" + - "\x13auth_data_signature\x18\x03 \x01(\v2 .xmtp.message_contents.SignatureR\x11authDataSignature\"J\n" + - "\bAuthData\x12\x1f\n" + - "\vwallet_addr\x18\x01 \x01(\tR\n" + - "walletAddr\x12\x1d\n" + - "\n" + - "created_ns\x18\x02 \x01(\x04R\tcreatedNsB\x80\x02\n" + - "1org.xmtp.android.library.push.xmtp.message_api.v1B\n" + - "AuthnProtoP\x01ZUgithub.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1;message_apiv1\xa2\x02\x03XMX\xaa\x02\x12Xmtp.MessageApi.V1\xca\x02\x12Xmtp\\MessageApi\\V1\xe2\x02\x1eXmtp\\MessageApi\\V1\\GPBMetadata\xea\x02\x14Xmtp::MessageApi::V1b\x06proto3" - -var ( - file_message_api_v1_authn_proto_rawDescOnce sync.Once - file_message_api_v1_authn_proto_rawDescData []byte -) - -func file_message_api_v1_authn_proto_rawDescGZIP() []byte { - file_message_api_v1_authn_proto_rawDescOnce.Do(func() { - file_message_api_v1_authn_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_api_v1_authn_proto_rawDesc), len(file_message_api_v1_authn_proto_rawDesc))) - }) - return file_message_api_v1_authn_proto_rawDescData -} - -var file_message_api_v1_authn_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_message_api_v1_authn_proto_goTypes = []any{ - (*Token)(nil), // 0: xmtp.message_api.v1.Token - (*AuthData)(nil), // 1: xmtp.message_api.v1.AuthData - (*message_contents.PublicKey)(nil), // 2: xmtp.message_contents.PublicKey - (*message_contents.Signature)(nil), // 3: xmtp.message_contents.Signature -} -var file_message_api_v1_authn_proto_depIdxs = []int32{ - 2, // 0: xmtp.message_api.v1.Token.identity_key:type_name -> xmtp.message_contents.PublicKey - 3, // 1: xmtp.message_api.v1.Token.auth_data_signature:type_name -> xmtp.message_contents.Signature - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_message_api_v1_authn_proto_init() } -func file_message_api_v1_authn_proto_init() { - if File_message_api_v1_authn_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_api_v1_authn_proto_rawDesc), len(file_message_api_v1_authn_proto_rawDesc)), - NumEnums: 0, - NumMessages: 2, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_api_v1_authn_proto_goTypes, - DependencyIndexes: file_message_api_v1_authn_proto_depIdxs, - MessageInfos: file_message_api_v1_authn_proto_msgTypes, - }.Build() - File_message_api_v1_authn_proto = out.File - file_message_api_v1_authn_proto_goTypes = nil - file_message_api_v1_authn_proto_depIdxs = nil -} diff --git a/pkg/proto/message_api/v1/message_api.pb.go b/pkg/proto/message_api/v1/message_api.pb.go deleted file mode 100644 index 26796743..00000000 --- a/pkg/proto/message_api/v1/message_api.pb.go +++ /dev/null @@ -1,852 +0,0 @@ -// Message API - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_api/v1/message_api.proto - -package message_apiv1 - -import ( - _ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options" - _ "google.golang.org/genproto/googleapis/api/annotations" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Sort direction -type SortDirection int32 - -const ( - SortDirection_SORT_DIRECTION_UNSPECIFIED SortDirection = 0 - SortDirection_SORT_DIRECTION_ASCENDING SortDirection = 1 - SortDirection_SORT_DIRECTION_DESCENDING SortDirection = 2 -) - -// Enum value maps for SortDirection. -var ( - SortDirection_name = map[int32]string{ - 0: "SORT_DIRECTION_UNSPECIFIED", - 1: "SORT_DIRECTION_ASCENDING", - 2: "SORT_DIRECTION_DESCENDING", - } - SortDirection_value = map[string]int32{ - "SORT_DIRECTION_UNSPECIFIED": 0, - "SORT_DIRECTION_ASCENDING": 1, - "SORT_DIRECTION_DESCENDING": 2, - } -) - -func (x SortDirection) Enum() *SortDirection { - p := new(SortDirection) - *p = x - return p -} - -func (x SortDirection) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (SortDirection) Descriptor() protoreflect.EnumDescriptor { - return file_message_api_v1_message_api_proto_enumTypes[0].Descriptor() -} - -func (SortDirection) Type() protoreflect.EnumType { - return &file_message_api_v1_message_api_proto_enumTypes[0] -} - -func (x SortDirection) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use SortDirection.Descriptor instead. -func (SortDirection) EnumDescriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{0} -} - -// This is based off of the go-waku Index type, but with the -// receiverTime and pubsubTopic removed for simplicity. -// Both removed fields are optional -type IndexCursor struct { - state protoimpl.MessageState `protogen:"open.v1"` - Digest []byte `protobuf:"bytes,1,opt,name=digest,proto3" json:"digest,omitempty"` - SenderTimeNs uint64 `protobuf:"varint,2,opt,name=sender_time_ns,json=senderTimeNs,proto3" json:"sender_time_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *IndexCursor) Reset() { - *x = IndexCursor{} - mi := &file_message_api_v1_message_api_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *IndexCursor) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*IndexCursor) ProtoMessage() {} - -func (x *IndexCursor) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use IndexCursor.ProtoReflect.Descriptor instead. -func (*IndexCursor) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{0} -} - -func (x *IndexCursor) GetDigest() []byte { - if x != nil { - return x.Digest - } - return nil -} - -func (x *IndexCursor) GetSenderTimeNs() uint64 { - if x != nil { - return x.SenderTimeNs - } - return 0 -} - -// Wrapper for potentially multiple types of cursor -type Cursor struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Making the cursor a one-of type, as I would like to change the way we - // handle pagination to use a precomputed sort field. - // This way we can handle both methods - // - // Types that are valid to be assigned to Cursor: - // - // *Cursor_Index - Cursor isCursor_Cursor `protobuf_oneof:"cursor"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Cursor) Reset() { - *x = Cursor{} - mi := &file_message_api_v1_message_api_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Cursor) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Cursor) ProtoMessage() {} - -func (x *Cursor) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Cursor.ProtoReflect.Descriptor instead. -func (*Cursor) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{1} -} - -func (x *Cursor) GetCursor() isCursor_Cursor { - if x != nil { - return x.Cursor - } - return nil -} - -func (x *Cursor) GetIndex() *IndexCursor { - if x != nil { - if x, ok := x.Cursor.(*Cursor_Index); ok { - return x.Index - } - } - return nil -} - -type isCursor_Cursor interface { - isCursor_Cursor() -} - -type Cursor_Index struct { - Index *IndexCursor `protobuf:"bytes,1,opt,name=index,proto3,oneof"` -} - -func (*Cursor_Index) isCursor_Cursor() {} - -// This is based off of the go-waku PagingInfo struct, but with the direction -// changed to our SortDirection enum format -type PagingInfo struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Note: this is a uint32, while go-waku's pageSize is a uint64 - Limit uint32 `protobuf:"varint,1,opt,name=limit,proto3" json:"limit,omitempty"` - Cursor *Cursor `protobuf:"bytes,2,opt,name=cursor,proto3" json:"cursor,omitempty"` - Direction SortDirection `protobuf:"varint,3,opt,name=direction,proto3,enum=xmtp.message_api.v1.SortDirection" json:"direction,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PagingInfo) Reset() { - *x = PagingInfo{} - mi := &file_message_api_v1_message_api_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PagingInfo) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PagingInfo) ProtoMessage() {} - -func (x *PagingInfo) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PagingInfo.ProtoReflect.Descriptor instead. -func (*PagingInfo) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{2} -} - -func (x *PagingInfo) GetLimit() uint32 { - if x != nil { - return x.Limit - } - return 0 -} - -func (x *PagingInfo) GetCursor() *Cursor { - if x != nil { - return x.Cursor - } - return nil -} - -func (x *PagingInfo) GetDirection() SortDirection { - if x != nil { - return x.Direction - } - return SortDirection_SORT_DIRECTION_UNSPECIFIED -} - -// Envelope encapsulates a message while in transit. -type Envelope struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The topic the message belongs to, - // If the message includes the topic as well - // it MUST be the same as the topic in the envelope. - ContentTopic string `protobuf:"bytes,1,opt,name=content_topic,json=contentTopic,proto3" json:"content_topic,omitempty"` - // Message creation timestamp - // If the message includes the timestamp as well - // it MUST be equivalent to the timestamp in the envelope. - TimestampNs uint64 `protobuf:"varint,2,opt,name=timestamp_ns,json=timestampNs,proto3" json:"timestamp_ns,omitempty"` - Message []byte `protobuf:"bytes,3,opt,name=message,proto3" json:"message,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Envelope) Reset() { - *x = Envelope{} - mi := &file_message_api_v1_message_api_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Envelope) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Envelope) ProtoMessage() {} - -func (x *Envelope) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Envelope.ProtoReflect.Descriptor instead. -func (*Envelope) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{3} -} - -func (x *Envelope) GetContentTopic() string { - if x != nil { - return x.ContentTopic - } - return "" -} - -func (x *Envelope) GetTimestampNs() uint64 { - if x != nil { - return x.TimestampNs - } - return 0 -} - -func (x *Envelope) GetMessage() []byte { - if x != nil { - return x.Message - } - return nil -} - -// Publish -type PublishRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Envelopes []*Envelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishRequest) Reset() { - *x = PublishRequest{} - mi := &file_message_api_v1_message_api_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishRequest) ProtoMessage() {} - -func (x *PublishRequest) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishRequest.ProtoReflect.Descriptor instead. -func (*PublishRequest) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{4} -} - -func (x *PublishRequest) GetEnvelopes() []*Envelope { - if x != nil { - return x.Envelopes - } - return nil -} - -// Empty message as a response for Publish -type PublishResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishResponse) Reset() { - *x = PublishResponse{} - mi := &file_message_api_v1_message_api_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishResponse) ProtoMessage() {} - -func (x *PublishResponse) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishResponse.ProtoReflect.Descriptor instead. -func (*PublishResponse) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{5} -} - -// Subscribe -type SubscribeRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - ContentTopics []string `protobuf:"bytes,1,rep,name=content_topics,json=contentTopics,proto3" json:"content_topics,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeRequest) Reset() { - *x = SubscribeRequest{} - mi := &file_message_api_v1_message_api_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeRequest) ProtoMessage() {} - -func (x *SubscribeRequest) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeRequest.ProtoReflect.Descriptor instead. -func (*SubscribeRequest) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{6} -} - -func (x *SubscribeRequest) GetContentTopics() []string { - if x != nil { - return x.ContentTopics - } - return nil -} - -// SubscribeAll -type SubscribeAllRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeAllRequest) Reset() { - *x = SubscribeAllRequest{} - mi := &file_message_api_v1_message_api_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeAllRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeAllRequest) ProtoMessage() {} - -func (x *SubscribeAllRequest) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeAllRequest.ProtoReflect.Descriptor instead. -func (*SubscribeAllRequest) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{7} -} - -// Query -type QueryRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - ContentTopics []string `protobuf:"bytes,1,rep,name=content_topics,json=contentTopics,proto3" json:"content_topics,omitempty"` - StartTimeNs uint64 `protobuf:"varint,2,opt,name=start_time_ns,json=startTimeNs,proto3" json:"start_time_ns,omitempty"` - EndTimeNs uint64 `protobuf:"varint,3,opt,name=end_time_ns,json=endTimeNs,proto3" json:"end_time_ns,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,4,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryRequest) Reset() { - *x = QueryRequest{} - mi := &file_message_api_v1_message_api_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryRequest) ProtoMessage() {} - -func (x *QueryRequest) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryRequest.ProtoReflect.Descriptor instead. -func (*QueryRequest) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{8} -} - -func (x *QueryRequest) GetContentTopics() []string { - if x != nil { - return x.ContentTopics - } - return nil -} - -func (x *QueryRequest) GetStartTimeNs() uint64 { - if x != nil { - return x.StartTimeNs - } - return 0 -} - -func (x *QueryRequest) GetEndTimeNs() uint64 { - if x != nil { - return x.EndTimeNs - } - return 0 -} - -func (x *QueryRequest) GetPagingInfo() *PagingInfo { - if x != nil { - return x.PagingInfo - } - return nil -} - -// The response, containing envelopes, for a query -type QueryResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Envelopes []*Envelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,2,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryResponse) Reset() { - *x = QueryResponse{} - mi := &file_message_api_v1_message_api_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryResponse) ProtoMessage() {} - -func (x *QueryResponse) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryResponse.ProtoReflect.Descriptor instead. -func (*QueryResponse) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{9} -} - -func (x *QueryResponse) GetEnvelopes() []*Envelope { - if x != nil { - return x.Envelopes - } - return nil -} - -func (x *QueryResponse) GetPagingInfo() *PagingInfo { - if x != nil { - return x.PagingInfo - } - return nil -} - -// BatchQuery -type BatchQueryRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*QueryRequest `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BatchQueryRequest) Reset() { - *x = BatchQueryRequest{} - mi := &file_message_api_v1_message_api_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BatchQueryRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BatchQueryRequest) ProtoMessage() {} - -func (x *BatchQueryRequest) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BatchQueryRequest.ProtoReflect.Descriptor instead. -func (*BatchQueryRequest) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{10} -} - -func (x *BatchQueryRequest) GetRequests() []*QueryRequest { - if x != nil { - return x.Requests - } - return nil -} - -// Response containing a list of QueryResponse messages -type BatchQueryResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*QueryResponse `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BatchQueryResponse) Reset() { - *x = BatchQueryResponse{} - mi := &file_message_api_v1_message_api_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BatchQueryResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BatchQueryResponse) ProtoMessage() {} - -func (x *BatchQueryResponse) ProtoReflect() protoreflect.Message { - mi := &file_message_api_v1_message_api_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BatchQueryResponse.ProtoReflect.Descriptor instead. -func (*BatchQueryResponse) Descriptor() ([]byte, []int) { - return file_message_api_v1_message_api_proto_rawDescGZIP(), []int{11} -} - -func (x *BatchQueryResponse) GetResponses() []*QueryResponse { - if x != nil { - return x.Responses - } - return nil -} - -var File_message_api_v1_message_api_proto protoreflect.FileDescriptor - -const file_message_api_v1_message_api_proto_rawDesc = "" + - "\n" + - " message_api/v1/message_api.proto\x12\x13xmtp.message_api.v1\x1a\x1cgoogle/api/annotations.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\"K\n" + - "\vIndexCursor\x12\x16\n" + - "\x06digest\x18\x01 \x01(\fR\x06digest\x12$\n" + - "\x0esender_time_ns\x18\x02 \x01(\x04R\fsenderTimeNs\"L\n" + - "\x06Cursor\x128\n" + - "\x05index\x18\x01 \x01(\v2 .xmtp.message_api.v1.IndexCursorH\x00R\x05indexB\b\n" + - "\x06cursor\"\x99\x01\n" + - "\n" + - "PagingInfo\x12\x14\n" + - "\x05limit\x18\x01 \x01(\rR\x05limit\x123\n" + - "\x06cursor\x18\x02 \x01(\v2\x1b.xmtp.message_api.v1.CursorR\x06cursor\x12@\n" + - "\tdirection\x18\x03 \x01(\x0e2\".xmtp.message_api.v1.SortDirectionR\tdirection\"l\n" + - "\bEnvelope\x12#\n" + - "\rcontent_topic\x18\x01 \x01(\tR\fcontentTopic\x12!\n" + - "\ftimestamp_ns\x18\x02 \x01(\x04R\vtimestampNs\x12\x18\n" + - "\amessage\x18\x03 \x01(\fR\amessage\"M\n" + - "\x0ePublishRequest\x12;\n" + - "\tenvelopes\x18\x01 \x03(\v2\x1d.xmtp.message_api.v1.EnvelopeR\tenvelopes\"\x11\n" + - "\x0fPublishResponse\"9\n" + - "\x10SubscribeRequest\x12%\n" + - "\x0econtent_topics\x18\x01 \x03(\tR\rcontentTopics\"\x15\n" + - "\x13SubscribeAllRequest\"\xbb\x01\n" + - "\fQueryRequest\x12%\n" + - "\x0econtent_topics\x18\x01 \x03(\tR\rcontentTopics\x12\"\n" + - "\rstart_time_ns\x18\x02 \x01(\x04R\vstartTimeNs\x12\x1e\n" + - "\vend_time_ns\x18\x03 \x01(\x04R\tendTimeNs\x12@\n" + - "\vpaging_info\x18\x04 \x01(\v2\x1f.xmtp.message_api.v1.PagingInfoR\n" + - "pagingInfo\"\x8e\x01\n" + - "\rQueryResponse\x12;\n" + - "\tenvelopes\x18\x01 \x03(\v2\x1d.xmtp.message_api.v1.EnvelopeR\tenvelopes\x12@\n" + - "\vpaging_info\x18\x02 \x01(\v2\x1f.xmtp.message_api.v1.PagingInfoR\n" + - "pagingInfo\"R\n" + - "\x11BatchQueryRequest\x12=\n" + - "\brequests\x18\x01 \x03(\v2!.xmtp.message_api.v1.QueryRequestR\brequests\"V\n" + - "\x12BatchQueryResponse\x12@\n" + - "\tresponses\x18\x01 \x03(\v2\".xmtp.message_api.v1.QueryResponseR\tresponses*l\n" + - "\rSortDirection\x12\x1e\n" + - "\x1aSORT_DIRECTION_UNSPECIFIED\x10\x00\x12\x1c\n" + - "\x18SORT_DIRECTION_ASCENDING\x10\x01\x12\x1d\n" + - "\x19SORT_DIRECTION_DESCENDING\x10\x022\xc6\x05\n" + - "\n" + - "MessageApi\x12t\n" + - "\aPublish\x12#.xmtp.message_api.v1.PublishRequest\x1a$.xmtp.message_api.v1.PublishResponse\"\x1e\x82\xd3\xe4\x93\x02\x18:\x01*\"\x13/message/v1/publish\x12u\n" + - "\tSubscribe\x12%.xmtp.message_api.v1.SubscribeRequest\x1a\x1d.xmtp.message_api.v1.Envelope\" \x82\xd3\xe4\x93\x02\x1a:\x01*\"\x15/message/v1/subscribe0\x01\x12X\n" + - "\n" + - "Subscribe2\x12%.xmtp.message_api.v1.SubscribeRequest\x1a\x1d.xmtp.message_api.v1.Envelope\"\x00(\x010\x01\x12\x7f\n" + - "\fSubscribeAll\x12(.xmtp.message_api.v1.SubscribeAllRequest\x1a\x1d.xmtp.message_api.v1.Envelope\"$\x82\xd3\xe4\x93\x02\x1e:\x01*\"\x19/message/v1/subscribe-all0\x01\x12l\n" + - "\x05Query\x12!.xmtp.message_api.v1.QueryRequest\x1a\".xmtp.message_api.v1.QueryResponse\"\x1c\x82\xd3\xe4\x93\x02\x16:\x01*\"\x11/message/v1/query\x12\x81\x01\n" + - "\n" + - "BatchQuery\x12&.xmtp.message_api.v1.BatchQueryRequest\x1a'.xmtp.message_api.v1.BatchQueryResponse\"\"\x82\xd3\xe4\x93\x02\x1c:\x01*\"\x17/message/v1/batch-queryB\x9b\x02\x92A\x13\x12\x11\n" + - "\n" + - "MessageApi2\x031.0\n" + - "1org.xmtp.android.library.push.xmtp.message_api.v1B\x0fMessageApiProtoP\x01ZUgithub.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1;message_apiv1\xa2\x02\x03XMX\xaa\x02\x12Xmtp.MessageApi.V1\xca\x02\x12Xmtp\\MessageApi\\V1\xe2\x02\x1eXmtp\\MessageApi\\V1\\GPBMetadata\xea\x02\x14Xmtp::MessageApi::V1b\x06proto3" - -var ( - file_message_api_v1_message_api_proto_rawDescOnce sync.Once - file_message_api_v1_message_api_proto_rawDescData []byte -) - -func file_message_api_v1_message_api_proto_rawDescGZIP() []byte { - file_message_api_v1_message_api_proto_rawDescOnce.Do(func() { - file_message_api_v1_message_api_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_api_v1_message_api_proto_rawDesc), len(file_message_api_v1_message_api_proto_rawDesc))) - }) - return file_message_api_v1_message_api_proto_rawDescData -} - -var file_message_api_v1_message_api_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_message_api_v1_message_api_proto_msgTypes = make([]protoimpl.MessageInfo, 12) -var file_message_api_v1_message_api_proto_goTypes = []any{ - (SortDirection)(0), // 0: xmtp.message_api.v1.SortDirection - (*IndexCursor)(nil), // 1: xmtp.message_api.v1.IndexCursor - (*Cursor)(nil), // 2: xmtp.message_api.v1.Cursor - (*PagingInfo)(nil), // 3: xmtp.message_api.v1.PagingInfo - (*Envelope)(nil), // 4: xmtp.message_api.v1.Envelope - (*PublishRequest)(nil), // 5: xmtp.message_api.v1.PublishRequest - (*PublishResponse)(nil), // 6: xmtp.message_api.v1.PublishResponse - (*SubscribeRequest)(nil), // 7: xmtp.message_api.v1.SubscribeRequest - (*SubscribeAllRequest)(nil), // 8: xmtp.message_api.v1.SubscribeAllRequest - (*QueryRequest)(nil), // 9: xmtp.message_api.v1.QueryRequest - (*QueryResponse)(nil), // 10: xmtp.message_api.v1.QueryResponse - (*BatchQueryRequest)(nil), // 11: xmtp.message_api.v1.BatchQueryRequest - (*BatchQueryResponse)(nil), // 12: xmtp.message_api.v1.BatchQueryResponse -} -var file_message_api_v1_message_api_proto_depIdxs = []int32{ - 1, // 0: xmtp.message_api.v1.Cursor.index:type_name -> xmtp.message_api.v1.IndexCursor - 2, // 1: xmtp.message_api.v1.PagingInfo.cursor:type_name -> xmtp.message_api.v1.Cursor - 0, // 2: xmtp.message_api.v1.PagingInfo.direction:type_name -> xmtp.message_api.v1.SortDirection - 4, // 3: xmtp.message_api.v1.PublishRequest.envelopes:type_name -> xmtp.message_api.v1.Envelope - 3, // 4: xmtp.message_api.v1.QueryRequest.paging_info:type_name -> xmtp.message_api.v1.PagingInfo - 4, // 5: xmtp.message_api.v1.QueryResponse.envelopes:type_name -> xmtp.message_api.v1.Envelope - 3, // 6: xmtp.message_api.v1.QueryResponse.paging_info:type_name -> xmtp.message_api.v1.PagingInfo - 9, // 7: xmtp.message_api.v1.BatchQueryRequest.requests:type_name -> xmtp.message_api.v1.QueryRequest - 10, // 8: xmtp.message_api.v1.BatchQueryResponse.responses:type_name -> xmtp.message_api.v1.QueryResponse - 5, // 9: xmtp.message_api.v1.MessageApi.Publish:input_type -> xmtp.message_api.v1.PublishRequest - 7, // 10: xmtp.message_api.v1.MessageApi.Subscribe:input_type -> xmtp.message_api.v1.SubscribeRequest - 7, // 11: xmtp.message_api.v1.MessageApi.Subscribe2:input_type -> xmtp.message_api.v1.SubscribeRequest - 8, // 12: xmtp.message_api.v1.MessageApi.SubscribeAll:input_type -> xmtp.message_api.v1.SubscribeAllRequest - 9, // 13: xmtp.message_api.v1.MessageApi.Query:input_type -> xmtp.message_api.v1.QueryRequest - 11, // 14: xmtp.message_api.v1.MessageApi.BatchQuery:input_type -> xmtp.message_api.v1.BatchQueryRequest - 6, // 15: xmtp.message_api.v1.MessageApi.Publish:output_type -> xmtp.message_api.v1.PublishResponse - 4, // 16: xmtp.message_api.v1.MessageApi.Subscribe:output_type -> xmtp.message_api.v1.Envelope - 4, // 17: xmtp.message_api.v1.MessageApi.Subscribe2:output_type -> xmtp.message_api.v1.Envelope - 4, // 18: xmtp.message_api.v1.MessageApi.SubscribeAll:output_type -> xmtp.message_api.v1.Envelope - 10, // 19: xmtp.message_api.v1.MessageApi.Query:output_type -> xmtp.message_api.v1.QueryResponse - 12, // 20: xmtp.message_api.v1.MessageApi.BatchQuery:output_type -> xmtp.message_api.v1.BatchQueryResponse - 15, // [15:21] is the sub-list for method output_type - 9, // [9:15] is the sub-list for method input_type - 9, // [9:9] is the sub-list for extension type_name - 9, // [9:9] is the sub-list for extension extendee - 0, // [0:9] is the sub-list for field type_name -} - -func init() { file_message_api_v1_message_api_proto_init() } -func file_message_api_v1_message_api_proto_init() { - if File_message_api_v1_message_api_proto != nil { - return - } - file_message_api_v1_message_api_proto_msgTypes[1].OneofWrappers = []any{ - (*Cursor_Index)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_api_v1_message_api_proto_rawDesc), len(file_message_api_v1_message_api_proto_rawDesc)), - NumEnums: 1, - NumMessages: 12, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_message_api_v1_message_api_proto_goTypes, - DependencyIndexes: file_message_api_v1_message_api_proto_depIdxs, - EnumInfos: file_message_api_v1_message_api_proto_enumTypes, - MessageInfos: file_message_api_v1_message_api_proto_msgTypes, - }.Build() - File_message_api_v1_message_api_proto = out.File - file_message_api_v1_message_api_proto_goTypes = nil - file_message_api_v1_message_api_proto_depIdxs = nil -} diff --git a/pkg/proto/message_api/v1/message_api_grpc.pb.go b/pkg/proto/message_api/v1/message_api_grpc.pb.go deleted file mode 100644 index b422aaa9..00000000 --- a/pkg/proto/message_api/v1/message_api_grpc.pb.go +++ /dev/null @@ -1,399 +0,0 @@ -// Message API - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: message_api/v1/message_api.proto - -package message_apiv1 - -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 ( - MessageApi_Publish_FullMethodName = "/xmtp.message_api.v1.MessageApi/Publish" - MessageApi_Subscribe_FullMethodName = "/xmtp.message_api.v1.MessageApi/Subscribe" - MessageApi_Subscribe2_FullMethodName = "/xmtp.message_api.v1.MessageApi/Subscribe2" - MessageApi_SubscribeAll_FullMethodName = "/xmtp.message_api.v1.MessageApi/SubscribeAll" - MessageApi_Query_FullMethodName = "/xmtp.message_api.v1.MessageApi/Query" - MessageApi_BatchQuery_FullMethodName = "/xmtp.message_api.v1.MessageApi/BatchQuery" -) - -// MessageApiClient is the client API for MessageApi 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 MessageApiClient interface { - // Publish messages to the network - Publish(ctx context.Context, in *PublishRequest, opts ...grpc.CallOption) (*PublishResponse, error) - // Subscribe to a stream of new envelopes matching a predicate - Subscribe(ctx context.Context, in *SubscribeRequest, opts ...grpc.CallOption) (MessageApi_SubscribeClient, error) - // Subscribe to a stream of new envelopes and your subscription using - // bidirectional streaming - // protolint:disable:next RPC_REQUEST_STANDARD_NAME - Subscribe2(ctx context.Context, opts ...grpc.CallOption) (MessageApi_Subscribe2Client, error) - // Subscribe to a stream of all messages - SubscribeAll(ctx context.Context, in *SubscribeAllRequest, opts ...grpc.CallOption) (MessageApi_SubscribeAllClient, error) - // Query the store for messages - Query(ctx context.Context, in *QueryRequest, opts ...grpc.CallOption) (*QueryResponse, error) - // BatchQuery containing a set of queries to be processed - BatchQuery(ctx context.Context, in *BatchQueryRequest, opts ...grpc.CallOption) (*BatchQueryResponse, error) -} - -type messageApiClient struct { - cc grpc.ClientConnInterface -} - -func NewMessageApiClient(cc grpc.ClientConnInterface) MessageApiClient { - return &messageApiClient{cc} -} - -func (c *messageApiClient) Publish(ctx context.Context, in *PublishRequest, opts ...grpc.CallOption) (*PublishResponse, error) { - out := new(PublishResponse) - err := c.cc.Invoke(ctx, MessageApi_Publish_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *messageApiClient) Subscribe(ctx context.Context, in *SubscribeRequest, opts ...grpc.CallOption) (MessageApi_SubscribeClient, error) { - stream, err := c.cc.NewStream(ctx, &MessageApi_ServiceDesc.Streams[0], MessageApi_Subscribe_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &messageApiSubscribeClient{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 MessageApi_SubscribeClient interface { - Recv() (*Envelope, error) - grpc.ClientStream -} - -type messageApiSubscribeClient struct { - grpc.ClientStream -} - -func (x *messageApiSubscribeClient) Recv() (*Envelope, error) { - m := new(Envelope) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *messageApiClient) Subscribe2(ctx context.Context, opts ...grpc.CallOption) (MessageApi_Subscribe2Client, error) { - stream, err := c.cc.NewStream(ctx, &MessageApi_ServiceDesc.Streams[1], MessageApi_Subscribe2_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &messageApiSubscribe2Client{stream} - return x, nil -} - -type MessageApi_Subscribe2Client interface { - Send(*SubscribeRequest) error - Recv() (*Envelope, error) - grpc.ClientStream -} - -type messageApiSubscribe2Client struct { - grpc.ClientStream -} - -func (x *messageApiSubscribe2Client) Send(m *SubscribeRequest) error { - return x.ClientStream.SendMsg(m) -} - -func (x *messageApiSubscribe2Client) Recv() (*Envelope, error) { - m := new(Envelope) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *messageApiClient) SubscribeAll(ctx context.Context, in *SubscribeAllRequest, opts ...grpc.CallOption) (MessageApi_SubscribeAllClient, error) { - stream, err := c.cc.NewStream(ctx, &MessageApi_ServiceDesc.Streams[2], MessageApi_SubscribeAll_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &messageApiSubscribeAllClient{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 MessageApi_SubscribeAllClient interface { - Recv() (*Envelope, error) - grpc.ClientStream -} - -type messageApiSubscribeAllClient struct { - grpc.ClientStream -} - -func (x *messageApiSubscribeAllClient) Recv() (*Envelope, error) { - m := new(Envelope) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *messageApiClient) Query(ctx context.Context, in *QueryRequest, opts ...grpc.CallOption) (*QueryResponse, error) { - out := new(QueryResponse) - err := c.cc.Invoke(ctx, MessageApi_Query_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *messageApiClient) BatchQuery(ctx context.Context, in *BatchQueryRequest, opts ...grpc.CallOption) (*BatchQueryResponse, error) { - out := new(BatchQueryResponse) - err := c.cc.Invoke(ctx, MessageApi_BatchQuery_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// MessageApiServer is the server API for MessageApi service. -// All implementations must embed UnimplementedMessageApiServer -// for forward compatibility -type MessageApiServer interface { - // Publish messages to the network - Publish(context.Context, *PublishRequest) (*PublishResponse, error) - // Subscribe to a stream of new envelopes matching a predicate - Subscribe(*SubscribeRequest, MessageApi_SubscribeServer) error - // Subscribe to a stream of new envelopes and your subscription using - // bidirectional streaming - // protolint:disable:next RPC_REQUEST_STANDARD_NAME - Subscribe2(MessageApi_Subscribe2Server) error - // Subscribe to a stream of all messages - SubscribeAll(*SubscribeAllRequest, MessageApi_SubscribeAllServer) error - // Query the store for messages - Query(context.Context, *QueryRequest) (*QueryResponse, error) - // BatchQuery containing a set of queries to be processed - BatchQuery(context.Context, *BatchQueryRequest) (*BatchQueryResponse, error) - mustEmbedUnimplementedMessageApiServer() -} - -// UnimplementedMessageApiServer must be embedded to have forward compatible implementations. -type UnimplementedMessageApiServer struct { -} - -func (UnimplementedMessageApiServer) Publish(context.Context, *PublishRequest) (*PublishResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Publish not implemented") -} -func (UnimplementedMessageApiServer) Subscribe(*SubscribeRequest, MessageApi_SubscribeServer) error { - return status.Errorf(codes.Unimplemented, "method Subscribe not implemented") -} -func (UnimplementedMessageApiServer) Subscribe2(MessageApi_Subscribe2Server) error { - return status.Errorf(codes.Unimplemented, "method Subscribe2 not implemented") -} -func (UnimplementedMessageApiServer) SubscribeAll(*SubscribeAllRequest, MessageApi_SubscribeAllServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeAll not implemented") -} -func (UnimplementedMessageApiServer) Query(context.Context, *QueryRequest) (*QueryResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method Query not implemented") -} -func (UnimplementedMessageApiServer) BatchQuery(context.Context, *BatchQueryRequest) (*BatchQueryResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method BatchQuery not implemented") -} -func (UnimplementedMessageApiServer) mustEmbedUnimplementedMessageApiServer() {} - -// UnsafeMessageApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to MessageApiServer will -// result in compilation errors. -type UnsafeMessageApiServer interface { - mustEmbedUnimplementedMessageApiServer() -} - -func RegisterMessageApiServer(s grpc.ServiceRegistrar, srv MessageApiServer) { - s.RegisterService(&MessageApi_ServiceDesc, srv) -} - -func _MessageApi_Publish_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(PublishRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MessageApiServer).Publish(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MessageApi_Publish_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MessageApiServer).Publish(ctx, req.(*PublishRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MessageApi_Subscribe_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(MessageApiServer).Subscribe(m, &messageApiSubscribeServer{stream}) -} - -type MessageApi_SubscribeServer interface { - Send(*Envelope) error - grpc.ServerStream -} - -type messageApiSubscribeServer struct { - grpc.ServerStream -} - -func (x *messageApiSubscribeServer) Send(m *Envelope) error { - return x.ServerStream.SendMsg(m) -} - -func _MessageApi_Subscribe2_Handler(srv interface{}, stream grpc.ServerStream) error { - return srv.(MessageApiServer).Subscribe2(&messageApiSubscribe2Server{stream}) -} - -type MessageApi_Subscribe2Server interface { - Send(*Envelope) error - Recv() (*SubscribeRequest, error) - grpc.ServerStream -} - -type messageApiSubscribe2Server struct { - grpc.ServerStream -} - -func (x *messageApiSubscribe2Server) Send(m *Envelope) error { - return x.ServerStream.SendMsg(m) -} - -func (x *messageApiSubscribe2Server) Recv() (*SubscribeRequest, error) { - m := new(SubscribeRequest) - if err := x.ServerStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func _MessageApi_SubscribeAll_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeAllRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(MessageApiServer).SubscribeAll(m, &messageApiSubscribeAllServer{stream}) -} - -type MessageApi_SubscribeAllServer interface { - Send(*Envelope) error - grpc.ServerStream -} - -type messageApiSubscribeAllServer struct { - grpc.ServerStream -} - -func (x *messageApiSubscribeAllServer) Send(m *Envelope) error { - return x.ServerStream.SendMsg(m) -} - -func _MessageApi_Query_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QueryRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MessageApiServer).Query(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MessageApi_Query_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MessageApiServer).Query(ctx, req.(*QueryRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MessageApi_BatchQuery_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(BatchQueryRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MessageApiServer).BatchQuery(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MessageApi_BatchQuery_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MessageApiServer).BatchQuery(ctx, req.(*BatchQueryRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// MessageApi_ServiceDesc is the grpc.ServiceDesc for MessageApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var MessageApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.message_api.v1.MessageApi", - HandlerType: (*MessageApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "Publish", - Handler: _MessageApi_Publish_Handler, - }, - { - MethodName: "Query", - Handler: _MessageApi_Query_Handler, - }, - { - MethodName: "BatchQuery", - Handler: _MessageApi_BatchQuery_Handler, - }, - }, - Streams: []grpc.StreamDesc{ - { - StreamName: "Subscribe", - Handler: _MessageApi_Subscribe_Handler, - ServerStreams: true, - }, - { - StreamName: "Subscribe2", - Handler: _MessageApi_Subscribe2_Handler, - ServerStreams: true, - ClientStreams: true, - }, - { - StreamName: "SubscribeAll", - Handler: _MessageApi_SubscribeAll_Handler, - ServerStreams: true, - }, - }, - Metadata: "message_api/v1/message_api.proto", -} diff --git a/pkg/proto/message_contents/ciphertext.pb.go b/pkg/proto/message_contents/ciphertext.pb.go deleted file mode 100644 index f7820729..00000000 --- a/pkg/proto/message_contents/ciphertext.pb.go +++ /dev/null @@ -1,364 +0,0 @@ -// Ciphertext is a generic structure for encrypted payload. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/ciphertext.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Ciphertext represents encrypted payload. -// It is definited as a union to support cryptographic algorithm agility. -// The payload is accompanied by the cryptographic parameters -// required by the chosen encryption scheme. -type Ciphertext struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Union: - // - // *Ciphertext_Aes256GcmHkdfSha256 - Union isCiphertext_Union `protobuf_oneof:"union"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Ciphertext) Reset() { - *x = Ciphertext{} - mi := &file_message_contents_ciphertext_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Ciphertext) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Ciphertext) ProtoMessage() {} - -func (x *Ciphertext) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_ciphertext_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Ciphertext.ProtoReflect.Descriptor instead. -func (*Ciphertext) Descriptor() ([]byte, []int) { - return file_message_contents_ciphertext_proto_rawDescGZIP(), []int{0} -} - -func (x *Ciphertext) GetUnion() isCiphertext_Union { - if x != nil { - return x.Union - } - return nil -} - -func (x *Ciphertext) GetAes256GcmHkdfSha256() *Ciphertext_Aes256GcmHkdfsha256 { - if x != nil { - if x, ok := x.Union.(*Ciphertext_Aes256GcmHkdfSha256); ok { - return x.Aes256GcmHkdfSha256 - } - } - return nil -} - -type isCiphertext_Union interface { - isCiphertext_Union() -} - -type Ciphertext_Aes256GcmHkdfSha256 struct { - Aes256GcmHkdfSha256 *Ciphertext_Aes256GcmHkdfsha256 `protobuf:"bytes,1,opt,name=aes256_gcm_hkdf_sha256,json=aes256GcmHkdfSha256,proto3,oneof"` -} - -func (*Ciphertext_Aes256GcmHkdfSha256) isCiphertext_Union() {} - -// SignedEciesCiphertext represents an ECIES encrypted payload and a signature -type SignedEciesCiphertext struct { - state protoimpl.MessageState `protogen:"open.v1"` - // serialized Ecies message - EciesBytes []byte `protobuf:"bytes,1,opt,name=ecies_bytes,json=eciesBytes,proto3" json:"ecies_bytes,omitempty"` - // signature of sha256(ecies_bytes) signed with the IdentityKey - Signature *Signature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignedEciesCiphertext) Reset() { - *x = SignedEciesCiphertext{} - mi := &file_message_contents_ciphertext_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignedEciesCiphertext) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignedEciesCiphertext) ProtoMessage() {} - -func (x *SignedEciesCiphertext) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_ciphertext_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignedEciesCiphertext.ProtoReflect.Descriptor instead. -func (*SignedEciesCiphertext) Descriptor() ([]byte, []int) { - return file_message_contents_ciphertext_proto_rawDescGZIP(), []int{1} -} - -func (x *SignedEciesCiphertext) GetEciesBytes() []byte { - if x != nil { - return x.EciesBytes - } - return nil -} - -func (x *SignedEciesCiphertext) GetSignature() *Signature { - if x != nil { - return x.Signature - } - return nil -} - -// Encryption: AES256-GCM -// Key derivation function: HKDF-SHA256 -type Ciphertext_Aes256GcmHkdfsha256 struct { - state protoimpl.MessageState `protogen:"open.v1"` - HkdfSalt []byte `protobuf:"bytes,1,opt,name=hkdf_salt,json=hkdfSalt,proto3" json:"hkdf_salt,omitempty"` // 32 bytes - GcmNonce []byte `protobuf:"bytes,2,opt,name=gcm_nonce,json=gcmNonce,proto3" json:"gcm_nonce,omitempty"` // 12 bytes - Payload []byte `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"` // encrypted payload - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Ciphertext_Aes256GcmHkdfsha256) Reset() { - *x = Ciphertext_Aes256GcmHkdfsha256{} - mi := &file_message_contents_ciphertext_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Ciphertext_Aes256GcmHkdfsha256) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Ciphertext_Aes256GcmHkdfsha256) ProtoMessage() {} - -func (x *Ciphertext_Aes256GcmHkdfsha256) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_ciphertext_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Ciphertext_Aes256GcmHkdfsha256.ProtoReflect.Descriptor instead. -func (*Ciphertext_Aes256GcmHkdfsha256) Descriptor() ([]byte, []int) { - return file_message_contents_ciphertext_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *Ciphertext_Aes256GcmHkdfsha256) GetHkdfSalt() []byte { - if x != nil { - return x.HkdfSalt - } - return nil -} - -func (x *Ciphertext_Aes256GcmHkdfsha256) GetGcmNonce() []byte { - if x != nil { - return x.GcmNonce - } - return nil -} - -func (x *Ciphertext_Aes256GcmHkdfsha256) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -// Ecies is ciphertext encrypted using ECIES with a MAC -type SignedEciesCiphertext_Ecies struct { - state protoimpl.MessageState `protogen:"open.v1"` - EphemeralPublicKey []byte `protobuf:"bytes,1,opt,name=ephemeral_public_key,json=ephemeralPublicKey,proto3" json:"ephemeral_public_key,omitempty"` // 65 bytes - Iv []byte `protobuf:"bytes,2,opt,name=iv,proto3" json:"iv,omitempty"` // 16 bytes - Mac []byte `protobuf:"bytes,3,opt,name=mac,proto3" json:"mac,omitempty"` // 32 bytes - Ciphertext []byte `protobuf:"bytes,4,opt,name=ciphertext,proto3" json:"ciphertext,omitempty"` // encrypted payload with block size of 16 - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignedEciesCiphertext_Ecies) Reset() { - *x = SignedEciesCiphertext_Ecies{} - mi := &file_message_contents_ciphertext_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignedEciesCiphertext_Ecies) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignedEciesCiphertext_Ecies) ProtoMessage() {} - -func (x *SignedEciesCiphertext_Ecies) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_ciphertext_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignedEciesCiphertext_Ecies.ProtoReflect.Descriptor instead. -func (*SignedEciesCiphertext_Ecies) Descriptor() ([]byte, []int) { - return file_message_contents_ciphertext_proto_rawDescGZIP(), []int{1, 0} -} - -func (x *SignedEciesCiphertext_Ecies) GetEphemeralPublicKey() []byte { - if x != nil { - return x.EphemeralPublicKey - } - return nil -} - -func (x *SignedEciesCiphertext_Ecies) GetIv() []byte { - if x != nil { - return x.Iv - } - return nil -} - -func (x *SignedEciesCiphertext_Ecies) GetMac() []byte { - if x != nil { - return x.Mac - } - return nil -} - -func (x *SignedEciesCiphertext_Ecies) GetCiphertext() []byte { - if x != nil { - return x.Ciphertext - } - return nil -} - -var File_message_contents_ciphertext_proto protoreflect.FileDescriptor - -const file_message_contents_ciphertext_proto_rawDesc = "" + - "\n" + - "!message_contents/ciphertext.proto\x12\x15xmtp.message_contents\x1a message_contents/signature.proto\"\xee\x01\n" + - "\n" + - "Ciphertext\x12l\n" + - "\x16aes256_gcm_hkdf_sha256\x18\x01 \x01(\v25.xmtp.message_contents.Ciphertext.Aes256gcmHkdfsha256H\x00R\x13aes256GcmHkdfSha256\x1ai\n" + - "\x13Aes256gcmHkdfsha256\x12\x1b\n" + - "\thkdf_salt\x18\x01 \x01(\fR\bhkdfSalt\x12\x1b\n" + - "\tgcm_nonce\x18\x02 \x01(\fR\bgcmNonce\x12\x18\n" + - "\apayload\x18\x03 \x01(\fR\apayloadB\a\n" + - "\x05union\"\xf5\x01\n" + - "\x15SignedEciesCiphertext\x12\x1f\n" + - "\vecies_bytes\x18\x01 \x01(\fR\n" + - "eciesBytes\x12>\n" + - "\tsignature\x18\x02 \x01(\v2 .xmtp.message_contents.SignatureR\tsignature\x1a{\n" + - "\x05Ecies\x120\n" + - "\x14ephemeral_public_key\x18\x01 \x01(\fR\x12ephemeralPublicKey\x12\x0e\n" + - "\x02iv\x18\x02 \x01(\fR\x02iv\x12\x10\n" + - "\x03mac\x18\x03 \x01(\fR\x03mac\x12\x1e\n" + - "\n" + - "ciphertext\x18\x04 \x01(\fR\n" + - "ciphertextB\x82\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x0fCiphertextProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_ciphertext_proto_rawDescOnce sync.Once - file_message_contents_ciphertext_proto_rawDescData []byte -) - -func file_message_contents_ciphertext_proto_rawDescGZIP() []byte { - file_message_contents_ciphertext_proto_rawDescOnce.Do(func() { - file_message_contents_ciphertext_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_ciphertext_proto_rawDesc), len(file_message_contents_ciphertext_proto_rawDesc))) - }) - return file_message_contents_ciphertext_proto_rawDescData -} - -var file_message_contents_ciphertext_proto_msgTypes = make([]protoimpl.MessageInfo, 4) -var file_message_contents_ciphertext_proto_goTypes = []any{ - (*Ciphertext)(nil), // 0: xmtp.message_contents.Ciphertext - (*SignedEciesCiphertext)(nil), // 1: xmtp.message_contents.SignedEciesCiphertext - (*Ciphertext_Aes256GcmHkdfsha256)(nil), // 2: xmtp.message_contents.Ciphertext.Aes256gcmHkdfsha256 - (*SignedEciesCiphertext_Ecies)(nil), // 3: xmtp.message_contents.SignedEciesCiphertext.Ecies - (*Signature)(nil), // 4: xmtp.message_contents.Signature -} -var file_message_contents_ciphertext_proto_depIdxs = []int32{ - 2, // 0: xmtp.message_contents.Ciphertext.aes256_gcm_hkdf_sha256:type_name -> xmtp.message_contents.Ciphertext.Aes256gcmHkdfsha256 - 4, // 1: xmtp.message_contents.SignedEciesCiphertext.signature:type_name -> xmtp.message_contents.Signature - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_message_contents_ciphertext_proto_init() } -func file_message_contents_ciphertext_proto_init() { - if File_message_contents_ciphertext_proto != nil { - return - } - file_message_contents_signature_proto_init() - file_message_contents_ciphertext_proto_msgTypes[0].OneofWrappers = []any{ - (*Ciphertext_Aes256GcmHkdfSha256)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_ciphertext_proto_rawDesc), len(file_message_contents_ciphertext_proto_rawDesc)), - NumEnums: 0, - NumMessages: 4, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_ciphertext_proto_goTypes, - DependencyIndexes: file_message_contents_ciphertext_proto_depIdxs, - MessageInfos: file_message_contents_ciphertext_proto_msgTypes, - }.Build() - File_message_contents_ciphertext_proto = out.File - file_message_contents_ciphertext_proto_goTypes = nil - file_message_contents_ciphertext_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/composite.pb.go b/pkg/proto/message_contents/composite.pb.go deleted file mode 100644 index e078c466..00000000 --- a/pkg/proto/message_contents/composite.pb.go +++ /dev/null @@ -1,223 +0,0 @@ -// Composite ContentType - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/composite.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Composite is used to implement xmtp.org/composite content type -type Composite struct { - state protoimpl.MessageState `protogen:"open.v1"` - Parts []*Composite_Part `protobuf:"bytes,1,rep,name=parts,proto3" json:"parts,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Composite) Reset() { - *x = Composite{} - mi := &file_message_contents_composite_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Composite) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Composite) ProtoMessage() {} - -func (x *Composite) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_composite_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Composite.ProtoReflect.Descriptor instead. -func (*Composite) Descriptor() ([]byte, []int) { - return file_message_contents_composite_proto_rawDescGZIP(), []int{0} -} - -func (x *Composite) GetParts() []*Composite_Part { - if x != nil { - return x.Parts - } - return nil -} - -// Part represents one section of a composite message -type Composite_Part struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Element: - // - // *Composite_Part_Part - // *Composite_Part_Composite - Element isComposite_Part_Element `protobuf_oneof:"element"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Composite_Part) Reset() { - *x = Composite_Part{} - mi := &file_message_contents_composite_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Composite_Part) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Composite_Part) ProtoMessage() {} - -func (x *Composite_Part) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_composite_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Composite_Part.ProtoReflect.Descriptor instead. -func (*Composite_Part) Descriptor() ([]byte, []int) { - return file_message_contents_composite_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *Composite_Part) GetElement() isComposite_Part_Element { - if x != nil { - return x.Element - } - return nil -} - -func (x *Composite_Part) GetPart() *EncodedContent { - if x != nil { - if x, ok := x.Element.(*Composite_Part_Part); ok { - return x.Part - } - } - return nil -} - -func (x *Composite_Part) GetComposite() *Composite { - if x != nil { - if x, ok := x.Element.(*Composite_Part_Composite); ok { - return x.Composite - } - } - return nil -} - -type isComposite_Part_Element interface { - isComposite_Part_Element() -} - -type Composite_Part_Part struct { - Part *EncodedContent `protobuf:"bytes,1,opt,name=part,proto3,oneof"` -} - -type Composite_Part_Composite struct { - Composite *Composite `protobuf:"bytes,2,opt,name=composite,proto3,oneof"` -} - -func (*Composite_Part_Part) isComposite_Part_Element() {} - -func (*Composite_Part_Composite) isComposite_Part_Element() {} - -var File_message_contents_composite_proto protoreflect.FileDescriptor - -const file_message_contents_composite_proto_rawDesc = "" + - "\n" + - " message_contents/composite.proto\x12\x15xmtp.message_contents\x1a\x1emessage_contents/content.proto\"\xdb\x01\n" + - "\tComposite\x12;\n" + - "\x05parts\x18\x01 \x03(\v2%.xmtp.message_contents.Composite.PartR\x05parts\x1a\x90\x01\n" + - "\x04Part\x12;\n" + - "\x04part\x18\x01 \x01(\v2%.xmtp.message_contents.EncodedContentH\x00R\x04part\x12@\n" + - "\tcomposite\x18\x02 \x01(\v2 .xmtp.message_contents.CompositeH\x00R\tcompositeB\t\n" + - "\aelementB\x81\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x0eCompositeProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_composite_proto_rawDescOnce sync.Once - file_message_contents_composite_proto_rawDescData []byte -) - -func file_message_contents_composite_proto_rawDescGZIP() []byte { - file_message_contents_composite_proto_rawDescOnce.Do(func() { - file_message_contents_composite_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_composite_proto_rawDesc), len(file_message_contents_composite_proto_rawDesc))) - }) - return file_message_contents_composite_proto_rawDescData -} - -var file_message_contents_composite_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_message_contents_composite_proto_goTypes = []any{ - (*Composite)(nil), // 0: xmtp.message_contents.Composite - (*Composite_Part)(nil), // 1: xmtp.message_contents.Composite.Part - (*EncodedContent)(nil), // 2: xmtp.message_contents.EncodedContent -} -var file_message_contents_composite_proto_depIdxs = []int32{ - 1, // 0: xmtp.message_contents.Composite.parts:type_name -> xmtp.message_contents.Composite.Part - 2, // 1: xmtp.message_contents.Composite.Part.part:type_name -> xmtp.message_contents.EncodedContent - 0, // 2: xmtp.message_contents.Composite.Part.composite:type_name -> xmtp.message_contents.Composite - 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_message_contents_composite_proto_init() } -func file_message_contents_composite_proto_init() { - if File_message_contents_composite_proto != nil { - return - } - file_message_contents_content_proto_init() - file_message_contents_composite_proto_msgTypes[1].OneofWrappers = []any{ - (*Composite_Part_Part)(nil), - (*Composite_Part_Composite)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_composite_proto_rawDesc), len(file_message_contents_composite_proto_rawDesc)), - NumEnums: 0, - NumMessages: 2, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_composite_proto_goTypes, - DependencyIndexes: file_message_contents_composite_proto_depIdxs, - MessageInfos: file_message_contents_composite_proto_msgTypes, - }.Build() - File_message_contents_composite_proto = out.File - file_message_contents_composite_proto_goTypes = nil - file_message_contents_composite_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/contact.pb.go b/pkg/proto/message_contents/contact.pb.go deleted file mode 100644 index 2d048b0e..00000000 --- a/pkg/proto/message_contents/contact.pb.go +++ /dev/null @@ -1,280 +0,0 @@ -// Contact Bundles are used to advertise user's public keys on the network. -// They are published in well known topics so that other participants -// can find them when they wish to communicate with the user. -// The public keys are used to sign messages and to derive encryption keys -// for some meta-messages, e.g. invitations. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/contact.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// LEGACY: User key bundle V1 using PublicKeys. -// The PublicKeys MUST be signed. -type ContactBundleV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyBundle *PublicKeyBundle `protobuf:"bytes,1,opt,name=key_bundle,json=keyBundle,proto3" json:"key_bundle,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ContactBundleV1) Reset() { - *x = ContactBundleV1{} - mi := &file_message_contents_contact_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ContactBundleV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ContactBundleV1) ProtoMessage() {} - -func (x *ContactBundleV1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_contact_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ContactBundleV1.ProtoReflect.Descriptor instead. -func (*ContactBundleV1) Descriptor() ([]byte, []int) { - return file_message_contents_contact_proto_rawDescGZIP(), []int{0} -} - -func (x *ContactBundleV1) GetKeyBundle() *PublicKeyBundle { - if x != nil { - return x.KeyBundle - } - return nil -} - -// User key bundle V2 using SignedPublicKeys. -type ContactBundleV2 struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyBundle *SignedPublicKeyBundle `protobuf:"bytes,1,opt,name=key_bundle,json=keyBundle,proto3" json:"key_bundle,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ContactBundleV2) Reset() { - *x = ContactBundleV2{} - mi := &file_message_contents_contact_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ContactBundleV2) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ContactBundleV2) ProtoMessage() {} - -func (x *ContactBundleV2) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_contact_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ContactBundleV2.ProtoReflect.Descriptor instead. -func (*ContactBundleV2) Descriptor() ([]byte, []int) { - return file_message_contents_contact_proto_rawDescGZIP(), []int{1} -} - -func (x *ContactBundleV2) GetKeyBundle() *SignedPublicKeyBundle { - if x != nil { - return x.KeyBundle - } - return nil -} - -// Versioned ContactBundle -type ContactBundle struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *ContactBundle_V1 - // *ContactBundle_V2 - Version isContactBundle_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ContactBundle) Reset() { - *x = ContactBundle{} - mi := &file_message_contents_contact_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ContactBundle) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ContactBundle) ProtoMessage() {} - -func (x *ContactBundle) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_contact_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ContactBundle.ProtoReflect.Descriptor instead. -func (*ContactBundle) Descriptor() ([]byte, []int) { - return file_message_contents_contact_proto_rawDescGZIP(), []int{2} -} - -func (x *ContactBundle) GetVersion() isContactBundle_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *ContactBundle) GetV1() *ContactBundleV1 { - if x != nil { - if x, ok := x.Version.(*ContactBundle_V1); ok { - return x.V1 - } - } - return nil -} - -func (x *ContactBundle) GetV2() *ContactBundleV2 { - if x != nil { - if x, ok := x.Version.(*ContactBundle_V2); ok { - return x.V2 - } - } - return nil -} - -type isContactBundle_Version interface { - isContactBundle_Version() -} - -type ContactBundle_V1 struct { - V1 *ContactBundleV1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -type ContactBundle_V2 struct { - V2 *ContactBundleV2 `protobuf:"bytes,2,opt,name=v2,proto3,oneof"` -} - -func (*ContactBundle_V1) isContactBundle_Version() {} - -func (*ContactBundle_V2) isContactBundle_Version() {} - -var File_message_contents_contact_proto protoreflect.FileDescriptor - -const file_message_contents_contact_proto_rawDesc = "" + - "\n" + - "\x1emessage_contents/contact.proto\x12\x15xmtp.message_contents\x1a!message_contents/public_key.proto\"X\n" + - "\x0fContactBundleV1\x12E\n" + - "\n" + - "key_bundle\x18\x01 \x01(\v2&.xmtp.message_contents.PublicKeyBundleR\tkeyBundle\"^\n" + - "\x0fContactBundleV2\x12K\n" + - "\n" + - "key_bundle\x18\x01 \x01(\v2,.xmtp.message_contents.SignedPublicKeyBundleR\tkeyBundle\"\x8e\x01\n" + - "\rContactBundle\x128\n" + - "\x02v1\x18\x01 \x01(\v2&.xmtp.message_contents.ContactBundleV1H\x00R\x02v1\x128\n" + - "\x02v2\x18\x02 \x01(\v2&.xmtp.message_contents.ContactBundleV2H\x00R\x02v2B\t\n" + - "\aversionB\xff\x01\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\fContactProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_contact_proto_rawDescOnce sync.Once - file_message_contents_contact_proto_rawDescData []byte -) - -func file_message_contents_contact_proto_rawDescGZIP() []byte { - file_message_contents_contact_proto_rawDescOnce.Do(func() { - file_message_contents_contact_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_contact_proto_rawDesc), len(file_message_contents_contact_proto_rawDesc))) - }) - return file_message_contents_contact_proto_rawDescData -} - -var file_message_contents_contact_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_message_contents_contact_proto_goTypes = []any{ - (*ContactBundleV1)(nil), // 0: xmtp.message_contents.ContactBundleV1 - (*ContactBundleV2)(nil), // 1: xmtp.message_contents.ContactBundleV2 - (*ContactBundle)(nil), // 2: xmtp.message_contents.ContactBundle - (*PublicKeyBundle)(nil), // 3: xmtp.message_contents.PublicKeyBundle - (*SignedPublicKeyBundle)(nil), // 4: xmtp.message_contents.SignedPublicKeyBundle -} -var file_message_contents_contact_proto_depIdxs = []int32{ - 3, // 0: xmtp.message_contents.ContactBundleV1.key_bundle:type_name -> xmtp.message_contents.PublicKeyBundle - 4, // 1: xmtp.message_contents.ContactBundleV2.key_bundle:type_name -> xmtp.message_contents.SignedPublicKeyBundle - 0, // 2: xmtp.message_contents.ContactBundle.v1:type_name -> xmtp.message_contents.ContactBundleV1 - 1, // 3: xmtp.message_contents.ContactBundle.v2:type_name -> xmtp.message_contents.ContactBundleV2 - 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_message_contents_contact_proto_init() } -func file_message_contents_contact_proto_init() { - if File_message_contents_contact_proto != nil { - return - } - file_message_contents_public_key_proto_init() - file_message_contents_contact_proto_msgTypes[2].OneofWrappers = []any{ - (*ContactBundle_V1)(nil), - (*ContactBundle_V2)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_contact_proto_rawDesc), len(file_message_contents_contact_proto_rawDesc)), - NumEnums: 0, - NumMessages: 3, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_contact_proto_goTypes, - DependencyIndexes: file_message_contents_contact_proto_depIdxs, - MessageInfos: file_message_contents_contact_proto_msgTypes, - }.Build() - File_message_contents_contact_proto = out.File - file_message_contents_contact_proto_goTypes = nil - file_message_contents_contact_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/content.pb.go b/pkg/proto/message_contents/content.pb.go deleted file mode 100644 index d2a95270..00000000 --- a/pkg/proto/message_contents/content.pb.go +++ /dev/null @@ -1,388 +0,0 @@ -// Message content encoding structures - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/content.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Recognized compression algorithms -// protolint:disable ENUM_FIELD_NAMES_ZERO_VALUE_END_WITH -type Compression int32 - -const ( - Compression_COMPRESSION_DEFLATE Compression = 0 - Compression_COMPRESSION_GZIP Compression = 1 -) - -// Enum value maps for Compression. -var ( - Compression_name = map[int32]string{ - 0: "COMPRESSION_DEFLATE", - 1: "COMPRESSION_GZIP", - } - Compression_value = map[string]int32{ - "COMPRESSION_DEFLATE": 0, - "COMPRESSION_GZIP": 1, - } -) - -func (x Compression) Enum() *Compression { - p := new(Compression) - *p = x - return p -} - -func (x Compression) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (Compression) Descriptor() protoreflect.EnumDescriptor { - return file_message_contents_content_proto_enumTypes[0].Descriptor() -} - -func (Compression) Type() protoreflect.EnumType { - return &file_message_contents_content_proto_enumTypes[0] -} - -func (x Compression) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use Compression.Descriptor instead. -func (Compression) EnumDescriptor() ([]byte, []int) { - return file_message_contents_content_proto_rawDescGZIP(), []int{0} -} - -// ContentTypeId is used to identify the type of content stored in a Message. -type ContentTypeId struct { - state protoimpl.MessageState `protogen:"open.v1"` - AuthorityId string `protobuf:"bytes,1,opt,name=authority_id,json=authorityId,proto3" json:"authority_id,omitempty"` // authority governing this content type - TypeId string `protobuf:"bytes,2,opt,name=type_id,json=typeId,proto3" json:"type_id,omitempty"` // type identifier - VersionMajor uint32 `protobuf:"varint,3,opt,name=version_major,json=versionMajor,proto3" json:"version_major,omitempty"` // major version of the type - VersionMinor uint32 `protobuf:"varint,4,opt,name=version_minor,json=versionMinor,proto3" json:"version_minor,omitempty"` // minor version of the type - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ContentTypeId) Reset() { - *x = ContentTypeId{} - mi := &file_message_contents_content_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ContentTypeId) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ContentTypeId) ProtoMessage() {} - -func (x *ContentTypeId) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_content_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ContentTypeId.ProtoReflect.Descriptor instead. -func (*ContentTypeId) Descriptor() ([]byte, []int) { - return file_message_contents_content_proto_rawDescGZIP(), []int{0} -} - -func (x *ContentTypeId) GetAuthorityId() string { - if x != nil { - return x.AuthorityId - } - return "" -} - -func (x *ContentTypeId) GetTypeId() string { - if x != nil { - return x.TypeId - } - return "" -} - -func (x *ContentTypeId) GetVersionMajor() uint32 { - if x != nil { - return x.VersionMajor - } - return 0 -} - -func (x *ContentTypeId) GetVersionMinor() uint32 { - if x != nil { - return x.VersionMinor - } - return 0 -} - -// EncodedContent bundles the content with metadata identifying its type -// and parameters required for correct decoding and presentation of the content. -type EncodedContent struct { - state protoimpl.MessageState `protogen:"open.v1"` - // content type identifier used to match the payload with - // the correct decoding machinery - Type *ContentTypeId `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"` - // optional encoding parameters required to correctly decode the content - Parameters map[string]string `protobuf:"bytes,2,rep,name=parameters,proto3" json:"parameters,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - // optional fallback description of the content that can be used in case - // the client cannot decode or render the content - Fallback *string `protobuf:"bytes,3,opt,name=fallback,proto3,oneof" json:"fallback,omitempty"` - // optional compression; the value indicates algorithm used to - // compress the encoded content bytes - Compression *Compression `protobuf:"varint,5,opt,name=compression,proto3,enum=xmtp.message_contents.Compression,oneof" json:"compression,omitempty"` - // encoded content itself - Content []byte `protobuf:"bytes,4,opt,name=content,proto3" json:"content,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncodedContent) Reset() { - *x = EncodedContent{} - mi := &file_message_contents_content_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncodedContent) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncodedContent) ProtoMessage() {} - -func (x *EncodedContent) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_content_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncodedContent.ProtoReflect.Descriptor instead. -func (*EncodedContent) Descriptor() ([]byte, []int) { - return file_message_contents_content_proto_rawDescGZIP(), []int{1} -} - -func (x *EncodedContent) GetType() *ContentTypeId { - if x != nil { - return x.Type - } - return nil -} - -func (x *EncodedContent) GetParameters() map[string]string { - if x != nil { - return x.Parameters - } - return nil -} - -func (x *EncodedContent) GetFallback() string { - if x != nil && x.Fallback != nil { - return *x.Fallback - } - return "" -} - -func (x *EncodedContent) GetCompression() Compression { - if x != nil && x.Compression != nil { - return *x.Compression - } - return Compression_COMPRESSION_DEFLATE -} - -func (x *EncodedContent) GetContent() []byte { - if x != nil { - return x.Content - } - return nil -} - -// SignedContent attaches a signature to EncodedContent. -type SignedContent struct { - state protoimpl.MessageState `protogen:"open.v1"` - // MUST contain EncodedContent - Payload []byte `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"` - Sender *SignedPublicKeyBundle `protobuf:"bytes,2,opt,name=sender,proto3" json:"sender,omitempty"` - // MUST be a signature of a concatenation of - // the message header bytes and the payload bytes, - // signed by the sender's pre-key. - Signature *Signature `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignedContent) Reset() { - *x = SignedContent{} - mi := &file_message_contents_content_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignedContent) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignedContent) ProtoMessage() {} - -func (x *SignedContent) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_content_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignedContent.ProtoReflect.Descriptor instead. -func (*SignedContent) Descriptor() ([]byte, []int) { - return file_message_contents_content_proto_rawDescGZIP(), []int{2} -} - -func (x *SignedContent) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -func (x *SignedContent) GetSender() *SignedPublicKeyBundle { - if x != nil { - return x.Sender - } - return nil -} - -func (x *SignedContent) GetSignature() *Signature { - if x != nil { - return x.Signature - } - return nil -} - -var File_message_contents_content_proto protoreflect.FileDescriptor - -const file_message_contents_content_proto_rawDesc = "" + - "\n" + - "\x1emessage_contents/content.proto\x12\x15xmtp.message_contents\x1a!message_contents/public_key.proto\x1a message_contents/signature.proto\"\x95\x01\n" + - "\rContentTypeId\x12!\n" + - "\fauthority_id\x18\x01 \x01(\tR\vauthorityId\x12\x17\n" + - "\atype_id\x18\x02 \x01(\tR\x06typeId\x12#\n" + - "\rversion_major\x18\x03 \x01(\rR\fversionMajor\x12#\n" + - "\rversion_minor\x18\x04 \x01(\rR\fversionMinor\"\x83\x03\n" + - "\x0eEncodedContent\x128\n" + - "\x04type\x18\x01 \x01(\v2$.xmtp.message_contents.ContentTypeIdR\x04type\x12U\n" + - "\n" + - "parameters\x18\x02 \x03(\v25.xmtp.message_contents.EncodedContent.ParametersEntryR\n" + - "parameters\x12\x1f\n" + - "\bfallback\x18\x03 \x01(\tH\x00R\bfallback\x88\x01\x01\x12I\n" + - "\vcompression\x18\x05 \x01(\x0e2\".xmtp.message_contents.CompressionH\x01R\vcompression\x88\x01\x01\x12\x18\n" + - "\acontent\x18\x04 \x01(\fR\acontent\x1a=\n" + - "\x0fParametersEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01B\v\n" + - "\t_fallbackB\x0e\n" + - "\f_compression\"\xaf\x01\n" + - "\rSignedContent\x12\x18\n" + - "\apayload\x18\x01 \x01(\fR\apayload\x12D\n" + - "\x06sender\x18\x02 \x01(\v2,.xmtp.message_contents.SignedPublicKeyBundleR\x06sender\x12>\n" + - "\tsignature\x18\x03 \x01(\v2 .xmtp.message_contents.SignatureR\tsignature*<\n" + - "\vCompression\x12\x17\n" + - "\x13COMPRESSION_DEFLATE\x10\x00\x12\x14\n" + - "\x10COMPRESSION_GZIP\x10\x01B\xff\x01\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\fContentProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_content_proto_rawDescOnce sync.Once - file_message_contents_content_proto_rawDescData []byte -) - -func file_message_contents_content_proto_rawDescGZIP() []byte { - file_message_contents_content_proto_rawDescOnce.Do(func() { - file_message_contents_content_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_content_proto_rawDesc), len(file_message_contents_content_proto_rawDesc))) - }) - return file_message_contents_content_proto_rawDescData -} - -var file_message_contents_content_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_message_contents_content_proto_msgTypes = make([]protoimpl.MessageInfo, 4) -var file_message_contents_content_proto_goTypes = []any{ - (Compression)(0), // 0: xmtp.message_contents.Compression - (*ContentTypeId)(nil), // 1: xmtp.message_contents.ContentTypeId - (*EncodedContent)(nil), // 2: xmtp.message_contents.EncodedContent - (*SignedContent)(nil), // 3: xmtp.message_contents.SignedContent - nil, // 4: xmtp.message_contents.EncodedContent.ParametersEntry - (*SignedPublicKeyBundle)(nil), // 5: xmtp.message_contents.SignedPublicKeyBundle - (*Signature)(nil), // 6: xmtp.message_contents.Signature -} -var file_message_contents_content_proto_depIdxs = []int32{ - 1, // 0: xmtp.message_contents.EncodedContent.type:type_name -> xmtp.message_contents.ContentTypeId - 4, // 1: xmtp.message_contents.EncodedContent.parameters:type_name -> xmtp.message_contents.EncodedContent.ParametersEntry - 0, // 2: xmtp.message_contents.EncodedContent.compression:type_name -> xmtp.message_contents.Compression - 5, // 3: xmtp.message_contents.SignedContent.sender:type_name -> xmtp.message_contents.SignedPublicKeyBundle - 6, // 4: xmtp.message_contents.SignedContent.signature:type_name -> xmtp.message_contents.Signature - 5, // [5:5] is the sub-list for method output_type - 5, // [5:5] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name -} - -func init() { file_message_contents_content_proto_init() } -func file_message_contents_content_proto_init() { - if File_message_contents_content_proto != nil { - return - } - file_message_contents_public_key_proto_init() - file_message_contents_signature_proto_init() - file_message_contents_content_proto_msgTypes[1].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_content_proto_rawDesc), len(file_message_contents_content_proto_rawDesc)), - NumEnums: 1, - NumMessages: 4, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_content_proto_goTypes, - DependencyIndexes: file_message_contents_content_proto_depIdxs, - EnumInfos: file_message_contents_content_proto_enumTypes, - MessageInfos: file_message_contents_content_proto_msgTypes, - }.Build() - File_message_contents_content_proto = out.File - file_message_contents_content_proto_goTypes = nil - file_message_contents_content_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/conversation_reference.pb.go b/pkg/proto/message_contents/conversation_reference.pb.go deleted file mode 100644 index f3a5bb79..00000000 --- a/pkg/proto/message_contents/conversation_reference.pb.go +++ /dev/null @@ -1,168 +0,0 @@ -// Holds the ConversationReference - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/conversation_reference.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// A light pointer for a conversation that contains no decryption keys -type ConversationReference struct { - state protoimpl.MessageState `protogen:"open.v1"` - Topic string `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"` - PeerAddress string `protobuf:"bytes,2,opt,name=peer_address,json=peerAddress,proto3" json:"peer_address,omitempty"` - CreatedNs uint64 `protobuf:"varint,3,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - Context *InvitationV1_Context `protobuf:"bytes,4,opt,name=context,proto3" json:"context,omitempty"` - ConsentProofPayload *ConsentProofPayload `protobuf:"bytes,5,opt,name=consent_proof_payload,json=consentProofPayload,proto3" json:"consent_proof_payload,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ConversationReference) Reset() { - *x = ConversationReference{} - mi := &file_message_contents_conversation_reference_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ConversationReference) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ConversationReference) ProtoMessage() {} - -func (x *ConversationReference) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_conversation_reference_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ConversationReference.ProtoReflect.Descriptor instead. -func (*ConversationReference) Descriptor() ([]byte, []int) { - return file_message_contents_conversation_reference_proto_rawDescGZIP(), []int{0} -} - -func (x *ConversationReference) GetTopic() string { - if x != nil { - return x.Topic - } - return "" -} - -func (x *ConversationReference) GetPeerAddress() string { - if x != nil { - return x.PeerAddress - } - return "" -} - -func (x *ConversationReference) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *ConversationReference) GetContext() *InvitationV1_Context { - if x != nil { - return x.Context - } - return nil -} - -func (x *ConversationReference) GetConsentProofPayload() *ConsentProofPayload { - if x != nil { - return x.ConsentProofPayload - } - return nil -} - -var File_message_contents_conversation_reference_proto protoreflect.FileDescriptor - -const file_message_contents_conversation_reference_proto_rawDesc = "" + - "\n" + - "-message_contents/conversation_reference.proto\x12\x15xmtp.message_contents\x1a!message_contents/invitation.proto\"\x96\x02\n" + - "\x15ConversationReference\x12\x14\n" + - "\x05topic\x18\x01 \x01(\tR\x05topic\x12!\n" + - "\fpeer_address\x18\x02 \x01(\tR\vpeerAddress\x12\x1d\n" + - "\n" + - "created_ns\x18\x03 \x01(\x04R\tcreatedNs\x12E\n" + - "\acontext\x18\x04 \x01(\v2+.xmtp.message_contents.InvitationV1.ContextR\acontext\x12^\n" + - "\x15consent_proof_payload\x18\x05 \x01(\v2*.xmtp.message_contents.ConsentProofPayloadR\x13consentProofPayloadB\x8d\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x1aConversationReferenceProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_conversation_reference_proto_rawDescOnce sync.Once - file_message_contents_conversation_reference_proto_rawDescData []byte -) - -func file_message_contents_conversation_reference_proto_rawDescGZIP() []byte { - file_message_contents_conversation_reference_proto_rawDescOnce.Do(func() { - file_message_contents_conversation_reference_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_conversation_reference_proto_rawDesc), len(file_message_contents_conversation_reference_proto_rawDesc))) - }) - return file_message_contents_conversation_reference_proto_rawDescData -} - -var file_message_contents_conversation_reference_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_message_contents_conversation_reference_proto_goTypes = []any{ - (*ConversationReference)(nil), // 0: xmtp.message_contents.ConversationReference - (*InvitationV1_Context)(nil), // 1: xmtp.message_contents.InvitationV1.Context - (*ConsentProofPayload)(nil), // 2: xmtp.message_contents.ConsentProofPayload -} -var file_message_contents_conversation_reference_proto_depIdxs = []int32{ - 1, // 0: xmtp.message_contents.ConversationReference.context:type_name -> xmtp.message_contents.InvitationV1.Context - 2, // 1: xmtp.message_contents.ConversationReference.consent_proof_payload:type_name -> xmtp.message_contents.ConsentProofPayload - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_message_contents_conversation_reference_proto_init() } -func file_message_contents_conversation_reference_proto_init() { - if File_message_contents_conversation_reference_proto != nil { - return - } - file_message_contents_invitation_proto_init() - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_conversation_reference_proto_rawDesc), len(file_message_contents_conversation_reference_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_conversation_reference_proto_goTypes, - DependencyIndexes: file_message_contents_conversation_reference_proto_depIdxs, - MessageInfos: file_message_contents_conversation_reference_proto_msgTypes, - }.Build() - File_message_contents_conversation_reference_proto = out.File - file_message_contents_conversation_reference_proto_goTypes = nil - file_message_contents_conversation_reference_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/ecies.pb.go b/pkg/proto/message_contents/ecies.pb.go deleted file mode 100644 index e9b75853..00000000 --- a/pkg/proto/message_contents/ecies.pb.go +++ /dev/null @@ -1,154 +0,0 @@ -// ECIES is a wrapper for ECIES payloads - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/ecies.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// EciesMessage is a wrapper for ECIES encrypted payloads -type EciesMessage struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *EciesMessage_V1 - Version isEciesMessage_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EciesMessage) Reset() { - *x = EciesMessage{} - mi := &file_message_contents_ecies_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EciesMessage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EciesMessage) ProtoMessage() {} - -func (x *EciesMessage) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_ecies_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EciesMessage.ProtoReflect.Descriptor instead. -func (*EciesMessage) Descriptor() ([]byte, []int) { - return file_message_contents_ecies_proto_rawDescGZIP(), []int{0} -} - -func (x *EciesMessage) GetVersion() isEciesMessage_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *EciesMessage) GetV1() []byte { - if x != nil { - if x, ok := x.Version.(*EciesMessage_V1); ok { - return x.V1 - } - } - return nil -} - -type isEciesMessage_Version interface { - isEciesMessage_Version() -} - -type EciesMessage_V1 struct { - // Expected to be an ECIES encrypted SignedPayload - V1 []byte `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*EciesMessage_V1) isEciesMessage_Version() {} - -var File_message_contents_ecies_proto protoreflect.FileDescriptor - -const file_message_contents_ecies_proto_rawDesc = "" + - "\n" + - "\x1cmessage_contents/ecies.proto\x12\x15xmtp.message_contents\"+\n" + - "\fEciesMessage\x12\x10\n" + - "\x02v1\x18\x01 \x01(\fH\x00R\x02v1B\t\n" + - "\aversionB\xfd\x01\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\n" + - "EciesProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_ecies_proto_rawDescOnce sync.Once - file_message_contents_ecies_proto_rawDescData []byte -) - -func file_message_contents_ecies_proto_rawDescGZIP() []byte { - file_message_contents_ecies_proto_rawDescOnce.Do(func() { - file_message_contents_ecies_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_ecies_proto_rawDesc), len(file_message_contents_ecies_proto_rawDesc))) - }) - return file_message_contents_ecies_proto_rawDescData -} - -var file_message_contents_ecies_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_message_contents_ecies_proto_goTypes = []any{ - (*EciesMessage)(nil), // 0: xmtp.message_contents.EciesMessage -} -var file_message_contents_ecies_proto_depIdxs = []int32{ - 0, // [0:0] is the sub-list for method output_type - 0, // [0:0] 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_message_contents_ecies_proto_init() } -func file_message_contents_ecies_proto_init() { - if File_message_contents_ecies_proto != nil { - return - } - file_message_contents_ecies_proto_msgTypes[0].OneofWrappers = []any{ - (*EciesMessage_V1)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_ecies_proto_rawDesc), len(file_message_contents_ecies_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_ecies_proto_goTypes, - DependencyIndexes: file_message_contents_ecies_proto_depIdxs, - MessageInfos: file_message_contents_ecies_proto_msgTypes, - }.Build() - File_message_contents_ecies_proto = out.File - file_message_contents_ecies_proto_goTypes = nil - file_message_contents_ecies_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/frames.pb.go b/pkg/proto/message_contents/frames.pb.go deleted file mode 100644 index dfcd08ec..00000000 --- a/pkg/proto/message_contents/frames.pb.go +++ /dev/null @@ -1,327 +0,0 @@ -// Signature is a generic structure for public key signatures. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/frames.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// The message that will be signed by the Client and returned inside the -// `action_body` field of the FrameAction message -type FrameActionBody struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The URL of the frame that was clicked - // May be different from `post_url` - FrameUrl string `protobuf:"bytes,1,opt,name=frame_url,json=frameUrl,proto3" json:"frame_url,omitempty"` - // The 1-indexed button that was clicked - ButtonIndex int32 `protobuf:"varint,2,opt,name=button_index,json=buttonIndex,proto3" json:"button_index,omitempty"` - // Timestamp of the click in milliseconds since the epoch - // - // Deprecated: Marked as deprecated in message_contents/frames.proto. - Timestamp uint64 `protobuf:"varint,3,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - // A unique identifier for the conversation, not tied to anything on the - // network. Will not match the topic or conversation_id - OpaqueConversationIdentifier string `protobuf:"bytes,4,opt,name=opaque_conversation_identifier,json=opaqueConversationIdentifier,proto3" json:"opaque_conversation_identifier,omitempty"` - // Unix timestamp - UnixTimestamp uint32 `protobuf:"varint,5,opt,name=unix_timestamp,json=unixTimestamp,proto3" json:"unix_timestamp,omitempty"` - // Input text from a text input field - InputText string `protobuf:"bytes,6,opt,name=input_text,json=inputText,proto3" json:"input_text,omitempty"` - // A state serialized to a string (for example via JSON.stringify()). Maximum 4096 bytes. - State string `protobuf:"bytes,7,opt,name=state,proto3" json:"state,omitempty"` - // A 0x wallet address - Address string `protobuf:"bytes,8,opt,name=address,proto3" json:"address,omitempty"` - // A hash from a transaction - TransactionId string `protobuf:"bytes,9,opt,name=transaction_id,json=transactionId,proto3" json:"transaction_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *FrameActionBody) Reset() { - *x = FrameActionBody{} - mi := &file_message_contents_frames_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *FrameActionBody) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*FrameActionBody) ProtoMessage() {} - -func (x *FrameActionBody) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_frames_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use FrameActionBody.ProtoReflect.Descriptor instead. -func (*FrameActionBody) Descriptor() ([]byte, []int) { - return file_message_contents_frames_proto_rawDescGZIP(), []int{0} -} - -func (x *FrameActionBody) GetFrameUrl() string { - if x != nil { - return x.FrameUrl - } - return "" -} - -func (x *FrameActionBody) GetButtonIndex() int32 { - if x != nil { - return x.ButtonIndex - } - return 0 -} - -// Deprecated: Marked as deprecated in message_contents/frames.proto. -func (x *FrameActionBody) GetTimestamp() uint64 { - if x != nil { - return x.Timestamp - } - return 0 -} - -func (x *FrameActionBody) GetOpaqueConversationIdentifier() string { - if x != nil { - return x.OpaqueConversationIdentifier - } - return "" -} - -func (x *FrameActionBody) GetUnixTimestamp() uint32 { - if x != nil { - return x.UnixTimestamp - } - return 0 -} - -func (x *FrameActionBody) GetInputText() string { - if x != nil { - return x.InputText - } - return "" -} - -func (x *FrameActionBody) GetState() string { - if x != nil { - return x.State - } - return "" -} - -func (x *FrameActionBody) GetAddress() string { - if x != nil { - return x.Address - } - return "" -} - -func (x *FrameActionBody) GetTransactionId() string { - if x != nil { - return x.TransactionId - } - return "" -} - -// The outer payload that will be sent as the `messageBytes` in the -// `trusted_data` part of the Frames message -type FrameAction struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Deprecated: Marked as deprecated in message_contents/frames.proto. - Signature *Signature `protobuf:"bytes,1,opt,name=signature,proto3" json:"signature,omitempty"` - // The SignedPublicKeyBundle of the signer, used to link the XMTP signature - // with a blockchain account through a chain of signatures. - // - // Deprecated: Marked as deprecated in message_contents/frames.proto. - SignedPublicKeyBundle *SignedPublicKeyBundle `protobuf:"bytes,2,opt,name=signed_public_key_bundle,json=signedPublicKeyBundle,proto3" json:"signed_public_key_bundle,omitempty"` - // Serialized FrameActionBody message, so that the signature verification can - // happen on a byte-perfect representation of the message - ActionBody []byte `protobuf:"bytes,3,opt,name=action_body,json=actionBody,proto3" json:"action_body,omitempty"` - // The installation signature - InstallationSignature []byte `protobuf:"bytes,4,opt,name=installation_signature,json=installationSignature,proto3" json:"installation_signature,omitempty"` - // The public installation id used to sign. - InstallationId []byte `protobuf:"bytes,5,opt,name=installation_id,json=installationId,proto3" json:"installation_id,omitempty"` - // The inbox id of the installation used to sign. - InboxId string `protobuf:"bytes,6,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *FrameAction) Reset() { - *x = FrameAction{} - mi := &file_message_contents_frames_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *FrameAction) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*FrameAction) ProtoMessage() {} - -func (x *FrameAction) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_frames_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use FrameAction.ProtoReflect.Descriptor instead. -func (*FrameAction) Descriptor() ([]byte, []int) { - return file_message_contents_frames_proto_rawDescGZIP(), []int{1} -} - -// Deprecated: Marked as deprecated in message_contents/frames.proto. -func (x *FrameAction) GetSignature() *Signature { - if x != nil { - return x.Signature - } - return nil -} - -// Deprecated: Marked as deprecated in message_contents/frames.proto. -func (x *FrameAction) GetSignedPublicKeyBundle() *SignedPublicKeyBundle { - if x != nil { - return x.SignedPublicKeyBundle - } - return nil -} - -func (x *FrameAction) GetActionBody() []byte { - if x != nil { - return x.ActionBody - } - return nil -} - -func (x *FrameAction) GetInstallationSignature() []byte { - if x != nil { - return x.InstallationSignature - } - return nil -} - -func (x *FrameAction) GetInstallationId() []byte { - if x != nil { - return x.InstallationId - } - return nil -} - -func (x *FrameAction) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -var File_message_contents_frames_proto protoreflect.FileDescriptor - -const file_message_contents_frames_proto_rawDesc = "" + - "\n" + - "\x1dmessage_contents/frames.proto\x12\x15xmtp.message_contents\x1a!message_contents/public_key.proto\x1a message_contents/signature.proto\"\xd6\x02\n" + - "\x0fFrameActionBody\x12\x1b\n" + - "\tframe_url\x18\x01 \x01(\tR\bframeUrl\x12!\n" + - "\fbutton_index\x18\x02 \x01(\x05R\vbuttonIndex\x12 \n" + - "\ttimestamp\x18\x03 \x01(\x04B\x02\x18\x01R\ttimestamp\x12D\n" + - "\x1eopaque_conversation_identifier\x18\x04 \x01(\tR\x1copaqueConversationIdentifier\x12%\n" + - "\x0eunix_timestamp\x18\x05 \x01(\rR\runixTimestamp\x12\x1d\n" + - "\n" + - "input_text\x18\x06 \x01(\tR\tinputText\x12\x14\n" + - "\x05state\x18\a \x01(\tR\x05state\x12\x18\n" + - "\aaddress\x18\b \x01(\tR\aaddress\x12%\n" + - "\x0etransaction_id\x18\t \x01(\tR\rtransactionId\"\xd8\x02\n" + - "\vFrameAction\x12B\n" + - "\tsignature\x18\x01 \x01(\v2 .xmtp.message_contents.SignatureB\x02\x18\x01R\tsignature\x12i\n" + - "\x18signed_public_key_bundle\x18\x02 \x01(\v2,.xmtp.message_contents.SignedPublicKeyBundleB\x02\x18\x01R\x15signedPublicKeyBundle\x12\x1f\n" + - "\vaction_body\x18\x03 \x01(\fR\n" + - "actionBody\x125\n" + - "\x16installation_signature\x18\x04 \x01(\fR\x15installationSignature\x12'\n" + - "\x0finstallation_id\x18\x05 \x01(\fR\x0einstallationId\x12\x19\n" + - "\binbox_id\x18\x06 \x01(\tR\ainboxIdB\xfe\x01\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\vFramesProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_frames_proto_rawDescOnce sync.Once - file_message_contents_frames_proto_rawDescData []byte -) - -func file_message_contents_frames_proto_rawDescGZIP() []byte { - file_message_contents_frames_proto_rawDescOnce.Do(func() { - file_message_contents_frames_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_frames_proto_rawDesc), len(file_message_contents_frames_proto_rawDesc))) - }) - return file_message_contents_frames_proto_rawDescData -} - -var file_message_contents_frames_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_message_contents_frames_proto_goTypes = []any{ - (*FrameActionBody)(nil), // 0: xmtp.message_contents.FrameActionBody - (*FrameAction)(nil), // 1: xmtp.message_contents.FrameAction - (*Signature)(nil), // 2: xmtp.message_contents.Signature - (*SignedPublicKeyBundle)(nil), // 3: xmtp.message_contents.SignedPublicKeyBundle -} -var file_message_contents_frames_proto_depIdxs = []int32{ - 2, // 0: xmtp.message_contents.FrameAction.signature:type_name -> xmtp.message_contents.Signature - 3, // 1: xmtp.message_contents.FrameAction.signed_public_key_bundle:type_name -> xmtp.message_contents.SignedPublicKeyBundle - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_message_contents_frames_proto_init() } -func file_message_contents_frames_proto_init() { - if File_message_contents_frames_proto != nil { - return - } - file_message_contents_public_key_proto_init() - file_message_contents_signature_proto_init() - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_frames_proto_rawDesc), len(file_message_contents_frames_proto_rawDesc)), - NumEnums: 0, - NumMessages: 2, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_frames_proto_goTypes, - DependencyIndexes: file_message_contents_frames_proto_depIdxs, - MessageInfos: file_message_contents_frames_proto_msgTypes, - }.Build() - File_message_contents_frames_proto = out.File - file_message_contents_frames_proto_goTypes = nil - file_message_contents_frames_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/invitation.pb.go b/pkg/proto/message_contents/invitation.pb.go deleted file mode 100644 index f61aa831..00000000 --- a/pkg/proto/message_contents/invitation.pb.go +++ /dev/null @@ -1,647 +0,0 @@ -// Invitation is used by an initiator to invite participants -// into a new conversation. Invitation carries the chosen topic name -// and encryption scheme and key material to be used for message encryption. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/invitation.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Version of consent proof payload -type ConsentProofPayloadVersion int32 - -const ( - ConsentProofPayloadVersion_CONSENT_PROOF_PAYLOAD_VERSION_UNSPECIFIED ConsentProofPayloadVersion = 0 - ConsentProofPayloadVersion_CONSENT_PROOF_PAYLOAD_VERSION_1 ConsentProofPayloadVersion = 1 -) - -// Enum value maps for ConsentProofPayloadVersion. -var ( - ConsentProofPayloadVersion_name = map[int32]string{ - 0: "CONSENT_PROOF_PAYLOAD_VERSION_UNSPECIFIED", - 1: "CONSENT_PROOF_PAYLOAD_VERSION_1", - } - ConsentProofPayloadVersion_value = map[string]int32{ - "CONSENT_PROOF_PAYLOAD_VERSION_UNSPECIFIED": 0, - "CONSENT_PROOF_PAYLOAD_VERSION_1": 1, - } -) - -func (x ConsentProofPayloadVersion) Enum() *ConsentProofPayloadVersion { - p := new(ConsentProofPayloadVersion) - *p = x - return p -} - -func (x ConsentProofPayloadVersion) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ConsentProofPayloadVersion) Descriptor() protoreflect.EnumDescriptor { - return file_message_contents_invitation_proto_enumTypes[0].Descriptor() -} - -func (ConsentProofPayloadVersion) Type() protoreflect.EnumType { - return &file_message_contents_invitation_proto_enumTypes[0] -} - -func (x ConsentProofPayloadVersion) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ConsentProofPayloadVersion.Descriptor instead. -func (ConsentProofPayloadVersion) EnumDescriptor() ([]byte, []int) { - return file_message_contents_invitation_proto_rawDescGZIP(), []int{0} -} - -// Unsealed invitation V1 -type InvitationV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // topic name chosen for this conversation. - // It MUST be randomly generated bytes (length >= 32), - // then base64 encoded without padding - Topic string `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"` - // A context object defining metadata - Context *InvitationV1_Context `protobuf:"bytes,2,opt,name=context,proto3" json:"context,omitempty"` - // message encryption scheme and keys for this conversation. - // - // Types that are valid to be assigned to Encryption: - // - // *InvitationV1_Aes256GcmHkdfSha256 - Encryption isInvitationV1_Encryption `protobuf_oneof:"encryption"` - // The user's consent proof - ConsentProof *ConsentProofPayload `protobuf:"bytes,4,opt,name=consent_proof,json=consentProof,proto3" json:"consent_proof,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *InvitationV1) Reset() { - *x = InvitationV1{} - mi := &file_message_contents_invitation_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *InvitationV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*InvitationV1) ProtoMessage() {} - -func (x *InvitationV1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_invitation_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use InvitationV1.ProtoReflect.Descriptor instead. -func (*InvitationV1) Descriptor() ([]byte, []int) { - return file_message_contents_invitation_proto_rawDescGZIP(), []int{0} -} - -func (x *InvitationV1) GetTopic() string { - if x != nil { - return x.Topic - } - return "" -} - -func (x *InvitationV1) GetContext() *InvitationV1_Context { - if x != nil { - return x.Context - } - return nil -} - -func (x *InvitationV1) GetEncryption() isInvitationV1_Encryption { - if x != nil { - return x.Encryption - } - return nil -} - -func (x *InvitationV1) GetAes256GcmHkdfSha256() *InvitationV1_Aes256GcmHkdfsha256 { - if x != nil { - if x, ok := x.Encryption.(*InvitationV1_Aes256GcmHkdfSha256); ok { - return x.Aes256GcmHkdfSha256 - } - } - return nil -} - -func (x *InvitationV1) GetConsentProof() *ConsentProofPayload { - if x != nil { - return x.ConsentProof - } - return nil -} - -type isInvitationV1_Encryption interface { - isInvitationV1_Encryption() -} - -type InvitationV1_Aes256GcmHkdfSha256 struct { - // Specify the encryption method to process the key material properly. - Aes256GcmHkdfSha256 *InvitationV1_Aes256GcmHkdfsha256 `protobuf:"bytes,3,opt,name=aes256_gcm_hkdf_sha256,json=aes256GcmHkdfSha256,proto3,oneof"` -} - -func (*InvitationV1_Aes256GcmHkdfSha256) isInvitationV1_Encryption() {} - -// Sealed Invitation V1 Header -// Header carries information that is unencrypted, thus readable by the network -// it is however authenticated as associated data with the AEAD scheme used -// to encrypt the invitation body, thus providing tamper evidence. -type SealedInvitationHeaderV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - Sender *SignedPublicKeyBundle `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty"` - Recipient *SignedPublicKeyBundle `protobuf:"bytes,2,opt,name=recipient,proto3" json:"recipient,omitempty"` - CreatedNs uint64 `protobuf:"varint,3,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SealedInvitationHeaderV1) Reset() { - *x = SealedInvitationHeaderV1{} - mi := &file_message_contents_invitation_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SealedInvitationHeaderV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SealedInvitationHeaderV1) ProtoMessage() {} - -func (x *SealedInvitationHeaderV1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_invitation_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SealedInvitationHeaderV1.ProtoReflect.Descriptor instead. -func (*SealedInvitationHeaderV1) Descriptor() ([]byte, []int) { - return file_message_contents_invitation_proto_rawDescGZIP(), []int{1} -} - -func (x *SealedInvitationHeaderV1) GetSender() *SignedPublicKeyBundle { - if x != nil { - return x.Sender - } - return nil -} - -func (x *SealedInvitationHeaderV1) GetRecipient() *SignedPublicKeyBundle { - if x != nil { - return x.Recipient - } - return nil -} - -func (x *SealedInvitationHeaderV1) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -// Sealed Invitation V1 -// Invitation encrypted with key material derived from the sender's and -// recipient's public key bundles using simplified X3DH where -// the sender's ephemeral key is replaced with sender's pre-key. -type SealedInvitationV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // encoded SealedInvitationHeaderV1 used as associated data for Ciphertext - HeaderBytes []byte `protobuf:"bytes,1,opt,name=header_bytes,json=headerBytes,proto3" json:"header_bytes,omitempty"` - // Ciphertext.payload MUST contain encrypted InvitationV1. - Ciphertext *Ciphertext `protobuf:"bytes,2,opt,name=ciphertext,proto3" json:"ciphertext,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SealedInvitationV1) Reset() { - *x = SealedInvitationV1{} - mi := &file_message_contents_invitation_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SealedInvitationV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SealedInvitationV1) ProtoMessage() {} - -func (x *SealedInvitationV1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_invitation_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SealedInvitationV1.ProtoReflect.Descriptor instead. -func (*SealedInvitationV1) Descriptor() ([]byte, []int) { - return file_message_contents_invitation_proto_rawDescGZIP(), []int{2} -} - -func (x *SealedInvitationV1) GetHeaderBytes() []byte { - if x != nil { - return x.HeaderBytes - } - return nil -} - -func (x *SealedInvitationV1) GetCiphertext() *Ciphertext { - if x != nil { - return x.Ciphertext - } - return nil -} - -// Versioned Sealed Invitation -type SealedInvitation struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *SealedInvitation_V1 - Version isSealedInvitation_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SealedInvitation) Reset() { - *x = SealedInvitation{} - mi := &file_message_contents_invitation_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SealedInvitation) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SealedInvitation) ProtoMessage() {} - -func (x *SealedInvitation) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_invitation_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SealedInvitation.ProtoReflect.Descriptor instead. -func (*SealedInvitation) Descriptor() ([]byte, []int) { - return file_message_contents_invitation_proto_rawDescGZIP(), []int{3} -} - -func (x *SealedInvitation) GetVersion() isSealedInvitation_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *SealedInvitation) GetV1() *SealedInvitationV1 { - if x != nil { - if x, ok := x.Version.(*SealedInvitation_V1); ok { - return x.V1 - } - } - return nil -} - -type isSealedInvitation_Version interface { - isSealedInvitation_Version() -} - -type SealedInvitation_V1 struct { - V1 *SealedInvitationV1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*SealedInvitation_V1) isSealedInvitation_Version() {} - -// Payload for user's consent proof to be set in the invitation -// Signifying the conversation should be preapproved for the user on receipt -type ConsentProofPayload struct { - state protoimpl.MessageState `protogen:"open.v1"` - // the user's signature in hex format - Signature string `protobuf:"bytes,1,opt,name=signature,proto3" json:"signature,omitempty"` - // approximate time when the user signed - Timestamp uint64 `protobuf:"varint,2,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - // version of the payload - PayloadVersion ConsentProofPayloadVersion `protobuf:"varint,3,opt,name=payload_version,json=payloadVersion,proto3,enum=xmtp.message_contents.ConsentProofPayloadVersion" json:"payload_version,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ConsentProofPayload) Reset() { - *x = ConsentProofPayload{} - mi := &file_message_contents_invitation_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ConsentProofPayload) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ConsentProofPayload) ProtoMessage() {} - -func (x *ConsentProofPayload) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_invitation_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ConsentProofPayload.ProtoReflect.Descriptor instead. -func (*ConsentProofPayload) Descriptor() ([]byte, []int) { - return file_message_contents_invitation_proto_rawDescGZIP(), []int{4} -} - -func (x *ConsentProofPayload) GetSignature() string { - if x != nil { - return x.Signature - } - return "" -} - -func (x *ConsentProofPayload) GetTimestamp() uint64 { - if x != nil { - return x.Timestamp - } - return 0 -} - -func (x *ConsentProofPayload) GetPayloadVersion() ConsentProofPayloadVersion { - if x != nil { - return x.PayloadVersion - } - return ConsentProofPayloadVersion_CONSENT_PROOF_PAYLOAD_VERSION_UNSPECIFIED -} - -// Supported encryption schemes -// AES256-GCM-HKDF-SHA256 -type InvitationV1_Aes256GcmHkdfsha256 struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyMaterial []byte `protobuf:"bytes,1,opt,name=key_material,json=keyMaterial,proto3" json:"key_material,omitempty"` // randomly generated key material (32 bytes) - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *InvitationV1_Aes256GcmHkdfsha256) Reset() { - *x = InvitationV1_Aes256GcmHkdfsha256{} - mi := &file_message_contents_invitation_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *InvitationV1_Aes256GcmHkdfsha256) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*InvitationV1_Aes256GcmHkdfsha256) ProtoMessage() {} - -func (x *InvitationV1_Aes256GcmHkdfsha256) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_invitation_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use InvitationV1_Aes256GcmHkdfsha256.ProtoReflect.Descriptor instead. -func (*InvitationV1_Aes256GcmHkdfsha256) Descriptor() ([]byte, []int) { - return file_message_contents_invitation_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *InvitationV1_Aes256GcmHkdfsha256) GetKeyMaterial() []byte { - if x != nil { - return x.KeyMaterial - } - return nil -} - -// The context type -type InvitationV1_Context struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Expected to be a URI (ie xmtp.org/convo1) - ConversationId string `protobuf:"bytes,1,opt,name=conversation_id,json=conversationId,proto3" json:"conversation_id,omitempty"` - // Key value map of additional metadata that would be exposed to - // application developers and could be used for filtering - Metadata map[string]string `protobuf:"bytes,2,rep,name=metadata,proto3" json:"metadata,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *InvitationV1_Context) Reset() { - *x = InvitationV1_Context{} - mi := &file_message_contents_invitation_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *InvitationV1_Context) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*InvitationV1_Context) ProtoMessage() {} - -func (x *InvitationV1_Context) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_invitation_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use InvitationV1_Context.ProtoReflect.Descriptor instead. -func (*InvitationV1_Context) Descriptor() ([]byte, []int) { - return file_message_contents_invitation_proto_rawDescGZIP(), []int{0, 1} -} - -func (x *InvitationV1_Context) GetConversationId() string { - if x != nil { - return x.ConversationId - } - return "" -} - -func (x *InvitationV1_Context) GetMetadata() map[string]string { - if x != nil { - return x.Metadata - } - return nil -} - -var File_message_contents_invitation_proto protoreflect.FileDescriptor - -const file_message_contents_invitation_proto_rawDesc = "" + - "\n" + - "!message_contents/invitation.proto\x12\x15xmtp.message_contents\x1a!message_contents/ciphertext.proto\x1a!message_contents/public_key.proto\"\xbd\x04\n" + - "\fInvitationV1\x12\x14\n" + - "\x05topic\x18\x01 \x01(\tR\x05topic\x12E\n" + - "\acontext\x18\x02 \x01(\v2+.xmtp.message_contents.InvitationV1.ContextR\acontext\x12n\n" + - "\x16aes256_gcm_hkdf_sha256\x18\x03 \x01(\v27.xmtp.message_contents.InvitationV1.Aes256gcmHkdfsha256H\x00R\x13aes256GcmHkdfSha256\x12O\n" + - "\rconsent_proof\x18\x04 \x01(\v2*.xmtp.message_contents.ConsentProofPayloadR\fconsentProof\x1a8\n" + - "\x13Aes256gcmHkdfsha256\x12!\n" + - "\fkey_material\x18\x01 \x01(\fR\vkeyMaterial\x1a\xc6\x01\n" + - "\aContext\x12'\n" + - "\x0fconversation_id\x18\x01 \x01(\tR\x0econversationId\x12U\n" + - "\bmetadata\x18\x02 \x03(\v29.xmtp.message_contents.InvitationV1.Context.MetadataEntryR\bmetadata\x1a;\n" + - "\rMetadataEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01B\f\n" + - "\n" + - "encryption\"\xcb\x01\n" + - "\x18SealedInvitationHeaderV1\x12D\n" + - "\x06sender\x18\x01 \x01(\v2,.xmtp.message_contents.SignedPublicKeyBundleR\x06sender\x12J\n" + - "\trecipient\x18\x02 \x01(\v2,.xmtp.message_contents.SignedPublicKeyBundleR\trecipient\x12\x1d\n" + - "\n" + - "created_ns\x18\x03 \x01(\x04R\tcreatedNs\"z\n" + - "\x12SealedInvitationV1\x12!\n" + - "\fheader_bytes\x18\x01 \x01(\fR\vheaderBytes\x12A\n" + - "\n" + - "ciphertext\x18\x02 \x01(\v2!.xmtp.message_contents.CiphertextR\n" + - "ciphertext\"`\n" + - "\x10SealedInvitation\x12;\n" + - "\x02v1\x18\x01 \x01(\v2).xmtp.message_contents.SealedInvitationV1H\x00R\x02v1B\t\n" + - "\aversionJ\x04\b\x02\x10\x03\"\xad\x01\n" + - "\x13ConsentProofPayload\x12\x1c\n" + - "\tsignature\x18\x01 \x01(\tR\tsignature\x12\x1c\n" + - "\ttimestamp\x18\x02 \x01(\x04R\ttimestamp\x12Z\n" + - "\x0fpayload_version\x18\x03 \x01(\x0e21.xmtp.message_contents.ConsentProofPayloadVersionR\x0epayloadVersion*p\n" + - "\x1aConsentProofPayloadVersion\x12-\n" + - ")CONSENT_PROOF_PAYLOAD_VERSION_UNSPECIFIED\x10\x00\x12#\n" + - "\x1fCONSENT_PROOF_PAYLOAD_VERSION_1\x10\x01B\x82\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x0fInvitationProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_invitation_proto_rawDescOnce sync.Once - file_message_contents_invitation_proto_rawDescData []byte -) - -func file_message_contents_invitation_proto_rawDescGZIP() []byte { - file_message_contents_invitation_proto_rawDescOnce.Do(func() { - file_message_contents_invitation_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_invitation_proto_rawDesc), len(file_message_contents_invitation_proto_rawDesc))) - }) - return file_message_contents_invitation_proto_rawDescData -} - -var file_message_contents_invitation_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_message_contents_invitation_proto_msgTypes = make([]protoimpl.MessageInfo, 8) -var file_message_contents_invitation_proto_goTypes = []any{ - (ConsentProofPayloadVersion)(0), // 0: xmtp.message_contents.ConsentProofPayloadVersion - (*InvitationV1)(nil), // 1: xmtp.message_contents.InvitationV1 - (*SealedInvitationHeaderV1)(nil), // 2: xmtp.message_contents.SealedInvitationHeaderV1 - (*SealedInvitationV1)(nil), // 3: xmtp.message_contents.SealedInvitationV1 - (*SealedInvitation)(nil), // 4: xmtp.message_contents.SealedInvitation - (*ConsentProofPayload)(nil), // 5: xmtp.message_contents.ConsentProofPayload - (*InvitationV1_Aes256GcmHkdfsha256)(nil), // 6: xmtp.message_contents.InvitationV1.Aes256gcmHkdfsha256 - (*InvitationV1_Context)(nil), // 7: xmtp.message_contents.InvitationV1.Context - nil, // 8: xmtp.message_contents.InvitationV1.Context.MetadataEntry - (*SignedPublicKeyBundle)(nil), // 9: xmtp.message_contents.SignedPublicKeyBundle - (*Ciphertext)(nil), // 10: xmtp.message_contents.Ciphertext -} -var file_message_contents_invitation_proto_depIdxs = []int32{ - 7, // 0: xmtp.message_contents.InvitationV1.context:type_name -> xmtp.message_contents.InvitationV1.Context - 6, // 1: xmtp.message_contents.InvitationV1.aes256_gcm_hkdf_sha256:type_name -> xmtp.message_contents.InvitationV1.Aes256gcmHkdfsha256 - 5, // 2: xmtp.message_contents.InvitationV1.consent_proof:type_name -> xmtp.message_contents.ConsentProofPayload - 9, // 3: xmtp.message_contents.SealedInvitationHeaderV1.sender:type_name -> xmtp.message_contents.SignedPublicKeyBundle - 9, // 4: xmtp.message_contents.SealedInvitationHeaderV1.recipient:type_name -> xmtp.message_contents.SignedPublicKeyBundle - 10, // 5: xmtp.message_contents.SealedInvitationV1.ciphertext:type_name -> xmtp.message_contents.Ciphertext - 3, // 6: xmtp.message_contents.SealedInvitation.v1:type_name -> xmtp.message_contents.SealedInvitationV1 - 0, // 7: xmtp.message_contents.ConsentProofPayload.payload_version:type_name -> xmtp.message_contents.ConsentProofPayloadVersion - 8, // 8: xmtp.message_contents.InvitationV1.Context.metadata:type_name -> xmtp.message_contents.InvitationV1.Context.MetadataEntry - 9, // [9:9] is the sub-list for method output_type - 9, // [9:9] is the sub-list for method input_type - 9, // [9:9] is the sub-list for extension type_name - 9, // [9:9] is the sub-list for extension extendee - 0, // [0:9] is the sub-list for field type_name -} - -func init() { file_message_contents_invitation_proto_init() } -func file_message_contents_invitation_proto_init() { - if File_message_contents_invitation_proto != nil { - return - } - file_message_contents_ciphertext_proto_init() - file_message_contents_public_key_proto_init() - file_message_contents_invitation_proto_msgTypes[0].OneofWrappers = []any{ - (*InvitationV1_Aes256GcmHkdfSha256)(nil), - } - file_message_contents_invitation_proto_msgTypes[3].OneofWrappers = []any{ - (*SealedInvitation_V1)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_invitation_proto_rawDesc), len(file_message_contents_invitation_proto_rawDesc)), - NumEnums: 1, - NumMessages: 8, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_invitation_proto_goTypes, - DependencyIndexes: file_message_contents_invitation_proto_depIdxs, - EnumInfos: file_message_contents_invitation_proto_enumTypes, - MessageInfos: file_message_contents_invitation_proto_msgTypes, - }.Build() - File_message_contents_invitation_proto = out.File - file_message_contents_invitation_proto_goTypes = nil - file_message_contents_invitation_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/message.pb.go b/pkg/proto/message_contents/message.pb.go deleted file mode 100644 index c6e8ab55..00000000 --- a/pkg/proto/message_contents/message.pb.go +++ /dev/null @@ -1,577 +0,0 @@ -// Messages used for transport and storage of user conversations. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/message.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Message header is encoded separately as the bytes are also used -// as associated data for authenticated encryption -type MessageHeaderV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - Sender *PublicKeyBundle `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty"` - Recipient *PublicKeyBundle `protobuf:"bytes,2,opt,name=recipient,proto3" json:"recipient,omitempty"` - Timestamp uint64 `protobuf:"varint,3,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MessageHeaderV1) Reset() { - *x = MessageHeaderV1{} - mi := &file_message_contents_message_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MessageHeaderV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MessageHeaderV1) ProtoMessage() {} - -func (x *MessageHeaderV1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_message_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MessageHeaderV1.ProtoReflect.Descriptor instead. -func (*MessageHeaderV1) Descriptor() ([]byte, []int) { - return file_message_contents_message_proto_rawDescGZIP(), []int{0} -} - -func (x *MessageHeaderV1) GetSender() *PublicKeyBundle { - if x != nil { - return x.Sender - } - return nil -} - -func (x *MessageHeaderV1) GetRecipient() *PublicKeyBundle { - if x != nil { - return x.Recipient - } - return nil -} - -func (x *MessageHeaderV1) GetTimestamp() uint64 { - if x != nil { - return x.Timestamp - } - return 0 -} - -// Message is the top level protocol element -type MessageV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // encapsulates encoded MessageHeaderV1 - HeaderBytes []byte `protobuf:"bytes,1,opt,name=header_bytes,json=headerBytes,proto3" json:"header_bytes,omitempty"` - // Ciphertext.payload MUST contain encrypted EncodedContent - Ciphertext *Ciphertext `protobuf:"bytes,2,opt,name=ciphertext,proto3" json:"ciphertext,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MessageV1) Reset() { - *x = MessageV1{} - mi := &file_message_contents_message_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MessageV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MessageV1) ProtoMessage() {} - -func (x *MessageV1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_message_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MessageV1.ProtoReflect.Descriptor instead. -func (*MessageV1) Descriptor() ([]byte, []int) { - return file_message_contents_message_proto_rawDescGZIP(), []int{1} -} - -func (x *MessageV1) GetHeaderBytes() []byte { - if x != nil { - return x.HeaderBytes - } - return nil -} - -func (x *MessageV1) GetCiphertext() *Ciphertext { - if x != nil { - return x.Ciphertext - } - return nil -} - -// Message header carries information that is not encrypted, and is therefore -// observable by the network. It is however authenticated as associated data -// of the AEAD encryption used to protect the message, -// thus providing tamper evidence. -type MessageHeaderV2 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // sender specified message creation time - CreatedNs uint64 `protobuf:"varint,1,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - // the topic the message belongs to - Topic string `protobuf:"bytes,2,opt,name=topic,proto3" json:"topic,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MessageHeaderV2) Reset() { - *x = MessageHeaderV2{} - mi := &file_message_contents_message_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MessageHeaderV2) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MessageHeaderV2) ProtoMessage() {} - -func (x *MessageHeaderV2) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_message_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MessageHeaderV2.ProtoReflect.Descriptor instead. -func (*MessageHeaderV2) Descriptor() ([]byte, []int) { - return file_message_contents_message_proto_rawDescGZIP(), []int{2} -} - -func (x *MessageHeaderV2) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *MessageHeaderV2) GetTopic() string { - if x != nil { - return x.Topic - } - return "" -} - -// Message combines the encoded header with the encrypted payload. -type MessageV2 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // encapsulates encoded MessageHeaderV2 - HeaderBytes []byte `protobuf:"bytes,1,opt,name=header_bytes,json=headerBytes,proto3" json:"header_bytes,omitempty"` - // Ciphertext.payload MUST contain encrypted SignedContent - Ciphertext *Ciphertext `protobuf:"bytes,2,opt,name=ciphertext,proto3" json:"ciphertext,omitempty"` - // HMAC of the message ciphertext, with the HMAC key derived from the topic - // key - SenderHmac []byte `protobuf:"bytes,3,opt,name=sender_hmac,json=senderHmac,proto3,oneof" json:"sender_hmac,omitempty"` - // Flag indicating whether the message should be pushed from a notification - // server - ShouldPush *bool `protobuf:"varint,4,opt,name=should_push,json=shouldPush,proto3,oneof" json:"should_push,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MessageV2) Reset() { - *x = MessageV2{} - mi := &file_message_contents_message_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MessageV2) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MessageV2) ProtoMessage() {} - -func (x *MessageV2) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_message_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MessageV2.ProtoReflect.Descriptor instead. -func (*MessageV2) Descriptor() ([]byte, []int) { - return file_message_contents_message_proto_rawDescGZIP(), []int{3} -} - -func (x *MessageV2) GetHeaderBytes() []byte { - if x != nil { - return x.HeaderBytes - } - return nil -} - -func (x *MessageV2) GetCiphertext() *Ciphertext { - if x != nil { - return x.Ciphertext - } - return nil -} - -func (x *MessageV2) GetSenderHmac() []byte { - if x != nil { - return x.SenderHmac - } - return nil -} - -func (x *MessageV2) GetShouldPush() bool { - if x != nil && x.ShouldPush != nil { - return *x.ShouldPush - } - return false -} - -// Versioned Message -type Message struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *Message_V1 - // *Message_V2 - Version isMessage_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Message) Reset() { - *x = Message{} - mi := &file_message_contents_message_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Message) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Message) ProtoMessage() {} - -func (x *Message) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_message_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Message.ProtoReflect.Descriptor instead. -func (*Message) Descriptor() ([]byte, []int) { - return file_message_contents_message_proto_rawDescGZIP(), []int{4} -} - -func (x *Message) GetVersion() isMessage_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *Message) GetV1() *MessageV1 { - if x != nil { - if x, ok := x.Version.(*Message_V1); ok { - return x.V1 - } - } - return nil -} - -func (x *Message) GetV2() *MessageV2 { - if x != nil { - if x, ok := x.Version.(*Message_V2); ok { - return x.V2 - } - } - return nil -} - -type isMessage_Version interface { - isMessage_Version() -} - -type Message_V1 struct { - V1 *MessageV1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -type Message_V2 struct { - V2 *MessageV2 `protobuf:"bytes,2,opt,name=v2,proto3,oneof"` -} - -func (*Message_V1) isMessage_Version() {} - -func (*Message_V2) isMessage_Version() {} - -// DecodedMessage represents the decrypted message contents. -// DecodedMessage instances are not stored on the network, but -// may be serialized and stored by clients -type DecodedMessage struct { - state protoimpl.MessageState `protogen:"open.v1"` - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` - MessageVersion string `protobuf:"bytes,2,opt,name=message_version,json=messageVersion,proto3" json:"message_version,omitempty"` - SenderAddress string `protobuf:"bytes,3,opt,name=sender_address,json=senderAddress,proto3" json:"sender_address,omitempty"` - RecipientAddress *string `protobuf:"bytes,4,opt,name=recipient_address,json=recipientAddress,proto3,oneof" json:"recipient_address,omitempty"` - SentNs uint64 `protobuf:"varint,5,opt,name=sent_ns,json=sentNs,proto3" json:"sent_ns,omitempty"` - ContentTopic string `protobuf:"bytes,6,opt,name=content_topic,json=contentTopic,proto3" json:"content_topic,omitempty"` - Conversation *ConversationReference `protobuf:"bytes,7,opt,name=conversation,proto3" json:"conversation,omitempty"` - ContentBytes []byte `protobuf:"bytes,8,opt,name=content_bytes,json=contentBytes,proto3" json:"content_bytes,omitempty"` // encapsulates EncodedContent - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DecodedMessage) Reset() { - *x = DecodedMessage{} - mi := &file_message_contents_message_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DecodedMessage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DecodedMessage) ProtoMessage() {} - -func (x *DecodedMessage) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_message_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DecodedMessage.ProtoReflect.Descriptor instead. -func (*DecodedMessage) Descriptor() ([]byte, []int) { - return file_message_contents_message_proto_rawDescGZIP(), []int{5} -} - -func (x *DecodedMessage) GetId() string { - if x != nil { - return x.Id - } - return "" -} - -func (x *DecodedMessage) GetMessageVersion() string { - if x != nil { - return x.MessageVersion - } - return "" -} - -func (x *DecodedMessage) GetSenderAddress() string { - if x != nil { - return x.SenderAddress - } - return "" -} - -func (x *DecodedMessage) GetRecipientAddress() string { - if x != nil && x.RecipientAddress != nil { - return *x.RecipientAddress - } - return "" -} - -func (x *DecodedMessage) GetSentNs() uint64 { - if x != nil { - return x.SentNs - } - return 0 -} - -func (x *DecodedMessage) GetContentTopic() string { - if x != nil { - return x.ContentTopic - } - return "" -} - -func (x *DecodedMessage) GetConversation() *ConversationReference { - if x != nil { - return x.Conversation - } - return nil -} - -func (x *DecodedMessage) GetContentBytes() []byte { - if x != nil { - return x.ContentBytes - } - return nil -} - -var File_message_contents_message_proto protoreflect.FileDescriptor - -const file_message_contents_message_proto_rawDesc = "" + - "\n" + - "\x1emessage_contents/message.proto\x12\x15xmtp.message_contents\x1a!message_contents/ciphertext.proto\x1a-message_contents/conversation_reference.proto\x1a!message_contents/public_key.proto\"\xb5\x01\n" + - "\x0fMessageHeaderV1\x12>\n" + - "\x06sender\x18\x01 \x01(\v2&.xmtp.message_contents.PublicKeyBundleR\x06sender\x12D\n" + - "\trecipient\x18\x02 \x01(\v2&.xmtp.message_contents.PublicKeyBundleR\trecipient\x12\x1c\n" + - "\ttimestamp\x18\x03 \x01(\x04R\ttimestamp\"q\n" + - "\tMessageV1\x12!\n" + - "\fheader_bytes\x18\x01 \x01(\fR\vheaderBytes\x12A\n" + - "\n" + - "ciphertext\x18\x02 \x01(\v2!.xmtp.message_contents.CiphertextR\n" + - "ciphertext\"F\n" + - "\x0fMessageHeaderV2\x12\x1d\n" + - "\n" + - "created_ns\x18\x01 \x01(\x04R\tcreatedNs\x12\x14\n" + - "\x05topic\x18\x02 \x01(\tR\x05topic\"\xdd\x01\n" + - "\tMessageV2\x12!\n" + - "\fheader_bytes\x18\x01 \x01(\fR\vheaderBytes\x12A\n" + - "\n" + - "ciphertext\x18\x02 \x01(\v2!.xmtp.message_contents.CiphertextR\n" + - "ciphertext\x12$\n" + - "\vsender_hmac\x18\x03 \x01(\fH\x00R\n" + - "senderHmac\x88\x01\x01\x12$\n" + - "\vshould_push\x18\x04 \x01(\bH\x01R\n" + - "shouldPush\x88\x01\x01B\x0e\n" + - "\f_sender_hmacB\x0e\n" + - "\f_should_push\"|\n" + - "\aMessage\x122\n" + - "\x02v1\x18\x01 \x01(\v2 .xmtp.message_contents.MessageV1H\x00R\x02v1\x122\n" + - "\x02v2\x18\x02 \x01(\v2 .xmtp.message_contents.MessageV2H\x00R\x02v2B\t\n" + - "\aversion\"\xed\x02\n" + - "\x0eDecodedMessage\x12\x0e\n" + - "\x02id\x18\x01 \x01(\tR\x02id\x12'\n" + - "\x0fmessage_version\x18\x02 \x01(\tR\x0emessageVersion\x12%\n" + - "\x0esender_address\x18\x03 \x01(\tR\rsenderAddress\x120\n" + - "\x11recipient_address\x18\x04 \x01(\tH\x00R\x10recipientAddress\x88\x01\x01\x12\x17\n" + - "\asent_ns\x18\x05 \x01(\x04R\x06sentNs\x12#\n" + - "\rcontent_topic\x18\x06 \x01(\tR\fcontentTopic\x12P\n" + - "\fconversation\x18\a \x01(\v2,.xmtp.message_contents.ConversationReferenceR\fconversation\x12#\n" + - "\rcontent_bytes\x18\b \x01(\fR\fcontentBytesB\x14\n" + - "\x12_recipient_addressB\xff\x01\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\fMessageProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_message_proto_rawDescOnce sync.Once - file_message_contents_message_proto_rawDescData []byte -) - -func file_message_contents_message_proto_rawDescGZIP() []byte { - file_message_contents_message_proto_rawDescOnce.Do(func() { - file_message_contents_message_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_message_proto_rawDesc), len(file_message_contents_message_proto_rawDesc))) - }) - return file_message_contents_message_proto_rawDescData -} - -var file_message_contents_message_proto_msgTypes = make([]protoimpl.MessageInfo, 6) -var file_message_contents_message_proto_goTypes = []any{ - (*MessageHeaderV1)(nil), // 0: xmtp.message_contents.MessageHeaderV1 - (*MessageV1)(nil), // 1: xmtp.message_contents.MessageV1 - (*MessageHeaderV2)(nil), // 2: xmtp.message_contents.MessageHeaderV2 - (*MessageV2)(nil), // 3: xmtp.message_contents.MessageV2 - (*Message)(nil), // 4: xmtp.message_contents.Message - (*DecodedMessage)(nil), // 5: xmtp.message_contents.DecodedMessage - (*PublicKeyBundle)(nil), // 6: xmtp.message_contents.PublicKeyBundle - (*Ciphertext)(nil), // 7: xmtp.message_contents.Ciphertext - (*ConversationReference)(nil), // 8: xmtp.message_contents.ConversationReference -} -var file_message_contents_message_proto_depIdxs = []int32{ - 6, // 0: xmtp.message_contents.MessageHeaderV1.sender:type_name -> xmtp.message_contents.PublicKeyBundle - 6, // 1: xmtp.message_contents.MessageHeaderV1.recipient:type_name -> xmtp.message_contents.PublicKeyBundle - 7, // 2: xmtp.message_contents.MessageV1.ciphertext:type_name -> xmtp.message_contents.Ciphertext - 7, // 3: xmtp.message_contents.MessageV2.ciphertext:type_name -> xmtp.message_contents.Ciphertext - 1, // 4: xmtp.message_contents.Message.v1:type_name -> xmtp.message_contents.MessageV1 - 3, // 5: xmtp.message_contents.Message.v2:type_name -> xmtp.message_contents.MessageV2 - 8, // 6: xmtp.message_contents.DecodedMessage.conversation:type_name -> xmtp.message_contents.ConversationReference - 7, // [7:7] is the sub-list for method output_type - 7, // [7:7] is the sub-list for method input_type - 7, // [7:7] is the sub-list for extension type_name - 7, // [7:7] is the sub-list for extension extendee - 0, // [0:7] is the sub-list for field type_name -} - -func init() { file_message_contents_message_proto_init() } -func file_message_contents_message_proto_init() { - if File_message_contents_message_proto != nil { - return - } - file_message_contents_ciphertext_proto_init() - file_message_contents_conversation_reference_proto_init() - file_message_contents_public_key_proto_init() - file_message_contents_message_proto_msgTypes[3].OneofWrappers = []any{} - file_message_contents_message_proto_msgTypes[4].OneofWrappers = []any{ - (*Message_V1)(nil), - (*Message_V2)(nil), - } - file_message_contents_message_proto_msgTypes[5].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_message_proto_rawDesc), len(file_message_contents_message_proto_rawDesc)), - NumEnums: 0, - NumMessages: 6, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_message_proto_goTypes, - DependencyIndexes: file_message_contents_message_proto_depIdxs, - MessageInfos: file_message_contents_message_proto_msgTypes, - }.Build() - File_message_contents_message_proto = out.File - file_message_contents_message_proto_goTypes = nil - file_message_contents_message_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/private_key.pb.go b/pkg/proto/message_contents/private_key.pb.go deleted file mode 100644 index bfaeab99..00000000 --- a/pkg/proto/message_contents/private_key.pb.go +++ /dev/null @@ -1,738 +0,0 @@ -// Private Key Storage -// -// Following definitions are not used in the protocol, instead -// they provide a way for encoding private keys for storage. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/private_key.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// PrivateKey generalized to support different key types -type SignedPrivateKey struct { - state protoimpl.MessageState `protogen:"open.v1"` - // time the key was created - CreatedNs uint64 `protobuf:"varint,1,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - // private key - // - // Types that are valid to be assigned to Union: - // - // *SignedPrivateKey_Secp256K1_ - Union isSignedPrivateKey_Union `protobuf_oneof:"union"` - // public key for this private key - PublicKey *SignedPublicKey `protobuf:"bytes,3,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignedPrivateKey) Reset() { - *x = SignedPrivateKey{} - mi := &file_message_contents_private_key_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignedPrivateKey) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignedPrivateKey) ProtoMessage() {} - -func (x *SignedPrivateKey) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignedPrivateKey.ProtoReflect.Descriptor instead. -func (*SignedPrivateKey) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{0} -} - -func (x *SignedPrivateKey) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *SignedPrivateKey) GetUnion() isSignedPrivateKey_Union { - if x != nil { - return x.Union - } - return nil -} - -func (x *SignedPrivateKey) GetSecp256K1() *SignedPrivateKey_Secp256K1 { - if x != nil { - if x, ok := x.Union.(*SignedPrivateKey_Secp256K1_); ok { - return x.Secp256K1 - } - } - return nil -} - -func (x *SignedPrivateKey) GetPublicKey() *SignedPublicKey { - if x != nil { - return x.PublicKey - } - return nil -} - -type isSignedPrivateKey_Union interface { - isSignedPrivateKey_Union() -} - -type SignedPrivateKey_Secp256K1_ struct { - Secp256K1 *SignedPrivateKey_Secp256K1 `protobuf:"bytes,2,opt,name=secp256k1,proto3,oneof"` -} - -func (*SignedPrivateKey_Secp256K1_) isSignedPrivateKey_Union() {} - -// PrivateKeyBundle wraps the identityKey and the preKeys, -// enforces usage of signed keys. -type PrivateKeyBundleV2 struct { - state protoimpl.MessageState `protogen:"open.v1"` - IdentityKey *SignedPrivateKey `protobuf:"bytes,1,opt,name=identity_key,json=identityKey,proto3" json:"identity_key,omitempty"` - // all the known pre-keys, newer keys first, - PreKeys []*SignedPrivateKey `protobuf:"bytes,2,rep,name=pre_keys,json=preKeys,proto3" json:"pre_keys,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivateKeyBundleV2) Reset() { - *x = PrivateKeyBundleV2{} - mi := &file_message_contents_private_key_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivateKeyBundleV2) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivateKeyBundleV2) ProtoMessage() {} - -func (x *PrivateKeyBundleV2) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivateKeyBundleV2.ProtoReflect.Descriptor instead. -func (*PrivateKeyBundleV2) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{1} -} - -func (x *PrivateKeyBundleV2) GetIdentityKey() *SignedPrivateKey { - if x != nil { - return x.IdentityKey - } - return nil -} - -func (x *PrivateKeyBundleV2) GetPreKeys() []*SignedPrivateKey { - if x != nil { - return x.PreKeys - } - return nil -} - -// LEGACY: PrivateKey generalized to support different key types -type PrivateKey struct { - state protoimpl.MessageState `protogen:"open.v1"` - // time the key was created - Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - // private key - // - // Types that are valid to be assigned to Union: - // - // *PrivateKey_Secp256K1_ - Union isPrivateKey_Union `protobuf_oneof:"union"` - // public key for this private key - PublicKey *PublicKey `protobuf:"bytes,3,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivateKey) Reset() { - *x = PrivateKey{} - mi := &file_message_contents_private_key_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivateKey) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivateKey) ProtoMessage() {} - -func (x *PrivateKey) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivateKey.ProtoReflect.Descriptor instead. -func (*PrivateKey) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{2} -} - -func (x *PrivateKey) GetTimestamp() uint64 { - if x != nil { - return x.Timestamp - } - return 0 -} - -func (x *PrivateKey) GetUnion() isPrivateKey_Union { - if x != nil { - return x.Union - } - return nil -} - -func (x *PrivateKey) GetSecp256K1() *PrivateKey_Secp256K1 { - if x != nil { - if x, ok := x.Union.(*PrivateKey_Secp256K1_); ok { - return x.Secp256K1 - } - } - return nil -} - -func (x *PrivateKey) GetPublicKey() *PublicKey { - if x != nil { - return x.PublicKey - } - return nil -} - -type isPrivateKey_Union interface { - isPrivateKey_Union() -} - -type PrivateKey_Secp256K1_ struct { - Secp256K1 *PrivateKey_Secp256K1 `protobuf:"bytes,2,opt,name=secp256k1,proto3,oneof"` -} - -func (*PrivateKey_Secp256K1_) isPrivateKey_Union() {} - -// LEGACY: PrivateKeyBundleV1 wraps the identityKey and the preKeys -type PrivateKeyBundleV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - IdentityKey *PrivateKey `protobuf:"bytes,1,opt,name=identity_key,json=identityKey,proto3" json:"identity_key,omitempty"` - // all the known pre-keys, newer keys first, - PreKeys []*PrivateKey `protobuf:"bytes,2,rep,name=pre_keys,json=preKeys,proto3" json:"pre_keys,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivateKeyBundleV1) Reset() { - *x = PrivateKeyBundleV1{} - mi := &file_message_contents_private_key_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivateKeyBundleV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivateKeyBundleV1) ProtoMessage() {} - -func (x *PrivateKeyBundleV1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivateKeyBundleV1.ProtoReflect.Descriptor instead. -func (*PrivateKeyBundleV1) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{3} -} - -func (x *PrivateKeyBundleV1) GetIdentityKey() *PrivateKey { - if x != nil { - return x.IdentityKey - } - return nil -} - -func (x *PrivateKeyBundleV1) GetPreKeys() []*PrivateKey { - if x != nil { - return x.PreKeys - } - return nil -} - -// Versioned PrivateKeyBundle -type PrivateKeyBundle struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *PrivateKeyBundle_V1 - // *PrivateKeyBundle_V2 - Version isPrivateKeyBundle_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivateKeyBundle) Reset() { - *x = PrivateKeyBundle{} - mi := &file_message_contents_private_key_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivateKeyBundle) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivateKeyBundle) ProtoMessage() {} - -func (x *PrivateKeyBundle) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivateKeyBundle.ProtoReflect.Descriptor instead. -func (*PrivateKeyBundle) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{4} -} - -func (x *PrivateKeyBundle) GetVersion() isPrivateKeyBundle_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *PrivateKeyBundle) GetV1() *PrivateKeyBundleV1 { - if x != nil { - if x, ok := x.Version.(*PrivateKeyBundle_V1); ok { - return x.V1 - } - } - return nil -} - -func (x *PrivateKeyBundle) GetV2() *PrivateKeyBundleV2 { - if x != nil { - if x, ok := x.Version.(*PrivateKeyBundle_V2); ok { - return x.V2 - } - } - return nil -} - -type isPrivateKeyBundle_Version interface { - isPrivateKeyBundle_Version() -} - -type PrivateKeyBundle_V1 struct { - V1 *PrivateKeyBundleV1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -type PrivateKeyBundle_V2 struct { - V2 *PrivateKeyBundleV2 `protobuf:"bytes,2,opt,name=v2,proto3,oneof"` -} - -func (*PrivateKeyBundle_V1) isPrivateKeyBundle_Version() {} - -func (*PrivateKeyBundle_V2) isPrivateKeyBundle_Version() {} - -// PrivateKeyBundle encrypted with key material generated by -// signing a randomly generated "pre-key" with the user's wallet, -// i.e. EIP-191 signature of a "storage signature" message with -// the pre-key embedded in it. -// (see xmtp-js::PrivateKeyBundle.toEncryptedBytes for details) -type EncryptedPrivateKeyBundleV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // randomly generated pre-key - WalletPreKey []byte `protobuf:"bytes,1,opt,name=wallet_pre_key,json=walletPreKey,proto3" json:"wallet_pre_key,omitempty"` // 32 bytes - // MUST contain encrypted PrivateKeyBundle - Ciphertext *Ciphertext `protobuf:"bytes,2,opt,name=ciphertext,proto3" json:"ciphertext,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptedPrivateKeyBundleV1) Reset() { - *x = EncryptedPrivateKeyBundleV1{} - mi := &file_message_contents_private_key_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptedPrivateKeyBundleV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptedPrivateKeyBundleV1) ProtoMessage() {} - -func (x *EncryptedPrivateKeyBundleV1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptedPrivateKeyBundleV1.ProtoReflect.Descriptor instead. -func (*EncryptedPrivateKeyBundleV1) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{5} -} - -func (x *EncryptedPrivateKeyBundleV1) GetWalletPreKey() []byte { - if x != nil { - return x.WalletPreKey - } - return nil -} - -func (x *EncryptedPrivateKeyBundleV1) GetCiphertext() *Ciphertext { - if x != nil { - return x.Ciphertext - } - return nil -} - -// Versioned encrypted PrivateKeyBundle -type EncryptedPrivateKeyBundle struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *EncryptedPrivateKeyBundle_V1 - Version isEncryptedPrivateKeyBundle_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncryptedPrivateKeyBundle) Reset() { - *x = EncryptedPrivateKeyBundle{} - mi := &file_message_contents_private_key_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncryptedPrivateKeyBundle) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncryptedPrivateKeyBundle) ProtoMessage() {} - -func (x *EncryptedPrivateKeyBundle) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncryptedPrivateKeyBundle.ProtoReflect.Descriptor instead. -func (*EncryptedPrivateKeyBundle) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{6} -} - -func (x *EncryptedPrivateKeyBundle) GetVersion() isEncryptedPrivateKeyBundle_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *EncryptedPrivateKeyBundle) GetV1() *EncryptedPrivateKeyBundleV1 { - if x != nil { - if x, ok := x.Version.(*EncryptedPrivateKeyBundle_V1); ok { - return x.V1 - } - } - return nil -} - -type isEncryptedPrivateKeyBundle_Version interface { - isEncryptedPrivateKeyBundle_Version() -} - -type EncryptedPrivateKeyBundle_V1 struct { - V1 *EncryptedPrivateKeyBundleV1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*EncryptedPrivateKeyBundle_V1) isEncryptedPrivateKeyBundle_Version() {} - -// EC: SECP256k1 -type SignedPrivateKey_Secp256K1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` // D big-endian, 32 bytes - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignedPrivateKey_Secp256K1) Reset() { - *x = SignedPrivateKey_Secp256K1{} - mi := &file_message_contents_private_key_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignedPrivateKey_Secp256K1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignedPrivateKey_Secp256K1) ProtoMessage() {} - -func (x *SignedPrivateKey_Secp256K1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignedPrivateKey_Secp256K1.ProtoReflect.Descriptor instead. -func (*SignedPrivateKey_Secp256K1) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *SignedPrivateKey_Secp256K1) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -// EC: SECP256k1 -type PrivateKey_Secp256K1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` // D big-endian, 32 bytes - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivateKey_Secp256K1) Reset() { - *x = PrivateKey_Secp256K1{} - mi := &file_message_contents_private_key_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivateKey_Secp256K1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivateKey_Secp256K1) ProtoMessage() {} - -func (x *PrivateKey_Secp256K1) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_key_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivateKey_Secp256K1.ProtoReflect.Descriptor instead. -func (*PrivateKey_Secp256K1) Descriptor() ([]byte, []int) { - return file_message_contents_private_key_proto_rawDescGZIP(), []int{2, 0} -} - -func (x *PrivateKey_Secp256K1) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -var File_message_contents_private_key_proto protoreflect.FileDescriptor - -const file_message_contents_private_key_proto_rawDesc = "" + - "\n" + - "\"message_contents/private_key.proto\x12\x15xmtp.message_contents\x1a!message_contents/ciphertext.proto\x1a!message_contents/public_key.proto\"\xf7\x01\n" + - "\x10SignedPrivateKey\x12\x1d\n" + - "\n" + - "created_ns\x18\x01 \x01(\x04R\tcreatedNs\x12Q\n" + - "\tsecp256k1\x18\x02 \x01(\v21.xmtp.message_contents.SignedPrivateKey.Secp256k1H\x00R\tsecp256k1\x12E\n" + - "\n" + - "public_key\x18\x03 \x01(\v2&.xmtp.message_contents.SignedPublicKeyR\tpublicKey\x1a!\n" + - "\tSecp256k1\x12\x14\n" + - "\x05bytes\x18\x01 \x01(\fR\x05bytesB\a\n" + - "\x05union\"\xa4\x01\n" + - "\x12PrivateKeyBundleV2\x12J\n" + - "\fidentity_key\x18\x01 \x01(\v2'.xmtp.message_contents.SignedPrivateKeyR\videntityKey\x12B\n" + - "\bpre_keys\x18\x02 \x03(\v2'.xmtp.message_contents.SignedPrivateKeyR\apreKeys\"\xe4\x01\n" + - "\n" + - "PrivateKey\x12\x1c\n" + - "\ttimestamp\x18\x01 \x01(\x04R\ttimestamp\x12K\n" + - "\tsecp256k1\x18\x02 \x01(\v2+.xmtp.message_contents.PrivateKey.Secp256k1H\x00R\tsecp256k1\x12?\n" + - "\n" + - "public_key\x18\x03 \x01(\v2 .xmtp.message_contents.PublicKeyR\tpublicKey\x1a!\n" + - "\tSecp256k1\x12\x14\n" + - "\x05bytes\x18\x01 \x01(\fR\x05bytesB\a\n" + - "\x05union\"\x98\x01\n" + - "\x12PrivateKeyBundleV1\x12D\n" + - "\fidentity_key\x18\x01 \x01(\v2!.xmtp.message_contents.PrivateKeyR\videntityKey\x12<\n" + - "\bpre_keys\x18\x02 \x03(\v2!.xmtp.message_contents.PrivateKeyR\apreKeys\"\x9d\x01\n" + - "\x10PrivateKeyBundle\x12;\n" + - "\x02v1\x18\x01 \x01(\v2).xmtp.message_contents.PrivateKeyBundleV1H\x00R\x02v1\x12;\n" + - "\x02v2\x18\x02 \x01(\v2).xmtp.message_contents.PrivateKeyBundleV2H\x00R\x02v2B\t\n" + - "\aversionJ\x04\b\x03\x10\x04\"\x86\x01\n" + - "\x1bEncryptedPrivateKeyBundleV1\x12$\n" + - "\x0ewallet_pre_key\x18\x01 \x01(\fR\fwalletPreKey\x12A\n" + - "\n" + - "ciphertext\x18\x02 \x01(\v2!.xmtp.message_contents.CiphertextR\n" + - "ciphertext\"l\n" + - "\x19EncryptedPrivateKeyBundle\x12D\n" + - "\x02v1\x18\x01 \x01(\v22.xmtp.message_contents.EncryptedPrivateKeyBundleV1H\x00R\x02v1B\t\n" + - "\aversionB\x82\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x0fPrivateKeyProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_private_key_proto_rawDescOnce sync.Once - file_message_contents_private_key_proto_rawDescData []byte -) - -func file_message_contents_private_key_proto_rawDescGZIP() []byte { - file_message_contents_private_key_proto_rawDescOnce.Do(func() { - file_message_contents_private_key_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_private_key_proto_rawDesc), len(file_message_contents_private_key_proto_rawDesc))) - }) - return file_message_contents_private_key_proto_rawDescData -} - -var file_message_contents_private_key_proto_msgTypes = make([]protoimpl.MessageInfo, 9) -var file_message_contents_private_key_proto_goTypes = []any{ - (*SignedPrivateKey)(nil), // 0: xmtp.message_contents.SignedPrivateKey - (*PrivateKeyBundleV2)(nil), // 1: xmtp.message_contents.PrivateKeyBundleV2 - (*PrivateKey)(nil), // 2: xmtp.message_contents.PrivateKey - (*PrivateKeyBundleV1)(nil), // 3: xmtp.message_contents.PrivateKeyBundleV1 - (*PrivateKeyBundle)(nil), // 4: xmtp.message_contents.PrivateKeyBundle - (*EncryptedPrivateKeyBundleV1)(nil), // 5: xmtp.message_contents.EncryptedPrivateKeyBundleV1 - (*EncryptedPrivateKeyBundle)(nil), // 6: xmtp.message_contents.EncryptedPrivateKeyBundle - (*SignedPrivateKey_Secp256K1)(nil), // 7: xmtp.message_contents.SignedPrivateKey.Secp256k1 - (*PrivateKey_Secp256K1)(nil), // 8: xmtp.message_contents.PrivateKey.Secp256k1 - (*SignedPublicKey)(nil), // 9: xmtp.message_contents.SignedPublicKey - (*PublicKey)(nil), // 10: xmtp.message_contents.PublicKey - (*Ciphertext)(nil), // 11: xmtp.message_contents.Ciphertext -} -var file_message_contents_private_key_proto_depIdxs = []int32{ - 7, // 0: xmtp.message_contents.SignedPrivateKey.secp256k1:type_name -> xmtp.message_contents.SignedPrivateKey.Secp256k1 - 9, // 1: xmtp.message_contents.SignedPrivateKey.public_key:type_name -> xmtp.message_contents.SignedPublicKey - 0, // 2: xmtp.message_contents.PrivateKeyBundleV2.identity_key:type_name -> xmtp.message_contents.SignedPrivateKey - 0, // 3: xmtp.message_contents.PrivateKeyBundleV2.pre_keys:type_name -> xmtp.message_contents.SignedPrivateKey - 8, // 4: xmtp.message_contents.PrivateKey.secp256k1:type_name -> xmtp.message_contents.PrivateKey.Secp256k1 - 10, // 5: xmtp.message_contents.PrivateKey.public_key:type_name -> xmtp.message_contents.PublicKey - 2, // 6: xmtp.message_contents.PrivateKeyBundleV1.identity_key:type_name -> xmtp.message_contents.PrivateKey - 2, // 7: xmtp.message_contents.PrivateKeyBundleV1.pre_keys:type_name -> xmtp.message_contents.PrivateKey - 3, // 8: xmtp.message_contents.PrivateKeyBundle.v1:type_name -> xmtp.message_contents.PrivateKeyBundleV1 - 1, // 9: xmtp.message_contents.PrivateKeyBundle.v2:type_name -> xmtp.message_contents.PrivateKeyBundleV2 - 11, // 10: xmtp.message_contents.EncryptedPrivateKeyBundleV1.ciphertext:type_name -> xmtp.message_contents.Ciphertext - 5, // 11: xmtp.message_contents.EncryptedPrivateKeyBundle.v1:type_name -> xmtp.message_contents.EncryptedPrivateKeyBundleV1 - 12, // [12:12] is the sub-list for method output_type - 12, // [12:12] is the sub-list for method input_type - 12, // [12:12] is the sub-list for extension type_name - 12, // [12:12] is the sub-list for extension extendee - 0, // [0:12] is the sub-list for field type_name -} - -func init() { file_message_contents_private_key_proto_init() } -func file_message_contents_private_key_proto_init() { - if File_message_contents_private_key_proto != nil { - return - } - file_message_contents_ciphertext_proto_init() - file_message_contents_public_key_proto_init() - file_message_contents_private_key_proto_msgTypes[0].OneofWrappers = []any{ - (*SignedPrivateKey_Secp256K1_)(nil), - } - file_message_contents_private_key_proto_msgTypes[2].OneofWrappers = []any{ - (*PrivateKey_Secp256K1_)(nil), - } - file_message_contents_private_key_proto_msgTypes[4].OneofWrappers = []any{ - (*PrivateKeyBundle_V1)(nil), - (*PrivateKeyBundle_V2)(nil), - } - file_message_contents_private_key_proto_msgTypes[6].OneofWrappers = []any{ - (*EncryptedPrivateKeyBundle_V1)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_private_key_proto_rawDesc), len(file_message_contents_private_key_proto_rawDesc)), - NumEnums: 0, - NumMessages: 9, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_private_key_proto_goTypes, - DependencyIndexes: file_message_contents_private_key_proto_depIdxs, - MessageInfos: file_message_contents_private_key_proto_msgTypes, - }.Build() - File_message_contents_private_key_proto = out.File - file_message_contents_private_key_proto_goTypes = nil - file_message_contents_private_key_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/private_preferences.pb.go b/pkg/proto/message_contents/private_preferences.pb.go deleted file mode 100644 index f1e32b1c..00000000 --- a/pkg/proto/message_contents/private_preferences.pb.go +++ /dev/null @@ -1,626 +0,0 @@ -// Private Key Storage -// -// Following definitions are not used in the protocol, instead they provide a -// way for encoding private keys for storage. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/private_preferences.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// PrivatePreferencesAction is a message used to update the client's preference -// store. -type PrivatePreferencesAction struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to MessageType: - // - // *PrivatePreferencesAction_AllowAddress_ - // *PrivatePreferencesAction_DenyAddress_ - // *PrivatePreferencesAction_AllowGroup_ - // *PrivatePreferencesAction_DenyGroup_ - // *PrivatePreferencesAction_AllowInboxId_ - // *PrivatePreferencesAction_DenyInboxId_ - MessageType isPrivatePreferencesAction_MessageType `protobuf_oneof:"message_type"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesAction) Reset() { - *x = PrivatePreferencesAction{} - mi := &file_message_contents_private_preferences_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesAction) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesAction) ProtoMessage() {} - -func (x *PrivatePreferencesAction) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_preferences_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesAction.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesAction) Descriptor() ([]byte, []int) { - return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0} -} - -func (x *PrivatePreferencesAction) GetMessageType() isPrivatePreferencesAction_MessageType { - if x != nil { - return x.MessageType - } - return nil -} - -func (x *PrivatePreferencesAction) GetAllowAddress() *PrivatePreferencesAction_AllowAddress { - if x != nil { - if x, ok := x.MessageType.(*PrivatePreferencesAction_AllowAddress_); ok { - return x.AllowAddress - } - } - return nil -} - -func (x *PrivatePreferencesAction) GetDenyAddress() *PrivatePreferencesAction_DenyAddress { - if x != nil { - if x, ok := x.MessageType.(*PrivatePreferencesAction_DenyAddress_); ok { - return x.DenyAddress - } - } - return nil -} - -func (x *PrivatePreferencesAction) GetAllowGroup() *PrivatePreferencesAction_AllowGroup { - if x != nil { - if x, ok := x.MessageType.(*PrivatePreferencesAction_AllowGroup_); ok { - return x.AllowGroup - } - } - return nil -} - -func (x *PrivatePreferencesAction) GetDenyGroup() *PrivatePreferencesAction_DenyGroup { - if x != nil { - if x, ok := x.MessageType.(*PrivatePreferencesAction_DenyGroup_); ok { - return x.DenyGroup - } - } - return nil -} - -func (x *PrivatePreferencesAction) GetAllowInboxId() *PrivatePreferencesAction_AllowInboxId { - if x != nil { - if x, ok := x.MessageType.(*PrivatePreferencesAction_AllowInboxId_); ok { - return x.AllowInboxId - } - } - return nil -} - -func (x *PrivatePreferencesAction) GetDenyInboxId() *PrivatePreferencesAction_DenyInboxId { - if x != nil { - if x, ok := x.MessageType.(*PrivatePreferencesAction_DenyInboxId_); ok { - return x.DenyInboxId - } - } - return nil -} - -type isPrivatePreferencesAction_MessageType interface { - isPrivatePreferencesAction_MessageType() -} - -type PrivatePreferencesAction_AllowAddress_ struct { - AllowAddress *PrivatePreferencesAction_AllowAddress `protobuf:"bytes,1,opt,name=allow_address,json=allowAddress,proto3,oneof"` -} - -type PrivatePreferencesAction_DenyAddress_ struct { - DenyAddress *PrivatePreferencesAction_DenyAddress `protobuf:"bytes,2,opt,name=deny_address,json=denyAddress,proto3,oneof"` -} - -type PrivatePreferencesAction_AllowGroup_ struct { - AllowGroup *PrivatePreferencesAction_AllowGroup `protobuf:"bytes,3,opt,name=allow_group,json=allowGroup,proto3,oneof"` -} - -type PrivatePreferencesAction_DenyGroup_ struct { - DenyGroup *PrivatePreferencesAction_DenyGroup `protobuf:"bytes,4,opt,name=deny_group,json=denyGroup,proto3,oneof"` -} - -type PrivatePreferencesAction_AllowInboxId_ struct { - AllowInboxId *PrivatePreferencesAction_AllowInboxId `protobuf:"bytes,5,opt,name=allow_inbox_id,json=allowInboxId,proto3,oneof"` -} - -type PrivatePreferencesAction_DenyInboxId_ struct { - DenyInboxId *PrivatePreferencesAction_DenyInboxId `protobuf:"bytes,6,opt,name=deny_inbox_id,json=denyInboxId,proto3,oneof"` -} - -func (*PrivatePreferencesAction_AllowAddress_) isPrivatePreferencesAction_MessageType() {} - -func (*PrivatePreferencesAction_DenyAddress_) isPrivatePreferencesAction_MessageType() {} - -func (*PrivatePreferencesAction_AllowGroup_) isPrivatePreferencesAction_MessageType() {} - -func (*PrivatePreferencesAction_DenyGroup_) isPrivatePreferencesAction_MessageType() {} - -func (*PrivatePreferencesAction_AllowInboxId_) isPrivatePreferencesAction_MessageType() {} - -func (*PrivatePreferencesAction_DenyInboxId_) isPrivatePreferencesAction_MessageType() {} - -// The payload that goes over the wire -type PrivatePreferencesPayload struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *PrivatePreferencesPayload_V1 - Version isPrivatePreferencesPayload_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesPayload) Reset() { - *x = PrivatePreferencesPayload{} - mi := &file_message_contents_private_preferences_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesPayload) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesPayload) ProtoMessage() {} - -func (x *PrivatePreferencesPayload) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_preferences_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesPayload.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesPayload) Descriptor() ([]byte, []int) { - return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{1} -} - -func (x *PrivatePreferencesPayload) GetVersion() isPrivatePreferencesPayload_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *PrivatePreferencesPayload) GetV1() *Ciphertext { - if x != nil { - if x, ok := x.Version.(*PrivatePreferencesPayload_V1); ok { - return x.V1 - } - } - return nil -} - -type isPrivatePreferencesPayload_Version interface { - isPrivatePreferencesPayload_Version() -} - -type PrivatePreferencesPayload_V1 struct { - V1 *Ciphertext `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*PrivatePreferencesPayload_V1) isPrivatePreferencesPayload_Version() {} - -// Allow 1:1 direct message (DM) access -type PrivatePreferencesAction_AllowAddress struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Add the given wallet addresses to the allow list - WalletAddresses []string `protobuf:"bytes,1,rep,name=wallet_addresses,json=walletAddresses,proto3" json:"wallet_addresses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesAction_AllowAddress) Reset() { - *x = PrivatePreferencesAction_AllowAddress{} - mi := &file_message_contents_private_preferences_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesAction_AllowAddress) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesAction_AllowAddress) ProtoMessage() {} - -func (x *PrivatePreferencesAction_AllowAddress) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_preferences_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesAction_AllowAddress.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesAction_AllowAddress) Descriptor() ([]byte, []int) { - return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *PrivatePreferencesAction_AllowAddress) GetWalletAddresses() []string { - if x != nil { - return x.WalletAddresses - } - return nil -} - -// Deny (block) 1:1 direct message (DM) access -type PrivatePreferencesAction_DenyAddress struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Add the given wallet addresses to the deny list - WalletAddresses []string `protobuf:"bytes,1,rep,name=wallet_addresses,json=walletAddresses,proto3" json:"wallet_addresses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesAction_DenyAddress) Reset() { - *x = PrivatePreferencesAction_DenyAddress{} - mi := &file_message_contents_private_preferences_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesAction_DenyAddress) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesAction_DenyAddress) ProtoMessage() {} - -func (x *PrivatePreferencesAction_DenyAddress) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_preferences_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesAction_DenyAddress.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesAction_DenyAddress) Descriptor() ([]byte, []int) { - return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0, 1} -} - -func (x *PrivatePreferencesAction_DenyAddress) GetWalletAddresses() []string { - if x != nil { - return x.WalletAddresses - } - return nil -} - -// Allow V3 1:1 direct message (DM) access -type PrivatePreferencesAction_AllowInboxId struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Add the given inbox id to the allow list - InboxIds []string `protobuf:"bytes,1,rep,name=inbox_ids,json=inboxIds,proto3" json:"inbox_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesAction_AllowInboxId) Reset() { - *x = PrivatePreferencesAction_AllowInboxId{} - mi := &file_message_contents_private_preferences_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesAction_AllowInboxId) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesAction_AllowInboxId) ProtoMessage() {} - -func (x *PrivatePreferencesAction_AllowInboxId) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_preferences_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesAction_AllowInboxId.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesAction_AllowInboxId) Descriptor() ([]byte, []int) { - return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0, 2} -} - -func (x *PrivatePreferencesAction_AllowInboxId) GetInboxIds() []string { - if x != nil { - return x.InboxIds - } - return nil -} - -// Deny (block) V3 1:1 direct message (DM) access -type PrivatePreferencesAction_DenyInboxId struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Add the given inbox id to the deny list - InboxIds []string `protobuf:"bytes,1,rep,name=inbox_ids,json=inboxIds,proto3" json:"inbox_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesAction_DenyInboxId) Reset() { - *x = PrivatePreferencesAction_DenyInboxId{} - mi := &file_message_contents_private_preferences_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesAction_DenyInboxId) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesAction_DenyInboxId) ProtoMessage() {} - -func (x *PrivatePreferencesAction_DenyInboxId) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_preferences_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesAction_DenyInboxId.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesAction_DenyInboxId) Descriptor() ([]byte, []int) { - return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0, 3} -} - -func (x *PrivatePreferencesAction_DenyInboxId) GetInboxIds() []string { - if x != nil { - return x.InboxIds - } - return nil -} - -// Allow Group access -type PrivatePreferencesAction_AllowGroup struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Add the given group_ids to the allow list - GroupIds []string `protobuf:"bytes,1,rep,name=group_ids,json=groupIds,proto3" json:"group_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesAction_AllowGroup) Reset() { - *x = PrivatePreferencesAction_AllowGroup{} - mi := &file_message_contents_private_preferences_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesAction_AllowGroup) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesAction_AllowGroup) ProtoMessage() {} - -func (x *PrivatePreferencesAction_AllowGroup) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_preferences_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesAction_AllowGroup.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesAction_AllowGroup) Descriptor() ([]byte, []int) { - return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0, 4} -} - -func (x *PrivatePreferencesAction_AllowGroup) GetGroupIds() []string { - if x != nil { - return x.GroupIds - } - return nil -} - -// Deny (deny) Group access -type PrivatePreferencesAction_DenyGroup struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Add the given group_ids to the deny list - GroupIds []string `protobuf:"bytes,1,rep,name=group_ids,json=groupIds,proto3" json:"group_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PrivatePreferencesAction_DenyGroup) Reset() { - *x = PrivatePreferencesAction_DenyGroup{} - mi := &file_message_contents_private_preferences_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PrivatePreferencesAction_DenyGroup) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PrivatePreferencesAction_DenyGroup) ProtoMessage() {} - -func (x *PrivatePreferencesAction_DenyGroup) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_private_preferences_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PrivatePreferencesAction_DenyGroup.ProtoReflect.Descriptor instead. -func (*PrivatePreferencesAction_DenyGroup) Descriptor() ([]byte, []int) { - return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0, 5} -} - -func (x *PrivatePreferencesAction_DenyGroup) GetGroupIds() []string { - if x != nil { - return x.GroupIds - } - return nil -} - -var File_message_contents_private_preferences_proto protoreflect.FileDescriptor - -const file_message_contents_private_preferences_proto_rawDesc = "" + - "\n" + - "*message_contents/private_preferences.proto\x12\x15xmtp.message_contents\x1a!message_contents/ciphertext.proto\"\x98\a\n" + - "\x18PrivatePreferencesAction\x12c\n" + - "\rallow_address\x18\x01 \x01(\v2<.xmtp.message_contents.PrivatePreferencesAction.AllowAddressH\x00R\fallowAddress\x12`\n" + - "\fdeny_address\x18\x02 \x01(\v2;.xmtp.message_contents.PrivatePreferencesAction.DenyAddressH\x00R\vdenyAddress\x12]\n" + - "\vallow_group\x18\x03 \x01(\v2:.xmtp.message_contents.PrivatePreferencesAction.AllowGroupH\x00R\n" + - "allowGroup\x12Z\n" + - "\n" + - "deny_group\x18\x04 \x01(\v29.xmtp.message_contents.PrivatePreferencesAction.DenyGroupH\x00R\tdenyGroup\x12d\n" + - "\x0eallow_inbox_id\x18\x05 \x01(\v2<.xmtp.message_contents.PrivatePreferencesAction.AllowInboxIdH\x00R\fallowInboxId\x12a\n" + - "\rdeny_inbox_id\x18\x06 \x01(\v2;.xmtp.message_contents.PrivatePreferencesAction.DenyInboxIdH\x00R\vdenyInboxId\x1a9\n" + - "\fAllowAddress\x12)\n" + - "\x10wallet_addresses\x18\x01 \x03(\tR\x0fwalletAddresses\x1a8\n" + - "\vDenyAddress\x12)\n" + - "\x10wallet_addresses\x18\x01 \x03(\tR\x0fwalletAddresses\x1a+\n" + - "\fAllowInboxId\x12\x1b\n" + - "\tinbox_ids\x18\x01 \x03(\tR\binboxIds\x1a*\n" + - "\vDenyInboxId\x12\x1b\n" + - "\tinbox_ids\x18\x01 \x03(\tR\binboxIds\x1a)\n" + - "\n" + - "AllowGroup\x12\x1b\n" + - "\tgroup_ids\x18\x01 \x03(\tR\bgroupIds\x1a(\n" + - "\tDenyGroup\x12\x1b\n" + - "\tgroup_ids\x18\x01 \x03(\tR\bgroupIdsB\x0e\n" + - "\fmessage_type\"[\n" + - "\x19PrivatePreferencesPayload\x123\n" + - "\x02v1\x18\x01 \x01(\v2!.xmtp.message_contents.CiphertextH\x00R\x02v1B\t\n" + - "\aversionB\x8a\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x17PrivatePreferencesProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_private_preferences_proto_rawDescOnce sync.Once - file_message_contents_private_preferences_proto_rawDescData []byte -) - -func file_message_contents_private_preferences_proto_rawDescGZIP() []byte { - file_message_contents_private_preferences_proto_rawDescOnce.Do(func() { - file_message_contents_private_preferences_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_private_preferences_proto_rawDesc), len(file_message_contents_private_preferences_proto_rawDesc))) - }) - return file_message_contents_private_preferences_proto_rawDescData -} - -var file_message_contents_private_preferences_proto_msgTypes = make([]protoimpl.MessageInfo, 8) -var file_message_contents_private_preferences_proto_goTypes = []any{ - (*PrivatePreferencesAction)(nil), // 0: xmtp.message_contents.PrivatePreferencesAction - (*PrivatePreferencesPayload)(nil), // 1: xmtp.message_contents.PrivatePreferencesPayload - (*PrivatePreferencesAction_AllowAddress)(nil), // 2: xmtp.message_contents.PrivatePreferencesAction.AllowAddress - (*PrivatePreferencesAction_DenyAddress)(nil), // 3: xmtp.message_contents.PrivatePreferencesAction.DenyAddress - (*PrivatePreferencesAction_AllowInboxId)(nil), // 4: xmtp.message_contents.PrivatePreferencesAction.AllowInboxId - (*PrivatePreferencesAction_DenyInboxId)(nil), // 5: xmtp.message_contents.PrivatePreferencesAction.DenyInboxId - (*PrivatePreferencesAction_AllowGroup)(nil), // 6: xmtp.message_contents.PrivatePreferencesAction.AllowGroup - (*PrivatePreferencesAction_DenyGroup)(nil), // 7: xmtp.message_contents.PrivatePreferencesAction.DenyGroup - (*Ciphertext)(nil), // 8: xmtp.message_contents.Ciphertext -} -var file_message_contents_private_preferences_proto_depIdxs = []int32{ - 2, // 0: xmtp.message_contents.PrivatePreferencesAction.allow_address:type_name -> xmtp.message_contents.PrivatePreferencesAction.AllowAddress - 3, // 1: xmtp.message_contents.PrivatePreferencesAction.deny_address:type_name -> xmtp.message_contents.PrivatePreferencesAction.DenyAddress - 6, // 2: xmtp.message_contents.PrivatePreferencesAction.allow_group:type_name -> xmtp.message_contents.PrivatePreferencesAction.AllowGroup - 7, // 3: xmtp.message_contents.PrivatePreferencesAction.deny_group:type_name -> xmtp.message_contents.PrivatePreferencesAction.DenyGroup - 4, // 4: xmtp.message_contents.PrivatePreferencesAction.allow_inbox_id:type_name -> xmtp.message_contents.PrivatePreferencesAction.AllowInboxId - 5, // 5: xmtp.message_contents.PrivatePreferencesAction.deny_inbox_id:type_name -> xmtp.message_contents.PrivatePreferencesAction.DenyInboxId - 8, // 6: xmtp.message_contents.PrivatePreferencesPayload.v1:type_name -> xmtp.message_contents.Ciphertext - 7, // [7:7] is the sub-list for method output_type - 7, // [7:7] is the sub-list for method input_type - 7, // [7:7] is the sub-list for extension type_name - 7, // [7:7] is the sub-list for extension extendee - 0, // [0:7] is the sub-list for field type_name -} - -func init() { file_message_contents_private_preferences_proto_init() } -func file_message_contents_private_preferences_proto_init() { - if File_message_contents_private_preferences_proto != nil { - return - } - file_message_contents_ciphertext_proto_init() - file_message_contents_private_preferences_proto_msgTypes[0].OneofWrappers = []any{ - (*PrivatePreferencesAction_AllowAddress_)(nil), - (*PrivatePreferencesAction_DenyAddress_)(nil), - (*PrivatePreferencesAction_AllowGroup_)(nil), - (*PrivatePreferencesAction_DenyGroup_)(nil), - (*PrivatePreferencesAction_AllowInboxId_)(nil), - (*PrivatePreferencesAction_DenyInboxId_)(nil), - } - file_message_contents_private_preferences_proto_msgTypes[1].OneofWrappers = []any{ - (*PrivatePreferencesPayload_V1)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_private_preferences_proto_rawDesc), len(file_message_contents_private_preferences_proto_rawDesc)), - NumEnums: 0, - NumMessages: 8, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_private_preferences_proto_goTypes, - DependencyIndexes: file_message_contents_private_preferences_proto_depIdxs, - MessageInfos: file_message_contents_private_preferences_proto_msgTypes, - }.Build() - File_message_contents_private_preferences_proto = out.File - file_message_contents_private_preferences_proto_goTypes = nil - file_message_contents_private_preferences_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/public_key.pb.go b/pkg/proto/message_contents/public_key.pb.go deleted file mode 100644 index 27684695..00000000 --- a/pkg/proto/message_contents/public_key.pb.go +++ /dev/null @@ -1,543 +0,0 @@ -// Structure for representing public keys of different types, -// including signatures used to authenticate the keys. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/public_key.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// UnsignedPublicKey represents a generalized public key, -// defined as a union to support cryptographic algorithm agility. -type UnsignedPublicKey struct { - state protoimpl.MessageState `protogen:"open.v1"` - CreatedNs uint64 `protobuf:"varint,1,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - // Types that are valid to be assigned to Union: - // - // *UnsignedPublicKey_Secp256K1Uncompressed_ - Union isUnsignedPublicKey_Union `protobuf_oneof:"union"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UnsignedPublicKey) Reset() { - *x = UnsignedPublicKey{} - mi := &file_message_contents_public_key_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UnsignedPublicKey) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UnsignedPublicKey) ProtoMessage() {} - -func (x *UnsignedPublicKey) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_public_key_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UnsignedPublicKey.ProtoReflect.Descriptor instead. -func (*UnsignedPublicKey) Descriptor() ([]byte, []int) { - return file_message_contents_public_key_proto_rawDescGZIP(), []int{0} -} - -func (x *UnsignedPublicKey) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *UnsignedPublicKey) GetUnion() isUnsignedPublicKey_Union { - if x != nil { - return x.Union - } - return nil -} - -func (x *UnsignedPublicKey) GetSecp256K1Uncompressed() *UnsignedPublicKey_Secp256K1Uncompressed { - if x != nil { - if x, ok := x.Union.(*UnsignedPublicKey_Secp256K1Uncompressed_); ok { - return x.Secp256K1Uncompressed - } - } - return nil -} - -type isUnsignedPublicKey_Union interface { - isUnsignedPublicKey_Union() -} - -type UnsignedPublicKey_Secp256K1Uncompressed_ struct { - Secp256K1Uncompressed *UnsignedPublicKey_Secp256K1Uncompressed `protobuf:"bytes,3,opt,name=secp256k1_uncompressed,json=secp256k1Uncompressed,proto3,oneof"` -} - -func (*UnsignedPublicKey_Secp256K1Uncompressed_) isUnsignedPublicKey_Union() {} - -// SignedPublicKey -type SignedPublicKey struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyBytes []byte `protobuf:"bytes,1,opt,name=key_bytes,json=keyBytes,proto3" json:"key_bytes,omitempty"` // embeds an UnsignedPublicKey - Signature *Signature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` // signs key_bytes - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignedPublicKey) Reset() { - *x = SignedPublicKey{} - mi := &file_message_contents_public_key_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignedPublicKey) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignedPublicKey) ProtoMessage() {} - -func (x *SignedPublicKey) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_public_key_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignedPublicKey.ProtoReflect.Descriptor instead. -func (*SignedPublicKey) Descriptor() ([]byte, []int) { - return file_message_contents_public_key_proto_rawDescGZIP(), []int{1} -} - -func (x *SignedPublicKey) GetKeyBytes() []byte { - if x != nil { - return x.KeyBytes - } - return nil -} - -func (x *SignedPublicKey) GetSignature() *Signature { - if x != nil { - return x.Signature - } - return nil -} - -// PublicKeyBundle packages the cryptographic keys associated with a wallet. -type SignedPublicKeyBundle struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Identity key MUST be signed by the wallet. - IdentityKey *SignedPublicKey `protobuf:"bytes,1,opt,name=identity_key,json=identityKey,proto3" json:"identity_key,omitempty"` - // Pre-key MUST be signed by the identity key. - PreKey *SignedPublicKey `protobuf:"bytes,2,opt,name=pre_key,json=preKey,proto3" json:"pre_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignedPublicKeyBundle) Reset() { - *x = SignedPublicKeyBundle{} - mi := &file_message_contents_public_key_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignedPublicKeyBundle) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignedPublicKeyBundle) ProtoMessage() {} - -func (x *SignedPublicKeyBundle) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_public_key_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignedPublicKeyBundle.ProtoReflect.Descriptor instead. -func (*SignedPublicKeyBundle) Descriptor() ([]byte, []int) { - return file_message_contents_public_key_proto_rawDescGZIP(), []int{2} -} - -func (x *SignedPublicKeyBundle) GetIdentityKey() *SignedPublicKey { - if x != nil { - return x.IdentityKey - } - return nil -} - -func (x *SignedPublicKeyBundle) GetPreKey() *SignedPublicKey { - if x != nil { - return x.PreKey - } - return nil -} - -// PublicKey represents a generalized public key, -// defined as a union to support cryptographic algorithm agility. -type PublicKey struct { - state protoimpl.MessageState `protogen:"open.v1"` - Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - Signature *Signature `protobuf:"bytes,2,opt,name=signature,proto3,oneof" json:"signature,omitempty"` - // Types that are valid to be assigned to Union: - // - // *PublicKey_Secp256K1Uncompressed_ - Union isPublicKey_Union `protobuf_oneof:"union"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublicKey) Reset() { - *x = PublicKey{} - mi := &file_message_contents_public_key_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublicKey) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublicKey) ProtoMessage() {} - -func (x *PublicKey) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_public_key_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublicKey.ProtoReflect.Descriptor instead. -func (*PublicKey) Descriptor() ([]byte, []int) { - return file_message_contents_public_key_proto_rawDescGZIP(), []int{3} -} - -func (x *PublicKey) GetTimestamp() uint64 { - if x != nil { - return x.Timestamp - } - return 0 -} - -func (x *PublicKey) GetSignature() *Signature { - if x != nil { - return x.Signature - } - return nil -} - -func (x *PublicKey) GetUnion() isPublicKey_Union { - if x != nil { - return x.Union - } - return nil -} - -func (x *PublicKey) GetSecp256K1Uncompressed() *PublicKey_Secp256K1Uncompressed { - if x != nil { - if x, ok := x.Union.(*PublicKey_Secp256K1Uncompressed_); ok { - return x.Secp256K1Uncompressed - } - } - return nil -} - -type isPublicKey_Union interface { - isPublicKey_Union() -} - -type PublicKey_Secp256K1Uncompressed_ struct { - Secp256K1Uncompressed *PublicKey_Secp256K1Uncompressed `protobuf:"bytes,3,opt,name=secp256k1_uncompressed,json=secp256k1Uncompressed,proto3,oneof"` -} - -func (*PublicKey_Secp256K1Uncompressed_) isPublicKey_Union() {} - -// PublicKeyBundle packages the cryptographic keys associated with a wallet, -// both senders and recipients are identified by their key bundles. -type PublicKeyBundle struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Identity key MUST be signed by the wallet. - IdentityKey *PublicKey `protobuf:"bytes,1,opt,name=identity_key,json=identityKey,proto3" json:"identity_key,omitempty"` - // Pre-key MUST be signed by the identity key. - PreKey *PublicKey `protobuf:"bytes,2,opt,name=pre_key,json=preKey,proto3" json:"pre_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublicKeyBundle) Reset() { - *x = PublicKeyBundle{} - mi := &file_message_contents_public_key_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublicKeyBundle) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublicKeyBundle) ProtoMessage() {} - -func (x *PublicKeyBundle) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_public_key_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublicKeyBundle.ProtoReflect.Descriptor instead. -func (*PublicKeyBundle) Descriptor() ([]byte, []int) { - return file_message_contents_public_key_proto_rawDescGZIP(), []int{4} -} - -func (x *PublicKeyBundle) GetIdentityKey() *PublicKey { - if x != nil { - return x.IdentityKey - } - return nil -} - -func (x *PublicKeyBundle) GetPreKey() *PublicKey { - if x != nil { - return x.PreKey - } - return nil -} - -// EC: SECP256k1 -type UnsignedPublicKey_Secp256K1Uncompressed struct { - state protoimpl.MessageState `protogen:"open.v1"` - // uncompressed point with prefix (0x04) [ P || X || Y ], 65 bytes - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UnsignedPublicKey_Secp256K1Uncompressed) Reset() { - *x = UnsignedPublicKey_Secp256K1Uncompressed{} - mi := &file_message_contents_public_key_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UnsignedPublicKey_Secp256K1Uncompressed) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UnsignedPublicKey_Secp256K1Uncompressed) ProtoMessage() {} - -func (x *UnsignedPublicKey_Secp256K1Uncompressed) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_public_key_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UnsignedPublicKey_Secp256K1Uncompressed.ProtoReflect.Descriptor instead. -func (*UnsignedPublicKey_Secp256K1Uncompressed) Descriptor() ([]byte, []int) { - return file_message_contents_public_key_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *UnsignedPublicKey_Secp256K1Uncompressed) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -// The key bytes -type PublicKey_Secp256K1Uncompressed struct { - state protoimpl.MessageState `protogen:"open.v1"` - // uncompressed point with prefix (0x04) [ P || X || Y ], 65 bytes - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublicKey_Secp256K1Uncompressed) Reset() { - *x = PublicKey_Secp256K1Uncompressed{} - mi := &file_message_contents_public_key_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublicKey_Secp256K1Uncompressed) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublicKey_Secp256K1Uncompressed) ProtoMessage() {} - -func (x *PublicKey_Secp256K1Uncompressed) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_public_key_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublicKey_Secp256K1Uncompressed.ProtoReflect.Descriptor instead. -func (*PublicKey_Secp256K1Uncompressed) Descriptor() ([]byte, []int) { - return file_message_contents_public_key_proto_rawDescGZIP(), []int{3, 0} -} - -func (x *PublicKey_Secp256K1Uncompressed) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -var File_message_contents_public_key_proto protoreflect.FileDescriptor - -const file_message_contents_public_key_proto_rawDesc = "" + - "\n" + - "!message_contents/public_key.proto\x12\x15xmtp.message_contents\x1a message_contents/signature.proto\"\xe3\x01\n" + - "\x11UnsignedPublicKey\x12\x1d\n" + - "\n" + - "created_ns\x18\x01 \x01(\x04R\tcreatedNs\x12w\n" + - "\x16secp256k1_uncompressed\x18\x03 \x01(\v2>.xmtp.message_contents.UnsignedPublicKey.Secp256k1UncompressedH\x00R\x15secp256k1Uncompressed\x1a-\n" + - "\x15Secp256k1Uncompressed\x12\x14\n" + - "\x05bytes\x18\x01 \x01(\fR\x05bytesB\a\n" + - "\x05union\"n\n" + - "\x0fSignedPublicKey\x12\x1b\n" + - "\tkey_bytes\x18\x01 \x01(\fR\bkeyBytes\x12>\n" + - "\tsignature\x18\x02 \x01(\v2 .xmtp.message_contents.SignatureR\tsignature\"\xa3\x01\n" + - "\x15SignedPublicKeyBundle\x12I\n" + - "\fidentity_key\x18\x01 \x01(\v2&.xmtp.message_contents.SignedPublicKeyR\videntityKey\x12?\n" + - "\apre_key\x18\x02 \x01(\v2&.xmtp.message_contents.SignedPublicKeyR\x06preKey\"\xa5\x02\n" + - "\tPublicKey\x12\x1c\n" + - "\ttimestamp\x18\x01 \x01(\x04R\ttimestamp\x12C\n" + - "\tsignature\x18\x02 \x01(\v2 .xmtp.message_contents.SignatureH\x01R\tsignature\x88\x01\x01\x12o\n" + - "\x16secp256k1_uncompressed\x18\x03 \x01(\v26.xmtp.message_contents.PublicKey.Secp256k1UncompressedH\x00R\x15secp256k1Uncompressed\x1a-\n" + - "\x15Secp256k1Uncompressed\x12\x14\n" + - "\x05bytes\x18\x01 \x01(\fR\x05bytesB\a\n" + - "\x05unionB\f\n" + - "\n" + - "_signature\"\x91\x01\n" + - "\x0fPublicKeyBundle\x12C\n" + - "\fidentity_key\x18\x01 \x01(\v2 .xmtp.message_contents.PublicKeyR\videntityKey\x129\n" + - "\apre_key\x18\x02 \x01(\v2 .xmtp.message_contents.PublicKeyR\x06preKeyB\x81\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x0ePublicKeyProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_public_key_proto_rawDescOnce sync.Once - file_message_contents_public_key_proto_rawDescData []byte -) - -func file_message_contents_public_key_proto_rawDescGZIP() []byte { - file_message_contents_public_key_proto_rawDescOnce.Do(func() { - file_message_contents_public_key_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_public_key_proto_rawDesc), len(file_message_contents_public_key_proto_rawDesc))) - }) - return file_message_contents_public_key_proto_rawDescData -} - -var file_message_contents_public_key_proto_msgTypes = make([]protoimpl.MessageInfo, 7) -var file_message_contents_public_key_proto_goTypes = []any{ - (*UnsignedPublicKey)(nil), // 0: xmtp.message_contents.UnsignedPublicKey - (*SignedPublicKey)(nil), // 1: xmtp.message_contents.SignedPublicKey - (*SignedPublicKeyBundle)(nil), // 2: xmtp.message_contents.SignedPublicKeyBundle - (*PublicKey)(nil), // 3: xmtp.message_contents.PublicKey - (*PublicKeyBundle)(nil), // 4: xmtp.message_contents.PublicKeyBundle - (*UnsignedPublicKey_Secp256K1Uncompressed)(nil), // 5: xmtp.message_contents.UnsignedPublicKey.Secp256k1Uncompressed - (*PublicKey_Secp256K1Uncompressed)(nil), // 6: xmtp.message_contents.PublicKey.Secp256k1Uncompressed - (*Signature)(nil), // 7: xmtp.message_contents.Signature -} -var file_message_contents_public_key_proto_depIdxs = []int32{ - 5, // 0: xmtp.message_contents.UnsignedPublicKey.secp256k1_uncompressed:type_name -> xmtp.message_contents.UnsignedPublicKey.Secp256k1Uncompressed - 7, // 1: xmtp.message_contents.SignedPublicKey.signature:type_name -> xmtp.message_contents.Signature - 1, // 2: xmtp.message_contents.SignedPublicKeyBundle.identity_key:type_name -> xmtp.message_contents.SignedPublicKey - 1, // 3: xmtp.message_contents.SignedPublicKeyBundle.pre_key:type_name -> xmtp.message_contents.SignedPublicKey - 7, // 4: xmtp.message_contents.PublicKey.signature:type_name -> xmtp.message_contents.Signature - 6, // 5: xmtp.message_contents.PublicKey.secp256k1_uncompressed:type_name -> xmtp.message_contents.PublicKey.Secp256k1Uncompressed - 3, // 6: xmtp.message_contents.PublicKeyBundle.identity_key:type_name -> xmtp.message_contents.PublicKey - 3, // 7: xmtp.message_contents.PublicKeyBundle.pre_key:type_name -> xmtp.message_contents.PublicKey - 8, // [8:8] is the sub-list for method output_type - 8, // [8:8] is the sub-list for method input_type - 8, // [8:8] is the sub-list for extension type_name - 8, // [8:8] is the sub-list for extension extendee - 0, // [0:8] is the sub-list for field type_name -} - -func init() { file_message_contents_public_key_proto_init() } -func file_message_contents_public_key_proto_init() { - if File_message_contents_public_key_proto != nil { - return - } - file_message_contents_signature_proto_init() - file_message_contents_public_key_proto_msgTypes[0].OneofWrappers = []any{ - (*UnsignedPublicKey_Secp256K1Uncompressed_)(nil), - } - file_message_contents_public_key_proto_msgTypes[3].OneofWrappers = []any{ - (*PublicKey_Secp256K1Uncompressed_)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_public_key_proto_rawDesc), len(file_message_contents_public_key_proto_rawDesc)), - NumEnums: 0, - NumMessages: 7, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_public_key_proto_goTypes, - DependencyIndexes: file_message_contents_public_key_proto_depIdxs, - MessageInfos: file_message_contents_public_key_proto_msgTypes, - }.Build() - File_message_contents_public_key_proto = out.File - file_message_contents_public_key_proto_goTypes = nil - file_message_contents_public_key_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/signature.pb.go b/pkg/proto/message_contents/signature.pb.go deleted file mode 100644 index caa25b6f..00000000 --- a/pkg/proto/message_contents/signature.pb.go +++ /dev/null @@ -1,290 +0,0 @@ -// Signature is a generic structure for public key signatures. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/signature.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Signature represents a generalized public key signature, -// defined as a union to support cryptographic algorithm agility. -type Signature struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Union: - // - // *Signature_EcdsaCompact - // *Signature_WalletEcdsaCompact - Union isSignature_Union `protobuf_oneof:"union"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Signature) Reset() { - *x = Signature{} - mi := &file_message_contents_signature_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Signature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Signature) ProtoMessage() {} - -func (x *Signature) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_signature_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Signature.ProtoReflect.Descriptor instead. -func (*Signature) Descriptor() ([]byte, []int) { - return file_message_contents_signature_proto_rawDescGZIP(), []int{0} -} - -func (x *Signature) GetUnion() isSignature_Union { - if x != nil { - return x.Union - } - return nil -} - -func (x *Signature) GetEcdsaCompact() *Signature_ECDSACompact { - if x != nil { - if x, ok := x.Union.(*Signature_EcdsaCompact); ok { - return x.EcdsaCompact - } - } - return nil -} - -func (x *Signature) GetWalletEcdsaCompact() *Signature_WalletECDSACompact { - if x != nil { - if x, ok := x.Union.(*Signature_WalletEcdsaCompact); ok { - return x.WalletEcdsaCompact - } - } - return nil -} - -type isSignature_Union interface { - isSignature_Union() -} - -type Signature_EcdsaCompact struct { - EcdsaCompact *Signature_ECDSACompact `protobuf:"bytes,1,opt,name=ecdsa_compact,json=ecdsaCompact,proto3,oneof"` -} - -type Signature_WalletEcdsaCompact struct { - WalletEcdsaCompact *Signature_WalletECDSACompact `protobuf:"bytes,2,opt,name=wallet_ecdsa_compact,json=walletEcdsaCompact,proto3,oneof"` -} - -func (*Signature_EcdsaCompact) isSignature_Union() {} - -func (*Signature_WalletEcdsaCompact) isSignature_Union() {} - -// ECDSA signature bytes and the recovery bit -type Signature_ECDSACompact struct { - state protoimpl.MessageState `protogen:"open.v1"` - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` // compact representation [ R || S ], 64 bytes - Recovery uint32 `protobuf:"varint,2,opt,name=recovery,proto3" json:"recovery,omitempty"` // recovery bit - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Signature_ECDSACompact) Reset() { - *x = Signature_ECDSACompact{} - mi := &file_message_contents_signature_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Signature_ECDSACompact) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Signature_ECDSACompact) ProtoMessage() {} - -func (x *Signature_ECDSACompact) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_signature_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Signature_ECDSACompact.ProtoReflect.Descriptor instead. -func (*Signature_ECDSACompact) Descriptor() ([]byte, []int) { - return file_message_contents_signature_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *Signature_ECDSACompact) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -func (x *Signature_ECDSACompact) GetRecovery() uint32 { - if x != nil { - return x.Recovery - } - return 0 -} - -// ECDSA signature bytes and the recovery bit -// produced by xmtp-js::PublicKey.signWithWallet function, i.e. -// EIP-191 signature of a "Create Identity" message with the key embedded. -// Used to sign identity keys. -type Signature_WalletECDSACompact struct { - state protoimpl.MessageState `protogen:"open.v1"` - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` // compact representation [ R || S ], 64 bytes - Recovery uint32 `protobuf:"varint,2,opt,name=recovery,proto3" json:"recovery,omitempty"` // recovery bit - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Signature_WalletECDSACompact) Reset() { - *x = Signature_WalletECDSACompact{} - mi := &file_message_contents_signature_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Signature_WalletECDSACompact) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Signature_WalletECDSACompact) ProtoMessage() {} - -func (x *Signature_WalletECDSACompact) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_signature_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Signature_WalletECDSACompact.ProtoReflect.Descriptor instead. -func (*Signature_WalletECDSACompact) Descriptor() ([]byte, []int) { - return file_message_contents_signature_proto_rawDescGZIP(), []int{0, 1} -} - -func (x *Signature_WalletECDSACompact) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -func (x *Signature_WalletECDSACompact) GetRecovery() uint32 { - if x != nil { - return x.Recovery - } - return 0 -} - -var File_message_contents_signature_proto protoreflect.FileDescriptor - -const file_message_contents_signature_proto_rawDesc = "" + - "\n" + - " message_contents/signature.proto\x12\x15xmtp.message_contents\"\xdd\x02\n" + - "\tSignature\x12T\n" + - "\recdsa_compact\x18\x01 \x01(\v2-.xmtp.message_contents.Signature.ECDSACompactH\x00R\fecdsaCompact\x12g\n" + - "\x14wallet_ecdsa_compact\x18\x02 \x01(\v23.xmtp.message_contents.Signature.WalletECDSACompactH\x00R\x12walletEcdsaCompact\x1a@\n" + - "\fECDSACompact\x12\x14\n" + - "\x05bytes\x18\x01 \x01(\fR\x05bytes\x12\x1a\n" + - "\brecovery\x18\x02 \x01(\rR\brecovery\x1aF\n" + - "\x12WalletECDSACompact\x12\x14\n" + - "\x05bytes\x18\x01 \x01(\fR\x05bytes\x12\x1a\n" + - "\brecovery\x18\x02 \x01(\rR\brecoveryB\a\n" + - "\x05unionB\x81\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x0eSignatureProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_signature_proto_rawDescOnce sync.Once - file_message_contents_signature_proto_rawDescData []byte -) - -func file_message_contents_signature_proto_rawDescGZIP() []byte { - file_message_contents_signature_proto_rawDescOnce.Do(func() { - file_message_contents_signature_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_signature_proto_rawDesc), len(file_message_contents_signature_proto_rawDesc))) - }) - return file_message_contents_signature_proto_rawDescData -} - -var file_message_contents_signature_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_message_contents_signature_proto_goTypes = []any{ - (*Signature)(nil), // 0: xmtp.message_contents.Signature - (*Signature_ECDSACompact)(nil), // 1: xmtp.message_contents.Signature.ECDSACompact - (*Signature_WalletECDSACompact)(nil), // 2: xmtp.message_contents.Signature.WalletECDSACompact -} -var file_message_contents_signature_proto_depIdxs = []int32{ - 1, // 0: xmtp.message_contents.Signature.ecdsa_compact:type_name -> xmtp.message_contents.Signature.ECDSACompact - 2, // 1: xmtp.message_contents.Signature.wallet_ecdsa_compact:type_name -> xmtp.message_contents.Signature.WalletECDSACompact - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_message_contents_signature_proto_init() } -func file_message_contents_signature_proto_init() { - if File_message_contents_signature_proto != nil { - return - } - file_message_contents_signature_proto_msgTypes[0].OneofWrappers = []any{ - (*Signature_EcdsaCompact)(nil), - (*Signature_WalletEcdsaCompact)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_signature_proto_rawDesc), len(file_message_contents_signature_proto_rawDesc)), - NumEnums: 0, - NumMessages: 3, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_signature_proto_goTypes, - DependencyIndexes: file_message_contents_signature_proto_depIdxs, - MessageInfos: file_message_contents_signature_proto_msgTypes, - }.Build() - File_message_contents_signature_proto = out.File - file_message_contents_signature_proto_goTypes = nil - file_message_contents_signature_proto_depIdxs = nil -} diff --git a/pkg/proto/message_contents/signed_payload.pb.go b/pkg/proto/message_contents/signed_payload.pb.go deleted file mode 100644 index d7354460..00000000 --- a/pkg/proto/message_contents/signed_payload.pb.go +++ /dev/null @@ -1,138 +0,0 @@ -// Signature is a generic structure for signed byte arrays - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: message_contents/signed_payload.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// SignedPayload is a wrapper for a signature and a payload -type SignedPayload struct { - state protoimpl.MessageState `protogen:"open.v1"` - Payload []byte `protobuf:"bytes,1,opt,name=payload,proto3" json:"payload,omitempty"` - Signature *Signature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SignedPayload) Reset() { - *x = SignedPayload{} - mi := &file_message_contents_signed_payload_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SignedPayload) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SignedPayload) ProtoMessage() {} - -func (x *SignedPayload) ProtoReflect() protoreflect.Message { - mi := &file_message_contents_signed_payload_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SignedPayload.ProtoReflect.Descriptor instead. -func (*SignedPayload) Descriptor() ([]byte, []int) { - return file_message_contents_signed_payload_proto_rawDescGZIP(), []int{0} -} - -func (x *SignedPayload) GetPayload() []byte { - if x != nil { - return x.Payload - } - return nil -} - -func (x *SignedPayload) GetSignature() *Signature { - if x != nil { - return x.Signature - } - return nil -} - -var File_message_contents_signed_payload_proto protoreflect.FileDescriptor - -const file_message_contents_signed_payload_proto_rawDesc = "" + - "\n" + - "%message_contents/signed_payload.proto\x12\x15xmtp.message_contents\x1a message_contents/signature.proto\"i\n" + - "\rSignedPayload\x12\x18\n" + - "\apayload\x18\x01 \x01(\fR\apayload\x12>\n" + - "\tsignature\x18\x02 \x01(\v2 .xmtp.message_contents.SignatureR\tsignatureB\x85\x02\n" + - "3org.xmtp.android.library.push.xmtp.message_contentsB\x12SignedPayloadProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/message_contents\xa2\x02\x03XMX\xaa\x02\x14Xmtp.MessageContents\xca\x02\x14Xmtp\\MessageContents\xe2\x02 Xmtp\\MessageContents\\GPBMetadata\xea\x02\x15Xmtp::MessageContentsb\x06proto3" - -var ( - file_message_contents_signed_payload_proto_rawDescOnce sync.Once - file_message_contents_signed_payload_proto_rawDescData []byte -) - -func file_message_contents_signed_payload_proto_rawDescGZIP() []byte { - file_message_contents_signed_payload_proto_rawDescOnce.Do(func() { - file_message_contents_signed_payload_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_message_contents_signed_payload_proto_rawDesc), len(file_message_contents_signed_payload_proto_rawDesc))) - }) - return file_message_contents_signed_payload_proto_rawDescData -} - -var file_message_contents_signed_payload_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_message_contents_signed_payload_proto_goTypes = []any{ - (*SignedPayload)(nil), // 0: xmtp.message_contents.SignedPayload - (*Signature)(nil), // 1: xmtp.message_contents.Signature -} -var file_message_contents_signed_payload_proto_depIdxs = []int32{ - 1, // 0: xmtp.message_contents.SignedPayload.signature:type_name -> xmtp.message_contents.Signature - 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_message_contents_signed_payload_proto_init() } -func file_message_contents_signed_payload_proto_init() { - if File_message_contents_signed_payload_proto != nil { - return - } - file_message_contents_signature_proto_init() - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_message_contents_signed_payload_proto_rawDesc), len(file_message_contents_signed_payload_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_message_contents_signed_payload_proto_goTypes, - DependencyIndexes: file_message_contents_signed_payload_proto_depIdxs, - MessageInfos: file_message_contents_signed_payload_proto_msgTypes, - }.Build() - File_message_contents_signed_payload_proto = out.File - file_message_contents_signed_payload_proto_goTypes = nil - file_message_contents_signed_payload_proto_depIdxs = nil -} diff --git a/pkg/proto/migration/api/v1/migration.pb.go b/pkg/proto/migration/api/v1/migration.pb.go deleted file mode 100644 index 5556c634..00000000 --- a/pkg/proto/migration/api/v1/migration.pb.go +++ /dev/null @@ -1,134 +0,0 @@ -// V3 -> D14n Migration Protos -// These can be removed once migration is complete - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: migration/api/v1/migration.proto - -package apiv1 - -import ( - _ "google.golang.org/genproto/googleapis/api/annotations" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - emptypb "google.golang.org/protobuf/types/known/emptypb" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type FetchD14NCutoverResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - // the unix timestamp at which point d14n becomes the canonical backend - TimestampNs uint64 `protobuf:"varint,1,opt,name=timestamp_ns,json=timestampNs,proto3" json:"timestamp_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *FetchD14NCutoverResponse) Reset() { - *x = FetchD14NCutoverResponse{} - mi := &file_migration_api_v1_migration_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *FetchD14NCutoverResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*FetchD14NCutoverResponse) ProtoMessage() {} - -func (x *FetchD14NCutoverResponse) ProtoReflect() protoreflect.Message { - mi := &file_migration_api_v1_migration_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use FetchD14NCutoverResponse.ProtoReflect.Descriptor instead. -func (*FetchD14NCutoverResponse) Descriptor() ([]byte, []int) { - return file_migration_api_v1_migration_proto_rawDescGZIP(), []int{0} -} - -func (x *FetchD14NCutoverResponse) GetTimestampNs() uint64 { - if x != nil { - return x.TimestampNs - } - return 0 -} - -var File_migration_api_v1_migration_proto protoreflect.FileDescriptor - -const file_migration_api_v1_migration_proto_rawDesc = "" + - "\n" + - " migration/api/v1/migration.proto\x12\x15xmtp.migration.api.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1bgoogle/protobuf/empty.proto\"=\n" + - "\x18FetchD14nCutoverResponse\x12!\n" + - "\ftimestamp_ns\x18\x01 \x01(\x04R\vtimestampNs2\x9d\x01\n" + - "\x10D14nMigrationApi\x12\x88\x01\n" + - "\x10FetchD14nCutover\x12\x16.google.protobuf.Empty\x1a/.xmtp.migration.api.v1.FetchD14nCutoverResponse\"+\x82\xd3\xe4\x93\x02%:\x01*\" /mls/v2/payer/fetch-d14n-cutoverB\x8d\x02\n" + - "3org.xmtp.android.library.push.xmtp.migration.api.v1B\x0eMigrationProtoP\x01ZOgithub.com/xmtp/example-notification-server-go/pkg/proto/migration/api/v1;apiv1\xa2\x02\x03XMA\xaa\x02\x15Xmtp.Migration.Api.V1\xca\x02\x15Xmtp\\Migration\\Api\\V1\xe2\x02!Xmtp\\Migration\\Api\\V1\\GPBMetadata\xea\x02\x18Xmtp::Migration::Api::V1b\x06proto3" - -var ( - file_migration_api_v1_migration_proto_rawDescOnce sync.Once - file_migration_api_v1_migration_proto_rawDescData []byte -) - -func file_migration_api_v1_migration_proto_rawDescGZIP() []byte { - file_migration_api_v1_migration_proto_rawDescOnce.Do(func() { - file_migration_api_v1_migration_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_migration_api_v1_migration_proto_rawDesc), len(file_migration_api_v1_migration_proto_rawDesc))) - }) - return file_migration_api_v1_migration_proto_rawDescData -} - -var file_migration_api_v1_migration_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_migration_api_v1_migration_proto_goTypes = []any{ - (*FetchD14NCutoverResponse)(nil), // 0: xmtp.migration.api.v1.FetchD14nCutoverResponse - (*emptypb.Empty)(nil), // 1: google.protobuf.Empty -} -var file_migration_api_v1_migration_proto_depIdxs = []int32{ - 1, // 0: xmtp.migration.api.v1.D14nMigrationApi.FetchD14nCutover:input_type -> google.protobuf.Empty - 0, // 1: xmtp.migration.api.v1.D14nMigrationApi.FetchD14nCutover:output_type -> xmtp.migration.api.v1.FetchD14nCutoverResponse - 1, // [1:2] is the sub-list for method output_type - 0, // [0:1] 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_migration_api_v1_migration_proto_init() } -func file_migration_api_v1_migration_proto_init() { - if File_migration_api_v1_migration_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_migration_api_v1_migration_proto_rawDesc), len(file_migration_api_v1_migration_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_migration_api_v1_migration_proto_goTypes, - DependencyIndexes: file_migration_api_v1_migration_proto_depIdxs, - MessageInfos: file_migration_api_v1_migration_proto_msgTypes, - }.Build() - File_migration_api_v1_migration_proto = out.File - file_migration_api_v1_migration_proto_goTypes = nil - file_migration_api_v1_migration_proto_depIdxs = nil -} diff --git a/pkg/proto/migration/api/v1/migration_grpc.pb.go b/pkg/proto/migration/api/v1/migration_grpc.pb.go deleted file mode 100644 index a36b4565..00000000 --- a/pkg/proto/migration/api/v1/migration_grpc.pb.go +++ /dev/null @@ -1,113 +0,0 @@ -// V3 -> D14n Migration Protos -// These can be removed once migration is complete - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: migration/api/v1/migration.proto - -package apiv1 - -import ( - context "context" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - emptypb "google.golang.org/protobuf/types/known/emptypb" -) - -// 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 ( - D14NMigrationApi_FetchD14NCutover_FullMethodName = "/xmtp.migration.api.v1.D14nMigrationApi/FetchD14nCutover" -) - -// D14NMigrationApiClient is the client API for D14NMigrationApi 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 D14NMigrationApiClient interface { - FetchD14NCutover(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FetchD14NCutoverResponse, error) -} - -type d14NMigrationApiClient struct { - cc grpc.ClientConnInterface -} - -func NewD14NMigrationApiClient(cc grpc.ClientConnInterface) D14NMigrationApiClient { - return &d14NMigrationApiClient{cc} -} - -func (c *d14NMigrationApiClient) FetchD14NCutover(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*FetchD14NCutoverResponse, error) { - out := new(FetchD14NCutoverResponse) - err := c.cc.Invoke(ctx, D14NMigrationApi_FetchD14NCutover_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// D14NMigrationApiServer is the server API for D14NMigrationApi service. -// All implementations must embed UnimplementedD14NMigrationApiServer -// for forward compatibility -type D14NMigrationApiServer interface { - FetchD14NCutover(context.Context, *emptypb.Empty) (*FetchD14NCutoverResponse, error) - mustEmbedUnimplementedD14NMigrationApiServer() -} - -// UnimplementedD14NMigrationApiServer must be embedded to have forward compatible implementations. -type UnimplementedD14NMigrationApiServer struct { -} - -func (UnimplementedD14NMigrationApiServer) FetchD14NCutover(context.Context, *emptypb.Empty) (*FetchD14NCutoverResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method FetchD14NCutover not implemented") -} -func (UnimplementedD14NMigrationApiServer) mustEmbedUnimplementedD14NMigrationApiServer() {} - -// UnsafeD14NMigrationApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to D14NMigrationApiServer will -// result in compilation errors. -type UnsafeD14NMigrationApiServer interface { - mustEmbedUnimplementedD14NMigrationApiServer() -} - -func RegisterD14NMigrationApiServer(s grpc.ServiceRegistrar, srv D14NMigrationApiServer) { - s.RegisterService(&D14NMigrationApi_ServiceDesc, srv) -} - -func _D14NMigrationApi_FetchD14NCutover_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(emptypb.Empty) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(D14NMigrationApiServer).FetchD14NCutover(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: D14NMigrationApi_FetchD14NCutover_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(D14NMigrationApiServer).FetchD14NCutover(ctx, req.(*emptypb.Empty)) - } - return interceptor(ctx, in, info, handler) -} - -// D14NMigrationApi_ServiceDesc is the grpc.ServiceDesc for D14NMigrationApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var D14NMigrationApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.migration.api.v1.D14nMigrationApi", - HandlerType: (*D14NMigrationApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "FetchD14nCutover", - Handler: _D14NMigrationApi_FetchD14NCutover_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "migration/api/v1/migration.proto", -} diff --git a/pkg/proto/mls/api/v1/mls.pb.go b/pkg/proto/mls/api/v1/mls.pb.go deleted file mode 100644 index f0520b62..00000000 --- a/pkg/proto/mls/api/v1/mls.pb.go +++ /dev/null @@ -1,3034 +0,0 @@ -// Message API - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/api/v1/mls.proto - -package apiv1 - -import ( - _ "github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-openapiv2/options" - associations "github.com/xmtp/example-notification-server-go/pkg/proto/identity/associations" - message_contents "github.com/xmtp/example-notification-server-go/pkg/proto/message_contents" - message_contents1 "github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents" - _ "google.golang.org/genproto/googleapis/api/annotations" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - emptypb "google.golang.org/protobuf/types/known/emptypb" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Sort direction for queries -type SortDirection int32 - -const ( - SortDirection_SORT_DIRECTION_UNSPECIFIED SortDirection = 0 - SortDirection_SORT_DIRECTION_ASCENDING SortDirection = 1 - SortDirection_SORT_DIRECTION_DESCENDING SortDirection = 2 -) - -// Enum value maps for SortDirection. -var ( - SortDirection_name = map[int32]string{ - 0: "SORT_DIRECTION_UNSPECIFIED", - 1: "SORT_DIRECTION_ASCENDING", - 2: "SORT_DIRECTION_DESCENDING", - } - SortDirection_value = map[string]int32{ - "SORT_DIRECTION_UNSPECIFIED": 0, - "SORT_DIRECTION_ASCENDING": 1, - "SORT_DIRECTION_DESCENDING": 2, - } -) - -func (x SortDirection) Enum() *SortDirection { - p := new(SortDirection) - *p = x - return p -} - -func (x SortDirection) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (SortDirection) Descriptor() protoreflect.EnumDescriptor { - return file_mls_api_v1_mls_proto_enumTypes[0].Descriptor() -} - -func (SortDirection) Type() protoreflect.EnumType { - return &file_mls_api_v1_mls_proto_enumTypes[0] -} - -func (x SortDirection) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use SortDirection.Descriptor instead. -func (SortDirection) EnumDescriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{0} -} - -// Full representation of a welcome message -type WelcomeMessage struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *WelcomeMessage_V1_ - // *WelcomeMessage_WelcomePointer_ - Version isWelcomeMessage_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomeMessage) Reset() { - *x = WelcomeMessage{} - mi := &file_mls_api_v1_mls_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomeMessage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomeMessage) ProtoMessage() {} - -func (x *WelcomeMessage) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomeMessage.ProtoReflect.Descriptor instead. -func (*WelcomeMessage) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{0} -} - -func (x *WelcomeMessage) GetVersion() isWelcomeMessage_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *WelcomeMessage) GetV1() *WelcomeMessage_V1 { - if x != nil { - if x, ok := x.Version.(*WelcomeMessage_V1_); ok { - return x.V1 - } - } - return nil -} - -func (x *WelcomeMessage) GetWelcomePointer() *WelcomeMessage_WelcomePointer { - if x != nil { - if x, ok := x.Version.(*WelcomeMessage_WelcomePointer_); ok { - return x.WelcomePointer - } - } - return nil -} - -type isWelcomeMessage_Version interface { - isWelcomeMessage_Version() -} - -type WelcomeMessage_V1_ struct { - V1 *WelcomeMessage_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -type WelcomeMessage_WelcomePointer_ struct { - WelcomePointer *WelcomeMessage_WelcomePointer `protobuf:"bytes,2,opt,name=welcome_pointer,json=welcomePointer,proto3,oneof"` -} - -func (*WelcomeMessage_V1_) isWelcomeMessage_Version() {} - -func (*WelcomeMessage_WelcomePointer_) isWelcomeMessage_Version() {} - -// Input type for a welcome message -type WelcomeMessageInput struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *WelcomeMessageInput_V1_ - // *WelcomeMessageInput_WelcomePointer_ - Version isWelcomeMessageInput_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomeMessageInput) Reset() { - *x = WelcomeMessageInput{} - mi := &file_mls_api_v1_mls_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomeMessageInput) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomeMessageInput) ProtoMessage() {} - -func (x *WelcomeMessageInput) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomeMessageInput.ProtoReflect.Descriptor instead. -func (*WelcomeMessageInput) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{1} -} - -func (x *WelcomeMessageInput) GetVersion() isWelcomeMessageInput_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *WelcomeMessageInput) GetV1() *WelcomeMessageInput_V1 { - if x != nil { - if x, ok := x.Version.(*WelcomeMessageInput_V1_); ok { - return x.V1 - } - } - return nil -} - -func (x *WelcomeMessageInput) GetWelcomePointer() *WelcomeMessageInput_WelcomePointer { - if x != nil { - if x, ok := x.Version.(*WelcomeMessageInput_WelcomePointer_); ok { - return x.WelcomePointer - } - } - return nil -} - -type isWelcomeMessageInput_Version interface { - isWelcomeMessageInput_Version() -} - -type WelcomeMessageInput_V1_ struct { - V1 *WelcomeMessageInput_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -type WelcomeMessageInput_WelcomePointer_ struct { - WelcomePointer *WelcomeMessageInput_WelcomePointer `protobuf:"bytes,2,opt,name=welcome_pointer,json=welcomePointer,proto3,oneof"` -} - -func (*WelcomeMessageInput_V1_) isWelcomeMessageInput_Version() {} - -func (*WelcomeMessageInput_WelcomePointer_) isWelcomeMessageInput_Version() {} - -// This field is encrypted along with the `data` field on the welcome message. -type WelcomeMetadata struct { - state protoimpl.MessageState `protogen:"open.v1"` - MessageCursor uint64 `protobuf:"varint,1,opt,name=message_cursor,json=messageCursor,proto3" json:"message_cursor,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomeMetadata) Reset() { - *x = WelcomeMetadata{} - mi := &file_mls_api_v1_mls_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomeMetadata) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomeMetadata) ProtoMessage() {} - -func (x *WelcomeMetadata) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomeMetadata.ProtoReflect.Descriptor instead. -func (*WelcomeMetadata) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{2} -} - -func (x *WelcomeMetadata) GetMessageCursor() uint64 { - if x != nil { - return x.MessageCursor - } - return 0 -} - -// Full representation of a group message -type GroupMessage struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *GroupMessage_V1_ - Version isGroupMessage_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMessage) Reset() { - *x = GroupMessage{} - mi := &file_mls_api_v1_mls_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMessage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMessage) ProtoMessage() {} - -func (x *GroupMessage) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMessage.ProtoReflect.Descriptor instead. -func (*GroupMessage) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{3} -} - -func (x *GroupMessage) GetVersion() isGroupMessage_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *GroupMessage) GetV1() *GroupMessage_V1 { - if x != nil { - if x, ok := x.Version.(*GroupMessage_V1_); ok { - return x.V1 - } - } - return nil -} - -type isGroupMessage_Version interface { - isGroupMessage_Version() -} - -type GroupMessage_V1_ struct { - V1 *GroupMessage_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*GroupMessage_V1_) isGroupMessage_Version() {} - -// Input type for a group message -type GroupMessageInput struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *GroupMessageInput_V1_ - Version isGroupMessageInput_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMessageInput) Reset() { - *x = GroupMessageInput{} - mi := &file_mls_api_v1_mls_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMessageInput) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMessageInput) ProtoMessage() {} - -func (x *GroupMessageInput) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMessageInput.ProtoReflect.Descriptor instead. -func (*GroupMessageInput) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{4} -} - -func (x *GroupMessageInput) GetVersion() isGroupMessageInput_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *GroupMessageInput) GetV1() *GroupMessageInput_V1 { - if x != nil { - if x, ok := x.Version.(*GroupMessageInput_V1_); ok { - return x.V1 - } - } - return nil -} - -type isGroupMessageInput_Version interface { - isGroupMessageInput_Version() -} - -type GroupMessageInput_V1_ struct { - V1 *GroupMessageInput_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*GroupMessageInput_V1_) isGroupMessageInput_Version() {} - -// Send a batch of MLS messages -type SendGroupMessagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Messages []*GroupMessageInput `protobuf:"bytes,1,rep,name=messages,proto3" json:"messages,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SendGroupMessagesRequest) Reset() { - *x = SendGroupMessagesRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SendGroupMessagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SendGroupMessagesRequest) ProtoMessage() {} - -func (x *SendGroupMessagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SendGroupMessagesRequest.ProtoReflect.Descriptor instead. -func (*SendGroupMessagesRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{5} -} - -func (x *SendGroupMessagesRequest) GetMessages() []*GroupMessageInput { - if x != nil { - return x.Messages - } - return nil -} - -// Send a batch of welcome messages -type SendWelcomeMessagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Messages []*WelcomeMessageInput `protobuf:"bytes,1,rep,name=messages,proto3" json:"messages,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SendWelcomeMessagesRequest) Reset() { - *x = SendWelcomeMessagesRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SendWelcomeMessagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SendWelcomeMessagesRequest) ProtoMessage() {} - -func (x *SendWelcomeMessagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SendWelcomeMessagesRequest.ProtoReflect.Descriptor instead. -func (*SendWelcomeMessagesRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{6} -} - -func (x *SendWelcomeMessagesRequest) GetMessages() []*WelcomeMessageInput { - if x != nil { - return x.Messages - } - return nil -} - -// A wrapper around the Key Package bytes -type KeyPackageUpload struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The owner's wallet address would be extracted from the identity - // credential in the key package, and all signatures would be validated. - KeyPackageTlsSerialized []byte `protobuf:"bytes,1,opt,name=key_package_tls_serialized,json=keyPackageTlsSerialized,proto3" json:"key_package_tls_serialized,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *KeyPackageUpload) Reset() { - *x = KeyPackageUpload{} - mi := &file_mls_api_v1_mls_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *KeyPackageUpload) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*KeyPackageUpload) ProtoMessage() {} - -func (x *KeyPackageUpload) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use KeyPackageUpload.ProtoReflect.Descriptor instead. -func (*KeyPackageUpload) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{7} -} - -func (x *KeyPackageUpload) GetKeyPackageTlsSerialized() []byte { - if x != nil { - return x.KeyPackageTlsSerialized - } - return nil -} - -// Register a new installation -type RegisterInstallationRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The Key Package contains all information needed to register an installation - KeyPackage *KeyPackageUpload `protobuf:"bytes,1,opt,name=key_package,json=keyPackage,proto3" json:"key_package,omitempty"` - IsInboxIdCredential bool `protobuf:"varint,2,opt,name=is_inbox_id_credential,json=isInboxIdCredential,proto3" json:"is_inbox_id_credential,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RegisterInstallationRequest) Reset() { - *x = RegisterInstallationRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RegisterInstallationRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RegisterInstallationRequest) ProtoMessage() {} - -func (x *RegisterInstallationRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RegisterInstallationRequest.ProtoReflect.Descriptor instead. -func (*RegisterInstallationRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{8} -} - -func (x *RegisterInstallationRequest) GetKeyPackage() *KeyPackageUpload { - if x != nil { - return x.KeyPackage - } - return nil -} - -func (x *RegisterInstallationRequest) GetIsInboxIdCredential() bool { - if x != nil { - return x.IsInboxIdCredential - } - return false -} - -// The response to a RegisterInstallationRequest -type RegisterInstallationResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RegisterInstallationResponse) Reset() { - *x = RegisterInstallationResponse{} - mi := &file_mls_api_v1_mls_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RegisterInstallationResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RegisterInstallationResponse) ProtoMessage() {} - -func (x *RegisterInstallationResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RegisterInstallationResponse.ProtoReflect.Descriptor instead. -func (*RegisterInstallationResponse) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{9} -} - -func (x *RegisterInstallationResponse) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -// Upload a new key packages -type UploadKeyPackageRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - // An individual key package upload request - KeyPackage *KeyPackageUpload `protobuf:"bytes,1,opt,name=key_package,json=keyPackage,proto3" json:"key_package,omitempty"` - IsInboxIdCredential bool `protobuf:"varint,2,opt,name=is_inbox_id_credential,json=isInboxIdCredential,proto3" json:"is_inbox_id_credential,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UploadKeyPackageRequest) Reset() { - *x = UploadKeyPackageRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UploadKeyPackageRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UploadKeyPackageRequest) ProtoMessage() {} - -func (x *UploadKeyPackageRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UploadKeyPackageRequest.ProtoReflect.Descriptor instead. -func (*UploadKeyPackageRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{10} -} - -func (x *UploadKeyPackageRequest) GetKeyPackage() *KeyPackageUpload { - if x != nil { - return x.KeyPackage - } - return nil -} - -func (x *UploadKeyPackageRequest) GetIsInboxIdCredential() bool { - if x != nil { - return x.IsInboxIdCredential - } - return false -} - -// Fetch one or more key packages -type FetchKeyPackagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The caller can provide an array of installation keys, and the API - // will return one key package for each installation associated with each - // installation key - InstallationKeys [][]byte `protobuf:"bytes,1,rep,name=installation_keys,json=installationKeys,proto3" json:"installation_keys,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *FetchKeyPackagesRequest) Reset() { - *x = FetchKeyPackagesRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *FetchKeyPackagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*FetchKeyPackagesRequest) ProtoMessage() {} - -func (x *FetchKeyPackagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use FetchKeyPackagesRequest.ProtoReflect.Descriptor instead. -func (*FetchKeyPackagesRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{11} -} - -func (x *FetchKeyPackagesRequest) GetInstallationKeys() [][]byte { - if x != nil { - return x.InstallationKeys - } - return nil -} - -// The response to a FetchKeyPackagesRequest -type FetchKeyPackagesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Returns one key package per installation in the original order of the - // request. If any installations are missing key packages, an empty entry is - // left in their respective spots in the array. - KeyPackages []*FetchKeyPackagesResponse_KeyPackage `protobuf:"bytes,1,rep,name=key_packages,json=keyPackages,proto3" json:"key_packages,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *FetchKeyPackagesResponse) Reset() { - *x = FetchKeyPackagesResponse{} - mi := &file_mls_api_v1_mls_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *FetchKeyPackagesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*FetchKeyPackagesResponse) ProtoMessage() {} - -func (x *FetchKeyPackagesResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[12] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use FetchKeyPackagesResponse.ProtoReflect.Descriptor instead. -func (*FetchKeyPackagesResponse) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{12} -} - -func (x *FetchKeyPackagesResponse) GetKeyPackages() []*FetchKeyPackagesResponse_KeyPackage { - if x != nil { - return x.KeyPackages - } - return nil -} - -// Revoke an installation -type RevokeInstallationRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - // All revocations must be validated with a wallet signature over the - // installation_id being revoked (and some sort of standard prologue) - WalletSignature *message_contents.Signature `protobuf:"bytes,2,opt,name=wallet_signature,json=walletSignature,proto3" json:"wallet_signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RevokeInstallationRequest) Reset() { - *x = RevokeInstallationRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RevokeInstallationRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RevokeInstallationRequest) ProtoMessage() {} - -func (x *RevokeInstallationRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[13] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RevokeInstallationRequest.ProtoReflect.Descriptor instead. -func (*RevokeInstallationRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{13} -} - -func (x *RevokeInstallationRequest) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *RevokeInstallationRequest) GetWalletSignature() *message_contents.Signature { - if x != nil { - return x.WalletSignature - } - return nil -} - -// Get all updates for an identity since the specified time -type GetIdentityUpdatesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - AccountAddresses []string `protobuf:"bytes,1,rep,name=account_addresses,json=accountAddresses,proto3" json:"account_addresses,omitempty"` - StartTimeNs uint64 `protobuf:"varint,2,opt,name=start_time_ns,json=startTimeNs,proto3" json:"start_time_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesRequest) Reset() { - *x = GetIdentityUpdatesRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesRequest) ProtoMessage() {} - -func (x *GetIdentityUpdatesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[14] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesRequest.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{14} -} - -func (x *GetIdentityUpdatesRequest) GetAccountAddresses() []string { - if x != nil { - return x.AccountAddresses - } - return nil -} - -func (x *GetIdentityUpdatesRequest) GetStartTimeNs() uint64 { - if x != nil { - return x.StartTimeNs - } - return 0 -} - -// Used to get any new or revoked installations for a list of wallet addresses -type GetIdentityUpdatesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - // A list of updates (or empty objects if no changes) in the original order - // of the request - Updates []*GetIdentityUpdatesResponse_WalletUpdates `protobuf:"bytes,1,rep,name=updates,proto3" json:"updates,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesResponse) Reset() { - *x = GetIdentityUpdatesResponse{} - mi := &file_mls_api_v1_mls_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesResponse) ProtoMessage() {} - -func (x *GetIdentityUpdatesResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[15] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesResponse.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesResponse) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{15} -} - -func (x *GetIdentityUpdatesResponse) GetUpdates() []*GetIdentityUpdatesResponse_WalletUpdates { - if x != nil { - return x.Updates - } - return nil -} - -// Pagination config for queries -type PagingInfo struct { - state protoimpl.MessageState `protogen:"open.v1"` - Direction SortDirection `protobuf:"varint,1,opt,name=direction,proto3,enum=xmtp.mls.api.v1.SortDirection" json:"direction,omitempty"` - Limit uint32 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"` - IdCursor uint64 `protobuf:"varint,3,opt,name=id_cursor,json=idCursor,proto3" json:"id_cursor,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PagingInfo) Reset() { - *x = PagingInfo{} - mi := &file_mls_api_v1_mls_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PagingInfo) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PagingInfo) ProtoMessage() {} - -func (x *PagingInfo) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[16] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PagingInfo.ProtoReflect.Descriptor instead. -func (*PagingInfo) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{16} -} - -func (x *PagingInfo) GetDirection() SortDirection { - if x != nil { - return x.Direction - } - return SortDirection_SORT_DIRECTION_UNSPECIFIED -} - -func (x *PagingInfo) GetLimit() uint32 { - if x != nil { - return x.Limit - } - return 0 -} - -func (x *PagingInfo) GetIdCursor() uint64 { - if x != nil { - return x.IdCursor - } - return 0 -} - -// Request for group message queries -type QueryGroupMessagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupId []byte `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,2,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryGroupMessagesRequest) Reset() { - *x = QueryGroupMessagesRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryGroupMessagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryGroupMessagesRequest) ProtoMessage() {} - -func (x *QueryGroupMessagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[17] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryGroupMessagesRequest.ProtoReflect.Descriptor instead. -func (*QueryGroupMessagesRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{17} -} - -func (x *QueryGroupMessagesRequest) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *QueryGroupMessagesRequest) GetPagingInfo() *PagingInfo { - if x != nil { - return x.PagingInfo - } - return nil -} - -// Response for group message queries -type QueryGroupMessagesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Messages []*GroupMessage `protobuf:"bytes,1,rep,name=messages,proto3" json:"messages,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,2,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryGroupMessagesResponse) Reset() { - *x = QueryGroupMessagesResponse{} - mi := &file_mls_api_v1_mls_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryGroupMessagesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryGroupMessagesResponse) ProtoMessage() {} - -func (x *QueryGroupMessagesResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[18] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryGroupMessagesResponse.ProtoReflect.Descriptor instead. -func (*QueryGroupMessagesResponse) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{18} -} - -func (x *QueryGroupMessagesResponse) GetMessages() []*GroupMessage { - if x != nil { - return x.Messages - } - return nil -} - -func (x *QueryGroupMessagesResponse) GetPagingInfo() *PagingInfo { - if x != nil { - return x.PagingInfo - } - return nil -} - -// Request for welcome message queries -type QueryWelcomeMessagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,2,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryWelcomeMessagesRequest) Reset() { - *x = QueryWelcomeMessagesRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryWelcomeMessagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryWelcomeMessagesRequest) ProtoMessage() {} - -func (x *QueryWelcomeMessagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[19] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryWelcomeMessagesRequest.ProtoReflect.Descriptor instead. -func (*QueryWelcomeMessagesRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{19} -} - -func (x *QueryWelcomeMessagesRequest) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *QueryWelcomeMessagesRequest) GetPagingInfo() *PagingInfo { - if x != nil { - return x.PagingInfo - } - return nil -} - -// Response for welcome message queries -type QueryWelcomeMessagesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Messages []*WelcomeMessage `protobuf:"bytes,1,rep,name=messages,proto3" json:"messages,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,2,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryWelcomeMessagesResponse) Reset() { - *x = QueryWelcomeMessagesResponse{} - mi := &file_mls_api_v1_mls_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryWelcomeMessagesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryWelcomeMessagesResponse) ProtoMessage() {} - -func (x *QueryWelcomeMessagesResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[20] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryWelcomeMessagesResponse.ProtoReflect.Descriptor instead. -func (*QueryWelcomeMessagesResponse) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{20} -} - -func (x *QueryWelcomeMessagesResponse) GetMessages() []*WelcomeMessage { - if x != nil { - return x.Messages - } - return nil -} - -func (x *QueryWelcomeMessagesResponse) GetPagingInfo() *PagingInfo { - if x != nil { - return x.PagingInfo - } - return nil -} - -// Request for subscribing to group messages -type SubscribeGroupMessagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Filters []*SubscribeGroupMessagesRequest_Filter `protobuf:"bytes,1,rep,name=filters,proto3" json:"filters,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeGroupMessagesRequest) Reset() { - *x = SubscribeGroupMessagesRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeGroupMessagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeGroupMessagesRequest) ProtoMessage() {} - -func (x *SubscribeGroupMessagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[21] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeGroupMessagesRequest.ProtoReflect.Descriptor instead. -func (*SubscribeGroupMessagesRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{21} -} - -func (x *SubscribeGroupMessagesRequest) GetFilters() []*SubscribeGroupMessagesRequest_Filter { - if x != nil { - return x.Filters - } - return nil -} - -// Request for subscribing to welcome messages -type SubscribeWelcomeMessagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Filters []*SubscribeWelcomeMessagesRequest_Filter `protobuf:"bytes,1,rep,name=filters,proto3" json:"filters,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeWelcomeMessagesRequest) Reset() { - *x = SubscribeWelcomeMessagesRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeWelcomeMessagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeWelcomeMessagesRequest) ProtoMessage() {} - -func (x *SubscribeWelcomeMessagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[22] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeWelcomeMessagesRequest.ProtoReflect.Descriptor instead. -func (*SubscribeWelcomeMessagesRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{22} -} - -func (x *SubscribeWelcomeMessagesRequest) GetFilters() []*SubscribeWelcomeMessagesRequest_Filter { - if x != nil { - return x.Filters - } - return nil -} - -type BatchPublishCommitLogRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*PublishCommitLogRequest `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BatchPublishCommitLogRequest) Reset() { - *x = BatchPublishCommitLogRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BatchPublishCommitLogRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BatchPublishCommitLogRequest) ProtoMessage() {} - -func (x *BatchPublishCommitLogRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[23] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BatchPublishCommitLogRequest.ProtoReflect.Descriptor instead. -func (*BatchPublishCommitLogRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{23} -} - -func (x *BatchPublishCommitLogRequest) GetRequests() []*PublishCommitLogRequest { - if x != nil { - return x.Requests - } - return nil -} - -type PublishCommitLogRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupId []byte `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - SerializedCommitLogEntry []byte `protobuf:"bytes,2,opt,name=serialized_commit_log_entry,json=serializedCommitLogEntry,proto3" json:"serialized_commit_log_entry,omitempty"` - Signature *associations.RecoverableEd25519Signature `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishCommitLogRequest) Reset() { - *x = PublishCommitLogRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishCommitLogRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishCommitLogRequest) ProtoMessage() {} - -func (x *PublishCommitLogRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[24] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishCommitLogRequest.ProtoReflect.Descriptor instead. -func (*PublishCommitLogRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{24} -} - -func (x *PublishCommitLogRequest) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *PublishCommitLogRequest) GetSerializedCommitLogEntry() []byte { - if x != nil { - return x.SerializedCommitLogEntry - } - return nil -} - -func (x *PublishCommitLogRequest) GetSignature() *associations.RecoverableEd25519Signature { - if x != nil { - return x.Signature - } - return nil -} - -type QueryCommitLogRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupId []byte `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,2,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryCommitLogRequest) Reset() { - *x = QueryCommitLogRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryCommitLogRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryCommitLogRequest) ProtoMessage() {} - -func (x *QueryCommitLogRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[25] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryCommitLogRequest.ProtoReflect.Descriptor instead. -func (*QueryCommitLogRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{25} -} - -func (x *QueryCommitLogRequest) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *QueryCommitLogRequest) GetPagingInfo() *PagingInfo { - if x != nil { - return x.PagingInfo - } - return nil -} - -type QueryCommitLogResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupId []byte `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - CommitLogEntries []*message_contents1.CommitLogEntry `protobuf:"bytes,2,rep,name=commit_log_entries,json=commitLogEntries,proto3" json:"commit_log_entries,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,3,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryCommitLogResponse) Reset() { - *x = QueryCommitLogResponse{} - mi := &file_mls_api_v1_mls_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryCommitLogResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryCommitLogResponse) ProtoMessage() {} - -func (x *QueryCommitLogResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[26] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryCommitLogResponse.ProtoReflect.Descriptor instead. -func (*QueryCommitLogResponse) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{26} -} - -func (x *QueryCommitLogResponse) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *QueryCommitLogResponse) GetCommitLogEntries() []*message_contents1.CommitLogEntry { - if x != nil { - return x.CommitLogEntries - } - return nil -} - -func (x *QueryCommitLogResponse) GetPagingInfo() *PagingInfo { - if x != nil { - return x.PagingInfo - } - return nil -} - -type BatchQueryCommitLogRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*QueryCommitLogRequest `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BatchQueryCommitLogRequest) Reset() { - *x = BatchQueryCommitLogRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BatchQueryCommitLogRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BatchQueryCommitLogRequest) ProtoMessage() {} - -func (x *BatchQueryCommitLogRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[27] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BatchQueryCommitLogRequest.ProtoReflect.Descriptor instead. -func (*BatchQueryCommitLogRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{27} -} - -func (x *BatchQueryCommitLogRequest) GetRequests() []*QueryCommitLogRequest { - if x != nil { - return x.Requests - } - return nil -} - -type BatchQueryCommitLogResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*QueryCommitLogResponse `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BatchQueryCommitLogResponse) Reset() { - *x = BatchQueryCommitLogResponse{} - mi := &file_mls_api_v1_mls_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BatchQueryCommitLogResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BatchQueryCommitLogResponse) ProtoMessage() {} - -func (x *BatchQueryCommitLogResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[28] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BatchQueryCommitLogResponse.ProtoReflect.Descriptor instead. -func (*BatchQueryCommitLogResponse) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{28} -} - -func (x *BatchQueryCommitLogResponse) GetResponses() []*QueryCommitLogResponse { - if x != nil { - return x.Responses - } - return nil -} - -// Request to get the newest group message from a range of topics -type GetNewestGroupMessageRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Get the newest message from each of these topics - GroupIds [][]byte `protobuf:"bytes,1,rep,name=group_ids,json=groupIds,proto3" json:"group_ids,omitempty"` - IncludeContent bool `protobuf:"varint,2,opt,name=include_content,json=includeContent,proto3" json:"include_content,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetNewestGroupMessageRequest) Reset() { - *x = GetNewestGroupMessageRequest{} - mi := &file_mls_api_v1_mls_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetNewestGroupMessageRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetNewestGroupMessageRequest) ProtoMessage() {} - -func (x *GetNewestGroupMessageRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[29] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetNewestGroupMessageRequest.ProtoReflect.Descriptor instead. -func (*GetNewestGroupMessageRequest) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{29} -} - -func (x *GetNewestGroupMessageRequest) GetGroupIds() [][]byte { - if x != nil { - return x.GroupIds - } - return nil -} - -func (x *GetNewestGroupMessageRequest) GetIncludeContent() bool { - if x != nil { - return x.IncludeContent - } - return false -} - -// Returns a list of responses that will always be the same length as the -// request -type GetNewestGroupMessageResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*GetNewestGroupMessageResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetNewestGroupMessageResponse) Reset() { - *x = GetNewestGroupMessageResponse{} - mi := &file_mls_api_v1_mls_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetNewestGroupMessageResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetNewestGroupMessageResponse) ProtoMessage() {} - -func (x *GetNewestGroupMessageResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[30] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetNewestGroupMessageResponse.ProtoReflect.Descriptor instead. -func (*GetNewestGroupMessageResponse) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{30} -} - -func (x *GetNewestGroupMessageResponse) GetResponses() []*GetNewestGroupMessageResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -// Version 1 of the WelcomeMessage format -type WelcomeMessage_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` - CreatedNs uint64 `protobuf:"varint,2,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - InstallationKey []byte `protobuf:"bytes,3,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - Data []byte `protobuf:"bytes,4,opt,name=data,proto3" json:"data,omitempty"` - HpkePublicKey []byte `protobuf:"bytes,5,opt,name=hpke_public_key,json=hpkePublicKey,proto3" json:"hpke_public_key,omitempty"` - WrapperAlgorithm message_contents1.WelcomeWrapperAlgorithm `protobuf:"varint,6,opt,name=wrapper_algorithm,json=wrapperAlgorithm,proto3,enum=xmtp.mls.message_contents.WelcomeWrapperAlgorithm" json:"wrapper_algorithm,omitempty"` - WelcomeMetadata []byte `protobuf:"bytes,7,opt,name=welcome_metadata,json=welcomeMetadata,proto3" json:"welcome_metadata,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomeMessage_V1) Reset() { - *x = WelcomeMessage_V1{} - mi := &file_mls_api_v1_mls_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomeMessage_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomeMessage_V1) ProtoMessage() {} - -func (x *WelcomeMessage_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[31] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomeMessage_V1.ProtoReflect.Descriptor instead. -func (*WelcomeMessage_V1) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *WelcomeMessage_V1) GetId() uint64 { - if x != nil { - return x.Id - } - return 0 -} - -func (x *WelcomeMessage_V1) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *WelcomeMessage_V1) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *WelcomeMessage_V1) GetData() []byte { - if x != nil { - return x.Data - } - return nil -} - -func (x *WelcomeMessage_V1) GetHpkePublicKey() []byte { - if x != nil { - return x.HpkePublicKey - } - return nil -} - -func (x *WelcomeMessage_V1) GetWrapperAlgorithm() message_contents1.WelcomeWrapperAlgorithm { - if x != nil { - return x.WrapperAlgorithm - } - return message_contents1.WelcomeWrapperAlgorithm(0) -} - -func (x *WelcomeMessage_V1) GetWelcomeMetadata() []byte { - if x != nil { - return x.WelcomeMetadata - } - return nil -} - -type WelcomeMessage_WelcomePointer struct { - state protoimpl.MessageState `protogen:"open.v1"` - Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` - CreatedNs uint64 `protobuf:"varint,2,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - // The topic of the welcome message (generally the installation id) - InstallationKey []byte `protobuf:"bytes,3,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - // A WelcomePointer encrypted using the algorithm specified by - // wrapper_algorithm - WelcomePointer []byte `protobuf:"bytes,4,opt,name=welcome_pointer,json=welcomePointer,proto3" json:"welcome_pointer,omitempty"` - // The public key used to encrypt the welcome pointer - HpkePublicKey []byte `protobuf:"bytes,5,opt,name=hpke_public_key,json=hpkePublicKey,proto3" json:"hpke_public_key,omitempty"` - // The algorithm used to encrypt the welcome pointer - WrapperAlgorithm message_contents1.WelcomePointerWrapperAlgorithm `protobuf:"varint,6,opt,name=wrapper_algorithm,json=wrapperAlgorithm,proto3,enum=xmtp.mls.message_contents.WelcomePointerWrapperAlgorithm" json:"wrapper_algorithm,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomeMessage_WelcomePointer) Reset() { - *x = WelcomeMessage_WelcomePointer{} - mi := &file_mls_api_v1_mls_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomeMessage_WelcomePointer) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomeMessage_WelcomePointer) ProtoMessage() {} - -func (x *WelcomeMessage_WelcomePointer) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[32] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomeMessage_WelcomePointer.ProtoReflect.Descriptor instead. -func (*WelcomeMessage_WelcomePointer) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{0, 1} -} - -func (x *WelcomeMessage_WelcomePointer) GetId() uint64 { - if x != nil { - return x.Id - } - return 0 -} - -func (x *WelcomeMessage_WelcomePointer) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *WelcomeMessage_WelcomePointer) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *WelcomeMessage_WelcomePointer) GetWelcomePointer() []byte { - if x != nil { - return x.WelcomePointer - } - return nil -} - -func (x *WelcomeMessage_WelcomePointer) GetHpkePublicKey() []byte { - if x != nil { - return x.HpkePublicKey - } - return nil -} - -func (x *WelcomeMessage_WelcomePointer) GetWrapperAlgorithm() message_contents1.WelcomePointerWrapperAlgorithm { - if x != nil { - return x.WrapperAlgorithm - } - return message_contents1.WelcomePointerWrapperAlgorithm(0) -} - -// Version 1 of the WelcomeMessageInput format, if used as the pointee of a -// WelcomePointer then the hpke_public_key will be unset, and the -// wrapper_algorithm will be WELCOME_WRAPPER_ALGORITHM_SYMMETRIC_KEY -type WelcomeMessageInput_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The topic of the welcome message (generally the installation id) - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - // An encrypted mls `Welcome` struct - Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` - // The public key of the welcome message - HpkePublicKey []byte `protobuf:"bytes,3,opt,name=hpke_public_key,json=hpkePublicKey,proto3" json:"hpke_public_key,omitempty"` - // The algorithm used to encrypt the welcome message - WrapperAlgorithm message_contents1.WelcomeWrapperAlgorithm `protobuf:"varint,4,opt,name=wrapper_algorithm,json=wrapperAlgorithm,proto3,enum=xmtp.mls.message_contents.WelcomeWrapperAlgorithm" json:"wrapper_algorithm,omitempty"` - // The metadata of the welcome message - WelcomeMetadata []byte `protobuf:"bytes,7,opt,name=welcome_metadata,json=welcomeMetadata,proto3" json:"welcome_metadata,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomeMessageInput_V1) Reset() { - *x = WelcomeMessageInput_V1{} - mi := &file_mls_api_v1_mls_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomeMessageInput_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomeMessageInput_V1) ProtoMessage() {} - -func (x *WelcomeMessageInput_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[33] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomeMessageInput_V1.ProtoReflect.Descriptor instead. -func (*WelcomeMessageInput_V1) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{1, 0} -} - -func (x *WelcomeMessageInput_V1) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *WelcomeMessageInput_V1) GetData() []byte { - if x != nil { - return x.Data - } - return nil -} - -func (x *WelcomeMessageInput_V1) GetHpkePublicKey() []byte { - if x != nil { - return x.HpkePublicKey - } - return nil -} - -func (x *WelcomeMessageInput_V1) GetWrapperAlgorithm() message_contents1.WelcomeWrapperAlgorithm { - if x != nil { - return x.WrapperAlgorithm - } - return message_contents1.WelcomeWrapperAlgorithm(0) -} - -func (x *WelcomeMessageInput_V1) GetWelcomeMetadata() []byte { - if x != nil { - return x.WelcomeMetadata - } - return nil -} - -// Version 2 of the WelcomeMessageInput format which uses a WelcomePointer -// to point to the welcome message for several installations at once -type WelcomeMessageInput_WelcomePointer struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The topic of the welcome message (generally the installation id) - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - // A WelcomePointer encrypted using the wrapper_algorithm - WelcomePointer []byte `protobuf:"bytes,2,opt,name=welcome_pointer,json=welcomePointer,proto3" json:"welcome_pointer,omitempty"` - // The public key used to encrypt the welcome pointer - HpkePublicKey []byte `protobuf:"bytes,3,opt,name=hpke_public_key,json=hpkePublicKey,proto3" json:"hpke_public_key,omitempty"` - // The algorithm used to encrypt the welcome pointer - WrapperAlgorithm message_contents1.WelcomePointerWrapperAlgorithm `protobuf:"varint,4,opt,name=wrapper_algorithm,json=wrapperAlgorithm,proto3,enum=xmtp.mls.message_contents.WelcomePointerWrapperAlgorithm" json:"wrapper_algorithm,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomeMessageInput_WelcomePointer) Reset() { - *x = WelcomeMessageInput_WelcomePointer{} - mi := &file_mls_api_v1_mls_proto_msgTypes[34] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomeMessageInput_WelcomePointer) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomeMessageInput_WelcomePointer) ProtoMessage() {} - -func (x *WelcomeMessageInput_WelcomePointer) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[34] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomeMessageInput_WelcomePointer.ProtoReflect.Descriptor instead. -func (*WelcomeMessageInput_WelcomePointer) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{1, 1} -} - -func (x *WelcomeMessageInput_WelcomePointer) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *WelcomeMessageInput_WelcomePointer) GetWelcomePointer() []byte { - if x != nil { - return x.WelcomePointer - } - return nil -} - -func (x *WelcomeMessageInput_WelcomePointer) GetHpkePublicKey() []byte { - if x != nil { - return x.HpkePublicKey - } - return nil -} - -func (x *WelcomeMessageInput_WelcomePointer) GetWrapperAlgorithm() message_contents1.WelcomePointerWrapperAlgorithm { - if x != nil { - return x.WrapperAlgorithm - } - return message_contents1.WelcomePointerWrapperAlgorithm(0) -} - -// Version 1 of the GroupMessage format -type GroupMessage_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` - CreatedNs uint64 `protobuf:"varint,2,opt,name=created_ns,json=createdNs,proto3" json:"created_ns,omitempty"` - GroupId []byte `protobuf:"bytes,3,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - Data []byte `protobuf:"bytes,4,opt,name=data,proto3" json:"data,omitempty"` - SenderHmac []byte `protobuf:"bytes,5,opt,name=sender_hmac,json=senderHmac,proto3" json:"sender_hmac,omitempty"` - ShouldPush bool `protobuf:"varint,6,opt,name=should_push,json=shouldPush,proto3" json:"should_push,omitempty"` - IsCommit bool `protobuf:"varint,7,opt,name=is_commit,json=isCommit,proto3" json:"is_commit,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMessage_V1) Reset() { - *x = GroupMessage_V1{} - mi := &file_mls_api_v1_mls_proto_msgTypes[35] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMessage_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMessage_V1) ProtoMessage() {} - -func (x *GroupMessage_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[35] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMessage_V1.ProtoReflect.Descriptor instead. -func (*GroupMessage_V1) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{3, 0} -} - -func (x *GroupMessage_V1) GetId() uint64 { - if x != nil { - return x.Id - } - return 0 -} - -func (x *GroupMessage_V1) GetCreatedNs() uint64 { - if x != nil { - return x.CreatedNs - } - return 0 -} - -func (x *GroupMessage_V1) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *GroupMessage_V1) GetData() []byte { - if x != nil { - return x.Data - } - return nil -} - -func (x *GroupMessage_V1) GetSenderHmac() []byte { - if x != nil { - return x.SenderHmac - } - return nil -} - -func (x *GroupMessage_V1) GetShouldPush() bool { - if x != nil { - return x.ShouldPush - } - return false -} - -func (x *GroupMessage_V1) GetIsCommit() bool { - if x != nil { - return x.IsCommit - } - return false -} - -// Version 1 of the GroupMessageInput payload format -type GroupMessageInput_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` // Serialized MlsProtocolMessage - SenderHmac []byte `protobuf:"bytes,2,opt,name=sender_hmac,json=senderHmac,proto3" json:"sender_hmac,omitempty"` - ShouldPush bool `protobuf:"varint,3,opt,name=should_push,json=shouldPush,proto3" json:"should_push,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMessageInput_V1) Reset() { - *x = GroupMessageInput_V1{} - mi := &file_mls_api_v1_mls_proto_msgTypes[36] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMessageInput_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMessageInput_V1) ProtoMessage() {} - -func (x *GroupMessageInput_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[36] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMessageInput_V1.ProtoReflect.Descriptor instead. -func (*GroupMessageInput_V1) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{4, 0} -} - -func (x *GroupMessageInput_V1) GetData() []byte { - if x != nil { - return x.Data - } - return nil -} - -func (x *GroupMessageInput_V1) GetSenderHmac() []byte { - if x != nil { - return x.SenderHmac - } - return nil -} - -func (x *GroupMessageInput_V1) GetShouldPush() bool { - if x != nil { - return x.ShouldPush - } - return false -} - -// An individual key package -type FetchKeyPackagesResponse_KeyPackage struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyPackageTlsSerialized []byte `protobuf:"bytes,1,opt,name=key_package_tls_serialized,json=keyPackageTlsSerialized,proto3" json:"key_package_tls_serialized,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *FetchKeyPackagesResponse_KeyPackage) Reset() { - *x = FetchKeyPackagesResponse_KeyPackage{} - mi := &file_mls_api_v1_mls_proto_msgTypes[37] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *FetchKeyPackagesResponse_KeyPackage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*FetchKeyPackagesResponse_KeyPackage) ProtoMessage() {} - -func (x *FetchKeyPackagesResponse_KeyPackage) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[37] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use FetchKeyPackagesResponse_KeyPackage.ProtoReflect.Descriptor instead. -func (*FetchKeyPackagesResponse_KeyPackage) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{12, 0} -} - -func (x *FetchKeyPackagesResponse_KeyPackage) GetKeyPackageTlsSerialized() []byte { - if x != nil { - return x.KeyPackageTlsSerialized - } - return nil -} - -// A new installation key was seen for the first time by the nodes -type GetIdentityUpdatesResponse_NewInstallationUpdate struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - CredentialIdentity []byte `protobuf:"bytes,2,opt,name=credential_identity,json=credentialIdentity,proto3" json:"credential_identity,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesResponse_NewInstallationUpdate) Reset() { - *x = GetIdentityUpdatesResponse_NewInstallationUpdate{} - mi := &file_mls_api_v1_mls_proto_msgTypes[38] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesResponse_NewInstallationUpdate) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesResponse_NewInstallationUpdate) ProtoMessage() {} - -func (x *GetIdentityUpdatesResponse_NewInstallationUpdate) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[38] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesResponse_NewInstallationUpdate.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesResponse_NewInstallationUpdate) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{15, 0} -} - -func (x *GetIdentityUpdatesResponse_NewInstallationUpdate) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *GetIdentityUpdatesResponse_NewInstallationUpdate) GetCredentialIdentity() []byte { - if x != nil { - return x.CredentialIdentity - } - return nil -} - -// An installation was revoked -type GetIdentityUpdatesResponse_RevokedInstallationUpdate struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesResponse_RevokedInstallationUpdate) Reset() { - *x = GetIdentityUpdatesResponse_RevokedInstallationUpdate{} - mi := &file_mls_api_v1_mls_proto_msgTypes[39] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesResponse_RevokedInstallationUpdate) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesResponse_RevokedInstallationUpdate) ProtoMessage() {} - -func (x *GetIdentityUpdatesResponse_RevokedInstallationUpdate) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[39] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesResponse_RevokedInstallationUpdate.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesResponse_RevokedInstallationUpdate) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{15, 1} -} - -func (x *GetIdentityUpdatesResponse_RevokedInstallationUpdate) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -// A wrapper for any update to the wallet -type GetIdentityUpdatesResponse_Update struct { - state protoimpl.MessageState `protogen:"open.v1"` - TimestampNs uint64 `protobuf:"varint,1,opt,name=timestamp_ns,json=timestampNs,proto3" json:"timestamp_ns,omitempty"` - // Types that are valid to be assigned to Kind: - // - // *GetIdentityUpdatesResponse_Update_NewInstallation - // *GetIdentityUpdatesResponse_Update_RevokedInstallation - Kind isGetIdentityUpdatesResponse_Update_Kind `protobuf_oneof:"kind"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesResponse_Update) Reset() { - *x = GetIdentityUpdatesResponse_Update{} - mi := &file_mls_api_v1_mls_proto_msgTypes[40] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesResponse_Update) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesResponse_Update) ProtoMessage() {} - -func (x *GetIdentityUpdatesResponse_Update) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[40] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesResponse_Update.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesResponse_Update) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{15, 2} -} - -func (x *GetIdentityUpdatesResponse_Update) GetTimestampNs() uint64 { - if x != nil { - return x.TimestampNs - } - return 0 -} - -func (x *GetIdentityUpdatesResponse_Update) GetKind() isGetIdentityUpdatesResponse_Update_Kind { - if x != nil { - return x.Kind - } - return nil -} - -func (x *GetIdentityUpdatesResponse_Update) GetNewInstallation() *GetIdentityUpdatesResponse_NewInstallationUpdate { - if x != nil { - if x, ok := x.Kind.(*GetIdentityUpdatesResponse_Update_NewInstallation); ok { - return x.NewInstallation - } - } - return nil -} - -func (x *GetIdentityUpdatesResponse_Update) GetRevokedInstallation() *GetIdentityUpdatesResponse_RevokedInstallationUpdate { - if x != nil { - if x, ok := x.Kind.(*GetIdentityUpdatesResponse_Update_RevokedInstallation); ok { - return x.RevokedInstallation - } - } - return nil -} - -type isGetIdentityUpdatesResponse_Update_Kind interface { - isGetIdentityUpdatesResponse_Update_Kind() -} - -type GetIdentityUpdatesResponse_Update_NewInstallation struct { - NewInstallation *GetIdentityUpdatesResponse_NewInstallationUpdate `protobuf:"bytes,2,opt,name=new_installation,json=newInstallation,proto3,oneof"` -} - -type GetIdentityUpdatesResponse_Update_RevokedInstallation struct { - RevokedInstallation *GetIdentityUpdatesResponse_RevokedInstallationUpdate `protobuf:"bytes,3,opt,name=revoked_installation,json=revokedInstallation,proto3,oneof"` -} - -func (*GetIdentityUpdatesResponse_Update_NewInstallation) isGetIdentityUpdatesResponse_Update_Kind() { -} - -func (*GetIdentityUpdatesResponse_Update_RevokedInstallation) isGetIdentityUpdatesResponse_Update_Kind() { -} - -// A wrapper for the updates for a single wallet -type GetIdentityUpdatesResponse_WalletUpdates struct { - state protoimpl.MessageState `protogen:"open.v1"` - Updates []*GetIdentityUpdatesResponse_Update `protobuf:"bytes,1,rep,name=updates,proto3" json:"updates,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetIdentityUpdatesResponse_WalletUpdates) Reset() { - *x = GetIdentityUpdatesResponse_WalletUpdates{} - mi := &file_mls_api_v1_mls_proto_msgTypes[41] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetIdentityUpdatesResponse_WalletUpdates) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetIdentityUpdatesResponse_WalletUpdates) ProtoMessage() {} - -func (x *GetIdentityUpdatesResponse_WalletUpdates) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[41] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetIdentityUpdatesResponse_WalletUpdates.ProtoReflect.Descriptor instead. -func (*GetIdentityUpdatesResponse_WalletUpdates) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{15, 3} -} - -func (x *GetIdentityUpdatesResponse_WalletUpdates) GetUpdates() []*GetIdentityUpdatesResponse_Update { - if x != nil { - return x.Updates - } - return nil -} - -// Subscription filter -type SubscribeGroupMessagesRequest_Filter struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupId []byte `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - IdCursor uint64 `protobuf:"varint,2,opt,name=id_cursor,json=idCursor,proto3" json:"id_cursor,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeGroupMessagesRequest_Filter) Reset() { - *x = SubscribeGroupMessagesRequest_Filter{} - mi := &file_mls_api_v1_mls_proto_msgTypes[42] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeGroupMessagesRequest_Filter) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeGroupMessagesRequest_Filter) ProtoMessage() {} - -func (x *SubscribeGroupMessagesRequest_Filter) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[42] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeGroupMessagesRequest_Filter.ProtoReflect.Descriptor instead. -func (*SubscribeGroupMessagesRequest_Filter) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{21, 0} -} - -func (x *SubscribeGroupMessagesRequest_Filter) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *SubscribeGroupMessagesRequest_Filter) GetIdCursor() uint64 { - if x != nil { - return x.IdCursor - } - return 0 -} - -// Subscription filter -type SubscribeWelcomeMessagesRequest_Filter struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - IdCursor uint64 `protobuf:"varint,2,opt,name=id_cursor,json=idCursor,proto3" json:"id_cursor,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeWelcomeMessagesRequest_Filter) Reset() { - *x = SubscribeWelcomeMessagesRequest_Filter{} - mi := &file_mls_api_v1_mls_proto_msgTypes[43] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeWelcomeMessagesRequest_Filter) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeWelcomeMessagesRequest_Filter) ProtoMessage() {} - -func (x *SubscribeWelcomeMessagesRequest_Filter) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[43] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeWelcomeMessagesRequest_Filter.ProtoReflect.Descriptor instead. -func (*SubscribeWelcomeMessagesRequest_Filter) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{22, 0} -} - -func (x *SubscribeWelcomeMessagesRequest_Filter) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *SubscribeWelcomeMessagesRequest_Filter) GetIdCursor() uint64 { - if x != nil { - return x.IdCursor - } - return 0 -} - -type GetNewestGroupMessageResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - // If no message is found on the topic, will be nil - GroupMessage *GroupMessage `protobuf:"bytes,1,opt,name=group_message,json=groupMessage,proto3,oneof" json:"group_message,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetNewestGroupMessageResponse_Response) Reset() { - *x = GetNewestGroupMessageResponse_Response{} - mi := &file_mls_api_v1_mls_proto_msgTypes[44] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetNewestGroupMessageResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetNewestGroupMessageResponse_Response) ProtoMessage() {} - -func (x *GetNewestGroupMessageResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_mls_api_v1_mls_proto_msgTypes[44] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetNewestGroupMessageResponse_Response.ProtoReflect.Descriptor instead. -func (*GetNewestGroupMessageResponse_Response) Descriptor() ([]byte, []int) { - return file_mls_api_v1_mls_proto_rawDescGZIP(), []int{30, 0} -} - -func (x *GetNewestGroupMessageResponse_Response) GetGroupMessage() *GroupMessage { - if x != nil { - return x.GroupMessage - } - return nil -} - -var File_mls_api_v1_mls_proto protoreflect.FileDescriptor - -const file_mls_api_v1_mls_proto_rawDesc = "" + - "\n" + - "\x14mls/api/v1/mls.proto\x12\x0fxmtp.mls.api.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a%identity/associations/signature.proto\x1a message_contents/signature.proto\x1a%mls/message_contents/commit_log.proto\x1a*mls/message_contents/welcome_pointer.proto\x1a-mls/message_contents/wrapper_encryption.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\"\xfb\x05\n" + - "\x0eWelcomeMessage\x124\n" + - "\x02v1\x18\x01 \x01(\v2\".xmtp.mls.api.v1.WelcomeMessage.V1H\x00R\x02v1\x12Y\n" + - "\x0fwelcome_pointer\x18\x02 \x01(\v2..xmtp.mls.api.v1.WelcomeMessage.WelcomePointerH\x00R\x0ewelcomePointer\x1a\xa6\x02\n" + - "\x02V1\x12\x0e\n" + - "\x02id\x18\x01 \x01(\x04R\x02id\x12\x1d\n" + - "\n" + - "created_ns\x18\x02 \x01(\x04R\tcreatedNs\x12)\n" + - "\x10installation_key\x18\x03 \x01(\fR\x0finstallationKey\x12\x12\n" + - "\x04data\x18\x04 \x01(\fR\x04data\x12&\n" + - "\x0fhpke_public_key\x18\x05 \x01(\fR\rhpkePublicKey\x12_\n" + - "\x11wrapper_algorithm\x18\x06 \x01(\x0e22.xmtp.mls.message_contents.WelcomeWrapperAlgorithmR\x10wrapperAlgorithm\x12)\n" + - "\x10welcome_metadata\x18\a \x01(\fR\x0fwelcomeMetadata\x1a\xa3\x02\n" + - "\x0eWelcomePointer\x12\x0e\n" + - "\x02id\x18\x01 \x01(\x04R\x02id\x12\x1d\n" + - "\n" + - "created_ns\x18\x02 \x01(\x04R\tcreatedNs\x12)\n" + - "\x10installation_key\x18\x03 \x01(\fR\x0finstallationKey\x12'\n" + - "\x0fwelcome_pointer\x18\x04 \x01(\fR\x0ewelcomePointer\x12&\n" + - "\x0fhpke_public_key\x18\x05 \x01(\fR\rhpkePublicKey\x12f\n" + - "\x11wrapper_algorithm\x18\x06 \x01(\x0e29.xmtp.mls.message_contents.WelcomePointerWrapperAlgorithmR\x10wrapperAlgorithmB\t\n" + - "\aversion\"\xac\x05\n" + - "\x13WelcomeMessageInput\x129\n" + - "\x02v1\x18\x01 \x01(\v2'.xmtp.mls.api.v1.WelcomeMessageInput.V1H\x00R\x02v1\x12^\n" + - "\x0fwelcome_pointer\x18\x02 \x01(\v23.xmtp.mls.api.v1.WelcomeMessageInput.WelcomePointerH\x00R\x0ewelcomePointer\x1a\xf7\x01\n" + - "\x02V1\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\x12\x12\n" + - "\x04data\x18\x02 \x01(\fR\x04data\x12&\n" + - "\x0fhpke_public_key\x18\x03 \x01(\fR\rhpkePublicKey\x12_\n" + - "\x11wrapper_algorithm\x18\x04 \x01(\x0e22.xmtp.mls.message_contents.WelcomeWrapperAlgorithmR\x10wrapperAlgorithm\x12)\n" + - "\x10welcome_metadata\x18\a \x01(\fR\x0fwelcomeMetadata\x1a\xf4\x01\n" + - "\x0eWelcomePointer\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\x12'\n" + - "\x0fwelcome_pointer\x18\x02 \x01(\fR\x0ewelcomePointer\x12&\n" + - "\x0fhpke_public_key\x18\x03 \x01(\fR\rhpkePublicKey\x12f\n" + - "\x11wrapper_algorithm\x18\x04 \x01(\x0e29.xmtp.mls.message_contents.WelcomePointerWrapperAlgorithmR\x10wrapperAlgorithmB\t\n" + - "\aversion\"8\n" + - "\x0fWelcomeMetadata\x12%\n" + - "\x0emessage_cursor\x18\x01 \x01(\x04R\rmessageCursor\"\x91\x02\n" + - "\fGroupMessage\x122\n" + - "\x02v1\x18\x01 \x01(\v2 .xmtp.mls.api.v1.GroupMessage.V1H\x00R\x02v1\x1a\xc1\x01\n" + - "\x02V1\x12\x0e\n" + - "\x02id\x18\x01 \x01(\x04R\x02id\x12\x1d\n" + - "\n" + - "created_ns\x18\x02 \x01(\x04R\tcreatedNs\x12\x19\n" + - "\bgroup_id\x18\x03 \x01(\fR\agroupId\x12\x12\n" + - "\x04data\x18\x04 \x01(\fR\x04data\x12\x1f\n" + - "\vsender_hmac\x18\x05 \x01(\fR\n" + - "senderHmac\x12\x1f\n" + - "\vshould_push\x18\x06 \x01(\bR\n" + - "shouldPush\x12\x1b\n" + - "\tis_commit\x18\a \x01(\bR\bisCommitB\t\n" + - "\aversion\"\xb3\x01\n" + - "\x11GroupMessageInput\x127\n" + - "\x02v1\x18\x01 \x01(\v2%.xmtp.mls.api.v1.GroupMessageInput.V1H\x00R\x02v1\x1aZ\n" + - "\x02V1\x12\x12\n" + - "\x04data\x18\x01 \x01(\fR\x04data\x12\x1f\n" + - "\vsender_hmac\x18\x02 \x01(\fR\n" + - "senderHmac\x12\x1f\n" + - "\vshould_push\x18\x03 \x01(\bR\n" + - "shouldPushB\t\n" + - "\aversion\"Z\n" + - "\x18SendGroupMessagesRequest\x12>\n" + - "\bmessages\x18\x01 \x03(\v2\".xmtp.mls.api.v1.GroupMessageInputR\bmessages\"^\n" + - "\x1aSendWelcomeMessagesRequest\x12@\n" + - "\bmessages\x18\x01 \x03(\v2$.xmtp.mls.api.v1.WelcomeMessageInputR\bmessages\"O\n" + - "\x10KeyPackageUpload\x12;\n" + - "\x1akey_package_tls_serialized\x18\x01 \x01(\fR\x17keyPackageTlsSerialized\"\x96\x01\n" + - "\x1bRegisterInstallationRequest\x12B\n" + - "\vkey_package\x18\x01 \x01(\v2!.xmtp.mls.api.v1.KeyPackageUploadR\n" + - "keyPackage\x123\n" + - "\x16is_inbox_id_credential\x18\x02 \x01(\bR\x13isInboxIdCredential\"I\n" + - "\x1cRegisterInstallationResponse\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\"\x92\x01\n" + - "\x17UploadKeyPackageRequest\x12B\n" + - "\vkey_package\x18\x01 \x01(\v2!.xmtp.mls.api.v1.KeyPackageUploadR\n" + - "keyPackage\x123\n" + - "\x16is_inbox_id_credential\x18\x02 \x01(\bR\x13isInboxIdCredential\"F\n" + - "\x17FetchKeyPackagesRequest\x12+\n" + - "\x11installation_keys\x18\x01 \x03(\fR\x10installationKeys\"\xbe\x01\n" + - "\x18FetchKeyPackagesResponse\x12W\n" + - "\fkey_packages\x18\x01 \x03(\v24.xmtp.mls.api.v1.FetchKeyPackagesResponse.KeyPackageR\vkeyPackages\x1aI\n" + - "\n" + - "KeyPackage\x12;\n" + - "\x1akey_package_tls_serialized\x18\x01 \x01(\fR\x17keyPackageTlsSerialized\"\x93\x01\n" + - "\x19RevokeInstallationRequest\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\x12K\n" + - "\x10wallet_signature\x18\x02 \x01(\v2 .xmtp.message_contents.SignatureR\x0fwalletSignature\"l\n" + - "\x19GetIdentityUpdatesRequest\x12+\n" + - "\x11account_addresses\x18\x01 \x03(\tR\x10accountAddresses\x12\"\n" + - "\rstart_time_ns\x18\x02 \x01(\x04R\vstartTimeNs\"\xaf\x05\n" + - "\x1aGetIdentityUpdatesResponse\x12S\n" + - "\aupdates\x18\x01 \x03(\v29.xmtp.mls.api.v1.GetIdentityUpdatesResponse.WalletUpdatesR\aupdates\x1as\n" + - "\x15NewInstallationUpdate\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\x12/\n" + - "\x13credential_identity\x18\x02 \x01(\fR\x12credentialIdentity\x1aF\n" + - "\x19RevokedInstallationUpdate\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\x1a\x9f\x02\n" + - "\x06Update\x12!\n" + - "\ftimestamp_ns\x18\x01 \x01(\x04R\vtimestampNs\x12n\n" + - "\x10new_installation\x18\x02 \x01(\v2A.xmtp.mls.api.v1.GetIdentityUpdatesResponse.NewInstallationUpdateH\x00R\x0fnewInstallation\x12z\n" + - "\x14revoked_installation\x18\x03 \x01(\v2E.xmtp.mls.api.v1.GetIdentityUpdatesResponse.RevokedInstallationUpdateH\x00R\x13revokedInstallationB\x06\n" + - "\x04kind\x1a]\n" + - "\rWalletUpdates\x12L\n" + - "\aupdates\x18\x01 \x03(\v22.xmtp.mls.api.v1.GetIdentityUpdatesResponse.UpdateR\aupdates\"}\n" + - "\n" + - "PagingInfo\x12<\n" + - "\tdirection\x18\x01 \x01(\x0e2\x1e.xmtp.mls.api.v1.SortDirectionR\tdirection\x12\x14\n" + - "\x05limit\x18\x02 \x01(\rR\x05limit\x12\x1b\n" + - "\tid_cursor\x18\x03 \x01(\x04R\bidCursor\"t\n" + - "\x19QueryGroupMessagesRequest\x12\x19\n" + - "\bgroup_id\x18\x01 \x01(\fR\agroupId\x12<\n" + - "\vpaging_info\x18\x02 \x01(\v2\x1b.xmtp.mls.api.v1.PagingInfoR\n" + - "pagingInfo\"\x95\x01\n" + - "\x1aQueryGroupMessagesResponse\x129\n" + - "\bmessages\x18\x01 \x03(\v2\x1d.xmtp.mls.api.v1.GroupMessageR\bmessages\x12<\n" + - "\vpaging_info\x18\x02 \x01(\v2\x1b.xmtp.mls.api.v1.PagingInfoR\n" + - "pagingInfo\"\x86\x01\n" + - "\x1bQueryWelcomeMessagesRequest\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\x12<\n" + - "\vpaging_info\x18\x02 \x01(\v2\x1b.xmtp.mls.api.v1.PagingInfoR\n" + - "pagingInfo\"\x99\x01\n" + - "\x1cQueryWelcomeMessagesResponse\x12;\n" + - "\bmessages\x18\x01 \x03(\v2\x1f.xmtp.mls.api.v1.WelcomeMessageR\bmessages\x12<\n" + - "\vpaging_info\x18\x02 \x01(\v2\x1b.xmtp.mls.api.v1.PagingInfoR\n" + - "pagingInfo\"\xb2\x01\n" + - "\x1dSubscribeGroupMessagesRequest\x12O\n" + - "\afilters\x18\x01 \x03(\v25.xmtp.mls.api.v1.SubscribeGroupMessagesRequest.FilterR\afilters\x1a@\n" + - "\x06Filter\x12\x19\n" + - "\bgroup_id\x18\x01 \x01(\fR\agroupId\x12\x1b\n" + - "\tid_cursor\x18\x02 \x01(\x04R\bidCursor\"\xc6\x01\n" + - "\x1fSubscribeWelcomeMessagesRequest\x12Q\n" + - "\afilters\x18\x01 \x03(\v27.xmtp.mls.api.v1.SubscribeWelcomeMessagesRequest.FilterR\afilters\x1aP\n" + - "\x06Filter\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\x12\x1b\n" + - "\tid_cursor\x18\x02 \x01(\x04R\bidCursor\"d\n" + - "\x1cBatchPublishCommitLogRequest\x12D\n" + - "\brequests\x18\x01 \x03(\v2(.xmtp.mls.api.v1.PublishCommitLogRequestR\brequests\"\xca\x01\n" + - "\x17PublishCommitLogRequest\x12\x19\n" + - "\bgroup_id\x18\x01 \x01(\fR\agroupId\x12=\n" + - "\x1bserialized_commit_log_entry\x18\x02 \x01(\fR\x18serializedCommitLogEntry\x12U\n" + - "\tsignature\x18\x03 \x01(\v27.xmtp.identity.associations.RecoverableEd25519SignatureR\tsignature\"p\n" + - "\x15QueryCommitLogRequest\x12\x19\n" + - "\bgroup_id\x18\x01 \x01(\fR\agroupId\x12<\n" + - "\vpaging_info\x18\x02 \x01(\v2\x1b.xmtp.mls.api.v1.PagingInfoR\n" + - "pagingInfo\"\xca\x01\n" + - "\x16QueryCommitLogResponse\x12\x19\n" + - "\bgroup_id\x18\x01 \x01(\fR\agroupId\x12W\n" + - "\x12commit_log_entries\x18\x02 \x03(\v2).xmtp.mls.message_contents.CommitLogEntryR\x10commitLogEntries\x12<\n" + - "\vpaging_info\x18\x03 \x01(\v2\x1b.xmtp.mls.api.v1.PagingInfoR\n" + - "pagingInfo\"`\n" + - "\x1aBatchQueryCommitLogRequest\x12B\n" + - "\brequests\x18\x01 \x03(\v2&.xmtp.mls.api.v1.QueryCommitLogRequestR\brequests\"d\n" + - "\x1bBatchQueryCommitLogResponse\x12E\n" + - "\tresponses\x18\x01 \x03(\v2'.xmtp.mls.api.v1.QueryCommitLogResponseR\tresponses\"d\n" + - "\x1cGetNewestGroupMessageRequest\x12\x1b\n" + - "\tgroup_ids\x18\x01 \x03(\fR\bgroupIds\x12'\n" + - "\x0finclude_content\x18\x02 \x01(\bR\x0eincludeContent\"\xdd\x01\n" + - "\x1dGetNewestGroupMessageResponse\x12U\n" + - "\tresponses\x18\x01 \x03(\v27.xmtp.mls.api.v1.GetNewestGroupMessageResponse.ResponseR\tresponses\x1ae\n" + - "\bResponse\x12G\n" + - "\rgroup_message\x18\x01 \x01(\v2\x1d.xmtp.mls.api.v1.GroupMessageH\x00R\fgroupMessage\x88\x01\x01B\x10\n" + - "\x0e_group_message*l\n" + - "\rSortDirection\x12\x1e\n" + - "\x1aSORT_DIRECTION_UNSPECIFIED\x10\x00\x12\x1c\n" + - "\x18SORT_DIRECTION_ASCENDING\x10\x01\x12\x1d\n" + - "\x19SORT_DIRECTION_DESCENDING\x10\x022\x9c\x10\n" + - "\x06MlsApi\x12~\n" + - "\x11SendGroupMessages\x12).xmtp.mls.api.v1.SendGroupMessagesRequest\x1a\x16.google.protobuf.Empty\"&\x82\xd3\xe4\x93\x02 :\x01*\"\x1b/mls/v1/send-group-messages\x12\x84\x01\n" + - "\x13SendWelcomeMessages\x12+.xmtp.mls.api.v1.SendWelcomeMessagesRequest\x1a\x16.google.protobuf.Empty\"(\x82\xd3\xe4\x93\x02\":\x01*\"\x1d/mls/v1/send-welcome-messages\x12\x9d\x01\n" + - "\x14RegisterInstallation\x12,.xmtp.mls.api.v1.RegisterInstallationRequest\x1a-.xmtp.mls.api.v1.RegisterInstallationResponse\"(\x82\xd3\xe4\x93\x02\":\x01*\"\x1d/mls/v1/register-installation\x12{\n" + - "\x10UploadKeyPackage\x12(.xmtp.mls.api.v1.UploadKeyPackageRequest\x1a\x16.google.protobuf.Empty\"%\x82\xd3\xe4\x93\x02\x1f:\x01*\"\x1a/mls/v1/upload-key-package\x12\x8e\x01\n" + - "\x10FetchKeyPackages\x12(.xmtp.mls.api.v1.FetchKeyPackagesRequest\x1a).xmtp.mls.api.v1.FetchKeyPackagesResponse\"%\x82\xd3\xe4\x93\x02\x1f:\x01*\"\x1a/mls/v1/fetch-key-packages\x12\x80\x01\n" + - "\x12RevokeInstallation\x12*.xmtp.mls.api.v1.RevokeInstallationRequest\x1a\x16.google.protobuf.Empty\"&\x82\xd3\xe4\x93\x02 :\x01*\"\x1b/mls/v1/revoke-installation\x12\x96\x01\n" + - "\x12GetIdentityUpdates\x12*.xmtp.mls.api.v1.GetIdentityUpdatesRequest\x1a+.xmtp.mls.api.v1.GetIdentityUpdatesResponse\"'\x82\xd3\xe4\x93\x02!:\x01*\"\x1c/mls/v1/get-identity-updates\x12\x96\x01\n" + - "\x12QueryGroupMessages\x12*.xmtp.mls.api.v1.QueryGroupMessagesRequest\x1a+.xmtp.mls.api.v1.QueryGroupMessagesResponse\"'\x82\xd3\xe4\x93\x02!:\x01*\"\x1c/mls/v1/query-group-messages\x12\x9e\x01\n" + - "\x14QueryWelcomeMessages\x12,.xmtp.mls.api.v1.QueryWelcomeMessagesRequest\x1a-.xmtp.mls.api.v1.QueryWelcomeMessagesResponse\")\x82\xd3\xe4\x93\x02#:\x01*\"\x1e/mls/v1/query-welcome-messages\x12\x96\x01\n" + - "\x16SubscribeGroupMessages\x12..xmtp.mls.api.v1.SubscribeGroupMessagesRequest\x1a\x1d.xmtp.mls.api.v1.GroupMessage\"+\x82\xd3\xe4\x93\x02%:\x01*\" /mls/v1/subscribe-group-messages0\x01\x12\x9e\x01\n" + - "\x18SubscribeWelcomeMessages\x120.xmtp.mls.api.v1.SubscribeWelcomeMessagesRequest\x1a\x1f.xmtp.mls.api.v1.WelcomeMessage\"-\x82\xd3\xe4\x93\x02':\x01*\"\"/mls/v1/subscribe-welcome-messages0\x01\x12\x8b\x01\n" + - "\x15BatchPublishCommitLog\x12-.xmtp.mls.api.v1.BatchPublishCommitLogRequest\x1a\x16.google.protobuf.Empty\"+\x82\xd3\xe4\x93\x02%:\x01*\" /mls/v1/batch-publish-commit-log\x12\x9b\x01\n" + - "\x13BatchQueryCommitLog\x12+.xmtp.mls.api.v1.BatchQueryCommitLogRequest\x1a,.xmtp.mls.api.v1.BatchQueryCommitLogResponse\")\x82\xd3\xe4\x93\x02#:\x01*\"\x1e/mls/v1/batch-query-commit-log\x12\xa0\x01\n" + - "\x15GetNewestGroupMessage\x12-.xmtp.mls.api.v1.GetNewestGroupMessageRequest\x1a..xmtp.mls.api.v1.GetNewestGroupMessageResponse\"(\x82\xd3\xe4\x93\x02\"\x12 /mls/v1/get-newest-group-messageB\xf5\x01\x92A\x0f\x12\r\n" + - "\x06MlsApi2\x031.0\n" + - "-org.xmtp.android.library.push.xmtp.mls.api.v1B\bMlsProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/api/v1;apiv1\xa2\x02\x03XMA\xaa\x02\x0fXmtp.Mls.Api.V1\xca\x02\x0fXmtp\\Mls\\Api\\V1\xe2\x02\x1bXmtp\\Mls\\Api\\V1\\GPBMetadata\xea\x02\x12Xmtp::Mls::Api::V1b\x06proto3" - -var ( - file_mls_api_v1_mls_proto_rawDescOnce sync.Once - file_mls_api_v1_mls_proto_rawDescData []byte -) - -func file_mls_api_v1_mls_proto_rawDescGZIP() []byte { - file_mls_api_v1_mls_proto_rawDescOnce.Do(func() { - file_mls_api_v1_mls_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_api_v1_mls_proto_rawDesc), len(file_mls_api_v1_mls_proto_rawDesc))) - }) - return file_mls_api_v1_mls_proto_rawDescData -} - -var file_mls_api_v1_mls_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_mls_api_v1_mls_proto_msgTypes = make([]protoimpl.MessageInfo, 45) -var file_mls_api_v1_mls_proto_goTypes = []any{ - (SortDirection)(0), // 0: xmtp.mls.api.v1.SortDirection - (*WelcomeMessage)(nil), // 1: xmtp.mls.api.v1.WelcomeMessage - (*WelcomeMessageInput)(nil), // 2: xmtp.mls.api.v1.WelcomeMessageInput - (*WelcomeMetadata)(nil), // 3: xmtp.mls.api.v1.WelcomeMetadata - (*GroupMessage)(nil), // 4: xmtp.mls.api.v1.GroupMessage - (*GroupMessageInput)(nil), // 5: xmtp.mls.api.v1.GroupMessageInput - (*SendGroupMessagesRequest)(nil), // 6: xmtp.mls.api.v1.SendGroupMessagesRequest - (*SendWelcomeMessagesRequest)(nil), // 7: xmtp.mls.api.v1.SendWelcomeMessagesRequest - (*KeyPackageUpload)(nil), // 8: xmtp.mls.api.v1.KeyPackageUpload - (*RegisterInstallationRequest)(nil), // 9: xmtp.mls.api.v1.RegisterInstallationRequest - (*RegisterInstallationResponse)(nil), // 10: xmtp.mls.api.v1.RegisterInstallationResponse - (*UploadKeyPackageRequest)(nil), // 11: xmtp.mls.api.v1.UploadKeyPackageRequest - (*FetchKeyPackagesRequest)(nil), // 12: xmtp.mls.api.v1.FetchKeyPackagesRequest - (*FetchKeyPackagesResponse)(nil), // 13: xmtp.mls.api.v1.FetchKeyPackagesResponse - (*RevokeInstallationRequest)(nil), // 14: xmtp.mls.api.v1.RevokeInstallationRequest - (*GetIdentityUpdatesRequest)(nil), // 15: xmtp.mls.api.v1.GetIdentityUpdatesRequest - (*GetIdentityUpdatesResponse)(nil), // 16: xmtp.mls.api.v1.GetIdentityUpdatesResponse - (*PagingInfo)(nil), // 17: xmtp.mls.api.v1.PagingInfo - (*QueryGroupMessagesRequest)(nil), // 18: xmtp.mls.api.v1.QueryGroupMessagesRequest - (*QueryGroupMessagesResponse)(nil), // 19: xmtp.mls.api.v1.QueryGroupMessagesResponse - (*QueryWelcomeMessagesRequest)(nil), // 20: xmtp.mls.api.v1.QueryWelcomeMessagesRequest - (*QueryWelcomeMessagesResponse)(nil), // 21: xmtp.mls.api.v1.QueryWelcomeMessagesResponse - (*SubscribeGroupMessagesRequest)(nil), // 22: xmtp.mls.api.v1.SubscribeGroupMessagesRequest - (*SubscribeWelcomeMessagesRequest)(nil), // 23: xmtp.mls.api.v1.SubscribeWelcomeMessagesRequest - (*BatchPublishCommitLogRequest)(nil), // 24: xmtp.mls.api.v1.BatchPublishCommitLogRequest - (*PublishCommitLogRequest)(nil), // 25: xmtp.mls.api.v1.PublishCommitLogRequest - (*QueryCommitLogRequest)(nil), // 26: xmtp.mls.api.v1.QueryCommitLogRequest - (*QueryCommitLogResponse)(nil), // 27: xmtp.mls.api.v1.QueryCommitLogResponse - (*BatchQueryCommitLogRequest)(nil), // 28: xmtp.mls.api.v1.BatchQueryCommitLogRequest - (*BatchQueryCommitLogResponse)(nil), // 29: xmtp.mls.api.v1.BatchQueryCommitLogResponse - (*GetNewestGroupMessageRequest)(nil), // 30: xmtp.mls.api.v1.GetNewestGroupMessageRequest - (*GetNewestGroupMessageResponse)(nil), // 31: xmtp.mls.api.v1.GetNewestGroupMessageResponse - (*WelcomeMessage_V1)(nil), // 32: xmtp.mls.api.v1.WelcomeMessage.V1 - (*WelcomeMessage_WelcomePointer)(nil), // 33: xmtp.mls.api.v1.WelcomeMessage.WelcomePointer - (*WelcomeMessageInput_V1)(nil), // 34: xmtp.mls.api.v1.WelcomeMessageInput.V1 - (*WelcomeMessageInput_WelcomePointer)(nil), // 35: xmtp.mls.api.v1.WelcomeMessageInput.WelcomePointer - (*GroupMessage_V1)(nil), // 36: xmtp.mls.api.v1.GroupMessage.V1 - (*GroupMessageInput_V1)(nil), // 37: xmtp.mls.api.v1.GroupMessageInput.V1 - (*FetchKeyPackagesResponse_KeyPackage)(nil), // 38: xmtp.mls.api.v1.FetchKeyPackagesResponse.KeyPackage - (*GetIdentityUpdatesResponse_NewInstallationUpdate)(nil), // 39: xmtp.mls.api.v1.GetIdentityUpdatesResponse.NewInstallationUpdate - (*GetIdentityUpdatesResponse_RevokedInstallationUpdate)(nil), // 40: xmtp.mls.api.v1.GetIdentityUpdatesResponse.RevokedInstallationUpdate - (*GetIdentityUpdatesResponse_Update)(nil), // 41: xmtp.mls.api.v1.GetIdentityUpdatesResponse.Update - (*GetIdentityUpdatesResponse_WalletUpdates)(nil), // 42: xmtp.mls.api.v1.GetIdentityUpdatesResponse.WalletUpdates - (*SubscribeGroupMessagesRequest_Filter)(nil), // 43: xmtp.mls.api.v1.SubscribeGroupMessagesRequest.Filter - (*SubscribeWelcomeMessagesRequest_Filter)(nil), // 44: xmtp.mls.api.v1.SubscribeWelcomeMessagesRequest.Filter - (*GetNewestGroupMessageResponse_Response)(nil), // 45: xmtp.mls.api.v1.GetNewestGroupMessageResponse.Response - (*message_contents.Signature)(nil), // 46: xmtp.message_contents.Signature - (*associations.RecoverableEd25519Signature)(nil), // 47: xmtp.identity.associations.RecoverableEd25519Signature - (*message_contents1.CommitLogEntry)(nil), // 48: xmtp.mls.message_contents.CommitLogEntry - (message_contents1.WelcomeWrapperAlgorithm)(0), // 49: xmtp.mls.message_contents.WelcomeWrapperAlgorithm - (message_contents1.WelcomePointerWrapperAlgorithm)(0), // 50: xmtp.mls.message_contents.WelcomePointerWrapperAlgorithm - (*emptypb.Empty)(nil), // 51: google.protobuf.Empty -} -var file_mls_api_v1_mls_proto_depIdxs = []int32{ - 32, // 0: xmtp.mls.api.v1.WelcomeMessage.v1:type_name -> xmtp.mls.api.v1.WelcomeMessage.V1 - 33, // 1: xmtp.mls.api.v1.WelcomeMessage.welcome_pointer:type_name -> xmtp.mls.api.v1.WelcomeMessage.WelcomePointer - 34, // 2: xmtp.mls.api.v1.WelcomeMessageInput.v1:type_name -> xmtp.mls.api.v1.WelcomeMessageInput.V1 - 35, // 3: xmtp.mls.api.v1.WelcomeMessageInput.welcome_pointer:type_name -> xmtp.mls.api.v1.WelcomeMessageInput.WelcomePointer - 36, // 4: xmtp.mls.api.v1.GroupMessage.v1:type_name -> xmtp.mls.api.v1.GroupMessage.V1 - 37, // 5: xmtp.mls.api.v1.GroupMessageInput.v1:type_name -> xmtp.mls.api.v1.GroupMessageInput.V1 - 5, // 6: xmtp.mls.api.v1.SendGroupMessagesRequest.messages:type_name -> xmtp.mls.api.v1.GroupMessageInput - 2, // 7: xmtp.mls.api.v1.SendWelcomeMessagesRequest.messages:type_name -> xmtp.mls.api.v1.WelcomeMessageInput - 8, // 8: xmtp.mls.api.v1.RegisterInstallationRequest.key_package:type_name -> xmtp.mls.api.v1.KeyPackageUpload - 8, // 9: xmtp.mls.api.v1.UploadKeyPackageRequest.key_package:type_name -> xmtp.mls.api.v1.KeyPackageUpload - 38, // 10: xmtp.mls.api.v1.FetchKeyPackagesResponse.key_packages:type_name -> xmtp.mls.api.v1.FetchKeyPackagesResponse.KeyPackage - 46, // 11: xmtp.mls.api.v1.RevokeInstallationRequest.wallet_signature:type_name -> xmtp.message_contents.Signature - 42, // 12: xmtp.mls.api.v1.GetIdentityUpdatesResponse.updates:type_name -> xmtp.mls.api.v1.GetIdentityUpdatesResponse.WalletUpdates - 0, // 13: xmtp.mls.api.v1.PagingInfo.direction:type_name -> xmtp.mls.api.v1.SortDirection - 17, // 14: xmtp.mls.api.v1.QueryGroupMessagesRequest.paging_info:type_name -> xmtp.mls.api.v1.PagingInfo - 4, // 15: xmtp.mls.api.v1.QueryGroupMessagesResponse.messages:type_name -> xmtp.mls.api.v1.GroupMessage - 17, // 16: xmtp.mls.api.v1.QueryGroupMessagesResponse.paging_info:type_name -> xmtp.mls.api.v1.PagingInfo - 17, // 17: xmtp.mls.api.v1.QueryWelcomeMessagesRequest.paging_info:type_name -> xmtp.mls.api.v1.PagingInfo - 1, // 18: xmtp.mls.api.v1.QueryWelcomeMessagesResponse.messages:type_name -> xmtp.mls.api.v1.WelcomeMessage - 17, // 19: xmtp.mls.api.v1.QueryWelcomeMessagesResponse.paging_info:type_name -> xmtp.mls.api.v1.PagingInfo - 43, // 20: xmtp.mls.api.v1.SubscribeGroupMessagesRequest.filters:type_name -> xmtp.mls.api.v1.SubscribeGroupMessagesRequest.Filter - 44, // 21: xmtp.mls.api.v1.SubscribeWelcomeMessagesRequest.filters:type_name -> xmtp.mls.api.v1.SubscribeWelcomeMessagesRequest.Filter - 25, // 22: xmtp.mls.api.v1.BatchPublishCommitLogRequest.requests:type_name -> xmtp.mls.api.v1.PublishCommitLogRequest - 47, // 23: xmtp.mls.api.v1.PublishCommitLogRequest.signature:type_name -> xmtp.identity.associations.RecoverableEd25519Signature - 17, // 24: xmtp.mls.api.v1.QueryCommitLogRequest.paging_info:type_name -> xmtp.mls.api.v1.PagingInfo - 48, // 25: xmtp.mls.api.v1.QueryCommitLogResponse.commit_log_entries:type_name -> xmtp.mls.message_contents.CommitLogEntry - 17, // 26: xmtp.mls.api.v1.QueryCommitLogResponse.paging_info:type_name -> xmtp.mls.api.v1.PagingInfo - 26, // 27: xmtp.mls.api.v1.BatchQueryCommitLogRequest.requests:type_name -> xmtp.mls.api.v1.QueryCommitLogRequest - 27, // 28: xmtp.mls.api.v1.BatchQueryCommitLogResponse.responses:type_name -> xmtp.mls.api.v1.QueryCommitLogResponse - 45, // 29: xmtp.mls.api.v1.GetNewestGroupMessageResponse.responses:type_name -> xmtp.mls.api.v1.GetNewestGroupMessageResponse.Response - 49, // 30: xmtp.mls.api.v1.WelcomeMessage.V1.wrapper_algorithm:type_name -> xmtp.mls.message_contents.WelcomeWrapperAlgorithm - 50, // 31: xmtp.mls.api.v1.WelcomeMessage.WelcomePointer.wrapper_algorithm:type_name -> xmtp.mls.message_contents.WelcomePointerWrapperAlgorithm - 49, // 32: xmtp.mls.api.v1.WelcomeMessageInput.V1.wrapper_algorithm:type_name -> xmtp.mls.message_contents.WelcomeWrapperAlgorithm - 50, // 33: xmtp.mls.api.v1.WelcomeMessageInput.WelcomePointer.wrapper_algorithm:type_name -> xmtp.mls.message_contents.WelcomePointerWrapperAlgorithm - 39, // 34: xmtp.mls.api.v1.GetIdentityUpdatesResponse.Update.new_installation:type_name -> xmtp.mls.api.v1.GetIdentityUpdatesResponse.NewInstallationUpdate - 40, // 35: xmtp.mls.api.v1.GetIdentityUpdatesResponse.Update.revoked_installation:type_name -> xmtp.mls.api.v1.GetIdentityUpdatesResponse.RevokedInstallationUpdate - 41, // 36: xmtp.mls.api.v1.GetIdentityUpdatesResponse.WalletUpdates.updates:type_name -> xmtp.mls.api.v1.GetIdentityUpdatesResponse.Update - 4, // 37: xmtp.mls.api.v1.GetNewestGroupMessageResponse.Response.group_message:type_name -> xmtp.mls.api.v1.GroupMessage - 6, // 38: xmtp.mls.api.v1.MlsApi.SendGroupMessages:input_type -> xmtp.mls.api.v1.SendGroupMessagesRequest - 7, // 39: xmtp.mls.api.v1.MlsApi.SendWelcomeMessages:input_type -> xmtp.mls.api.v1.SendWelcomeMessagesRequest - 9, // 40: xmtp.mls.api.v1.MlsApi.RegisterInstallation:input_type -> xmtp.mls.api.v1.RegisterInstallationRequest - 11, // 41: xmtp.mls.api.v1.MlsApi.UploadKeyPackage:input_type -> xmtp.mls.api.v1.UploadKeyPackageRequest - 12, // 42: xmtp.mls.api.v1.MlsApi.FetchKeyPackages:input_type -> xmtp.mls.api.v1.FetchKeyPackagesRequest - 14, // 43: xmtp.mls.api.v1.MlsApi.RevokeInstallation:input_type -> xmtp.mls.api.v1.RevokeInstallationRequest - 15, // 44: xmtp.mls.api.v1.MlsApi.GetIdentityUpdates:input_type -> xmtp.mls.api.v1.GetIdentityUpdatesRequest - 18, // 45: xmtp.mls.api.v1.MlsApi.QueryGroupMessages:input_type -> xmtp.mls.api.v1.QueryGroupMessagesRequest - 20, // 46: xmtp.mls.api.v1.MlsApi.QueryWelcomeMessages:input_type -> xmtp.mls.api.v1.QueryWelcomeMessagesRequest - 22, // 47: xmtp.mls.api.v1.MlsApi.SubscribeGroupMessages:input_type -> xmtp.mls.api.v1.SubscribeGroupMessagesRequest - 23, // 48: xmtp.mls.api.v1.MlsApi.SubscribeWelcomeMessages:input_type -> xmtp.mls.api.v1.SubscribeWelcomeMessagesRequest - 24, // 49: xmtp.mls.api.v1.MlsApi.BatchPublishCommitLog:input_type -> xmtp.mls.api.v1.BatchPublishCommitLogRequest - 28, // 50: xmtp.mls.api.v1.MlsApi.BatchQueryCommitLog:input_type -> xmtp.mls.api.v1.BatchQueryCommitLogRequest - 30, // 51: xmtp.mls.api.v1.MlsApi.GetNewestGroupMessage:input_type -> xmtp.mls.api.v1.GetNewestGroupMessageRequest - 51, // 52: xmtp.mls.api.v1.MlsApi.SendGroupMessages:output_type -> google.protobuf.Empty - 51, // 53: xmtp.mls.api.v1.MlsApi.SendWelcomeMessages:output_type -> google.protobuf.Empty - 10, // 54: xmtp.mls.api.v1.MlsApi.RegisterInstallation:output_type -> xmtp.mls.api.v1.RegisterInstallationResponse - 51, // 55: xmtp.mls.api.v1.MlsApi.UploadKeyPackage:output_type -> google.protobuf.Empty - 13, // 56: xmtp.mls.api.v1.MlsApi.FetchKeyPackages:output_type -> xmtp.mls.api.v1.FetchKeyPackagesResponse - 51, // 57: xmtp.mls.api.v1.MlsApi.RevokeInstallation:output_type -> google.protobuf.Empty - 16, // 58: xmtp.mls.api.v1.MlsApi.GetIdentityUpdates:output_type -> xmtp.mls.api.v1.GetIdentityUpdatesResponse - 19, // 59: xmtp.mls.api.v1.MlsApi.QueryGroupMessages:output_type -> xmtp.mls.api.v1.QueryGroupMessagesResponse - 21, // 60: xmtp.mls.api.v1.MlsApi.QueryWelcomeMessages:output_type -> xmtp.mls.api.v1.QueryWelcomeMessagesResponse - 4, // 61: xmtp.mls.api.v1.MlsApi.SubscribeGroupMessages:output_type -> xmtp.mls.api.v1.GroupMessage - 1, // 62: xmtp.mls.api.v1.MlsApi.SubscribeWelcomeMessages:output_type -> xmtp.mls.api.v1.WelcomeMessage - 51, // 63: xmtp.mls.api.v1.MlsApi.BatchPublishCommitLog:output_type -> google.protobuf.Empty - 29, // 64: xmtp.mls.api.v1.MlsApi.BatchQueryCommitLog:output_type -> xmtp.mls.api.v1.BatchQueryCommitLogResponse - 31, // 65: xmtp.mls.api.v1.MlsApi.GetNewestGroupMessage:output_type -> xmtp.mls.api.v1.GetNewestGroupMessageResponse - 52, // [52:66] is the sub-list for method output_type - 38, // [38:52] is the sub-list for method input_type - 38, // [38:38] is the sub-list for extension type_name - 38, // [38:38] is the sub-list for extension extendee - 0, // [0:38] is the sub-list for field type_name -} - -func init() { file_mls_api_v1_mls_proto_init() } -func file_mls_api_v1_mls_proto_init() { - if File_mls_api_v1_mls_proto != nil { - return - } - file_mls_api_v1_mls_proto_msgTypes[0].OneofWrappers = []any{ - (*WelcomeMessage_V1_)(nil), - (*WelcomeMessage_WelcomePointer_)(nil), - } - file_mls_api_v1_mls_proto_msgTypes[1].OneofWrappers = []any{ - (*WelcomeMessageInput_V1_)(nil), - (*WelcomeMessageInput_WelcomePointer_)(nil), - } - file_mls_api_v1_mls_proto_msgTypes[3].OneofWrappers = []any{ - (*GroupMessage_V1_)(nil), - } - file_mls_api_v1_mls_proto_msgTypes[4].OneofWrappers = []any{ - (*GroupMessageInput_V1_)(nil), - } - file_mls_api_v1_mls_proto_msgTypes[40].OneofWrappers = []any{ - (*GetIdentityUpdatesResponse_Update_NewInstallation)(nil), - (*GetIdentityUpdatesResponse_Update_RevokedInstallation)(nil), - } - file_mls_api_v1_mls_proto_msgTypes[44].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_api_v1_mls_proto_rawDesc), len(file_mls_api_v1_mls_proto_rawDesc)), - NumEnums: 1, - NumMessages: 45, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_mls_api_v1_mls_proto_goTypes, - DependencyIndexes: file_mls_api_v1_mls_proto_depIdxs, - EnumInfos: file_mls_api_v1_mls_proto_enumTypes, - MessageInfos: file_mls_api_v1_mls_proto_msgTypes, - }.Build() - File_mls_api_v1_mls_proto = out.File - file_mls_api_v1_mls_proto_goTypes = nil - file_mls_api_v1_mls_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/api/v1/mls_grpc.pb.go b/pkg/proto/mls/api/v1/mls_grpc.pb.go deleted file mode 100644 index dc2e571f..00000000 --- a/pkg/proto/mls/api/v1/mls_grpc.pb.go +++ /dev/null @@ -1,678 +0,0 @@ -// Message API - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: mls/api/v1/mls.proto - -package apiv1 - -import ( - context "context" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" - emptypb "google.golang.org/protobuf/types/known/emptypb" -) - -// 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 ( - MlsApi_SendGroupMessages_FullMethodName = "/xmtp.mls.api.v1.MlsApi/SendGroupMessages" - MlsApi_SendWelcomeMessages_FullMethodName = "/xmtp.mls.api.v1.MlsApi/SendWelcomeMessages" - MlsApi_RegisterInstallation_FullMethodName = "/xmtp.mls.api.v1.MlsApi/RegisterInstallation" - MlsApi_UploadKeyPackage_FullMethodName = "/xmtp.mls.api.v1.MlsApi/UploadKeyPackage" - MlsApi_FetchKeyPackages_FullMethodName = "/xmtp.mls.api.v1.MlsApi/FetchKeyPackages" - MlsApi_RevokeInstallation_FullMethodName = "/xmtp.mls.api.v1.MlsApi/RevokeInstallation" - MlsApi_GetIdentityUpdates_FullMethodName = "/xmtp.mls.api.v1.MlsApi/GetIdentityUpdates" - MlsApi_QueryGroupMessages_FullMethodName = "/xmtp.mls.api.v1.MlsApi/QueryGroupMessages" - MlsApi_QueryWelcomeMessages_FullMethodName = "/xmtp.mls.api.v1.MlsApi/QueryWelcomeMessages" - MlsApi_SubscribeGroupMessages_FullMethodName = "/xmtp.mls.api.v1.MlsApi/SubscribeGroupMessages" - MlsApi_SubscribeWelcomeMessages_FullMethodName = "/xmtp.mls.api.v1.MlsApi/SubscribeWelcomeMessages" - MlsApi_BatchPublishCommitLog_FullMethodName = "/xmtp.mls.api.v1.MlsApi/BatchPublishCommitLog" - MlsApi_BatchQueryCommitLog_FullMethodName = "/xmtp.mls.api.v1.MlsApi/BatchQueryCommitLog" - MlsApi_GetNewestGroupMessage_FullMethodName = "/xmtp.mls.api.v1.MlsApi/GetNewestGroupMessage" -) - -// MlsApiClient is the client API for MlsApi 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 MlsApiClient interface { - // Send a MLS payload, that would be validated before being stored to the - // network - SendGroupMessages(ctx context.Context, in *SendGroupMessagesRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) - // Send a batch of welcome messages - SendWelcomeMessages(ctx context.Context, in *SendWelcomeMessagesRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) - // Register a new installation, which would be validated before storage - RegisterInstallation(ctx context.Context, in *RegisterInstallationRequest, opts ...grpc.CallOption) (*RegisterInstallationResponse, error) - // Upload a new KeyPackage, which would be validated before storage - UploadKeyPackage(ctx context.Context, in *UploadKeyPackageRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) - // Get one or more Key Packages by installation_id - FetchKeyPackages(ctx context.Context, in *FetchKeyPackagesRequest, opts ...grpc.CallOption) (*FetchKeyPackagesResponse, error) - // Would delete all key packages associated with the installation and mark - // the installation as having been revoked - RevokeInstallation(ctx context.Context, in *RevokeInstallationRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) - // Used to check for changes related to members of a group. - // Would return an array of any new installations associated with the wallet - // address, and any revocations that have happened. - GetIdentityUpdates(ctx context.Context, in *GetIdentityUpdatesRequest, opts ...grpc.CallOption) (*GetIdentityUpdatesResponse, error) - // Query stored group messages - QueryGroupMessages(ctx context.Context, in *QueryGroupMessagesRequest, opts ...grpc.CallOption) (*QueryGroupMessagesResponse, error) - // Query stored group messages - QueryWelcomeMessages(ctx context.Context, in *QueryWelcomeMessagesRequest, opts ...grpc.CallOption) (*QueryWelcomeMessagesResponse, error) - // Subscribe stream of new group messages - SubscribeGroupMessages(ctx context.Context, in *SubscribeGroupMessagesRequest, opts ...grpc.CallOption) (MlsApi_SubscribeGroupMessagesClient, error) - // Subscribe stream of new welcome messages - SubscribeWelcomeMessages(ctx context.Context, in *SubscribeWelcomeMessagesRequest, opts ...grpc.CallOption) (MlsApi_SubscribeWelcomeMessagesClient, error) - BatchPublishCommitLog(ctx context.Context, in *BatchPublishCommitLogRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) - BatchQueryCommitLog(ctx context.Context, in *BatchQueryCommitLogRequest, opts ...grpc.CallOption) (*BatchQueryCommitLogResponse, error) - GetNewestGroupMessage(ctx context.Context, in *GetNewestGroupMessageRequest, opts ...grpc.CallOption) (*GetNewestGroupMessageResponse, error) -} - -type mlsApiClient struct { - cc grpc.ClientConnInterface -} - -func NewMlsApiClient(cc grpc.ClientConnInterface) MlsApiClient { - return &mlsApiClient{cc} -} - -func (c *mlsApiClient) SendGroupMessages(ctx context.Context, in *SendGroupMessagesRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { - out := new(emptypb.Empty) - err := c.cc.Invoke(ctx, MlsApi_SendGroupMessages_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) SendWelcomeMessages(ctx context.Context, in *SendWelcomeMessagesRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { - out := new(emptypb.Empty) - err := c.cc.Invoke(ctx, MlsApi_SendWelcomeMessages_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) RegisterInstallation(ctx context.Context, in *RegisterInstallationRequest, opts ...grpc.CallOption) (*RegisterInstallationResponse, error) { - out := new(RegisterInstallationResponse) - err := c.cc.Invoke(ctx, MlsApi_RegisterInstallation_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) UploadKeyPackage(ctx context.Context, in *UploadKeyPackageRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { - out := new(emptypb.Empty) - err := c.cc.Invoke(ctx, MlsApi_UploadKeyPackage_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) FetchKeyPackages(ctx context.Context, in *FetchKeyPackagesRequest, opts ...grpc.CallOption) (*FetchKeyPackagesResponse, error) { - out := new(FetchKeyPackagesResponse) - err := c.cc.Invoke(ctx, MlsApi_FetchKeyPackages_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) RevokeInstallation(ctx context.Context, in *RevokeInstallationRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { - out := new(emptypb.Empty) - err := c.cc.Invoke(ctx, MlsApi_RevokeInstallation_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) GetIdentityUpdates(ctx context.Context, in *GetIdentityUpdatesRequest, opts ...grpc.CallOption) (*GetIdentityUpdatesResponse, error) { - out := new(GetIdentityUpdatesResponse) - err := c.cc.Invoke(ctx, MlsApi_GetIdentityUpdates_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) QueryGroupMessages(ctx context.Context, in *QueryGroupMessagesRequest, opts ...grpc.CallOption) (*QueryGroupMessagesResponse, error) { - out := new(QueryGroupMessagesResponse) - err := c.cc.Invoke(ctx, MlsApi_QueryGroupMessages_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) QueryWelcomeMessages(ctx context.Context, in *QueryWelcomeMessagesRequest, opts ...grpc.CallOption) (*QueryWelcomeMessagesResponse, error) { - out := new(QueryWelcomeMessagesResponse) - err := c.cc.Invoke(ctx, MlsApi_QueryWelcomeMessages_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) SubscribeGroupMessages(ctx context.Context, in *SubscribeGroupMessagesRequest, opts ...grpc.CallOption) (MlsApi_SubscribeGroupMessagesClient, error) { - stream, err := c.cc.NewStream(ctx, &MlsApi_ServiceDesc.Streams[0], MlsApi_SubscribeGroupMessages_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &mlsApiSubscribeGroupMessagesClient{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 MlsApi_SubscribeGroupMessagesClient interface { - Recv() (*GroupMessage, error) - grpc.ClientStream -} - -type mlsApiSubscribeGroupMessagesClient struct { - grpc.ClientStream -} - -func (x *mlsApiSubscribeGroupMessagesClient) Recv() (*GroupMessage, error) { - m := new(GroupMessage) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *mlsApiClient) SubscribeWelcomeMessages(ctx context.Context, in *SubscribeWelcomeMessagesRequest, opts ...grpc.CallOption) (MlsApi_SubscribeWelcomeMessagesClient, error) { - stream, err := c.cc.NewStream(ctx, &MlsApi_ServiceDesc.Streams[1], MlsApi_SubscribeWelcomeMessages_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &mlsApiSubscribeWelcomeMessagesClient{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 MlsApi_SubscribeWelcomeMessagesClient interface { - Recv() (*WelcomeMessage, error) - grpc.ClientStream -} - -type mlsApiSubscribeWelcomeMessagesClient struct { - grpc.ClientStream -} - -func (x *mlsApiSubscribeWelcomeMessagesClient) Recv() (*WelcomeMessage, error) { - m := new(WelcomeMessage) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *mlsApiClient) BatchPublishCommitLog(ctx context.Context, in *BatchPublishCommitLogRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { - out := new(emptypb.Empty) - err := c.cc.Invoke(ctx, MlsApi_BatchPublishCommitLog_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) BatchQueryCommitLog(ctx context.Context, in *BatchQueryCommitLogRequest, opts ...grpc.CallOption) (*BatchQueryCommitLogResponse, error) { - out := new(BatchQueryCommitLogResponse) - err := c.cc.Invoke(ctx, MlsApi_BatchQueryCommitLog_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *mlsApiClient) GetNewestGroupMessage(ctx context.Context, in *GetNewestGroupMessageRequest, opts ...grpc.CallOption) (*GetNewestGroupMessageResponse, error) { - out := new(GetNewestGroupMessageResponse) - err := c.cc.Invoke(ctx, MlsApi_GetNewestGroupMessage_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// MlsApiServer is the server API for MlsApi service. -// All implementations must embed UnimplementedMlsApiServer -// for forward compatibility -type MlsApiServer interface { - // Send a MLS payload, that would be validated before being stored to the - // network - SendGroupMessages(context.Context, *SendGroupMessagesRequest) (*emptypb.Empty, error) - // Send a batch of welcome messages - SendWelcomeMessages(context.Context, *SendWelcomeMessagesRequest) (*emptypb.Empty, error) - // Register a new installation, which would be validated before storage - RegisterInstallation(context.Context, *RegisterInstallationRequest) (*RegisterInstallationResponse, error) - // Upload a new KeyPackage, which would be validated before storage - UploadKeyPackage(context.Context, *UploadKeyPackageRequest) (*emptypb.Empty, error) - // Get one or more Key Packages by installation_id - FetchKeyPackages(context.Context, *FetchKeyPackagesRequest) (*FetchKeyPackagesResponse, error) - // Would delete all key packages associated with the installation and mark - // the installation as having been revoked - RevokeInstallation(context.Context, *RevokeInstallationRequest) (*emptypb.Empty, error) - // Used to check for changes related to members of a group. - // Would return an array of any new installations associated with the wallet - // address, and any revocations that have happened. - GetIdentityUpdates(context.Context, *GetIdentityUpdatesRequest) (*GetIdentityUpdatesResponse, error) - // Query stored group messages - QueryGroupMessages(context.Context, *QueryGroupMessagesRequest) (*QueryGroupMessagesResponse, error) - // Query stored group messages - QueryWelcomeMessages(context.Context, *QueryWelcomeMessagesRequest) (*QueryWelcomeMessagesResponse, error) - // Subscribe stream of new group messages - SubscribeGroupMessages(*SubscribeGroupMessagesRequest, MlsApi_SubscribeGroupMessagesServer) error - // Subscribe stream of new welcome messages - SubscribeWelcomeMessages(*SubscribeWelcomeMessagesRequest, MlsApi_SubscribeWelcomeMessagesServer) error - BatchPublishCommitLog(context.Context, *BatchPublishCommitLogRequest) (*emptypb.Empty, error) - BatchQueryCommitLog(context.Context, *BatchQueryCommitLogRequest) (*BatchQueryCommitLogResponse, error) - GetNewestGroupMessage(context.Context, *GetNewestGroupMessageRequest) (*GetNewestGroupMessageResponse, error) - mustEmbedUnimplementedMlsApiServer() -} - -// UnimplementedMlsApiServer must be embedded to have forward compatible implementations. -type UnimplementedMlsApiServer struct { -} - -func (UnimplementedMlsApiServer) SendGroupMessages(context.Context, *SendGroupMessagesRequest) (*emptypb.Empty, error) { - return nil, status.Errorf(codes.Unimplemented, "method SendGroupMessages not implemented") -} -func (UnimplementedMlsApiServer) SendWelcomeMessages(context.Context, *SendWelcomeMessagesRequest) (*emptypb.Empty, error) { - return nil, status.Errorf(codes.Unimplemented, "method SendWelcomeMessages not implemented") -} -func (UnimplementedMlsApiServer) RegisterInstallation(context.Context, *RegisterInstallationRequest) (*RegisterInstallationResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method RegisterInstallation not implemented") -} -func (UnimplementedMlsApiServer) UploadKeyPackage(context.Context, *UploadKeyPackageRequest) (*emptypb.Empty, error) { - return nil, status.Errorf(codes.Unimplemented, "method UploadKeyPackage not implemented") -} -func (UnimplementedMlsApiServer) FetchKeyPackages(context.Context, *FetchKeyPackagesRequest) (*FetchKeyPackagesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method FetchKeyPackages not implemented") -} -func (UnimplementedMlsApiServer) RevokeInstallation(context.Context, *RevokeInstallationRequest) (*emptypb.Empty, error) { - return nil, status.Errorf(codes.Unimplemented, "method RevokeInstallation not implemented") -} -func (UnimplementedMlsApiServer) GetIdentityUpdates(context.Context, *GetIdentityUpdatesRequest) (*GetIdentityUpdatesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetIdentityUpdates not implemented") -} -func (UnimplementedMlsApiServer) QueryGroupMessages(context.Context, *QueryGroupMessagesRequest) (*QueryGroupMessagesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method QueryGroupMessages not implemented") -} -func (UnimplementedMlsApiServer) QueryWelcomeMessages(context.Context, *QueryWelcomeMessagesRequest) (*QueryWelcomeMessagesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method QueryWelcomeMessages not implemented") -} -func (UnimplementedMlsApiServer) SubscribeGroupMessages(*SubscribeGroupMessagesRequest, MlsApi_SubscribeGroupMessagesServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeGroupMessages not implemented") -} -func (UnimplementedMlsApiServer) SubscribeWelcomeMessages(*SubscribeWelcomeMessagesRequest, MlsApi_SubscribeWelcomeMessagesServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeWelcomeMessages not implemented") -} -func (UnimplementedMlsApiServer) BatchPublishCommitLog(context.Context, *BatchPublishCommitLogRequest) (*emptypb.Empty, error) { - return nil, status.Errorf(codes.Unimplemented, "method BatchPublishCommitLog not implemented") -} -func (UnimplementedMlsApiServer) BatchQueryCommitLog(context.Context, *BatchQueryCommitLogRequest) (*BatchQueryCommitLogResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method BatchQueryCommitLog not implemented") -} -func (UnimplementedMlsApiServer) GetNewestGroupMessage(context.Context, *GetNewestGroupMessageRequest) (*GetNewestGroupMessageResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetNewestGroupMessage not implemented") -} -func (UnimplementedMlsApiServer) mustEmbedUnimplementedMlsApiServer() {} - -// UnsafeMlsApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to MlsApiServer will -// result in compilation errors. -type UnsafeMlsApiServer interface { - mustEmbedUnimplementedMlsApiServer() -} - -func RegisterMlsApiServer(s grpc.ServiceRegistrar, srv MlsApiServer) { - s.RegisterService(&MlsApi_ServiceDesc, srv) -} - -func _MlsApi_SendGroupMessages_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SendGroupMessagesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).SendGroupMessages(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_SendGroupMessages_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).SendGroupMessages(ctx, req.(*SendGroupMessagesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_SendWelcomeMessages_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SendWelcomeMessagesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).SendWelcomeMessages(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_SendWelcomeMessages_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).SendWelcomeMessages(ctx, req.(*SendWelcomeMessagesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_RegisterInstallation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(RegisterInstallationRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).RegisterInstallation(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_RegisterInstallation_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).RegisterInstallation(ctx, req.(*RegisterInstallationRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_UploadKeyPackage_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(UploadKeyPackageRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).UploadKeyPackage(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_UploadKeyPackage_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).UploadKeyPackage(ctx, req.(*UploadKeyPackageRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_FetchKeyPackages_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(FetchKeyPackagesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).FetchKeyPackages(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_FetchKeyPackages_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).FetchKeyPackages(ctx, req.(*FetchKeyPackagesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_RevokeInstallation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(RevokeInstallationRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).RevokeInstallation(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_RevokeInstallation_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).RevokeInstallation(ctx, req.(*RevokeInstallationRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_GetIdentityUpdates_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetIdentityUpdatesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).GetIdentityUpdates(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_GetIdentityUpdates_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).GetIdentityUpdates(ctx, req.(*GetIdentityUpdatesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_QueryGroupMessages_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QueryGroupMessagesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).QueryGroupMessages(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_QueryGroupMessages_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).QueryGroupMessages(ctx, req.(*QueryGroupMessagesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_QueryWelcomeMessages_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QueryWelcomeMessagesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).QueryWelcomeMessages(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_QueryWelcomeMessages_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).QueryWelcomeMessages(ctx, req.(*QueryWelcomeMessagesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_SubscribeGroupMessages_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeGroupMessagesRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(MlsApiServer).SubscribeGroupMessages(m, &mlsApiSubscribeGroupMessagesServer{stream}) -} - -type MlsApi_SubscribeGroupMessagesServer interface { - Send(*GroupMessage) error - grpc.ServerStream -} - -type mlsApiSubscribeGroupMessagesServer struct { - grpc.ServerStream -} - -func (x *mlsApiSubscribeGroupMessagesServer) Send(m *GroupMessage) error { - return x.ServerStream.SendMsg(m) -} - -func _MlsApi_SubscribeWelcomeMessages_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeWelcomeMessagesRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(MlsApiServer).SubscribeWelcomeMessages(m, &mlsApiSubscribeWelcomeMessagesServer{stream}) -} - -type MlsApi_SubscribeWelcomeMessagesServer interface { - Send(*WelcomeMessage) error - grpc.ServerStream -} - -type mlsApiSubscribeWelcomeMessagesServer struct { - grpc.ServerStream -} - -func (x *mlsApiSubscribeWelcomeMessagesServer) Send(m *WelcomeMessage) error { - return x.ServerStream.SendMsg(m) -} - -func _MlsApi_BatchPublishCommitLog_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(BatchPublishCommitLogRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).BatchPublishCommitLog(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_BatchPublishCommitLog_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).BatchPublishCommitLog(ctx, req.(*BatchPublishCommitLogRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_BatchQueryCommitLog_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(BatchQueryCommitLogRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).BatchQueryCommitLog(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_BatchQueryCommitLog_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).BatchQueryCommitLog(ctx, req.(*BatchQueryCommitLogRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MlsApi_GetNewestGroupMessage_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetNewestGroupMessageRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MlsApiServer).GetNewestGroupMessage(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MlsApi_GetNewestGroupMessage_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MlsApiServer).GetNewestGroupMessage(ctx, req.(*GetNewestGroupMessageRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// MlsApi_ServiceDesc is the grpc.ServiceDesc for MlsApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var MlsApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.mls.api.v1.MlsApi", - HandlerType: (*MlsApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "SendGroupMessages", - Handler: _MlsApi_SendGroupMessages_Handler, - }, - { - MethodName: "SendWelcomeMessages", - Handler: _MlsApi_SendWelcomeMessages_Handler, - }, - { - MethodName: "RegisterInstallation", - Handler: _MlsApi_RegisterInstallation_Handler, - }, - { - MethodName: "UploadKeyPackage", - Handler: _MlsApi_UploadKeyPackage_Handler, - }, - { - MethodName: "FetchKeyPackages", - Handler: _MlsApi_FetchKeyPackages_Handler, - }, - { - MethodName: "RevokeInstallation", - Handler: _MlsApi_RevokeInstallation_Handler, - }, - { - MethodName: "GetIdentityUpdates", - Handler: _MlsApi_GetIdentityUpdates_Handler, - }, - { - MethodName: "QueryGroupMessages", - Handler: _MlsApi_QueryGroupMessages_Handler, - }, - { - MethodName: "QueryWelcomeMessages", - Handler: _MlsApi_QueryWelcomeMessages_Handler, - }, - { - MethodName: "BatchPublishCommitLog", - Handler: _MlsApi_BatchPublishCommitLog_Handler, - }, - { - MethodName: "BatchQueryCommitLog", - Handler: _MlsApi_BatchQueryCommitLog_Handler, - }, - { - MethodName: "GetNewestGroupMessage", - Handler: _MlsApi_GetNewestGroupMessage_Handler, - }, - }, - Streams: []grpc.StreamDesc{ - { - StreamName: "SubscribeGroupMessages", - Handler: _MlsApi_SubscribeGroupMessages_Handler, - ServerStreams: true, - }, - { - StreamName: "SubscribeWelcomeMessages", - Handler: _MlsApi_SubscribeWelcomeMessages_Handler, - ServerStreams: true, - }, - }, - Metadata: "mls/api/v1/mls.proto", -} diff --git a/pkg/proto/mls/database/intents.pb.go b/pkg/proto/mls/database/intents.pb.go deleted file mode 100644 index 2b2e63fb..00000000 --- a/pkg/proto/mls/database/intents.pb.go +++ /dev/null @@ -1,2111 +0,0 @@ -// Intent protos that are stored in the libxmtp database - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/database/intents.proto - -package database - -import ( - message_contents "github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Type of update to admin lists -type AdminListUpdateType int32 - -const ( - AdminListUpdateType_ADMIN_LIST_UPDATE_TYPE_UNSPECIFIED AdminListUpdateType = 0 - AdminListUpdateType_ADMIN_LIST_UPDATE_TYPE_ADD_ADMIN AdminListUpdateType = 1 - AdminListUpdateType_ADMIN_LIST_UPDATE_TYPE_REMOVE_ADMIN AdminListUpdateType = 2 - AdminListUpdateType_ADMIN_LIST_UPDATE_TYPE_ADD_SUPER_ADMIN AdminListUpdateType = 3 - AdminListUpdateType_ADMIN_LIST_UPDATE_TYPE_REMOVE_SUPER_ADMIN AdminListUpdateType = 4 -) - -// Enum value maps for AdminListUpdateType. -var ( - AdminListUpdateType_name = map[int32]string{ - 0: "ADMIN_LIST_UPDATE_TYPE_UNSPECIFIED", - 1: "ADMIN_LIST_UPDATE_TYPE_ADD_ADMIN", - 2: "ADMIN_LIST_UPDATE_TYPE_REMOVE_ADMIN", - 3: "ADMIN_LIST_UPDATE_TYPE_ADD_SUPER_ADMIN", - 4: "ADMIN_LIST_UPDATE_TYPE_REMOVE_SUPER_ADMIN", - } - AdminListUpdateType_value = map[string]int32{ - "ADMIN_LIST_UPDATE_TYPE_UNSPECIFIED": 0, - "ADMIN_LIST_UPDATE_TYPE_ADD_ADMIN": 1, - "ADMIN_LIST_UPDATE_TYPE_REMOVE_ADMIN": 2, - "ADMIN_LIST_UPDATE_TYPE_ADD_SUPER_ADMIN": 3, - "ADMIN_LIST_UPDATE_TYPE_REMOVE_SUPER_ADMIN": 4, - } -) - -func (x AdminListUpdateType) Enum() *AdminListUpdateType { - p := new(AdminListUpdateType) - *p = x - return p -} - -func (x AdminListUpdateType) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (AdminListUpdateType) Descriptor() protoreflect.EnumDescriptor { - return file_mls_database_intents_proto_enumTypes[0].Descriptor() -} - -func (AdminListUpdateType) Type() protoreflect.EnumType { - return &file_mls_database_intents_proto_enumTypes[0] -} - -func (x AdminListUpdateType) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use AdminListUpdateType.Descriptor instead. -func (AdminListUpdateType) EnumDescriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{0} -} - -// Type of Permission to Update -type PermissionUpdateType int32 - -const ( - PermissionUpdateType_PERMISSION_UPDATE_TYPE_UNSPECIFIED PermissionUpdateType = 0 - PermissionUpdateType_PERMISSION_UPDATE_TYPE_ADD_MEMBER PermissionUpdateType = 1 - PermissionUpdateType_PERMISSION_UPDATE_TYPE_REMOVE_MEMBER PermissionUpdateType = 2 - PermissionUpdateType_PERMISSION_UPDATE_TYPE_ADD_ADMIN PermissionUpdateType = 3 - PermissionUpdateType_PERMISSION_UPDATE_TYPE_REMOVE_ADMIN PermissionUpdateType = 4 - PermissionUpdateType_PERMISSION_UPDATE_TYPE_UPDATE_METADATA PermissionUpdateType = 5 -) - -// Enum value maps for PermissionUpdateType. -var ( - PermissionUpdateType_name = map[int32]string{ - 0: "PERMISSION_UPDATE_TYPE_UNSPECIFIED", - 1: "PERMISSION_UPDATE_TYPE_ADD_MEMBER", - 2: "PERMISSION_UPDATE_TYPE_REMOVE_MEMBER", - 3: "PERMISSION_UPDATE_TYPE_ADD_ADMIN", - 4: "PERMISSION_UPDATE_TYPE_REMOVE_ADMIN", - 5: "PERMISSION_UPDATE_TYPE_UPDATE_METADATA", - } - PermissionUpdateType_value = map[string]int32{ - "PERMISSION_UPDATE_TYPE_UNSPECIFIED": 0, - "PERMISSION_UPDATE_TYPE_ADD_MEMBER": 1, - "PERMISSION_UPDATE_TYPE_REMOVE_MEMBER": 2, - "PERMISSION_UPDATE_TYPE_ADD_ADMIN": 3, - "PERMISSION_UPDATE_TYPE_REMOVE_ADMIN": 4, - "PERMISSION_UPDATE_TYPE_UPDATE_METADATA": 5, - } -) - -func (x PermissionUpdateType) Enum() *PermissionUpdateType { - p := new(PermissionUpdateType) - *p = x - return p -} - -func (x PermissionUpdateType) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (PermissionUpdateType) Descriptor() protoreflect.EnumDescriptor { - return file_mls_database_intents_proto_enumTypes[1].Descriptor() -} - -func (PermissionUpdateType) Type() protoreflect.EnumType { - return &file_mls_database_intents_proto_enumTypes[1] -} - -func (x PermissionUpdateType) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use PermissionUpdateType.Descriptor instead. -func (PermissionUpdateType) EnumDescriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{1} -} - -// Permission Policy -type PermissionPolicyOption int32 - -const ( - PermissionPolicyOption_PERMISSION_POLICY_OPTION_UNSPECIFIED PermissionPolicyOption = 0 - PermissionPolicyOption_PERMISSION_POLICY_OPTION_ALLOW PermissionPolicyOption = 1 - PermissionPolicyOption_PERMISSION_POLICY_OPTION_DENY PermissionPolicyOption = 2 - PermissionPolicyOption_PERMISSION_POLICY_OPTION_ADMIN_ONLY PermissionPolicyOption = 3 - PermissionPolicyOption_PERMISSION_POLICY_OPTION_SUPER_ADMIN_ONLY PermissionPolicyOption = 4 -) - -// Enum value maps for PermissionPolicyOption. -var ( - PermissionPolicyOption_name = map[int32]string{ - 0: "PERMISSION_POLICY_OPTION_UNSPECIFIED", - 1: "PERMISSION_POLICY_OPTION_ALLOW", - 2: "PERMISSION_POLICY_OPTION_DENY", - 3: "PERMISSION_POLICY_OPTION_ADMIN_ONLY", - 4: "PERMISSION_POLICY_OPTION_SUPER_ADMIN_ONLY", - } - PermissionPolicyOption_value = map[string]int32{ - "PERMISSION_POLICY_OPTION_UNSPECIFIED": 0, - "PERMISSION_POLICY_OPTION_ALLOW": 1, - "PERMISSION_POLICY_OPTION_DENY": 2, - "PERMISSION_POLICY_OPTION_ADMIN_ONLY": 3, - "PERMISSION_POLICY_OPTION_SUPER_ADMIN_ONLY": 4, - } -) - -func (x PermissionPolicyOption) Enum() *PermissionPolicyOption { - p := new(PermissionPolicyOption) - *p = x - return p -} - -func (x PermissionPolicyOption) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (PermissionPolicyOption) Descriptor() protoreflect.EnumDescriptor { - return file_mls_database_intents_proto_enumTypes[2].Descriptor() -} - -func (PermissionPolicyOption) Type() protoreflect.EnumType { - return &file_mls_database_intents_proto_enumTypes[2] -} - -func (x PermissionPolicyOption) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use PermissionPolicyOption.Descriptor instead. -func (PermissionPolicyOption) EnumDescriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{2} -} - -// The data required to publish a message -type SendMessageData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *SendMessageData_V1_ - Version isSendMessageData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SendMessageData) Reset() { - *x = SendMessageData{} - mi := &file_mls_database_intents_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SendMessageData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SendMessageData) ProtoMessage() {} - -func (x *SendMessageData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SendMessageData.ProtoReflect.Descriptor instead. -func (*SendMessageData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{0} -} - -func (x *SendMessageData) GetVersion() isSendMessageData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *SendMessageData) GetV1() *SendMessageData_V1 { - if x != nil { - if x, ok := x.Version.(*SendMessageData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isSendMessageData_Version interface { - isSendMessageData_Version() -} - -type SendMessageData_V1_ struct { - V1 *SendMessageData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*SendMessageData_V1_) isSendMessageData_Version() {} - -// Wrapper around a list af repeated EVM Account Addresses -type AccountAddresses struct { - state protoimpl.MessageState `protogen:"open.v1"` - AccountAddresses []string `protobuf:"bytes,1,rep,name=account_addresses,json=accountAddresses,proto3" json:"account_addresses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AccountAddresses) Reset() { - *x = AccountAddresses{} - mi := &file_mls_database_intents_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AccountAddresses) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AccountAddresses) ProtoMessage() {} - -func (x *AccountAddresses) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AccountAddresses.ProtoReflect.Descriptor instead. -func (*AccountAddresses) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{1} -} - -func (x *AccountAddresses) GetAccountAddresses() []string { - if x != nil { - return x.AccountAddresses - } - return nil -} - -// Wrapper around a list of repeated Installation IDs -type InstallationIds struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationIds [][]byte `protobuf:"bytes,1,rep,name=installation_ids,json=installationIds,proto3" json:"installation_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *InstallationIds) Reset() { - *x = InstallationIds{} - mi := &file_mls_database_intents_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *InstallationIds) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*InstallationIds) ProtoMessage() {} - -func (x *InstallationIds) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use InstallationIds.ProtoReflect.Descriptor instead. -func (*InstallationIds) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{2} -} - -func (x *InstallationIds) GetInstallationIds() [][]byte { - if x != nil { - return x.InstallationIds - } - return nil -} - -// One of an EVM account address or Installation ID -type AddressesOrInstallationIds struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to AddressesOrInstallationIds: - // - // *AddressesOrInstallationIds_AccountAddresses - // *AddressesOrInstallationIds_InstallationIds - AddressesOrInstallationIds isAddressesOrInstallationIds_AddressesOrInstallationIds `protobuf_oneof:"addresses_or_installation_ids"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AddressesOrInstallationIds) Reset() { - *x = AddressesOrInstallationIds{} - mi := &file_mls_database_intents_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AddressesOrInstallationIds) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AddressesOrInstallationIds) ProtoMessage() {} - -func (x *AddressesOrInstallationIds) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AddressesOrInstallationIds.ProtoReflect.Descriptor instead. -func (*AddressesOrInstallationIds) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{3} -} - -func (x *AddressesOrInstallationIds) GetAddressesOrInstallationIds() isAddressesOrInstallationIds_AddressesOrInstallationIds { - if x != nil { - return x.AddressesOrInstallationIds - } - return nil -} - -func (x *AddressesOrInstallationIds) GetAccountAddresses() *AccountAddresses { - if x != nil { - if x, ok := x.AddressesOrInstallationIds.(*AddressesOrInstallationIds_AccountAddresses); ok { - return x.AccountAddresses - } - } - return nil -} - -func (x *AddressesOrInstallationIds) GetInstallationIds() *InstallationIds { - if x != nil { - if x, ok := x.AddressesOrInstallationIds.(*AddressesOrInstallationIds_InstallationIds); ok { - return x.InstallationIds - } - } - return nil -} - -type isAddressesOrInstallationIds_AddressesOrInstallationIds interface { - isAddressesOrInstallationIds_AddressesOrInstallationIds() -} - -type AddressesOrInstallationIds_AccountAddresses struct { - AccountAddresses *AccountAddresses `protobuf:"bytes,1,opt,name=account_addresses,json=accountAddresses,proto3,oneof"` -} - -type AddressesOrInstallationIds_InstallationIds struct { - InstallationIds *InstallationIds `protobuf:"bytes,2,opt,name=installation_ids,json=installationIds,proto3,oneof"` -} - -func (*AddressesOrInstallationIds_AccountAddresses) isAddressesOrInstallationIds_AddressesOrInstallationIds() { -} - -func (*AddressesOrInstallationIds_InstallationIds) isAddressesOrInstallationIds_AddressesOrInstallationIds() { -} - -// DEPRECATED -// The data required to add members to a group -type AddMembersData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *AddMembersData_V1_ - Version isAddMembersData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AddMembersData) Reset() { - *x = AddMembersData{} - mi := &file_mls_database_intents_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AddMembersData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AddMembersData) ProtoMessage() {} - -func (x *AddMembersData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AddMembersData.ProtoReflect.Descriptor instead. -func (*AddMembersData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{4} -} - -func (x *AddMembersData) GetVersion() isAddMembersData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *AddMembersData) GetV1() *AddMembersData_V1 { - if x != nil { - if x, ok := x.Version.(*AddMembersData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isAddMembersData_Version interface { - isAddMembersData_Version() -} - -type AddMembersData_V1_ struct { - V1 *AddMembersData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*AddMembersData_V1_) isAddMembersData_Version() {} - -// DEPRECATED -// The data required to remove members from a group -type RemoveMembersData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *RemoveMembersData_V1_ - Version isRemoveMembersData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RemoveMembersData) Reset() { - *x = RemoveMembersData{} - mi := &file_mls_database_intents_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RemoveMembersData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RemoveMembersData) ProtoMessage() {} - -func (x *RemoveMembersData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RemoveMembersData.ProtoReflect.Descriptor instead. -func (*RemoveMembersData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{5} -} - -func (x *RemoveMembersData) GetVersion() isRemoveMembersData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *RemoveMembersData) GetV1() *RemoveMembersData_V1 { - if x != nil { - if x, ok := x.Version.(*RemoveMembersData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isRemoveMembersData_Version interface { - isRemoveMembersData_Version() -} - -type RemoveMembersData_V1_ struct { - V1 *RemoveMembersData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*RemoveMembersData_V1_) isRemoveMembersData_Version() {} - -// The data required to make a commit that updates group membership -// Handles both Add and Remove actions -type UpdateGroupMembershipData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *UpdateGroupMembershipData_V1_ - Version isUpdateGroupMembershipData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UpdateGroupMembershipData) Reset() { - *x = UpdateGroupMembershipData{} - mi := &file_mls_database_intents_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UpdateGroupMembershipData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UpdateGroupMembershipData) ProtoMessage() {} - -func (x *UpdateGroupMembershipData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UpdateGroupMembershipData.ProtoReflect.Descriptor instead. -func (*UpdateGroupMembershipData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{6} -} - -func (x *UpdateGroupMembershipData) GetVersion() isUpdateGroupMembershipData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *UpdateGroupMembershipData) GetV1() *UpdateGroupMembershipData_V1 { - if x != nil { - if x, ok := x.Version.(*UpdateGroupMembershipData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isUpdateGroupMembershipData_Version interface { - isUpdateGroupMembershipData_Version() -} - -type UpdateGroupMembershipData_V1_ struct { - V1 *UpdateGroupMembershipData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*UpdateGroupMembershipData_V1_) isUpdateGroupMembershipData_Version() {} - -// The data required to remove and readd existing leaf nodes -// on the MLS tree. Does not change or update the members list. -// Used for fork recovery -type ReaddInstallationsData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *ReaddInstallationsData_V1_ - Version isReaddInstallationsData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ReaddInstallationsData) Reset() { - *x = ReaddInstallationsData{} - mi := &file_mls_database_intents_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ReaddInstallationsData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ReaddInstallationsData) ProtoMessage() {} - -func (x *ReaddInstallationsData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ReaddInstallationsData.ProtoReflect.Descriptor instead. -func (*ReaddInstallationsData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{7} -} - -func (x *ReaddInstallationsData) GetVersion() isReaddInstallationsData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *ReaddInstallationsData) GetV1() *ReaddInstallationsData_V1 { - if x != nil { - if x, ok := x.Version.(*ReaddInstallationsData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isReaddInstallationsData_Version interface { - isReaddInstallationsData_Version() -} - -type ReaddInstallationsData_V1_ struct { - V1 *ReaddInstallationsData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*ReaddInstallationsData_V1_) isReaddInstallationsData_Version() {} - -// The data required to update group metadata -type UpdateMetadataData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *UpdateMetadataData_V1_ - Version isUpdateMetadataData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UpdateMetadataData) Reset() { - *x = UpdateMetadataData{} - mi := &file_mls_database_intents_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UpdateMetadataData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UpdateMetadataData) ProtoMessage() {} - -func (x *UpdateMetadataData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UpdateMetadataData.ProtoReflect.Descriptor instead. -func (*UpdateMetadataData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{8} -} - -func (x *UpdateMetadataData) GetVersion() isUpdateMetadataData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *UpdateMetadataData) GetV1() *UpdateMetadataData_V1 { - if x != nil { - if x, ok := x.Version.(*UpdateMetadataData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isUpdateMetadataData_Version interface { - isUpdateMetadataData_Version() -} - -type UpdateMetadataData_V1_ struct { - V1 *UpdateMetadataData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*UpdateMetadataData_V1_) isUpdateMetadataData_Version() {} - -// The data required to update group admin/super admin lists -type UpdateAdminListsData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *UpdateAdminListsData_V1_ - Version isUpdateAdminListsData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UpdateAdminListsData) Reset() { - *x = UpdateAdminListsData{} - mi := &file_mls_database_intents_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UpdateAdminListsData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UpdateAdminListsData) ProtoMessage() {} - -func (x *UpdateAdminListsData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UpdateAdminListsData.ProtoReflect.Descriptor instead. -func (*UpdateAdminListsData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{9} -} - -func (x *UpdateAdminListsData) GetVersion() isUpdateAdminListsData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *UpdateAdminListsData) GetV1() *UpdateAdminListsData_V1 { - if x != nil { - if x, ok := x.Version.(*UpdateAdminListsData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isUpdateAdminListsData_Version interface { - isUpdateAdminListsData_Version() -} - -type UpdateAdminListsData_V1_ struct { - V1 *UpdateAdminListsData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*UpdateAdminListsData_V1_) isUpdateAdminListsData_Version() {} - -// The data required to update permissions -type UpdatePermissionData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *UpdatePermissionData_V1_ - Version isUpdatePermissionData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UpdatePermissionData) Reset() { - *x = UpdatePermissionData{} - mi := &file_mls_database_intents_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UpdatePermissionData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UpdatePermissionData) ProtoMessage() {} - -func (x *UpdatePermissionData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UpdatePermissionData.ProtoReflect.Descriptor instead. -func (*UpdatePermissionData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{10} -} - -func (x *UpdatePermissionData) GetVersion() isUpdatePermissionData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *UpdatePermissionData) GetV1() *UpdatePermissionData_V1 { - if x != nil { - if x, ok := x.Version.(*UpdatePermissionData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isUpdatePermissionData_Version interface { - isUpdatePermissionData_Version() -} - -type UpdatePermissionData_V1_ struct { - V1 *UpdatePermissionData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*UpdatePermissionData_V1_) isUpdatePermissionData_Version() {} - -// Generic data-type for all post-commit actions -type PostCommitAction struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Kind: - // - // *PostCommitAction_SendWelcomes_ - Kind isPostCommitAction_Kind `protobuf_oneof:"kind"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PostCommitAction) Reset() { - *x = PostCommitAction{} - mi := &file_mls_database_intents_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PostCommitAction) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PostCommitAction) ProtoMessage() {} - -func (x *PostCommitAction) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PostCommitAction.ProtoReflect.Descriptor instead. -func (*PostCommitAction) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{11} -} - -func (x *PostCommitAction) GetKind() isPostCommitAction_Kind { - if x != nil { - return x.Kind - } - return nil -} - -func (x *PostCommitAction) GetSendWelcomes() *PostCommitAction_SendWelcomes { - if x != nil { - if x, ok := x.Kind.(*PostCommitAction_SendWelcomes_); ok { - return x.SendWelcomes - } - } - return nil -} - -type isPostCommitAction_Kind interface { - isPostCommitAction_Kind() -} - -type PostCommitAction_SendWelcomes_ struct { - SendWelcomes *PostCommitAction_SendWelcomes `protobuf:"bytes,1,opt,name=send_welcomes,json=sendWelcomes,proto3,oneof"` -} - -func (*PostCommitAction_SendWelcomes_) isPostCommitAction_Kind() {} - -type ProposeMemberUpdateData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *ProposeMemberUpdateData_V1_ - Version isProposeMemberUpdateData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ProposeMemberUpdateData) Reset() { - *x = ProposeMemberUpdateData{} - mi := &file_mls_database_intents_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ProposeMemberUpdateData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ProposeMemberUpdateData) ProtoMessage() {} - -func (x *ProposeMemberUpdateData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[12] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ProposeMemberUpdateData.ProtoReflect.Descriptor instead. -func (*ProposeMemberUpdateData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{12} -} - -func (x *ProposeMemberUpdateData) GetVersion() isProposeMemberUpdateData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *ProposeMemberUpdateData) GetV1() *ProposeMemberUpdateData_V1 { - if x != nil { - if x, ok := x.Version.(*ProposeMemberUpdateData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isProposeMemberUpdateData_Version interface { - isProposeMemberUpdateData_Version() -} - -type ProposeMemberUpdateData_V1_ struct { - V1 *ProposeMemberUpdateData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*ProposeMemberUpdateData_V1_) isProposeMemberUpdateData_Version() {} - -type ProposeGroupContextExtensionData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *ProposeGroupContextExtensionData_V1_ - Version isProposeGroupContextExtensionData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ProposeGroupContextExtensionData) Reset() { - *x = ProposeGroupContextExtensionData{} - mi := &file_mls_database_intents_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ProposeGroupContextExtensionData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ProposeGroupContextExtensionData) ProtoMessage() {} - -func (x *ProposeGroupContextExtensionData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[13] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ProposeGroupContextExtensionData.ProtoReflect.Descriptor instead. -func (*ProposeGroupContextExtensionData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{13} -} - -func (x *ProposeGroupContextExtensionData) GetVersion() isProposeGroupContextExtensionData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *ProposeGroupContextExtensionData) GetV1() *ProposeGroupContextExtensionData_V1 { - if x != nil { - if x, ok := x.Version.(*ProposeGroupContextExtensionData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isProposeGroupContextExtensionData_Version interface { - isProposeGroupContextExtensionData_Version() -} - -type ProposeGroupContextExtensionData_V1_ struct { - V1 *ProposeGroupContextExtensionData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*ProposeGroupContextExtensionData_V1_) isProposeGroupContextExtensionData_Version() {} - -type CommitPendingProposalsData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *CommitPendingProposalsData_V1_ - Version isCommitPendingProposalsData_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *CommitPendingProposalsData) Reset() { - *x = CommitPendingProposalsData{} - mi := &file_mls_database_intents_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *CommitPendingProposalsData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CommitPendingProposalsData) ProtoMessage() {} - -func (x *CommitPendingProposalsData) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[14] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CommitPendingProposalsData.ProtoReflect.Descriptor instead. -func (*CommitPendingProposalsData) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{14} -} - -func (x *CommitPendingProposalsData) GetVersion() isCommitPendingProposalsData_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *CommitPendingProposalsData) GetV1() *CommitPendingProposalsData_V1 { - if x != nil { - if x, ok := x.Version.(*CommitPendingProposalsData_V1_); ok { - return x.V1 - } - } - return nil -} - -type isCommitPendingProposalsData_Version interface { - isCommitPendingProposalsData_Version() -} - -type CommitPendingProposalsData_V1_ struct { - V1 *CommitPendingProposalsData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -func (*CommitPendingProposalsData_V1_) isCommitPendingProposalsData_Version() {} - -// V1 of SendMessagePublishData -type SendMessageData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - PayloadBytes []byte `protobuf:"bytes,1,opt,name=payload_bytes,json=payloadBytes,proto3" json:"payload_bytes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SendMessageData_V1) Reset() { - *x = SendMessageData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SendMessageData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SendMessageData_V1) ProtoMessage() {} - -func (x *SendMessageData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[15] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SendMessageData_V1.ProtoReflect.Descriptor instead. -func (*SendMessageData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *SendMessageData_V1) GetPayloadBytes() []byte { - if x != nil { - return x.PayloadBytes - } - return nil -} - -// V1 of AddMembersPublishData -type AddMembersData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - AddressesOrInstallationIds *AddressesOrInstallationIds `protobuf:"bytes,1,opt,name=addresses_or_installation_ids,json=addressesOrInstallationIds,proto3" json:"addresses_or_installation_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AddMembersData_V1) Reset() { - *x = AddMembersData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AddMembersData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AddMembersData_V1) ProtoMessage() {} - -func (x *AddMembersData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[16] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AddMembersData_V1.ProtoReflect.Descriptor instead. -func (*AddMembersData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{4, 0} -} - -func (x *AddMembersData_V1) GetAddressesOrInstallationIds() *AddressesOrInstallationIds { - if x != nil { - return x.AddressesOrInstallationIds - } - return nil -} - -// V1 of RemoveMembersPublishData -type RemoveMembersData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - AddressesOrInstallationIds *AddressesOrInstallationIds `protobuf:"bytes,1,opt,name=addresses_or_installation_ids,json=addressesOrInstallationIds,proto3" json:"addresses_or_installation_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RemoveMembersData_V1) Reset() { - *x = RemoveMembersData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RemoveMembersData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RemoveMembersData_V1) ProtoMessage() {} - -func (x *RemoveMembersData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[17] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RemoveMembersData_V1.ProtoReflect.Descriptor instead. -func (*RemoveMembersData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{5, 0} -} - -func (x *RemoveMembersData_V1) GetAddressesOrInstallationIds() *AddressesOrInstallationIds { - if x != nil { - return x.AddressesOrInstallationIds - } - return nil -} - -// V1 of UpdateGroupMembershipPublishData -type UpdateGroupMembershipData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Contains delta of membership updates that need to be applied - MembershipUpdates map[string]uint64 `protobuf:"bytes,1,rep,name=membership_updates,json=membershipUpdates,proto3" json:"membership_updates,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"varint,2,opt,name=value"` - // Contains the list of members that will be removed - RemovedMembers []string `protobuf:"bytes,2,rep,name=removed_members,json=removedMembers,proto3" json:"removed_members,omitempty"` - // List of installations that failed to be added due to errors encountered during the evaluation process. - FailedInstallations [][]byte `protobuf:"bytes,3,rep,name=failed_installations,json=failedInstallations,proto3" json:"failed_installations,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UpdateGroupMembershipData_V1) Reset() { - *x = UpdateGroupMembershipData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UpdateGroupMembershipData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UpdateGroupMembershipData_V1) ProtoMessage() {} - -func (x *UpdateGroupMembershipData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[18] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UpdateGroupMembershipData_V1.ProtoReflect.Descriptor instead. -func (*UpdateGroupMembershipData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{6, 0} -} - -func (x *UpdateGroupMembershipData_V1) GetMembershipUpdates() map[string]uint64 { - if x != nil { - return x.MembershipUpdates - } - return nil -} - -func (x *UpdateGroupMembershipData_V1) GetRemovedMembers() []string { - if x != nil { - return x.RemovedMembers - } - return nil -} - -func (x *UpdateGroupMembershipData_V1) GetFailedInstallations() [][]byte { - if x != nil { - return x.FailedInstallations - } - return nil -} - -type ReaddInstallationsData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - ReaddedInstallations [][]byte `protobuf:"bytes,1,rep,name=readded_installations,json=readdedInstallations,proto3" json:"readded_installations,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ReaddInstallationsData_V1) Reset() { - *x = ReaddInstallationsData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ReaddInstallationsData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ReaddInstallationsData_V1) ProtoMessage() {} - -func (x *ReaddInstallationsData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[20] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ReaddInstallationsData_V1.ProtoReflect.Descriptor instead. -func (*ReaddInstallationsData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{7, 0} -} - -func (x *ReaddInstallationsData_V1) GetReaddedInstallations() [][]byte { - if x != nil { - return x.ReaddedInstallations - } - return nil -} - -// V1 of UpdateMetadataPublishData -type UpdateMetadataData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - FieldName string `protobuf:"bytes,1,opt,name=field_name,json=fieldName,proto3" json:"field_name,omitempty"` - FieldValue string `protobuf:"bytes,2,opt,name=field_value,json=fieldValue,proto3" json:"field_value,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UpdateMetadataData_V1) Reset() { - *x = UpdateMetadataData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UpdateMetadataData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UpdateMetadataData_V1) ProtoMessage() {} - -func (x *UpdateMetadataData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[21] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UpdateMetadataData_V1.ProtoReflect.Descriptor instead. -func (*UpdateMetadataData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{8, 0} -} - -func (x *UpdateMetadataData_V1) GetFieldName() string { - if x != nil { - return x.FieldName - } - return "" -} - -func (x *UpdateMetadataData_V1) GetFieldValue() string { - if x != nil { - return x.FieldValue - } - return "" -} - -// V1 of UpdateAdminListsPublishData -type UpdateAdminListsData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - AdminListUpdateType AdminListUpdateType `protobuf:"varint,1,opt,name=admin_list_update_type,json=adminListUpdateType,proto3,enum=xmtp.mls.database.AdminListUpdateType" json:"admin_list_update_type,omitempty"` - InboxId string `protobuf:"bytes,2,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UpdateAdminListsData_V1) Reset() { - *x = UpdateAdminListsData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UpdateAdminListsData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UpdateAdminListsData_V1) ProtoMessage() {} - -func (x *UpdateAdminListsData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[22] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UpdateAdminListsData_V1.ProtoReflect.Descriptor instead. -func (*UpdateAdminListsData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{9, 0} -} - -func (x *UpdateAdminListsData_V1) GetAdminListUpdateType() AdminListUpdateType { - if x != nil { - return x.AdminListUpdateType - } - return AdminListUpdateType_ADMIN_LIST_UPDATE_TYPE_UNSPECIFIED -} - -func (x *UpdateAdminListsData_V1) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -// V1 of UpdatePermissionData -type UpdatePermissionData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - PermissionUpdateType PermissionUpdateType `protobuf:"varint,1,opt,name=permission_update_type,json=permissionUpdateType,proto3,enum=xmtp.mls.database.PermissionUpdateType" json:"permission_update_type,omitempty"` - PermissionPolicyOption PermissionPolicyOption `protobuf:"varint,2,opt,name=permission_policy_option,json=permissionPolicyOption,proto3,enum=xmtp.mls.database.PermissionPolicyOption" json:"permission_policy_option,omitempty"` - // Metadata permissions update specify which field permission they are updating - MetadataFieldName *string `protobuf:"bytes,3,opt,name=metadata_field_name,json=metadataFieldName,proto3,oneof" json:"metadata_field_name,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UpdatePermissionData_V1) Reset() { - *x = UpdatePermissionData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UpdatePermissionData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UpdatePermissionData_V1) ProtoMessage() {} - -func (x *UpdatePermissionData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[23] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UpdatePermissionData_V1.ProtoReflect.Descriptor instead. -func (*UpdatePermissionData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{10, 0} -} - -func (x *UpdatePermissionData_V1) GetPermissionUpdateType() PermissionUpdateType { - if x != nil { - return x.PermissionUpdateType - } - return PermissionUpdateType_PERMISSION_UPDATE_TYPE_UNSPECIFIED -} - -func (x *UpdatePermissionData_V1) GetPermissionPolicyOption() PermissionPolicyOption { - if x != nil { - return x.PermissionPolicyOption - } - return PermissionPolicyOption_PERMISSION_POLICY_OPTION_UNSPECIFIED -} - -func (x *UpdatePermissionData_V1) GetMetadataFieldName() string { - if x != nil && x.MetadataFieldName != nil { - return *x.MetadataFieldName - } - return "" -} - -// An installation -type PostCommitAction_Installation struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationKey []byte `protobuf:"bytes,1,opt,name=installation_key,json=installationKey,proto3" json:"installation_key,omitempty"` - HpkePublicKey []byte `protobuf:"bytes,2,opt,name=hpke_public_key,json=hpkePublicKey,proto3" json:"hpke_public_key,omitempty"` - WelcomeWrapperAlgorithm message_contents.WelcomeWrapperAlgorithm `protobuf:"varint,3,opt,name=welcome_wrapper_algorithm,json=welcomeWrapperAlgorithm,proto3,enum=xmtp.mls.message_contents.WelcomeWrapperAlgorithm" json:"welcome_wrapper_algorithm,omitempty"` - WelcomePointeeEncryptionAeadTypes *message_contents.WelcomePointeeEncryptionAeadTypesExtension `protobuf:"bytes,4,opt,name=welcome_pointee_encryption_aead_types,json=welcomePointeeEncryptionAeadTypes,proto3" json:"welcome_pointee_encryption_aead_types,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PostCommitAction_Installation) Reset() { - *x = PostCommitAction_Installation{} - mi := &file_mls_database_intents_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PostCommitAction_Installation) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PostCommitAction_Installation) ProtoMessage() {} - -func (x *PostCommitAction_Installation) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[24] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PostCommitAction_Installation.ProtoReflect.Descriptor instead. -func (*PostCommitAction_Installation) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{11, 0} -} - -func (x *PostCommitAction_Installation) GetInstallationKey() []byte { - if x != nil { - return x.InstallationKey - } - return nil -} - -func (x *PostCommitAction_Installation) GetHpkePublicKey() []byte { - if x != nil { - return x.HpkePublicKey - } - return nil -} - -func (x *PostCommitAction_Installation) GetWelcomeWrapperAlgorithm() message_contents.WelcomeWrapperAlgorithm { - if x != nil { - return x.WelcomeWrapperAlgorithm - } - return message_contents.WelcomeWrapperAlgorithm(0) -} - -func (x *PostCommitAction_Installation) GetWelcomePointeeEncryptionAeadTypes() *message_contents.WelcomePointeeEncryptionAeadTypesExtension { - if x != nil { - return x.WelcomePointeeEncryptionAeadTypes - } - return nil -} - -// SendWelcome message -type PostCommitAction_SendWelcomes struct { - state protoimpl.MessageState `protogen:"open.v1"` - Installations []*PostCommitAction_Installation `protobuf:"bytes,1,rep,name=installations,proto3" json:"installations,omitempty"` - WelcomeMessage []byte `protobuf:"bytes,2,opt,name=welcome_message,json=welcomeMessage,proto3" json:"welcome_message,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PostCommitAction_SendWelcomes) Reset() { - *x = PostCommitAction_SendWelcomes{} - mi := &file_mls_database_intents_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PostCommitAction_SendWelcomes) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PostCommitAction_SendWelcomes) ProtoMessage() {} - -func (x *PostCommitAction_SendWelcomes) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[25] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PostCommitAction_SendWelcomes.ProtoReflect.Descriptor instead. -func (*PostCommitAction_SendWelcomes) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{11, 1} -} - -func (x *PostCommitAction_SendWelcomes) GetInstallations() []*PostCommitAction_Installation { - if x != nil { - return x.Installations - } - return nil -} - -func (x *PostCommitAction_SendWelcomes) GetWelcomeMessage() []byte { - if x != nil { - return x.WelcomeMessage - } - return nil -} - -type ProposeMemberUpdateData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Not hex encoded - AddInboxIds [][]byte `protobuf:"bytes,1,rep,name=add_inbox_ids,json=addInboxIds,proto3" json:"add_inbox_ids,omitempty"` - RemoveInboxIds [][]byte `protobuf:"bytes,2,rep,name=remove_inbox_ids,json=removeInboxIds,proto3" json:"remove_inbox_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ProposeMemberUpdateData_V1) Reset() { - *x = ProposeMemberUpdateData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ProposeMemberUpdateData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ProposeMemberUpdateData_V1) ProtoMessage() {} - -func (x *ProposeMemberUpdateData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[26] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ProposeMemberUpdateData_V1.ProtoReflect.Descriptor instead. -func (*ProposeMemberUpdateData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{12, 0} -} - -func (x *ProposeMemberUpdateData_V1) GetAddInboxIds() [][]byte { - if x != nil { - return x.AddInboxIds - } - return nil -} - -func (x *ProposeMemberUpdateData_V1) GetRemoveInboxIds() [][]byte { - if x != nil { - return x.RemoveInboxIds - } - return nil -} - -type ProposeGroupContextExtensionData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupContextExtension []byte `protobuf:"bytes,1,opt,name=group_context_extension,json=groupContextExtension,proto3" json:"group_context_extension,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ProposeGroupContextExtensionData_V1) Reset() { - *x = ProposeGroupContextExtensionData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ProposeGroupContextExtensionData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ProposeGroupContextExtensionData_V1) ProtoMessage() {} - -func (x *ProposeGroupContextExtensionData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[27] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ProposeGroupContextExtensionData_V1.ProtoReflect.Descriptor instead. -func (*ProposeGroupContextExtensionData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{13, 0} -} - -func (x *ProposeGroupContextExtensionData_V1) GetGroupContextExtension() []byte { - if x != nil { - return x.GroupContextExtension - } - return nil -} - -type CommitPendingProposalsData_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - ProposalHashes [][]byte `protobuf:"bytes,1,rep,name=proposal_hashes,json=proposalHashes,proto3" json:"proposal_hashes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *CommitPendingProposalsData_V1) Reset() { - *x = CommitPendingProposalsData_V1{} - mi := &file_mls_database_intents_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *CommitPendingProposalsData_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CommitPendingProposalsData_V1) ProtoMessage() {} - -func (x *CommitPendingProposalsData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[28] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CommitPendingProposalsData_V1.ProtoReflect.Descriptor instead. -func (*CommitPendingProposalsData_V1) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{14, 0} -} - -func (x *CommitPendingProposalsData_V1) GetProposalHashes() [][]byte { - if x != nil { - return x.ProposalHashes - } - return nil -} - -var File_mls_database_intents_proto protoreflect.FileDescriptor - -const file_mls_database_intents_proto_rawDesc = "" + - "\n" + - "\x1amls/database/intents.proto\x12\x11xmtp.mls.database\x1a*mls/message_contents/welcome_pointer.proto\x1a-mls/message_contents/wrapper_encryption.proto\"\x80\x01\n" + - "\x0fSendMessageData\x127\n" + - "\x02v1\x18\x01 \x01(\v2%.xmtp.mls.database.SendMessageData.V1H\x00R\x02v1\x1a)\n" + - "\x02V1\x12#\n" + - "\rpayload_bytes\x18\x01 \x01(\fR\fpayloadBytesB\t\n" + - "\aversion\"?\n" + - "\x10AccountAddresses\x12+\n" + - "\x11account_addresses\x18\x01 \x03(\tR\x10accountAddresses\"<\n" + - "\x0fInstallationIds\x12)\n" + - "\x10installation_ids\x18\x01 \x03(\fR\x0finstallationIds\"\xe2\x01\n" + - "\x1aAddressesOrInstallationIds\x12R\n" + - "\x11account_addresses\x18\x01 \x01(\v2#.xmtp.mls.database.AccountAddressesH\x00R\x10accountAddresses\x12O\n" + - "\x10installation_ids\x18\x02 \x01(\v2\".xmtp.mls.database.InstallationIdsH\x00R\x0finstallationIdsB\x1f\n" + - "\x1daddresses_or_installation_ids\"\xcb\x01\n" + - "\x0eAddMembersData\x126\n" + - "\x02v1\x18\x01 \x01(\v2$.xmtp.mls.database.AddMembersData.V1H\x00R\x02v1\x1av\n" + - "\x02V1\x12p\n" + - "\x1daddresses_or_installation_ids\x18\x01 \x01(\v2-.xmtp.mls.database.AddressesOrInstallationIdsR\x1aaddressesOrInstallationIdsB\t\n" + - "\aversion\"\xd1\x01\n" + - "\x11RemoveMembersData\x129\n" + - "\x02v1\x18\x01 \x01(\v2'.xmtp.mls.database.RemoveMembersData.V1H\x00R\x02v1\x1av\n" + - "\x02V1\x12p\n" + - "\x1daddresses_or_installation_ids\x18\x01 \x01(\v2-.xmtp.mls.database.AddressesOrInstallationIdsR\x1aaddressesOrInstallationIdsB\t\n" + - "\aversion\"\x89\x03\n" + - "\x19UpdateGroupMembershipData\x12A\n" + - "\x02v1\x18\x01 \x01(\v2/.xmtp.mls.database.UpdateGroupMembershipData.V1H\x00R\x02v1\x1a\x9d\x02\n" + - "\x02V1\x12u\n" + - "\x12membership_updates\x18\x01 \x03(\v2F.xmtp.mls.database.UpdateGroupMembershipData.V1.MembershipUpdatesEntryR\x11membershipUpdates\x12'\n" + - "\x0fremoved_members\x18\x02 \x03(\tR\x0eremovedMembers\x121\n" + - "\x14failed_installations\x18\x03 \x03(\fR\x13failedInstallations\x1aD\n" + - "\x16MembershipUpdatesEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\x04R\x05value:\x028\x01B\t\n" + - "\aversion\"\x9e\x01\n" + - "\x16ReaddInstallationsData\x12>\n" + - "\x02v1\x18\x01 \x01(\v2,.xmtp.mls.database.ReaddInstallationsData.V1H\x00R\x02v1\x1a9\n" + - "\x02V1\x123\n" + - "\x15readded_installations\x18\x01 \x03(\fR\x14readdedInstallationsB\t\n" + - "\aversion\"\xa1\x01\n" + - "\x12UpdateMetadataData\x12:\n" + - "\x02v1\x18\x01 \x01(\v2(.xmtp.mls.database.UpdateMetadataData.V1H\x00R\x02v1\x1aD\n" + - "\x02V1\x12\x1d\n" + - "\n" + - "field_name\x18\x01 \x01(\tR\tfieldName\x12\x1f\n" + - "\vfield_value\x18\x02 \x01(\tR\n" + - "fieldValueB\t\n" + - "\aversion\"\xdd\x01\n" + - "\x14UpdateAdminListsData\x12<\n" + - "\x02v1\x18\x01 \x01(\v2*.xmtp.mls.database.UpdateAdminListsData.V1H\x00R\x02v1\x1a|\n" + - "\x02V1\x12[\n" + - "\x16admin_list_update_type\x18\x01 \x01(\x0e2&.xmtp.mls.database.AdminListUpdateTypeR\x13adminListUpdateType\x12\x19\n" + - "\binbox_id\x18\x02 \x01(\tR\ainboxIdB\t\n" + - "\aversion\"\xf7\x02\n" + - "\x14UpdatePermissionData\x12<\n" + - "\x02v1\x18\x01 \x01(\v2*.xmtp.mls.database.UpdatePermissionData.V1H\x00R\x02v1\x1a\x95\x02\n" + - "\x02V1\x12]\n" + - "\x16permission_update_type\x18\x01 \x01(\x0e2'.xmtp.mls.database.PermissionUpdateTypeR\x14permissionUpdateType\x12c\n" + - "\x18permission_policy_option\x18\x02 \x01(\x0e2).xmtp.mls.database.PermissionPolicyOptionR\x16permissionPolicyOption\x123\n" + - "\x13metadata_field_name\x18\x03 \x01(\tH\x00R\x11metadataFieldName\x88\x01\x01B\x16\n" + - "\x14_metadata_field_nameB\t\n" + - "\aversion\"\xf3\x04\n" + - "\x10PostCommitAction\x12W\n" + - "\rsend_welcomes\x18\x01 \x01(\v20.xmtp.mls.database.PostCommitAction.SendWelcomesH\x00R\fsendWelcomes\x1a\xeb\x02\n" + - "\fInstallation\x12)\n" + - "\x10installation_key\x18\x01 \x01(\fR\x0finstallationKey\x12&\n" + - "\x0fhpke_public_key\x18\x02 \x01(\fR\rhpkePublicKey\x12n\n" + - "\x19welcome_wrapper_algorithm\x18\x03 \x01(\x0e22.xmtp.mls.message_contents.WelcomeWrapperAlgorithmR\x17welcomeWrapperAlgorithm\x12\x97\x01\n" + - "%welcome_pointee_encryption_aead_types\x18\x04 \x01(\v2E.xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypesExtensionR!welcomePointeeEncryptionAeadTypes\x1a\x8f\x01\n" + - "\fSendWelcomes\x12V\n" + - "\rinstallations\x18\x01 \x03(\v20.xmtp.mls.database.PostCommitAction.InstallationR\rinstallations\x12'\n" + - "\x0fwelcome_message\x18\x02 \x01(\fR\x0ewelcomeMessageB\x06\n" + - "\x04kind\"\xb9\x01\n" + - "\x17ProposeMemberUpdateData\x12?\n" + - "\x02v1\x18\x01 \x01(\v2-.xmtp.mls.database.ProposeMemberUpdateData.V1H\x00R\x02v1\x1aR\n" + - "\x02V1\x12\"\n" + - "\radd_inbox_ids\x18\x01 \x03(\fR\vaddInboxIds\x12(\n" + - "\x10remove_inbox_ids\x18\x02 \x03(\fR\x0eremoveInboxIdsB\t\n" + - "\aversion\"\xb5\x01\n" + - " ProposeGroupContextExtensionData\x12H\n" + - "\x02v1\x18\x01 \x01(\v26.xmtp.mls.database.ProposeGroupContextExtensionData.V1H\x00R\x02v1\x1a<\n" + - "\x02V1\x126\n" + - "\x17group_context_extension\x18\x01 \x01(\fR\x15groupContextExtensionB\t\n" + - "\aversion\"\x9a\x01\n" + - "\x1aCommitPendingProposalsData\x12B\n" + - "\x02v1\x18\x01 \x01(\v20.xmtp.mls.database.CommitPendingProposalsData.V1H\x00R\x02v1\x1a-\n" + - "\x02V1\x12'\n" + - "\x0fproposal_hashes\x18\x01 \x03(\fR\x0eproposalHashesB\t\n" + - "\aversion*\xe7\x01\n" + - "\x13AdminListUpdateType\x12&\n" + - "\"ADMIN_LIST_UPDATE_TYPE_UNSPECIFIED\x10\x00\x12$\n" + - " ADMIN_LIST_UPDATE_TYPE_ADD_ADMIN\x10\x01\x12'\n" + - "#ADMIN_LIST_UPDATE_TYPE_REMOVE_ADMIN\x10\x02\x12*\n" + - "&ADMIN_LIST_UPDATE_TYPE_ADD_SUPER_ADMIN\x10\x03\x12-\n" + - ")ADMIN_LIST_UPDATE_TYPE_REMOVE_SUPER_ADMIN\x10\x04*\x8a\x02\n" + - "\x14PermissionUpdateType\x12&\n" + - "\"PERMISSION_UPDATE_TYPE_UNSPECIFIED\x10\x00\x12%\n" + - "!PERMISSION_UPDATE_TYPE_ADD_MEMBER\x10\x01\x12(\n" + - "$PERMISSION_UPDATE_TYPE_REMOVE_MEMBER\x10\x02\x12$\n" + - " PERMISSION_UPDATE_TYPE_ADD_ADMIN\x10\x03\x12'\n" + - "#PERMISSION_UPDATE_TYPE_REMOVE_ADMIN\x10\x04\x12*\n" + - "&PERMISSION_UPDATE_TYPE_UPDATE_METADATA\x10\x05*\xe1\x01\n" + - "\x16PermissionPolicyOption\x12(\n" + - "$PERMISSION_POLICY_OPTION_UNSPECIFIED\x10\x00\x12\"\n" + - "\x1ePERMISSION_POLICY_OPTION_ALLOW\x10\x01\x12!\n" + - "\x1dPERMISSION_POLICY_OPTION_DENY\x10\x02\x12'\n" + - "#PERMISSION_POLICY_OPTION_ADMIN_ONLY\x10\x03\x12-\n" + - ")PERMISSION_POLICY_OPTION_SUPER_ADMIN_ONLY\x10\x04B\xec\x01\n" + - "/org.xmtp.android.library.push.xmtp.mls.databaseB\fIntentsProtoP\x01ZEgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/database\xa2\x02\x03XMD\xaa\x02\x11Xmtp.Mls.Database\xca\x02\x11Xmtp\\Mls\\Database\xe2\x02\x1dXmtp\\Mls\\Database\\GPBMetadata\xea\x02\x13Xmtp::Mls::Databaseb\x06proto3" - -var ( - file_mls_database_intents_proto_rawDescOnce sync.Once - file_mls_database_intents_proto_rawDescData []byte -) - -func file_mls_database_intents_proto_rawDescGZIP() []byte { - file_mls_database_intents_proto_rawDescOnce.Do(func() { - file_mls_database_intents_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_database_intents_proto_rawDesc), len(file_mls_database_intents_proto_rawDesc))) - }) - return file_mls_database_intents_proto_rawDescData -} - -var file_mls_database_intents_proto_enumTypes = make([]protoimpl.EnumInfo, 3) -var file_mls_database_intents_proto_msgTypes = make([]protoimpl.MessageInfo, 29) -var file_mls_database_intents_proto_goTypes = []any{ - (AdminListUpdateType)(0), // 0: xmtp.mls.database.AdminListUpdateType - (PermissionUpdateType)(0), // 1: xmtp.mls.database.PermissionUpdateType - (PermissionPolicyOption)(0), // 2: xmtp.mls.database.PermissionPolicyOption - (*SendMessageData)(nil), // 3: xmtp.mls.database.SendMessageData - (*AccountAddresses)(nil), // 4: xmtp.mls.database.AccountAddresses - (*InstallationIds)(nil), // 5: xmtp.mls.database.InstallationIds - (*AddressesOrInstallationIds)(nil), // 6: xmtp.mls.database.AddressesOrInstallationIds - (*AddMembersData)(nil), // 7: xmtp.mls.database.AddMembersData - (*RemoveMembersData)(nil), // 8: xmtp.mls.database.RemoveMembersData - (*UpdateGroupMembershipData)(nil), // 9: xmtp.mls.database.UpdateGroupMembershipData - (*ReaddInstallationsData)(nil), // 10: xmtp.mls.database.ReaddInstallationsData - (*UpdateMetadataData)(nil), // 11: xmtp.mls.database.UpdateMetadataData - (*UpdateAdminListsData)(nil), // 12: xmtp.mls.database.UpdateAdminListsData - (*UpdatePermissionData)(nil), // 13: xmtp.mls.database.UpdatePermissionData - (*PostCommitAction)(nil), // 14: xmtp.mls.database.PostCommitAction - (*ProposeMemberUpdateData)(nil), // 15: xmtp.mls.database.ProposeMemberUpdateData - (*ProposeGroupContextExtensionData)(nil), // 16: xmtp.mls.database.ProposeGroupContextExtensionData - (*CommitPendingProposalsData)(nil), // 17: xmtp.mls.database.CommitPendingProposalsData - (*SendMessageData_V1)(nil), // 18: xmtp.mls.database.SendMessageData.V1 - (*AddMembersData_V1)(nil), // 19: xmtp.mls.database.AddMembersData.V1 - (*RemoveMembersData_V1)(nil), // 20: xmtp.mls.database.RemoveMembersData.V1 - (*UpdateGroupMembershipData_V1)(nil), // 21: xmtp.mls.database.UpdateGroupMembershipData.V1 - nil, // 22: xmtp.mls.database.UpdateGroupMembershipData.V1.MembershipUpdatesEntry - (*ReaddInstallationsData_V1)(nil), // 23: xmtp.mls.database.ReaddInstallationsData.V1 - (*UpdateMetadataData_V1)(nil), // 24: xmtp.mls.database.UpdateMetadataData.V1 - (*UpdateAdminListsData_V1)(nil), // 25: xmtp.mls.database.UpdateAdminListsData.V1 - (*UpdatePermissionData_V1)(nil), // 26: xmtp.mls.database.UpdatePermissionData.V1 - (*PostCommitAction_Installation)(nil), // 27: xmtp.mls.database.PostCommitAction.Installation - (*PostCommitAction_SendWelcomes)(nil), // 28: xmtp.mls.database.PostCommitAction.SendWelcomes - (*ProposeMemberUpdateData_V1)(nil), // 29: xmtp.mls.database.ProposeMemberUpdateData.V1 - (*ProposeGroupContextExtensionData_V1)(nil), // 30: xmtp.mls.database.ProposeGroupContextExtensionData.V1 - (*CommitPendingProposalsData_V1)(nil), // 31: xmtp.mls.database.CommitPendingProposalsData.V1 - (message_contents.WelcomeWrapperAlgorithm)(0), // 32: xmtp.mls.message_contents.WelcomeWrapperAlgorithm - (*message_contents.WelcomePointeeEncryptionAeadTypesExtension)(nil), // 33: xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypesExtension -} -var file_mls_database_intents_proto_depIdxs = []int32{ - 18, // 0: xmtp.mls.database.SendMessageData.v1:type_name -> xmtp.mls.database.SendMessageData.V1 - 4, // 1: xmtp.mls.database.AddressesOrInstallationIds.account_addresses:type_name -> xmtp.mls.database.AccountAddresses - 5, // 2: xmtp.mls.database.AddressesOrInstallationIds.installation_ids:type_name -> xmtp.mls.database.InstallationIds - 19, // 3: xmtp.mls.database.AddMembersData.v1:type_name -> xmtp.mls.database.AddMembersData.V1 - 20, // 4: xmtp.mls.database.RemoveMembersData.v1:type_name -> xmtp.mls.database.RemoveMembersData.V1 - 21, // 5: xmtp.mls.database.UpdateGroupMembershipData.v1:type_name -> xmtp.mls.database.UpdateGroupMembershipData.V1 - 23, // 6: xmtp.mls.database.ReaddInstallationsData.v1:type_name -> xmtp.mls.database.ReaddInstallationsData.V1 - 24, // 7: xmtp.mls.database.UpdateMetadataData.v1:type_name -> xmtp.mls.database.UpdateMetadataData.V1 - 25, // 8: xmtp.mls.database.UpdateAdminListsData.v1:type_name -> xmtp.mls.database.UpdateAdminListsData.V1 - 26, // 9: xmtp.mls.database.UpdatePermissionData.v1:type_name -> xmtp.mls.database.UpdatePermissionData.V1 - 28, // 10: xmtp.mls.database.PostCommitAction.send_welcomes:type_name -> xmtp.mls.database.PostCommitAction.SendWelcomes - 29, // 11: xmtp.mls.database.ProposeMemberUpdateData.v1:type_name -> xmtp.mls.database.ProposeMemberUpdateData.V1 - 30, // 12: xmtp.mls.database.ProposeGroupContextExtensionData.v1:type_name -> xmtp.mls.database.ProposeGroupContextExtensionData.V1 - 31, // 13: xmtp.mls.database.CommitPendingProposalsData.v1:type_name -> xmtp.mls.database.CommitPendingProposalsData.V1 - 6, // 14: xmtp.mls.database.AddMembersData.V1.addresses_or_installation_ids:type_name -> xmtp.mls.database.AddressesOrInstallationIds - 6, // 15: xmtp.mls.database.RemoveMembersData.V1.addresses_or_installation_ids:type_name -> xmtp.mls.database.AddressesOrInstallationIds - 22, // 16: xmtp.mls.database.UpdateGroupMembershipData.V1.membership_updates:type_name -> xmtp.mls.database.UpdateGroupMembershipData.V1.MembershipUpdatesEntry - 0, // 17: xmtp.mls.database.UpdateAdminListsData.V1.admin_list_update_type:type_name -> xmtp.mls.database.AdminListUpdateType - 1, // 18: xmtp.mls.database.UpdatePermissionData.V1.permission_update_type:type_name -> xmtp.mls.database.PermissionUpdateType - 2, // 19: xmtp.mls.database.UpdatePermissionData.V1.permission_policy_option:type_name -> xmtp.mls.database.PermissionPolicyOption - 32, // 20: xmtp.mls.database.PostCommitAction.Installation.welcome_wrapper_algorithm:type_name -> xmtp.mls.message_contents.WelcomeWrapperAlgorithm - 33, // 21: xmtp.mls.database.PostCommitAction.Installation.welcome_pointee_encryption_aead_types:type_name -> xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypesExtension - 27, // 22: xmtp.mls.database.PostCommitAction.SendWelcomes.installations:type_name -> xmtp.mls.database.PostCommitAction.Installation - 23, // [23:23] is the sub-list for method output_type - 23, // [23:23] is the sub-list for method input_type - 23, // [23:23] is the sub-list for extension type_name - 23, // [23:23] is the sub-list for extension extendee - 0, // [0:23] is the sub-list for field type_name -} - -func init() { file_mls_database_intents_proto_init() } -func file_mls_database_intents_proto_init() { - if File_mls_database_intents_proto != nil { - return - } - file_mls_database_intents_proto_msgTypes[0].OneofWrappers = []any{ - (*SendMessageData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[3].OneofWrappers = []any{ - (*AddressesOrInstallationIds_AccountAddresses)(nil), - (*AddressesOrInstallationIds_InstallationIds)(nil), - } - file_mls_database_intents_proto_msgTypes[4].OneofWrappers = []any{ - (*AddMembersData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[5].OneofWrappers = []any{ - (*RemoveMembersData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[6].OneofWrappers = []any{ - (*UpdateGroupMembershipData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[7].OneofWrappers = []any{ - (*ReaddInstallationsData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[8].OneofWrappers = []any{ - (*UpdateMetadataData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[9].OneofWrappers = []any{ - (*UpdateAdminListsData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[10].OneofWrappers = []any{ - (*UpdatePermissionData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[11].OneofWrappers = []any{ - (*PostCommitAction_SendWelcomes_)(nil), - } - file_mls_database_intents_proto_msgTypes[12].OneofWrappers = []any{ - (*ProposeMemberUpdateData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[13].OneofWrappers = []any{ - (*ProposeGroupContextExtensionData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[14].OneofWrappers = []any{ - (*CommitPendingProposalsData_V1_)(nil), - } - file_mls_database_intents_proto_msgTypes[23].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_database_intents_proto_rawDesc), len(file_mls_database_intents_proto_rawDesc)), - NumEnums: 3, - NumMessages: 29, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_database_intents_proto_goTypes, - DependencyIndexes: file_mls_database_intents_proto_depIdxs, - EnumInfos: file_mls_database_intents_proto_enumTypes, - MessageInfos: file_mls_database_intents_proto_msgTypes, - }.Build() - File_mls_database_intents_proto = out.File - file_mls_database_intents_proto_goTypes = nil - file_mls_database_intents_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/database/task.pb.go b/pkg/proto/mls/database/task.pb.go deleted file mode 100644 index 984ad6c5..00000000 --- a/pkg/proto/mls/database/task.pb.go +++ /dev/null @@ -1,253 +0,0 @@ -// Intent protos that are stored in the libxmtp database - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/database/task.proto - -package database - -import ( - device_sync "github.com/xmtp/example-notification-server-go/pkg/proto/device_sync" - message_contents "github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type Task struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Task: - // - // *Task_ProcessWelcomePointer - // *Task_SendSyncArchive - Task isTask_Task `protobuf_oneof:"task"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Task) Reset() { - *x = Task{} - mi := &file_mls_database_task_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Task) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Task) ProtoMessage() {} - -func (x *Task) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_task_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Task.ProtoReflect.Descriptor instead. -func (*Task) Descriptor() ([]byte, []int) { - return file_mls_database_task_proto_rawDescGZIP(), []int{0} -} - -func (x *Task) GetTask() isTask_Task { - if x != nil { - return x.Task - } - return nil -} - -func (x *Task) GetProcessWelcomePointer() *message_contents.WelcomePointer { - if x != nil { - if x, ok := x.Task.(*Task_ProcessWelcomePointer); ok { - return x.ProcessWelcomePointer - } - } - return nil -} - -func (x *Task) GetSendSyncArchive() *SendSyncArchive { - if x != nil { - if x, ok := x.Task.(*Task_SendSyncArchive); ok { - return x.SendSyncArchive - } - } - return nil -} - -type isTask_Task interface { - isTask_Task() -} - -type Task_ProcessWelcomePointer struct { - ProcessWelcomePointer *message_contents.WelcomePointer `protobuf:"bytes,1,opt,name=process_welcome_pointer,json=processWelcomePointer,proto3,oneof"` -} - -type Task_SendSyncArchive struct { - SendSyncArchive *SendSyncArchive `protobuf:"bytes,2,opt,name=send_sync_archive,json=sendSyncArchive,proto3,oneof"` -} - -func (*Task_ProcessWelcomePointer) isTask_Task() {} - -func (*Task_SendSyncArchive) isTask_Task() {} - -type SendSyncArchive struct { - state protoimpl.MessageState `protogen:"open.v1"` - Options *device_sync.ArchiveOptions `protobuf:"bytes,1,opt,name=options,proto3" json:"options,omitempty"` - SyncGroupId []byte `protobuf:"bytes,2,opt,name=sync_group_id,json=syncGroupId,proto3" json:"sync_group_id,omitempty"` - Pin *string `protobuf:"bytes,3,opt,name=pin,proto3,oneof" json:"pin,omitempty"` - ServerUrl string `protobuf:"bytes,4,opt,name=server_url,json=serverUrl,proto3" json:"server_url,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SendSyncArchive) Reset() { - *x = SendSyncArchive{} - mi := &file_mls_database_task_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SendSyncArchive) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SendSyncArchive) ProtoMessage() {} - -func (x *SendSyncArchive) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_task_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SendSyncArchive.ProtoReflect.Descriptor instead. -func (*SendSyncArchive) Descriptor() ([]byte, []int) { - return file_mls_database_task_proto_rawDescGZIP(), []int{1} -} - -func (x *SendSyncArchive) GetOptions() *device_sync.ArchiveOptions { - if x != nil { - return x.Options - } - return nil -} - -func (x *SendSyncArchive) GetSyncGroupId() []byte { - if x != nil { - return x.SyncGroupId - } - return nil -} - -func (x *SendSyncArchive) GetPin() string { - if x != nil && x.Pin != nil { - return *x.Pin - } - return "" -} - -func (x *SendSyncArchive) GetServerUrl() string { - if x != nil { - return x.ServerUrl - } - return "" -} - -var File_mls_database_task_proto protoreflect.FileDescriptor - -const file_mls_database_task_proto_rawDesc = "" + - "\n" + - "\x17mls/database/task.proto\x12\x11xmtp.mls.database\x1a\x1ddevice_sync/device_sync.proto\x1a*mls/message_contents/welcome_pointer.proto\"\xc5\x01\n" + - "\x04Task\x12c\n" + - "\x17process_welcome_pointer\x18\x01 \x01(\v2).xmtp.mls.message_contents.WelcomePointerH\x00R\x15processWelcomePointer\x12P\n" + - "\x11send_sync_archive\x18\x02 \x01(\v2\".xmtp.mls.database.SendSyncArchiveH\x00R\x0fsendSyncArchiveB\x06\n" + - "\x04task\"\xaf\x01\n" + - "\x0fSendSyncArchive\x12:\n" + - "\aoptions\x18\x01 \x01(\v2 .xmtp.device_sync.ArchiveOptionsR\aoptions\x12\"\n" + - "\rsync_group_id\x18\x02 \x01(\fR\vsyncGroupId\x12\x15\n" + - "\x03pin\x18\x03 \x01(\tH\x00R\x03pin\x88\x01\x01\x12\x1d\n" + - "\n" + - "server_url\x18\x04 \x01(\tR\tserverUrlB\x06\n" + - "\x04_pinB\xe9\x01\n" + - "/org.xmtp.android.library.push.xmtp.mls.databaseB\tTaskProtoP\x01ZEgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/database\xa2\x02\x03XMD\xaa\x02\x11Xmtp.Mls.Database\xca\x02\x11Xmtp\\Mls\\Database\xe2\x02\x1dXmtp\\Mls\\Database\\GPBMetadata\xea\x02\x13Xmtp::Mls::Databaseb\x06proto3" - -var ( - file_mls_database_task_proto_rawDescOnce sync.Once - file_mls_database_task_proto_rawDescData []byte -) - -func file_mls_database_task_proto_rawDescGZIP() []byte { - file_mls_database_task_proto_rawDescOnce.Do(func() { - file_mls_database_task_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_database_task_proto_rawDesc), len(file_mls_database_task_proto_rawDesc))) - }) - return file_mls_database_task_proto_rawDescData -} - -var file_mls_database_task_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_mls_database_task_proto_goTypes = []any{ - (*Task)(nil), // 0: xmtp.mls.database.Task - (*SendSyncArchive)(nil), // 1: xmtp.mls.database.SendSyncArchive - (*message_contents.WelcomePointer)(nil), // 2: xmtp.mls.message_contents.WelcomePointer - (*device_sync.ArchiveOptions)(nil), // 3: xmtp.device_sync.ArchiveOptions -} -var file_mls_database_task_proto_depIdxs = []int32{ - 2, // 0: xmtp.mls.database.Task.process_welcome_pointer:type_name -> xmtp.mls.message_contents.WelcomePointer - 1, // 1: xmtp.mls.database.Task.send_sync_archive:type_name -> xmtp.mls.database.SendSyncArchive - 3, // 2: xmtp.mls.database.SendSyncArchive.options:type_name -> xmtp.device_sync.ArchiveOptions - 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_mls_database_task_proto_init() } -func file_mls_database_task_proto_init() { - if File_mls_database_task_proto != nil { - return - } - file_mls_database_task_proto_msgTypes[0].OneofWrappers = []any{ - (*Task_ProcessWelcomePointer)(nil), - (*Task_SendSyncArchive)(nil), - } - file_mls_database_task_proto_msgTypes[1].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_database_task_proto_rawDesc), len(file_mls_database_task_proto_rawDesc)), - NumEnums: 0, - NumMessages: 2, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_database_task_proto_goTypes, - DependencyIndexes: file_mls_database_task_proto_depIdxs, - MessageInfos: file_mls_database_task_proto_msgTypes, - }.Build() - File_mls_database_task_proto = out.File - file_mls_database_task_proto_goTypes = nil - file_mls_database_task_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/commit_log.pb.go b/pkg/proto/mls/message_contents/commit_log.pb.go deleted file mode 100644 index 02e0f93c..00000000 --- a/pkg/proto/mls/message_contents/commit_log.pb.go +++ /dev/null @@ -1,313 +0,0 @@ -// Defines entries on the commit log, used for fork detection and recovery -// XIP: https://community.xmtp.org/t/xip-68-draft-automated-fork-recovery/951 - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/commit_log.proto - -package message_contents - -import ( - associations "github.com/xmtp/example-notification-server-go/pkg/proto/identity/associations" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type CommitResult int32 - -const ( - CommitResult_COMMIT_RESULT_UNSPECIFIED CommitResult = 0 - CommitResult_COMMIT_RESULT_APPLIED CommitResult = 1 - CommitResult_COMMIT_RESULT_WRONG_EPOCH CommitResult = 2 - CommitResult_COMMIT_RESULT_UNDECRYPTABLE CommitResult = 3 - CommitResult_COMMIT_RESULT_INVALID CommitResult = 4 -) - -// Enum value maps for CommitResult. -var ( - CommitResult_name = map[int32]string{ - 0: "COMMIT_RESULT_UNSPECIFIED", - 1: "COMMIT_RESULT_APPLIED", - 2: "COMMIT_RESULT_WRONG_EPOCH", - 3: "COMMIT_RESULT_UNDECRYPTABLE", - 4: "COMMIT_RESULT_INVALID", - } - CommitResult_value = map[string]int32{ - "COMMIT_RESULT_UNSPECIFIED": 0, - "COMMIT_RESULT_APPLIED": 1, - "COMMIT_RESULT_WRONG_EPOCH": 2, - "COMMIT_RESULT_UNDECRYPTABLE": 3, - "COMMIT_RESULT_INVALID": 4, - } -) - -func (x CommitResult) Enum() *CommitResult { - p := new(CommitResult) - *p = x - return p -} - -func (x CommitResult) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (CommitResult) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_commit_log_proto_enumTypes[0].Descriptor() -} - -func (CommitResult) Type() protoreflect.EnumType { - return &file_mls_message_contents_commit_log_proto_enumTypes[0] -} - -func (x CommitResult) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use CommitResult.Descriptor instead. -func (CommitResult) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_commit_log_proto_rawDescGZIP(), []int{0} -} - -// PlaintextCommitLogEntry indicates whether a commit was successful or not, -// when applied on top of the indicated `last_epoch_authenticator`. -type PlaintextCommitLogEntry struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The group_id of the group that the commit belongs to. - GroupId []byte `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - // The sequence ID of the commit payload being validated. - CommitSequenceId uint64 `protobuf:"varint,2,opt,name=commit_sequence_id,json=commitSequenceId,proto3" json:"commit_sequence_id,omitempty"` - // The encryption state before the commit was applied. - LastEpochAuthenticator []byte `protobuf:"bytes,3,opt,name=last_epoch_authenticator,json=lastEpochAuthenticator,proto3" json:"last_epoch_authenticator,omitempty"` - // Indicates whether the commit was successful, or why it failed. - CommitResult CommitResult `protobuf:"varint,4,opt,name=commit_result,json=commitResult,proto3,enum=xmtp.mls.message_contents.CommitResult" json:"commit_result,omitempty"` - // The epoch number after the commit was applied, if successful. - AppliedEpochNumber uint64 `protobuf:"varint,5,opt,name=applied_epoch_number,json=appliedEpochNumber,proto3" json:"applied_epoch_number,omitempty"` - // The encryption state after the commit was applied, if successful. - AppliedEpochAuthenticator []byte `protobuf:"bytes,6,opt,name=applied_epoch_authenticator,json=appliedEpochAuthenticator,proto3" json:"applied_epoch_authenticator,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PlaintextCommitLogEntry) Reset() { - *x = PlaintextCommitLogEntry{} - mi := &file_mls_message_contents_commit_log_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PlaintextCommitLogEntry) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PlaintextCommitLogEntry) ProtoMessage() {} - -func (x *PlaintextCommitLogEntry) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_commit_log_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PlaintextCommitLogEntry.ProtoReflect.Descriptor instead. -func (*PlaintextCommitLogEntry) Descriptor() ([]byte, []int) { - return file_mls_message_contents_commit_log_proto_rawDescGZIP(), []int{0} -} - -func (x *PlaintextCommitLogEntry) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *PlaintextCommitLogEntry) GetCommitSequenceId() uint64 { - if x != nil { - return x.CommitSequenceId - } - return 0 -} - -func (x *PlaintextCommitLogEntry) GetLastEpochAuthenticator() []byte { - if x != nil { - return x.LastEpochAuthenticator - } - return nil -} - -func (x *PlaintextCommitLogEntry) GetCommitResult() CommitResult { - if x != nil { - return x.CommitResult - } - return CommitResult_COMMIT_RESULT_UNSPECIFIED -} - -func (x *PlaintextCommitLogEntry) GetAppliedEpochNumber() uint64 { - if x != nil { - return x.AppliedEpochNumber - } - return 0 -} - -func (x *PlaintextCommitLogEntry) GetAppliedEpochAuthenticator() []byte { - if x != nil { - return x.AppliedEpochAuthenticator - } - return nil -} - -type CommitLogEntry struct { - state protoimpl.MessageState `protogen:"open.v1"` - SequenceId uint64 `protobuf:"varint,1,opt,name=sequence_id,json=sequenceId,proto3" json:"sequence_id,omitempty"` - SerializedCommitLogEntry []byte `protobuf:"bytes,2,opt,name=serialized_commit_log_entry,json=serializedCommitLogEntry,proto3" json:"serialized_commit_log_entry,omitempty"` - Signature *associations.RecoverableEd25519Signature `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *CommitLogEntry) Reset() { - *x = CommitLogEntry{} - mi := &file_mls_message_contents_commit_log_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *CommitLogEntry) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CommitLogEntry) ProtoMessage() {} - -func (x *CommitLogEntry) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_commit_log_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CommitLogEntry.ProtoReflect.Descriptor instead. -func (*CommitLogEntry) Descriptor() ([]byte, []int) { - return file_mls_message_contents_commit_log_proto_rawDescGZIP(), []int{1} -} - -func (x *CommitLogEntry) GetSequenceId() uint64 { - if x != nil { - return x.SequenceId - } - return 0 -} - -func (x *CommitLogEntry) GetSerializedCommitLogEntry() []byte { - if x != nil { - return x.SerializedCommitLogEntry - } - return nil -} - -func (x *CommitLogEntry) GetSignature() *associations.RecoverableEd25519Signature { - if x != nil { - return x.Signature - } - return nil -} - -var File_mls_message_contents_commit_log_proto protoreflect.FileDescriptor - -const file_mls_message_contents_commit_log_proto_rawDesc = "" + - "\n" + - "%mls/message_contents/commit_log.proto\x12\x19xmtp.mls.message_contents\x1a%identity/associations/signature.proto\"\xdc\x02\n" + - "\x17PlaintextCommitLogEntry\x12\x19\n" + - "\bgroup_id\x18\x01 \x01(\fR\agroupId\x12,\n" + - "\x12commit_sequence_id\x18\x02 \x01(\x04R\x10commitSequenceId\x128\n" + - "\x18last_epoch_authenticator\x18\x03 \x01(\fR\x16lastEpochAuthenticator\x12L\n" + - "\rcommit_result\x18\x04 \x01(\x0e2'.xmtp.mls.message_contents.CommitResultR\fcommitResult\x120\n" + - "\x14applied_epoch_number\x18\x05 \x01(\x04R\x12appliedEpochNumber\x12>\n" + - "\x1bapplied_epoch_authenticator\x18\x06 \x01(\fR\x19appliedEpochAuthenticator\"\xc7\x01\n" + - "\x0eCommitLogEntry\x12\x1f\n" + - "\vsequence_id\x18\x01 \x01(\x04R\n" + - "sequenceId\x12=\n" + - "\x1bserialized_commit_log_entry\x18\x02 \x01(\fR\x18serializedCommitLogEntry\x12U\n" + - "\tsignature\x18\x03 \x01(\v27.xmtp.identity.associations.RecoverableEd25519SignatureR\tsignature*\xa3\x01\n" + - "\fCommitResult\x12\x1d\n" + - "\x19COMMIT_RESULT_UNSPECIFIED\x10\x00\x12\x19\n" + - "\x15COMMIT_RESULT_APPLIED\x10\x01\x12\x1d\n" + - "\x19COMMIT_RESULT_WRONG_EPOCH\x10\x02\x12\x1f\n" + - "\x1bCOMMIT_RESULT_UNDECRYPTABLE\x10\x03\x12\x19\n" + - "\x15COMMIT_RESULT_INVALID\x10\x04B\x9a\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x0eCommitLogProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_commit_log_proto_rawDescOnce sync.Once - file_mls_message_contents_commit_log_proto_rawDescData []byte -) - -func file_mls_message_contents_commit_log_proto_rawDescGZIP() []byte { - file_mls_message_contents_commit_log_proto_rawDescOnce.Do(func() { - file_mls_message_contents_commit_log_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_commit_log_proto_rawDesc), len(file_mls_message_contents_commit_log_proto_rawDesc))) - }) - return file_mls_message_contents_commit_log_proto_rawDescData -} - -var file_mls_message_contents_commit_log_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_mls_message_contents_commit_log_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_mls_message_contents_commit_log_proto_goTypes = []any{ - (CommitResult)(0), // 0: xmtp.mls.message_contents.CommitResult - (*PlaintextCommitLogEntry)(nil), // 1: xmtp.mls.message_contents.PlaintextCommitLogEntry - (*CommitLogEntry)(nil), // 2: xmtp.mls.message_contents.CommitLogEntry - (*associations.RecoverableEd25519Signature)(nil), // 3: xmtp.identity.associations.RecoverableEd25519Signature -} -var file_mls_message_contents_commit_log_proto_depIdxs = []int32{ - 0, // 0: xmtp.mls.message_contents.PlaintextCommitLogEntry.commit_result:type_name -> xmtp.mls.message_contents.CommitResult - 3, // 1: xmtp.mls.message_contents.CommitLogEntry.signature:type_name -> xmtp.identity.associations.RecoverableEd25519Signature - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_mls_message_contents_commit_log_proto_init() } -func file_mls_message_contents_commit_log_proto_init() { - if File_mls_message_contents_commit_log_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_commit_log_proto_rawDesc), len(file_mls_message_contents_commit_log_proto_rawDesc)), - NumEnums: 1, - NumMessages: 2, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_commit_log_proto_goTypes, - DependencyIndexes: file_mls_message_contents_commit_log_proto_depIdxs, - EnumInfos: file_mls_message_contents_commit_log_proto_enumTypes, - MessageInfos: file_mls_message_contents_commit_log_proto_msgTypes, - }.Build() - File_mls_message_contents_commit_log_proto = out.File - file_mls_message_contents_commit_log_proto_goTypes = nil - file_mls_message_contents_commit_log_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/content.pb.go b/pkg/proto/mls/message_contents/content.pb.go deleted file mode 100644 index 223aa0a4..00000000 --- a/pkg/proto/mls/message_contents/content.pb.go +++ /dev/null @@ -1,620 +0,0 @@ -// Message content encoding structures -// Copied from V2 code so that we can eventually retire all V2 message content - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/content.proto - -package message_contents - -import ( - device_sync "github.com/xmtp/example-notification-server-go/pkg/proto/device_sync" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Recognized compression algorithms -// protolint:disable ENUM_FIELD_NAMES_ZERO_VALUE_END_WITH -type Compression int32 - -const ( - Compression_COMPRESSION_DEFLATE Compression = 0 - Compression_COMPRESSION_GZIP Compression = 1 -) - -// Enum value maps for Compression. -var ( - Compression_name = map[int32]string{ - 0: "COMPRESSION_DEFLATE", - 1: "COMPRESSION_GZIP", - } - Compression_value = map[string]int32{ - "COMPRESSION_DEFLATE": 0, - "COMPRESSION_GZIP": 1, - } -) - -func (x Compression) Enum() *Compression { - p := new(Compression) - *p = x - return p -} - -func (x Compression) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (Compression) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_content_proto_enumTypes[0].Descriptor() -} - -func (Compression) Type() protoreflect.EnumType { - return &file_mls_message_contents_content_proto_enumTypes[0] -} - -func (x Compression) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use Compression.Descriptor instead. -func (Compression) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_content_proto_rawDescGZIP(), []int{0} -} - -// ContentTypeId is used to identify the type of content stored in a Message. -type ContentTypeId struct { - state protoimpl.MessageState `protogen:"open.v1"` - AuthorityId string `protobuf:"bytes,1,opt,name=authority_id,json=authorityId,proto3" json:"authority_id,omitempty"` // authority governing this content type - TypeId string `protobuf:"bytes,2,opt,name=type_id,json=typeId,proto3" json:"type_id,omitempty"` // type identifier - VersionMajor uint32 `protobuf:"varint,3,opt,name=version_major,json=versionMajor,proto3" json:"version_major,omitempty"` // major version of the type - VersionMinor uint32 `protobuf:"varint,4,opt,name=version_minor,json=versionMinor,proto3" json:"version_minor,omitempty"` // minor version of the type - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ContentTypeId) Reset() { - *x = ContentTypeId{} - mi := &file_mls_message_contents_content_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ContentTypeId) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ContentTypeId) ProtoMessage() {} - -func (x *ContentTypeId) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ContentTypeId.ProtoReflect.Descriptor instead. -func (*ContentTypeId) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_proto_rawDescGZIP(), []int{0} -} - -func (x *ContentTypeId) GetAuthorityId() string { - if x != nil { - return x.AuthorityId - } - return "" -} - -func (x *ContentTypeId) GetTypeId() string { - if x != nil { - return x.TypeId - } - return "" -} - -func (x *ContentTypeId) GetVersionMajor() uint32 { - if x != nil { - return x.VersionMajor - } - return 0 -} - -func (x *ContentTypeId) GetVersionMinor() uint32 { - if x != nil { - return x.VersionMinor - } - return 0 -} - -// EncodedContent bundles the content with metadata identifying its type -// and parameters required for correct decoding and presentation of the content. -type EncodedContent struct { - state protoimpl.MessageState `protogen:"open.v1"` - // content type identifier used to match the payload with - // the correct decoding machinery - Type *ContentTypeId `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"` - // optional encoding parameters required to correctly decode the content - Parameters map[string]string `protobuf:"bytes,2,rep,name=parameters,proto3" json:"parameters,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - // optional fallback description of the content that can be used in case - // the client cannot decode or render the content - Fallback *string `protobuf:"bytes,3,opt,name=fallback,proto3,oneof" json:"fallback,omitempty"` - // optional compression; the value indicates algorithm used to - // compress the encoded content bytes - Compression *Compression `protobuf:"varint,5,opt,name=compression,proto3,enum=xmtp.mls.message_contents.Compression,oneof" json:"compression,omitempty"` - // encoded content itself - Content []byte `protobuf:"bytes,4,opt,name=content,proto3" json:"content,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EncodedContent) Reset() { - *x = EncodedContent{} - mi := &file_mls_message_contents_content_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EncodedContent) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EncodedContent) ProtoMessage() {} - -func (x *EncodedContent) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EncodedContent.ProtoReflect.Descriptor instead. -func (*EncodedContent) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_proto_rawDescGZIP(), []int{1} -} - -func (x *EncodedContent) GetType() *ContentTypeId { - if x != nil { - return x.Type - } - return nil -} - -func (x *EncodedContent) GetParameters() map[string]string { - if x != nil { - return x.Parameters - } - return nil -} - -func (x *EncodedContent) GetFallback() string { - if x != nil && x.Fallback != nil { - return *x.Fallback - } - return "" -} - -func (x *EncodedContent) GetCompression() Compression { - if x != nil && x.Compression != nil { - return *x.Compression - } - return Compression_COMPRESSION_DEFLATE -} - -func (x *EncodedContent) GetContent() []byte { - if x != nil { - return x.Content - } - return nil -} - -// A PlaintextEnvelope is the outermost payload that gets encrypted by MLS -type PlaintextEnvelope struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Selector which declares which version of the EncodedContent this - // PlaintextEnvelope is - // - // Types that are valid to be assigned to Content: - // - // *PlaintextEnvelope_V1_ - // *PlaintextEnvelope_V2_ - Content isPlaintextEnvelope_Content `protobuf_oneof:"content"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PlaintextEnvelope) Reset() { - *x = PlaintextEnvelope{} - mi := &file_mls_message_contents_content_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PlaintextEnvelope) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PlaintextEnvelope) ProtoMessage() {} - -func (x *PlaintextEnvelope) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PlaintextEnvelope.ProtoReflect.Descriptor instead. -func (*PlaintextEnvelope) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_proto_rawDescGZIP(), []int{2} -} - -func (x *PlaintextEnvelope) GetContent() isPlaintextEnvelope_Content { - if x != nil { - return x.Content - } - return nil -} - -func (x *PlaintextEnvelope) GetV1() *PlaintextEnvelope_V1 { - if x != nil { - if x, ok := x.Content.(*PlaintextEnvelope_V1_); ok { - return x.V1 - } - } - return nil -} - -func (x *PlaintextEnvelope) GetV2() *PlaintextEnvelope_V2 { - if x != nil { - if x, ok := x.Content.(*PlaintextEnvelope_V2_); ok { - return x.V2 - } - } - return nil -} - -type isPlaintextEnvelope_Content interface { - isPlaintextEnvelope_Content() -} - -type PlaintextEnvelope_V1_ struct { - V1 *PlaintextEnvelope_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` -} - -type PlaintextEnvelope_V2_ struct { - V2 *PlaintextEnvelope_V2 `protobuf:"bytes,2,opt,name=v2,proto3,oneof"` -} - -func (*PlaintextEnvelope_V1_) isPlaintextEnvelope_Content() {} - -func (*PlaintextEnvelope_V2_) isPlaintextEnvelope_Content() {} - -// Version 1 of the encrypted envelope -type PlaintextEnvelope_V1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Expected to be EncodedContent - Content []byte `protobuf:"bytes,1,opt,name=content,proto3" json:"content,omitempty"` - // A unique value that can be used to ensure that the same content can - // produce different hashes. May be the sender timestamp. - IdempotencyKey string `protobuf:"bytes,2,opt,name=idempotency_key,json=idempotencyKey,proto3" json:"idempotency_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PlaintextEnvelope_V1) Reset() { - *x = PlaintextEnvelope_V1{} - mi := &file_mls_message_contents_content_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PlaintextEnvelope_V1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PlaintextEnvelope_V1) ProtoMessage() {} - -func (x *PlaintextEnvelope_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PlaintextEnvelope_V1.ProtoReflect.Descriptor instead. -func (*PlaintextEnvelope_V1) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_proto_rawDescGZIP(), []int{2, 0} -} - -func (x *PlaintextEnvelope_V1) GetContent() []byte { - if x != nil { - return x.Content - } - return nil -} - -func (x *PlaintextEnvelope_V1) GetIdempotencyKey() string { - if x != nil { - return x.IdempotencyKey - } - return "" -} - -// Version 2 of the encrypted envelope -type PlaintextEnvelope_V2 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // A unique value that can be used to ensure that the same content can - // produce different hashes. May be the sender timestamp. - IdempotencyKey string `protobuf:"bytes,1,opt,name=idempotency_key,json=idempotencyKey,proto3" json:"idempotency_key,omitempty"` - // Types that are valid to be assigned to MessageType: - // - // *PlaintextEnvelope_V2_Content - // *PlaintextEnvelope_V2_DeviceSyncRequest - // *PlaintextEnvelope_V2_DeviceSyncReply - // *PlaintextEnvelope_V2_UserPreferenceUpdate - MessageType isPlaintextEnvelope_V2_MessageType `protobuf_oneof:"message_type"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PlaintextEnvelope_V2) Reset() { - *x = PlaintextEnvelope_V2{} - mi := &file_mls_message_contents_content_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PlaintextEnvelope_V2) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PlaintextEnvelope_V2) ProtoMessage() {} - -func (x *PlaintextEnvelope_V2) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PlaintextEnvelope_V2.ProtoReflect.Descriptor instead. -func (*PlaintextEnvelope_V2) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_proto_rawDescGZIP(), []int{2, 1} -} - -func (x *PlaintextEnvelope_V2) GetIdempotencyKey() string { - if x != nil { - return x.IdempotencyKey - } - return "" -} - -func (x *PlaintextEnvelope_V2) GetMessageType() isPlaintextEnvelope_V2_MessageType { - if x != nil { - return x.MessageType - } - return nil -} - -func (x *PlaintextEnvelope_V2) GetContent() []byte { - if x != nil { - if x, ok := x.MessageType.(*PlaintextEnvelope_V2_Content); ok { - return x.Content - } - } - return nil -} - -func (x *PlaintextEnvelope_V2) GetDeviceSyncRequest() *device_sync.DeviceSyncRequest { - if x != nil { - if x, ok := x.MessageType.(*PlaintextEnvelope_V2_DeviceSyncRequest); ok { - return x.DeviceSyncRequest - } - } - return nil -} - -func (x *PlaintextEnvelope_V2) GetDeviceSyncReply() *device_sync.DeviceSyncReply { - if x != nil { - if x, ok := x.MessageType.(*PlaintextEnvelope_V2_DeviceSyncReply); ok { - return x.DeviceSyncReply - } - } - return nil -} - -func (x *PlaintextEnvelope_V2) GetUserPreferenceUpdate() *device_sync.V1UserPreferenceUpdate { - if x != nil { - if x, ok := x.MessageType.(*PlaintextEnvelope_V2_UserPreferenceUpdate); ok { - return x.UserPreferenceUpdate - } - } - return nil -} - -type isPlaintextEnvelope_V2_MessageType interface { - isPlaintextEnvelope_V2_MessageType() -} - -type PlaintextEnvelope_V2_Content struct { - // Expected to be EncodedContent - Content []byte `protobuf:"bytes,2,opt,name=content,proto3,oneof"` -} - -type PlaintextEnvelope_V2_DeviceSyncRequest struct { - // Initiator sends a request to receive sync payload - DeviceSyncRequest *device_sync.DeviceSyncRequest `protobuf:"bytes,3,opt,name=device_sync_request,json=deviceSyncRequest,proto3,oneof"` -} - -type PlaintextEnvelope_V2_DeviceSyncReply struct { - // Some other authorized installation sends a reply with a link to payload - DeviceSyncReply *device_sync.DeviceSyncReply `protobuf:"bytes,4,opt,name=device_sync_reply,json=deviceSyncReply,proto3,oneof"` -} - -type PlaintextEnvelope_V2_UserPreferenceUpdate struct { - // A serialized user preference update - UserPreferenceUpdate *device_sync.V1UserPreferenceUpdate `protobuf:"bytes,5,opt,name=user_preference_update,json=userPreferenceUpdate,proto3,oneof"` -} - -func (*PlaintextEnvelope_V2_Content) isPlaintextEnvelope_V2_MessageType() {} - -func (*PlaintextEnvelope_V2_DeviceSyncRequest) isPlaintextEnvelope_V2_MessageType() {} - -func (*PlaintextEnvelope_V2_DeviceSyncReply) isPlaintextEnvelope_V2_MessageType() {} - -func (*PlaintextEnvelope_V2_UserPreferenceUpdate) isPlaintextEnvelope_V2_MessageType() {} - -var File_mls_message_contents_content_proto protoreflect.FileDescriptor - -const file_mls_message_contents_content_proto_rawDesc = "" + - "\n" + - "\"mls/message_contents/content.proto\x12\x19xmtp.mls.message_contents\x1a\x19device_sync/content.proto\"\x95\x01\n" + - "\rContentTypeId\x12!\n" + - "\fauthority_id\x18\x01 \x01(\tR\vauthorityId\x12\x17\n" + - "\atype_id\x18\x02 \x01(\tR\x06typeId\x12#\n" + - "\rversion_major\x18\x03 \x01(\rR\fversionMajor\x12#\n" + - "\rversion_minor\x18\x04 \x01(\rR\fversionMinor\"\x8f\x03\n" + - "\x0eEncodedContent\x12<\n" + - "\x04type\x18\x01 \x01(\v2(.xmtp.mls.message_contents.ContentTypeIdR\x04type\x12Y\n" + - "\n" + - "parameters\x18\x02 \x03(\v29.xmtp.mls.message_contents.EncodedContent.ParametersEntryR\n" + - "parameters\x12\x1f\n" + - "\bfallback\x18\x03 \x01(\tH\x00R\bfallback\x88\x01\x01\x12M\n" + - "\vcompression\x18\x05 \x01(\x0e2&.xmtp.mls.message_contents.CompressionH\x01R\vcompression\x88\x01\x01\x12\x18\n" + - "\acontent\x18\x04 \x01(\fR\acontent\x1a=\n" + - "\x0fParametersEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01B\v\n" + - "\t_fallbackB\x0e\n" + - "\f_compression\"\x80\x05\n" + - "\x11PlaintextEnvelope\x12A\n" + - "\x02v1\x18\x01 \x01(\v2/.xmtp.mls.message_contents.PlaintextEnvelope.V1H\x00R\x02v1\x12A\n" + - "\x02v2\x18\x02 \x01(\v2/.xmtp.mls.message_contents.PlaintextEnvelope.V2H\x00R\x02v2\x1aG\n" + - "\x02V1\x12\x18\n" + - "\acontent\x18\x01 \x01(\fR\acontent\x12'\n" + - "\x0fidempotency_key\x18\x02 \x01(\tR\x0eidempotencyKey\x1a\x90\x03\n" + - "\x02V2\x12'\n" + - "\x0fidempotency_key\x18\x01 \x01(\tR\x0eidempotencyKey\x12\x1a\n" + - "\acontent\x18\x02 \x01(\fH\x00R\acontent\x12]\n" + - "\x13device_sync_request\x18\x03 \x01(\v2+.xmtp.device_sync.content.DeviceSyncRequestH\x00R\x11deviceSyncRequest\x12W\n" + - "\x11device_sync_reply\x18\x04 \x01(\v2).xmtp.device_sync.content.DeviceSyncReplyH\x00R\x0fdeviceSyncReply\x12h\n" + - "\x16user_preference_update\x18\x05 \x01(\v20.xmtp.device_sync.content.V1UserPreferenceUpdateH\x00R\x14userPreferenceUpdateB\x0e\n" + - "\fmessage_typeJ\x04\b\x06\x10\aR\rreadd_requestB\t\n" + - "\acontent*<\n" + - "\vCompression\x12\x17\n" + - "\x13COMPRESSION_DEFLATE\x10\x00\x12\x14\n" + - "\x10COMPRESSION_GZIP\x10\x01B\x98\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\fContentProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_content_proto_rawDescOnce sync.Once - file_mls_message_contents_content_proto_rawDescData []byte -) - -func file_mls_message_contents_content_proto_rawDescGZIP() []byte { - file_mls_message_contents_content_proto_rawDescOnce.Do(func() { - file_mls_message_contents_content_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_proto_rawDesc), len(file_mls_message_contents_content_proto_rawDesc))) - }) - return file_mls_message_contents_content_proto_rawDescData -} - -var file_mls_message_contents_content_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_mls_message_contents_content_proto_msgTypes = make([]protoimpl.MessageInfo, 6) -var file_mls_message_contents_content_proto_goTypes = []any{ - (Compression)(0), // 0: xmtp.mls.message_contents.Compression - (*ContentTypeId)(nil), // 1: xmtp.mls.message_contents.ContentTypeId - (*EncodedContent)(nil), // 2: xmtp.mls.message_contents.EncodedContent - (*PlaintextEnvelope)(nil), // 3: xmtp.mls.message_contents.PlaintextEnvelope - nil, // 4: xmtp.mls.message_contents.EncodedContent.ParametersEntry - (*PlaintextEnvelope_V1)(nil), // 5: xmtp.mls.message_contents.PlaintextEnvelope.V1 - (*PlaintextEnvelope_V2)(nil), // 6: xmtp.mls.message_contents.PlaintextEnvelope.V2 - (*device_sync.DeviceSyncRequest)(nil), // 7: xmtp.device_sync.content.DeviceSyncRequest - (*device_sync.DeviceSyncReply)(nil), // 8: xmtp.device_sync.content.DeviceSyncReply - (*device_sync.V1UserPreferenceUpdate)(nil), // 9: xmtp.device_sync.content.V1UserPreferenceUpdate -} -var file_mls_message_contents_content_proto_depIdxs = []int32{ - 1, // 0: xmtp.mls.message_contents.EncodedContent.type:type_name -> xmtp.mls.message_contents.ContentTypeId - 4, // 1: xmtp.mls.message_contents.EncodedContent.parameters:type_name -> xmtp.mls.message_contents.EncodedContent.ParametersEntry - 0, // 2: xmtp.mls.message_contents.EncodedContent.compression:type_name -> xmtp.mls.message_contents.Compression - 5, // 3: xmtp.mls.message_contents.PlaintextEnvelope.v1:type_name -> xmtp.mls.message_contents.PlaintextEnvelope.V1 - 6, // 4: xmtp.mls.message_contents.PlaintextEnvelope.v2:type_name -> xmtp.mls.message_contents.PlaintextEnvelope.V2 - 7, // 5: xmtp.mls.message_contents.PlaintextEnvelope.V2.device_sync_request:type_name -> xmtp.device_sync.content.DeviceSyncRequest - 8, // 6: xmtp.mls.message_contents.PlaintextEnvelope.V2.device_sync_reply:type_name -> xmtp.device_sync.content.DeviceSyncReply - 9, // 7: xmtp.mls.message_contents.PlaintextEnvelope.V2.user_preference_update:type_name -> xmtp.device_sync.content.V1UserPreferenceUpdate - 8, // [8:8] is the sub-list for method output_type - 8, // [8:8] is the sub-list for method input_type - 8, // [8:8] is the sub-list for extension type_name - 8, // [8:8] is the sub-list for extension extendee - 0, // [0:8] is the sub-list for field type_name -} - -func init() { file_mls_message_contents_content_proto_init() } -func file_mls_message_contents_content_proto_init() { - if File_mls_message_contents_content_proto != nil { - return - } - file_mls_message_contents_content_proto_msgTypes[1].OneofWrappers = []any{} - file_mls_message_contents_content_proto_msgTypes[2].OneofWrappers = []any{ - (*PlaintextEnvelope_V1_)(nil), - (*PlaintextEnvelope_V2_)(nil), - } - file_mls_message_contents_content_proto_msgTypes[5].OneofWrappers = []any{ - (*PlaintextEnvelope_V2_Content)(nil), - (*PlaintextEnvelope_V2_DeviceSyncRequest)(nil), - (*PlaintextEnvelope_V2_DeviceSyncReply)(nil), - (*PlaintextEnvelope_V2_UserPreferenceUpdate)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_proto_rawDesc), len(file_mls_message_contents_content_proto_rawDesc)), - NumEnums: 1, - NumMessages: 6, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_content_proto_goTypes, - DependencyIndexes: file_mls_message_contents_content_proto_depIdxs, - EnumInfos: file_mls_message_contents_content_proto_enumTypes, - MessageInfos: file_mls_message_contents_content_proto_msgTypes, - }.Build() - File_mls_message_contents_content_proto = out.File - file_mls_message_contents_content_proto_goTypes = nil - file_mls_message_contents_content_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/content_types/delete_message.pb.go b/pkg/proto/mls/message_contents/content_types/delete_message.pb.go deleted file mode 100644 index 47a73609..00000000 --- a/pkg/proto/mls/message_contents/content_types/delete_message.pb.go +++ /dev/null @@ -1,137 +0,0 @@ -// delete_message.proto -// This file defines the DeleteMessage message type and is associated with the following ContentTypeId: -// -// ContentTypeId { -// authority_id: "xmtp.org", -// type_id: "deleteMessage", -// version_major: 1, -// version_minor: 0, -// } -// - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/content_types/delete_message.proto - -package content_types - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// DeleteMessage message type -type DeleteMessage struct { - state protoimpl.MessageState `protogen:"open.v1"` - // ID of the message to delete - MessageId string `protobuf:"bytes,1,opt,name=message_id,json=messageId,proto3" json:"message_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DeleteMessage) Reset() { - *x = DeleteMessage{} - mi := &file_mls_message_contents_content_types_delete_message_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DeleteMessage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DeleteMessage) ProtoMessage() {} - -func (x *DeleteMessage) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_types_delete_message_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DeleteMessage.ProtoReflect.Descriptor instead. -func (*DeleteMessage) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_delete_message_proto_rawDescGZIP(), []int{0} -} - -func (x *DeleteMessage) GetMessageId() string { - if x != nil { - return x.MessageId - } - return "" -} - -var File_mls_message_contents_content_types_delete_message_proto protoreflect.FileDescriptor - -const file_mls_message_contents_content_types_delete_message_proto_rawDesc = "" + - "\n" + - "7mls/message_contents/content_types/delete_message.proto\x12'xmtp.mls.message_contents.content_types\".\n" + - "\rDeleteMessage\x12\x1d\n" + - "\n" + - "message_id\x18\x01 \x01(\tR\tmessageIdB\xf0\x02\n" + - "Eorg.xmtp.android.library.push.xmtp.mls.message_contents.content_typesB\x12DeleteMessageProtoP\x01Z[github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents/content_types\xa2\x02\x04XMMC\xaa\x02%Xmtp.Mls.MessageContents.ContentTypes\xca\x02%Xmtp\\Mls\\MessageContents\\ContentTypes\xe2\x021Xmtp\\Mls\\MessageContents\\ContentTypes\\GPBMetadata\xea\x02(Xmtp::Mls::MessageContents::ContentTypesb\x06proto3" - -var ( - file_mls_message_contents_content_types_delete_message_proto_rawDescOnce sync.Once - file_mls_message_contents_content_types_delete_message_proto_rawDescData []byte -) - -func file_mls_message_contents_content_types_delete_message_proto_rawDescGZIP() []byte { - file_mls_message_contents_content_types_delete_message_proto_rawDescOnce.Do(func() { - file_mls_message_contents_content_types_delete_message_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_delete_message_proto_rawDesc), len(file_mls_message_contents_content_types_delete_message_proto_rawDesc))) - }) - return file_mls_message_contents_content_types_delete_message_proto_rawDescData -} - -var file_mls_message_contents_content_types_delete_message_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_mls_message_contents_content_types_delete_message_proto_goTypes = []any{ - (*DeleteMessage)(nil), // 0: xmtp.mls.message_contents.content_types.DeleteMessage -} -var file_mls_message_contents_content_types_delete_message_proto_depIdxs = []int32{ - 0, // [0:0] is the sub-list for method output_type - 0, // [0:0] 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_mls_message_contents_content_types_delete_message_proto_init() } -func file_mls_message_contents_content_types_delete_message_proto_init() { - if File_mls_message_contents_content_types_delete_message_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_delete_message_proto_rawDesc), len(file_mls_message_contents_content_types_delete_message_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_content_types_delete_message_proto_goTypes, - DependencyIndexes: file_mls_message_contents_content_types_delete_message_proto_depIdxs, - MessageInfos: file_mls_message_contents_content_types_delete_message_proto_msgTypes, - }.Build() - File_mls_message_contents_content_types_delete_message_proto = out.File - file_mls_message_contents_content_types_delete_message_proto_goTypes = nil - file_mls_message_contents_content_types_delete_message_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/content_types/edit_message.pb.go b/pkg/proto/mls/message_contents/content_types/edit_message.pb.go deleted file mode 100644 index 6274e44f..00000000 --- a/pkg/proto/mls/message_contents/content_types/edit_message.pb.go +++ /dev/null @@ -1,150 +0,0 @@ -// edit_message.proto -// This file defines the EditMessage message type and is associated with the following ContentTypeId: -// -// ContentTypeId { -// authority_id: "xmtp.org", -// type_id: "editMessage", -// version_major: 1, -// version_minor: 0, -// } -// - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/content_types/edit_message.proto - -package content_types - -import ( - message_contents "github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// EditMessage message type -type EditMessage struct { - state protoimpl.MessageState `protogen:"open.v1"` - // ID of the message to edit - MessageId string `protobuf:"bytes,1,opt,name=message_id,json=messageId,proto3" json:"message_id,omitempty"` - // The new content for the message - EditedContent *message_contents.EncodedContent `protobuf:"bytes,2,opt,name=edited_content,json=editedContent,proto3" json:"edited_content,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EditMessage) Reset() { - *x = EditMessage{} - mi := &file_mls_message_contents_content_types_edit_message_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EditMessage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EditMessage) ProtoMessage() {} - -func (x *EditMessage) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_types_edit_message_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EditMessage.ProtoReflect.Descriptor instead. -func (*EditMessage) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_edit_message_proto_rawDescGZIP(), []int{0} -} - -func (x *EditMessage) GetMessageId() string { - if x != nil { - return x.MessageId - } - return "" -} - -func (x *EditMessage) GetEditedContent() *message_contents.EncodedContent { - if x != nil { - return x.EditedContent - } - return nil -} - -var File_mls_message_contents_content_types_edit_message_proto protoreflect.FileDescriptor - -const file_mls_message_contents_content_types_edit_message_proto_rawDesc = "" + - "\n" + - "5mls/message_contents/content_types/edit_message.proto\x12'xmtp.mls.message_contents.content_types\x1a\"mls/message_contents/content.proto\"~\n" + - "\vEditMessage\x12\x1d\n" + - "\n" + - "message_id\x18\x01 \x01(\tR\tmessageId\x12P\n" + - "\x0eedited_content\x18\x02 \x01(\v2).xmtp.mls.message_contents.EncodedContentR\reditedContentB\xee\x02\n" + - "Eorg.xmtp.android.library.push.xmtp.mls.message_contents.content_typesB\x10EditMessageProtoP\x01Z[github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents/content_types\xa2\x02\x04XMMC\xaa\x02%Xmtp.Mls.MessageContents.ContentTypes\xca\x02%Xmtp\\Mls\\MessageContents\\ContentTypes\xe2\x021Xmtp\\Mls\\MessageContents\\ContentTypes\\GPBMetadata\xea\x02(Xmtp::Mls::MessageContents::ContentTypesb\x06proto3" - -var ( - file_mls_message_contents_content_types_edit_message_proto_rawDescOnce sync.Once - file_mls_message_contents_content_types_edit_message_proto_rawDescData []byte -) - -func file_mls_message_contents_content_types_edit_message_proto_rawDescGZIP() []byte { - file_mls_message_contents_content_types_edit_message_proto_rawDescOnce.Do(func() { - file_mls_message_contents_content_types_edit_message_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_edit_message_proto_rawDesc), len(file_mls_message_contents_content_types_edit_message_proto_rawDesc))) - }) - return file_mls_message_contents_content_types_edit_message_proto_rawDescData -} - -var file_mls_message_contents_content_types_edit_message_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_mls_message_contents_content_types_edit_message_proto_goTypes = []any{ - (*EditMessage)(nil), // 0: xmtp.mls.message_contents.content_types.EditMessage - (*message_contents.EncodedContent)(nil), // 1: xmtp.mls.message_contents.EncodedContent -} -var file_mls_message_contents_content_types_edit_message_proto_depIdxs = []int32{ - 1, // 0: xmtp.mls.message_contents.content_types.EditMessage.edited_content:type_name -> xmtp.mls.message_contents.EncodedContent - 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_mls_message_contents_content_types_edit_message_proto_init() } -func file_mls_message_contents_content_types_edit_message_proto_init() { - if File_mls_message_contents_content_types_edit_message_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_edit_message_proto_rawDesc), len(file_mls_message_contents_content_types_edit_message_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_content_types_edit_message_proto_goTypes, - DependencyIndexes: file_mls_message_contents_content_types_edit_message_proto_depIdxs, - MessageInfos: file_mls_message_contents_content_types_edit_message_proto_msgTypes, - }.Build() - File_mls_message_contents_content_types_edit_message_proto = out.File - file_mls_message_contents_content_types_edit_message_proto_goTypes = nil - file_mls_message_contents_content_types_edit_message_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/content_types/leave_request.pb.go b/pkg/proto/mls/message_contents/content_types/leave_request.pb.go deleted file mode 100644 index 66640c76..00000000 --- a/pkg/proto/mls/message_contents/content_types/leave_request.pb.go +++ /dev/null @@ -1,138 +0,0 @@ -// leave_request.proto -// This file defines the LeaveRequest message type and is associated with the following ContentTypeId: -// -// ContentTypeId { -// authority_id: "xmtp.org", -// type_id: "leaveRequest", -// version_major: 1, -// version_minor: 0, -// } -// - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/content_types/leave_request.proto - -package content_types - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// LeaveRequest message type -type LeaveRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - // A serialized AuthenticatedNote containing the sender's signed, member-only verifiable statement - AuthenticatedNote []byte `protobuf:"bytes,1,opt,name=authenticated_note,json=authenticatedNote,proto3,oneof" json:"authenticated_note,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *LeaveRequest) Reset() { - *x = LeaveRequest{} - mi := &file_mls_message_contents_content_types_leave_request_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *LeaveRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*LeaveRequest) ProtoMessage() {} - -func (x *LeaveRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_types_leave_request_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use LeaveRequest.ProtoReflect.Descriptor instead. -func (*LeaveRequest) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_leave_request_proto_rawDescGZIP(), []int{0} -} - -func (x *LeaveRequest) GetAuthenticatedNote() []byte { - if x != nil { - return x.AuthenticatedNote - } - return nil -} - -var File_mls_message_contents_content_types_leave_request_proto protoreflect.FileDescriptor - -const file_mls_message_contents_content_types_leave_request_proto_rawDesc = "" + - "\n" + - "6mls/message_contents/content_types/leave_request.proto\x12'xmtp.mls.message_contents.content_types\"Y\n" + - "\fLeaveRequest\x122\n" + - "\x12authenticated_note\x18\x01 \x01(\fH\x00R\x11authenticatedNote\x88\x01\x01B\x15\n" + - "\x13_authenticated_noteB\xef\x02\n" + - "Eorg.xmtp.android.library.push.xmtp.mls.message_contents.content_typesB\x11LeaveRequestProtoP\x01Z[github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents/content_types\xa2\x02\x04XMMC\xaa\x02%Xmtp.Mls.MessageContents.ContentTypes\xca\x02%Xmtp\\Mls\\MessageContents\\ContentTypes\xe2\x021Xmtp\\Mls\\MessageContents\\ContentTypes\\GPBMetadata\xea\x02(Xmtp::Mls::MessageContents::ContentTypesb\x06proto3" - -var ( - file_mls_message_contents_content_types_leave_request_proto_rawDescOnce sync.Once - file_mls_message_contents_content_types_leave_request_proto_rawDescData []byte -) - -func file_mls_message_contents_content_types_leave_request_proto_rawDescGZIP() []byte { - file_mls_message_contents_content_types_leave_request_proto_rawDescOnce.Do(func() { - file_mls_message_contents_content_types_leave_request_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_leave_request_proto_rawDesc), len(file_mls_message_contents_content_types_leave_request_proto_rawDesc))) - }) - return file_mls_message_contents_content_types_leave_request_proto_rawDescData -} - -var file_mls_message_contents_content_types_leave_request_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_mls_message_contents_content_types_leave_request_proto_goTypes = []any{ - (*LeaveRequest)(nil), // 0: xmtp.mls.message_contents.content_types.LeaveRequest -} -var file_mls_message_contents_content_types_leave_request_proto_depIdxs = []int32{ - 0, // [0:0] is the sub-list for method output_type - 0, // [0:0] 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_mls_message_contents_content_types_leave_request_proto_init() } -func file_mls_message_contents_content_types_leave_request_proto_init() { - if File_mls_message_contents_content_types_leave_request_proto != nil { - return - } - file_mls_message_contents_content_types_leave_request_proto_msgTypes[0].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_leave_request_proto_rawDesc), len(file_mls_message_contents_content_types_leave_request_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_content_types_leave_request_proto_goTypes, - DependencyIndexes: file_mls_message_contents_content_types_leave_request_proto_depIdxs, - MessageInfos: file_mls_message_contents_content_types_leave_request_proto_msgTypes, - }.Build() - File_mls_message_contents_content_types_leave_request_proto = out.File - file_mls_message_contents_content_types_leave_request_proto_goTypes = nil - file_mls_message_contents_content_types_leave_request_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/content_types/multi_remote_attachment.pb.go b/pkg/proto/mls/message_contents/content_types/multi_remote_attachment.pb.go deleted file mode 100644 index 15cebd36..00000000 --- a/pkg/proto/mls/message_contents/content_types/multi_remote_attachment.pb.go +++ /dev/null @@ -1,258 +0,0 @@ -// multi_remote_attachment.proto -// This file defines the MultiRemoteAttachment message type and is associated with the following ContentTypeId: -// -// ContentTypeId { -// authority_id: "xmtp.org", -// type_id: "multiRemoteStaticContent", -// version_major: 1, -// version_minor: 0, -// } -// - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/content_types/multi_remote_attachment.proto - -package content_types - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// MultiRemoteAttachment message type -type MultiRemoteAttachment struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Array of attachment information - Attachments []*RemoteAttachmentInfo `protobuf:"bytes,1,rep,name=attachments,proto3" json:"attachments,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MultiRemoteAttachment) Reset() { - *x = MultiRemoteAttachment{} - mi := &file_mls_message_contents_content_types_multi_remote_attachment_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MultiRemoteAttachment) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MultiRemoteAttachment) ProtoMessage() {} - -func (x *MultiRemoteAttachment) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_types_multi_remote_attachment_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MultiRemoteAttachment.ProtoReflect.Descriptor instead. -func (*MultiRemoteAttachment) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDescGZIP(), []int{0} -} - -func (x *MultiRemoteAttachment) GetAttachments() []*RemoteAttachmentInfo { - if x != nil { - return x.Attachments - } - return nil -} - -type RemoteAttachmentInfo struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The SHA256 hash of the remote content - ContentDigest string `protobuf:"bytes,1,opt,name=content_digest,json=contentDigest,proto3" json:"content_digest,omitempty"` - // A 32 byte array for decrypting the remote content payload - Secret []byte `protobuf:"bytes,2,opt,name=secret,proto3" json:"secret,omitempty"` - // A byte array for the nonce used to encrypt the remote content payload - Nonce []byte `protobuf:"bytes,3,opt,name=nonce,proto3" json:"nonce,omitempty"` - // A byte array for the salt used to encrypt the remote content payload - Salt []byte `protobuf:"bytes,4,opt,name=salt,proto3" json:"salt,omitempty"` - // The scheme of the URL. Must be "https://" - Scheme string `protobuf:"bytes,5,opt,name=scheme,proto3" json:"scheme,omitempty"` - // The URL of the remote content - Url string `protobuf:"bytes,6,opt,name=url,proto3" json:"url,omitempty"` - // The size of the encrypted content in bytes (max size of 4GB) - ContentLength *uint32 `protobuf:"varint,7,opt,name=content_length,json=contentLength,proto3,oneof" json:"content_length,omitempty"` - // The filename of the remote content - Filename *string `protobuf:"bytes,8,opt,name=filename,proto3,oneof" json:"filename,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *RemoteAttachmentInfo) Reset() { - *x = RemoteAttachmentInfo{} - mi := &file_mls_message_contents_content_types_multi_remote_attachment_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *RemoteAttachmentInfo) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RemoteAttachmentInfo) ProtoMessage() {} - -func (x *RemoteAttachmentInfo) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_types_multi_remote_attachment_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RemoteAttachmentInfo.ProtoReflect.Descriptor instead. -func (*RemoteAttachmentInfo) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDescGZIP(), []int{1} -} - -func (x *RemoteAttachmentInfo) GetContentDigest() string { - if x != nil { - return x.ContentDigest - } - return "" -} - -func (x *RemoteAttachmentInfo) GetSecret() []byte { - if x != nil { - return x.Secret - } - return nil -} - -func (x *RemoteAttachmentInfo) GetNonce() []byte { - if x != nil { - return x.Nonce - } - return nil -} - -func (x *RemoteAttachmentInfo) GetSalt() []byte { - if x != nil { - return x.Salt - } - return nil -} - -func (x *RemoteAttachmentInfo) GetScheme() string { - if x != nil { - return x.Scheme - } - return "" -} - -func (x *RemoteAttachmentInfo) GetUrl() string { - if x != nil { - return x.Url - } - return "" -} - -func (x *RemoteAttachmentInfo) GetContentLength() uint32 { - if x != nil && x.ContentLength != nil { - return *x.ContentLength - } - return 0 -} - -func (x *RemoteAttachmentInfo) GetFilename() string { - if x != nil && x.Filename != nil { - return *x.Filename - } - return "" -} - -var File_mls_message_contents_content_types_multi_remote_attachment_proto protoreflect.FileDescriptor - -const file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDesc = "" + - "\n" + - "@mls/message_contents/content_types/multi_remote_attachment.proto\x12'xmtp.mls.message_contents.content_types\"x\n" + - "\x15MultiRemoteAttachment\x12_\n" + - "\vattachments\x18\x01 \x03(\v2=.xmtp.mls.message_contents.content_types.RemoteAttachmentInfoR\vattachments\"\x96\x02\n" + - "\x14RemoteAttachmentInfo\x12%\n" + - "\x0econtent_digest\x18\x01 \x01(\tR\rcontentDigest\x12\x16\n" + - "\x06secret\x18\x02 \x01(\fR\x06secret\x12\x14\n" + - "\x05nonce\x18\x03 \x01(\fR\x05nonce\x12\x12\n" + - "\x04salt\x18\x04 \x01(\fR\x04salt\x12\x16\n" + - "\x06scheme\x18\x05 \x01(\tR\x06scheme\x12\x10\n" + - "\x03url\x18\x06 \x01(\tR\x03url\x12*\n" + - "\x0econtent_length\x18\a \x01(\rH\x00R\rcontentLength\x88\x01\x01\x12\x1f\n" + - "\bfilename\x18\b \x01(\tH\x01R\bfilename\x88\x01\x01B\x11\n" + - "\x0f_content_lengthB\v\n" + - "\t_filenameB\xf8\x02\n" + - "Eorg.xmtp.android.library.push.xmtp.mls.message_contents.content_typesB\x1aMultiRemoteAttachmentProtoP\x01Z[github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents/content_types\xa2\x02\x04XMMC\xaa\x02%Xmtp.Mls.MessageContents.ContentTypes\xca\x02%Xmtp\\Mls\\MessageContents\\ContentTypes\xe2\x021Xmtp\\Mls\\MessageContents\\ContentTypes\\GPBMetadata\xea\x02(Xmtp::Mls::MessageContents::ContentTypesb\x06proto3" - -var ( - file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDescOnce sync.Once - file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDescData []byte -) - -func file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDescGZIP() []byte { - file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDescOnce.Do(func() { - file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDesc), len(file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDesc))) - }) - return file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDescData -} - -var file_mls_message_contents_content_types_multi_remote_attachment_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_mls_message_contents_content_types_multi_remote_attachment_proto_goTypes = []any{ - (*MultiRemoteAttachment)(nil), // 0: xmtp.mls.message_contents.content_types.MultiRemoteAttachment - (*RemoteAttachmentInfo)(nil), // 1: xmtp.mls.message_contents.content_types.RemoteAttachmentInfo -} -var file_mls_message_contents_content_types_multi_remote_attachment_proto_depIdxs = []int32{ - 1, // 0: xmtp.mls.message_contents.content_types.MultiRemoteAttachment.attachments:type_name -> xmtp.mls.message_contents.content_types.RemoteAttachmentInfo - 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_mls_message_contents_content_types_multi_remote_attachment_proto_init() } -func file_mls_message_contents_content_types_multi_remote_attachment_proto_init() { - if File_mls_message_contents_content_types_multi_remote_attachment_proto != nil { - return - } - file_mls_message_contents_content_types_multi_remote_attachment_proto_msgTypes[1].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDesc), len(file_mls_message_contents_content_types_multi_remote_attachment_proto_rawDesc)), - NumEnums: 0, - NumMessages: 2, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_content_types_multi_remote_attachment_proto_goTypes, - DependencyIndexes: file_mls_message_contents_content_types_multi_remote_attachment_proto_depIdxs, - MessageInfos: file_mls_message_contents_content_types_multi_remote_attachment_proto_msgTypes, - }.Build() - File_mls_message_contents_content_types_multi_remote_attachment_proto = out.File - file_mls_message_contents_content_types_multi_remote_attachment_proto_goTypes = nil - file_mls_message_contents_content_types_multi_remote_attachment_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/content_types/reaction.pb.go b/pkg/proto/mls/message_contents/content_types/reaction.pb.go deleted file mode 100644 index 46a9af23..00000000 --- a/pkg/proto/mls/message_contents/content_types/reaction.pb.go +++ /dev/null @@ -1,296 +0,0 @@ -// reaction.proto -// This file defines the ReactionV2 message type and is associated with the following ContentTypeId: -// -// ContentTypeId { -// authority_id: "xmtp.org", -// type_id: "reaction", -// version_major: 2, -// version_minor: 0, -// } -// - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/content_types/reaction.proto - -package content_types - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Action enum to represent reaction states -type ReactionAction int32 - -const ( - ReactionAction_REACTION_ACTION_UNSPECIFIED ReactionAction = 0 - ReactionAction_REACTION_ACTION_ADDED ReactionAction = 1 - ReactionAction_REACTION_ACTION_REMOVED ReactionAction = 2 -) - -// Enum value maps for ReactionAction. -var ( - ReactionAction_name = map[int32]string{ - 0: "REACTION_ACTION_UNSPECIFIED", - 1: "REACTION_ACTION_ADDED", - 2: "REACTION_ACTION_REMOVED", - } - ReactionAction_value = map[string]int32{ - "REACTION_ACTION_UNSPECIFIED": 0, - "REACTION_ACTION_ADDED": 1, - "REACTION_ACTION_REMOVED": 2, - } -) - -func (x ReactionAction) Enum() *ReactionAction { - p := new(ReactionAction) - *p = x - return p -} - -func (x ReactionAction) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ReactionAction) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_content_types_reaction_proto_enumTypes[0].Descriptor() -} - -func (ReactionAction) Type() protoreflect.EnumType { - return &file_mls_message_contents_content_types_reaction_proto_enumTypes[0] -} - -func (x ReactionAction) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ReactionAction.Descriptor instead. -func (ReactionAction) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_reaction_proto_rawDescGZIP(), []int{0} -} - -// Schema enum to represent reaction content types -type ReactionSchema int32 - -const ( - ReactionSchema_REACTION_SCHEMA_UNSPECIFIED ReactionSchema = 0 - ReactionSchema_REACTION_SCHEMA_UNICODE ReactionSchema = 1 - ReactionSchema_REACTION_SCHEMA_SHORTCODE ReactionSchema = 2 - ReactionSchema_REACTION_SCHEMA_CUSTOM ReactionSchema = 3 -) - -// Enum value maps for ReactionSchema. -var ( - ReactionSchema_name = map[int32]string{ - 0: "REACTION_SCHEMA_UNSPECIFIED", - 1: "REACTION_SCHEMA_UNICODE", - 2: "REACTION_SCHEMA_SHORTCODE", - 3: "REACTION_SCHEMA_CUSTOM", - } - ReactionSchema_value = map[string]int32{ - "REACTION_SCHEMA_UNSPECIFIED": 0, - "REACTION_SCHEMA_UNICODE": 1, - "REACTION_SCHEMA_SHORTCODE": 2, - "REACTION_SCHEMA_CUSTOM": 3, - } -) - -func (x ReactionSchema) Enum() *ReactionSchema { - p := new(ReactionSchema) - *p = x - return p -} - -func (x ReactionSchema) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ReactionSchema) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_content_types_reaction_proto_enumTypes[1].Descriptor() -} - -func (ReactionSchema) Type() protoreflect.EnumType { - return &file_mls_message_contents_content_types_reaction_proto_enumTypes[1] -} - -func (x ReactionSchema) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ReactionSchema.Descriptor instead. -func (ReactionSchema) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_reaction_proto_rawDescGZIP(), []int{1} -} - -// Reaction message type -type ReactionV2 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The message ID being reacted to - Reference string `protobuf:"bytes,1,opt,name=reference,proto3" json:"reference,omitempty"` - // The inbox ID of the user who sent the message being reacted to - // Optional for group messages - ReferenceInboxId string `protobuf:"bytes,2,opt,name=reference_inbox_id,json=referenceInboxId,proto3" json:"reference_inbox_id,omitempty"` - // The action of the reaction (added or removed) - Action ReactionAction `protobuf:"varint,3,opt,name=action,proto3,enum=xmtp.mls.message_contents.content_types.ReactionAction" json:"action,omitempty"` - // The content of the reaction - Content string `protobuf:"bytes,4,opt,name=content,proto3" json:"content,omitempty"` - // The schema of the reaction content - Schema ReactionSchema `protobuf:"varint,5,opt,name=schema,proto3,enum=xmtp.mls.message_contents.content_types.ReactionSchema" json:"schema,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ReactionV2) Reset() { - *x = ReactionV2{} - mi := &file_mls_message_contents_content_types_reaction_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ReactionV2) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ReactionV2) ProtoMessage() {} - -func (x *ReactionV2) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_types_reaction_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ReactionV2.ProtoReflect.Descriptor instead. -func (*ReactionV2) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_reaction_proto_rawDescGZIP(), []int{0} -} - -func (x *ReactionV2) GetReference() string { - if x != nil { - return x.Reference - } - return "" -} - -func (x *ReactionV2) GetReferenceInboxId() string { - if x != nil { - return x.ReferenceInboxId - } - return "" -} - -func (x *ReactionV2) GetAction() ReactionAction { - if x != nil { - return x.Action - } - return ReactionAction_REACTION_ACTION_UNSPECIFIED -} - -func (x *ReactionV2) GetContent() string { - if x != nil { - return x.Content - } - return "" -} - -func (x *ReactionV2) GetSchema() ReactionSchema { - if x != nil { - return x.Schema - } - return ReactionSchema_REACTION_SCHEMA_UNSPECIFIED -} - -var File_mls_message_contents_content_types_reaction_proto protoreflect.FileDescriptor - -const file_mls_message_contents_content_types_reaction_proto_rawDesc = "" + - "\n" + - "1mls/message_contents/content_types/reaction.proto\x12'xmtp.mls.message_contents.content_types\"\x94\x02\n" + - "\n" + - "ReactionV2\x12\x1c\n" + - "\treference\x18\x01 \x01(\tR\treference\x12,\n" + - "\x12reference_inbox_id\x18\x02 \x01(\tR\x10referenceInboxId\x12O\n" + - "\x06action\x18\x03 \x01(\x0e27.xmtp.mls.message_contents.content_types.ReactionActionR\x06action\x12\x18\n" + - "\acontent\x18\x04 \x01(\tR\acontent\x12O\n" + - "\x06schema\x18\x05 \x01(\x0e27.xmtp.mls.message_contents.content_types.ReactionSchemaR\x06schema*i\n" + - "\x0eReactionAction\x12\x1f\n" + - "\x1bREACTION_ACTION_UNSPECIFIED\x10\x00\x12\x19\n" + - "\x15REACTION_ACTION_ADDED\x10\x01\x12\x1b\n" + - "\x17REACTION_ACTION_REMOVED\x10\x02*\x89\x01\n" + - "\x0eReactionSchema\x12\x1f\n" + - "\x1bREACTION_SCHEMA_UNSPECIFIED\x10\x00\x12\x1b\n" + - "\x17REACTION_SCHEMA_UNICODE\x10\x01\x12\x1d\n" + - "\x19REACTION_SCHEMA_SHORTCODE\x10\x02\x12\x1a\n" + - "\x16REACTION_SCHEMA_CUSTOM\x10\x03B\xeb\x02\n" + - "Eorg.xmtp.android.library.push.xmtp.mls.message_contents.content_typesB\rReactionProtoP\x01Z[github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents/content_types\xa2\x02\x04XMMC\xaa\x02%Xmtp.Mls.MessageContents.ContentTypes\xca\x02%Xmtp\\Mls\\MessageContents\\ContentTypes\xe2\x021Xmtp\\Mls\\MessageContents\\ContentTypes\\GPBMetadata\xea\x02(Xmtp::Mls::MessageContents::ContentTypesb\x06proto3" - -var ( - file_mls_message_contents_content_types_reaction_proto_rawDescOnce sync.Once - file_mls_message_contents_content_types_reaction_proto_rawDescData []byte -) - -func file_mls_message_contents_content_types_reaction_proto_rawDescGZIP() []byte { - file_mls_message_contents_content_types_reaction_proto_rawDescOnce.Do(func() { - file_mls_message_contents_content_types_reaction_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_reaction_proto_rawDesc), len(file_mls_message_contents_content_types_reaction_proto_rawDesc))) - }) - return file_mls_message_contents_content_types_reaction_proto_rawDescData -} - -var file_mls_message_contents_content_types_reaction_proto_enumTypes = make([]protoimpl.EnumInfo, 2) -var file_mls_message_contents_content_types_reaction_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_mls_message_contents_content_types_reaction_proto_goTypes = []any{ - (ReactionAction)(0), // 0: xmtp.mls.message_contents.content_types.ReactionAction - (ReactionSchema)(0), // 1: xmtp.mls.message_contents.content_types.ReactionSchema - (*ReactionV2)(nil), // 2: xmtp.mls.message_contents.content_types.ReactionV2 -} -var file_mls_message_contents_content_types_reaction_proto_depIdxs = []int32{ - 0, // 0: xmtp.mls.message_contents.content_types.ReactionV2.action:type_name -> xmtp.mls.message_contents.content_types.ReactionAction - 1, // 1: xmtp.mls.message_contents.content_types.ReactionV2.schema:type_name -> xmtp.mls.message_contents.content_types.ReactionSchema - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_mls_message_contents_content_types_reaction_proto_init() } -func file_mls_message_contents_content_types_reaction_proto_init() { - if File_mls_message_contents_content_types_reaction_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_reaction_proto_rawDesc), len(file_mls_message_contents_content_types_reaction_proto_rawDesc)), - NumEnums: 2, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_content_types_reaction_proto_goTypes, - DependencyIndexes: file_mls_message_contents_content_types_reaction_proto_depIdxs, - EnumInfos: file_mls_message_contents_content_types_reaction_proto_enumTypes, - MessageInfos: file_mls_message_contents_content_types_reaction_proto_msgTypes, - }.Build() - File_mls_message_contents_content_types_reaction_proto = out.File - file_mls_message_contents_content_types_reaction_proto_goTypes = nil - file_mls_message_contents_content_types_reaction_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/content_types/wallet_send_calls.pb.go b/pkg/proto/mls/message_contents/content_types/wallet_send_calls.pb.go deleted file mode 100644 index 708060ba..00000000 --- a/pkg/proto/mls/message_contents/content_types/wallet_send_calls.pb.go +++ /dev/null @@ -1,274 +0,0 @@ -// wallet_send_calls.proto -// This file defines the WalletSendCalls message type and is associated with the following ContentTypeId: -// -// ContentTypeId { -// authority_id: "xmtp.org", -// type_id: "walletSendCalls", -// version_major: 1, -// version_minor: 0, -// } -// - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/content_types/wallet_send_calls.proto - -package content_types - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// WalletSendCalls represents parameters for sending wallet calls -type WalletSendCalls struct { - state protoimpl.MessageState `protogen:"open.v1"` - Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` - // hex chain id, e.g., "0x1" - ChainId string `protobuf:"bytes,2,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"` - // hex address of the sender, e.g., "0xabc..." - From string `protobuf:"bytes,3,opt,name=from,proto3" json:"from,omitempty"` - Calls []*Call `protobuf:"bytes,4,rep,name=calls,proto3" json:"calls,omitempty"` - // wallet capabilities to request or configure - Capabilities map[string]string `protobuf:"bytes,5,rep,name=capabilities,proto3" json:"capabilities,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WalletSendCalls) Reset() { - *x = WalletSendCalls{} - mi := &file_mls_message_contents_content_types_wallet_send_calls_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WalletSendCalls) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WalletSendCalls) ProtoMessage() {} - -func (x *WalletSendCalls) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_types_wallet_send_calls_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WalletSendCalls.ProtoReflect.Descriptor instead. -func (*WalletSendCalls) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_wallet_send_calls_proto_rawDescGZIP(), []int{0} -} - -func (x *WalletSendCalls) GetVersion() string { - if x != nil { - return x.Version - } - return "" -} - -func (x *WalletSendCalls) GetChainId() string { - if x != nil { - return x.ChainId - } - return "" -} - -func (x *WalletSendCalls) GetFrom() string { - if x != nil { - return x.From - } - return "" -} - -func (x *WalletSendCalls) GetCalls() []*Call { - if x != nil { - return x.Calls - } - return nil -} - -func (x *WalletSendCalls) GetCapabilities() map[string]string { - if x != nil { - return x.Capabilities - } - return nil -} - -// Call represents an individual transaction call -type Call struct { - state protoimpl.MessageState `protogen:"open.v1"` - // destination address - To string `protobuf:"bytes,1,opt,name=to,proto3" json:"to,omitempty"` - // call data payload - Data string `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` - // hex value to send - Value string `protobuf:"bytes,3,opt,name=value,proto3" json:"value,omitempty"` - // hex gas limit - Gas string `protobuf:"bytes,4,opt,name=gas,proto3" json:"gas,omitempty"` - // metadata for the call - Metadata map[string]string `protobuf:"bytes,5,rep,name=metadata,proto3" json:"metadata,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Call) Reset() { - *x = Call{} - mi := &file_mls_message_contents_content_types_wallet_send_calls_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Call) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Call) ProtoMessage() {} - -func (x *Call) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_content_types_wallet_send_calls_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Call.ProtoReflect.Descriptor instead. -func (*Call) Descriptor() ([]byte, []int) { - return file_mls_message_contents_content_types_wallet_send_calls_proto_rawDescGZIP(), []int{1} -} - -func (x *Call) GetTo() string { - if x != nil { - return x.To - } - return "" -} - -func (x *Call) GetData() string { - if x != nil { - return x.Data - } - return "" -} - -func (x *Call) GetValue() string { - if x != nil { - return x.Value - } - return "" -} - -func (x *Call) GetGas() string { - if x != nil { - return x.Gas - } - return "" -} - -func (x *Call) GetMetadata() map[string]string { - if x != nil { - return x.Metadata - } - return nil -} - -var File_mls_message_contents_content_types_wallet_send_calls_proto protoreflect.FileDescriptor - -const file_mls_message_contents_content_types_wallet_send_calls_proto_rawDesc = "" + - "\n" + - ":mls/message_contents/content_types/wallet_send_calls.proto\x12'xmtp.mls.message_contents.content_types\"\xd0\x02\n" + - "\x0fWalletSendCalls\x12\x18\n" + - "\aversion\x18\x01 \x01(\tR\aversion\x12\x19\n" + - "\bchain_id\x18\x02 \x01(\tR\achainId\x12\x12\n" + - "\x04from\x18\x03 \x01(\tR\x04from\x12C\n" + - "\x05calls\x18\x04 \x03(\v2-.xmtp.mls.message_contents.content_types.CallR\x05calls\x12n\n" + - "\fcapabilities\x18\x05 \x03(\v2J.xmtp.mls.message_contents.content_types.WalletSendCalls.CapabilitiesEntryR\fcapabilities\x1a?\n" + - "\x11CapabilitiesEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\"\xe8\x01\n" + - "\x04Call\x12\x0e\n" + - "\x02to\x18\x01 \x01(\tR\x02to\x12\x12\n" + - "\x04data\x18\x02 \x01(\tR\x04data\x12\x14\n" + - "\x05value\x18\x03 \x01(\tR\x05value\x12\x10\n" + - "\x03gas\x18\x04 \x01(\tR\x03gas\x12W\n" + - "\bmetadata\x18\x05 \x03(\v2;.xmtp.mls.message_contents.content_types.Call.MetadataEntryR\bmetadata\x1a;\n" + - "\rMetadataEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01B\xf2\x02\n" + - "Eorg.xmtp.android.library.push.xmtp.mls.message_contents.content_typesB\x14WalletSendCallsProtoP\x01Z[github.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents/content_types\xa2\x02\x04XMMC\xaa\x02%Xmtp.Mls.MessageContents.ContentTypes\xca\x02%Xmtp\\Mls\\MessageContents\\ContentTypes\xe2\x021Xmtp\\Mls\\MessageContents\\ContentTypes\\GPBMetadata\xea\x02(Xmtp::Mls::MessageContents::ContentTypesb\x06proto3" - -var ( - file_mls_message_contents_content_types_wallet_send_calls_proto_rawDescOnce sync.Once - file_mls_message_contents_content_types_wallet_send_calls_proto_rawDescData []byte -) - -func file_mls_message_contents_content_types_wallet_send_calls_proto_rawDescGZIP() []byte { - file_mls_message_contents_content_types_wallet_send_calls_proto_rawDescOnce.Do(func() { - file_mls_message_contents_content_types_wallet_send_calls_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_wallet_send_calls_proto_rawDesc), len(file_mls_message_contents_content_types_wallet_send_calls_proto_rawDesc))) - }) - return file_mls_message_contents_content_types_wallet_send_calls_proto_rawDescData -} - -var file_mls_message_contents_content_types_wallet_send_calls_proto_msgTypes = make([]protoimpl.MessageInfo, 4) -var file_mls_message_contents_content_types_wallet_send_calls_proto_goTypes = []any{ - (*WalletSendCalls)(nil), // 0: xmtp.mls.message_contents.content_types.WalletSendCalls - (*Call)(nil), // 1: xmtp.mls.message_contents.content_types.Call - nil, // 2: xmtp.mls.message_contents.content_types.WalletSendCalls.CapabilitiesEntry - nil, // 3: xmtp.mls.message_contents.content_types.Call.MetadataEntry -} -var file_mls_message_contents_content_types_wallet_send_calls_proto_depIdxs = []int32{ - 1, // 0: xmtp.mls.message_contents.content_types.WalletSendCalls.calls:type_name -> xmtp.mls.message_contents.content_types.Call - 2, // 1: xmtp.mls.message_contents.content_types.WalletSendCalls.capabilities:type_name -> xmtp.mls.message_contents.content_types.WalletSendCalls.CapabilitiesEntry - 3, // 2: xmtp.mls.message_contents.content_types.Call.metadata:type_name -> xmtp.mls.message_contents.content_types.Call.MetadataEntry - 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_mls_message_contents_content_types_wallet_send_calls_proto_init() } -func file_mls_message_contents_content_types_wallet_send_calls_proto_init() { - if File_mls_message_contents_content_types_wallet_send_calls_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_content_types_wallet_send_calls_proto_rawDesc), len(file_mls_message_contents_content_types_wallet_send_calls_proto_rawDesc)), - NumEnums: 0, - NumMessages: 4, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_content_types_wallet_send_calls_proto_goTypes, - DependencyIndexes: file_mls_message_contents_content_types_wallet_send_calls_proto_depIdxs, - MessageInfos: file_mls_message_contents_content_types_wallet_send_calls_proto_msgTypes, - }.Build() - File_mls_message_contents_content_types_wallet_send_calls_proto = out.File - file_mls_message_contents_content_types_wallet_send_calls_proto_goTypes = nil - file_mls_message_contents_content_types_wallet_send_calls_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/group_membership.pb.go b/pkg/proto/mls/message_contents/group_membership.pb.go deleted file mode 100644 index 6a058242..00000000 --- a/pkg/proto/mls/message_contents/group_membership.pb.go +++ /dev/null @@ -1,142 +0,0 @@ -// Group membership - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/group_membership.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Contains a mapping of `inbox_id` -> `sequence_id` for all members of a group. -// Designed to be stored in the group context extension of the MLS group -type GroupMembership struct { - state protoimpl.MessageState `protogen:"open.v1"` - Members map[string]uint64 `protobuf:"bytes,1,rep,name=members,proto3" json:"members,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"varint,2,opt,name=value"` - // List of installations that failed to be added due to errors encountered during the evaluation process. - FailedInstallations [][]byte `protobuf:"bytes,2,rep,name=failed_installations,json=failedInstallations,proto3" json:"failed_installations,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMembership) Reset() { - *x = GroupMembership{} - mi := &file_mls_message_contents_group_membership_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMembership) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMembership) ProtoMessage() {} - -func (x *GroupMembership) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_membership_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMembership.ProtoReflect.Descriptor instead. -func (*GroupMembership) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_membership_proto_rawDescGZIP(), []int{0} -} - -func (x *GroupMembership) GetMembers() map[string]uint64 { - if x != nil { - return x.Members - } - return nil -} - -func (x *GroupMembership) GetFailedInstallations() [][]byte { - if x != nil { - return x.FailedInstallations - } - return nil -} - -var File_mls_message_contents_group_membership_proto protoreflect.FileDescriptor - -const file_mls_message_contents_group_membership_proto_rawDesc = "" + - "\n" + - "+mls/message_contents/group_membership.proto\x12\x19xmtp.mls.message_contents\"\xd3\x01\n" + - "\x0fGroupMembership\x12Q\n" + - "\amembers\x18\x01 \x03(\v27.xmtp.mls.message_contents.GroupMembership.MembersEntryR\amembers\x121\n" + - "\x14failed_installations\x18\x02 \x03(\fR\x13failedInstallations\x1a:\n" + - "\fMembersEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\x04R\x05value:\x028\x01B\xa0\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x14GroupMembershipProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_group_membership_proto_rawDescOnce sync.Once - file_mls_message_contents_group_membership_proto_rawDescData []byte -) - -func file_mls_message_contents_group_membership_proto_rawDescGZIP() []byte { - file_mls_message_contents_group_membership_proto_rawDescOnce.Do(func() { - file_mls_message_contents_group_membership_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_group_membership_proto_rawDesc), len(file_mls_message_contents_group_membership_proto_rawDesc))) - }) - return file_mls_message_contents_group_membership_proto_rawDescData -} - -var file_mls_message_contents_group_membership_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_mls_message_contents_group_membership_proto_goTypes = []any{ - (*GroupMembership)(nil), // 0: xmtp.mls.message_contents.GroupMembership - nil, // 1: xmtp.mls.message_contents.GroupMembership.MembersEntry -} -var file_mls_message_contents_group_membership_proto_depIdxs = []int32{ - 1, // 0: xmtp.mls.message_contents.GroupMembership.members:type_name -> xmtp.mls.message_contents.GroupMembership.MembersEntry - 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_mls_message_contents_group_membership_proto_init() } -func file_mls_message_contents_group_membership_proto_init() { - if File_mls_message_contents_group_membership_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_group_membership_proto_rawDesc), len(file_mls_message_contents_group_membership_proto_rawDesc)), - NumEnums: 0, - NumMessages: 2, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_group_membership_proto_goTypes, - DependencyIndexes: file_mls_message_contents_group_membership_proto_depIdxs, - MessageInfos: file_mls_message_contents_group_membership_proto_msgTypes, - }.Build() - File_mls_message_contents_group_membership_proto = out.File - file_mls_message_contents_group_membership_proto_goTypes = nil - file_mls_message_contents_group_membership_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/group_metadata.pb.go b/pkg/proto/mls/message_contents/group_metadata.pb.go deleted file mode 100644 index 931ff964..00000000 --- a/pkg/proto/mls/message_contents/group_metadata.pb.go +++ /dev/null @@ -1,346 +0,0 @@ -// Group immutable metadata - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/group_metadata.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Defines the type of conversation -type ConversationType int32 - -const ( - ConversationType_CONVERSATION_TYPE_UNSPECIFIED ConversationType = 0 - ConversationType_CONVERSATION_TYPE_GROUP ConversationType = 1 - ConversationType_CONVERSATION_TYPE_DM ConversationType = 2 - ConversationType_CONVERSATION_TYPE_SYNC ConversationType = 3 - ConversationType_CONVERSATION_TYPE_ONESHOT ConversationType = 4 -) - -// Enum value maps for ConversationType. -var ( - ConversationType_name = map[int32]string{ - 0: "CONVERSATION_TYPE_UNSPECIFIED", - 1: "CONVERSATION_TYPE_GROUP", - 2: "CONVERSATION_TYPE_DM", - 3: "CONVERSATION_TYPE_SYNC", - 4: "CONVERSATION_TYPE_ONESHOT", - } - ConversationType_value = map[string]int32{ - "CONVERSATION_TYPE_UNSPECIFIED": 0, - "CONVERSATION_TYPE_GROUP": 1, - "CONVERSATION_TYPE_DM": 2, - "CONVERSATION_TYPE_SYNC": 3, - "CONVERSATION_TYPE_ONESHOT": 4, - } -) - -func (x ConversationType) Enum() *ConversationType { - p := new(ConversationType) - *p = x - return p -} - -func (x ConversationType) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ConversationType) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_group_metadata_proto_enumTypes[0].Descriptor() -} - -func (ConversationType) Type() protoreflect.EnumType { - return &file_mls_message_contents_group_metadata_proto_enumTypes[0] -} - -func (x ConversationType) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ConversationType.Descriptor instead. -func (ConversationType) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_group_metadata_proto_rawDescGZIP(), []int{0} -} - -// Parent message for group metadata -type GroupMetadataV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - ConversationType ConversationType `protobuf:"varint,1,opt,name=conversation_type,json=conversationType,proto3,enum=xmtp.mls.message_contents.ConversationType" json:"conversation_type,omitempty"` - // This will be removed soon - CreatorAccountAddress string `protobuf:"bytes,2,opt,name=creator_account_address,json=creatorAccountAddress,proto3" json:"creator_account_address,omitempty"` - CreatorInboxId string `protobuf:"bytes,3,opt,name=creator_inbox_id,json=creatorInboxId,proto3" json:"creator_inbox_id,omitempty"` - // Should only be present for CONVERSATION_TYPE_DM - DmMembers *DmMembers `protobuf:"bytes,4,opt,name=dm_members,json=dmMembers,proto3,oneof" json:"dm_members,omitempty"` - // Should only be present for CONVERSATION_TYPE_ONESHOT - OneshotMessage *OneshotMessage `protobuf:"bytes,5,opt,name=oneshot_message,json=oneshotMessage,proto3,oneof" json:"oneshot_message,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMetadataV1) Reset() { - *x = GroupMetadataV1{} - mi := &file_mls_message_contents_group_metadata_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMetadataV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMetadataV1) ProtoMessage() {} - -func (x *GroupMetadataV1) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_metadata_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMetadataV1.ProtoReflect.Descriptor instead. -func (*GroupMetadataV1) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_metadata_proto_rawDescGZIP(), []int{0} -} - -func (x *GroupMetadataV1) GetConversationType() ConversationType { - if x != nil { - return x.ConversationType - } - return ConversationType_CONVERSATION_TYPE_UNSPECIFIED -} - -func (x *GroupMetadataV1) GetCreatorAccountAddress() string { - if x != nil { - return x.CreatorAccountAddress - } - return "" -} - -func (x *GroupMetadataV1) GetCreatorInboxId() string { - if x != nil { - return x.CreatorInboxId - } - return "" -} - -func (x *GroupMetadataV1) GetDmMembers() *DmMembers { - if x != nil { - return x.DmMembers - } - return nil -} - -func (x *GroupMetadataV1) GetOneshotMessage() *OneshotMessage { - if x != nil { - return x.OneshotMessage - } - return nil -} - -// Wrapper around an Inbox Id -type Inbox struct { - state protoimpl.MessageState `protogen:"open.v1"` - InboxId string `protobuf:"bytes,1,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Inbox) Reset() { - *x = Inbox{} - mi := &file_mls_message_contents_group_metadata_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Inbox) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Inbox) ProtoMessage() {} - -func (x *Inbox) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_metadata_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Inbox.ProtoReflect.Descriptor instead. -func (*Inbox) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_metadata_proto_rawDescGZIP(), []int{1} -} - -func (x *Inbox) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -// Ordering does not matter here -type DmMembers struct { - state protoimpl.MessageState `protogen:"open.v1"` - DmMemberOne *Inbox `protobuf:"bytes,1,opt,name=dm_member_one,json=dmMemberOne,proto3" json:"dm_member_one,omitempty"` - DmMemberTwo *Inbox `protobuf:"bytes,2,opt,name=dm_member_two,json=dmMemberTwo,proto3" json:"dm_member_two,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *DmMembers) Reset() { - *x = DmMembers{} - mi := &file_mls_message_contents_group_metadata_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *DmMembers) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*DmMembers) ProtoMessage() {} - -func (x *DmMembers) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_metadata_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use DmMembers.ProtoReflect.Descriptor instead. -func (*DmMembers) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_metadata_proto_rawDescGZIP(), []int{2} -} - -func (x *DmMembers) GetDmMemberOne() *Inbox { - if x != nil { - return x.DmMemberOne - } - return nil -} - -func (x *DmMembers) GetDmMemberTwo() *Inbox { - if x != nil { - return x.DmMemberTwo - } - return nil -} - -var File_mls_message_contents_group_metadata_proto protoreflect.FileDescriptor - -const file_mls_message_contents_group_metadata_proto_rawDesc = "" + - "\n" + - ")mls/message_contents/group_metadata.proto\x12\x19xmtp.mls.message_contents\x1a\"mls/message_contents/oneshot.proto\"\x93\x03\n" + - "\x0fGroupMetadataV1\x12X\n" + - "\x11conversation_type\x18\x01 \x01(\x0e2+.xmtp.mls.message_contents.ConversationTypeR\x10conversationType\x126\n" + - "\x17creator_account_address\x18\x02 \x01(\tR\x15creatorAccountAddress\x12(\n" + - "\x10creator_inbox_id\x18\x03 \x01(\tR\x0ecreatorInboxId\x12H\n" + - "\n" + - "dm_members\x18\x04 \x01(\v2$.xmtp.mls.message_contents.DmMembersH\x00R\tdmMembers\x88\x01\x01\x12W\n" + - "\x0foneshot_message\x18\x05 \x01(\v2).xmtp.mls.message_contents.OneshotMessageH\x01R\x0eoneshotMessage\x88\x01\x01B\r\n" + - "\v_dm_membersB\x12\n" + - "\x10_oneshot_message\"\"\n" + - "\x05Inbox\x12\x19\n" + - "\binbox_id\x18\x01 \x01(\tR\ainboxId\"\x97\x01\n" + - "\tDmMembers\x12D\n" + - "\rdm_member_one\x18\x01 \x01(\v2 .xmtp.mls.message_contents.InboxR\vdmMemberOne\x12D\n" + - "\rdm_member_two\x18\x02 \x01(\v2 .xmtp.mls.message_contents.InboxR\vdmMemberTwo*\xa7\x01\n" + - "\x10ConversationType\x12!\n" + - "\x1dCONVERSATION_TYPE_UNSPECIFIED\x10\x00\x12\x1b\n" + - "\x17CONVERSATION_TYPE_GROUP\x10\x01\x12\x18\n" + - "\x14CONVERSATION_TYPE_DM\x10\x02\x12\x1a\n" + - "\x16CONVERSATION_TYPE_SYNC\x10\x03\x12\x1d\n" + - "\x19CONVERSATION_TYPE_ONESHOT\x10\x04B\x9e\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x12GroupMetadataProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_group_metadata_proto_rawDescOnce sync.Once - file_mls_message_contents_group_metadata_proto_rawDescData []byte -) - -func file_mls_message_contents_group_metadata_proto_rawDescGZIP() []byte { - file_mls_message_contents_group_metadata_proto_rawDescOnce.Do(func() { - file_mls_message_contents_group_metadata_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_group_metadata_proto_rawDesc), len(file_mls_message_contents_group_metadata_proto_rawDesc))) - }) - return file_mls_message_contents_group_metadata_proto_rawDescData -} - -var file_mls_message_contents_group_metadata_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_mls_message_contents_group_metadata_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_mls_message_contents_group_metadata_proto_goTypes = []any{ - (ConversationType)(0), // 0: xmtp.mls.message_contents.ConversationType - (*GroupMetadataV1)(nil), // 1: xmtp.mls.message_contents.GroupMetadataV1 - (*Inbox)(nil), // 2: xmtp.mls.message_contents.Inbox - (*DmMembers)(nil), // 3: xmtp.mls.message_contents.DmMembers - (*OneshotMessage)(nil), // 4: xmtp.mls.message_contents.OneshotMessage -} -var file_mls_message_contents_group_metadata_proto_depIdxs = []int32{ - 0, // 0: xmtp.mls.message_contents.GroupMetadataV1.conversation_type:type_name -> xmtp.mls.message_contents.ConversationType - 3, // 1: xmtp.mls.message_contents.GroupMetadataV1.dm_members:type_name -> xmtp.mls.message_contents.DmMembers - 4, // 2: xmtp.mls.message_contents.GroupMetadataV1.oneshot_message:type_name -> xmtp.mls.message_contents.OneshotMessage - 2, // 3: xmtp.mls.message_contents.DmMembers.dm_member_one:type_name -> xmtp.mls.message_contents.Inbox - 2, // 4: xmtp.mls.message_contents.DmMembers.dm_member_two:type_name -> xmtp.mls.message_contents.Inbox - 5, // [5:5] is the sub-list for method output_type - 5, // [5:5] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name -} - -func init() { file_mls_message_contents_group_metadata_proto_init() } -func file_mls_message_contents_group_metadata_proto_init() { - if File_mls_message_contents_group_metadata_proto != nil { - return - } - file_mls_message_contents_oneshot_proto_init() - file_mls_message_contents_group_metadata_proto_msgTypes[0].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_group_metadata_proto_rawDesc), len(file_mls_message_contents_group_metadata_proto_rawDesc)), - NumEnums: 1, - NumMessages: 3, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_group_metadata_proto_goTypes, - DependencyIndexes: file_mls_message_contents_group_metadata_proto_depIdxs, - EnumInfos: file_mls_message_contents_group_metadata_proto_enumTypes, - MessageInfos: file_mls_message_contents_group_metadata_proto_msgTypes, - }.Build() - File_mls_message_contents_group_metadata_proto = out.File - file_mls_message_contents_group_metadata_proto_goTypes = nil - file_mls_message_contents_group_metadata_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/group_mutable_metadata.pb.go b/pkg/proto/mls/message_contents/group_mutable_metadata.pb.go deleted file mode 100644 index 9edc93b7..00000000 --- a/pkg/proto/mls/message_contents/group_mutable_metadata.pb.go +++ /dev/null @@ -1,205 +0,0 @@ -// Group mutable metadata - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/group_mutable_metadata.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Message for group mutable metadata -type GroupMutableMetadataV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Map to store various metadata attributes (Group name, etc.) - Attributes map[string]string `protobuf:"bytes,1,rep,name=attributes,proto3" json:"attributes,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - AdminList *Inboxes `protobuf:"bytes,2,opt,name=admin_list,json=adminList,proto3" json:"admin_list,omitempty"` - // Creator starts as only super_admin - // Only super_admin can add/remove other super_admin - SuperAdminList *Inboxes `protobuf:"bytes,3,opt,name=super_admin_list,json=superAdminList,proto3" json:"super_admin_list,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMutableMetadataV1) Reset() { - *x = GroupMutableMetadataV1{} - mi := &file_mls_message_contents_group_mutable_metadata_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMutableMetadataV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMutableMetadataV1) ProtoMessage() {} - -func (x *GroupMutableMetadataV1) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_mutable_metadata_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMutableMetadataV1.ProtoReflect.Descriptor instead. -func (*GroupMutableMetadataV1) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_mutable_metadata_proto_rawDescGZIP(), []int{0} -} - -func (x *GroupMutableMetadataV1) GetAttributes() map[string]string { - if x != nil { - return x.Attributes - } - return nil -} - -func (x *GroupMutableMetadataV1) GetAdminList() *Inboxes { - if x != nil { - return x.AdminList - } - return nil -} - -func (x *GroupMutableMetadataV1) GetSuperAdminList() *Inboxes { - if x != nil { - return x.SuperAdminList - } - return nil -} - -// Wrapper around a list of repeated Inbox Ids -type Inboxes struct { - state protoimpl.MessageState `protogen:"open.v1"` - InboxIds []string `protobuf:"bytes,1,rep,name=inbox_ids,json=inboxIds,proto3" json:"inbox_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Inboxes) Reset() { - *x = Inboxes{} - mi := &file_mls_message_contents_group_mutable_metadata_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Inboxes) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Inboxes) ProtoMessage() {} - -func (x *Inboxes) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_mutable_metadata_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Inboxes.ProtoReflect.Descriptor instead. -func (*Inboxes) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_mutable_metadata_proto_rawDescGZIP(), []int{1} -} - -func (x *Inboxes) GetInboxIds() []string { - if x != nil { - return x.InboxIds - } - return nil -} - -var File_mls_message_contents_group_mutable_metadata_proto protoreflect.FileDescriptor - -const file_mls_message_contents_group_mutable_metadata_proto_rawDesc = "" + - "\n" + - "1mls/message_contents/group_mutable_metadata.proto\x12\x19xmtp.mls.message_contents\"\xe4\x02\n" + - "\x16GroupMutableMetadataV1\x12a\n" + - "\n" + - "attributes\x18\x01 \x03(\v2A.xmtp.mls.message_contents.GroupMutableMetadataV1.AttributesEntryR\n" + - "attributes\x12A\n" + - "\n" + - "admin_list\x18\x02 \x01(\v2\".xmtp.mls.message_contents.InboxesR\tadminList\x12L\n" + - "\x10super_admin_list\x18\x03 \x01(\v2\".xmtp.mls.message_contents.InboxesR\x0esuperAdminList\x1a=\n" + - "\x0fAttributesEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01J\x04\b\x04\x10\x05R\x11commit_log_signer\"&\n" + - "\aInboxes\x12\x1b\n" + - "\tinbox_ids\x18\x01 \x03(\tR\binboxIdsB\xa5\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x19GroupMutableMetadataProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_group_mutable_metadata_proto_rawDescOnce sync.Once - file_mls_message_contents_group_mutable_metadata_proto_rawDescData []byte -) - -func file_mls_message_contents_group_mutable_metadata_proto_rawDescGZIP() []byte { - file_mls_message_contents_group_mutable_metadata_proto_rawDescOnce.Do(func() { - file_mls_message_contents_group_mutable_metadata_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_group_mutable_metadata_proto_rawDesc), len(file_mls_message_contents_group_mutable_metadata_proto_rawDesc))) - }) - return file_mls_message_contents_group_mutable_metadata_proto_rawDescData -} - -var file_mls_message_contents_group_mutable_metadata_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_mls_message_contents_group_mutable_metadata_proto_goTypes = []any{ - (*GroupMutableMetadataV1)(nil), // 0: xmtp.mls.message_contents.GroupMutableMetadataV1 - (*Inboxes)(nil), // 1: xmtp.mls.message_contents.Inboxes - nil, // 2: xmtp.mls.message_contents.GroupMutableMetadataV1.AttributesEntry -} -var file_mls_message_contents_group_mutable_metadata_proto_depIdxs = []int32{ - 2, // 0: xmtp.mls.message_contents.GroupMutableMetadataV1.attributes:type_name -> xmtp.mls.message_contents.GroupMutableMetadataV1.AttributesEntry - 1, // 1: xmtp.mls.message_contents.GroupMutableMetadataV1.admin_list:type_name -> xmtp.mls.message_contents.Inboxes - 1, // 2: xmtp.mls.message_contents.GroupMutableMetadataV1.super_admin_list:type_name -> xmtp.mls.message_contents.Inboxes - 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_mls_message_contents_group_mutable_metadata_proto_init() } -func file_mls_message_contents_group_mutable_metadata_proto_init() { - if File_mls_message_contents_group_mutable_metadata_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_group_mutable_metadata_proto_rawDesc), len(file_mls_message_contents_group_mutable_metadata_proto_rawDesc)), - NumEnums: 0, - NumMessages: 3, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_group_mutable_metadata_proto_goTypes, - DependencyIndexes: file_mls_message_contents_group_mutable_metadata_proto_depIdxs, - MessageInfos: file_mls_message_contents_group_mutable_metadata_proto_msgTypes, - }.Build() - File_mls_message_contents_group_mutable_metadata_proto = out.File - file_mls_message_contents_group_mutable_metadata_proto_goTypes = nil - file_mls_message_contents_group_mutable_metadata_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/group_permissions.pb.go b/pkg/proto/mls/message_contents/group_permissions.pb.go deleted file mode 100644 index 370d0016..00000000 --- a/pkg/proto/mls/message_contents/group_permissions.pb.go +++ /dev/null @@ -1,1052 +0,0 @@ -// Group mutable permissions metadata - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/group_permissions.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Base policy -type MembershipPolicy_BasePolicy int32 - -const ( - MembershipPolicy_BASE_POLICY_UNSPECIFIED MembershipPolicy_BasePolicy = 0 - MembershipPolicy_BASE_POLICY_ALLOW MembershipPolicy_BasePolicy = 1 - MembershipPolicy_BASE_POLICY_DENY MembershipPolicy_BasePolicy = 2 - MembershipPolicy_BASE_POLICY_ALLOW_IF_ADMIN_OR_SUPER_ADMIN MembershipPolicy_BasePolicy = 3 - MembershipPolicy_BASE_POLICY_ALLOW_IF_SUPER_ADMIN MembershipPolicy_BasePolicy = 4 -) - -// Enum value maps for MembershipPolicy_BasePolicy. -var ( - MembershipPolicy_BasePolicy_name = map[int32]string{ - 0: "BASE_POLICY_UNSPECIFIED", - 1: "BASE_POLICY_ALLOW", - 2: "BASE_POLICY_DENY", - 3: "BASE_POLICY_ALLOW_IF_ADMIN_OR_SUPER_ADMIN", - 4: "BASE_POLICY_ALLOW_IF_SUPER_ADMIN", - } - MembershipPolicy_BasePolicy_value = map[string]int32{ - "BASE_POLICY_UNSPECIFIED": 0, - "BASE_POLICY_ALLOW": 1, - "BASE_POLICY_DENY": 2, - "BASE_POLICY_ALLOW_IF_ADMIN_OR_SUPER_ADMIN": 3, - "BASE_POLICY_ALLOW_IF_SUPER_ADMIN": 4, - } -) - -func (x MembershipPolicy_BasePolicy) Enum() *MembershipPolicy_BasePolicy { - p := new(MembershipPolicy_BasePolicy) - *p = x - return p -} - -func (x MembershipPolicy_BasePolicy) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (MembershipPolicy_BasePolicy) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_group_permissions_proto_enumTypes[0].Descriptor() -} - -func (MembershipPolicy_BasePolicy) Type() protoreflect.EnumType { - return &file_mls_message_contents_group_permissions_proto_enumTypes[0] -} - -func (x MembershipPolicy_BasePolicy) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use MembershipPolicy_BasePolicy.Descriptor instead. -func (MembershipPolicy_BasePolicy) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{2, 0} -} - -// Base policy -type MetadataPolicy_MetadataBasePolicy int32 - -const ( - MetadataPolicy_METADATA_BASE_POLICY_UNSPECIFIED MetadataPolicy_MetadataBasePolicy = 0 - MetadataPolicy_METADATA_BASE_POLICY_ALLOW MetadataPolicy_MetadataBasePolicy = 1 - MetadataPolicy_METADATA_BASE_POLICY_DENY MetadataPolicy_MetadataBasePolicy = 2 - MetadataPolicy_METADATA_BASE_POLICY_ALLOW_IF_ADMIN MetadataPolicy_MetadataBasePolicy = 3 - MetadataPolicy_METADATA_BASE_POLICY_ALLOW_IF_SUPER_ADMIN MetadataPolicy_MetadataBasePolicy = 4 -) - -// Enum value maps for MetadataPolicy_MetadataBasePolicy. -var ( - MetadataPolicy_MetadataBasePolicy_name = map[int32]string{ - 0: "METADATA_BASE_POLICY_UNSPECIFIED", - 1: "METADATA_BASE_POLICY_ALLOW", - 2: "METADATA_BASE_POLICY_DENY", - 3: "METADATA_BASE_POLICY_ALLOW_IF_ADMIN", - 4: "METADATA_BASE_POLICY_ALLOW_IF_SUPER_ADMIN", - } - MetadataPolicy_MetadataBasePolicy_value = map[string]int32{ - "METADATA_BASE_POLICY_UNSPECIFIED": 0, - "METADATA_BASE_POLICY_ALLOW": 1, - "METADATA_BASE_POLICY_DENY": 2, - "METADATA_BASE_POLICY_ALLOW_IF_ADMIN": 3, - "METADATA_BASE_POLICY_ALLOW_IF_SUPER_ADMIN": 4, - } -) - -func (x MetadataPolicy_MetadataBasePolicy) Enum() *MetadataPolicy_MetadataBasePolicy { - p := new(MetadataPolicy_MetadataBasePolicy) - *p = x - return p -} - -func (x MetadataPolicy_MetadataBasePolicy) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (MetadataPolicy_MetadataBasePolicy) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_group_permissions_proto_enumTypes[1].Descriptor() -} - -func (MetadataPolicy_MetadataBasePolicy) Type() protoreflect.EnumType { - return &file_mls_message_contents_group_permissions_proto_enumTypes[1] -} - -func (x MetadataPolicy_MetadataBasePolicy) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use MetadataPolicy_MetadataBasePolicy.Descriptor instead. -func (MetadataPolicy_MetadataBasePolicy) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{3, 0} -} - -// Base policy -type PermissionsUpdatePolicy_PermissionsBasePolicy int32 - -const ( - PermissionsUpdatePolicy_PERMISSIONS_BASE_POLICY_UNSPECIFIED PermissionsUpdatePolicy_PermissionsBasePolicy = 0 - PermissionsUpdatePolicy_PERMISSIONS_BASE_POLICY_DENY PermissionsUpdatePolicy_PermissionsBasePolicy = 1 - PermissionsUpdatePolicy_PERMISSIONS_BASE_POLICY_ALLOW_IF_ADMIN PermissionsUpdatePolicy_PermissionsBasePolicy = 2 - PermissionsUpdatePolicy_PERMISSIONS_BASE_POLICY_ALLOW_IF_SUPER_ADMIN PermissionsUpdatePolicy_PermissionsBasePolicy = 3 -) - -// Enum value maps for PermissionsUpdatePolicy_PermissionsBasePolicy. -var ( - PermissionsUpdatePolicy_PermissionsBasePolicy_name = map[int32]string{ - 0: "PERMISSIONS_BASE_POLICY_UNSPECIFIED", - 1: "PERMISSIONS_BASE_POLICY_DENY", - 2: "PERMISSIONS_BASE_POLICY_ALLOW_IF_ADMIN", - 3: "PERMISSIONS_BASE_POLICY_ALLOW_IF_SUPER_ADMIN", - } - PermissionsUpdatePolicy_PermissionsBasePolicy_value = map[string]int32{ - "PERMISSIONS_BASE_POLICY_UNSPECIFIED": 0, - "PERMISSIONS_BASE_POLICY_DENY": 1, - "PERMISSIONS_BASE_POLICY_ALLOW_IF_ADMIN": 2, - "PERMISSIONS_BASE_POLICY_ALLOW_IF_SUPER_ADMIN": 3, - } -) - -func (x PermissionsUpdatePolicy_PermissionsBasePolicy) Enum() *PermissionsUpdatePolicy_PermissionsBasePolicy { - p := new(PermissionsUpdatePolicy_PermissionsBasePolicy) - *p = x - return p -} - -func (x PermissionsUpdatePolicy_PermissionsBasePolicy) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (PermissionsUpdatePolicy_PermissionsBasePolicy) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_group_permissions_proto_enumTypes[2].Descriptor() -} - -func (PermissionsUpdatePolicy_PermissionsBasePolicy) Type() protoreflect.EnumType { - return &file_mls_message_contents_group_permissions_proto_enumTypes[2] -} - -func (x PermissionsUpdatePolicy_PermissionsBasePolicy) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use PermissionsUpdatePolicy_PermissionsBasePolicy.Descriptor instead. -func (PermissionsUpdatePolicy_PermissionsBasePolicy) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{4, 0} -} - -// Message for group mutable metadata -type GroupMutablePermissionsV1 struct { - state protoimpl.MessageState `protogen:"open.v1"` - Policies *PolicySet `protobuf:"bytes,1,opt,name=policies,proto3" json:"policies,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMutablePermissionsV1) Reset() { - *x = GroupMutablePermissionsV1{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMutablePermissionsV1) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMutablePermissionsV1) ProtoMessage() {} - -func (x *GroupMutablePermissionsV1) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMutablePermissionsV1.ProtoReflect.Descriptor instead. -func (*GroupMutablePermissionsV1) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{0} -} - -func (x *GroupMutablePermissionsV1) GetPolicies() *PolicySet { - if x != nil { - return x.Policies - } - return nil -} - -// The set of policies that govern the group -type PolicySet struct { - state protoimpl.MessageState `protogen:"open.v1"` - AddMemberPolicy *MembershipPolicy `protobuf:"bytes,1,opt,name=add_member_policy,json=addMemberPolicy,proto3" json:"add_member_policy,omitempty"` - RemoveMemberPolicy *MembershipPolicy `protobuf:"bytes,2,opt,name=remove_member_policy,json=removeMemberPolicy,proto3" json:"remove_member_policy,omitempty"` - UpdateMetadataPolicy map[string]*MetadataPolicy `protobuf:"bytes,3,rep,name=update_metadata_policy,json=updateMetadataPolicy,proto3" json:"update_metadata_policy,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - AddAdminPolicy *PermissionsUpdatePolicy `protobuf:"bytes,4,opt,name=add_admin_policy,json=addAdminPolicy,proto3" json:"add_admin_policy,omitempty"` - RemoveAdminPolicy *PermissionsUpdatePolicy `protobuf:"bytes,5,opt,name=remove_admin_policy,json=removeAdminPolicy,proto3" json:"remove_admin_policy,omitempty"` - UpdatePermissionsPolicy *PermissionsUpdatePolicy `protobuf:"bytes,6,opt,name=update_permissions_policy,json=updatePermissionsPolicy,proto3" json:"update_permissions_policy,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PolicySet) Reset() { - *x = PolicySet{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PolicySet) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PolicySet) ProtoMessage() {} - -func (x *PolicySet) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PolicySet.ProtoReflect.Descriptor instead. -func (*PolicySet) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{1} -} - -func (x *PolicySet) GetAddMemberPolicy() *MembershipPolicy { - if x != nil { - return x.AddMemberPolicy - } - return nil -} - -func (x *PolicySet) GetRemoveMemberPolicy() *MembershipPolicy { - if x != nil { - return x.RemoveMemberPolicy - } - return nil -} - -func (x *PolicySet) GetUpdateMetadataPolicy() map[string]*MetadataPolicy { - if x != nil { - return x.UpdateMetadataPolicy - } - return nil -} - -func (x *PolicySet) GetAddAdminPolicy() *PermissionsUpdatePolicy { - if x != nil { - return x.AddAdminPolicy - } - return nil -} - -func (x *PolicySet) GetRemoveAdminPolicy() *PermissionsUpdatePolicy { - if x != nil { - return x.RemoveAdminPolicy - } - return nil -} - -func (x *PolicySet) GetUpdatePermissionsPolicy() *PermissionsUpdatePolicy { - if x != nil { - return x.UpdatePermissionsPolicy - } - return nil -} - -// A policy that governs adding/removing members or installations -type MembershipPolicy struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Kind: - // - // *MembershipPolicy_Base - // *MembershipPolicy_AndCondition_ - // *MembershipPolicy_AnyCondition_ - Kind isMembershipPolicy_Kind `protobuf_oneof:"kind"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MembershipPolicy) Reset() { - *x = MembershipPolicy{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MembershipPolicy) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MembershipPolicy) ProtoMessage() {} - -func (x *MembershipPolicy) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MembershipPolicy.ProtoReflect.Descriptor instead. -func (*MembershipPolicy) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{2} -} - -func (x *MembershipPolicy) GetKind() isMembershipPolicy_Kind { - if x != nil { - return x.Kind - } - return nil -} - -func (x *MembershipPolicy) GetBase() MembershipPolicy_BasePolicy { - if x != nil { - if x, ok := x.Kind.(*MembershipPolicy_Base); ok { - return x.Base - } - } - return MembershipPolicy_BASE_POLICY_UNSPECIFIED -} - -func (x *MembershipPolicy) GetAndCondition() *MembershipPolicy_AndCondition { - if x != nil { - if x, ok := x.Kind.(*MembershipPolicy_AndCondition_); ok { - return x.AndCondition - } - } - return nil -} - -func (x *MembershipPolicy) GetAnyCondition() *MembershipPolicy_AnyCondition { - if x != nil { - if x, ok := x.Kind.(*MembershipPolicy_AnyCondition_); ok { - return x.AnyCondition - } - } - return nil -} - -type isMembershipPolicy_Kind interface { - isMembershipPolicy_Kind() -} - -type MembershipPolicy_Base struct { - Base MembershipPolicy_BasePolicy `protobuf:"varint,1,opt,name=base,proto3,enum=xmtp.mls.message_contents.MembershipPolicy_BasePolicy,oneof"` -} - -type MembershipPolicy_AndCondition_ struct { - AndCondition *MembershipPolicy_AndCondition `protobuf:"bytes,2,opt,name=and_condition,json=andCondition,proto3,oneof"` -} - -type MembershipPolicy_AnyCondition_ struct { - AnyCondition *MembershipPolicy_AnyCondition `protobuf:"bytes,3,opt,name=any_condition,json=anyCondition,proto3,oneof"` -} - -func (*MembershipPolicy_Base) isMembershipPolicy_Kind() {} - -func (*MembershipPolicy_AndCondition_) isMembershipPolicy_Kind() {} - -func (*MembershipPolicy_AnyCondition_) isMembershipPolicy_Kind() {} - -// A policy that governs updating metadata -type MetadataPolicy struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Kind: - // - // *MetadataPolicy_Base - // *MetadataPolicy_AndCondition_ - // *MetadataPolicy_AnyCondition_ - Kind isMetadataPolicy_Kind `protobuf_oneof:"kind"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MetadataPolicy) Reset() { - *x = MetadataPolicy{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MetadataPolicy) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MetadataPolicy) ProtoMessage() {} - -func (x *MetadataPolicy) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MetadataPolicy.ProtoReflect.Descriptor instead. -func (*MetadataPolicy) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{3} -} - -func (x *MetadataPolicy) GetKind() isMetadataPolicy_Kind { - if x != nil { - return x.Kind - } - return nil -} - -func (x *MetadataPolicy) GetBase() MetadataPolicy_MetadataBasePolicy { - if x != nil { - if x, ok := x.Kind.(*MetadataPolicy_Base); ok { - return x.Base - } - } - return MetadataPolicy_METADATA_BASE_POLICY_UNSPECIFIED -} - -func (x *MetadataPolicy) GetAndCondition() *MetadataPolicy_AndCondition { - if x != nil { - if x, ok := x.Kind.(*MetadataPolicy_AndCondition_); ok { - return x.AndCondition - } - } - return nil -} - -func (x *MetadataPolicy) GetAnyCondition() *MetadataPolicy_AnyCondition { - if x != nil { - if x, ok := x.Kind.(*MetadataPolicy_AnyCondition_); ok { - return x.AnyCondition - } - } - return nil -} - -type isMetadataPolicy_Kind interface { - isMetadataPolicy_Kind() -} - -type MetadataPolicy_Base struct { - Base MetadataPolicy_MetadataBasePolicy `protobuf:"varint,1,opt,name=base,proto3,enum=xmtp.mls.message_contents.MetadataPolicy_MetadataBasePolicy,oneof"` -} - -type MetadataPolicy_AndCondition_ struct { - AndCondition *MetadataPolicy_AndCondition `protobuf:"bytes,2,opt,name=and_condition,json=andCondition,proto3,oneof"` -} - -type MetadataPolicy_AnyCondition_ struct { - AnyCondition *MetadataPolicy_AnyCondition `protobuf:"bytes,3,opt,name=any_condition,json=anyCondition,proto3,oneof"` -} - -func (*MetadataPolicy_Base) isMetadataPolicy_Kind() {} - -func (*MetadataPolicy_AndCondition_) isMetadataPolicy_Kind() {} - -func (*MetadataPolicy_AnyCondition_) isMetadataPolicy_Kind() {} - -// A policy that governs updating permissions -type PermissionsUpdatePolicy struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Kind: - // - // *PermissionsUpdatePolicy_Base - // *PermissionsUpdatePolicy_AndCondition_ - // *PermissionsUpdatePolicy_AnyCondition_ - Kind isPermissionsUpdatePolicy_Kind `protobuf_oneof:"kind"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PermissionsUpdatePolicy) Reset() { - *x = PermissionsUpdatePolicy{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PermissionsUpdatePolicy) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PermissionsUpdatePolicy) ProtoMessage() {} - -func (x *PermissionsUpdatePolicy) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PermissionsUpdatePolicy.ProtoReflect.Descriptor instead. -func (*PermissionsUpdatePolicy) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{4} -} - -func (x *PermissionsUpdatePolicy) GetKind() isPermissionsUpdatePolicy_Kind { - if x != nil { - return x.Kind - } - return nil -} - -func (x *PermissionsUpdatePolicy) GetBase() PermissionsUpdatePolicy_PermissionsBasePolicy { - if x != nil { - if x, ok := x.Kind.(*PermissionsUpdatePolicy_Base); ok { - return x.Base - } - } - return PermissionsUpdatePolicy_PERMISSIONS_BASE_POLICY_UNSPECIFIED -} - -func (x *PermissionsUpdatePolicy) GetAndCondition() *PermissionsUpdatePolicy_AndCondition { - if x != nil { - if x, ok := x.Kind.(*PermissionsUpdatePolicy_AndCondition_); ok { - return x.AndCondition - } - } - return nil -} - -func (x *PermissionsUpdatePolicy) GetAnyCondition() *PermissionsUpdatePolicy_AnyCondition { - if x != nil { - if x, ok := x.Kind.(*PermissionsUpdatePolicy_AnyCondition_); ok { - return x.AnyCondition - } - } - return nil -} - -type isPermissionsUpdatePolicy_Kind interface { - isPermissionsUpdatePolicy_Kind() -} - -type PermissionsUpdatePolicy_Base struct { - Base PermissionsUpdatePolicy_PermissionsBasePolicy `protobuf:"varint,1,opt,name=base,proto3,enum=xmtp.mls.message_contents.PermissionsUpdatePolicy_PermissionsBasePolicy,oneof"` -} - -type PermissionsUpdatePolicy_AndCondition_ struct { - AndCondition *PermissionsUpdatePolicy_AndCondition `protobuf:"bytes,2,opt,name=and_condition,json=andCondition,proto3,oneof"` -} - -type PermissionsUpdatePolicy_AnyCondition_ struct { - AnyCondition *PermissionsUpdatePolicy_AnyCondition `protobuf:"bytes,3,opt,name=any_condition,json=anyCondition,proto3,oneof"` -} - -func (*PermissionsUpdatePolicy_Base) isPermissionsUpdatePolicy_Kind() {} - -func (*PermissionsUpdatePolicy_AndCondition_) isPermissionsUpdatePolicy_Kind() {} - -func (*PermissionsUpdatePolicy_AnyCondition_) isPermissionsUpdatePolicy_Kind() {} - -// Combine multiple policies. All must evaluate to true -type MembershipPolicy_AndCondition struct { - state protoimpl.MessageState `protogen:"open.v1"` - Policies []*MembershipPolicy `protobuf:"bytes,1,rep,name=policies,proto3" json:"policies,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MembershipPolicy_AndCondition) Reset() { - *x = MembershipPolicy_AndCondition{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MembershipPolicy_AndCondition) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MembershipPolicy_AndCondition) ProtoMessage() {} - -func (x *MembershipPolicy_AndCondition) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MembershipPolicy_AndCondition.ProtoReflect.Descriptor instead. -func (*MembershipPolicy_AndCondition) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{2, 0} -} - -func (x *MembershipPolicy_AndCondition) GetPolicies() []*MembershipPolicy { - if x != nil { - return x.Policies - } - return nil -} - -// Combine multiple policies. Any must evaluate to true -type MembershipPolicy_AnyCondition struct { - state protoimpl.MessageState `protogen:"open.v1"` - Policies []*MembershipPolicy `protobuf:"bytes,1,rep,name=policies,proto3" json:"policies,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MembershipPolicy_AnyCondition) Reset() { - *x = MembershipPolicy_AnyCondition{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MembershipPolicy_AnyCondition) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MembershipPolicy_AnyCondition) ProtoMessage() {} - -func (x *MembershipPolicy_AnyCondition) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MembershipPolicy_AnyCondition.ProtoReflect.Descriptor instead. -func (*MembershipPolicy_AnyCondition) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{2, 1} -} - -func (x *MembershipPolicy_AnyCondition) GetPolicies() []*MembershipPolicy { - if x != nil { - return x.Policies - } - return nil -} - -// Combine multiple policies. All must evaluate to true -type MetadataPolicy_AndCondition struct { - state protoimpl.MessageState `protogen:"open.v1"` - Policies []*MetadataPolicy `protobuf:"bytes,1,rep,name=policies,proto3" json:"policies,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MetadataPolicy_AndCondition) Reset() { - *x = MetadataPolicy_AndCondition{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MetadataPolicy_AndCondition) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MetadataPolicy_AndCondition) ProtoMessage() {} - -func (x *MetadataPolicy_AndCondition) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MetadataPolicy_AndCondition.ProtoReflect.Descriptor instead. -func (*MetadataPolicy_AndCondition) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{3, 0} -} - -func (x *MetadataPolicy_AndCondition) GetPolicies() []*MetadataPolicy { - if x != nil { - return x.Policies - } - return nil -} - -// Combine multiple policies. Any must evaluate to true -type MetadataPolicy_AnyCondition struct { - state protoimpl.MessageState `protogen:"open.v1"` - Policies []*MetadataPolicy `protobuf:"bytes,1,rep,name=policies,proto3" json:"policies,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MetadataPolicy_AnyCondition) Reset() { - *x = MetadataPolicy_AnyCondition{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MetadataPolicy_AnyCondition) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MetadataPolicy_AnyCondition) ProtoMessage() {} - -func (x *MetadataPolicy_AnyCondition) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MetadataPolicy_AnyCondition.ProtoReflect.Descriptor instead. -func (*MetadataPolicy_AnyCondition) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{3, 1} -} - -func (x *MetadataPolicy_AnyCondition) GetPolicies() []*MetadataPolicy { - if x != nil { - return x.Policies - } - return nil -} - -// Combine multiple policies. All must evaluate to true -type PermissionsUpdatePolicy_AndCondition struct { - state protoimpl.MessageState `protogen:"open.v1"` - Policies []*PermissionsUpdatePolicy `protobuf:"bytes,1,rep,name=policies,proto3" json:"policies,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PermissionsUpdatePolicy_AndCondition) Reset() { - *x = PermissionsUpdatePolicy_AndCondition{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PermissionsUpdatePolicy_AndCondition) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PermissionsUpdatePolicy_AndCondition) ProtoMessage() {} - -func (x *PermissionsUpdatePolicy_AndCondition) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PermissionsUpdatePolicy_AndCondition.ProtoReflect.Descriptor instead. -func (*PermissionsUpdatePolicy_AndCondition) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{4, 0} -} - -func (x *PermissionsUpdatePolicy_AndCondition) GetPolicies() []*PermissionsUpdatePolicy { - if x != nil { - return x.Policies - } - return nil -} - -// Combine multiple policies. Any must evaluate to true -type PermissionsUpdatePolicy_AnyCondition struct { - state protoimpl.MessageState `protogen:"open.v1"` - Policies []*PermissionsUpdatePolicy `protobuf:"bytes,1,rep,name=policies,proto3" json:"policies,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PermissionsUpdatePolicy_AnyCondition) Reset() { - *x = PermissionsUpdatePolicy_AnyCondition{} - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PermissionsUpdatePolicy_AnyCondition) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PermissionsUpdatePolicy_AnyCondition) ProtoMessage() {} - -func (x *PermissionsUpdatePolicy_AnyCondition) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_group_permissions_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PermissionsUpdatePolicy_AnyCondition.ProtoReflect.Descriptor instead. -func (*PermissionsUpdatePolicy_AnyCondition) Descriptor() ([]byte, []int) { - return file_mls_message_contents_group_permissions_proto_rawDescGZIP(), []int{4, 1} -} - -func (x *PermissionsUpdatePolicy_AnyCondition) GetPolicies() []*PermissionsUpdatePolicy { - if x != nil { - return x.Policies - } - return nil -} - -var File_mls_message_contents_group_permissions_proto protoreflect.FileDescriptor - -const file_mls_message_contents_group_permissions_proto_rawDesc = "" + - "\n" + - ",mls/message_contents/group_permissions.proto\x12\x19xmtp.mls.message_contents\"]\n" + - "\x19GroupMutablePermissionsV1\x12@\n" + - "\bpolicies\x18\x01 \x01(\v2$.xmtp.mls.message_contents.PolicySetR\bpolicies\"\xdf\x05\n" + - "\tPolicySet\x12W\n" + - "\x11add_member_policy\x18\x01 \x01(\v2+.xmtp.mls.message_contents.MembershipPolicyR\x0faddMemberPolicy\x12]\n" + - "\x14remove_member_policy\x18\x02 \x01(\v2+.xmtp.mls.message_contents.MembershipPolicyR\x12removeMemberPolicy\x12t\n" + - "\x16update_metadata_policy\x18\x03 \x03(\v2>.xmtp.mls.message_contents.PolicySet.UpdateMetadataPolicyEntryR\x14updateMetadataPolicy\x12\\\n" + - "\x10add_admin_policy\x18\x04 \x01(\v22.xmtp.mls.message_contents.PermissionsUpdatePolicyR\x0eaddAdminPolicy\x12b\n" + - "\x13remove_admin_policy\x18\x05 \x01(\v22.xmtp.mls.message_contents.PermissionsUpdatePolicyR\x11removeAdminPolicy\x12n\n" + - "\x19update_permissions_policy\x18\x06 \x01(\v22.xmtp.mls.message_contents.PermissionsUpdatePolicyR\x17updatePermissionsPolicy\x1ar\n" + - "\x19UpdateMetadataPolicyEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12?\n" + - "\x05value\x18\x02 \x01(\v2).xmtp.mls.message_contents.MetadataPolicyR\x05value:\x028\x01\"\x8a\x05\n" + - "\x10MembershipPolicy\x12L\n" + - "\x04base\x18\x01 \x01(\x0e26.xmtp.mls.message_contents.MembershipPolicy.BasePolicyH\x00R\x04base\x12_\n" + - "\rand_condition\x18\x02 \x01(\v28.xmtp.mls.message_contents.MembershipPolicy.AndConditionH\x00R\fandCondition\x12_\n" + - "\rany_condition\x18\x03 \x01(\v28.xmtp.mls.message_contents.MembershipPolicy.AnyConditionH\x00R\fanyCondition\x1aW\n" + - "\fAndCondition\x12G\n" + - "\bpolicies\x18\x01 \x03(\v2+.xmtp.mls.message_contents.MembershipPolicyR\bpolicies\x1aW\n" + - "\fAnyCondition\x12G\n" + - "\bpolicies\x18\x01 \x03(\v2+.xmtp.mls.message_contents.MembershipPolicyR\bpolicies\"\xab\x01\n" + - "\n" + - "BasePolicy\x12\x1b\n" + - "\x17BASE_POLICY_UNSPECIFIED\x10\x00\x12\x15\n" + - "\x11BASE_POLICY_ALLOW\x10\x01\x12\x14\n" + - "\x10BASE_POLICY_DENY\x10\x02\x12-\n" + - ")BASE_POLICY_ALLOW_IF_ADMIN_OR_SUPER_ADMIN\x10\x03\x12$\n" + - " BASE_POLICY_ALLOW_IF_SUPER_ADMIN\x10\x04B\x06\n" + - "\x04kind\"\xac\x05\n" + - "\x0eMetadataPolicy\x12R\n" + - "\x04base\x18\x01 \x01(\x0e2<.xmtp.mls.message_contents.MetadataPolicy.MetadataBasePolicyH\x00R\x04base\x12]\n" + - "\rand_condition\x18\x02 \x01(\v26.xmtp.mls.message_contents.MetadataPolicy.AndConditionH\x00R\fandCondition\x12]\n" + - "\rany_condition\x18\x03 \x01(\v26.xmtp.mls.message_contents.MetadataPolicy.AnyConditionH\x00R\fanyCondition\x1aU\n" + - "\fAndCondition\x12E\n" + - "\bpolicies\x18\x01 \x03(\v2).xmtp.mls.message_contents.MetadataPolicyR\bpolicies\x1aU\n" + - "\fAnyCondition\x12E\n" + - "\bpolicies\x18\x01 \x03(\v2).xmtp.mls.message_contents.MetadataPolicyR\bpolicies\"\xd1\x01\n" + - "\x12MetadataBasePolicy\x12$\n" + - " METADATA_BASE_POLICY_UNSPECIFIED\x10\x00\x12\x1e\n" + - "\x1aMETADATA_BASE_POLICY_ALLOW\x10\x01\x12\x1d\n" + - "\x19METADATA_BASE_POLICY_DENY\x10\x02\x12'\n" + - "#METADATA_BASE_POLICY_ALLOW_IF_ADMIN\x10\x03\x12-\n" + - ")METADATA_BASE_POLICY_ALLOW_IF_SUPER_ADMIN\x10\x04B\x06\n" + - "\x04kind\"\xd4\x05\n" + - "\x17PermissionsUpdatePolicy\x12^\n" + - "\x04base\x18\x01 \x01(\x0e2H.xmtp.mls.message_contents.PermissionsUpdatePolicy.PermissionsBasePolicyH\x00R\x04base\x12f\n" + - "\rand_condition\x18\x02 \x01(\v2?.xmtp.mls.message_contents.PermissionsUpdatePolicy.AndConditionH\x00R\fandCondition\x12f\n" + - "\rany_condition\x18\x03 \x01(\v2?.xmtp.mls.message_contents.PermissionsUpdatePolicy.AnyConditionH\x00R\fanyCondition\x1a^\n" + - "\fAndCondition\x12N\n" + - "\bpolicies\x18\x01 \x03(\v22.xmtp.mls.message_contents.PermissionsUpdatePolicyR\bpolicies\x1a^\n" + - "\fAnyCondition\x12N\n" + - "\bpolicies\x18\x01 \x03(\v22.xmtp.mls.message_contents.PermissionsUpdatePolicyR\bpolicies\"\xc0\x01\n" + - "\x15PermissionsBasePolicy\x12'\n" + - "#PERMISSIONS_BASE_POLICY_UNSPECIFIED\x10\x00\x12 \n" + - "\x1cPERMISSIONS_BASE_POLICY_DENY\x10\x01\x12*\n" + - "&PERMISSIONS_BASE_POLICY_ALLOW_IF_ADMIN\x10\x02\x120\n" + - ",PERMISSIONS_BASE_POLICY_ALLOW_IF_SUPER_ADMIN\x10\x03B\x06\n" + - "\x04kindB\xa1\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x15GroupPermissionsProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_group_permissions_proto_rawDescOnce sync.Once - file_mls_message_contents_group_permissions_proto_rawDescData []byte -) - -func file_mls_message_contents_group_permissions_proto_rawDescGZIP() []byte { - file_mls_message_contents_group_permissions_proto_rawDescOnce.Do(func() { - file_mls_message_contents_group_permissions_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_group_permissions_proto_rawDesc), len(file_mls_message_contents_group_permissions_proto_rawDesc))) - }) - return file_mls_message_contents_group_permissions_proto_rawDescData -} - -var file_mls_message_contents_group_permissions_proto_enumTypes = make([]protoimpl.EnumInfo, 3) -var file_mls_message_contents_group_permissions_proto_msgTypes = make([]protoimpl.MessageInfo, 12) -var file_mls_message_contents_group_permissions_proto_goTypes = []any{ - (MembershipPolicy_BasePolicy)(0), // 0: xmtp.mls.message_contents.MembershipPolicy.BasePolicy - (MetadataPolicy_MetadataBasePolicy)(0), // 1: xmtp.mls.message_contents.MetadataPolicy.MetadataBasePolicy - (PermissionsUpdatePolicy_PermissionsBasePolicy)(0), // 2: xmtp.mls.message_contents.PermissionsUpdatePolicy.PermissionsBasePolicy - (*GroupMutablePermissionsV1)(nil), // 3: xmtp.mls.message_contents.GroupMutablePermissionsV1 - (*PolicySet)(nil), // 4: xmtp.mls.message_contents.PolicySet - (*MembershipPolicy)(nil), // 5: xmtp.mls.message_contents.MembershipPolicy - (*MetadataPolicy)(nil), // 6: xmtp.mls.message_contents.MetadataPolicy - (*PermissionsUpdatePolicy)(nil), // 7: xmtp.mls.message_contents.PermissionsUpdatePolicy - nil, // 8: xmtp.mls.message_contents.PolicySet.UpdateMetadataPolicyEntry - (*MembershipPolicy_AndCondition)(nil), // 9: xmtp.mls.message_contents.MembershipPolicy.AndCondition - (*MembershipPolicy_AnyCondition)(nil), // 10: xmtp.mls.message_contents.MembershipPolicy.AnyCondition - (*MetadataPolicy_AndCondition)(nil), // 11: xmtp.mls.message_contents.MetadataPolicy.AndCondition - (*MetadataPolicy_AnyCondition)(nil), // 12: xmtp.mls.message_contents.MetadataPolicy.AnyCondition - (*PermissionsUpdatePolicy_AndCondition)(nil), // 13: xmtp.mls.message_contents.PermissionsUpdatePolicy.AndCondition - (*PermissionsUpdatePolicy_AnyCondition)(nil), // 14: xmtp.mls.message_contents.PermissionsUpdatePolicy.AnyCondition -} -var file_mls_message_contents_group_permissions_proto_depIdxs = []int32{ - 4, // 0: xmtp.mls.message_contents.GroupMutablePermissionsV1.policies:type_name -> xmtp.mls.message_contents.PolicySet - 5, // 1: xmtp.mls.message_contents.PolicySet.add_member_policy:type_name -> xmtp.mls.message_contents.MembershipPolicy - 5, // 2: xmtp.mls.message_contents.PolicySet.remove_member_policy:type_name -> xmtp.mls.message_contents.MembershipPolicy - 8, // 3: xmtp.mls.message_contents.PolicySet.update_metadata_policy:type_name -> xmtp.mls.message_contents.PolicySet.UpdateMetadataPolicyEntry - 7, // 4: xmtp.mls.message_contents.PolicySet.add_admin_policy:type_name -> xmtp.mls.message_contents.PermissionsUpdatePolicy - 7, // 5: xmtp.mls.message_contents.PolicySet.remove_admin_policy:type_name -> xmtp.mls.message_contents.PermissionsUpdatePolicy - 7, // 6: xmtp.mls.message_contents.PolicySet.update_permissions_policy:type_name -> xmtp.mls.message_contents.PermissionsUpdatePolicy - 0, // 7: xmtp.mls.message_contents.MembershipPolicy.base:type_name -> xmtp.mls.message_contents.MembershipPolicy.BasePolicy - 9, // 8: xmtp.mls.message_contents.MembershipPolicy.and_condition:type_name -> xmtp.mls.message_contents.MembershipPolicy.AndCondition - 10, // 9: xmtp.mls.message_contents.MembershipPolicy.any_condition:type_name -> xmtp.mls.message_contents.MembershipPolicy.AnyCondition - 1, // 10: xmtp.mls.message_contents.MetadataPolicy.base:type_name -> xmtp.mls.message_contents.MetadataPolicy.MetadataBasePolicy - 11, // 11: xmtp.mls.message_contents.MetadataPolicy.and_condition:type_name -> xmtp.mls.message_contents.MetadataPolicy.AndCondition - 12, // 12: xmtp.mls.message_contents.MetadataPolicy.any_condition:type_name -> xmtp.mls.message_contents.MetadataPolicy.AnyCondition - 2, // 13: xmtp.mls.message_contents.PermissionsUpdatePolicy.base:type_name -> xmtp.mls.message_contents.PermissionsUpdatePolicy.PermissionsBasePolicy - 13, // 14: xmtp.mls.message_contents.PermissionsUpdatePolicy.and_condition:type_name -> xmtp.mls.message_contents.PermissionsUpdatePolicy.AndCondition - 14, // 15: xmtp.mls.message_contents.PermissionsUpdatePolicy.any_condition:type_name -> xmtp.mls.message_contents.PermissionsUpdatePolicy.AnyCondition - 6, // 16: xmtp.mls.message_contents.PolicySet.UpdateMetadataPolicyEntry.value:type_name -> xmtp.mls.message_contents.MetadataPolicy - 5, // 17: xmtp.mls.message_contents.MembershipPolicy.AndCondition.policies:type_name -> xmtp.mls.message_contents.MembershipPolicy - 5, // 18: xmtp.mls.message_contents.MembershipPolicy.AnyCondition.policies:type_name -> xmtp.mls.message_contents.MembershipPolicy - 6, // 19: xmtp.mls.message_contents.MetadataPolicy.AndCondition.policies:type_name -> xmtp.mls.message_contents.MetadataPolicy - 6, // 20: xmtp.mls.message_contents.MetadataPolicy.AnyCondition.policies:type_name -> xmtp.mls.message_contents.MetadataPolicy - 7, // 21: xmtp.mls.message_contents.PermissionsUpdatePolicy.AndCondition.policies:type_name -> xmtp.mls.message_contents.PermissionsUpdatePolicy - 7, // 22: xmtp.mls.message_contents.PermissionsUpdatePolicy.AnyCondition.policies:type_name -> xmtp.mls.message_contents.PermissionsUpdatePolicy - 23, // [23:23] is the sub-list for method output_type - 23, // [23:23] is the sub-list for method input_type - 23, // [23:23] is the sub-list for extension type_name - 23, // [23:23] is the sub-list for extension extendee - 0, // [0:23] is the sub-list for field type_name -} - -func init() { file_mls_message_contents_group_permissions_proto_init() } -func file_mls_message_contents_group_permissions_proto_init() { - if File_mls_message_contents_group_permissions_proto != nil { - return - } - file_mls_message_contents_group_permissions_proto_msgTypes[2].OneofWrappers = []any{ - (*MembershipPolicy_Base)(nil), - (*MembershipPolicy_AndCondition_)(nil), - (*MembershipPolicy_AnyCondition_)(nil), - } - file_mls_message_contents_group_permissions_proto_msgTypes[3].OneofWrappers = []any{ - (*MetadataPolicy_Base)(nil), - (*MetadataPolicy_AndCondition_)(nil), - (*MetadataPolicy_AnyCondition_)(nil), - } - file_mls_message_contents_group_permissions_proto_msgTypes[4].OneofWrappers = []any{ - (*PermissionsUpdatePolicy_Base)(nil), - (*PermissionsUpdatePolicy_AndCondition_)(nil), - (*PermissionsUpdatePolicy_AnyCondition_)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_group_permissions_proto_rawDesc), len(file_mls_message_contents_group_permissions_proto_rawDesc)), - NumEnums: 3, - NumMessages: 12, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_group_permissions_proto_goTypes, - DependencyIndexes: file_mls_message_contents_group_permissions_proto_depIdxs, - EnumInfos: file_mls_message_contents_group_permissions_proto_enumTypes, - MessageInfos: file_mls_message_contents_group_permissions_proto_msgTypes, - }.Build() - File_mls_message_contents_group_permissions_proto = out.File - file_mls_message_contents_group_permissions_proto_goTypes = nil - file_mls_message_contents_group_permissions_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/oneshot.pb.go b/pkg/proto/mls/message_contents/oneshot.pb.go deleted file mode 100644 index e29827f3..00000000 --- a/pkg/proto/mls/message_contents/oneshot.pb.go +++ /dev/null @@ -1,215 +0,0 @@ -// Out-of-band signaling payloads that are sent between devices on -// side channels outside of the main group. - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/oneshot.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type OneshotMessage struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to MessageType: - // - // *OneshotMessage_ReaddRequest - MessageType isOneshotMessage_MessageType `protobuf_oneof:"message_type"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *OneshotMessage) Reset() { - *x = OneshotMessage{} - mi := &file_mls_message_contents_oneshot_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *OneshotMessage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*OneshotMessage) ProtoMessage() {} - -func (x *OneshotMessage) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_oneshot_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use OneshotMessage.ProtoReflect.Descriptor instead. -func (*OneshotMessage) Descriptor() ([]byte, []int) { - return file_mls_message_contents_oneshot_proto_rawDescGZIP(), []int{0} -} - -func (x *OneshotMessage) GetMessageType() isOneshotMessage_MessageType { - if x != nil { - return x.MessageType - } - return nil -} - -func (x *OneshotMessage) GetReaddRequest() *ReaddRequest { - if x != nil { - if x, ok := x.MessageType.(*OneshotMessage_ReaddRequest); ok { - return x.ReaddRequest - } - } - return nil -} - -type isOneshotMessage_MessageType interface { - isOneshotMessage_MessageType() -} - -type OneshotMessage_ReaddRequest struct { - ReaddRequest *ReaddRequest `protobuf:"bytes,1,opt,name=readd_request,json=readdRequest,proto3,oneof"` -} - -func (*OneshotMessage_ReaddRequest) isOneshotMessage_MessageType() {} - -// A request sent by an installation to recover from a fork. Other members -// may remove and readd that installation from the group. -// XIP: https://community.xmtp.org/t/xip-68-draft-automated-fork-recovery/951 -type ReaddRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupId []byte `protobuf:"bytes,1,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - // The sequence ID of the latest commit log entry at the time the request - // is sent; used to disambiguate cases where an installation forks - // and is readded multiple times. - LatestCommitSequenceId uint64 `protobuf:"varint,2,opt,name=latest_commit_sequence_id,json=latestCommitSequenceId,proto3" json:"latest_commit_sequence_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ReaddRequest) Reset() { - *x = ReaddRequest{} - mi := &file_mls_message_contents_oneshot_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ReaddRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ReaddRequest) ProtoMessage() {} - -func (x *ReaddRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_oneshot_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ReaddRequest.ProtoReflect.Descriptor instead. -func (*ReaddRequest) Descriptor() ([]byte, []int) { - return file_mls_message_contents_oneshot_proto_rawDescGZIP(), []int{1} -} - -func (x *ReaddRequest) GetGroupId() []byte { - if x != nil { - return x.GroupId - } - return nil -} - -func (x *ReaddRequest) GetLatestCommitSequenceId() uint64 { - if x != nil { - return x.LatestCommitSequenceId - } - return 0 -} - -var File_mls_message_contents_oneshot_proto protoreflect.FileDescriptor - -const file_mls_message_contents_oneshot_proto_rawDesc = "" + - "\n" + - "\"mls/message_contents/oneshot.proto\x12\x19xmtp.mls.message_contents\"p\n" + - "\x0eOneshotMessage\x12N\n" + - "\rreadd_request\x18\x01 \x01(\v2'.xmtp.mls.message_contents.ReaddRequestH\x00R\freaddRequestB\x0e\n" + - "\fmessage_type\"d\n" + - "\fReaddRequest\x12\x19\n" + - "\bgroup_id\x18\x01 \x01(\fR\agroupId\x129\n" + - "\x19latest_commit_sequence_id\x18\x02 \x01(\x04R\x16latestCommitSequenceIdB\x98\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\fOneshotProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_oneshot_proto_rawDescOnce sync.Once - file_mls_message_contents_oneshot_proto_rawDescData []byte -) - -func file_mls_message_contents_oneshot_proto_rawDescGZIP() []byte { - file_mls_message_contents_oneshot_proto_rawDescOnce.Do(func() { - file_mls_message_contents_oneshot_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_oneshot_proto_rawDesc), len(file_mls_message_contents_oneshot_proto_rawDesc))) - }) - return file_mls_message_contents_oneshot_proto_rawDescData -} - -var file_mls_message_contents_oneshot_proto_msgTypes = make([]protoimpl.MessageInfo, 2) -var file_mls_message_contents_oneshot_proto_goTypes = []any{ - (*OneshotMessage)(nil), // 0: xmtp.mls.message_contents.OneshotMessage - (*ReaddRequest)(nil), // 1: xmtp.mls.message_contents.ReaddRequest -} -var file_mls_message_contents_oneshot_proto_depIdxs = []int32{ - 1, // 0: xmtp.mls.message_contents.OneshotMessage.readd_request:type_name -> xmtp.mls.message_contents.ReaddRequest - 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_mls_message_contents_oneshot_proto_init() } -func file_mls_message_contents_oneshot_proto_init() { - if File_mls_message_contents_oneshot_proto != nil { - return - } - file_mls_message_contents_oneshot_proto_msgTypes[0].OneofWrappers = []any{ - (*OneshotMessage_ReaddRequest)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_oneshot_proto_rawDesc), len(file_mls_message_contents_oneshot_proto_rawDesc)), - NumEnums: 0, - NumMessages: 2, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_oneshot_proto_goTypes, - DependencyIndexes: file_mls_message_contents_oneshot_proto_depIdxs, - MessageInfos: file_mls_message_contents_oneshot_proto_msgTypes, - }.Build() - File_mls_message_contents_oneshot_proto = out.File - file_mls_message_contents_oneshot_proto_goTypes = nil - file_mls_message_contents_oneshot_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/proposal_support.pb.go b/pkg/proto/mls/message_contents/proposal_support.pb.go deleted file mode 100644 index 4d27e88e..00000000 --- a/pkg/proto/mls/message_contents/proposal_support.pb.go +++ /dev/null @@ -1,128 +0,0 @@ -// Proposal support extension data - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/proposal_support.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Extension data for proposal support in group context. -// When present in the group context extensions, indicates the group -// uses proposal-by-reference flow. -type ProposalSupport struct { - state protoimpl.MessageState `protogen:"open.v1"` - Version uint32 `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ProposalSupport) Reset() { - *x = ProposalSupport{} - mi := &file_mls_message_contents_proposal_support_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ProposalSupport) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ProposalSupport) ProtoMessage() {} - -func (x *ProposalSupport) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_proposal_support_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ProposalSupport.ProtoReflect.Descriptor instead. -func (*ProposalSupport) Descriptor() ([]byte, []int) { - return file_mls_message_contents_proposal_support_proto_rawDescGZIP(), []int{0} -} - -func (x *ProposalSupport) GetVersion() uint32 { - if x != nil { - return x.Version - } - return 0 -} - -var File_mls_message_contents_proposal_support_proto protoreflect.FileDescriptor - -const file_mls_message_contents_proposal_support_proto_rawDesc = "" + - "\n" + - "+mls/message_contents/proposal_support.proto\x12\x19xmtp.mls.message_contents\"+\n" + - "\x0fProposalSupport\x12\x18\n" + - "\aversion\x18\x01 \x01(\rR\aversionB\xa0\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x14ProposalSupportProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_proposal_support_proto_rawDescOnce sync.Once - file_mls_message_contents_proposal_support_proto_rawDescData []byte -) - -func file_mls_message_contents_proposal_support_proto_rawDescGZIP() []byte { - file_mls_message_contents_proposal_support_proto_rawDescOnce.Do(func() { - file_mls_message_contents_proposal_support_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_proposal_support_proto_rawDesc), len(file_mls_message_contents_proposal_support_proto_rawDesc))) - }) - return file_mls_message_contents_proposal_support_proto_rawDescData -} - -var file_mls_message_contents_proposal_support_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_mls_message_contents_proposal_support_proto_goTypes = []any{ - (*ProposalSupport)(nil), // 0: xmtp.mls.message_contents.ProposalSupport -} -var file_mls_message_contents_proposal_support_proto_depIdxs = []int32{ - 0, // [0:0] is the sub-list for method output_type - 0, // [0:0] 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_mls_message_contents_proposal_support_proto_init() } -func file_mls_message_contents_proposal_support_proto_init() { - if File_mls_message_contents_proposal_support_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_proposal_support_proto_rawDesc), len(file_mls_message_contents_proposal_support_proto_rawDesc)), - NumEnums: 0, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_proposal_support_proto_goTypes, - DependencyIndexes: file_mls_message_contents_proposal_support_proto_depIdxs, - MessageInfos: file_mls_message_contents_proposal_support_proto_msgTypes, - }.Build() - File_mls_message_contents_proposal_support_proto = out.File - file_mls_message_contents_proposal_support_proto_goTypes = nil - file_mls_message_contents_proposal_support_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/transcript_messages.pb.go b/pkg/proto/mls/message_contents/transcript_messages.pb.go deleted file mode 100644 index 86092994..00000000 --- a/pkg/proto/mls/message_contents/transcript_messages.pb.go +++ /dev/null @@ -1,487 +0,0 @@ -// Message content encoding structures - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/transcript_messages.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// A group member and affected installation IDs -type MembershipChange struct { - state protoimpl.MessageState `protogen:"open.v1"` - InstallationIds [][]byte `protobuf:"bytes,1,rep,name=installation_ids,json=installationIds,proto3" json:"installation_ids,omitempty"` - AccountAddress string `protobuf:"bytes,2,opt,name=account_address,json=accountAddress,proto3" json:"account_address,omitempty"` - InitiatedByAccountAddress string `protobuf:"bytes,3,opt,name=initiated_by_account_address,json=initiatedByAccountAddress,proto3" json:"initiated_by_account_address,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MembershipChange) Reset() { - *x = MembershipChange{} - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MembershipChange) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MembershipChange) ProtoMessage() {} - -func (x *MembershipChange) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MembershipChange.ProtoReflect.Descriptor instead. -func (*MembershipChange) Descriptor() ([]byte, []int) { - return file_mls_message_contents_transcript_messages_proto_rawDescGZIP(), []int{0} -} - -func (x *MembershipChange) GetInstallationIds() [][]byte { - if x != nil { - return x.InstallationIds - } - return nil -} - -func (x *MembershipChange) GetAccountAddress() string { - if x != nil { - return x.AccountAddress - } - return "" -} - -func (x *MembershipChange) GetInitiatedByAccountAddress() string { - if x != nil { - return x.InitiatedByAccountAddress - } - return "" -} - -// The group membership change proto -type GroupMembershipChanges struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Members that have been added in the commit - MembersAdded []*MembershipChange `protobuf:"bytes,1,rep,name=members_added,json=membersAdded,proto3" json:"members_added,omitempty"` - // Members that have been removed in the commit - MembersRemoved []*MembershipChange `protobuf:"bytes,2,rep,name=members_removed,json=membersRemoved,proto3" json:"members_removed,omitempty"` - // Installations that have been added in the commit, grouped by member - InstallationsAdded []*MembershipChange `protobuf:"bytes,3,rep,name=installations_added,json=installationsAdded,proto3" json:"installations_added,omitempty"` - // Installations removed in the commit, grouped by member - InstallationsRemoved []*MembershipChange `protobuf:"bytes,4,rep,name=installations_removed,json=installationsRemoved,proto3" json:"installations_removed,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupMembershipChanges) Reset() { - *x = GroupMembershipChanges{} - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupMembershipChanges) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupMembershipChanges) ProtoMessage() {} - -func (x *GroupMembershipChanges) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupMembershipChanges.ProtoReflect.Descriptor instead. -func (*GroupMembershipChanges) Descriptor() ([]byte, []int) { - return file_mls_message_contents_transcript_messages_proto_rawDescGZIP(), []int{1} -} - -func (x *GroupMembershipChanges) GetMembersAdded() []*MembershipChange { - if x != nil { - return x.MembersAdded - } - return nil -} - -func (x *GroupMembershipChanges) GetMembersRemoved() []*MembershipChange { - if x != nil { - return x.MembersRemoved - } - return nil -} - -func (x *GroupMembershipChanges) GetInstallationsAdded() []*MembershipChange { - if x != nil { - return x.InstallationsAdded - } - return nil -} - -func (x *GroupMembershipChanges) GetInstallationsRemoved() []*MembershipChange { - if x != nil { - return x.InstallationsRemoved - } - return nil -} - -// A summary of the changes in a commit. -// Includes added/removed inboxes and changes to metadata -type GroupUpdated struct { - state protoimpl.MessageState `protogen:"open.v1"` - InitiatedByInboxId string `protobuf:"bytes,1,opt,name=initiated_by_inbox_id,json=initiatedByInboxId,proto3" json:"initiated_by_inbox_id,omitempty"` - // The inboxes added in the commit - AddedInboxes []*GroupUpdated_Inbox `protobuf:"bytes,2,rep,name=added_inboxes,json=addedInboxes,proto3" json:"added_inboxes,omitempty"` - // The inboxes removed in the commit - RemovedInboxes []*GroupUpdated_Inbox `protobuf:"bytes,3,rep,name=removed_inboxes,json=removedInboxes,proto3" json:"removed_inboxes,omitempty"` - // The metadata changes in the commit - MetadataFieldChanges []*GroupUpdated_MetadataFieldChange `protobuf:"bytes,4,rep,name=metadata_field_changes,json=metadataFieldChanges,proto3" json:"metadata_field_changes,omitempty"` - // / The inboxes that were removed from the group in response to pending-remove/self-remove requests - LeftInboxes []*GroupUpdated_Inbox `protobuf:"bytes,5,rep,name=left_inboxes,json=leftInboxes,proto3" json:"left_inboxes,omitempty"` - // The inboxes that were added to admin list in the commit - AddedAdminInboxes []*GroupUpdated_Inbox `protobuf:"bytes,6,rep,name=added_admin_inboxes,json=addedAdminInboxes,proto3" json:"added_admin_inboxes,omitempty"` - // The inboxes that were removed from admin list in the commit - RemovedAdminInboxes []*GroupUpdated_Inbox `protobuf:"bytes,7,rep,name=removed_admin_inboxes,json=removedAdminInboxes,proto3" json:"removed_admin_inboxes,omitempty"` - // The inboxes that were added to super admin list in the commit - AddedSuperAdminInboxes []*GroupUpdated_Inbox `protobuf:"bytes,8,rep,name=added_super_admin_inboxes,json=addedSuperAdminInboxes,proto3" json:"added_super_admin_inboxes,omitempty"` - // The inboxes that were removed from super admin list in the commit - RemovedSuperAdminInboxes []*GroupUpdated_Inbox `protobuf:"bytes,9,rep,name=removed_super_admin_inboxes,json=removedSuperAdminInboxes,proto3" json:"removed_super_admin_inboxes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupUpdated) Reset() { - *x = GroupUpdated{} - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupUpdated) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupUpdated) ProtoMessage() {} - -func (x *GroupUpdated) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupUpdated.ProtoReflect.Descriptor instead. -func (*GroupUpdated) Descriptor() ([]byte, []int) { - return file_mls_message_contents_transcript_messages_proto_rawDescGZIP(), []int{2} -} - -func (x *GroupUpdated) GetInitiatedByInboxId() string { - if x != nil { - return x.InitiatedByInboxId - } - return "" -} - -func (x *GroupUpdated) GetAddedInboxes() []*GroupUpdated_Inbox { - if x != nil { - return x.AddedInboxes - } - return nil -} - -func (x *GroupUpdated) GetRemovedInboxes() []*GroupUpdated_Inbox { - if x != nil { - return x.RemovedInboxes - } - return nil -} - -func (x *GroupUpdated) GetMetadataFieldChanges() []*GroupUpdated_MetadataFieldChange { - if x != nil { - return x.MetadataFieldChanges - } - return nil -} - -func (x *GroupUpdated) GetLeftInboxes() []*GroupUpdated_Inbox { - if x != nil { - return x.LeftInboxes - } - return nil -} - -func (x *GroupUpdated) GetAddedAdminInboxes() []*GroupUpdated_Inbox { - if x != nil { - return x.AddedAdminInboxes - } - return nil -} - -func (x *GroupUpdated) GetRemovedAdminInboxes() []*GroupUpdated_Inbox { - if x != nil { - return x.RemovedAdminInboxes - } - return nil -} - -func (x *GroupUpdated) GetAddedSuperAdminInboxes() []*GroupUpdated_Inbox { - if x != nil { - return x.AddedSuperAdminInboxes - } - return nil -} - -func (x *GroupUpdated) GetRemovedSuperAdminInboxes() []*GroupUpdated_Inbox { - if x != nil { - return x.RemovedSuperAdminInboxes - } - return nil -} - -// An inbox that was added or removed in this commit -type GroupUpdated_Inbox struct { - state protoimpl.MessageState `protogen:"open.v1"` - InboxId string `protobuf:"bytes,1,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupUpdated_Inbox) Reset() { - *x = GroupUpdated_Inbox{} - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupUpdated_Inbox) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupUpdated_Inbox) ProtoMessage() {} - -func (x *GroupUpdated_Inbox) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupUpdated_Inbox.ProtoReflect.Descriptor instead. -func (*GroupUpdated_Inbox) Descriptor() ([]byte, []int) { - return file_mls_message_contents_transcript_messages_proto_rawDescGZIP(), []int{2, 0} -} - -func (x *GroupUpdated_Inbox) GetInboxId() string { - if x != nil { - return x.InboxId - } - return "" -} - -// A summary of a change to the mutable metadata -type GroupUpdated_MetadataFieldChange struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The field that was changed - FieldName string `protobuf:"bytes,1,opt,name=field_name,json=fieldName,proto3" json:"field_name,omitempty"` - // The previous value - OldValue *string `protobuf:"bytes,2,opt,name=old_value,json=oldValue,proto3,oneof" json:"old_value,omitempty"` - // The updated value - NewValue *string `protobuf:"bytes,3,opt,name=new_value,json=newValue,proto3,oneof" json:"new_value,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GroupUpdated_MetadataFieldChange) Reset() { - *x = GroupUpdated_MetadataFieldChange{} - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GroupUpdated_MetadataFieldChange) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GroupUpdated_MetadataFieldChange) ProtoMessage() {} - -func (x *GroupUpdated_MetadataFieldChange) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_transcript_messages_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GroupUpdated_MetadataFieldChange.ProtoReflect.Descriptor instead. -func (*GroupUpdated_MetadataFieldChange) Descriptor() ([]byte, []int) { - return file_mls_message_contents_transcript_messages_proto_rawDescGZIP(), []int{2, 1} -} - -func (x *GroupUpdated_MetadataFieldChange) GetFieldName() string { - if x != nil { - return x.FieldName - } - return "" -} - -func (x *GroupUpdated_MetadataFieldChange) GetOldValue() string { - if x != nil && x.OldValue != nil { - return *x.OldValue - } - return "" -} - -func (x *GroupUpdated_MetadataFieldChange) GetNewValue() string { - if x != nil && x.NewValue != nil { - return *x.NewValue - } - return "" -} - -var File_mls_message_contents_transcript_messages_proto protoreflect.FileDescriptor - -const file_mls_message_contents_transcript_messages_proto_rawDesc = "" + - "\n" + - ".mls/message_contents/transcript_messages.proto\x12\x19xmtp.mls.message_contents\"\xa7\x01\n" + - "\x10MembershipChange\x12)\n" + - "\x10installation_ids\x18\x01 \x03(\fR\x0finstallationIds\x12'\n" + - "\x0faccount_address\x18\x02 \x01(\tR\x0eaccountAddress\x12?\n" + - "\x1cinitiated_by_account_address\x18\x03 \x01(\tR\x19initiatedByAccountAddress\"\x80\x03\n" + - "\x16GroupMembershipChanges\x12P\n" + - "\rmembers_added\x18\x01 \x03(\v2+.xmtp.mls.message_contents.MembershipChangeR\fmembersAdded\x12T\n" + - "\x0fmembers_removed\x18\x02 \x03(\v2+.xmtp.mls.message_contents.MembershipChangeR\x0emembersRemoved\x12\\\n" + - "\x13installations_added\x18\x03 \x03(\v2+.xmtp.mls.message_contents.MembershipChangeR\x12installationsAdded\x12`\n" + - "\x15installations_removed\x18\x04 \x03(\v2+.xmtp.mls.message_contents.MembershipChangeR\x14installationsRemoved\"\x87\b\n" + - "\fGroupUpdated\x121\n" + - "\x15initiated_by_inbox_id\x18\x01 \x01(\tR\x12initiatedByInboxId\x12R\n" + - "\radded_inboxes\x18\x02 \x03(\v2-.xmtp.mls.message_contents.GroupUpdated.InboxR\faddedInboxes\x12V\n" + - "\x0fremoved_inboxes\x18\x03 \x03(\v2-.xmtp.mls.message_contents.GroupUpdated.InboxR\x0eremovedInboxes\x12q\n" + - "\x16metadata_field_changes\x18\x04 \x03(\v2;.xmtp.mls.message_contents.GroupUpdated.MetadataFieldChangeR\x14metadataFieldChanges\x12P\n" + - "\fleft_inboxes\x18\x05 \x03(\v2-.xmtp.mls.message_contents.GroupUpdated.InboxR\vleftInboxes\x12]\n" + - "\x13added_admin_inboxes\x18\x06 \x03(\v2-.xmtp.mls.message_contents.GroupUpdated.InboxR\x11addedAdminInboxes\x12a\n" + - "\x15removed_admin_inboxes\x18\a \x03(\v2-.xmtp.mls.message_contents.GroupUpdated.InboxR\x13removedAdminInboxes\x12h\n" + - "\x19added_super_admin_inboxes\x18\b \x03(\v2-.xmtp.mls.message_contents.GroupUpdated.InboxR\x16addedSuperAdminInboxes\x12l\n" + - "\x1bremoved_super_admin_inboxes\x18\t \x03(\v2-.xmtp.mls.message_contents.GroupUpdated.InboxR\x18removedSuperAdminInboxes\x1a\"\n" + - "\x05Inbox\x12\x19\n" + - "\binbox_id\x18\x01 \x01(\tR\ainboxId\x1a\x94\x01\n" + - "\x13MetadataFieldChange\x12\x1d\n" + - "\n" + - "field_name\x18\x01 \x01(\tR\tfieldName\x12 \n" + - "\told_value\x18\x02 \x01(\tH\x00R\boldValue\x88\x01\x01\x12 \n" + - "\tnew_value\x18\x03 \x01(\tH\x01R\bnewValue\x88\x01\x01B\f\n" + - "\n" + - "_old_valueB\f\n" + - "\n" + - "_new_valueB\xa3\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x17TranscriptMessagesProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_transcript_messages_proto_rawDescOnce sync.Once - file_mls_message_contents_transcript_messages_proto_rawDescData []byte -) - -func file_mls_message_contents_transcript_messages_proto_rawDescGZIP() []byte { - file_mls_message_contents_transcript_messages_proto_rawDescOnce.Do(func() { - file_mls_message_contents_transcript_messages_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_transcript_messages_proto_rawDesc), len(file_mls_message_contents_transcript_messages_proto_rawDesc))) - }) - return file_mls_message_contents_transcript_messages_proto_rawDescData -} - -var file_mls_message_contents_transcript_messages_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_mls_message_contents_transcript_messages_proto_goTypes = []any{ - (*MembershipChange)(nil), // 0: xmtp.mls.message_contents.MembershipChange - (*GroupMembershipChanges)(nil), // 1: xmtp.mls.message_contents.GroupMembershipChanges - (*GroupUpdated)(nil), // 2: xmtp.mls.message_contents.GroupUpdated - (*GroupUpdated_Inbox)(nil), // 3: xmtp.mls.message_contents.GroupUpdated.Inbox - (*GroupUpdated_MetadataFieldChange)(nil), // 4: xmtp.mls.message_contents.GroupUpdated.MetadataFieldChange -} -var file_mls_message_contents_transcript_messages_proto_depIdxs = []int32{ - 0, // 0: xmtp.mls.message_contents.GroupMembershipChanges.members_added:type_name -> xmtp.mls.message_contents.MembershipChange - 0, // 1: xmtp.mls.message_contents.GroupMembershipChanges.members_removed:type_name -> xmtp.mls.message_contents.MembershipChange - 0, // 2: xmtp.mls.message_contents.GroupMembershipChanges.installations_added:type_name -> xmtp.mls.message_contents.MembershipChange - 0, // 3: xmtp.mls.message_contents.GroupMembershipChanges.installations_removed:type_name -> xmtp.mls.message_contents.MembershipChange - 3, // 4: xmtp.mls.message_contents.GroupUpdated.added_inboxes:type_name -> xmtp.mls.message_contents.GroupUpdated.Inbox - 3, // 5: xmtp.mls.message_contents.GroupUpdated.removed_inboxes:type_name -> xmtp.mls.message_contents.GroupUpdated.Inbox - 4, // 6: xmtp.mls.message_contents.GroupUpdated.metadata_field_changes:type_name -> xmtp.mls.message_contents.GroupUpdated.MetadataFieldChange - 3, // 7: xmtp.mls.message_contents.GroupUpdated.left_inboxes:type_name -> xmtp.mls.message_contents.GroupUpdated.Inbox - 3, // 8: xmtp.mls.message_contents.GroupUpdated.added_admin_inboxes:type_name -> xmtp.mls.message_contents.GroupUpdated.Inbox - 3, // 9: xmtp.mls.message_contents.GroupUpdated.removed_admin_inboxes:type_name -> xmtp.mls.message_contents.GroupUpdated.Inbox - 3, // 10: xmtp.mls.message_contents.GroupUpdated.added_super_admin_inboxes:type_name -> xmtp.mls.message_contents.GroupUpdated.Inbox - 3, // 11: xmtp.mls.message_contents.GroupUpdated.removed_super_admin_inboxes:type_name -> xmtp.mls.message_contents.GroupUpdated.Inbox - 12, // [12:12] is the sub-list for method output_type - 12, // [12:12] is the sub-list for method input_type - 12, // [12:12] is the sub-list for extension type_name - 12, // [12:12] is the sub-list for extension extendee - 0, // [0:12] is the sub-list for field type_name -} - -func init() { file_mls_message_contents_transcript_messages_proto_init() } -func file_mls_message_contents_transcript_messages_proto_init() { - if File_mls_message_contents_transcript_messages_proto != nil { - return - } - file_mls_message_contents_transcript_messages_proto_msgTypes[4].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_transcript_messages_proto_rawDesc), len(file_mls_message_contents_transcript_messages_proto_rawDesc)), - NumEnums: 0, - NumMessages: 5, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_transcript_messages_proto_goTypes, - DependencyIndexes: file_mls_message_contents_transcript_messages_proto_depIdxs, - MessageInfos: file_mls_message_contents_transcript_messages_proto_msgTypes, - }.Build() - File_mls_message_contents_transcript_messages_proto = out.File - file_mls_message_contents_transcript_messages_proto_goTypes = nil - file_mls_message_contents_transcript_messages_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/welcome_pointer.pb.go b/pkg/proto/mls/message_contents/welcome_pointer.pb.go deleted file mode 100644 index 1f129064..00000000 --- a/pkg/proto/mls/message_contents/welcome_pointer.pb.go +++ /dev/null @@ -1,397 +0,0 @@ -// WelcomePointer is used to point to the welcome message for several installations at once to save overhead - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/welcome_pointer.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type WelcomePointeeEncryptionAeadType int32 - -const ( - WelcomePointeeEncryptionAeadType_WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_UNSPECIFIED WelcomePointeeEncryptionAeadType = 0 - // Use same encoding as openmls::AeadType - WelcomePointeeEncryptionAeadType_WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_CHACHA20_POLY1305 WelcomePointeeEncryptionAeadType = 3 -) - -// Enum value maps for WelcomePointeeEncryptionAeadType. -var ( - WelcomePointeeEncryptionAeadType_name = map[int32]string{ - 0: "WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_UNSPECIFIED", - 3: "WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_CHACHA20_POLY1305", - } - WelcomePointeeEncryptionAeadType_value = map[string]int32{ - "WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_UNSPECIFIED": 0, - "WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_CHACHA20_POLY1305": 3, - } -) - -func (x WelcomePointeeEncryptionAeadType) Enum() *WelcomePointeeEncryptionAeadType { - p := new(WelcomePointeeEncryptionAeadType) - *p = x - return p -} - -func (x WelcomePointeeEncryptionAeadType) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (WelcomePointeeEncryptionAeadType) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_welcome_pointer_proto_enumTypes[0].Descriptor() -} - -func (WelcomePointeeEncryptionAeadType) Type() protoreflect.EnumType { - return &file_mls_message_contents_welcome_pointer_proto_enumTypes[0] -} - -func (x WelcomePointeeEncryptionAeadType) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use WelcomePointeeEncryptionAeadType.Descriptor instead. -func (WelcomePointeeEncryptionAeadType) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_welcome_pointer_proto_rawDescGZIP(), []int{0} -} - -// MUST match the WelcomeWrapperAlgorithm enum values without 25519 so that the i32 transformations are compatible -type WelcomePointerWrapperAlgorithm int32 - -const ( - WelcomePointerWrapperAlgorithm_WELCOME_POINTER_WRAPPER_ALGORITHM_UNSPECIFIED WelcomePointerWrapperAlgorithm = 0 - WelcomePointerWrapperAlgorithm_WELCOME_POINTER_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6 WelcomePointerWrapperAlgorithm = 2 -) - -// Enum value maps for WelcomePointerWrapperAlgorithm. -var ( - WelcomePointerWrapperAlgorithm_name = map[int32]string{ - 0: "WELCOME_POINTER_WRAPPER_ALGORITHM_UNSPECIFIED", - 2: "WELCOME_POINTER_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6", - } - WelcomePointerWrapperAlgorithm_value = map[string]int32{ - "WELCOME_POINTER_WRAPPER_ALGORITHM_UNSPECIFIED": 0, - "WELCOME_POINTER_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6": 2, - } -) - -func (x WelcomePointerWrapperAlgorithm) Enum() *WelcomePointerWrapperAlgorithm { - p := new(WelcomePointerWrapperAlgorithm) - *p = x - return p -} - -func (x WelcomePointerWrapperAlgorithm) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (WelcomePointerWrapperAlgorithm) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_welcome_pointer_proto_enumTypes[1].Descriptor() -} - -func (WelcomePointerWrapperAlgorithm) Type() protoreflect.EnumType { - return &file_mls_message_contents_welcome_pointer_proto_enumTypes[1] -} - -func (x WelcomePointerWrapperAlgorithm) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use WelcomePointerWrapperAlgorithm.Descriptor instead. -func (WelcomePointerWrapperAlgorithm) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_welcome_pointer_proto_rawDescGZIP(), []int{1} -} - -// A WelcomePointer is used to point to the welcome message for several installations at once to save overhead -type WelcomePointer struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Version: - // - // *WelcomePointer_WelcomeV1Pointer_ - Version isWelcomePointer_Version `protobuf_oneof:"version"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomePointer) Reset() { - *x = WelcomePointer{} - mi := &file_mls_message_contents_welcome_pointer_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomePointer) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomePointer) ProtoMessage() {} - -func (x *WelcomePointer) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_welcome_pointer_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomePointer.ProtoReflect.Descriptor instead. -func (*WelcomePointer) Descriptor() ([]byte, []int) { - return file_mls_message_contents_welcome_pointer_proto_rawDescGZIP(), []int{0} -} - -func (x *WelcomePointer) GetVersion() isWelcomePointer_Version { - if x != nil { - return x.Version - } - return nil -} - -func (x *WelcomePointer) GetWelcomeV1Pointer() *WelcomePointer_WelcomeV1Pointer { - if x != nil { - if x, ok := x.Version.(*WelcomePointer_WelcomeV1Pointer_); ok { - return x.WelcomeV1Pointer - } - } - return nil -} - -type isWelcomePointer_Version interface { - isWelcomePointer_Version() -} - -type WelcomePointer_WelcomeV1Pointer_ struct { - WelcomeV1Pointer *WelcomePointer_WelcomeV1Pointer `protobuf:"bytes,1,opt,name=welcome_v1_pointer,json=welcomeV1Pointer,proto3,oneof"` -} - -func (*WelcomePointer_WelcomeV1Pointer_) isWelcomePointer_Version() {} - -// Extension message that indicates the types of encryption supported by a client -type WelcomePointeeEncryptionAeadTypesExtension struct { - state protoimpl.MessageState `protogen:"open.v1"` - SupportedAeadTypes []WelcomePointeeEncryptionAeadType `protobuf:"varint,1,rep,packed,name=supported_aead_types,json=supportedAeadTypes,proto3,enum=xmtp.mls.message_contents.WelcomePointeeEncryptionAeadType" json:"supported_aead_types,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomePointeeEncryptionAeadTypesExtension) Reset() { - *x = WelcomePointeeEncryptionAeadTypesExtension{} - mi := &file_mls_message_contents_welcome_pointer_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomePointeeEncryptionAeadTypesExtension) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomePointeeEncryptionAeadTypesExtension) ProtoMessage() {} - -func (x *WelcomePointeeEncryptionAeadTypesExtension) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_welcome_pointer_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomePointeeEncryptionAeadTypesExtension.ProtoReflect.Descriptor instead. -func (*WelcomePointeeEncryptionAeadTypesExtension) Descriptor() ([]byte, []int) { - return file_mls_message_contents_welcome_pointer_proto_rawDescGZIP(), []int{1} -} - -func (x *WelcomePointeeEncryptionAeadTypesExtension) GetSupportedAeadTypes() []WelcomePointeeEncryptionAeadType { - if x != nil { - return x.SupportedAeadTypes - } - return nil -} - -// Points to a V1 WelcomeMessage -type WelcomePointer_WelcomeV1Pointer struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The topic of the welcome message. For V1, this means that it will be the first message in the topic, so no other identifier is required - Destination []byte `protobuf:"bytes,1,opt,name=destination,proto3" json:"destination,omitempty"` - // The algorithm used to encrypt the welcome pointer - AeadType WelcomePointeeEncryptionAeadType `protobuf:"varint,2,opt,name=aead_type,json=aeadType,proto3,enum=xmtp.mls.message_contents.WelcomePointeeEncryptionAeadType" json:"aead_type,omitempty"` - // The encryption key of the welcome message. Must match key size specified by the aead_type. - EncryptionKey []byte `protobuf:"bytes,3,opt,name=encryption_key,json=encryptionKey,proto3" json:"encryption_key,omitempty"` - // Nonce used to encrypt the data field. Must match nonce size specified by the aead_type. - DataNonce []byte `protobuf:"bytes,4,opt,name=data_nonce,json=dataNonce,proto3" json:"data_nonce,omitempty"` - // Nonce used to encrypt the welcome_metadata field. Must match nonce size specified by the aead_type. - WelcomeMetadataNonce []byte `protobuf:"bytes,5,opt,name=welcome_metadata_nonce,json=welcomeMetadataNonce,proto3" json:"welcome_metadata_nonce,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomePointer_WelcomeV1Pointer) Reset() { - *x = WelcomePointer_WelcomeV1Pointer{} - mi := &file_mls_message_contents_welcome_pointer_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomePointer_WelcomeV1Pointer) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomePointer_WelcomeV1Pointer) ProtoMessage() {} - -func (x *WelcomePointer_WelcomeV1Pointer) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_welcome_pointer_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomePointer_WelcomeV1Pointer.ProtoReflect.Descriptor instead. -func (*WelcomePointer_WelcomeV1Pointer) Descriptor() ([]byte, []int) { - return file_mls_message_contents_welcome_pointer_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *WelcomePointer_WelcomeV1Pointer) GetDestination() []byte { - if x != nil { - return x.Destination - } - return nil -} - -func (x *WelcomePointer_WelcomeV1Pointer) GetAeadType() WelcomePointeeEncryptionAeadType { - if x != nil { - return x.AeadType - } - return WelcomePointeeEncryptionAeadType_WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_UNSPECIFIED -} - -func (x *WelcomePointer_WelcomeV1Pointer) GetEncryptionKey() []byte { - if x != nil { - return x.EncryptionKey - } - return nil -} - -func (x *WelcomePointer_WelcomeV1Pointer) GetDataNonce() []byte { - if x != nil { - return x.DataNonce - } - return nil -} - -func (x *WelcomePointer_WelcomeV1Pointer) GetWelcomeMetadataNonce() []byte { - if x != nil { - return x.WelcomeMetadataNonce - } - return nil -} - -var File_mls_message_contents_welcome_pointer_proto protoreflect.FileDescriptor - -const file_mls_message_contents_welcome_pointer_proto_rawDesc = "" + - "\n" + - "*mls/message_contents/welcome_pointer.proto\x12\x19xmtp.mls.message_contents\"\x94\x03\n" + - "\x0eWelcomePointer\x12j\n" + - "\x12welcome_v1_pointer\x18\x01 \x01(\v2:.xmtp.mls.message_contents.WelcomePointer.WelcomeV1PointerH\x00R\x10welcomeV1Pointer\x1a\x8a\x02\n" + - "\x10WelcomeV1Pointer\x12 \n" + - "\vdestination\x18\x01 \x01(\fR\vdestination\x12X\n" + - "\taead_type\x18\x02 \x01(\x0e2;.xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypeR\baeadType\x12%\n" + - "\x0eencryption_key\x18\x03 \x01(\fR\rencryptionKey\x12\x1d\n" + - "\n" + - "data_nonce\x18\x04 \x01(\fR\tdataNonce\x124\n" + - "\x16welcome_metadata_nonce\x18\x05 \x01(\fR\x14welcomeMetadataNonceB\t\n" + - "\aversion\"\x9b\x01\n" + - "*WelcomePointeeEncryptionAeadTypesExtension\x12m\n" + - "\x14supported_aead_types\x18\x01 \x03(\x0e2;.xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypeR\x12supportedAeadTypes*\x94\x01\n" + - " WelcomePointeeEncryptionAeadType\x124\n" + - "0WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_UNSPECIFIED\x10\x00\x12:\n" + - "6WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_CHACHA20_POLY1305\x10\x03*\x92\x01\n" + - "\x1eWelcomePointerWrapperAlgorithm\x121\n" + - "-WELCOME_POINTER_WRAPPER_ALGORITHM_UNSPECIFIED\x10\x00\x12=\n" + - "9WELCOME_POINTER_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6\x10\x02B\x9f\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x13WelcomePointerProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_welcome_pointer_proto_rawDescOnce sync.Once - file_mls_message_contents_welcome_pointer_proto_rawDescData []byte -) - -func file_mls_message_contents_welcome_pointer_proto_rawDescGZIP() []byte { - file_mls_message_contents_welcome_pointer_proto_rawDescOnce.Do(func() { - file_mls_message_contents_welcome_pointer_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_welcome_pointer_proto_rawDesc), len(file_mls_message_contents_welcome_pointer_proto_rawDesc))) - }) - return file_mls_message_contents_welcome_pointer_proto_rawDescData -} - -var file_mls_message_contents_welcome_pointer_proto_enumTypes = make([]protoimpl.EnumInfo, 2) -var file_mls_message_contents_welcome_pointer_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_mls_message_contents_welcome_pointer_proto_goTypes = []any{ - (WelcomePointeeEncryptionAeadType)(0), // 0: xmtp.mls.message_contents.WelcomePointeeEncryptionAeadType - (WelcomePointerWrapperAlgorithm)(0), // 1: xmtp.mls.message_contents.WelcomePointerWrapperAlgorithm - (*WelcomePointer)(nil), // 2: xmtp.mls.message_contents.WelcomePointer - (*WelcomePointeeEncryptionAeadTypesExtension)(nil), // 3: xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypesExtension - (*WelcomePointer_WelcomeV1Pointer)(nil), // 4: xmtp.mls.message_contents.WelcomePointer.WelcomeV1Pointer -} -var file_mls_message_contents_welcome_pointer_proto_depIdxs = []int32{ - 4, // 0: xmtp.mls.message_contents.WelcomePointer.welcome_v1_pointer:type_name -> xmtp.mls.message_contents.WelcomePointer.WelcomeV1Pointer - 0, // 1: xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypesExtension.supported_aead_types:type_name -> xmtp.mls.message_contents.WelcomePointeeEncryptionAeadType - 0, // 2: xmtp.mls.message_contents.WelcomePointer.WelcomeV1Pointer.aead_type:type_name -> xmtp.mls.message_contents.WelcomePointeeEncryptionAeadType - 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_mls_message_contents_welcome_pointer_proto_init() } -func file_mls_message_contents_welcome_pointer_proto_init() { - if File_mls_message_contents_welcome_pointer_proto != nil { - return - } - file_mls_message_contents_welcome_pointer_proto_msgTypes[0].OneofWrappers = []any{ - (*WelcomePointer_WelcomeV1Pointer_)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_welcome_pointer_proto_rawDesc), len(file_mls_message_contents_welcome_pointer_proto_rawDesc)), - NumEnums: 2, - NumMessages: 3, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_welcome_pointer_proto_goTypes, - DependencyIndexes: file_mls_message_contents_welcome_pointer_proto_depIdxs, - EnumInfos: file_mls_message_contents_welcome_pointer_proto_enumTypes, - MessageInfos: file_mls_message_contents_welcome_pointer_proto_msgTypes, - }.Build() - File_mls_message_contents_welcome_pointer_proto = out.File - file_mls_message_contents_welcome_pointer_proto_goTypes = nil - file_mls_message_contents_welcome_pointer_proto_depIdxs = nil -} diff --git a/pkg/proto/mls/message_contents/wrapper_encryption.pb.go b/pkg/proto/mls/message_contents/wrapper_encryption.pb.go deleted file mode 100644 index b037f0e0..00000000 --- a/pkg/proto/mls/message_contents/wrapper_encryption.pb.go +++ /dev/null @@ -1,198 +0,0 @@ -// Encryption algorithms for the Welcome Wrapper - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls/message_contents/wrapper_encryption.proto - -package message_contents - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Describes the algorithm used to encrypt the Welcome Wrapper -type WelcomeWrapperAlgorithm int32 - -const ( - WelcomeWrapperAlgorithm_WELCOME_WRAPPER_ALGORITHM_UNSPECIFIED WelcomeWrapperAlgorithm = 0 - WelcomeWrapperAlgorithm_WELCOME_WRAPPER_ALGORITHM_CURVE25519 WelcomeWrapperAlgorithm = 1 - WelcomeWrapperAlgorithm_WELCOME_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6 WelcomeWrapperAlgorithm = 2 - // Only used for WelcomePointee's - WelcomeWrapperAlgorithm_WELCOME_WRAPPER_ALGORITHM_SYMMETRIC_KEY WelcomeWrapperAlgorithm = 3 -) - -// Enum value maps for WelcomeWrapperAlgorithm. -var ( - WelcomeWrapperAlgorithm_name = map[int32]string{ - 0: "WELCOME_WRAPPER_ALGORITHM_UNSPECIFIED", - 1: "WELCOME_WRAPPER_ALGORITHM_CURVE25519", - 2: "WELCOME_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6", - 3: "WELCOME_WRAPPER_ALGORITHM_SYMMETRIC_KEY", - } - WelcomeWrapperAlgorithm_value = map[string]int32{ - "WELCOME_WRAPPER_ALGORITHM_UNSPECIFIED": 0, - "WELCOME_WRAPPER_ALGORITHM_CURVE25519": 1, - "WELCOME_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6": 2, - "WELCOME_WRAPPER_ALGORITHM_SYMMETRIC_KEY": 3, - } -) - -func (x WelcomeWrapperAlgorithm) Enum() *WelcomeWrapperAlgorithm { - p := new(WelcomeWrapperAlgorithm) - *p = x - return p -} - -func (x WelcomeWrapperAlgorithm) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (WelcomeWrapperAlgorithm) Descriptor() protoreflect.EnumDescriptor { - return file_mls_message_contents_wrapper_encryption_proto_enumTypes[0].Descriptor() -} - -func (WelcomeWrapperAlgorithm) Type() protoreflect.EnumType { - return &file_mls_message_contents_wrapper_encryption_proto_enumTypes[0] -} - -func (x WelcomeWrapperAlgorithm) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use WelcomeWrapperAlgorithm.Descriptor instead. -func (WelcomeWrapperAlgorithm) EnumDescriptor() ([]byte, []int) { - return file_mls_message_contents_wrapper_encryption_proto_rawDescGZIP(), []int{0} -} - -// The KeyPackageExtension that stores the PubKey and the WelcomeWrapperEncryption -type WelcomeWrapperEncryption struct { - state protoimpl.MessageState `protogen:"open.v1"` - PubKey []byte `protobuf:"bytes,1,opt,name=pub_key,json=pubKey,proto3" json:"pub_key,omitempty"` - Algorithm WelcomeWrapperAlgorithm `protobuf:"varint,2,opt,name=algorithm,proto3,enum=xmtp.mls.message_contents.WelcomeWrapperAlgorithm" json:"algorithm,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WelcomeWrapperEncryption) Reset() { - *x = WelcomeWrapperEncryption{} - mi := &file_mls_message_contents_wrapper_encryption_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WelcomeWrapperEncryption) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WelcomeWrapperEncryption) ProtoMessage() {} - -func (x *WelcomeWrapperEncryption) ProtoReflect() protoreflect.Message { - mi := &file_mls_message_contents_wrapper_encryption_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WelcomeWrapperEncryption.ProtoReflect.Descriptor instead. -func (*WelcomeWrapperEncryption) Descriptor() ([]byte, []int) { - return file_mls_message_contents_wrapper_encryption_proto_rawDescGZIP(), []int{0} -} - -func (x *WelcomeWrapperEncryption) GetPubKey() []byte { - if x != nil { - return x.PubKey - } - return nil -} - -func (x *WelcomeWrapperEncryption) GetAlgorithm() WelcomeWrapperAlgorithm { - if x != nil { - return x.Algorithm - } - return WelcomeWrapperAlgorithm_WELCOME_WRAPPER_ALGORITHM_UNSPECIFIED -} - -var File_mls_message_contents_wrapper_encryption_proto protoreflect.FileDescriptor - -const file_mls_message_contents_wrapper_encryption_proto_rawDesc = "" + - "\n" + - "-mls/message_contents/wrapper_encryption.proto\x12\x19xmtp.mls.message_contents\"\x85\x01\n" + - "\x18WelcomeWrapperEncryption\x12\x17\n" + - "\apub_key\x18\x01 \x01(\fR\x06pubKey\x12P\n" + - "\talgorithm\x18\x02 \x01(\x0e22.xmtp.mls.message_contents.WelcomeWrapperAlgorithmR\talgorithm*\xd2\x01\n" + - "\x17WelcomeWrapperAlgorithm\x12)\n" + - "%WELCOME_WRAPPER_ALGORITHM_UNSPECIFIED\x10\x00\x12(\n" + - "$WELCOME_WRAPPER_ALGORITHM_CURVE25519\x10\x01\x125\n" + - "1WELCOME_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6\x10\x02\x12+\n" + - "'WELCOME_WRAPPER_ALGORITHM_SYMMETRIC_KEY\x10\x03B\xa2\x02\n" + - "7org.xmtp.android.library.push.xmtp.mls.message_contentsB\x16WrapperEncryptionProtoP\x01ZMgithub.com/xmtp/example-notification-server-go/pkg/proto/mls/message_contents\xa2\x02\x03XMM\xaa\x02\x18Xmtp.Mls.MessageContents\xca\x02\x18Xmtp\\Mls\\MessageContents\xe2\x02$Xmtp\\Mls\\MessageContents\\GPBMetadata\xea\x02\x1aXmtp::Mls::MessageContentsb\x06proto3" - -var ( - file_mls_message_contents_wrapper_encryption_proto_rawDescOnce sync.Once - file_mls_message_contents_wrapper_encryption_proto_rawDescData []byte -) - -func file_mls_message_contents_wrapper_encryption_proto_rawDescGZIP() []byte { - file_mls_message_contents_wrapper_encryption_proto_rawDescOnce.Do(func() { - file_mls_message_contents_wrapper_encryption_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_message_contents_wrapper_encryption_proto_rawDesc), len(file_mls_message_contents_wrapper_encryption_proto_rawDesc))) - }) - return file_mls_message_contents_wrapper_encryption_proto_rawDescData -} - -var file_mls_message_contents_wrapper_encryption_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_mls_message_contents_wrapper_encryption_proto_msgTypes = make([]protoimpl.MessageInfo, 1) -var file_mls_message_contents_wrapper_encryption_proto_goTypes = []any{ - (WelcomeWrapperAlgorithm)(0), // 0: xmtp.mls.message_contents.WelcomeWrapperAlgorithm - (*WelcomeWrapperEncryption)(nil), // 1: xmtp.mls.message_contents.WelcomeWrapperEncryption -} -var file_mls_message_contents_wrapper_encryption_proto_depIdxs = []int32{ - 0, // 0: xmtp.mls.message_contents.WelcomeWrapperEncryption.algorithm:type_name -> xmtp.mls.message_contents.WelcomeWrapperAlgorithm - 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_mls_message_contents_wrapper_encryption_proto_init() } -func file_mls_message_contents_wrapper_encryption_proto_init() { - if File_mls_message_contents_wrapper_encryption_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_message_contents_wrapper_encryption_proto_rawDesc), len(file_mls_message_contents_wrapper_encryption_proto_rawDesc)), - NumEnums: 1, - NumMessages: 1, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_mls_message_contents_wrapper_encryption_proto_goTypes, - DependencyIndexes: file_mls_message_contents_wrapper_encryption_proto_depIdxs, - EnumInfos: file_mls_message_contents_wrapper_encryption_proto_enumTypes, - MessageInfos: file_mls_message_contents_wrapper_encryption_proto_msgTypes, - }.Build() - File_mls_message_contents_wrapper_encryption_proto = out.File - file_mls_message_contents_wrapper_encryption_proto_goTypes = nil - file_mls_message_contents_wrapper_encryption_proto_depIdxs = nil -} diff --git a/pkg/proto/mls_validation/v1/service.pb.go b/pkg/proto/mls_validation/v1/service.pb.go deleted file mode 100644 index cac21218..00000000 --- a/pkg/proto/mls_validation/v1/service.pb.go +++ /dev/null @@ -1,940 +0,0 @@ -// Message API - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: mls_validation/v1/service.proto - -package mls_validationv1 - -import ( - identity "github.com/xmtp/example-notification-server-go/pkg/proto/identity" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/identity/api/v1" - associations "github.com/xmtp/example-notification-server-go/pkg/proto/identity/associations" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Contains a batch of serialized Key Packages -type ValidateInboxIdKeyPackagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyPackages []*ValidateInboxIdKeyPackagesRequest_KeyPackage `protobuf:"bytes,1,rep,name=key_packages,json=keyPackages,proto3" json:"key_packages,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateInboxIdKeyPackagesRequest) Reset() { - *x = ValidateInboxIdKeyPackagesRequest{} - mi := &file_mls_validation_v1_service_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateInboxIdKeyPackagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateInboxIdKeyPackagesRequest) ProtoMessage() {} - -func (x *ValidateInboxIdKeyPackagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateInboxIdKeyPackagesRequest.ProtoReflect.Descriptor instead. -func (*ValidateInboxIdKeyPackagesRequest) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{0} -} - -func (x *ValidateInboxIdKeyPackagesRequest) GetKeyPackages() []*ValidateInboxIdKeyPackagesRequest_KeyPackage { - if x != nil { - return x.KeyPackages - } - return nil -} - -// Validates a Inbox-ID Key Package Type -type ValidateInboxIdKeyPackagesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*ValidateInboxIdKeyPackagesResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateInboxIdKeyPackagesResponse) Reset() { - *x = ValidateInboxIdKeyPackagesResponse{} - mi := &file_mls_validation_v1_service_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateInboxIdKeyPackagesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateInboxIdKeyPackagesResponse) ProtoMessage() {} - -func (x *ValidateInboxIdKeyPackagesResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateInboxIdKeyPackagesResponse.ProtoReflect.Descriptor instead. -func (*ValidateInboxIdKeyPackagesResponse) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{1} -} - -func (x *ValidateInboxIdKeyPackagesResponse) GetResponses() []*ValidateInboxIdKeyPackagesResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -// Contains a batch of serialized Key Packages -type ValidateKeyPackagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyPackages []*ValidateKeyPackagesRequest_KeyPackage `protobuf:"bytes,1,rep,name=key_packages,json=keyPackages,proto3" json:"key_packages,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateKeyPackagesRequest) Reset() { - *x = ValidateKeyPackagesRequest{} - mi := &file_mls_validation_v1_service_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateKeyPackagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateKeyPackagesRequest) ProtoMessage() {} - -func (x *ValidateKeyPackagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateKeyPackagesRequest.ProtoReflect.Descriptor instead. -func (*ValidateKeyPackagesRequest) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{2} -} - -func (x *ValidateKeyPackagesRequest) GetKeyPackages() []*ValidateKeyPackagesRequest_KeyPackage { - if x != nil { - return x.KeyPackages - } - return nil -} - -// Response to ValidateKeyPackagesRequest -type ValidateKeyPackagesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*ValidateKeyPackagesResponse_ValidationResponse `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateKeyPackagesResponse) Reset() { - *x = ValidateKeyPackagesResponse{} - mi := &file_mls_validation_v1_service_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateKeyPackagesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateKeyPackagesResponse) ProtoMessage() {} - -func (x *ValidateKeyPackagesResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateKeyPackagesResponse.ProtoReflect.Descriptor instead. -func (*ValidateKeyPackagesResponse) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{3} -} - -func (x *ValidateKeyPackagesResponse) GetResponses() []*ValidateKeyPackagesResponse_ValidationResponse { - if x != nil { - return x.Responses - } - return nil -} - -// Contains a batch of serialized Group Messages -type ValidateGroupMessagesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupMessages []*ValidateGroupMessagesRequest_GroupMessage `protobuf:"bytes,1,rep,name=group_messages,json=groupMessages,proto3" json:"group_messages,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateGroupMessagesRequest) Reset() { - *x = ValidateGroupMessagesRequest{} - mi := &file_mls_validation_v1_service_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateGroupMessagesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateGroupMessagesRequest) ProtoMessage() {} - -func (x *ValidateGroupMessagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateGroupMessagesRequest.ProtoReflect.Descriptor instead. -func (*ValidateGroupMessagesRequest) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{4} -} - -func (x *ValidateGroupMessagesRequest) GetGroupMessages() []*ValidateGroupMessagesRequest_GroupMessage { - if x != nil { - return x.GroupMessages - } - return nil -} - -// Response to ValidateGroupMessagesRequest -type ValidateGroupMessagesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*ValidateGroupMessagesResponse_ValidationResponse `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateGroupMessagesResponse) Reset() { - *x = ValidateGroupMessagesResponse{} - mi := &file_mls_validation_v1_service_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateGroupMessagesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateGroupMessagesResponse) ProtoMessage() {} - -func (x *ValidateGroupMessagesResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateGroupMessagesResponse.ProtoReflect.Descriptor instead. -func (*ValidateGroupMessagesResponse) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{5} -} - -func (x *ValidateGroupMessagesResponse) GetResponses() []*ValidateGroupMessagesResponse_ValidationResponse { - if x != nil { - return x.Responses - } - return nil -} - -// Request to get a final association state for identity updates -type GetAssociationStateRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - // List of identity updates - OldUpdates []*associations.IdentityUpdate `protobuf:"bytes,1,rep,name=old_updates,json=oldUpdates,proto3" json:"old_updates,omitempty"` - NewUpdates []*associations.IdentityUpdate `protobuf:"bytes,2,rep,name=new_updates,json=newUpdates,proto3" json:"new_updates,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetAssociationStateRequest) Reset() { - *x = GetAssociationStateRequest{} - mi := &file_mls_validation_v1_service_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetAssociationStateRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetAssociationStateRequest) ProtoMessage() {} - -func (x *GetAssociationStateRequest) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetAssociationStateRequest.ProtoReflect.Descriptor instead. -func (*GetAssociationStateRequest) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{6} -} - -func (x *GetAssociationStateRequest) GetOldUpdates() []*associations.IdentityUpdate { - if x != nil { - return x.OldUpdates - } - return nil -} - -func (x *GetAssociationStateRequest) GetNewUpdates() []*associations.IdentityUpdate { - if x != nil { - return x.NewUpdates - } - return nil -} - -// Response to GetAssociationStateRequest, containing the final association -// state for an InboxID -type GetAssociationStateResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - AssociationState *associations.AssociationState `protobuf:"bytes,1,opt,name=association_state,json=associationState,proto3" json:"association_state,omitempty"` - StateDiff *associations.AssociationStateDiff `protobuf:"bytes,2,opt,name=state_diff,json=stateDiff,proto3" json:"state_diff,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetAssociationStateResponse) Reset() { - *x = GetAssociationStateResponse{} - mi := &file_mls_validation_v1_service_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetAssociationStateResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetAssociationStateResponse) ProtoMessage() {} - -func (x *GetAssociationStateResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetAssociationStateResponse.ProtoReflect.Descriptor instead. -func (*GetAssociationStateResponse) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{7} -} - -func (x *GetAssociationStateResponse) GetAssociationState() *associations.AssociationState { - if x != nil { - return x.AssociationState - } - return nil -} - -func (x *GetAssociationStateResponse) GetStateDiff() *associations.AssociationStateDiff { - if x != nil { - return x.StateDiff - } - return nil -} - -// Wrapper for each key package -type ValidateInboxIdKeyPackagesRequest_KeyPackage struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyPackageBytesTlsSerialized []byte `protobuf:"bytes,1,opt,name=key_package_bytes_tls_serialized,json=keyPackageBytesTlsSerialized,proto3" json:"key_package_bytes_tls_serialized,omitempty"` - IsInboxIdCredential bool `protobuf:"varint,2,opt,name=is_inbox_id_credential,json=isInboxIdCredential,proto3" json:"is_inbox_id_credential,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateInboxIdKeyPackagesRequest_KeyPackage) Reset() { - *x = ValidateInboxIdKeyPackagesRequest_KeyPackage{} - mi := &file_mls_validation_v1_service_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateInboxIdKeyPackagesRequest_KeyPackage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateInboxIdKeyPackagesRequest_KeyPackage) ProtoMessage() {} - -func (x *ValidateInboxIdKeyPackagesRequest_KeyPackage) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateInboxIdKeyPackagesRequest_KeyPackage.ProtoReflect.Descriptor instead. -func (*ValidateInboxIdKeyPackagesRequest_KeyPackage) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{0, 0} -} - -func (x *ValidateInboxIdKeyPackagesRequest_KeyPackage) GetKeyPackageBytesTlsSerialized() []byte { - if x != nil { - return x.KeyPackageBytesTlsSerialized - } - return nil -} - -func (x *ValidateInboxIdKeyPackagesRequest_KeyPackage) GetIsInboxIdCredential() bool { - if x != nil { - return x.IsInboxIdCredential - } - return false -} - -// one response corresponding to information about one key package -type ValidateInboxIdKeyPackagesResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - IsOk bool `protobuf:"varint,1,opt,name=is_ok,json=isOk,proto3" json:"is_ok,omitempty"` - ErrorMessage string `protobuf:"bytes,2,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"` - Credential *identity.MlsCredential `protobuf:"bytes,3,opt,name=credential,proto3" json:"credential,omitempty"` - InstallationPublicKey []byte `protobuf:"bytes,4,opt,name=installation_public_key,json=installationPublicKey,proto3" json:"installation_public_key,omitempty"` - Expiration uint64 `protobuf:"varint,5,opt,name=expiration,proto3" json:"expiration,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateInboxIdKeyPackagesResponse_Response) Reset() { - *x = ValidateInboxIdKeyPackagesResponse_Response{} - mi := &file_mls_validation_v1_service_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateInboxIdKeyPackagesResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateInboxIdKeyPackagesResponse_Response) ProtoMessage() {} - -func (x *ValidateInboxIdKeyPackagesResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateInboxIdKeyPackagesResponse_Response.ProtoReflect.Descriptor instead. -func (*ValidateInboxIdKeyPackagesResponse_Response) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{1, 0} -} - -func (x *ValidateInboxIdKeyPackagesResponse_Response) GetIsOk() bool { - if x != nil { - return x.IsOk - } - return false -} - -func (x *ValidateInboxIdKeyPackagesResponse_Response) GetErrorMessage() string { - if x != nil { - return x.ErrorMessage - } - return "" -} - -func (x *ValidateInboxIdKeyPackagesResponse_Response) GetCredential() *identity.MlsCredential { - if x != nil { - return x.Credential - } - return nil -} - -func (x *ValidateInboxIdKeyPackagesResponse_Response) GetInstallationPublicKey() []byte { - if x != nil { - return x.InstallationPublicKey - } - return nil -} - -func (x *ValidateInboxIdKeyPackagesResponse_Response) GetExpiration() uint64 { - if x != nil { - return x.Expiration - } - return 0 -} - -// Wrapper for each key package -type ValidateKeyPackagesRequest_KeyPackage struct { - state protoimpl.MessageState `protogen:"open.v1"` - KeyPackageBytesTlsSerialized []byte `protobuf:"bytes,1,opt,name=key_package_bytes_tls_serialized,json=keyPackageBytesTlsSerialized,proto3" json:"key_package_bytes_tls_serialized,omitempty"` - IsInboxIdCredential bool `protobuf:"varint,2,opt,name=is_inbox_id_credential,json=isInboxIdCredential,proto3" json:"is_inbox_id_credential,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateKeyPackagesRequest_KeyPackage) Reset() { - *x = ValidateKeyPackagesRequest_KeyPackage{} - mi := &file_mls_validation_v1_service_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateKeyPackagesRequest_KeyPackage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateKeyPackagesRequest_KeyPackage) ProtoMessage() {} - -func (x *ValidateKeyPackagesRequest_KeyPackage) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateKeyPackagesRequest_KeyPackage.ProtoReflect.Descriptor instead. -func (*ValidateKeyPackagesRequest_KeyPackage) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{2, 0} -} - -func (x *ValidateKeyPackagesRequest_KeyPackage) GetKeyPackageBytesTlsSerialized() []byte { - if x != nil { - return x.KeyPackageBytesTlsSerialized - } - return nil -} - -func (x *ValidateKeyPackagesRequest_KeyPackage) GetIsInboxIdCredential() bool { - if x != nil { - return x.IsInboxIdCredential - } - return false -} - -// An individual response to one key package -type ValidateKeyPackagesResponse_ValidationResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - IsOk bool `protobuf:"varint,1,opt,name=is_ok,json=isOk,proto3" json:"is_ok,omitempty"` - ErrorMessage string `protobuf:"bytes,2,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"` - InstallationId []byte `protobuf:"bytes,3,opt,name=installation_id,json=installationId,proto3" json:"installation_id,omitempty"` - AccountAddress string `protobuf:"bytes,4,opt,name=account_address,json=accountAddress,proto3" json:"account_address,omitempty"` - CredentialIdentityBytes []byte `protobuf:"bytes,5,opt,name=credential_identity_bytes,json=credentialIdentityBytes,proto3" json:"credential_identity_bytes,omitempty"` - Expiration uint64 `protobuf:"varint,6,opt,name=expiration,proto3" json:"expiration,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) Reset() { - *x = ValidateKeyPackagesResponse_ValidationResponse{} - mi := &file_mls_validation_v1_service_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateKeyPackagesResponse_ValidationResponse) ProtoMessage() {} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateKeyPackagesResponse_ValidationResponse.ProtoReflect.Descriptor instead. -func (*ValidateKeyPackagesResponse_ValidationResponse) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{3, 0} -} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) GetIsOk() bool { - if x != nil { - return x.IsOk - } - return false -} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) GetErrorMessage() string { - if x != nil { - return x.ErrorMessage - } - return "" -} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) GetInstallationId() []byte { - if x != nil { - return x.InstallationId - } - return nil -} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) GetAccountAddress() string { - if x != nil { - return x.AccountAddress - } - return "" -} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) GetCredentialIdentityBytes() []byte { - if x != nil { - return x.CredentialIdentityBytes - } - return nil -} - -func (x *ValidateKeyPackagesResponse_ValidationResponse) GetExpiration() uint64 { - if x != nil { - return x.Expiration - } - return 0 -} - -// Wrapper for each message -type ValidateGroupMessagesRequest_GroupMessage struct { - state protoimpl.MessageState `protogen:"open.v1"` - GroupMessageBytesTlsSerialized []byte `protobuf:"bytes,1,opt,name=group_message_bytes_tls_serialized,json=groupMessageBytesTlsSerialized,proto3" json:"group_message_bytes_tls_serialized,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateGroupMessagesRequest_GroupMessage) Reset() { - *x = ValidateGroupMessagesRequest_GroupMessage{} - mi := &file_mls_validation_v1_service_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateGroupMessagesRequest_GroupMessage) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateGroupMessagesRequest_GroupMessage) ProtoMessage() {} - -func (x *ValidateGroupMessagesRequest_GroupMessage) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[12] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateGroupMessagesRequest_GroupMessage.ProtoReflect.Descriptor instead. -func (*ValidateGroupMessagesRequest_GroupMessage) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{4, 0} -} - -func (x *ValidateGroupMessagesRequest_GroupMessage) GetGroupMessageBytesTlsSerialized() []byte { - if x != nil { - return x.GroupMessageBytesTlsSerialized - } - return nil -} - -// An individual response to one message -type ValidateGroupMessagesResponse_ValidationResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - IsOk bool `protobuf:"varint,1,opt,name=is_ok,json=isOk,proto3" json:"is_ok,omitempty"` - ErrorMessage string `protobuf:"bytes,2,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"` - GroupId string `protobuf:"bytes,3,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"` - IsCommit bool `protobuf:"varint,4,opt,name=is_commit,json=isCommit,proto3" json:"is_commit,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ValidateGroupMessagesResponse_ValidationResponse) Reset() { - *x = ValidateGroupMessagesResponse_ValidationResponse{} - mi := &file_mls_validation_v1_service_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ValidateGroupMessagesResponse_ValidationResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ValidateGroupMessagesResponse_ValidationResponse) ProtoMessage() {} - -func (x *ValidateGroupMessagesResponse_ValidationResponse) ProtoReflect() protoreflect.Message { - mi := &file_mls_validation_v1_service_proto_msgTypes[13] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ValidateGroupMessagesResponse_ValidationResponse.ProtoReflect.Descriptor instead. -func (*ValidateGroupMessagesResponse_ValidationResponse) Descriptor() ([]byte, []int) { - return file_mls_validation_v1_service_proto_rawDescGZIP(), []int{5, 0} -} - -func (x *ValidateGroupMessagesResponse_ValidationResponse) GetIsOk() bool { - if x != nil { - return x.IsOk - } - return false -} - -func (x *ValidateGroupMessagesResponse_ValidationResponse) GetErrorMessage() string { - if x != nil { - return x.ErrorMessage - } - return "" -} - -func (x *ValidateGroupMessagesResponse_ValidationResponse) GetGroupId() string { - if x != nil { - return x.GroupId - } - return "" -} - -func (x *ValidateGroupMessagesResponse_ValidationResponse) GetIsCommit() bool { - if x != nil { - return x.IsCommit - } - return false -} - -var File_mls_validation_v1_service_proto protoreflect.FileDescriptor - -const file_mls_validation_v1_service_proto_rawDesc = "" + - "\n" + - "\x1fmls_validation/v1/service.proto\x12\x16xmtp.mls_validation.v1\x1a\x1eidentity/api/v1/identity.proto\x1a'identity/associations/association.proto\x1a\x19identity/credential.proto\"\x98\x02\n" + - "!ValidateInboxIdKeyPackagesRequest\x12g\n" + - "\fkey_packages\x18\x01 \x03(\v2D.xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesRequest.KeyPackageR\vkeyPackages\x1a\x89\x01\n" + - "\n" + - "KeyPackage\x12F\n" + - " key_package_bytes_tls_serialized\x18\x01 \x01(\fR\x1ckeyPackageBytesTlsSerialized\x123\n" + - "\x16is_inbox_id_credential\x18\x02 \x01(\bR\x13isInboxIdCredential\"\xe4\x02\n" + - "\"ValidateInboxIdKeyPackagesResponse\x12a\n" + - "\tresponses\x18\x01 \x03(\v2C.xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesResponse.ResponseR\tresponses\x1a\xda\x01\n" + - "\bResponse\x12\x13\n" + - "\x05is_ok\x18\x01 \x01(\bR\x04isOk\x12#\n" + - "\rerror_message\x18\x02 \x01(\tR\ferrorMessage\x12<\n" + - "\n" + - "credential\x18\x03 \x01(\v2\x1c.xmtp.identity.MlsCredentialR\n" + - "credential\x126\n" + - "\x17installation_public_key\x18\x04 \x01(\fR\x15installationPublicKey\x12\x1e\n" + - "\n" + - "expiration\x18\x05 \x01(\x04R\n" + - "expiration\"\x8a\x02\n" + - "\x1aValidateKeyPackagesRequest\x12`\n" + - "\fkey_packages\x18\x01 \x03(\v2=.xmtp.mls_validation.v1.ValidateKeyPackagesRequest.KeyPackageR\vkeyPackages\x1a\x89\x01\n" + - "\n" + - "KeyPackage\x12F\n" + - " key_package_bytes_tls_serialized\x18\x01 \x01(\fR\x1ckeyPackageBytesTlsSerialized\x123\n" + - "\x16is_inbox_id_credential\x18\x02 \x01(\bR\x13isInboxIdCredential\"\x82\x03\n" + - "\x1bValidateKeyPackagesResponse\x12d\n" + - "\tresponses\x18\x01 \x03(\v2F.xmtp.mls_validation.v1.ValidateKeyPackagesResponse.ValidationResponseR\tresponses\x1a\xfc\x01\n" + - "\x12ValidationResponse\x12\x13\n" + - "\x05is_ok\x18\x01 \x01(\bR\x04isOk\x12#\n" + - "\rerror_message\x18\x02 \x01(\tR\ferrorMessage\x12'\n" + - "\x0finstallation_id\x18\x03 \x01(\fR\x0einstallationId\x12'\n" + - "\x0faccount_address\x18\x04 \x01(\tR\x0eaccountAddress\x12:\n" + - "\x19credential_identity_bytes\x18\x05 \x01(\fR\x17credentialIdentityBytes\x12\x1e\n" + - "\n" + - "expiration\x18\x06 \x01(\x04R\n" + - "expiration\"\xe4\x01\n" + - "\x1cValidateGroupMessagesRequest\x12h\n" + - "\x0egroup_messages\x18\x01 \x03(\v2A.xmtp.mls_validation.v1.ValidateGroupMessagesRequest.GroupMessageR\rgroupMessages\x1aZ\n" + - "\fGroupMessage\x12J\n" + - "\"group_message_bytes_tls_serialized\x18\x01 \x01(\fR\x1egroupMessageBytesTlsSerialized\"\x90\x02\n" + - "\x1dValidateGroupMessagesResponse\x12f\n" + - "\tresponses\x18\x01 \x03(\v2H.xmtp.mls_validation.v1.ValidateGroupMessagesResponse.ValidationResponseR\tresponses\x1a\x86\x01\n" + - "\x12ValidationResponse\x12\x13\n" + - "\x05is_ok\x18\x01 \x01(\bR\x04isOk\x12#\n" + - "\rerror_message\x18\x02 \x01(\tR\ferrorMessage\x12\x19\n" + - "\bgroup_id\x18\x03 \x01(\tR\agroupId\x12\x1b\n" + - "\tis_commit\x18\x04 \x01(\bR\bisCommit\"\xb6\x01\n" + - "\x1aGetAssociationStateRequest\x12K\n" + - "\vold_updates\x18\x01 \x03(\v2*.xmtp.identity.associations.IdentityUpdateR\n" + - "oldUpdates\x12K\n" + - "\vnew_updates\x18\x02 \x03(\v2*.xmtp.identity.associations.IdentityUpdateR\n" + - "newUpdates\"\xc9\x01\n" + - "\x1bGetAssociationStateResponse\x12Y\n" + - "\x11association_state\x18\x01 \x01(\v2,.xmtp.identity.associations.AssociationStateR\x10associationState\x12O\n" + - "\n" + - "state_diff\x18\x02 \x01(\v20.xmtp.identity.associations.AssociationStateDiffR\tstateDiff2\xdb\x04\n" + - "\rValidationApi\x12\x86\x01\n" + - "\x15ValidateGroupMessages\x124.xmtp.mls_validation.v1.ValidateGroupMessagesRequest\x1a5.xmtp.mls_validation.v1.ValidateGroupMessagesResponse\"\x00\x12\x80\x01\n" + - "\x13GetAssociationState\x122.xmtp.mls_validation.v1.GetAssociationStateRequest\x1a3.xmtp.mls_validation.v1.GetAssociationStateResponse\"\x00\x12\x8e\x01\n" + - "\x1aValidateInboxIdKeyPackages\x122.xmtp.mls_validation.v1.ValidateKeyPackagesRequest\x1a:.xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesResponse\"\x00\x12\xac\x01\n" + - "#VerifySmartContractWalletSignatures\x12@.xmtp.identity.api.v1.VerifySmartContractWalletSignaturesRequest\x1aA.xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse\"\x00B\x97\x02\n" + - "4org.xmtp.android.library.push.xmtp.mls_validation.v1B\fServiceProtoP\x01Z[github.com/xmtp/example-notification-server-go/pkg/proto/mls_validation/v1;mls_validationv1\xa2\x02\x03XMX\xaa\x02\x15Xmtp.MlsValidation.V1\xca\x02\x15Xmtp\\MlsValidation\\V1\xe2\x02!Xmtp\\MlsValidation\\V1\\GPBMetadata\xea\x02\x17Xmtp::MlsValidation::V1b\x06proto3" - -var ( - file_mls_validation_v1_service_proto_rawDescOnce sync.Once - file_mls_validation_v1_service_proto_rawDescData []byte -) - -func file_mls_validation_v1_service_proto_rawDescGZIP() []byte { - file_mls_validation_v1_service_proto_rawDescOnce.Do(func() { - file_mls_validation_v1_service_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_mls_validation_v1_service_proto_rawDesc), len(file_mls_validation_v1_service_proto_rawDesc))) - }) - return file_mls_validation_v1_service_proto_rawDescData -} - -var file_mls_validation_v1_service_proto_msgTypes = make([]protoimpl.MessageInfo, 14) -var file_mls_validation_v1_service_proto_goTypes = []any{ - (*ValidateInboxIdKeyPackagesRequest)(nil), // 0: xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesRequest - (*ValidateInboxIdKeyPackagesResponse)(nil), // 1: xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesResponse - (*ValidateKeyPackagesRequest)(nil), // 2: xmtp.mls_validation.v1.ValidateKeyPackagesRequest - (*ValidateKeyPackagesResponse)(nil), // 3: xmtp.mls_validation.v1.ValidateKeyPackagesResponse - (*ValidateGroupMessagesRequest)(nil), // 4: xmtp.mls_validation.v1.ValidateGroupMessagesRequest - (*ValidateGroupMessagesResponse)(nil), // 5: xmtp.mls_validation.v1.ValidateGroupMessagesResponse - (*GetAssociationStateRequest)(nil), // 6: xmtp.mls_validation.v1.GetAssociationStateRequest - (*GetAssociationStateResponse)(nil), // 7: xmtp.mls_validation.v1.GetAssociationStateResponse - (*ValidateInboxIdKeyPackagesRequest_KeyPackage)(nil), // 8: xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesRequest.KeyPackage - (*ValidateInboxIdKeyPackagesResponse_Response)(nil), // 9: xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesResponse.Response - (*ValidateKeyPackagesRequest_KeyPackage)(nil), // 10: xmtp.mls_validation.v1.ValidateKeyPackagesRequest.KeyPackage - (*ValidateKeyPackagesResponse_ValidationResponse)(nil), // 11: xmtp.mls_validation.v1.ValidateKeyPackagesResponse.ValidationResponse - (*ValidateGroupMessagesRequest_GroupMessage)(nil), // 12: xmtp.mls_validation.v1.ValidateGroupMessagesRequest.GroupMessage - (*ValidateGroupMessagesResponse_ValidationResponse)(nil), // 13: xmtp.mls_validation.v1.ValidateGroupMessagesResponse.ValidationResponse - (*associations.IdentityUpdate)(nil), // 14: xmtp.identity.associations.IdentityUpdate - (*associations.AssociationState)(nil), // 15: xmtp.identity.associations.AssociationState - (*associations.AssociationStateDiff)(nil), // 16: xmtp.identity.associations.AssociationStateDiff - (*identity.MlsCredential)(nil), // 17: xmtp.identity.MlsCredential - (*v1.VerifySmartContractWalletSignaturesRequest)(nil), // 18: xmtp.identity.api.v1.VerifySmartContractWalletSignaturesRequest - (*v1.VerifySmartContractWalletSignaturesResponse)(nil), // 19: xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse -} -var file_mls_validation_v1_service_proto_depIdxs = []int32{ - 8, // 0: xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesRequest.key_packages:type_name -> xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesRequest.KeyPackage - 9, // 1: xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesResponse.responses:type_name -> xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesResponse.Response - 10, // 2: xmtp.mls_validation.v1.ValidateKeyPackagesRequest.key_packages:type_name -> xmtp.mls_validation.v1.ValidateKeyPackagesRequest.KeyPackage - 11, // 3: xmtp.mls_validation.v1.ValidateKeyPackagesResponse.responses:type_name -> xmtp.mls_validation.v1.ValidateKeyPackagesResponse.ValidationResponse - 12, // 4: xmtp.mls_validation.v1.ValidateGroupMessagesRequest.group_messages:type_name -> xmtp.mls_validation.v1.ValidateGroupMessagesRequest.GroupMessage - 13, // 5: xmtp.mls_validation.v1.ValidateGroupMessagesResponse.responses:type_name -> xmtp.mls_validation.v1.ValidateGroupMessagesResponse.ValidationResponse - 14, // 6: xmtp.mls_validation.v1.GetAssociationStateRequest.old_updates:type_name -> xmtp.identity.associations.IdentityUpdate - 14, // 7: xmtp.mls_validation.v1.GetAssociationStateRequest.new_updates:type_name -> xmtp.identity.associations.IdentityUpdate - 15, // 8: xmtp.mls_validation.v1.GetAssociationStateResponse.association_state:type_name -> xmtp.identity.associations.AssociationState - 16, // 9: xmtp.mls_validation.v1.GetAssociationStateResponse.state_diff:type_name -> xmtp.identity.associations.AssociationStateDiff - 17, // 10: xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesResponse.Response.credential:type_name -> xmtp.identity.MlsCredential - 4, // 11: xmtp.mls_validation.v1.ValidationApi.ValidateGroupMessages:input_type -> xmtp.mls_validation.v1.ValidateGroupMessagesRequest - 6, // 12: xmtp.mls_validation.v1.ValidationApi.GetAssociationState:input_type -> xmtp.mls_validation.v1.GetAssociationStateRequest - 2, // 13: xmtp.mls_validation.v1.ValidationApi.ValidateInboxIdKeyPackages:input_type -> xmtp.mls_validation.v1.ValidateKeyPackagesRequest - 18, // 14: xmtp.mls_validation.v1.ValidationApi.VerifySmartContractWalletSignatures:input_type -> xmtp.identity.api.v1.VerifySmartContractWalletSignaturesRequest - 5, // 15: xmtp.mls_validation.v1.ValidationApi.ValidateGroupMessages:output_type -> xmtp.mls_validation.v1.ValidateGroupMessagesResponse - 7, // 16: xmtp.mls_validation.v1.ValidationApi.GetAssociationState:output_type -> xmtp.mls_validation.v1.GetAssociationStateResponse - 1, // 17: xmtp.mls_validation.v1.ValidationApi.ValidateInboxIdKeyPackages:output_type -> xmtp.mls_validation.v1.ValidateInboxIdKeyPackagesResponse - 19, // 18: xmtp.mls_validation.v1.ValidationApi.VerifySmartContractWalletSignatures:output_type -> xmtp.identity.api.v1.VerifySmartContractWalletSignaturesResponse - 15, // [15:19] is the sub-list for method output_type - 11, // [11:15] is the sub-list for method input_type - 11, // [11:11] is the sub-list for extension type_name - 11, // [11:11] is the sub-list for extension extendee - 0, // [0:11] is the sub-list for field type_name -} - -func init() { file_mls_validation_v1_service_proto_init() } -func file_mls_validation_v1_service_proto_init() { - if File_mls_validation_v1_service_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_mls_validation_v1_service_proto_rawDesc), len(file_mls_validation_v1_service_proto_rawDesc)), - NumEnums: 0, - NumMessages: 14, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_mls_validation_v1_service_proto_goTypes, - DependencyIndexes: file_mls_validation_v1_service_proto_depIdxs, - MessageInfos: file_mls_validation_v1_service_proto_msgTypes, - }.Build() - File_mls_validation_v1_service_proto = out.File - file_mls_validation_v1_service_proto_goTypes = nil - file_mls_validation_v1_service_proto_depIdxs = nil -} diff --git a/pkg/proto/mls_validation/v1/service_grpc.pb.go b/pkg/proto/mls_validation/v1/service_grpc.pb.go deleted file mode 100644 index 1eea03b9..00000000 --- a/pkg/proto/mls_validation/v1/service_grpc.pb.go +++ /dev/null @@ -1,237 +0,0 @@ -// Message API - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: mls_validation/v1/service.proto - -package mls_validationv1 - -import ( - context "context" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/identity/api/v1" - 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 ( - ValidationApi_ValidateGroupMessages_FullMethodName = "/xmtp.mls_validation.v1.ValidationApi/ValidateGroupMessages" - ValidationApi_GetAssociationState_FullMethodName = "/xmtp.mls_validation.v1.ValidationApi/GetAssociationState" - ValidationApi_ValidateInboxIdKeyPackages_FullMethodName = "/xmtp.mls_validation.v1.ValidationApi/ValidateInboxIdKeyPackages" - ValidationApi_VerifySmartContractWalletSignatures_FullMethodName = "/xmtp.mls_validation.v1.ValidationApi/VerifySmartContractWalletSignatures" -) - -// ValidationApiClient is the client API for ValidationApi 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 ValidationApiClient interface { - // Validates and parses a group message and returns relevant details - ValidateGroupMessages(ctx context.Context, in *ValidateGroupMessagesRequest, opts ...grpc.CallOption) (*ValidateGroupMessagesResponse, error) - // Gets the final association state for a batch of identity updates - GetAssociationState(ctx context.Context, in *GetAssociationStateRequest, opts ...grpc.CallOption) (*GetAssociationStateResponse, error) - // Validates InboxID key packages and returns credential information for them, - // without checking whether an InboxId <> InstallationPublicKey pair is really - // valid. - ValidateInboxIdKeyPackages(ctx context.Context, in *ValidateKeyPackagesRequest, opts ...grpc.CallOption) (*ValidateInboxIdKeyPackagesResponse, error) - // Verifies smart contracts - // This request is proxied from the node, so we'll reuse those messages. - VerifySmartContractWalletSignatures(ctx context.Context, in *v1.VerifySmartContractWalletSignaturesRequest, opts ...grpc.CallOption) (*v1.VerifySmartContractWalletSignaturesResponse, error) -} - -type validationApiClient struct { - cc grpc.ClientConnInterface -} - -func NewValidationApiClient(cc grpc.ClientConnInterface) ValidationApiClient { - return &validationApiClient{cc} -} - -func (c *validationApiClient) ValidateGroupMessages(ctx context.Context, in *ValidateGroupMessagesRequest, opts ...grpc.CallOption) (*ValidateGroupMessagesResponse, error) { - out := new(ValidateGroupMessagesResponse) - err := c.cc.Invoke(ctx, ValidationApi_ValidateGroupMessages_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *validationApiClient) GetAssociationState(ctx context.Context, in *GetAssociationStateRequest, opts ...grpc.CallOption) (*GetAssociationStateResponse, error) { - out := new(GetAssociationStateResponse) - err := c.cc.Invoke(ctx, ValidationApi_GetAssociationState_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *validationApiClient) ValidateInboxIdKeyPackages(ctx context.Context, in *ValidateKeyPackagesRequest, opts ...grpc.CallOption) (*ValidateInboxIdKeyPackagesResponse, error) { - out := new(ValidateInboxIdKeyPackagesResponse) - err := c.cc.Invoke(ctx, ValidationApi_ValidateInboxIdKeyPackages_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *validationApiClient) VerifySmartContractWalletSignatures(ctx context.Context, in *v1.VerifySmartContractWalletSignaturesRequest, opts ...grpc.CallOption) (*v1.VerifySmartContractWalletSignaturesResponse, error) { - out := new(v1.VerifySmartContractWalletSignaturesResponse) - err := c.cc.Invoke(ctx, ValidationApi_VerifySmartContractWalletSignatures_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// ValidationApiServer is the server API for ValidationApi service. -// All implementations must embed UnimplementedValidationApiServer -// for forward compatibility -type ValidationApiServer interface { - // Validates and parses a group message and returns relevant details - ValidateGroupMessages(context.Context, *ValidateGroupMessagesRequest) (*ValidateGroupMessagesResponse, error) - // Gets the final association state for a batch of identity updates - GetAssociationState(context.Context, *GetAssociationStateRequest) (*GetAssociationStateResponse, error) - // Validates InboxID key packages and returns credential information for them, - // without checking whether an InboxId <> InstallationPublicKey pair is really - // valid. - ValidateInboxIdKeyPackages(context.Context, *ValidateKeyPackagesRequest) (*ValidateInboxIdKeyPackagesResponse, error) - // Verifies smart contracts - // This request is proxied from the node, so we'll reuse those messages. - VerifySmartContractWalletSignatures(context.Context, *v1.VerifySmartContractWalletSignaturesRequest) (*v1.VerifySmartContractWalletSignaturesResponse, error) - mustEmbedUnimplementedValidationApiServer() -} - -// UnimplementedValidationApiServer must be embedded to have forward compatible implementations. -type UnimplementedValidationApiServer struct { -} - -func (UnimplementedValidationApiServer) ValidateGroupMessages(context.Context, *ValidateGroupMessagesRequest) (*ValidateGroupMessagesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method ValidateGroupMessages not implemented") -} -func (UnimplementedValidationApiServer) GetAssociationState(context.Context, *GetAssociationStateRequest) (*GetAssociationStateResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetAssociationState not implemented") -} -func (UnimplementedValidationApiServer) ValidateInboxIdKeyPackages(context.Context, *ValidateKeyPackagesRequest) (*ValidateInboxIdKeyPackagesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method ValidateInboxIdKeyPackages not implemented") -} -func (UnimplementedValidationApiServer) VerifySmartContractWalletSignatures(context.Context, *v1.VerifySmartContractWalletSignaturesRequest) (*v1.VerifySmartContractWalletSignaturesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method VerifySmartContractWalletSignatures not implemented") -} -func (UnimplementedValidationApiServer) mustEmbedUnimplementedValidationApiServer() {} - -// UnsafeValidationApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to ValidationApiServer will -// result in compilation errors. -type UnsafeValidationApiServer interface { - mustEmbedUnimplementedValidationApiServer() -} - -func RegisterValidationApiServer(s grpc.ServiceRegistrar, srv ValidationApiServer) { - s.RegisterService(&ValidationApi_ServiceDesc, srv) -} - -func _ValidationApi_ValidateGroupMessages_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(ValidateGroupMessagesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ValidationApiServer).ValidateGroupMessages(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ValidationApi_ValidateGroupMessages_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ValidationApiServer).ValidateGroupMessages(ctx, req.(*ValidateGroupMessagesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _ValidationApi_GetAssociationState_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetAssociationStateRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ValidationApiServer).GetAssociationState(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ValidationApi_GetAssociationState_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ValidationApiServer).GetAssociationState(ctx, req.(*GetAssociationStateRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _ValidationApi_ValidateInboxIdKeyPackages_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(ValidateKeyPackagesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ValidationApiServer).ValidateInboxIdKeyPackages(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ValidationApi_ValidateInboxIdKeyPackages_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ValidationApiServer).ValidateInboxIdKeyPackages(ctx, req.(*ValidateKeyPackagesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _ValidationApi_VerifySmartContractWalletSignatures_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(v1.VerifySmartContractWalletSignaturesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ValidationApiServer).VerifySmartContractWalletSignatures(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ValidationApi_VerifySmartContractWalletSignatures_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ValidationApiServer).VerifySmartContractWalletSignatures(ctx, req.(*v1.VerifySmartContractWalletSignaturesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// ValidationApi_ServiceDesc is the grpc.ServiceDesc for ValidationApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var ValidationApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.mls_validation.v1.ValidationApi", - HandlerType: (*ValidationApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "ValidateGroupMessages", - Handler: _ValidationApi_ValidateGroupMessages_Handler, - }, - { - MethodName: "GetAssociationState", - Handler: _ValidationApi_GetAssociationState_Handler, - }, - { - MethodName: "ValidateInboxIdKeyPackages", - Handler: _ValidationApi_ValidateInboxIdKeyPackages_Handler, - }, - { - MethodName: "VerifySmartContractWalletSignatures", - Handler: _ValidationApi_VerifySmartContractWalletSignatures_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "mls_validation/v1/service.proto", -} diff --git a/pkg/proto/xmtpv4/envelopes/envelopes.pb.go b/pkg/proto/xmtpv4/envelopes/envelopes.pb.go deleted file mode 100644 index a5386961..00000000 --- a/pkg/proto/xmtpv4/envelopes/envelopes.pb.go +++ /dev/null @@ -1,709 +0,0 @@ -// Message API for XMTP V4 - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/envelopes/envelopes.proto - -package envelopes - -import ( - associations "github.com/xmtp/example-notification-server-go/pkg/proto/identity/associations" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/mls/api/v1" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// The last seen entry per originator. Originators that have not been seen are omitted. -type Cursor struct { - state protoimpl.MessageState `protogen:"open.v1"` - NodeIdToSequenceId map[uint32]uint64 `protobuf:"bytes,1,rep,name=node_id_to_sequence_id,json=nodeIdToSequenceId,proto3" json:"node_id_to_sequence_id,omitempty" protobuf_key:"varint,1,opt,name=key" protobuf_val:"varint,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Cursor) Reset() { - *x = Cursor{} - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Cursor) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Cursor) ProtoMessage() {} - -func (x *Cursor) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Cursor.ProtoReflect.Descriptor instead. -func (*Cursor) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_envelopes_proto_rawDescGZIP(), []int{0} -} - -func (x *Cursor) GetNodeIdToSequenceId() map[uint32]uint64 { - if x != nil { - return x.NodeIdToSequenceId - } - return nil -} - -// Data visible to the server that has been authenticated by the client. -type AuthenticatedData struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Do NOT reuse tag 1 — previously used by target_originator - TargetTopic []byte `protobuf:"bytes,2,opt,name=target_topic,json=targetTopic,proto3" json:"target_topic,omitempty"` - DependsOn *Cursor `protobuf:"bytes,3,opt,name=depends_on,json=dependsOn,proto3" json:"depends_on,omitempty"` // Do NOT reuse tag 4 — previously used by is_commit - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AuthenticatedData) Reset() { - *x = AuthenticatedData{} - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AuthenticatedData) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AuthenticatedData) ProtoMessage() {} - -func (x *AuthenticatedData) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AuthenticatedData.ProtoReflect.Descriptor instead. -func (*AuthenticatedData) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_envelopes_proto_rawDescGZIP(), []int{1} -} - -func (x *AuthenticatedData) GetTargetTopic() []byte { - if x != nil { - return x.TargetTopic - } - return nil -} - -func (x *AuthenticatedData) GetDependsOn() *Cursor { - if x != nil { - return x.DependsOn - } - return nil -} - -type ClientEnvelope struct { - state protoimpl.MessageState `protogen:"open.v1"` - Aad *AuthenticatedData `protobuf:"bytes,1,opt,name=aad,proto3" json:"aad,omitempty"` - // Types that are valid to be assigned to Payload: - // - // *ClientEnvelope_GroupMessage - // *ClientEnvelope_WelcomeMessage - // *ClientEnvelope_UploadKeyPackage - // *ClientEnvelope_IdentityUpdate - // *ClientEnvelope_PayerReport - // *ClientEnvelope_PayerReportAttestation - Payload isClientEnvelope_Payload `protobuf_oneof:"payload"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ClientEnvelope) Reset() { - *x = ClientEnvelope{} - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ClientEnvelope) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ClientEnvelope) ProtoMessage() {} - -func (x *ClientEnvelope) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ClientEnvelope.ProtoReflect.Descriptor instead. -func (*ClientEnvelope) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_envelopes_proto_rawDescGZIP(), []int{2} -} - -func (x *ClientEnvelope) GetAad() *AuthenticatedData { - if x != nil { - return x.Aad - } - return nil -} - -func (x *ClientEnvelope) GetPayload() isClientEnvelope_Payload { - if x != nil { - return x.Payload - } - return nil -} - -func (x *ClientEnvelope) GetGroupMessage() *v1.GroupMessageInput { - if x != nil { - if x, ok := x.Payload.(*ClientEnvelope_GroupMessage); ok { - return x.GroupMessage - } - } - return nil -} - -func (x *ClientEnvelope) GetWelcomeMessage() *v1.WelcomeMessageInput { - if x != nil { - if x, ok := x.Payload.(*ClientEnvelope_WelcomeMessage); ok { - return x.WelcomeMessage - } - } - return nil -} - -func (x *ClientEnvelope) GetUploadKeyPackage() *v1.UploadKeyPackageRequest { - if x != nil { - if x, ok := x.Payload.(*ClientEnvelope_UploadKeyPackage); ok { - return x.UploadKeyPackage - } - } - return nil -} - -func (x *ClientEnvelope) GetIdentityUpdate() *associations.IdentityUpdate { - if x != nil { - if x, ok := x.Payload.(*ClientEnvelope_IdentityUpdate); ok { - return x.IdentityUpdate - } - } - return nil -} - -func (x *ClientEnvelope) GetPayerReport() *PayerReport { - if x != nil { - if x, ok := x.Payload.(*ClientEnvelope_PayerReport); ok { - return x.PayerReport - } - } - return nil -} - -func (x *ClientEnvelope) GetPayerReportAttestation() *PayerReportAttestation { - if x != nil { - if x, ok := x.Payload.(*ClientEnvelope_PayerReportAttestation); ok { - return x.PayerReportAttestation - } - } - return nil -} - -type isClientEnvelope_Payload interface { - isClientEnvelope_Payload() -} - -type ClientEnvelope_GroupMessage struct { - GroupMessage *v1.GroupMessageInput `protobuf:"bytes,2,opt,name=group_message,json=groupMessage,proto3,oneof"` -} - -type ClientEnvelope_WelcomeMessage struct { - WelcomeMessage *v1.WelcomeMessageInput `protobuf:"bytes,3,opt,name=welcome_message,json=welcomeMessage,proto3,oneof"` -} - -type ClientEnvelope_UploadKeyPackage struct { - UploadKeyPackage *v1.UploadKeyPackageRequest `protobuf:"bytes,4,opt,name=upload_key_package,json=uploadKeyPackage,proto3,oneof"` -} - -type ClientEnvelope_IdentityUpdate struct { - IdentityUpdate *associations.IdentityUpdate `protobuf:"bytes,5,opt,name=identity_update,json=identityUpdate,proto3,oneof"` -} - -type ClientEnvelope_PayerReport struct { - PayerReport *PayerReport `protobuf:"bytes,6,opt,name=payer_report,json=payerReport,proto3,oneof"` -} - -type ClientEnvelope_PayerReportAttestation struct { - PayerReportAttestation *PayerReportAttestation `protobuf:"bytes,7,opt,name=payer_report_attestation,json=payerReportAttestation,proto3,oneof"` -} - -func (*ClientEnvelope_GroupMessage) isClientEnvelope_Payload() {} - -func (*ClientEnvelope_WelcomeMessage) isClientEnvelope_Payload() {} - -func (*ClientEnvelope_UploadKeyPackage) isClientEnvelope_Payload() {} - -func (*ClientEnvelope_IdentityUpdate) isClientEnvelope_Payload() {} - -func (*ClientEnvelope_PayerReport) isClientEnvelope_Payload() {} - -func (*ClientEnvelope_PayerReportAttestation) isClientEnvelope_Payload() {} - -// Wraps client envelope with payer signature -type PayerEnvelope struct { - state protoimpl.MessageState `protogen:"open.v1"` - UnsignedClientEnvelope []byte `protobuf:"bytes,1,opt,name=unsigned_client_envelope,json=unsignedClientEnvelope,proto3" json:"unsigned_client_envelope,omitempty"` // Protobuf serialized - PayerSignature *associations.RecoverableEcdsaSignature `protobuf:"bytes,2,opt,name=payer_signature,json=payerSignature,proto3" json:"payer_signature,omitempty"` - TargetOriginator uint32 `protobuf:"varint,3,opt,name=target_originator,json=targetOriginator,proto3" json:"target_originator,omitempty"` - MessageRetentionDays uint32 `protobuf:"varint,4,opt,name=message_retention_days,json=messageRetentionDays,proto3" json:"message_retention_days,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PayerEnvelope) Reset() { - *x = PayerEnvelope{} - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PayerEnvelope) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PayerEnvelope) ProtoMessage() {} - -func (x *PayerEnvelope) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PayerEnvelope.ProtoReflect.Descriptor instead. -func (*PayerEnvelope) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_envelopes_proto_rawDescGZIP(), []int{3} -} - -func (x *PayerEnvelope) GetUnsignedClientEnvelope() []byte { - if x != nil { - return x.UnsignedClientEnvelope - } - return nil -} - -func (x *PayerEnvelope) GetPayerSignature() *associations.RecoverableEcdsaSignature { - if x != nil { - return x.PayerSignature - } - return nil -} - -func (x *PayerEnvelope) GetTargetOriginator() uint32 { - if x != nil { - return x.TargetOriginator - } - return 0 -} - -func (x *PayerEnvelope) GetMessageRetentionDays() uint32 { - if x != nil { - return x.MessageRetentionDays - } - return 0 -} - -// For blockchain envelopes, these fields are set by the smart contract -type UnsignedOriginatorEnvelope struct { - state protoimpl.MessageState `protogen:"open.v1"` - OriginatorNodeId uint32 `protobuf:"varint,1,opt,name=originator_node_id,json=originatorNodeId,proto3" json:"originator_node_id,omitempty"` - OriginatorSequenceId uint64 `protobuf:"varint,2,opt,name=originator_sequence_id,json=originatorSequenceId,proto3" json:"originator_sequence_id,omitempty"` - OriginatorNs int64 `protobuf:"varint,3,opt,name=originator_ns,json=originatorNs,proto3" json:"originator_ns,omitempty"` - PayerEnvelopeBytes []byte `protobuf:"bytes,4,opt,name=payer_envelope_bytes,json=payerEnvelopeBytes,proto3" json:"payer_envelope_bytes,omitempty"` - BaseFeePicodollars uint64 `protobuf:"varint,5,opt,name=base_fee_picodollars,json=baseFeePicodollars,proto3" json:"base_fee_picodollars,omitempty"` // The base fee for the message in picodollars - CongestionFeePicodollars uint64 `protobuf:"varint,6,opt,name=congestion_fee_picodollars,json=congestionFeePicodollars,proto3" json:"congestion_fee_picodollars,omitempty"` // The congestion fee for the message in picodollars - ExpiryUnixtime uint64 `protobuf:"varint,7,opt,name=expiry_unixtime,json=expiryUnixtime,proto3" json:"expiry_unixtime,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UnsignedOriginatorEnvelope) Reset() { - *x = UnsignedOriginatorEnvelope{} - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UnsignedOriginatorEnvelope) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UnsignedOriginatorEnvelope) ProtoMessage() {} - -func (x *UnsignedOriginatorEnvelope) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UnsignedOriginatorEnvelope.ProtoReflect.Descriptor instead. -func (*UnsignedOriginatorEnvelope) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_envelopes_proto_rawDescGZIP(), []int{4} -} - -func (x *UnsignedOriginatorEnvelope) GetOriginatorNodeId() uint32 { - if x != nil { - return x.OriginatorNodeId - } - return 0 -} - -func (x *UnsignedOriginatorEnvelope) GetOriginatorSequenceId() uint64 { - if x != nil { - return x.OriginatorSequenceId - } - return 0 -} - -func (x *UnsignedOriginatorEnvelope) GetOriginatorNs() int64 { - if x != nil { - return x.OriginatorNs - } - return 0 -} - -func (x *UnsignedOriginatorEnvelope) GetPayerEnvelopeBytes() []byte { - if x != nil { - return x.PayerEnvelopeBytes - } - return nil -} - -func (x *UnsignedOriginatorEnvelope) GetBaseFeePicodollars() uint64 { - if x != nil { - return x.BaseFeePicodollars - } - return 0 -} - -func (x *UnsignedOriginatorEnvelope) GetCongestionFeePicodollars() uint64 { - if x != nil { - return x.CongestionFeePicodollars - } - return 0 -} - -func (x *UnsignedOriginatorEnvelope) GetExpiryUnixtime() uint64 { - if x != nil { - return x.ExpiryUnixtime - } - return 0 -} - -// An alternative to a signature for blockchain payloads -type BlockchainProof struct { - state protoimpl.MessageState `protogen:"open.v1"` - TransactionHash []byte `protobuf:"bytes,1,opt,name=transaction_hash,json=transactionHash,proto3" json:"transaction_hash,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BlockchainProof) Reset() { - *x = BlockchainProof{} - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BlockchainProof) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BlockchainProof) ProtoMessage() {} - -func (x *BlockchainProof) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BlockchainProof.ProtoReflect.Descriptor instead. -func (*BlockchainProof) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_envelopes_proto_rawDescGZIP(), []int{5} -} - -func (x *BlockchainProof) GetTransactionHash() []byte { - if x != nil { - return x.TransactionHash - } - return nil -} - -// Signed originator envelope -type OriginatorEnvelope struct { - state protoimpl.MessageState `protogen:"open.v1"` - UnsignedOriginatorEnvelope []byte `protobuf:"bytes,1,opt,name=unsigned_originator_envelope,json=unsignedOriginatorEnvelope,proto3" json:"unsigned_originator_envelope,omitempty"` // Protobuf serialized - // Types that are valid to be assigned to Proof: - // - // *OriginatorEnvelope_OriginatorSignature - // *OriginatorEnvelope_BlockchainProof - Proof isOriginatorEnvelope_Proof `protobuf_oneof:"proof"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *OriginatorEnvelope) Reset() { - *x = OriginatorEnvelope{} - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *OriginatorEnvelope) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*OriginatorEnvelope) ProtoMessage() {} - -func (x *OriginatorEnvelope) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_envelopes_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use OriginatorEnvelope.ProtoReflect.Descriptor instead. -func (*OriginatorEnvelope) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_envelopes_proto_rawDescGZIP(), []int{6} -} - -func (x *OriginatorEnvelope) GetUnsignedOriginatorEnvelope() []byte { - if x != nil { - return x.UnsignedOriginatorEnvelope - } - return nil -} - -func (x *OriginatorEnvelope) GetProof() isOriginatorEnvelope_Proof { - if x != nil { - return x.Proof - } - return nil -} - -func (x *OriginatorEnvelope) GetOriginatorSignature() *associations.RecoverableEcdsaSignature { - if x != nil { - if x, ok := x.Proof.(*OriginatorEnvelope_OriginatorSignature); ok { - return x.OriginatorSignature - } - } - return nil -} - -func (x *OriginatorEnvelope) GetBlockchainProof() *BlockchainProof { - if x != nil { - if x, ok := x.Proof.(*OriginatorEnvelope_BlockchainProof); ok { - return x.BlockchainProof - } - } - return nil -} - -type isOriginatorEnvelope_Proof interface { - isOriginatorEnvelope_Proof() -} - -type OriginatorEnvelope_OriginatorSignature struct { - OriginatorSignature *associations.RecoverableEcdsaSignature `protobuf:"bytes,2,opt,name=originator_signature,json=originatorSignature,proto3,oneof"` -} - -type OriginatorEnvelope_BlockchainProof struct { - BlockchainProof *BlockchainProof `protobuf:"bytes,3,opt,name=blockchain_proof,json=blockchainProof,proto3,oneof"` -} - -func (*OriginatorEnvelope_OriginatorSignature) isOriginatorEnvelope_Proof() {} - -func (*OriginatorEnvelope_BlockchainProof) isOriginatorEnvelope_Proof() {} - -var File_xmtpv4_envelopes_envelopes_proto protoreflect.FileDescriptor - -const file_xmtpv4_envelopes_envelopes_proto_rawDesc = "" + - "\n" + - " xmtpv4/envelopes/envelopes.proto\x12\x15xmtp.xmtpv4.envelopes\x1a'identity/associations/association.proto\x1a%identity/associations/signature.proto\x1a\x14mls/api/v1/mls.proto\x1a#xmtpv4/envelopes/payer_report.proto\"\xba\x01\n" + - "\x06Cursor\x12i\n" + - "\x16node_id_to_sequence_id\x18\x01 \x03(\v25.xmtp.xmtpv4.envelopes.Cursor.NodeIdToSequenceIdEntryR\x12nodeIdToSequenceId\x1aE\n" + - "\x17NodeIdToSequenceIdEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\rR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\x04R\x05value:\x028\x01\"t\n" + - "\x11AuthenticatedData\x12!\n" + - "\ftarget_topic\x18\x02 \x01(\fR\vtargetTopic\x12<\n" + - "\n" + - "depends_on\x18\x03 \x01(\v2\x1d.xmtp.xmtpv4.envelopes.CursorR\tdependsOn\"\xd8\x04\n" + - "\x0eClientEnvelope\x12:\n" + - "\x03aad\x18\x01 \x01(\v2(.xmtp.xmtpv4.envelopes.AuthenticatedDataR\x03aad\x12I\n" + - "\rgroup_message\x18\x02 \x01(\v2\".xmtp.mls.api.v1.GroupMessageInputH\x00R\fgroupMessage\x12O\n" + - "\x0fwelcome_message\x18\x03 \x01(\v2$.xmtp.mls.api.v1.WelcomeMessageInputH\x00R\x0ewelcomeMessage\x12X\n" + - "\x12upload_key_package\x18\x04 \x01(\v2(.xmtp.mls.api.v1.UploadKeyPackageRequestH\x00R\x10uploadKeyPackage\x12U\n" + - "\x0fidentity_update\x18\x05 \x01(\v2*.xmtp.identity.associations.IdentityUpdateH\x00R\x0eidentityUpdate\x12G\n" + - "\fpayer_report\x18\x06 \x01(\v2\".xmtp.xmtpv4.envelopes.PayerReportH\x00R\vpayerReport\x12i\n" + - "\x18payer_report_attestation\x18\a \x01(\v2-.xmtp.xmtpv4.envelopes.PayerReportAttestationH\x00R\x16payerReportAttestationB\t\n" + - "\apayload\"\x8c\x02\n" + - "\rPayerEnvelope\x128\n" + - "\x18unsigned_client_envelope\x18\x01 \x01(\fR\x16unsignedClientEnvelope\x12^\n" + - "\x0fpayer_signature\x18\x02 \x01(\v25.xmtp.identity.associations.RecoverableEcdsaSignatureR\x0epayerSignature\x12+\n" + - "\x11target_originator\x18\x03 \x01(\rR\x10targetOriginator\x124\n" + - "\x16message_retention_days\x18\x04 \x01(\rR\x14messageRetentionDays\"\xf0\x02\n" + - "\x1aUnsignedOriginatorEnvelope\x12,\n" + - "\x12originator_node_id\x18\x01 \x01(\rR\x10originatorNodeId\x124\n" + - "\x16originator_sequence_id\x18\x02 \x01(\x04R\x14originatorSequenceId\x12#\n" + - "\roriginator_ns\x18\x03 \x01(\x03R\foriginatorNs\x120\n" + - "\x14payer_envelope_bytes\x18\x04 \x01(\fR\x12payerEnvelopeBytes\x120\n" + - "\x14base_fee_picodollars\x18\x05 \x01(\x04R\x12baseFeePicodollars\x12<\n" + - "\x1acongestion_fee_picodollars\x18\x06 \x01(\x04R\x18congestionFeePicodollars\x12'\n" + - "\x0fexpiry_unixtime\x18\a \x01(\x04R\x0eexpiryUnixtime\"<\n" + - "\x0fBlockchainProof\x12)\n" + - "\x10transaction_hash\x18\x01 \x01(\fR\x0ftransactionHash\"\xa0\x02\n" + - "\x12OriginatorEnvelope\x12@\n" + - "\x1cunsigned_originator_envelope\x18\x01 \x01(\fR\x1aunsignedOriginatorEnvelope\x12j\n" + - "\x14originator_signature\x18\x02 \x01(\v25.xmtp.identity.associations.RecoverableEcdsaSignatureH\x00R\x13originatorSignature\x12S\n" + - "\x10blockchain_proof\x18\x03 \x01(\v2&.xmtp.xmtpv4.envelopes.BlockchainProofH\x00R\x0fblockchainProofB\a\n" + - "\x05proofB\x86\x02\n" + - "3org.xmtp.android.library.push.xmtp.xmtpv4.envelopesB\x0eEnvelopesProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/envelopes\xa2\x02\x03XXE\xaa\x02\x15Xmtp.Xmtpv4.Envelopes\xca\x02\x15Xmtp\\Xmtpv4\\Envelopes\xe2\x02!Xmtp\\Xmtpv4\\Envelopes\\GPBMetadata\xea\x02\x17Xmtp::Xmtpv4::Envelopesb\x06proto3" - -var ( - file_xmtpv4_envelopes_envelopes_proto_rawDescOnce sync.Once - file_xmtpv4_envelopes_envelopes_proto_rawDescData []byte -) - -func file_xmtpv4_envelopes_envelopes_proto_rawDescGZIP() []byte { - file_xmtpv4_envelopes_envelopes_proto_rawDescOnce.Do(func() { - file_xmtpv4_envelopes_envelopes_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_xmtpv4_envelopes_envelopes_proto_rawDesc), len(file_xmtpv4_envelopes_envelopes_proto_rawDesc))) - }) - return file_xmtpv4_envelopes_envelopes_proto_rawDescData -} - -var file_xmtpv4_envelopes_envelopes_proto_msgTypes = make([]protoimpl.MessageInfo, 8) -var file_xmtpv4_envelopes_envelopes_proto_goTypes = []any{ - (*Cursor)(nil), // 0: xmtp.xmtpv4.envelopes.Cursor - (*AuthenticatedData)(nil), // 1: xmtp.xmtpv4.envelopes.AuthenticatedData - (*ClientEnvelope)(nil), // 2: xmtp.xmtpv4.envelopes.ClientEnvelope - (*PayerEnvelope)(nil), // 3: xmtp.xmtpv4.envelopes.PayerEnvelope - (*UnsignedOriginatorEnvelope)(nil), // 4: xmtp.xmtpv4.envelopes.UnsignedOriginatorEnvelope - (*BlockchainProof)(nil), // 5: xmtp.xmtpv4.envelopes.BlockchainProof - (*OriginatorEnvelope)(nil), // 6: xmtp.xmtpv4.envelopes.OriginatorEnvelope - nil, // 7: xmtp.xmtpv4.envelopes.Cursor.NodeIdToSequenceIdEntry - (*v1.GroupMessageInput)(nil), // 8: xmtp.mls.api.v1.GroupMessageInput - (*v1.WelcomeMessageInput)(nil), // 9: xmtp.mls.api.v1.WelcomeMessageInput - (*v1.UploadKeyPackageRequest)(nil), // 10: xmtp.mls.api.v1.UploadKeyPackageRequest - (*associations.IdentityUpdate)(nil), // 11: xmtp.identity.associations.IdentityUpdate - (*PayerReport)(nil), // 12: xmtp.xmtpv4.envelopes.PayerReport - (*PayerReportAttestation)(nil), // 13: xmtp.xmtpv4.envelopes.PayerReportAttestation - (*associations.RecoverableEcdsaSignature)(nil), // 14: xmtp.identity.associations.RecoverableEcdsaSignature -} -var file_xmtpv4_envelopes_envelopes_proto_depIdxs = []int32{ - 7, // 0: xmtp.xmtpv4.envelopes.Cursor.node_id_to_sequence_id:type_name -> xmtp.xmtpv4.envelopes.Cursor.NodeIdToSequenceIdEntry - 0, // 1: xmtp.xmtpv4.envelopes.AuthenticatedData.depends_on:type_name -> xmtp.xmtpv4.envelopes.Cursor - 1, // 2: xmtp.xmtpv4.envelopes.ClientEnvelope.aad:type_name -> xmtp.xmtpv4.envelopes.AuthenticatedData - 8, // 3: xmtp.xmtpv4.envelopes.ClientEnvelope.group_message:type_name -> xmtp.mls.api.v1.GroupMessageInput - 9, // 4: xmtp.xmtpv4.envelopes.ClientEnvelope.welcome_message:type_name -> xmtp.mls.api.v1.WelcomeMessageInput - 10, // 5: xmtp.xmtpv4.envelopes.ClientEnvelope.upload_key_package:type_name -> xmtp.mls.api.v1.UploadKeyPackageRequest - 11, // 6: xmtp.xmtpv4.envelopes.ClientEnvelope.identity_update:type_name -> xmtp.identity.associations.IdentityUpdate - 12, // 7: xmtp.xmtpv4.envelopes.ClientEnvelope.payer_report:type_name -> xmtp.xmtpv4.envelopes.PayerReport - 13, // 8: xmtp.xmtpv4.envelopes.ClientEnvelope.payer_report_attestation:type_name -> xmtp.xmtpv4.envelopes.PayerReportAttestation - 14, // 9: xmtp.xmtpv4.envelopes.PayerEnvelope.payer_signature:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature - 14, // 10: xmtp.xmtpv4.envelopes.OriginatorEnvelope.originator_signature:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature - 5, // 11: xmtp.xmtpv4.envelopes.OriginatorEnvelope.blockchain_proof:type_name -> xmtp.xmtpv4.envelopes.BlockchainProof - 12, // [12:12] is the sub-list for method output_type - 12, // [12:12] is the sub-list for method input_type - 12, // [12:12] is the sub-list for extension type_name - 12, // [12:12] is the sub-list for extension extendee - 0, // [0:12] is the sub-list for field type_name -} - -func init() { file_xmtpv4_envelopes_envelopes_proto_init() } -func file_xmtpv4_envelopes_envelopes_proto_init() { - if File_xmtpv4_envelopes_envelopes_proto != nil { - return - } - file_xmtpv4_envelopes_payer_report_proto_init() - file_xmtpv4_envelopes_envelopes_proto_msgTypes[2].OneofWrappers = []any{ - (*ClientEnvelope_GroupMessage)(nil), - (*ClientEnvelope_WelcomeMessage)(nil), - (*ClientEnvelope_UploadKeyPackage)(nil), - (*ClientEnvelope_IdentityUpdate)(nil), - (*ClientEnvelope_PayerReport)(nil), - (*ClientEnvelope_PayerReportAttestation)(nil), - } - file_xmtpv4_envelopes_envelopes_proto_msgTypes[6].OneofWrappers = []any{ - (*OriginatorEnvelope_OriginatorSignature)(nil), - (*OriginatorEnvelope_BlockchainProof)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_envelopes_envelopes_proto_rawDesc), len(file_xmtpv4_envelopes_envelopes_proto_rawDesc)), - NumEnums: 0, - NumMessages: 8, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_xmtpv4_envelopes_envelopes_proto_goTypes, - DependencyIndexes: file_xmtpv4_envelopes_envelopes_proto_depIdxs, - MessageInfos: file_xmtpv4_envelopes_envelopes_proto_msgTypes, - }.Build() - File_xmtpv4_envelopes_envelopes_proto = out.File - file_xmtpv4_envelopes_envelopes_proto_goTypes = nil - file_xmtpv4_envelopes_envelopes_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/envelopes/payer_report.pb.go b/pkg/proto/xmtpv4/envelopes/payer_report.pb.go deleted file mode 100644 index a26b9ee1..00000000 --- a/pkg/proto/xmtpv4/envelopes/payer_report.pb.go +++ /dev/null @@ -1,296 +0,0 @@ -// Message API for XMTP V4 - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/envelopes/payer_report.proto - -package envelopes - -import ( - associations "github.com/xmtp/example-notification-server-go/pkg/proto/identity/associations" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// A report of the payers and nodes that sent messages in a given range of messages -type PayerReport struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The originator this report is referring to - OriginatorNodeId uint32 `protobuf:"varint,1,opt,name=originator_node_id,json=originatorNodeId,proto3" json:"originator_node_id,omitempty"` - // The sequence_id that the report starts at [exclusive] - StartSequenceId uint64 `protobuf:"varint,2,opt,name=start_sequence_id,json=startSequenceId,proto3" json:"start_sequence_id,omitempty"` - // The sequence_id that the report ends at [inclusive] - EndSequenceId uint64 `protobuf:"varint,3,opt,name=end_sequence_id,json=endSequenceId,proto3" json:"end_sequence_id,omitempty"` - // The end timestamp of the report - EndMinuteSinceEpoch uint32 `protobuf:"varint,4,opt,name=end_minute_since_epoch,json=endMinuteSinceEpoch,proto3" json:"end_minute_since_epoch,omitempty"` - // The merkle root of the payer balance diff tree - PayersMerkleRoot []byte `protobuf:"bytes,5,opt,name=payers_merkle_root,json=payersMerkleRoot,proto3" json:"payers_merkle_root,omitempty"` - // The node IDs that are active in the network at the time of the report - ActiveNodeIds []uint32 `protobuf:"varint,6,rep,packed,name=active_node_ids,json=activeNodeIds,proto3" json:"active_node_ids,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PayerReport) Reset() { - *x = PayerReport{} - mi := &file_xmtpv4_envelopes_payer_report_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PayerReport) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PayerReport) ProtoMessage() {} - -func (x *PayerReport) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_payer_report_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PayerReport.ProtoReflect.Descriptor instead. -func (*PayerReport) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_payer_report_proto_rawDescGZIP(), []int{0} -} - -func (x *PayerReport) GetOriginatorNodeId() uint32 { - if x != nil { - return x.OriginatorNodeId - } - return 0 -} - -func (x *PayerReport) GetStartSequenceId() uint64 { - if x != nil { - return x.StartSequenceId - } - return 0 -} - -func (x *PayerReport) GetEndSequenceId() uint64 { - if x != nil { - return x.EndSequenceId - } - return 0 -} - -func (x *PayerReport) GetEndMinuteSinceEpoch() uint32 { - if x != nil { - return x.EndMinuteSinceEpoch - } - return 0 -} - -func (x *PayerReport) GetPayersMerkleRoot() []byte { - if x != nil { - return x.PayersMerkleRoot - } - return nil -} - -func (x *PayerReport) GetActiveNodeIds() []uint32 { - if x != nil { - return x.ActiveNodeIds - } - return nil -} - -type NodeSignature struct { - state protoimpl.MessageState `protogen:"open.v1"` - NodeId uint32 `protobuf:"varint,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"` - Signature *associations.RecoverableEcdsaSignature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *NodeSignature) Reset() { - *x = NodeSignature{} - mi := &file_xmtpv4_envelopes_payer_report_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *NodeSignature) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*NodeSignature) ProtoMessage() {} - -func (x *NodeSignature) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_payer_report_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use NodeSignature.ProtoReflect.Descriptor instead. -func (*NodeSignature) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_payer_report_proto_rawDescGZIP(), []int{1} -} - -func (x *NodeSignature) GetNodeId() uint32 { - if x != nil { - return x.NodeId - } - return 0 -} - -func (x *NodeSignature) GetSignature() *associations.RecoverableEcdsaSignature { - if x != nil { - return x.Signature - } - return nil -} - -// An attestation of a payer report -type PayerReportAttestation struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The ID of the report, determined by hashing the report contents - ReportId []byte `protobuf:"bytes,1,opt,name=report_id,json=reportId,proto3" json:"report_id,omitempty"` - // The signature of the attester - Signature *NodeSignature `protobuf:"bytes,2,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PayerReportAttestation) Reset() { - *x = PayerReportAttestation{} - mi := &file_xmtpv4_envelopes_payer_report_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PayerReportAttestation) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PayerReportAttestation) ProtoMessage() {} - -func (x *PayerReportAttestation) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_envelopes_payer_report_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PayerReportAttestation.ProtoReflect.Descriptor instead. -func (*PayerReportAttestation) Descriptor() ([]byte, []int) { - return file_xmtpv4_envelopes_payer_report_proto_rawDescGZIP(), []int{2} -} - -func (x *PayerReportAttestation) GetReportId() []byte { - if x != nil { - return x.ReportId - } - return nil -} - -func (x *PayerReportAttestation) GetSignature() *NodeSignature { - if x != nil { - return x.Signature - } - return nil -} - -var File_xmtpv4_envelopes_payer_report_proto protoreflect.FileDescriptor - -const file_xmtpv4_envelopes_payer_report_proto_rawDesc = "" + - "\n" + - "#xmtpv4/envelopes/payer_report.proto\x12\x15xmtp.xmtpv4.envelopes\x1a%identity/associations/signature.proto\"\x9a\x02\n" + - "\vPayerReport\x12,\n" + - "\x12originator_node_id\x18\x01 \x01(\rR\x10originatorNodeId\x12*\n" + - "\x11start_sequence_id\x18\x02 \x01(\x04R\x0fstartSequenceId\x12&\n" + - "\x0fend_sequence_id\x18\x03 \x01(\x04R\rendSequenceId\x123\n" + - "\x16end_minute_since_epoch\x18\x04 \x01(\rR\x13endMinuteSinceEpoch\x12,\n" + - "\x12payers_merkle_root\x18\x05 \x01(\fR\x10payersMerkleRoot\x12&\n" + - "\x0factive_node_ids\x18\x06 \x03(\rR\ractiveNodeIds\"}\n" + - "\rNodeSignature\x12\x17\n" + - "\anode_id\x18\x01 \x01(\rR\x06nodeId\x12S\n" + - "\tsignature\x18\x02 \x01(\v25.xmtp.identity.associations.RecoverableEcdsaSignatureR\tsignature\"y\n" + - "\x16PayerReportAttestation\x12\x1b\n" + - "\treport_id\x18\x01 \x01(\fR\breportId\x12B\n" + - "\tsignature\x18\x02 \x01(\v2$.xmtp.xmtpv4.envelopes.NodeSignatureR\tsignatureB\x88\x02\n" + - "3org.xmtp.android.library.push.xmtp.xmtpv4.envelopesB\x10PayerReportProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/envelopes\xa2\x02\x03XXE\xaa\x02\x15Xmtp.Xmtpv4.Envelopes\xca\x02\x15Xmtp\\Xmtpv4\\Envelopes\xe2\x02!Xmtp\\Xmtpv4\\Envelopes\\GPBMetadata\xea\x02\x17Xmtp::Xmtpv4::Envelopesb\x06proto3" - -var ( - file_xmtpv4_envelopes_payer_report_proto_rawDescOnce sync.Once - file_xmtpv4_envelopes_payer_report_proto_rawDescData []byte -) - -func file_xmtpv4_envelopes_payer_report_proto_rawDescGZIP() []byte { - file_xmtpv4_envelopes_payer_report_proto_rawDescOnce.Do(func() { - file_xmtpv4_envelopes_payer_report_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_xmtpv4_envelopes_payer_report_proto_rawDesc), len(file_xmtpv4_envelopes_payer_report_proto_rawDesc))) - }) - return file_xmtpv4_envelopes_payer_report_proto_rawDescData -} - -var file_xmtpv4_envelopes_payer_report_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_xmtpv4_envelopes_payer_report_proto_goTypes = []any{ - (*PayerReport)(nil), // 0: xmtp.xmtpv4.envelopes.PayerReport - (*NodeSignature)(nil), // 1: xmtp.xmtpv4.envelopes.NodeSignature - (*PayerReportAttestation)(nil), // 2: xmtp.xmtpv4.envelopes.PayerReportAttestation - (*associations.RecoverableEcdsaSignature)(nil), // 3: xmtp.identity.associations.RecoverableEcdsaSignature -} -var file_xmtpv4_envelopes_payer_report_proto_depIdxs = []int32{ - 3, // 0: xmtp.xmtpv4.envelopes.NodeSignature.signature:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature - 1, // 1: xmtp.xmtpv4.envelopes.PayerReportAttestation.signature:type_name -> xmtp.xmtpv4.envelopes.NodeSignature - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name -} - -func init() { file_xmtpv4_envelopes_payer_report_proto_init() } -func file_xmtpv4_envelopes_payer_report_proto_init() { - if File_xmtpv4_envelopes_payer_report_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_envelopes_payer_report_proto_rawDesc), len(file_xmtpv4_envelopes_payer_report_proto_rawDesc)), - NumEnums: 0, - NumMessages: 3, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_xmtpv4_envelopes_payer_report_proto_goTypes, - DependencyIndexes: file_xmtpv4_envelopes_payer_report_proto_depIdxs, - MessageInfos: file_xmtpv4_envelopes_payer_report_proto_msgTypes, - }.Build() - File_xmtpv4_envelopes_payer_report_proto = out.File - file_xmtpv4_envelopes_payer_report_proto_goTypes = nil - file_xmtpv4_envelopes_payer_report_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/gateway_api/gateway_api.pb.go b/pkg/proto/xmtpv4/gateway_api/gateway_api.pb.go deleted file mode 100644 index 226ef8d4..00000000 --- a/pkg/proto/xmtpv4/gateway_api/gateway_api.pb.go +++ /dev/null @@ -1,76 +0,0 @@ -// Gateway API - Client to Gateway requests - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/gateway_api/gateway_api.proto - -package gateway_api - -import ( - payer_api "github.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/payer_api" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -var File_xmtpv4_gateway_api_gateway_api_proto protoreflect.FileDescriptor - -const file_xmtpv4_gateway_api_gateway_api_proto_rawDesc = "" + - "\n" + - "$xmtpv4/gateway_api/gateway_api.proto\x12\x17xmtp.xmtpv4.gateway_api\x1a xmtpv4/payer_api/payer_api.proto2\xf5\x01\n" + - "\n" + - "GatewayApi\x12\x87\x01\n" + - "\x16PublishClientEnvelopes\x124.xmtp.xmtpv4.payer_api.PublishClientEnvelopesRequest\x1a5.xmtp.xmtpv4.payer_api.PublishClientEnvelopesResponse\"\x00\x12]\n" + - "\bGetNodes\x12&.xmtp.xmtpv4.payer_api.GetNodesRequest\x1a'.xmtp.xmtpv4.payer_api.GetNodesResponse\"\x00B\x8f\x02\n" + - "5org.xmtp.android.library.push.xmtp.xmtpv4.gateway_apiB\x0fGatewayApiProtoP\x01ZKgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/gateway_api\xa2\x02\x03XXG\xaa\x02\x16Xmtp.Xmtpv4.GatewayApi\xca\x02\x16Xmtp\\Xmtpv4\\GatewayApi\xe2\x02\"Xmtp\\Xmtpv4\\GatewayApi\\GPBMetadata\xea\x02\x18Xmtp::Xmtpv4::GatewayApib\x06proto3" - -var file_xmtpv4_gateway_api_gateway_api_proto_goTypes = []any{ - (*payer_api.PublishClientEnvelopesRequest)(nil), // 0: xmtp.xmtpv4.payer_api.PublishClientEnvelopesRequest - (*payer_api.GetNodesRequest)(nil), // 1: xmtp.xmtpv4.payer_api.GetNodesRequest - (*payer_api.PublishClientEnvelopesResponse)(nil), // 2: xmtp.xmtpv4.payer_api.PublishClientEnvelopesResponse - (*payer_api.GetNodesResponse)(nil), // 3: xmtp.xmtpv4.payer_api.GetNodesResponse -} -var file_xmtpv4_gateway_api_gateway_api_proto_depIdxs = []int32{ - 0, // 0: xmtp.xmtpv4.gateway_api.GatewayApi.PublishClientEnvelopes:input_type -> xmtp.xmtpv4.payer_api.PublishClientEnvelopesRequest - 1, // 1: xmtp.xmtpv4.gateway_api.GatewayApi.GetNodes:input_type -> xmtp.xmtpv4.payer_api.GetNodesRequest - 2, // 2: xmtp.xmtpv4.gateway_api.GatewayApi.PublishClientEnvelopes:output_type -> xmtp.xmtpv4.payer_api.PublishClientEnvelopesResponse - 3, // 3: xmtp.xmtpv4.gateway_api.GatewayApi.GetNodes:output_type -> xmtp.xmtpv4.payer_api.GetNodesResponse - 2, // [2:4] is the sub-list for method output_type - 0, // [0:2] 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_xmtpv4_gateway_api_gateway_api_proto_init() } -func file_xmtpv4_gateway_api_gateway_api_proto_init() { - if File_xmtpv4_gateway_api_gateway_api_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_gateway_api_gateway_api_proto_rawDesc), len(file_xmtpv4_gateway_api_gateway_api_proto_rawDesc)), - NumEnums: 0, - NumMessages: 0, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_xmtpv4_gateway_api_gateway_api_proto_goTypes, - DependencyIndexes: file_xmtpv4_gateway_api_gateway_api_proto_depIdxs, - }.Build() - File_xmtpv4_gateway_api_gateway_api_proto = out.File - file_xmtpv4_gateway_api_gateway_api_proto_goTypes = nil - file_xmtpv4_gateway_api_gateway_api_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/gateway_api/gateway_api_grpc.pb.go b/pkg/proto/xmtpv4/gateway_api/gateway_api_grpc.pb.go deleted file mode 100644 index bed81443..00000000 --- a/pkg/proto/xmtpv4/gateway_api/gateway_api_grpc.pb.go +++ /dev/null @@ -1,149 +0,0 @@ -// Gateway API - Client to Gateway requests - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: xmtpv4/gateway_api/gateway_api.proto - -package gateway_api - -import ( - context "context" - payer_api "github.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/payer_api" - 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 ( - GatewayApi_PublishClientEnvelopes_FullMethodName = "/xmtp.xmtpv4.gateway_api.GatewayApi/PublishClientEnvelopes" - GatewayApi_GetNodes_FullMethodName = "/xmtp.xmtpv4.gateway_api.GatewayApi/GetNodes" -) - -// GatewayApiClient is the client API for GatewayApi 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 GatewayApiClient interface { - PublishClientEnvelopes(ctx context.Context, in *payer_api.PublishClientEnvelopesRequest, opts ...grpc.CallOption) (*payer_api.PublishClientEnvelopesResponse, error) - GetNodes(ctx context.Context, in *payer_api.GetNodesRequest, opts ...grpc.CallOption) (*payer_api.GetNodesResponse, error) -} - -type gatewayApiClient struct { - cc grpc.ClientConnInterface -} - -func NewGatewayApiClient(cc grpc.ClientConnInterface) GatewayApiClient { - return &gatewayApiClient{cc} -} - -func (c *gatewayApiClient) PublishClientEnvelopes(ctx context.Context, in *payer_api.PublishClientEnvelopesRequest, opts ...grpc.CallOption) (*payer_api.PublishClientEnvelopesResponse, error) { - out := new(payer_api.PublishClientEnvelopesResponse) - err := c.cc.Invoke(ctx, GatewayApi_PublishClientEnvelopes_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *gatewayApiClient) GetNodes(ctx context.Context, in *payer_api.GetNodesRequest, opts ...grpc.CallOption) (*payer_api.GetNodesResponse, error) { - out := new(payer_api.GetNodesResponse) - err := c.cc.Invoke(ctx, GatewayApi_GetNodes_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// GatewayApiServer is the server API for GatewayApi service. -// All implementations must embed UnimplementedGatewayApiServer -// for forward compatibility -type GatewayApiServer interface { - PublishClientEnvelopes(context.Context, *payer_api.PublishClientEnvelopesRequest) (*payer_api.PublishClientEnvelopesResponse, error) - GetNodes(context.Context, *payer_api.GetNodesRequest) (*payer_api.GetNodesResponse, error) - mustEmbedUnimplementedGatewayApiServer() -} - -// UnimplementedGatewayApiServer must be embedded to have forward compatible implementations. -type UnimplementedGatewayApiServer struct { -} - -func (UnimplementedGatewayApiServer) PublishClientEnvelopes(context.Context, *payer_api.PublishClientEnvelopesRequest) (*payer_api.PublishClientEnvelopesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method PublishClientEnvelopes not implemented") -} -func (UnimplementedGatewayApiServer) GetNodes(context.Context, *payer_api.GetNodesRequest) (*payer_api.GetNodesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetNodes not implemented") -} -func (UnimplementedGatewayApiServer) mustEmbedUnimplementedGatewayApiServer() {} - -// UnsafeGatewayApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to GatewayApiServer will -// result in compilation errors. -type UnsafeGatewayApiServer interface { - mustEmbedUnimplementedGatewayApiServer() -} - -func RegisterGatewayApiServer(s grpc.ServiceRegistrar, srv GatewayApiServer) { - s.RegisterService(&GatewayApi_ServiceDesc, srv) -} - -func _GatewayApi_PublishClientEnvelopes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(payer_api.PublishClientEnvelopesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(GatewayApiServer).PublishClientEnvelopes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: GatewayApi_PublishClientEnvelopes_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(GatewayApiServer).PublishClientEnvelopes(ctx, req.(*payer_api.PublishClientEnvelopesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _GatewayApi_GetNodes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(payer_api.GetNodesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(GatewayApiServer).GetNodes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: GatewayApi_GetNodes_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(GatewayApiServer).GetNodes(ctx, req.(*payer_api.GetNodesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// GatewayApi_ServiceDesc is the grpc.ServiceDesc for GatewayApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var GatewayApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.xmtpv4.gateway_api.GatewayApi", - HandlerType: (*GatewayApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "PublishClientEnvelopes", - Handler: _GatewayApi_PublishClientEnvelopes_Handler, - }, - { - MethodName: "GetNodes", - Handler: _GatewayApi_GetNodes_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "xmtpv4/gateway_api/gateway_api.proto", -} diff --git a/pkg/proto/xmtpv4/message_api/message_api.pb.go b/pkg/proto/xmtpv4/message_api/message_api.pb.go deleted file mode 100644 index a7586850..00000000 --- a/pkg/proto/xmtpv4/message_api/message_api.pb.go +++ /dev/null @@ -1,1480 +0,0 @@ -// Message API for XMTP V4 - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/message_api/message_api.proto - -package message_api - -import ( - associations "github.com/xmtp/example-notification-server-go/pkg/proto/identity/associations" - envelopes "github.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/envelopes" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type SubscribeTopicsResponse_SubscriptionStatus int32 - -const ( - SubscribeTopicsResponse_SUBSCRIPTION_STATUS_UNSPECIFIED SubscribeTopicsResponse_SubscriptionStatus = 0 - SubscribeTopicsResponse_SUBSCRIPTION_STATUS_STARTED SubscribeTopicsResponse_SubscriptionStatus = 1 - SubscribeTopicsResponse_SUBSCRIPTION_STATUS_CATCHUP_COMPLETE SubscribeTopicsResponse_SubscriptionStatus = 2 - SubscribeTopicsResponse_SUBSCRIPTION_STATUS_WAITING SubscribeTopicsResponse_SubscriptionStatus = 3 -) - -// Enum value maps for SubscribeTopicsResponse_SubscriptionStatus. -var ( - SubscribeTopicsResponse_SubscriptionStatus_name = map[int32]string{ - 0: "SUBSCRIPTION_STATUS_UNSPECIFIED", - 1: "SUBSCRIPTION_STATUS_STARTED", - 2: "SUBSCRIPTION_STATUS_CATCHUP_COMPLETE", - 3: "SUBSCRIPTION_STATUS_WAITING", - } - SubscribeTopicsResponse_SubscriptionStatus_value = map[string]int32{ - "SUBSCRIPTION_STATUS_UNSPECIFIED": 0, - "SUBSCRIPTION_STATUS_STARTED": 1, - "SUBSCRIPTION_STATUS_CATCHUP_COMPLETE": 2, - "SUBSCRIPTION_STATUS_WAITING": 3, - } -) - -func (x SubscribeTopicsResponse_SubscriptionStatus) Enum() *SubscribeTopicsResponse_SubscriptionStatus { - p := new(SubscribeTopicsResponse_SubscriptionStatus) - *p = x - return p -} - -func (x SubscribeTopicsResponse_SubscriptionStatus) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (SubscribeTopicsResponse_SubscriptionStatus) Descriptor() protoreflect.EnumDescriptor { - return file_xmtpv4_message_api_message_api_proto_enumTypes[0].Descriptor() -} - -func (SubscribeTopicsResponse_SubscriptionStatus) Type() protoreflect.EnumType { - return &file_xmtpv4_message_api_message_api_proto_enumTypes[0] -} - -func (x SubscribeTopicsResponse_SubscriptionStatus) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use SubscribeTopicsResponse_SubscriptionStatus.Descriptor instead. -func (SubscribeTopicsResponse_SubscriptionStatus) EnumDescriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{3, 0} -} - -// Query for envelopes, shared by query and subscribe endpoints -// Either topics or originator_node_ids may be set, but not both -type EnvelopesQuery struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Client queries - Topics [][]byte `protobuf:"bytes,1,rep,name=topics,proto3" json:"topics,omitempty"` - // Node queries - OriginatorNodeIds []uint32 `protobuf:"varint,2,rep,packed,name=originator_node_ids,json=originatorNodeIds,proto3" json:"originator_node_ids,omitempty"` - LastSeen *envelopes.Cursor `protobuf:"bytes,3,opt,name=last_seen,json=lastSeen,proto3" json:"last_seen,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *EnvelopesQuery) Reset() { - *x = EnvelopesQuery{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *EnvelopesQuery) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*EnvelopesQuery) ProtoMessage() {} - -func (x *EnvelopesQuery) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use EnvelopesQuery.ProtoReflect.Descriptor instead. -func (*EnvelopesQuery) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{0} -} - -func (x *EnvelopesQuery) GetTopics() [][]byte { - if x != nil { - return x.Topics - } - return nil -} - -func (x *EnvelopesQuery) GetOriginatorNodeIds() []uint32 { - if x != nil { - return x.OriginatorNodeIds - } - return nil -} - -func (x *EnvelopesQuery) GetLastSeen() *envelopes.Cursor { - if x != nil { - return x.LastSeen - } - return nil -} - -// Batch subscribe to envelopes -type SubscribeEnvelopesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Query *EnvelopesQuery `protobuf:"bytes,1,opt,name=query,proto3" json:"query,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeEnvelopesRequest) Reset() { - *x = SubscribeEnvelopesRequest{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeEnvelopesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeEnvelopesRequest) ProtoMessage() {} - -func (x *SubscribeEnvelopesRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeEnvelopesRequest.ProtoReflect.Descriptor instead. -func (*SubscribeEnvelopesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{1} -} - -func (x *SubscribeEnvelopesRequest) GetQuery() *EnvelopesQuery { - if x != nil { - return x.Query - } - return nil -} - -// Request to subscribe to a series of topics, with a separate cursor for each topic -type SubscribeTopicsRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Filters []*SubscribeTopicsRequest_TopicFilter `protobuf:"bytes,1,rep,name=filters,proto3" json:"filters,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeTopicsRequest) Reset() { - *x = SubscribeTopicsRequest{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeTopicsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeTopicsRequest) ProtoMessage() {} - -func (x *SubscribeTopicsRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeTopicsRequest.ProtoReflect.Descriptor instead. -func (*SubscribeTopicsRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{2} -} - -func (x *SubscribeTopicsRequest) GetFilters() []*SubscribeTopicsRequest_TopicFilter { - if x != nil { - return x.Filters - } - return nil -} - -// Response to SubscribeTopics -type SubscribeTopicsResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Response: - // - // *SubscribeTopicsResponse_Envelopes_ - // *SubscribeTopicsResponse_StatusUpdate_ - Response isSubscribeTopicsResponse_Response `protobuf_oneof:"response"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeTopicsResponse) Reset() { - *x = SubscribeTopicsResponse{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeTopicsResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeTopicsResponse) ProtoMessage() {} - -func (x *SubscribeTopicsResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeTopicsResponse.ProtoReflect.Descriptor instead. -func (*SubscribeTopicsResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{3} -} - -func (x *SubscribeTopicsResponse) GetResponse() isSubscribeTopicsResponse_Response { - if x != nil { - return x.Response - } - return nil -} - -func (x *SubscribeTopicsResponse) GetEnvelopes() *SubscribeTopicsResponse_Envelopes { - if x != nil { - if x, ok := x.Response.(*SubscribeTopicsResponse_Envelopes_); ok { - return x.Envelopes - } - } - return nil -} - -func (x *SubscribeTopicsResponse) GetStatusUpdate() *SubscribeTopicsResponse_StatusUpdate { - if x != nil { - if x, ok := x.Response.(*SubscribeTopicsResponse_StatusUpdate_); ok { - return x.StatusUpdate - } - } - return nil -} - -type isSubscribeTopicsResponse_Response interface { - isSubscribeTopicsResponse_Response() -} - -type SubscribeTopicsResponse_Envelopes_ struct { - Envelopes *SubscribeTopicsResponse_Envelopes `protobuf:"bytes,1,opt,name=envelopes,proto3,oneof"` -} - -type SubscribeTopicsResponse_StatusUpdate_ struct { - StatusUpdate *SubscribeTopicsResponse_StatusUpdate `protobuf:"bytes,2,opt,name=status_update,json=statusUpdate,proto3,oneof"` -} - -func (*SubscribeTopicsResponse_Envelopes_) isSubscribeTopicsResponse_Response() {} - -func (*SubscribeTopicsResponse_StatusUpdate_) isSubscribeTopicsResponse_Response() {} - -// Streamed response for batch subscribe - can be multiple envelopes at once -type SubscribeEnvelopesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Envelopes []*envelopes.OriginatorEnvelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeEnvelopesResponse) Reset() { - *x = SubscribeEnvelopesResponse{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeEnvelopesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeEnvelopesResponse) ProtoMessage() {} - -func (x *SubscribeEnvelopesResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeEnvelopesResponse.ProtoReflect.Descriptor instead. -func (*SubscribeEnvelopesResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{4} -} - -func (x *SubscribeEnvelopesResponse) GetEnvelopes() []*envelopes.OriginatorEnvelope { - if x != nil { - return x.Envelopes - } - return nil -} - -// Batch subscribe to all envelopes -type SubscribeAllEnvelopesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeAllEnvelopesRequest) Reset() { - *x = SubscribeAllEnvelopesRequest{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeAllEnvelopesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeAllEnvelopesRequest) ProtoMessage() {} - -func (x *SubscribeAllEnvelopesRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeAllEnvelopesRequest.ProtoReflect.Descriptor instead. -func (*SubscribeAllEnvelopesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{5} -} - -// Query envelopes request -type QueryEnvelopesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Query *EnvelopesQuery `protobuf:"bytes,1,opt,name=query,proto3" json:"query,omitempty"` - Limit uint32 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryEnvelopesRequest) Reset() { - *x = QueryEnvelopesRequest{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryEnvelopesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryEnvelopesRequest) ProtoMessage() {} - -func (x *QueryEnvelopesRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryEnvelopesRequest.ProtoReflect.Descriptor instead. -func (*QueryEnvelopesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{6} -} - -func (x *QueryEnvelopesRequest) GetQuery() *EnvelopesQuery { - if x != nil { - return x.Query - } - return nil -} - -func (x *QueryEnvelopesRequest) GetLimit() uint32 { - if x != nil { - return x.Limit - } - return 0 -} - -// Query envelopes response -type QueryEnvelopesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Envelopes []*envelopes.OriginatorEnvelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryEnvelopesResponse) Reset() { - *x = QueryEnvelopesResponse{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryEnvelopesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryEnvelopesResponse) ProtoMessage() {} - -func (x *QueryEnvelopesResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryEnvelopesResponse.ProtoReflect.Descriptor instead. -func (*QueryEnvelopesResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{7} -} - -func (x *QueryEnvelopesResponse) GetEnvelopes() []*envelopes.OriginatorEnvelope { - if x != nil { - return x.Envelopes - } - return nil -} - -type PublishPayerEnvelopesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - PayerEnvelopes []*envelopes.PayerEnvelope `protobuf:"bytes,1,rep,name=payer_envelopes,json=payerEnvelopes,proto3" json:"payer_envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishPayerEnvelopesRequest) Reset() { - *x = PublishPayerEnvelopesRequest{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishPayerEnvelopesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishPayerEnvelopesRequest) ProtoMessage() {} - -func (x *PublishPayerEnvelopesRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishPayerEnvelopesRequest.ProtoReflect.Descriptor instead. -func (*PublishPayerEnvelopesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{8} -} - -func (x *PublishPayerEnvelopesRequest) GetPayerEnvelopes() []*envelopes.PayerEnvelope { - if x != nil { - return x.PayerEnvelopes - } - return nil -} - -type PublishPayerEnvelopesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - OriginatorEnvelopes []*envelopes.OriginatorEnvelope `protobuf:"bytes,1,rep,name=originator_envelopes,json=originatorEnvelopes,proto3" json:"originator_envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishPayerEnvelopesResponse) Reset() { - *x = PublishPayerEnvelopesResponse{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishPayerEnvelopesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishPayerEnvelopesResponse) ProtoMessage() {} - -func (x *PublishPayerEnvelopesResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishPayerEnvelopesResponse.ProtoReflect.Descriptor instead. -func (*PublishPayerEnvelopesResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{9} -} - -func (x *PublishPayerEnvelopesResponse) GetOriginatorEnvelopes() []*envelopes.OriginatorEnvelope { - if x != nil { - return x.OriginatorEnvelopes - } - return nil -} - -// Request to retrieve the XIDs for the given addresses -type GetInboxIdsRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Requests []*GetInboxIdsRequest_Request `protobuf:"bytes,1,rep,name=requests,proto3" json:"requests,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetInboxIdsRequest) Reset() { - *x = GetInboxIdsRequest{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetInboxIdsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetInboxIdsRequest) ProtoMessage() {} - -func (x *GetInboxIdsRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetInboxIdsRequest.ProtoReflect.Descriptor instead. -func (*GetInboxIdsRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{10} -} - -func (x *GetInboxIdsRequest) GetRequests() []*GetInboxIdsRequest_Request { - if x != nil { - return x.Requests - } - return nil -} - -// Response with the XIDs for the requested addresses -type GetInboxIdsResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Responses []*GetInboxIdsResponse_Response `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetInboxIdsResponse) Reset() { - *x = GetInboxIdsResponse{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetInboxIdsResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetInboxIdsResponse) ProtoMessage() {} - -func (x *GetInboxIdsResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetInboxIdsResponse.ProtoReflect.Descriptor instead. -func (*GetInboxIdsResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{11} -} - -func (x *GetInboxIdsResponse) GetResponses() []*GetInboxIdsResponse_Response { - if x != nil { - return x.Responses - } - return nil -} - -// Request to get the newest envelope for a given topic -type GetNewestEnvelopeRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Topics [][]byte `protobuf:"bytes,1,rep,name=topics,proto3" json:"topics,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetNewestEnvelopeRequest) Reset() { - *x = GetNewestEnvelopeRequest{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetNewestEnvelopeRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetNewestEnvelopeRequest) ProtoMessage() {} - -func (x *GetNewestEnvelopeRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[12] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetNewestEnvelopeRequest.ProtoReflect.Descriptor instead. -func (*GetNewestEnvelopeRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{12} -} - -func (x *GetNewestEnvelopeRequest) GetTopics() [][]byte { - if x != nil { - return x.Topics - } - return nil -} - -// Response to GetNewestEnvelopeRequest -type GetNewestEnvelopeResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - // The newest envelope for the given topic OR null if there are no envelopes on the topic - Results []*GetNewestEnvelopeResponse_Response `protobuf:"bytes,1,rep,name=results,proto3" json:"results,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetNewestEnvelopeResponse) Reset() { - *x = GetNewestEnvelopeResponse{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetNewestEnvelopeResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetNewestEnvelopeResponse) ProtoMessage() {} - -func (x *GetNewestEnvelopeResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[13] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetNewestEnvelopeResponse.ProtoReflect.Descriptor instead. -func (*GetNewestEnvelopeResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{13} -} - -func (x *GetNewestEnvelopeResponse) GetResults() []*GetNewestEnvelopeResponse_Response { - if x != nil { - return x.Results - } - return nil -} - -// Subscribe to envelopes from specific originator nodes -type SubscribeOriginatorsRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Filter *SubscribeOriginatorsRequest_OriginatorFilter `protobuf:"bytes,1,opt,name=filter,proto3" json:"filter,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeOriginatorsRequest) Reset() { - *x = SubscribeOriginatorsRequest{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeOriginatorsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeOriginatorsRequest) ProtoMessage() {} - -func (x *SubscribeOriginatorsRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[14] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeOriginatorsRequest.ProtoReflect.Descriptor instead. -func (*SubscribeOriginatorsRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{14} -} - -func (x *SubscribeOriginatorsRequest) GetFilter() *SubscribeOriginatorsRequest_OriginatorFilter { - if x != nil { - return x.Filter - } - return nil -} - -// Response for SubscribeOriginators -type SubscribeOriginatorsResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Types that are valid to be assigned to Response: - // - // *SubscribeOriginatorsResponse_Envelopes_ - Response isSubscribeOriginatorsResponse_Response `protobuf_oneof:"response"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeOriginatorsResponse) Reset() { - *x = SubscribeOriginatorsResponse{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeOriginatorsResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeOriginatorsResponse) ProtoMessage() {} - -func (x *SubscribeOriginatorsResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[15] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeOriginatorsResponse.ProtoReflect.Descriptor instead. -func (*SubscribeOriginatorsResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{15} -} - -func (x *SubscribeOriginatorsResponse) GetResponse() isSubscribeOriginatorsResponse_Response { - if x != nil { - return x.Response - } - return nil -} - -func (x *SubscribeOriginatorsResponse) GetEnvelopes() *SubscribeOriginatorsResponse_Envelopes { - if x != nil { - if x, ok := x.Response.(*SubscribeOriginatorsResponse_Envelopes_); ok { - return x.Envelopes - } - } - return nil -} - -type isSubscribeOriginatorsResponse_Response interface { - isSubscribeOriginatorsResponse_Response() -} - -type SubscribeOriginatorsResponse_Envelopes_ struct { - Envelopes *SubscribeOriginatorsResponse_Envelopes `protobuf:"bytes,1,opt,name=envelopes,proto3,oneof"` -} - -func (*SubscribeOriginatorsResponse_Envelopes_) isSubscribeOriginatorsResponse_Response() {} - -type SubscribeTopicsRequest_TopicFilter struct { - state protoimpl.MessageState `protogen:"open.v1"` - Topic []byte `protobuf:"bytes,1,opt,name=topic,proto3" json:"topic,omitempty"` - LastSeen *envelopes.Cursor `protobuf:"bytes,2,opt,name=last_seen,json=lastSeen,proto3" json:"last_seen,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeTopicsRequest_TopicFilter) Reset() { - *x = SubscribeTopicsRequest_TopicFilter{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeTopicsRequest_TopicFilter) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeTopicsRequest_TopicFilter) ProtoMessage() {} - -func (x *SubscribeTopicsRequest_TopicFilter) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[16] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeTopicsRequest_TopicFilter.ProtoReflect.Descriptor instead. -func (*SubscribeTopicsRequest_TopicFilter) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{2, 0} -} - -func (x *SubscribeTopicsRequest_TopicFilter) GetTopic() []byte { - if x != nil { - return x.Topic - } - return nil -} - -func (x *SubscribeTopicsRequest_TopicFilter) GetLastSeen() *envelopes.Cursor { - if x != nil { - return x.LastSeen - } - return nil -} - -type SubscribeTopicsResponse_StatusUpdate struct { - state protoimpl.MessageState `protogen:"open.v1"` - Status SubscribeTopicsResponse_SubscriptionStatus `protobuf:"varint,1,opt,name=status,proto3,enum=xmtp.xmtpv4.message_api.SubscribeTopicsResponse_SubscriptionStatus" json:"status,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeTopicsResponse_StatusUpdate) Reset() { - *x = SubscribeTopicsResponse_StatusUpdate{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeTopicsResponse_StatusUpdate) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeTopicsResponse_StatusUpdate) ProtoMessage() {} - -func (x *SubscribeTopicsResponse_StatusUpdate) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[17] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeTopicsResponse_StatusUpdate.ProtoReflect.Descriptor instead. -func (*SubscribeTopicsResponse_StatusUpdate) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{3, 0} -} - -func (x *SubscribeTopicsResponse_StatusUpdate) GetStatus() SubscribeTopicsResponse_SubscriptionStatus { - if x != nil { - return x.Status - } - return SubscribeTopicsResponse_SUBSCRIPTION_STATUS_UNSPECIFIED -} - -type SubscribeTopicsResponse_Envelopes struct { - state protoimpl.MessageState `protogen:"open.v1"` - Envelopes []*envelopes.OriginatorEnvelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeTopicsResponse_Envelopes) Reset() { - *x = SubscribeTopicsResponse_Envelopes{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeTopicsResponse_Envelopes) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeTopicsResponse_Envelopes) ProtoMessage() {} - -func (x *SubscribeTopicsResponse_Envelopes) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[18] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeTopicsResponse_Envelopes.ProtoReflect.Descriptor instead. -func (*SubscribeTopicsResponse_Envelopes) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{3, 1} -} - -func (x *SubscribeTopicsResponse_Envelopes) GetEnvelopes() []*envelopes.OriginatorEnvelope { - if x != nil { - return x.Envelopes - } - return nil -} - -// A single request for a given address -type GetInboxIdsRequest_Request struct { - state protoimpl.MessageState `protogen:"open.v1"` - Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"` - IdentifierKind associations.IdentifierKind `protobuf:"varint,2,opt,name=identifier_kind,json=identifierKind,proto3,enum=xmtp.identity.associations.IdentifierKind" json:"identifier_kind,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetInboxIdsRequest_Request) Reset() { - *x = GetInboxIdsRequest_Request{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetInboxIdsRequest_Request) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetInboxIdsRequest_Request) ProtoMessage() {} - -func (x *GetInboxIdsRequest_Request) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[19] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetInboxIdsRequest_Request.ProtoReflect.Descriptor instead. -func (*GetInboxIdsRequest_Request) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{10, 0} -} - -func (x *GetInboxIdsRequest_Request) GetIdentifier() string { - if x != nil { - return x.Identifier - } - return "" -} - -func (x *GetInboxIdsRequest_Request) GetIdentifierKind() associations.IdentifierKind { - if x != nil { - return x.IdentifierKind - } - return associations.IdentifierKind(0) -} - -// A single response for a given address -type GetInboxIdsResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"` - InboxId *string `protobuf:"bytes,2,opt,name=inbox_id,json=inboxId,proto3,oneof" json:"inbox_id,omitempty"` - IdentifierKind associations.IdentifierKind `protobuf:"varint,3,opt,name=identifier_kind,json=identifierKind,proto3,enum=xmtp.identity.associations.IdentifierKind" json:"identifier_kind,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetInboxIdsResponse_Response) Reset() { - *x = GetInboxIdsResponse_Response{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetInboxIdsResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetInboxIdsResponse_Response) ProtoMessage() {} - -func (x *GetInboxIdsResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[20] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetInboxIdsResponse_Response.ProtoReflect.Descriptor instead. -func (*GetInboxIdsResponse_Response) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{11, 0} -} - -func (x *GetInboxIdsResponse_Response) GetIdentifier() string { - if x != nil { - return x.Identifier - } - return "" -} - -func (x *GetInboxIdsResponse_Response) GetInboxId() string { - if x != nil && x.InboxId != nil { - return *x.InboxId - } - return "" -} - -func (x *GetInboxIdsResponse_Response) GetIdentifierKind() associations.IdentifierKind { - if x != nil { - return x.IdentifierKind - } - return associations.IdentifierKind(0) -} - -type GetNewestEnvelopeResponse_Response struct { - state protoimpl.MessageState `protogen:"open.v1"` - OriginatorEnvelope *envelopes.OriginatorEnvelope `protobuf:"bytes,1,opt,name=originator_envelope,json=originatorEnvelope,proto3,oneof" json:"originator_envelope,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetNewestEnvelopeResponse_Response) Reset() { - *x = GetNewestEnvelopeResponse_Response{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetNewestEnvelopeResponse_Response) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetNewestEnvelopeResponse_Response) ProtoMessage() {} - -func (x *GetNewestEnvelopeResponse_Response) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[21] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetNewestEnvelopeResponse_Response.ProtoReflect.Descriptor instead. -func (*GetNewestEnvelopeResponse_Response) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{13, 0} -} - -func (x *GetNewestEnvelopeResponse_Response) GetOriginatorEnvelope() *envelopes.OriginatorEnvelope { - if x != nil { - return x.OriginatorEnvelope - } - return nil -} - -type SubscribeOriginatorsRequest_OriginatorFilter struct { - state protoimpl.MessageState `protogen:"open.v1"` - OriginatorNodeIds []uint32 `protobuf:"varint,1,rep,packed,name=originator_node_ids,json=originatorNodeIds,proto3" json:"originator_node_ids,omitempty"` - LastSeen *envelopes.Cursor `protobuf:"bytes,2,opt,name=last_seen,json=lastSeen,proto3" json:"last_seen,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeOriginatorsRequest_OriginatorFilter) Reset() { - *x = SubscribeOriginatorsRequest_OriginatorFilter{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeOriginatorsRequest_OriginatorFilter) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeOriginatorsRequest_OriginatorFilter) ProtoMessage() {} - -func (x *SubscribeOriginatorsRequest_OriginatorFilter) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[22] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeOriginatorsRequest_OriginatorFilter.ProtoReflect.Descriptor instead. -func (*SubscribeOriginatorsRequest_OriginatorFilter) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{14, 0} -} - -func (x *SubscribeOriginatorsRequest_OriginatorFilter) GetOriginatorNodeIds() []uint32 { - if x != nil { - return x.OriginatorNodeIds - } - return nil -} - -func (x *SubscribeOriginatorsRequest_OriginatorFilter) GetLastSeen() *envelopes.Cursor { - if x != nil { - return x.LastSeen - } - return nil -} - -type SubscribeOriginatorsResponse_Envelopes struct { - state protoimpl.MessageState `protogen:"open.v1"` - Envelopes []*envelopes.OriginatorEnvelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubscribeOriginatorsResponse_Envelopes) Reset() { - *x = SubscribeOriginatorsResponse_Envelopes{} - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubscribeOriginatorsResponse_Envelopes) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeOriginatorsResponse_Envelopes) ProtoMessage() {} - -func (x *SubscribeOriginatorsResponse_Envelopes) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[23] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeOriginatorsResponse_Envelopes.ProtoReflect.Descriptor instead. -func (*SubscribeOriginatorsResponse_Envelopes) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{15, 0} -} - -func (x *SubscribeOriginatorsResponse_Envelopes) GetEnvelopes() []*envelopes.OriginatorEnvelope { - if x != nil { - return x.Envelopes - } - return nil -} - -var File_xmtpv4_message_api_message_api_proto protoreflect.FileDescriptor - -const file_xmtpv4_message_api_message_api_proto_rawDesc = "" + - "\n" + - "$xmtpv4/message_api/message_api.proto\x12\x17xmtp.xmtpv4.message_api\x1a'identity/associations/association.proto\x1a xmtpv4/envelopes/envelopes.proto\"\x94\x01\n" + - "\x0eEnvelopesQuery\x12\x16\n" + - "\x06topics\x18\x01 \x03(\fR\x06topics\x12.\n" + - "\x13originator_node_ids\x18\x02 \x03(\rR\x11originatorNodeIds\x12:\n" + - "\tlast_seen\x18\x03 \x01(\v2\x1d.xmtp.xmtpv4.envelopes.CursorR\blastSeen\"Z\n" + - "\x19SubscribeEnvelopesRequest\x12=\n" + - "\x05query\x18\x01 \x01(\v2'.xmtp.xmtpv4.message_api.EnvelopesQueryR\x05query\"\xd0\x01\n" + - "\x16SubscribeTopicsRequest\x12U\n" + - "\afilters\x18\x01 \x03(\v2;.xmtp.xmtpv4.message_api.SubscribeTopicsRequest.TopicFilterR\afilters\x1a_\n" + - "\vTopicFilter\x12\x14\n" + - "\x05topic\x18\x01 \x01(\fR\x05topic\x12:\n" + - "\tlast_seen\x18\x02 \x01(\v2\x1d.xmtp.xmtpv4.envelopes.CursorR\blastSeen\"\xd2\x04\n" + - "\x17SubscribeTopicsResponse\x12Z\n" + - "\tenvelopes\x18\x01 \x01(\v2:.xmtp.xmtpv4.message_api.SubscribeTopicsResponse.EnvelopesH\x00R\tenvelopes\x12d\n" + - "\rstatus_update\x18\x02 \x01(\v2=.xmtp.xmtpv4.message_api.SubscribeTopicsResponse.StatusUpdateH\x00R\fstatusUpdate\x1ak\n" + - "\fStatusUpdate\x12[\n" + - "\x06status\x18\x01 \x01(\x0e2C.xmtp.xmtpv4.message_api.SubscribeTopicsResponse.SubscriptionStatusR\x06status\x1aT\n" + - "\tEnvelopes\x12G\n" + - "\tenvelopes\x18\x01 \x03(\v2).xmtp.xmtpv4.envelopes.OriginatorEnvelopeR\tenvelopes\"\xa5\x01\n" + - "\x12SubscriptionStatus\x12#\n" + - "\x1fSUBSCRIPTION_STATUS_UNSPECIFIED\x10\x00\x12\x1f\n" + - "\x1bSUBSCRIPTION_STATUS_STARTED\x10\x01\x12(\n" + - "$SUBSCRIPTION_STATUS_CATCHUP_COMPLETE\x10\x02\x12\x1f\n" + - "\x1bSUBSCRIPTION_STATUS_WAITING\x10\x03B\n" + - "\n" + - "\bresponse\"e\n" + - "\x1aSubscribeEnvelopesResponse\x12G\n" + - "\tenvelopes\x18\x01 \x03(\v2).xmtp.xmtpv4.envelopes.OriginatorEnvelopeR\tenvelopes\"\x1e\n" + - "\x1cSubscribeAllEnvelopesRequest\"l\n" + - "\x15QueryEnvelopesRequest\x12=\n" + - "\x05query\x18\x01 \x01(\v2'.xmtp.xmtpv4.message_api.EnvelopesQueryR\x05query\x12\x14\n" + - "\x05limit\x18\x02 \x01(\rR\x05limit\"a\n" + - "\x16QueryEnvelopesResponse\x12G\n" + - "\tenvelopes\x18\x01 \x03(\v2).xmtp.xmtpv4.envelopes.OriginatorEnvelopeR\tenvelopes\"m\n" + - "\x1cPublishPayerEnvelopesRequest\x12M\n" + - "\x0fpayer_envelopes\x18\x01 \x03(\v2$.xmtp.xmtpv4.envelopes.PayerEnvelopeR\x0epayerEnvelopes\"}\n" + - "\x1dPublishPayerEnvelopesResponse\x12\\\n" + - "\x14originator_envelopes\x18\x01 \x03(\v2).xmtp.xmtpv4.envelopes.OriginatorEnvelopeR\x13originatorEnvelopes\"\xe5\x01\n" + - "\x12GetInboxIdsRequest\x12O\n" + - "\brequests\x18\x01 \x03(\v23.xmtp.xmtpv4.message_api.GetInboxIdsRequest.RequestR\brequests\x1a~\n" + - "\aRequest\x12\x1e\n" + - "\n" + - "identifier\x18\x01 \x01(\tR\n" + - "identifier\x12S\n" + - "\x0fidentifier_kind\x18\x02 \x01(\x0e2*.xmtp.identity.associations.IdentifierKindR\x0eidentifierKind\"\x99\x02\n" + - "\x13GetInboxIdsResponse\x12S\n" + - "\tresponses\x18\x01 \x03(\v25.xmtp.xmtpv4.message_api.GetInboxIdsResponse.ResponseR\tresponses\x1a\xac\x01\n" + - "\bResponse\x12\x1e\n" + - "\n" + - "identifier\x18\x01 \x01(\tR\n" + - "identifier\x12\x1e\n" + - "\binbox_id\x18\x02 \x01(\tH\x00R\ainboxId\x88\x01\x01\x12S\n" + - "\x0fidentifier_kind\x18\x03 \x01(\x0e2*.xmtp.identity.associations.IdentifierKindR\x0eidentifierKindB\v\n" + - "\t_inbox_id\"2\n" + - "\x18GetNewestEnvelopeRequest\x12\x16\n" + - "\x06topics\x18\x01 \x03(\fR\x06topics\"\xf8\x01\n" + - "\x19GetNewestEnvelopeResponse\x12U\n" + - "\aresults\x18\x01 \x03(\v2;.xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse.ResponseR\aresults\x1a\x83\x01\n" + - "\bResponse\x12_\n" + - "\x13originator_envelope\x18\x01 \x01(\v2).xmtp.xmtpv4.envelopes.OriginatorEnvelopeH\x00R\x12originatorEnvelope\x88\x01\x01B\x16\n" + - "\x14_originator_envelope\"\xfc\x01\n" + - "\x1bSubscribeOriginatorsRequest\x12]\n" + - "\x06filter\x18\x01 \x01(\v2E.xmtp.xmtpv4.message_api.SubscribeOriginatorsRequest.OriginatorFilterR\x06filter\x1a~\n" + - "\x10OriginatorFilter\x12.\n" + - "\x13originator_node_ids\x18\x01 \x03(\rR\x11originatorNodeIds\x12:\n" + - "\tlast_seen\x18\x02 \x01(\v2\x1d.xmtp.xmtpv4.envelopes.CursorR\blastSeen\"\xe1\x01\n" + - "\x1cSubscribeOriginatorsResponse\x12_\n" + - "\tenvelopes\x18\x01 \x01(\v2?.xmtp.xmtpv4.message_api.SubscribeOriginatorsResponse.EnvelopesH\x00R\tenvelopes\x1aT\n" + - "\tEnvelopes\x12G\n" + - "\tenvelopes\x18\x01 \x03(\v2).xmtp.xmtpv4.envelopes.OriginatorEnvelopeR\tenvelopesB\n" + - "\n" + - "\bresponse2\x94\a\n" + - "\x0eReplicationApi\x12\x87\x01\n" + - "\x14SubscribeOriginators\x124.xmtp.xmtpv4.message_api.SubscribeOriginatorsRequest\x1a5.xmtp.xmtpv4.message_api.SubscribeOriginatorsResponse\"\x000\x01\x12\x84\x01\n" + - "\x12SubscribeEnvelopes\x122.xmtp.xmtpv4.message_api.SubscribeEnvelopesRequest\x1a3.xmtp.xmtpv4.message_api.SubscribeEnvelopesResponse\"\x03\x88\x02\x010\x01\x12{\n" + - "\x0fSubscribeTopics\x12/.xmtp.xmtpv4.message_api.SubscribeTopicsRequest\x1a0.xmtp.xmtpv4.message_api.SubscribeTopicsResponse\"\x03\x88\x02\x010\x01\x12v\n" + - "\x0eQueryEnvelopes\x12..xmtp.xmtpv4.message_api.QueryEnvelopesRequest\x1a/.xmtp.xmtpv4.message_api.QueryEnvelopesResponse\"\x03\x88\x02\x01\x12\x8b\x01\n" + - "\x15PublishPayerEnvelopes\x125.xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest\x1a6.xmtp.xmtpv4.message_api.PublishPayerEnvelopesResponse\"\x03\x88\x02\x01\x12m\n" + - "\vGetInboxIds\x12+.xmtp.xmtpv4.message_api.GetInboxIdsRequest\x1a,.xmtp.xmtpv4.message_api.GetInboxIdsResponse\"\x03\x88\x02\x01\x12\x7f\n" + - "\x11GetNewestEnvelope\x121.xmtp.xmtpv4.message_api.GetNewestEnvelopeRequest\x1a2.xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse\"\x03\x88\x02\x01B\x8f\x02\n" + - "5org.xmtp.android.library.push.xmtp.xmtpv4.message_apiB\x0fMessageApiProtoP\x01ZKgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/message_api\xa2\x02\x03XXM\xaa\x02\x16Xmtp.Xmtpv4.MessageApi\xca\x02\x16Xmtp\\Xmtpv4\\MessageApi\xe2\x02\"Xmtp\\Xmtpv4\\MessageApi\\GPBMetadata\xea\x02\x18Xmtp::Xmtpv4::MessageApib\x06proto3" - -var ( - file_xmtpv4_message_api_message_api_proto_rawDescOnce sync.Once - file_xmtpv4_message_api_message_api_proto_rawDescData []byte -) - -func file_xmtpv4_message_api_message_api_proto_rawDescGZIP() []byte { - file_xmtpv4_message_api_message_api_proto_rawDescOnce.Do(func() { - file_xmtpv4_message_api_message_api_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_xmtpv4_message_api_message_api_proto_rawDesc), len(file_xmtpv4_message_api_message_api_proto_rawDesc))) - }) - return file_xmtpv4_message_api_message_api_proto_rawDescData -} - -var file_xmtpv4_message_api_message_api_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_xmtpv4_message_api_message_api_proto_msgTypes = make([]protoimpl.MessageInfo, 24) -var file_xmtpv4_message_api_message_api_proto_goTypes = []any{ - (SubscribeTopicsResponse_SubscriptionStatus)(0), // 0: xmtp.xmtpv4.message_api.SubscribeTopicsResponse.SubscriptionStatus - (*EnvelopesQuery)(nil), // 1: xmtp.xmtpv4.message_api.EnvelopesQuery - (*SubscribeEnvelopesRequest)(nil), // 2: xmtp.xmtpv4.message_api.SubscribeEnvelopesRequest - (*SubscribeTopicsRequest)(nil), // 3: xmtp.xmtpv4.message_api.SubscribeTopicsRequest - (*SubscribeTopicsResponse)(nil), // 4: xmtp.xmtpv4.message_api.SubscribeTopicsResponse - (*SubscribeEnvelopesResponse)(nil), // 5: xmtp.xmtpv4.message_api.SubscribeEnvelopesResponse - (*SubscribeAllEnvelopesRequest)(nil), // 6: xmtp.xmtpv4.message_api.SubscribeAllEnvelopesRequest - (*QueryEnvelopesRequest)(nil), // 7: xmtp.xmtpv4.message_api.QueryEnvelopesRequest - (*QueryEnvelopesResponse)(nil), // 8: xmtp.xmtpv4.message_api.QueryEnvelopesResponse - (*PublishPayerEnvelopesRequest)(nil), // 9: xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest - (*PublishPayerEnvelopesResponse)(nil), // 10: xmtp.xmtpv4.message_api.PublishPayerEnvelopesResponse - (*GetInboxIdsRequest)(nil), // 11: xmtp.xmtpv4.message_api.GetInboxIdsRequest - (*GetInboxIdsResponse)(nil), // 12: xmtp.xmtpv4.message_api.GetInboxIdsResponse - (*GetNewestEnvelopeRequest)(nil), // 13: xmtp.xmtpv4.message_api.GetNewestEnvelopeRequest - (*GetNewestEnvelopeResponse)(nil), // 14: xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse - (*SubscribeOriginatorsRequest)(nil), // 15: xmtp.xmtpv4.message_api.SubscribeOriginatorsRequest - (*SubscribeOriginatorsResponse)(nil), // 16: xmtp.xmtpv4.message_api.SubscribeOriginatorsResponse - (*SubscribeTopicsRequest_TopicFilter)(nil), // 17: xmtp.xmtpv4.message_api.SubscribeTopicsRequest.TopicFilter - (*SubscribeTopicsResponse_StatusUpdate)(nil), // 18: xmtp.xmtpv4.message_api.SubscribeTopicsResponse.StatusUpdate - (*SubscribeTopicsResponse_Envelopes)(nil), // 19: xmtp.xmtpv4.message_api.SubscribeTopicsResponse.Envelopes - (*GetInboxIdsRequest_Request)(nil), // 20: xmtp.xmtpv4.message_api.GetInboxIdsRequest.Request - (*GetInboxIdsResponse_Response)(nil), // 21: xmtp.xmtpv4.message_api.GetInboxIdsResponse.Response - (*GetNewestEnvelopeResponse_Response)(nil), // 22: xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse.Response - (*SubscribeOriginatorsRequest_OriginatorFilter)(nil), // 23: xmtp.xmtpv4.message_api.SubscribeOriginatorsRequest.OriginatorFilter - (*SubscribeOriginatorsResponse_Envelopes)(nil), // 24: xmtp.xmtpv4.message_api.SubscribeOriginatorsResponse.Envelopes - (*envelopes.Cursor)(nil), // 25: xmtp.xmtpv4.envelopes.Cursor - (*envelopes.OriginatorEnvelope)(nil), // 26: xmtp.xmtpv4.envelopes.OriginatorEnvelope - (*envelopes.PayerEnvelope)(nil), // 27: xmtp.xmtpv4.envelopes.PayerEnvelope - (associations.IdentifierKind)(0), // 28: xmtp.identity.associations.IdentifierKind -} -var file_xmtpv4_message_api_message_api_proto_depIdxs = []int32{ - 25, // 0: xmtp.xmtpv4.message_api.EnvelopesQuery.last_seen:type_name -> xmtp.xmtpv4.envelopes.Cursor - 1, // 1: xmtp.xmtpv4.message_api.SubscribeEnvelopesRequest.query:type_name -> xmtp.xmtpv4.message_api.EnvelopesQuery - 17, // 2: xmtp.xmtpv4.message_api.SubscribeTopicsRequest.filters:type_name -> xmtp.xmtpv4.message_api.SubscribeTopicsRequest.TopicFilter - 19, // 3: xmtp.xmtpv4.message_api.SubscribeTopicsResponse.envelopes:type_name -> xmtp.xmtpv4.message_api.SubscribeTopicsResponse.Envelopes - 18, // 4: xmtp.xmtpv4.message_api.SubscribeTopicsResponse.status_update:type_name -> xmtp.xmtpv4.message_api.SubscribeTopicsResponse.StatusUpdate - 26, // 5: xmtp.xmtpv4.message_api.SubscribeEnvelopesResponse.envelopes:type_name -> xmtp.xmtpv4.envelopes.OriginatorEnvelope - 1, // 6: xmtp.xmtpv4.message_api.QueryEnvelopesRequest.query:type_name -> xmtp.xmtpv4.message_api.EnvelopesQuery - 26, // 7: xmtp.xmtpv4.message_api.QueryEnvelopesResponse.envelopes:type_name -> xmtp.xmtpv4.envelopes.OriginatorEnvelope - 27, // 8: xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest.payer_envelopes:type_name -> xmtp.xmtpv4.envelopes.PayerEnvelope - 26, // 9: xmtp.xmtpv4.message_api.PublishPayerEnvelopesResponse.originator_envelopes:type_name -> xmtp.xmtpv4.envelopes.OriginatorEnvelope - 20, // 10: xmtp.xmtpv4.message_api.GetInboxIdsRequest.requests:type_name -> xmtp.xmtpv4.message_api.GetInboxIdsRequest.Request - 21, // 11: xmtp.xmtpv4.message_api.GetInboxIdsResponse.responses:type_name -> xmtp.xmtpv4.message_api.GetInboxIdsResponse.Response - 22, // 12: xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse.results:type_name -> xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse.Response - 23, // 13: xmtp.xmtpv4.message_api.SubscribeOriginatorsRequest.filter:type_name -> xmtp.xmtpv4.message_api.SubscribeOriginatorsRequest.OriginatorFilter - 24, // 14: xmtp.xmtpv4.message_api.SubscribeOriginatorsResponse.envelopes:type_name -> xmtp.xmtpv4.message_api.SubscribeOriginatorsResponse.Envelopes - 25, // 15: xmtp.xmtpv4.message_api.SubscribeTopicsRequest.TopicFilter.last_seen:type_name -> xmtp.xmtpv4.envelopes.Cursor - 0, // 16: xmtp.xmtpv4.message_api.SubscribeTopicsResponse.StatusUpdate.status:type_name -> xmtp.xmtpv4.message_api.SubscribeTopicsResponse.SubscriptionStatus - 26, // 17: xmtp.xmtpv4.message_api.SubscribeTopicsResponse.Envelopes.envelopes:type_name -> xmtp.xmtpv4.envelopes.OriginatorEnvelope - 28, // 18: xmtp.xmtpv4.message_api.GetInboxIdsRequest.Request.identifier_kind:type_name -> xmtp.identity.associations.IdentifierKind - 28, // 19: xmtp.xmtpv4.message_api.GetInboxIdsResponse.Response.identifier_kind:type_name -> xmtp.identity.associations.IdentifierKind - 26, // 20: xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse.Response.originator_envelope:type_name -> xmtp.xmtpv4.envelopes.OriginatorEnvelope - 25, // 21: xmtp.xmtpv4.message_api.SubscribeOriginatorsRequest.OriginatorFilter.last_seen:type_name -> xmtp.xmtpv4.envelopes.Cursor - 26, // 22: xmtp.xmtpv4.message_api.SubscribeOriginatorsResponse.Envelopes.envelopes:type_name -> xmtp.xmtpv4.envelopes.OriginatorEnvelope - 15, // 23: xmtp.xmtpv4.message_api.ReplicationApi.SubscribeOriginators:input_type -> xmtp.xmtpv4.message_api.SubscribeOriginatorsRequest - 2, // 24: xmtp.xmtpv4.message_api.ReplicationApi.SubscribeEnvelopes:input_type -> xmtp.xmtpv4.message_api.SubscribeEnvelopesRequest - 3, // 25: xmtp.xmtpv4.message_api.ReplicationApi.SubscribeTopics:input_type -> xmtp.xmtpv4.message_api.SubscribeTopicsRequest - 7, // 26: xmtp.xmtpv4.message_api.ReplicationApi.QueryEnvelopes:input_type -> xmtp.xmtpv4.message_api.QueryEnvelopesRequest - 9, // 27: xmtp.xmtpv4.message_api.ReplicationApi.PublishPayerEnvelopes:input_type -> xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest - 11, // 28: xmtp.xmtpv4.message_api.ReplicationApi.GetInboxIds:input_type -> xmtp.xmtpv4.message_api.GetInboxIdsRequest - 13, // 29: xmtp.xmtpv4.message_api.ReplicationApi.GetNewestEnvelope:input_type -> xmtp.xmtpv4.message_api.GetNewestEnvelopeRequest - 16, // 30: xmtp.xmtpv4.message_api.ReplicationApi.SubscribeOriginators:output_type -> xmtp.xmtpv4.message_api.SubscribeOriginatorsResponse - 5, // 31: xmtp.xmtpv4.message_api.ReplicationApi.SubscribeEnvelopes:output_type -> xmtp.xmtpv4.message_api.SubscribeEnvelopesResponse - 4, // 32: xmtp.xmtpv4.message_api.ReplicationApi.SubscribeTopics:output_type -> xmtp.xmtpv4.message_api.SubscribeTopicsResponse - 8, // 33: xmtp.xmtpv4.message_api.ReplicationApi.QueryEnvelopes:output_type -> xmtp.xmtpv4.message_api.QueryEnvelopesResponse - 10, // 34: xmtp.xmtpv4.message_api.ReplicationApi.PublishPayerEnvelopes:output_type -> xmtp.xmtpv4.message_api.PublishPayerEnvelopesResponse - 12, // 35: xmtp.xmtpv4.message_api.ReplicationApi.GetInboxIds:output_type -> xmtp.xmtpv4.message_api.GetInboxIdsResponse - 14, // 36: xmtp.xmtpv4.message_api.ReplicationApi.GetNewestEnvelope:output_type -> xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse - 30, // [30:37] is the sub-list for method output_type - 23, // [23:30] is the sub-list for method input_type - 23, // [23:23] is the sub-list for extension type_name - 23, // [23:23] is the sub-list for extension extendee - 0, // [0:23] is the sub-list for field type_name -} - -func init() { file_xmtpv4_message_api_message_api_proto_init() } -func file_xmtpv4_message_api_message_api_proto_init() { - if File_xmtpv4_message_api_message_api_proto != nil { - return - } - file_xmtpv4_message_api_message_api_proto_msgTypes[3].OneofWrappers = []any{ - (*SubscribeTopicsResponse_Envelopes_)(nil), - (*SubscribeTopicsResponse_StatusUpdate_)(nil), - } - file_xmtpv4_message_api_message_api_proto_msgTypes[15].OneofWrappers = []any{ - (*SubscribeOriginatorsResponse_Envelopes_)(nil), - } - file_xmtpv4_message_api_message_api_proto_msgTypes[20].OneofWrappers = []any{} - file_xmtpv4_message_api_message_api_proto_msgTypes[21].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_message_api_message_api_proto_rawDesc), len(file_xmtpv4_message_api_message_api_proto_rawDesc)), - NumEnums: 1, - NumMessages: 24, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_xmtpv4_message_api_message_api_proto_goTypes, - DependencyIndexes: file_xmtpv4_message_api_message_api_proto_depIdxs, - EnumInfos: file_xmtpv4_message_api_message_api_proto_enumTypes, - MessageInfos: file_xmtpv4_message_api_message_api_proto_msgTypes, - }.Build() - File_xmtpv4_message_api_message_api_proto = out.File - file_xmtpv4_message_api_message_api_proto_goTypes = nil - file_xmtpv4_message_api_message_api_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/message_api/message_api_grpc.pb.go b/pkg/proto/xmtpv4/message_api/message_api_grpc.pb.go deleted file mode 100644 index dbb7af36..00000000 --- a/pkg/proto/xmtpv4/message_api/message_api_grpc.pb.go +++ /dev/null @@ -1,449 +0,0 @@ -// Message API for XMTP V4 - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: xmtpv4/message_api/message_api.proto - -package message_api - -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 ( - ReplicationApi_SubscribeOriginators_FullMethodName = "/xmtp.xmtpv4.message_api.ReplicationApi/SubscribeOriginators" - ReplicationApi_SubscribeEnvelopes_FullMethodName = "/xmtp.xmtpv4.message_api.ReplicationApi/SubscribeEnvelopes" - ReplicationApi_SubscribeTopics_FullMethodName = "/xmtp.xmtpv4.message_api.ReplicationApi/SubscribeTopics" - ReplicationApi_QueryEnvelopes_FullMethodName = "/xmtp.xmtpv4.message_api.ReplicationApi/QueryEnvelopes" - ReplicationApi_PublishPayerEnvelopes_FullMethodName = "/xmtp.xmtpv4.message_api.ReplicationApi/PublishPayerEnvelopes" - ReplicationApi_GetInboxIds_FullMethodName = "/xmtp.xmtpv4.message_api.ReplicationApi/GetInboxIds" - ReplicationApi_GetNewestEnvelope_FullMethodName = "/xmtp.xmtpv4.message_api.ReplicationApi/GetNewestEnvelope" -) - -// ReplicationApiClient is the client API for ReplicationApi 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 ReplicationApiClient interface { - // Node-to-node originator subscription - SubscribeOriginators(ctx context.Context, in *SubscribeOriginatorsRequest, opts ...grpc.CallOption) (ReplicationApi_SubscribeOriginatorsClient, error) - // Deprecated: Do not use. - // Deprecated: use SubscribeOriginators for node queries, - // QueryApi.SubscribeTopics for client queries - SubscribeEnvelopes(ctx context.Context, in *SubscribeEnvelopesRequest, opts ...grpc.CallOption) (ReplicationApi_SubscribeEnvelopesClient, error) - // Deprecated: Do not use. - // Deprecated: moved to QueryApi - SubscribeTopics(ctx context.Context, in *SubscribeTopicsRequest, opts ...grpc.CallOption) (ReplicationApi_SubscribeTopicsClient, error) - // Deprecated: Do not use. - // Deprecated: moved to QueryApi - QueryEnvelopes(ctx context.Context, in *QueryEnvelopesRequest, opts ...grpc.CallOption) (*QueryEnvelopesResponse, error) - // Deprecated: Do not use. - // Deprecated: moved to PublishApi - PublishPayerEnvelopes(ctx context.Context, in *PublishPayerEnvelopesRequest, opts ...grpc.CallOption) (*PublishPayerEnvelopesResponse, error) - // Deprecated: Do not use. - // Deprecated: moved to QueryApi - GetInboxIds(ctx context.Context, in *GetInboxIdsRequest, opts ...grpc.CallOption) (*GetInboxIdsResponse, error) - // Deprecated: Do not use. - // Deprecated: moved to QueryApi - GetNewestEnvelope(ctx context.Context, in *GetNewestEnvelopeRequest, opts ...grpc.CallOption) (*GetNewestEnvelopeResponse, error) -} - -type replicationApiClient struct { - cc grpc.ClientConnInterface -} - -func NewReplicationApiClient(cc grpc.ClientConnInterface) ReplicationApiClient { - return &replicationApiClient{cc} -} - -func (c *replicationApiClient) SubscribeOriginators(ctx context.Context, in *SubscribeOriginatorsRequest, opts ...grpc.CallOption) (ReplicationApi_SubscribeOriginatorsClient, error) { - stream, err := c.cc.NewStream(ctx, &ReplicationApi_ServiceDesc.Streams[0], ReplicationApi_SubscribeOriginators_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &replicationApiSubscribeOriginatorsClient{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 ReplicationApi_SubscribeOriginatorsClient interface { - Recv() (*SubscribeOriginatorsResponse, error) - grpc.ClientStream -} - -type replicationApiSubscribeOriginatorsClient struct { - grpc.ClientStream -} - -func (x *replicationApiSubscribeOriginatorsClient) Recv() (*SubscribeOriginatorsResponse, error) { - m := new(SubscribeOriginatorsResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -// Deprecated: Do not use. -func (c *replicationApiClient) SubscribeEnvelopes(ctx context.Context, in *SubscribeEnvelopesRequest, opts ...grpc.CallOption) (ReplicationApi_SubscribeEnvelopesClient, error) { - stream, err := c.cc.NewStream(ctx, &ReplicationApi_ServiceDesc.Streams[1], ReplicationApi_SubscribeEnvelopes_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &replicationApiSubscribeEnvelopesClient{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 ReplicationApi_SubscribeEnvelopesClient interface { - Recv() (*SubscribeEnvelopesResponse, error) - grpc.ClientStream -} - -type replicationApiSubscribeEnvelopesClient struct { - grpc.ClientStream -} - -func (x *replicationApiSubscribeEnvelopesClient) Recv() (*SubscribeEnvelopesResponse, error) { - m := new(SubscribeEnvelopesResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -// Deprecated: Do not use. -func (c *replicationApiClient) SubscribeTopics(ctx context.Context, in *SubscribeTopicsRequest, opts ...grpc.CallOption) (ReplicationApi_SubscribeTopicsClient, error) { - stream, err := c.cc.NewStream(ctx, &ReplicationApi_ServiceDesc.Streams[2], ReplicationApi_SubscribeTopics_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &replicationApiSubscribeTopicsClient{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 ReplicationApi_SubscribeTopicsClient interface { - Recv() (*SubscribeTopicsResponse, error) - grpc.ClientStream -} - -type replicationApiSubscribeTopicsClient struct { - grpc.ClientStream -} - -func (x *replicationApiSubscribeTopicsClient) Recv() (*SubscribeTopicsResponse, error) { - m := new(SubscribeTopicsResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -// Deprecated: Do not use. -func (c *replicationApiClient) QueryEnvelopes(ctx context.Context, in *QueryEnvelopesRequest, opts ...grpc.CallOption) (*QueryEnvelopesResponse, error) { - out := new(QueryEnvelopesResponse) - err := c.cc.Invoke(ctx, ReplicationApi_QueryEnvelopes_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// Deprecated: Do not use. -func (c *replicationApiClient) PublishPayerEnvelopes(ctx context.Context, in *PublishPayerEnvelopesRequest, opts ...grpc.CallOption) (*PublishPayerEnvelopesResponse, error) { - out := new(PublishPayerEnvelopesResponse) - err := c.cc.Invoke(ctx, ReplicationApi_PublishPayerEnvelopes_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// Deprecated: Do not use. -func (c *replicationApiClient) GetInboxIds(ctx context.Context, in *GetInboxIdsRequest, opts ...grpc.CallOption) (*GetInboxIdsResponse, error) { - out := new(GetInboxIdsResponse) - err := c.cc.Invoke(ctx, ReplicationApi_GetInboxIds_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// Deprecated: Do not use. -func (c *replicationApiClient) GetNewestEnvelope(ctx context.Context, in *GetNewestEnvelopeRequest, opts ...grpc.CallOption) (*GetNewestEnvelopeResponse, error) { - out := new(GetNewestEnvelopeResponse) - err := c.cc.Invoke(ctx, ReplicationApi_GetNewestEnvelope_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// ReplicationApiServer is the server API for ReplicationApi service. -// All implementations must embed UnimplementedReplicationApiServer -// for forward compatibility -type ReplicationApiServer interface { - // Node-to-node originator subscription - SubscribeOriginators(*SubscribeOriginatorsRequest, ReplicationApi_SubscribeOriginatorsServer) error - // Deprecated: Do not use. - // Deprecated: use SubscribeOriginators for node queries, - // QueryApi.SubscribeTopics for client queries - SubscribeEnvelopes(*SubscribeEnvelopesRequest, ReplicationApi_SubscribeEnvelopesServer) error - // Deprecated: Do not use. - // Deprecated: moved to QueryApi - SubscribeTopics(*SubscribeTopicsRequest, ReplicationApi_SubscribeTopicsServer) error - // Deprecated: Do not use. - // Deprecated: moved to QueryApi - QueryEnvelopes(context.Context, *QueryEnvelopesRequest) (*QueryEnvelopesResponse, error) - // Deprecated: Do not use. - // Deprecated: moved to PublishApi - PublishPayerEnvelopes(context.Context, *PublishPayerEnvelopesRequest) (*PublishPayerEnvelopesResponse, error) - // Deprecated: Do not use. - // Deprecated: moved to QueryApi - GetInboxIds(context.Context, *GetInboxIdsRequest) (*GetInboxIdsResponse, error) - // Deprecated: Do not use. - // Deprecated: moved to QueryApi - GetNewestEnvelope(context.Context, *GetNewestEnvelopeRequest) (*GetNewestEnvelopeResponse, error) - mustEmbedUnimplementedReplicationApiServer() -} - -// UnimplementedReplicationApiServer must be embedded to have forward compatible implementations. -type UnimplementedReplicationApiServer struct { -} - -func (UnimplementedReplicationApiServer) SubscribeOriginators(*SubscribeOriginatorsRequest, ReplicationApi_SubscribeOriginatorsServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeOriginators not implemented") -} -func (UnimplementedReplicationApiServer) SubscribeEnvelopes(*SubscribeEnvelopesRequest, ReplicationApi_SubscribeEnvelopesServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeEnvelopes not implemented") -} -func (UnimplementedReplicationApiServer) SubscribeTopics(*SubscribeTopicsRequest, ReplicationApi_SubscribeTopicsServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeTopics not implemented") -} -func (UnimplementedReplicationApiServer) QueryEnvelopes(context.Context, *QueryEnvelopesRequest) (*QueryEnvelopesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method QueryEnvelopes not implemented") -} -func (UnimplementedReplicationApiServer) PublishPayerEnvelopes(context.Context, *PublishPayerEnvelopesRequest) (*PublishPayerEnvelopesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method PublishPayerEnvelopes not implemented") -} -func (UnimplementedReplicationApiServer) GetInboxIds(context.Context, *GetInboxIdsRequest) (*GetInboxIdsResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetInboxIds not implemented") -} -func (UnimplementedReplicationApiServer) GetNewestEnvelope(context.Context, *GetNewestEnvelopeRequest) (*GetNewestEnvelopeResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetNewestEnvelope not implemented") -} -func (UnimplementedReplicationApiServer) mustEmbedUnimplementedReplicationApiServer() {} - -// UnsafeReplicationApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to ReplicationApiServer will -// result in compilation errors. -type UnsafeReplicationApiServer interface { - mustEmbedUnimplementedReplicationApiServer() -} - -func RegisterReplicationApiServer(s grpc.ServiceRegistrar, srv ReplicationApiServer) { - s.RegisterService(&ReplicationApi_ServiceDesc, srv) -} - -func _ReplicationApi_SubscribeOriginators_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeOriginatorsRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(ReplicationApiServer).SubscribeOriginators(m, &replicationApiSubscribeOriginatorsServer{stream}) -} - -type ReplicationApi_SubscribeOriginatorsServer interface { - Send(*SubscribeOriginatorsResponse) error - grpc.ServerStream -} - -type replicationApiSubscribeOriginatorsServer struct { - grpc.ServerStream -} - -func (x *replicationApiSubscribeOriginatorsServer) Send(m *SubscribeOriginatorsResponse) error { - return x.ServerStream.SendMsg(m) -} - -func _ReplicationApi_SubscribeEnvelopes_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeEnvelopesRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(ReplicationApiServer).SubscribeEnvelopes(m, &replicationApiSubscribeEnvelopesServer{stream}) -} - -type ReplicationApi_SubscribeEnvelopesServer interface { - Send(*SubscribeEnvelopesResponse) error - grpc.ServerStream -} - -type replicationApiSubscribeEnvelopesServer struct { - grpc.ServerStream -} - -func (x *replicationApiSubscribeEnvelopesServer) Send(m *SubscribeEnvelopesResponse) error { - return x.ServerStream.SendMsg(m) -} - -func _ReplicationApi_SubscribeTopics_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeTopicsRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(ReplicationApiServer).SubscribeTopics(m, &replicationApiSubscribeTopicsServer{stream}) -} - -type ReplicationApi_SubscribeTopicsServer interface { - Send(*SubscribeTopicsResponse) error - grpc.ServerStream -} - -type replicationApiSubscribeTopicsServer struct { - grpc.ServerStream -} - -func (x *replicationApiSubscribeTopicsServer) Send(m *SubscribeTopicsResponse) error { - return x.ServerStream.SendMsg(m) -} - -func _ReplicationApi_QueryEnvelopes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QueryEnvelopesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ReplicationApiServer).QueryEnvelopes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ReplicationApi_QueryEnvelopes_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ReplicationApiServer).QueryEnvelopes(ctx, req.(*QueryEnvelopesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _ReplicationApi_PublishPayerEnvelopes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(PublishPayerEnvelopesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ReplicationApiServer).PublishPayerEnvelopes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ReplicationApi_PublishPayerEnvelopes_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ReplicationApiServer).PublishPayerEnvelopes(ctx, req.(*PublishPayerEnvelopesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _ReplicationApi_GetInboxIds_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetInboxIdsRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ReplicationApiServer).GetInboxIds(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ReplicationApi_GetInboxIds_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ReplicationApiServer).GetInboxIds(ctx, req.(*GetInboxIdsRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _ReplicationApi_GetNewestEnvelope_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetNewestEnvelopeRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ReplicationApiServer).GetNewestEnvelope(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ReplicationApi_GetNewestEnvelope_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ReplicationApiServer).GetNewestEnvelope(ctx, req.(*GetNewestEnvelopeRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// ReplicationApi_ServiceDesc is the grpc.ServiceDesc for ReplicationApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var ReplicationApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.xmtpv4.message_api.ReplicationApi", - HandlerType: (*ReplicationApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "QueryEnvelopes", - Handler: _ReplicationApi_QueryEnvelopes_Handler, - }, - { - MethodName: "PublishPayerEnvelopes", - Handler: _ReplicationApi_PublishPayerEnvelopes_Handler, - }, - { - MethodName: "GetInboxIds", - Handler: _ReplicationApi_GetInboxIds_Handler, - }, - { - MethodName: "GetNewestEnvelope", - Handler: _ReplicationApi_GetNewestEnvelope_Handler, - }, - }, - Streams: []grpc.StreamDesc{ - { - StreamName: "SubscribeOriginators", - Handler: _ReplicationApi_SubscribeOriginators_Handler, - ServerStreams: true, - }, - { - StreamName: "SubscribeEnvelopes", - Handler: _ReplicationApi_SubscribeEnvelopes_Handler, - ServerStreams: true, - }, - { - StreamName: "SubscribeTopics", - Handler: _ReplicationApi_SubscribeTopics_Handler, - ServerStreams: true, - }, - }, - Metadata: "xmtpv4/message_api/message_api.proto", -} diff --git a/pkg/proto/xmtpv4/message_api/misbehavior_api.pb.go b/pkg/proto/xmtpv4/message_api/misbehavior_api.pb.go deleted file mode 100644 index 8892df89..00000000 --- a/pkg/proto/xmtpv4/message_api/misbehavior_api.pb.go +++ /dev/null @@ -1,723 +0,0 @@ -// API for reporting and querying node misbehavior in decentralized XMTP - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/message_api/misbehavior_api.proto - -package message_api - -import ( - associations "github.com/xmtp/example-notification-server-go/pkg/proto/identity/associations" - envelopes "github.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/envelopes" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type Misbehavior int32 - -const ( - Misbehavior_MISBEHAVIOR_UNSPECIFIED Misbehavior = 0 - Misbehavior_MISBEHAVIOR_UNRESPONSIVE_NODE Misbehavior = 1 - Misbehavior_MISBEHAVIOR_SLOW_NODE Misbehavior = 2 - Misbehavior_MISBEHAVIOR_FAILED_REQUEST Misbehavior = 3 - Misbehavior_MISBEHAVIOR_OUT_OF_ORDER Misbehavior = 4 - Misbehavior_MISBEHAVIOR_DUPLICATE_SEQUENCE_ID Misbehavior = 5 - Misbehavior_MISBEHAVIOR_CAUSAL_ORDERING Misbehavior = 6 - Misbehavior_MISBEHAVIOR_INVALID_PAYLOAD Misbehavior = 7 - Misbehavior_MISBEHAVIOR_BLOCKCHAIN_INCONSISTENCY Misbehavior = 8 -) - -// Enum value maps for Misbehavior. -var ( - Misbehavior_name = map[int32]string{ - 0: "MISBEHAVIOR_UNSPECIFIED", - 1: "MISBEHAVIOR_UNRESPONSIVE_NODE", - 2: "MISBEHAVIOR_SLOW_NODE", - 3: "MISBEHAVIOR_FAILED_REQUEST", - 4: "MISBEHAVIOR_OUT_OF_ORDER", - 5: "MISBEHAVIOR_DUPLICATE_SEQUENCE_ID", - 6: "MISBEHAVIOR_CAUSAL_ORDERING", - 7: "MISBEHAVIOR_INVALID_PAYLOAD", - 8: "MISBEHAVIOR_BLOCKCHAIN_INCONSISTENCY", - } - Misbehavior_value = map[string]int32{ - "MISBEHAVIOR_UNSPECIFIED": 0, - "MISBEHAVIOR_UNRESPONSIVE_NODE": 1, - "MISBEHAVIOR_SLOW_NODE": 2, - "MISBEHAVIOR_FAILED_REQUEST": 3, - "MISBEHAVIOR_OUT_OF_ORDER": 4, - "MISBEHAVIOR_DUPLICATE_SEQUENCE_ID": 5, - "MISBEHAVIOR_CAUSAL_ORDERING": 6, - "MISBEHAVIOR_INVALID_PAYLOAD": 7, - "MISBEHAVIOR_BLOCKCHAIN_INCONSISTENCY": 8, - } -) - -func (x Misbehavior) Enum() *Misbehavior { - p := new(Misbehavior) - *p = x - return p -} - -func (x Misbehavior) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (Misbehavior) Descriptor() protoreflect.EnumDescriptor { - return file_xmtpv4_message_api_misbehavior_api_proto_enumTypes[0].Descriptor() -} - -func (Misbehavior) Type() protoreflect.EnumType { - return &file_xmtpv4_message_api_misbehavior_api_proto_enumTypes[0] -} - -func (x Misbehavior) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use Misbehavior.Descriptor instead. -func (Misbehavior) EnumDescriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{0} -} - -type LivenessFailure struct { - state protoimpl.MessageState `protogen:"open.v1"` - ResponseTimeNs uint32 `protobuf:"varint,1,opt,name=response_time_ns,json=responseTimeNs,proto3" json:"response_time_ns,omitempty"` - // Types that are valid to be assigned to Request: - // - // *LivenessFailure_Subscribe - // *LivenessFailure_Query - // *LivenessFailure_Publish - Request isLivenessFailure_Request `protobuf_oneof:"request"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *LivenessFailure) Reset() { - *x = LivenessFailure{} - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *LivenessFailure) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*LivenessFailure) ProtoMessage() {} - -func (x *LivenessFailure) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use LivenessFailure.ProtoReflect.Descriptor instead. -func (*LivenessFailure) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{0} -} - -func (x *LivenessFailure) GetResponseTimeNs() uint32 { - if x != nil { - return x.ResponseTimeNs - } - return 0 -} - -func (x *LivenessFailure) GetRequest() isLivenessFailure_Request { - if x != nil { - return x.Request - } - return nil -} - -func (x *LivenessFailure) GetSubscribe() *SubscribeEnvelopesRequest { - if x != nil { - if x, ok := x.Request.(*LivenessFailure_Subscribe); ok { - return x.Subscribe - } - } - return nil -} - -func (x *LivenessFailure) GetQuery() *QueryEnvelopesRequest { - if x != nil { - if x, ok := x.Request.(*LivenessFailure_Query); ok { - return x.Query - } - } - return nil -} - -func (x *LivenessFailure) GetPublish() *PublishPayerEnvelopesRequest { - if x != nil { - if x, ok := x.Request.(*LivenessFailure_Publish); ok { - return x.Publish - } - } - return nil -} - -type isLivenessFailure_Request interface { - isLivenessFailure_Request() -} - -type LivenessFailure_Subscribe struct { - Subscribe *SubscribeEnvelopesRequest `protobuf:"bytes,2,opt,name=subscribe,proto3,oneof"` -} - -type LivenessFailure_Query struct { - Query *QueryEnvelopesRequest `protobuf:"bytes,3,opt,name=query,proto3,oneof"` -} - -type LivenessFailure_Publish struct { - Publish *PublishPayerEnvelopesRequest `protobuf:"bytes,4,opt,name=publish,proto3,oneof"` -} - -func (*LivenessFailure_Subscribe) isLivenessFailure_Request() {} - -func (*LivenessFailure_Query) isLivenessFailure_Request() {} - -func (*LivenessFailure_Publish) isLivenessFailure_Request() {} - -type SafetyFailure struct { - state protoimpl.MessageState `protogen:"open.v1"` - Envelopes []*envelopes.OriginatorEnvelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SafetyFailure) Reset() { - *x = SafetyFailure{} - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SafetyFailure) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SafetyFailure) ProtoMessage() {} - -func (x *SafetyFailure) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SafetyFailure.ProtoReflect.Descriptor instead. -func (*SafetyFailure) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{1} -} - -func (x *SafetyFailure) GetEnvelopes() []*envelopes.OriginatorEnvelope { - if x != nil { - return x.Envelopes - } - return nil -} - -type UnsignedMisbehaviorReport struct { - state protoimpl.MessageState `protogen:"open.v1"` - ReporterTimeNs uint64 `protobuf:"varint,1,opt,name=reporter_time_ns,json=reporterTimeNs,proto3" json:"reporter_time_ns,omitempty"` - MisbehavingNodeId uint32 `protobuf:"varint,2,opt,name=misbehaving_node_id,json=misbehavingNodeId,proto3" json:"misbehaving_node_id,omitempty"` - Type Misbehavior `protobuf:"varint,3,opt,name=type,proto3,enum=xmtp.xmtpv4.message_api.Misbehavior" json:"type,omitempty"` - // Types that are valid to be assigned to Failure: - // - // *UnsignedMisbehaviorReport_Liveness - // *UnsignedMisbehaviorReport_Safety - Failure isUnsignedMisbehaviorReport_Failure `protobuf_oneof:"failure"` - // Nodes must verify this field is false for client-submitted reports - SubmittedByNode bool `protobuf:"varint,6,opt,name=submitted_by_node,json=submittedByNode,proto3" json:"submitted_by_node,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *UnsignedMisbehaviorReport) Reset() { - *x = UnsignedMisbehaviorReport{} - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *UnsignedMisbehaviorReport) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*UnsignedMisbehaviorReport) ProtoMessage() {} - -func (x *UnsignedMisbehaviorReport) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use UnsignedMisbehaviorReport.ProtoReflect.Descriptor instead. -func (*UnsignedMisbehaviorReport) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{2} -} - -func (x *UnsignedMisbehaviorReport) GetReporterTimeNs() uint64 { - if x != nil { - return x.ReporterTimeNs - } - return 0 -} - -func (x *UnsignedMisbehaviorReport) GetMisbehavingNodeId() uint32 { - if x != nil { - return x.MisbehavingNodeId - } - return 0 -} - -func (x *UnsignedMisbehaviorReport) GetType() Misbehavior { - if x != nil { - return x.Type - } - return Misbehavior_MISBEHAVIOR_UNSPECIFIED -} - -func (x *UnsignedMisbehaviorReport) GetFailure() isUnsignedMisbehaviorReport_Failure { - if x != nil { - return x.Failure - } - return nil -} - -func (x *UnsignedMisbehaviorReport) GetLiveness() *LivenessFailure { - if x != nil { - if x, ok := x.Failure.(*UnsignedMisbehaviorReport_Liveness); ok { - return x.Liveness - } - } - return nil -} - -func (x *UnsignedMisbehaviorReport) GetSafety() *SafetyFailure { - if x != nil { - if x, ok := x.Failure.(*UnsignedMisbehaviorReport_Safety); ok { - return x.Safety - } - } - return nil -} - -func (x *UnsignedMisbehaviorReport) GetSubmittedByNode() bool { - if x != nil { - return x.SubmittedByNode - } - return false -} - -type isUnsignedMisbehaviorReport_Failure interface { - isUnsignedMisbehaviorReport_Failure() -} - -type UnsignedMisbehaviorReport_Liveness struct { - Liveness *LivenessFailure `protobuf:"bytes,4,opt,name=liveness,proto3,oneof"` -} - -type UnsignedMisbehaviorReport_Safety struct { - Safety *SafetyFailure `protobuf:"bytes,5,opt,name=safety,proto3,oneof"` -} - -func (*UnsignedMisbehaviorReport_Liveness) isUnsignedMisbehaviorReport_Failure() {} - -func (*UnsignedMisbehaviorReport_Safety) isUnsignedMisbehaviorReport_Failure() {} - -type MisbehaviorReport struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Server time when the report was stored. Used only for querying reports. - // This field is not signed. - ServerTimeNs uint64 `protobuf:"varint,1,opt,name=server_time_ns,json=serverTimeNs,proto3" json:"server_time_ns,omitempty"` - UnsignedMisbehaviorReport []byte `protobuf:"bytes,2,opt,name=unsigned_misbehavior_report,json=unsignedMisbehaviorReport,proto3" json:"unsigned_misbehavior_report,omitempty"` - // Signed by the node hosting the report - Signature *associations.RecoverableEcdsaSignature `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *MisbehaviorReport) Reset() { - *x = MisbehaviorReport{} - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *MisbehaviorReport) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MisbehaviorReport) ProtoMessage() {} - -func (x *MisbehaviorReport) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MisbehaviorReport.ProtoReflect.Descriptor instead. -func (*MisbehaviorReport) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{3} -} - -func (x *MisbehaviorReport) GetServerTimeNs() uint64 { - if x != nil { - return x.ServerTimeNs - } - return 0 -} - -func (x *MisbehaviorReport) GetUnsignedMisbehaviorReport() []byte { - if x != nil { - return x.UnsignedMisbehaviorReport - } - return nil -} - -func (x *MisbehaviorReport) GetSignature() *associations.RecoverableEcdsaSignature { - if x != nil { - return x.Signature - } - return nil -} - -type SubmitMisbehaviorReportRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Report *UnsignedMisbehaviorReport `protobuf:"bytes,1,opt,name=report,proto3" json:"report,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubmitMisbehaviorReportRequest) Reset() { - *x = SubmitMisbehaviorReportRequest{} - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubmitMisbehaviorReportRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubmitMisbehaviorReportRequest) ProtoMessage() {} - -func (x *SubmitMisbehaviorReportRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubmitMisbehaviorReportRequest.ProtoReflect.Descriptor instead. -func (*SubmitMisbehaviorReportRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{4} -} - -func (x *SubmitMisbehaviorReportRequest) GetReport() *UnsignedMisbehaviorReport { - if x != nil { - return x.Report - } - return nil -} - -type SubmitMisbehaviorReportResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *SubmitMisbehaviorReportResponse) Reset() { - *x = SubmitMisbehaviorReportResponse{} - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *SubmitMisbehaviorReportResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubmitMisbehaviorReportResponse) ProtoMessage() {} - -func (x *SubmitMisbehaviorReportResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubmitMisbehaviorReportResponse.ProtoReflect.Descriptor instead. -func (*SubmitMisbehaviorReportResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{5} -} - -type QueryMisbehaviorReportsRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - AfterNs uint64 `protobuf:"varint,1,opt,name=after_ns,json=afterNs,proto3" json:"after_ns,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryMisbehaviorReportsRequest) Reset() { - *x = QueryMisbehaviorReportsRequest{} - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryMisbehaviorReportsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryMisbehaviorReportsRequest) ProtoMessage() {} - -func (x *QueryMisbehaviorReportsRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryMisbehaviorReportsRequest.ProtoReflect.Descriptor instead. -func (*QueryMisbehaviorReportsRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{6} -} - -func (x *QueryMisbehaviorReportsRequest) GetAfterNs() uint64 { - if x != nil { - return x.AfterNs - } - return 0 -} - -type QueryMisbehaviorReportsResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Reports []*MisbehaviorReport `protobuf:"bytes,1,rep,name=reports,proto3" json:"reports,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *QueryMisbehaviorReportsResponse) Reset() { - *x = QueryMisbehaviorReportsResponse{} - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *QueryMisbehaviorReportsResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*QueryMisbehaviorReportsResponse) ProtoMessage() {} - -func (x *QueryMisbehaviorReportsResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use QueryMisbehaviorReportsResponse.ProtoReflect.Descriptor instead. -func (*QueryMisbehaviorReportsResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP(), []int{7} -} - -func (x *QueryMisbehaviorReportsResponse) GetReports() []*MisbehaviorReport { - if x != nil { - return x.Reports - } - return nil -} - -var File_xmtpv4_message_api_misbehavior_api_proto protoreflect.FileDescriptor - -const file_xmtpv4_message_api_misbehavior_api_proto_rawDesc = "" + - "\n" + - "(xmtpv4/message_api/misbehavior_api.proto\x12\x17xmtp.xmtpv4.message_api\x1a%identity/associations/signature.proto\x1a xmtpv4/envelopes/envelopes.proto\x1a$xmtpv4/message_api/message_api.proto\"\xb5\x02\n" + - "\x0fLivenessFailure\x12(\n" + - "\x10response_time_ns\x18\x01 \x01(\rR\x0eresponseTimeNs\x12R\n" + - "\tsubscribe\x18\x02 \x01(\v22.xmtp.xmtpv4.message_api.SubscribeEnvelopesRequestH\x00R\tsubscribe\x12F\n" + - "\x05query\x18\x03 \x01(\v2..xmtp.xmtpv4.message_api.QueryEnvelopesRequestH\x00R\x05query\x12Q\n" + - "\apublish\x18\x04 \x01(\v25.xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequestH\x00R\apublishB\t\n" + - "\arequest\"X\n" + - "\rSafetyFailure\x12G\n" + - "\tenvelopes\x18\x01 \x03(\v2).xmtp.xmtpv4.envelopes.OriginatorEnvelopeR\tenvelopes\"\xf0\x02\n" + - "\x19UnsignedMisbehaviorReport\x12(\n" + - "\x10reporter_time_ns\x18\x01 \x01(\x04R\x0ereporterTimeNs\x12.\n" + - "\x13misbehaving_node_id\x18\x02 \x01(\rR\x11misbehavingNodeId\x128\n" + - "\x04type\x18\x03 \x01(\x0e2$.xmtp.xmtpv4.message_api.MisbehaviorR\x04type\x12F\n" + - "\bliveness\x18\x04 \x01(\v2(.xmtp.xmtpv4.message_api.LivenessFailureH\x00R\bliveness\x12@\n" + - "\x06safety\x18\x05 \x01(\v2&.xmtp.xmtpv4.message_api.SafetyFailureH\x00R\x06safety\x12*\n" + - "\x11submitted_by_node\x18\x06 \x01(\bR\x0fsubmittedByNodeB\t\n" + - "\afailure\"\xce\x01\n" + - "\x11MisbehaviorReport\x12$\n" + - "\x0eserver_time_ns\x18\x01 \x01(\x04R\fserverTimeNs\x12>\n" + - "\x1bunsigned_misbehavior_report\x18\x02 \x01(\fR\x19unsignedMisbehaviorReport\x12S\n" + - "\tsignature\x18\x03 \x01(\v25.xmtp.identity.associations.RecoverableEcdsaSignatureR\tsignature\"l\n" + - "\x1eSubmitMisbehaviorReportRequest\x12J\n" + - "\x06report\x18\x01 \x01(\v22.xmtp.xmtpv4.message_api.UnsignedMisbehaviorReportR\x06report\"!\n" + - "\x1fSubmitMisbehaviorReportResponse\";\n" + - "\x1eQueryMisbehaviorReportsRequest\x12\x19\n" + - "\bafter_ns\x18\x01 \x01(\x04R\aafterNs\"g\n" + - "\x1fQueryMisbehaviorReportsResponse\x12D\n" + - "\areports\x18\x01 \x03(\v2*.xmtp.xmtpv4.message_api.MisbehaviorReportR\areports*\xb9\x02\n" + - "\vMisbehavior\x12\x1b\n" + - "\x17MISBEHAVIOR_UNSPECIFIED\x10\x00\x12!\n" + - "\x1dMISBEHAVIOR_UNRESPONSIVE_NODE\x10\x01\x12\x19\n" + - "\x15MISBEHAVIOR_SLOW_NODE\x10\x02\x12\x1e\n" + - "\x1aMISBEHAVIOR_FAILED_REQUEST\x10\x03\x12\x1c\n" + - "\x18MISBEHAVIOR_OUT_OF_ORDER\x10\x04\x12%\n" + - "!MISBEHAVIOR_DUPLICATE_SEQUENCE_ID\x10\x05\x12\x1f\n" + - "\x1bMISBEHAVIOR_CAUSAL_ORDERING\x10\x06\x12\x1f\n" + - "\x1bMISBEHAVIOR_INVALID_PAYLOAD\x10\a\x12(\n" + - "$MISBEHAVIOR_BLOCKCHAIN_INCONSISTENCY\x10\b2\xb2\x02\n" + - "\x0eMisbehaviorApi\x12\x8e\x01\n" + - "\x17SubmitMisbehaviorReport\x127.xmtp.xmtpv4.message_api.SubmitMisbehaviorReportRequest\x1a8.xmtp.xmtpv4.message_api.SubmitMisbehaviorReportResponse\"\x00\x12\x8e\x01\n" + - "\x17QueryMisbehaviorReports\x127.xmtp.xmtpv4.message_api.QueryMisbehaviorReportsRequest\x1a8.xmtp.xmtpv4.message_api.QueryMisbehaviorReportsResponse\"\x00B\x93\x02\n" + - "5org.xmtp.android.library.push.xmtp.xmtpv4.message_apiB\x13MisbehaviorApiProtoP\x01ZKgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/message_api\xa2\x02\x03XXM\xaa\x02\x16Xmtp.Xmtpv4.MessageApi\xca\x02\x16Xmtp\\Xmtpv4\\MessageApi\xe2\x02\"Xmtp\\Xmtpv4\\MessageApi\\GPBMetadata\xea\x02\x18Xmtp::Xmtpv4::MessageApib\x06proto3" - -var ( - file_xmtpv4_message_api_misbehavior_api_proto_rawDescOnce sync.Once - file_xmtpv4_message_api_misbehavior_api_proto_rawDescData []byte -) - -func file_xmtpv4_message_api_misbehavior_api_proto_rawDescGZIP() []byte { - file_xmtpv4_message_api_misbehavior_api_proto_rawDescOnce.Do(func() { - file_xmtpv4_message_api_misbehavior_api_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_xmtpv4_message_api_misbehavior_api_proto_rawDesc), len(file_xmtpv4_message_api_misbehavior_api_proto_rawDesc))) - }) - return file_xmtpv4_message_api_misbehavior_api_proto_rawDescData -} - -var file_xmtpv4_message_api_misbehavior_api_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_xmtpv4_message_api_misbehavior_api_proto_msgTypes = make([]protoimpl.MessageInfo, 8) -var file_xmtpv4_message_api_misbehavior_api_proto_goTypes = []any{ - (Misbehavior)(0), // 0: xmtp.xmtpv4.message_api.Misbehavior - (*LivenessFailure)(nil), // 1: xmtp.xmtpv4.message_api.LivenessFailure - (*SafetyFailure)(nil), // 2: xmtp.xmtpv4.message_api.SafetyFailure - (*UnsignedMisbehaviorReport)(nil), // 3: xmtp.xmtpv4.message_api.UnsignedMisbehaviorReport - (*MisbehaviorReport)(nil), // 4: xmtp.xmtpv4.message_api.MisbehaviorReport - (*SubmitMisbehaviorReportRequest)(nil), // 5: xmtp.xmtpv4.message_api.SubmitMisbehaviorReportRequest - (*SubmitMisbehaviorReportResponse)(nil), // 6: xmtp.xmtpv4.message_api.SubmitMisbehaviorReportResponse - (*QueryMisbehaviorReportsRequest)(nil), // 7: xmtp.xmtpv4.message_api.QueryMisbehaviorReportsRequest - (*QueryMisbehaviorReportsResponse)(nil), // 8: xmtp.xmtpv4.message_api.QueryMisbehaviorReportsResponse - (*SubscribeEnvelopesRequest)(nil), // 9: xmtp.xmtpv4.message_api.SubscribeEnvelopesRequest - (*QueryEnvelopesRequest)(nil), // 10: xmtp.xmtpv4.message_api.QueryEnvelopesRequest - (*PublishPayerEnvelopesRequest)(nil), // 11: xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest - (*envelopes.OriginatorEnvelope)(nil), // 12: xmtp.xmtpv4.envelopes.OriginatorEnvelope - (*associations.RecoverableEcdsaSignature)(nil), // 13: xmtp.identity.associations.RecoverableEcdsaSignature -} -var file_xmtpv4_message_api_misbehavior_api_proto_depIdxs = []int32{ - 9, // 0: xmtp.xmtpv4.message_api.LivenessFailure.subscribe:type_name -> xmtp.xmtpv4.message_api.SubscribeEnvelopesRequest - 10, // 1: xmtp.xmtpv4.message_api.LivenessFailure.query:type_name -> xmtp.xmtpv4.message_api.QueryEnvelopesRequest - 11, // 2: xmtp.xmtpv4.message_api.LivenessFailure.publish:type_name -> xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest - 12, // 3: xmtp.xmtpv4.message_api.SafetyFailure.envelopes:type_name -> xmtp.xmtpv4.envelopes.OriginatorEnvelope - 0, // 4: xmtp.xmtpv4.message_api.UnsignedMisbehaviorReport.type:type_name -> xmtp.xmtpv4.message_api.Misbehavior - 1, // 5: xmtp.xmtpv4.message_api.UnsignedMisbehaviorReport.liveness:type_name -> xmtp.xmtpv4.message_api.LivenessFailure - 2, // 6: xmtp.xmtpv4.message_api.UnsignedMisbehaviorReport.safety:type_name -> xmtp.xmtpv4.message_api.SafetyFailure - 13, // 7: xmtp.xmtpv4.message_api.MisbehaviorReport.signature:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature - 3, // 8: xmtp.xmtpv4.message_api.SubmitMisbehaviorReportRequest.report:type_name -> xmtp.xmtpv4.message_api.UnsignedMisbehaviorReport - 4, // 9: xmtp.xmtpv4.message_api.QueryMisbehaviorReportsResponse.reports:type_name -> xmtp.xmtpv4.message_api.MisbehaviorReport - 5, // 10: xmtp.xmtpv4.message_api.MisbehaviorApi.SubmitMisbehaviorReport:input_type -> xmtp.xmtpv4.message_api.SubmitMisbehaviorReportRequest - 7, // 11: xmtp.xmtpv4.message_api.MisbehaviorApi.QueryMisbehaviorReports:input_type -> xmtp.xmtpv4.message_api.QueryMisbehaviorReportsRequest - 6, // 12: xmtp.xmtpv4.message_api.MisbehaviorApi.SubmitMisbehaviorReport:output_type -> xmtp.xmtpv4.message_api.SubmitMisbehaviorReportResponse - 8, // 13: xmtp.xmtpv4.message_api.MisbehaviorApi.QueryMisbehaviorReports:output_type -> xmtp.xmtpv4.message_api.QueryMisbehaviorReportsResponse - 12, // [12:14] is the sub-list for method output_type - 10, // [10:12] is the sub-list for method input_type - 10, // [10:10] is the sub-list for extension type_name - 10, // [10:10] is the sub-list for extension extendee - 0, // [0:10] is the sub-list for field type_name -} - -func init() { file_xmtpv4_message_api_misbehavior_api_proto_init() } -func file_xmtpv4_message_api_misbehavior_api_proto_init() { - if File_xmtpv4_message_api_misbehavior_api_proto != nil { - return - } - file_xmtpv4_message_api_message_api_proto_init() - file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[0].OneofWrappers = []any{ - (*LivenessFailure_Subscribe)(nil), - (*LivenessFailure_Query)(nil), - (*LivenessFailure_Publish)(nil), - } - file_xmtpv4_message_api_misbehavior_api_proto_msgTypes[2].OneofWrappers = []any{ - (*UnsignedMisbehaviorReport_Liveness)(nil), - (*UnsignedMisbehaviorReport_Safety)(nil), - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_message_api_misbehavior_api_proto_rawDesc), len(file_xmtpv4_message_api_misbehavior_api_proto_rawDesc)), - NumEnums: 1, - NumMessages: 8, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_xmtpv4_message_api_misbehavior_api_proto_goTypes, - DependencyIndexes: file_xmtpv4_message_api_misbehavior_api_proto_depIdxs, - EnumInfos: file_xmtpv4_message_api_misbehavior_api_proto_enumTypes, - MessageInfos: file_xmtpv4_message_api_misbehavior_api_proto_msgTypes, - }.Build() - File_xmtpv4_message_api_misbehavior_api_proto = out.File - file_xmtpv4_message_api_misbehavior_api_proto_goTypes = nil - file_xmtpv4_message_api_misbehavior_api_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/message_api/misbehavior_api_grpc.pb.go b/pkg/proto/xmtpv4/message_api/misbehavior_api_grpc.pb.go deleted file mode 100644 index 48a122d7..00000000 --- a/pkg/proto/xmtpv4/message_api/misbehavior_api_grpc.pb.go +++ /dev/null @@ -1,148 +0,0 @@ -// API for reporting and querying node misbehavior in decentralized XMTP - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: xmtpv4/message_api/misbehavior_api.proto - -package message_api - -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 ( - MisbehaviorApi_SubmitMisbehaviorReport_FullMethodName = "/xmtp.xmtpv4.message_api.MisbehaviorApi/SubmitMisbehaviorReport" - MisbehaviorApi_QueryMisbehaviorReports_FullMethodName = "/xmtp.xmtpv4.message_api.MisbehaviorApi/QueryMisbehaviorReports" -) - -// MisbehaviorApiClient is the client API for MisbehaviorApi 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 MisbehaviorApiClient interface { - SubmitMisbehaviorReport(ctx context.Context, in *SubmitMisbehaviorReportRequest, opts ...grpc.CallOption) (*SubmitMisbehaviorReportResponse, error) - QueryMisbehaviorReports(ctx context.Context, in *QueryMisbehaviorReportsRequest, opts ...grpc.CallOption) (*QueryMisbehaviorReportsResponse, error) -} - -type misbehaviorApiClient struct { - cc grpc.ClientConnInterface -} - -func NewMisbehaviorApiClient(cc grpc.ClientConnInterface) MisbehaviorApiClient { - return &misbehaviorApiClient{cc} -} - -func (c *misbehaviorApiClient) SubmitMisbehaviorReport(ctx context.Context, in *SubmitMisbehaviorReportRequest, opts ...grpc.CallOption) (*SubmitMisbehaviorReportResponse, error) { - out := new(SubmitMisbehaviorReportResponse) - err := c.cc.Invoke(ctx, MisbehaviorApi_SubmitMisbehaviorReport_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *misbehaviorApiClient) QueryMisbehaviorReports(ctx context.Context, in *QueryMisbehaviorReportsRequest, opts ...grpc.CallOption) (*QueryMisbehaviorReportsResponse, error) { - out := new(QueryMisbehaviorReportsResponse) - err := c.cc.Invoke(ctx, MisbehaviorApi_QueryMisbehaviorReports_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// MisbehaviorApiServer is the server API for MisbehaviorApi service. -// All implementations must embed UnimplementedMisbehaviorApiServer -// for forward compatibility -type MisbehaviorApiServer interface { - SubmitMisbehaviorReport(context.Context, *SubmitMisbehaviorReportRequest) (*SubmitMisbehaviorReportResponse, error) - QueryMisbehaviorReports(context.Context, *QueryMisbehaviorReportsRequest) (*QueryMisbehaviorReportsResponse, error) - mustEmbedUnimplementedMisbehaviorApiServer() -} - -// UnimplementedMisbehaviorApiServer must be embedded to have forward compatible implementations. -type UnimplementedMisbehaviorApiServer struct { -} - -func (UnimplementedMisbehaviorApiServer) SubmitMisbehaviorReport(context.Context, *SubmitMisbehaviorReportRequest) (*SubmitMisbehaviorReportResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method SubmitMisbehaviorReport not implemented") -} -func (UnimplementedMisbehaviorApiServer) QueryMisbehaviorReports(context.Context, *QueryMisbehaviorReportsRequest) (*QueryMisbehaviorReportsResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method QueryMisbehaviorReports not implemented") -} -func (UnimplementedMisbehaviorApiServer) mustEmbedUnimplementedMisbehaviorApiServer() {} - -// UnsafeMisbehaviorApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to MisbehaviorApiServer will -// result in compilation errors. -type UnsafeMisbehaviorApiServer interface { - mustEmbedUnimplementedMisbehaviorApiServer() -} - -func RegisterMisbehaviorApiServer(s grpc.ServiceRegistrar, srv MisbehaviorApiServer) { - s.RegisterService(&MisbehaviorApi_ServiceDesc, srv) -} - -func _MisbehaviorApi_SubmitMisbehaviorReport_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SubmitMisbehaviorReportRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MisbehaviorApiServer).SubmitMisbehaviorReport(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MisbehaviorApi_SubmitMisbehaviorReport_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MisbehaviorApiServer).SubmitMisbehaviorReport(ctx, req.(*SubmitMisbehaviorReportRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MisbehaviorApi_QueryMisbehaviorReports_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QueryMisbehaviorReportsRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MisbehaviorApiServer).QueryMisbehaviorReports(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MisbehaviorApi_QueryMisbehaviorReports_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MisbehaviorApiServer).QueryMisbehaviorReports(ctx, req.(*QueryMisbehaviorReportsRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// MisbehaviorApi_ServiceDesc is the grpc.ServiceDesc for MisbehaviorApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var MisbehaviorApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.xmtpv4.message_api.MisbehaviorApi", - HandlerType: (*MisbehaviorApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "SubmitMisbehaviorReport", - Handler: _MisbehaviorApi_SubmitMisbehaviorReport_Handler, - }, - { - MethodName: "QueryMisbehaviorReports", - Handler: _MisbehaviorApi_QueryMisbehaviorReports_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "xmtpv4/message_api/misbehavior_api.proto", -} diff --git a/pkg/proto/xmtpv4/message_api/notification_api.pb.go b/pkg/proto/xmtpv4/message_api/notification_api.pb.go deleted file mode 100644 index b3f39ffc..00000000 --- a/pkg/proto/xmtpv4/message_api/notification_api.pb.go +++ /dev/null @@ -1,70 +0,0 @@ -// Notification API - Full envelope stream for push notification servers - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/message_api/notification_api.proto - -package message_api - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -var File_xmtpv4_message_api_notification_api_proto protoreflect.FileDescriptor - -const file_xmtpv4_message_api_notification_api_proto_rawDesc = "" + - "\n" + - ")xmtpv4/message_api/notification_api.proto\x12\x17xmtp.xmtpv4.message_api\x1a$xmtpv4/message_api/message_api.proto2\x9b\x01\n" + - "\x0fNotificationApi\x12\x87\x01\n" + - "\x15SubscribeAllEnvelopes\x125.xmtp.xmtpv4.message_api.SubscribeAllEnvelopesRequest\x1a3.xmtp.xmtpv4.message_api.SubscribeEnvelopesResponse\"\x000\x01B\x94\x02\n" + - "5org.xmtp.android.library.push.xmtp.xmtpv4.message_apiB\x14NotificationApiProtoP\x01ZKgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/message_api\xa2\x02\x03XXM\xaa\x02\x16Xmtp.Xmtpv4.MessageApi\xca\x02\x16Xmtp\\Xmtpv4\\MessageApi\xe2\x02\"Xmtp\\Xmtpv4\\MessageApi\\GPBMetadata\xea\x02\x18Xmtp::Xmtpv4::MessageApib\x06proto3" - -var file_xmtpv4_message_api_notification_api_proto_goTypes = []any{ - (*SubscribeAllEnvelopesRequest)(nil), // 0: xmtp.xmtpv4.message_api.SubscribeAllEnvelopesRequest - (*SubscribeEnvelopesResponse)(nil), // 1: xmtp.xmtpv4.message_api.SubscribeEnvelopesResponse -} -var file_xmtpv4_message_api_notification_api_proto_depIdxs = []int32{ - 0, // 0: xmtp.xmtpv4.message_api.NotificationApi.SubscribeAllEnvelopes:input_type -> xmtp.xmtpv4.message_api.SubscribeAllEnvelopesRequest - 1, // 1: xmtp.xmtpv4.message_api.NotificationApi.SubscribeAllEnvelopes:output_type -> xmtp.xmtpv4.message_api.SubscribeEnvelopesResponse - 1, // [1:2] is the sub-list for method output_type - 0, // [0:1] 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_xmtpv4_message_api_notification_api_proto_init() } -func file_xmtpv4_message_api_notification_api_proto_init() { - if File_xmtpv4_message_api_notification_api_proto != nil { - return - } - file_xmtpv4_message_api_message_api_proto_init() - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_message_api_notification_api_proto_rawDesc), len(file_xmtpv4_message_api_notification_api_proto_rawDesc)), - NumEnums: 0, - NumMessages: 0, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_xmtpv4_message_api_notification_api_proto_goTypes, - DependencyIndexes: file_xmtpv4_message_api_notification_api_proto_depIdxs, - }.Build() - File_xmtpv4_message_api_notification_api_proto = out.File - file_xmtpv4_message_api_notification_api_proto_goTypes = nil - file_xmtpv4_message_api_notification_api_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/message_api/notification_api_grpc.pb.go b/pkg/proto/xmtpv4/message_api/notification_api_grpc.pb.go deleted file mode 100644 index 997830e4..00000000 --- a/pkg/proto/xmtpv4/message_api/notification_api_grpc.pb.go +++ /dev/null @@ -1,138 +0,0 @@ -// Notification API - Full envelope stream for push notification servers - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: xmtpv4/message_api/notification_api.proto - -package message_api - -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 ( - NotificationApi_SubscribeAllEnvelopes_FullMethodName = "/xmtp.xmtpv4.message_api.NotificationApi/SubscribeAllEnvelopes" -) - -// NotificationApiClient is the client API for NotificationApi 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 NotificationApiClient interface { - SubscribeAllEnvelopes(ctx context.Context, in *SubscribeAllEnvelopesRequest, opts ...grpc.CallOption) (NotificationApi_SubscribeAllEnvelopesClient, error) -} - -type notificationApiClient struct { - cc grpc.ClientConnInterface -} - -func NewNotificationApiClient(cc grpc.ClientConnInterface) NotificationApiClient { - return ¬ificationApiClient{cc} -} - -func (c *notificationApiClient) SubscribeAllEnvelopes(ctx context.Context, in *SubscribeAllEnvelopesRequest, opts ...grpc.CallOption) (NotificationApi_SubscribeAllEnvelopesClient, error) { - stream, err := c.cc.NewStream(ctx, &NotificationApi_ServiceDesc.Streams[0], NotificationApi_SubscribeAllEnvelopes_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := ¬ificationApiSubscribeAllEnvelopesClient{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 NotificationApi_SubscribeAllEnvelopesClient interface { - Recv() (*SubscribeEnvelopesResponse, error) - grpc.ClientStream -} - -type notificationApiSubscribeAllEnvelopesClient struct { - grpc.ClientStream -} - -func (x *notificationApiSubscribeAllEnvelopesClient) Recv() (*SubscribeEnvelopesResponse, error) { - m := new(SubscribeEnvelopesResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -// NotificationApiServer is the server API for NotificationApi service. -// All implementations must embed UnimplementedNotificationApiServer -// for forward compatibility -type NotificationApiServer interface { - SubscribeAllEnvelopes(*SubscribeAllEnvelopesRequest, NotificationApi_SubscribeAllEnvelopesServer) error - mustEmbedUnimplementedNotificationApiServer() -} - -// UnimplementedNotificationApiServer must be embedded to have forward compatible implementations. -type UnimplementedNotificationApiServer struct { -} - -func (UnimplementedNotificationApiServer) SubscribeAllEnvelopes(*SubscribeAllEnvelopesRequest, NotificationApi_SubscribeAllEnvelopesServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeAllEnvelopes not implemented") -} -func (UnimplementedNotificationApiServer) mustEmbedUnimplementedNotificationApiServer() {} - -// UnsafeNotificationApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to NotificationApiServer will -// result in compilation errors. -type UnsafeNotificationApiServer interface { - mustEmbedUnimplementedNotificationApiServer() -} - -func RegisterNotificationApiServer(s grpc.ServiceRegistrar, srv NotificationApiServer) { - s.RegisterService(&NotificationApi_ServiceDesc, srv) -} - -func _NotificationApi_SubscribeAllEnvelopes_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeAllEnvelopesRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(NotificationApiServer).SubscribeAllEnvelopes(m, ¬ificationApiSubscribeAllEnvelopesServer{stream}) -} - -type NotificationApi_SubscribeAllEnvelopesServer interface { - Send(*SubscribeEnvelopesResponse) error - grpc.ServerStream -} - -type notificationApiSubscribeAllEnvelopesServer struct { - grpc.ServerStream -} - -func (x *notificationApiSubscribeAllEnvelopesServer) Send(m *SubscribeEnvelopesResponse) error { - return x.ServerStream.SendMsg(m) -} - -// NotificationApi_ServiceDesc is the grpc.ServiceDesc for NotificationApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var NotificationApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.xmtpv4.message_api.NotificationApi", - HandlerType: (*NotificationApiServer)(nil), - Methods: []grpc.MethodDesc{}, - Streams: []grpc.StreamDesc{ - { - StreamName: "SubscribeAllEnvelopes", - Handler: _NotificationApi_SubscribeAllEnvelopes_Handler, - ServerStreams: true, - }, - }, - Metadata: "xmtpv4/message_api/notification_api.proto", -} diff --git a/pkg/proto/xmtpv4/message_api/publish_api.pb.go b/pkg/proto/xmtpv4/message_api/publish_api.pb.go deleted file mode 100644 index a11b9f89..00000000 --- a/pkg/proto/xmtpv4/message_api/publish_api.pb.go +++ /dev/null @@ -1,71 +0,0 @@ -// Publish API - Gateway to Node publishing - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/message_api/publish_api.proto - -package message_api - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -var File_xmtpv4_message_api_publish_api_proto protoreflect.FileDescriptor - -const file_xmtpv4_message_api_publish_api_proto_rawDesc = "" + - "\n" + - "$xmtpv4/message_api/publish_api.proto\x12\x17xmtp.xmtpv4.message_api\x1a$xmtpv4/message_api/message_api.proto2\x97\x01\n" + - "\n" + - "PublishApi\x12\x88\x01\n" + - "\x15PublishPayerEnvelopes\x125.xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest\x1a6.xmtp.xmtpv4.message_api.PublishPayerEnvelopesResponse\"\x00B\x8f\x02\n" + - "5org.xmtp.android.library.push.xmtp.xmtpv4.message_apiB\x0fPublishApiProtoP\x01ZKgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/message_api\xa2\x02\x03XXM\xaa\x02\x16Xmtp.Xmtpv4.MessageApi\xca\x02\x16Xmtp\\Xmtpv4\\MessageApi\xe2\x02\"Xmtp\\Xmtpv4\\MessageApi\\GPBMetadata\xea\x02\x18Xmtp::Xmtpv4::MessageApib\x06proto3" - -var file_xmtpv4_message_api_publish_api_proto_goTypes = []any{ - (*PublishPayerEnvelopesRequest)(nil), // 0: xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest - (*PublishPayerEnvelopesResponse)(nil), // 1: xmtp.xmtpv4.message_api.PublishPayerEnvelopesResponse -} -var file_xmtpv4_message_api_publish_api_proto_depIdxs = []int32{ - 0, // 0: xmtp.xmtpv4.message_api.PublishApi.PublishPayerEnvelopes:input_type -> xmtp.xmtpv4.message_api.PublishPayerEnvelopesRequest - 1, // 1: xmtp.xmtpv4.message_api.PublishApi.PublishPayerEnvelopes:output_type -> xmtp.xmtpv4.message_api.PublishPayerEnvelopesResponse - 1, // [1:2] is the sub-list for method output_type - 0, // [0:1] 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_xmtpv4_message_api_publish_api_proto_init() } -func file_xmtpv4_message_api_publish_api_proto_init() { - if File_xmtpv4_message_api_publish_api_proto != nil { - return - } - file_xmtpv4_message_api_message_api_proto_init() - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_message_api_publish_api_proto_rawDesc), len(file_xmtpv4_message_api_publish_api_proto_rawDesc)), - NumEnums: 0, - NumMessages: 0, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_xmtpv4_message_api_publish_api_proto_goTypes, - DependencyIndexes: file_xmtpv4_message_api_publish_api_proto_depIdxs, - }.Build() - File_xmtpv4_message_api_publish_api_proto = out.File - file_xmtpv4_message_api_publish_api_proto_goTypes = nil - file_xmtpv4_message_api_publish_api_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/message_api/publish_api_grpc.pb.go b/pkg/proto/xmtpv4/message_api/publish_api_grpc.pb.go deleted file mode 100644 index af15d2ba..00000000 --- a/pkg/proto/xmtpv4/message_api/publish_api_grpc.pb.go +++ /dev/null @@ -1,111 +0,0 @@ -// Publish API - Gateway to Node publishing - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: xmtpv4/message_api/publish_api.proto - -package message_api - -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 ( - PublishApi_PublishPayerEnvelopes_FullMethodName = "/xmtp.xmtpv4.message_api.PublishApi/PublishPayerEnvelopes" -) - -// PublishApiClient is the client API for PublishApi 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 PublishApiClient interface { - PublishPayerEnvelopes(ctx context.Context, in *PublishPayerEnvelopesRequest, opts ...grpc.CallOption) (*PublishPayerEnvelopesResponse, error) -} - -type publishApiClient struct { - cc grpc.ClientConnInterface -} - -func NewPublishApiClient(cc grpc.ClientConnInterface) PublishApiClient { - return &publishApiClient{cc} -} - -func (c *publishApiClient) PublishPayerEnvelopes(ctx context.Context, in *PublishPayerEnvelopesRequest, opts ...grpc.CallOption) (*PublishPayerEnvelopesResponse, error) { - out := new(PublishPayerEnvelopesResponse) - err := c.cc.Invoke(ctx, PublishApi_PublishPayerEnvelopes_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// PublishApiServer is the server API for PublishApi service. -// All implementations must embed UnimplementedPublishApiServer -// for forward compatibility -type PublishApiServer interface { - PublishPayerEnvelopes(context.Context, *PublishPayerEnvelopesRequest) (*PublishPayerEnvelopesResponse, error) - mustEmbedUnimplementedPublishApiServer() -} - -// UnimplementedPublishApiServer must be embedded to have forward compatible implementations. -type UnimplementedPublishApiServer struct { -} - -func (UnimplementedPublishApiServer) PublishPayerEnvelopes(context.Context, *PublishPayerEnvelopesRequest) (*PublishPayerEnvelopesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method PublishPayerEnvelopes not implemented") -} -func (UnimplementedPublishApiServer) mustEmbedUnimplementedPublishApiServer() {} - -// UnsafePublishApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to PublishApiServer will -// result in compilation errors. -type UnsafePublishApiServer interface { - mustEmbedUnimplementedPublishApiServer() -} - -func RegisterPublishApiServer(s grpc.ServiceRegistrar, srv PublishApiServer) { - s.RegisterService(&PublishApi_ServiceDesc, srv) -} - -func _PublishApi_PublishPayerEnvelopes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(PublishPayerEnvelopesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(PublishApiServer).PublishPayerEnvelopes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: PublishApi_PublishPayerEnvelopes_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(PublishApiServer).PublishPayerEnvelopes(ctx, req.(*PublishPayerEnvelopesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// PublishApi_ServiceDesc is the grpc.ServiceDesc for PublishApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var PublishApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.xmtpv4.message_api.PublishApi", - HandlerType: (*PublishApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "PublishPayerEnvelopes", - Handler: _PublishApi_PublishPayerEnvelopes_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "xmtpv4/message_api/publish_api.proto", -} diff --git a/pkg/proto/xmtpv4/message_api/query_api.pb.go b/pkg/proto/xmtpv4/message_api/query_api.pb.go deleted file mode 100644 index 1902f80b..00000000 --- a/pkg/proto/xmtpv4/message_api/query_api.pb.go +++ /dev/null @@ -1,85 +0,0 @@ -// Query API - Client to Node queries and subscriptions - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/message_api/query_api.proto - -package message_api - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -var File_xmtpv4_message_api_query_api_proto protoreflect.FileDescriptor - -const file_xmtpv4_message_api_query_api_proto_rawDesc = "" + - "\n" + - "\"xmtpv4/message_api/query_api.proto\x12\x17xmtp.xmtpv4.message_api\x1a$xmtpv4/message_api/message_api.proto2\xe3\x03\n" + - "\bQueryApi\x12s\n" + - "\x0eQueryEnvelopes\x12..xmtp.xmtpv4.message_api.QueryEnvelopesRequest\x1a/.xmtp.xmtpv4.message_api.QueryEnvelopesResponse\"\x00\x12x\n" + - "\x0fSubscribeTopics\x12/.xmtp.xmtpv4.message_api.SubscribeTopicsRequest\x1a0.xmtp.xmtpv4.message_api.SubscribeTopicsResponse\"\x000\x01\x12j\n" + - "\vGetInboxIds\x12+.xmtp.xmtpv4.message_api.GetInboxIdsRequest\x1a,.xmtp.xmtpv4.message_api.GetInboxIdsResponse\"\x00\x12|\n" + - "\x11GetNewestEnvelope\x121.xmtp.xmtpv4.message_api.GetNewestEnvelopeRequest\x1a2.xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse\"\x00B\x8d\x02\n" + - "5org.xmtp.android.library.push.xmtp.xmtpv4.message_apiB\rQueryApiProtoP\x01ZKgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/message_api\xa2\x02\x03XXM\xaa\x02\x16Xmtp.Xmtpv4.MessageApi\xca\x02\x16Xmtp\\Xmtpv4\\MessageApi\xe2\x02\"Xmtp\\Xmtpv4\\MessageApi\\GPBMetadata\xea\x02\x18Xmtp::Xmtpv4::MessageApib\x06proto3" - -var file_xmtpv4_message_api_query_api_proto_goTypes = []any{ - (*QueryEnvelopesRequest)(nil), // 0: xmtp.xmtpv4.message_api.QueryEnvelopesRequest - (*SubscribeTopicsRequest)(nil), // 1: xmtp.xmtpv4.message_api.SubscribeTopicsRequest - (*GetInboxIdsRequest)(nil), // 2: xmtp.xmtpv4.message_api.GetInboxIdsRequest - (*GetNewestEnvelopeRequest)(nil), // 3: xmtp.xmtpv4.message_api.GetNewestEnvelopeRequest - (*QueryEnvelopesResponse)(nil), // 4: xmtp.xmtpv4.message_api.QueryEnvelopesResponse - (*SubscribeTopicsResponse)(nil), // 5: xmtp.xmtpv4.message_api.SubscribeTopicsResponse - (*GetInboxIdsResponse)(nil), // 6: xmtp.xmtpv4.message_api.GetInboxIdsResponse - (*GetNewestEnvelopeResponse)(nil), // 7: xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse -} -var file_xmtpv4_message_api_query_api_proto_depIdxs = []int32{ - 0, // 0: xmtp.xmtpv4.message_api.QueryApi.QueryEnvelopes:input_type -> xmtp.xmtpv4.message_api.QueryEnvelopesRequest - 1, // 1: xmtp.xmtpv4.message_api.QueryApi.SubscribeTopics:input_type -> xmtp.xmtpv4.message_api.SubscribeTopicsRequest - 2, // 2: xmtp.xmtpv4.message_api.QueryApi.GetInboxIds:input_type -> xmtp.xmtpv4.message_api.GetInboxIdsRequest - 3, // 3: xmtp.xmtpv4.message_api.QueryApi.GetNewestEnvelope:input_type -> xmtp.xmtpv4.message_api.GetNewestEnvelopeRequest - 4, // 4: xmtp.xmtpv4.message_api.QueryApi.QueryEnvelopes:output_type -> xmtp.xmtpv4.message_api.QueryEnvelopesResponse - 5, // 5: xmtp.xmtpv4.message_api.QueryApi.SubscribeTopics:output_type -> xmtp.xmtpv4.message_api.SubscribeTopicsResponse - 6, // 6: xmtp.xmtpv4.message_api.QueryApi.GetInboxIds:output_type -> xmtp.xmtpv4.message_api.GetInboxIdsResponse - 7, // 7: xmtp.xmtpv4.message_api.QueryApi.GetNewestEnvelope:output_type -> xmtp.xmtpv4.message_api.GetNewestEnvelopeResponse - 4, // [4:8] is the sub-list for method output_type - 0, // [0:4] 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_xmtpv4_message_api_query_api_proto_init() } -func file_xmtpv4_message_api_query_api_proto_init() { - if File_xmtpv4_message_api_query_api_proto != nil { - return - } - file_xmtpv4_message_api_message_api_proto_init() - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_message_api_query_api_proto_rawDesc), len(file_xmtpv4_message_api_query_api_proto_rawDesc)), - NumEnums: 0, - NumMessages: 0, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_xmtpv4_message_api_query_api_proto_goTypes, - DependencyIndexes: file_xmtpv4_message_api_query_api_proto_depIdxs, - }.Build() - File_xmtpv4_message_api_query_api_proto = out.File - file_xmtpv4_message_api_query_api_proto_goTypes = nil - file_xmtpv4_message_api_query_api_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/message_api/query_api_grpc.pb.go b/pkg/proto/xmtpv4/message_api/query_api_grpc.pb.go deleted file mode 100644 index 699804cd..00000000 --- a/pkg/proto/xmtpv4/message_api/query_api_grpc.pb.go +++ /dev/null @@ -1,250 +0,0 @@ -// Query API - Client to Node queries and subscriptions - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: xmtpv4/message_api/query_api.proto - -package message_api - -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 ( - QueryApi_QueryEnvelopes_FullMethodName = "/xmtp.xmtpv4.message_api.QueryApi/QueryEnvelopes" - QueryApi_SubscribeTopics_FullMethodName = "/xmtp.xmtpv4.message_api.QueryApi/SubscribeTopics" - QueryApi_GetInboxIds_FullMethodName = "/xmtp.xmtpv4.message_api.QueryApi/GetInboxIds" - QueryApi_GetNewestEnvelope_FullMethodName = "/xmtp.xmtpv4.message_api.QueryApi/GetNewestEnvelope" -) - -// QueryApiClient is the client API for QueryApi 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 QueryApiClient interface { - QueryEnvelopes(ctx context.Context, in *QueryEnvelopesRequest, opts ...grpc.CallOption) (*QueryEnvelopesResponse, error) - SubscribeTopics(ctx context.Context, in *SubscribeTopicsRequest, opts ...grpc.CallOption) (QueryApi_SubscribeTopicsClient, error) - GetInboxIds(ctx context.Context, in *GetInboxIdsRequest, opts ...grpc.CallOption) (*GetInboxIdsResponse, error) - GetNewestEnvelope(ctx context.Context, in *GetNewestEnvelopeRequest, opts ...grpc.CallOption) (*GetNewestEnvelopeResponse, error) -} - -type queryApiClient struct { - cc grpc.ClientConnInterface -} - -func NewQueryApiClient(cc grpc.ClientConnInterface) QueryApiClient { - return &queryApiClient{cc} -} - -func (c *queryApiClient) QueryEnvelopes(ctx context.Context, in *QueryEnvelopesRequest, opts ...grpc.CallOption) (*QueryEnvelopesResponse, error) { - out := new(QueryEnvelopesResponse) - err := c.cc.Invoke(ctx, QueryApi_QueryEnvelopes_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *queryApiClient) SubscribeTopics(ctx context.Context, in *SubscribeTopicsRequest, opts ...grpc.CallOption) (QueryApi_SubscribeTopicsClient, error) { - stream, err := c.cc.NewStream(ctx, &QueryApi_ServiceDesc.Streams[0], QueryApi_SubscribeTopics_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &queryApiSubscribeTopicsClient{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 QueryApi_SubscribeTopicsClient interface { - Recv() (*SubscribeTopicsResponse, error) - grpc.ClientStream -} - -type queryApiSubscribeTopicsClient struct { - grpc.ClientStream -} - -func (x *queryApiSubscribeTopicsClient) Recv() (*SubscribeTopicsResponse, error) { - m := new(SubscribeTopicsResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *queryApiClient) GetInboxIds(ctx context.Context, in *GetInboxIdsRequest, opts ...grpc.CallOption) (*GetInboxIdsResponse, error) { - out := new(GetInboxIdsResponse) - err := c.cc.Invoke(ctx, QueryApi_GetInboxIds_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *queryApiClient) GetNewestEnvelope(ctx context.Context, in *GetNewestEnvelopeRequest, opts ...grpc.CallOption) (*GetNewestEnvelopeResponse, error) { - out := new(GetNewestEnvelopeResponse) - err := c.cc.Invoke(ctx, QueryApi_GetNewestEnvelope_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// QueryApiServer is the server API for QueryApi service. -// All implementations must embed UnimplementedQueryApiServer -// for forward compatibility -type QueryApiServer interface { - QueryEnvelopes(context.Context, *QueryEnvelopesRequest) (*QueryEnvelopesResponse, error) - SubscribeTopics(*SubscribeTopicsRequest, QueryApi_SubscribeTopicsServer) error - GetInboxIds(context.Context, *GetInboxIdsRequest) (*GetInboxIdsResponse, error) - GetNewestEnvelope(context.Context, *GetNewestEnvelopeRequest) (*GetNewestEnvelopeResponse, error) - mustEmbedUnimplementedQueryApiServer() -} - -// UnimplementedQueryApiServer must be embedded to have forward compatible implementations. -type UnimplementedQueryApiServer struct { -} - -func (UnimplementedQueryApiServer) QueryEnvelopes(context.Context, *QueryEnvelopesRequest) (*QueryEnvelopesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method QueryEnvelopes not implemented") -} -func (UnimplementedQueryApiServer) SubscribeTopics(*SubscribeTopicsRequest, QueryApi_SubscribeTopicsServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeTopics not implemented") -} -func (UnimplementedQueryApiServer) GetInboxIds(context.Context, *GetInboxIdsRequest) (*GetInboxIdsResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetInboxIds not implemented") -} -func (UnimplementedQueryApiServer) GetNewestEnvelope(context.Context, *GetNewestEnvelopeRequest) (*GetNewestEnvelopeResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetNewestEnvelope not implemented") -} -func (UnimplementedQueryApiServer) mustEmbedUnimplementedQueryApiServer() {} - -// UnsafeQueryApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to QueryApiServer will -// result in compilation errors. -type UnsafeQueryApiServer interface { - mustEmbedUnimplementedQueryApiServer() -} - -func RegisterQueryApiServer(s grpc.ServiceRegistrar, srv QueryApiServer) { - s.RegisterService(&QueryApi_ServiceDesc, srv) -} - -func _QueryApi_QueryEnvelopes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(QueryEnvelopesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(QueryApiServer).QueryEnvelopes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: QueryApi_QueryEnvelopes_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(QueryApiServer).QueryEnvelopes(ctx, req.(*QueryEnvelopesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _QueryApi_SubscribeTopics_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeTopicsRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(QueryApiServer).SubscribeTopics(m, &queryApiSubscribeTopicsServer{stream}) -} - -type QueryApi_SubscribeTopicsServer interface { - Send(*SubscribeTopicsResponse) error - grpc.ServerStream -} - -type queryApiSubscribeTopicsServer struct { - grpc.ServerStream -} - -func (x *queryApiSubscribeTopicsServer) Send(m *SubscribeTopicsResponse) error { - return x.ServerStream.SendMsg(m) -} - -func _QueryApi_GetInboxIds_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetInboxIdsRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(QueryApiServer).GetInboxIds(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: QueryApi_GetInboxIds_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(QueryApiServer).GetInboxIds(ctx, req.(*GetInboxIdsRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _QueryApi_GetNewestEnvelope_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetNewestEnvelopeRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(QueryApiServer).GetNewestEnvelope(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: QueryApi_GetNewestEnvelope_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(QueryApiServer).GetNewestEnvelope(ctx, req.(*GetNewestEnvelopeRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// QueryApi_ServiceDesc is the grpc.ServiceDesc for QueryApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var QueryApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.xmtpv4.message_api.QueryApi", - HandlerType: (*QueryApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "QueryEnvelopes", - Handler: _QueryApi_QueryEnvelopes_Handler, - }, - { - MethodName: "GetInboxIds", - Handler: _QueryApi_GetInboxIds_Handler, - }, - { - MethodName: "GetNewestEnvelope", - Handler: _QueryApi_GetNewestEnvelope_Handler, - }, - }, - Streams: []grpc.StreamDesc{ - { - StreamName: "SubscribeTopics", - Handler: _QueryApi_SubscribeTopics_Handler, - ServerStreams: true, - }, - }, - Metadata: "xmtpv4/message_api/query_api.proto", -} diff --git a/pkg/proto/xmtpv4/metadata_api/metadata_api.pb.go b/pkg/proto/xmtpv4/metadata_api/metadata_api.pb.go deleted file mode 100644 index 66ffdfdc..00000000 --- a/pkg/proto/xmtpv4/metadata_api/metadata_api.pb.go +++ /dev/null @@ -1,550 +0,0 @@ -// Metadata API - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/metadata_api/metadata_api.proto - -package metadata_api - -import ( - envelopes "github.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/envelopes" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Whether to group spend by hour or day -type PayerInfoGranularity int32 - -const ( - PayerInfoGranularity_PAYER_INFO_GRANULARITY_UNSPECIFIED PayerInfoGranularity = 0 - PayerInfoGranularity_PAYER_INFO_GRANULARITY_HOUR PayerInfoGranularity = 1 - PayerInfoGranularity_PAYER_INFO_GRANULARITY_DAY PayerInfoGranularity = 2 -) - -// Enum value maps for PayerInfoGranularity. -var ( - PayerInfoGranularity_name = map[int32]string{ - 0: "PAYER_INFO_GRANULARITY_UNSPECIFIED", - 1: "PAYER_INFO_GRANULARITY_HOUR", - 2: "PAYER_INFO_GRANULARITY_DAY", - } - PayerInfoGranularity_value = map[string]int32{ - "PAYER_INFO_GRANULARITY_UNSPECIFIED": 0, - "PAYER_INFO_GRANULARITY_HOUR": 1, - "PAYER_INFO_GRANULARITY_DAY": 2, - } -) - -func (x PayerInfoGranularity) Enum() *PayerInfoGranularity { - p := new(PayerInfoGranularity) - *p = x - return p -} - -func (x PayerInfoGranularity) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (PayerInfoGranularity) Descriptor() protoreflect.EnumDescriptor { - return file_xmtpv4_metadata_api_metadata_api_proto_enumTypes[0].Descriptor() -} - -func (PayerInfoGranularity) Type() protoreflect.EnumType { - return &file_xmtpv4_metadata_api_metadata_api_proto_enumTypes[0] -} - -func (x PayerInfoGranularity) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use PayerInfoGranularity.Descriptor instead. -func (PayerInfoGranularity) EnumDescriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{0} -} - -type GetSyncCursorRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetSyncCursorRequest) Reset() { - *x = GetSyncCursorRequest{} - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetSyncCursorRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetSyncCursorRequest) ProtoMessage() {} - -func (x *GetSyncCursorRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetSyncCursorRequest.ProtoReflect.Descriptor instead. -func (*GetSyncCursorRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{0} -} - -type GetSyncCursorResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - LatestSync *envelopes.Cursor `protobuf:"bytes,1,opt,name=latest_sync,json=latestSync,proto3" json:"latest_sync,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetSyncCursorResponse) Reset() { - *x = GetSyncCursorResponse{} - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetSyncCursorResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetSyncCursorResponse) ProtoMessage() {} - -func (x *GetSyncCursorResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetSyncCursorResponse.ProtoReflect.Descriptor instead. -func (*GetSyncCursorResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{1} -} - -func (x *GetSyncCursorResponse) GetLatestSync() *envelopes.Cursor { - if x != nil { - return x.LatestSync - } - return nil -} - -type GetVersionRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetVersionRequest) Reset() { - *x = GetVersionRequest{} - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetVersionRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetVersionRequest) ProtoMessage() {} - -func (x *GetVersionRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetVersionRequest.ProtoReflect.Descriptor instead. -func (*GetVersionRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{2} -} - -type GetVersionResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetVersionResponse) Reset() { - *x = GetVersionResponse{} - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetVersionResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetVersionResponse) ProtoMessage() {} - -func (x *GetVersionResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetVersionResponse.ProtoReflect.Descriptor instead. -func (*GetVersionResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{3} -} - -func (x *GetVersionResponse) GetVersion() string { - if x != nil { - return x.Version - } - return "" -} - -// Get information about payer spend and message counts for a given time period -type GetPayerInfoRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - PayerAddresses []string `protobuf:"bytes,1,rep,name=payer_addresses,json=payerAddresses,proto3" json:"payer_addresses,omitempty"` - Granularity PayerInfoGranularity `protobuf:"varint,2,opt,name=granularity,proto3,enum=xmtp.xmtpv4.metadata_api.PayerInfoGranularity" json:"granularity,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetPayerInfoRequest) Reset() { - *x = GetPayerInfoRequest{} - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetPayerInfoRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetPayerInfoRequest) ProtoMessage() {} - -func (x *GetPayerInfoRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetPayerInfoRequest.ProtoReflect.Descriptor instead. -func (*GetPayerInfoRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{4} -} - -func (x *GetPayerInfoRequest) GetPayerAddresses() []string { - if x != nil { - return x.PayerAddresses - } - return nil -} - -func (x *GetPayerInfoRequest) GetGranularity() PayerInfoGranularity { - if x != nil { - return x.Granularity - } - return PayerInfoGranularity_PAYER_INFO_GRANULARITY_UNSPECIFIED -} - -// Response to GetPayerInfoRequest -type GetPayerInfoResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Map of payer address - PayerInfo map[string]*GetPayerInfoResponse_PayerInfo `protobuf:"bytes,1,rep,name=payer_info,json=payerInfo,proto3" json:"payer_info,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetPayerInfoResponse) Reset() { - *x = GetPayerInfoResponse{} - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetPayerInfoResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetPayerInfoResponse) ProtoMessage() {} - -func (x *GetPayerInfoResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetPayerInfoResponse.ProtoReflect.Descriptor instead. -func (*GetPayerInfoResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{5} -} - -func (x *GetPayerInfoResponse) GetPayerInfo() map[string]*GetPayerInfoResponse_PayerInfo { - if x != nil { - return x.PayerInfo - } - return nil -} - -type GetPayerInfoResponse_PeriodSummary struct { - state protoimpl.MessageState `protogen:"open.v1"` - AmountSpentPicodollars uint64 `protobuf:"varint,1,opt,name=amount_spent_picodollars,json=amountSpentPicodollars,proto3" json:"amount_spent_picodollars,omitempty"` - NumMessages uint64 `protobuf:"varint,2,opt,name=num_messages,json=numMessages,proto3" json:"num_messages,omitempty"` - PeriodStartUnixSeconds uint64 `protobuf:"varint,3,opt,name=period_start_unix_seconds,json=periodStartUnixSeconds,proto3" json:"period_start_unix_seconds,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetPayerInfoResponse_PeriodSummary) Reset() { - *x = GetPayerInfoResponse_PeriodSummary{} - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetPayerInfoResponse_PeriodSummary) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetPayerInfoResponse_PeriodSummary) ProtoMessage() {} - -func (x *GetPayerInfoResponse_PeriodSummary) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetPayerInfoResponse_PeriodSummary.ProtoReflect.Descriptor instead. -func (*GetPayerInfoResponse_PeriodSummary) Descriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{5, 0} -} - -func (x *GetPayerInfoResponse_PeriodSummary) GetAmountSpentPicodollars() uint64 { - if x != nil { - return x.AmountSpentPicodollars - } - return 0 -} - -func (x *GetPayerInfoResponse_PeriodSummary) GetNumMessages() uint64 { - if x != nil { - return x.NumMessages - } - return 0 -} - -func (x *GetPayerInfoResponse_PeriodSummary) GetPeriodStartUnixSeconds() uint64 { - if x != nil { - return x.PeriodStartUnixSeconds - } - return 0 -} - -type GetPayerInfoResponse_PayerInfo struct { - state protoimpl.MessageState `protogen:"open.v1"` - PeriodSummaries []*GetPayerInfoResponse_PeriodSummary `protobuf:"bytes,1,rep,name=period_summaries,json=periodSummaries,proto3" json:"period_summaries,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetPayerInfoResponse_PayerInfo) Reset() { - *x = GetPayerInfoResponse_PayerInfo{} - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetPayerInfoResponse_PayerInfo) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetPayerInfoResponse_PayerInfo) ProtoMessage() {} - -func (x *GetPayerInfoResponse_PayerInfo) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_metadata_api_metadata_api_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetPayerInfoResponse_PayerInfo.ProtoReflect.Descriptor instead. -func (*GetPayerInfoResponse_PayerInfo) Descriptor() ([]byte, []int) { - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP(), []int{5, 1} -} - -func (x *GetPayerInfoResponse_PayerInfo) GetPeriodSummaries() []*GetPayerInfoResponse_PeriodSummary { - if x != nil { - return x.PeriodSummaries - } - return nil -} - -var File_xmtpv4_metadata_api_metadata_api_proto protoreflect.FileDescriptor - -const file_xmtpv4_metadata_api_metadata_api_proto_rawDesc = "" + - "\n" + - "&xmtpv4/metadata_api/metadata_api.proto\x12\x18xmtp.xmtpv4.metadata_api\x1a xmtpv4/envelopes/envelopes.proto\"\x16\n" + - "\x14GetSyncCursorRequest\"W\n" + - "\x15GetSyncCursorResponse\x12>\n" + - "\vlatest_sync\x18\x01 \x01(\v2\x1d.xmtp.xmtpv4.envelopes.CursorR\n" + - "latestSync\"\x13\n" + - "\x11GetVersionRequest\".\n" + - "\x12GetVersionResponse\x12\x18\n" + - "\aversion\x18\x01 \x01(\tR\aversion\"\x90\x01\n" + - "\x13GetPayerInfoRequest\x12'\n" + - "\x0fpayer_addresses\x18\x01 \x03(\tR\x0epayerAddresses\x12P\n" + - "\vgranularity\x18\x02 \x01(\x0e2..xmtp.xmtpv4.metadata_api.PayerInfoGranularityR\vgranularity\"\x8c\x04\n" + - "\x14GetPayerInfoResponse\x12\\\n" + - "\n" + - "payer_info\x18\x01 \x03(\v2=.xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PayerInfoEntryR\tpayerInfo\x1a\xa7\x01\n" + - "\rPeriodSummary\x128\n" + - "\x18amount_spent_picodollars\x18\x01 \x01(\x04R\x16amountSpentPicodollars\x12!\n" + - "\fnum_messages\x18\x02 \x01(\x04R\vnumMessages\x129\n" + - "\x19period_start_unix_seconds\x18\x03 \x01(\x04R\x16periodStartUnixSeconds\x1at\n" + - "\tPayerInfo\x12g\n" + - "\x10period_summaries\x18\x01 \x03(\v2<.xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PeriodSummaryR\x0fperiodSummaries\x1av\n" + - "\x0ePayerInfoEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\tR\x03key\x12N\n" + - "\x05value\x18\x02 \x01(\v28.xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PayerInfoR\x05value:\x028\x01*\x7f\n" + - "\x14PayerInfoGranularity\x12&\n" + - "\"PAYER_INFO_GRANULARITY_UNSPECIFIED\x10\x00\x12\x1f\n" + - "\x1bPAYER_INFO_GRANULARITY_HOUR\x10\x01\x12\x1e\n" + - "\x1aPAYER_INFO_GRANULARITY_DAY\x10\x022\xd9\x03\n" + - "\vMetadataApi\x12r\n" + - "\rGetSyncCursor\x12..xmtp.xmtpv4.metadata_api.GetSyncCursorRequest\x1a/.xmtp.xmtpv4.metadata_api.GetSyncCursorResponse\"\x00\x12z\n" + - "\x13SubscribeSyncCursor\x12..xmtp.xmtpv4.metadata_api.GetSyncCursorRequest\x1a/.xmtp.xmtpv4.metadata_api.GetSyncCursorResponse\"\x000\x01\x12i\n" + - "\n" + - "GetVersion\x12+.xmtp.xmtpv4.metadata_api.GetVersionRequest\x1a,.xmtp.xmtpv4.metadata_api.GetVersionResponse\"\x00\x12o\n" + - "\fGetPayerInfo\x12-.xmtp.xmtpv4.metadata_api.GetPayerInfoRequest\x1a..xmtp.xmtpv4.metadata_api.GetPayerInfoResponse\"\x00B\x96\x02\n" + - "6org.xmtp.android.library.push.xmtp.xmtpv4.metadata_apiB\x10MetadataApiProtoP\x01ZLgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/metadata_api\xa2\x02\x03XXM\xaa\x02\x17Xmtp.Xmtpv4.MetadataApi\xca\x02\x17Xmtp\\Xmtpv4\\MetadataApi\xe2\x02#Xmtp\\Xmtpv4\\MetadataApi\\GPBMetadata\xea\x02\x19Xmtp::Xmtpv4::MetadataApib\x06proto3" - -var ( - file_xmtpv4_metadata_api_metadata_api_proto_rawDescOnce sync.Once - file_xmtpv4_metadata_api_metadata_api_proto_rawDescData []byte -) - -func file_xmtpv4_metadata_api_metadata_api_proto_rawDescGZIP() []byte { - file_xmtpv4_metadata_api_metadata_api_proto_rawDescOnce.Do(func() { - file_xmtpv4_metadata_api_metadata_api_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_xmtpv4_metadata_api_metadata_api_proto_rawDesc), len(file_xmtpv4_metadata_api_metadata_api_proto_rawDesc))) - }) - return file_xmtpv4_metadata_api_metadata_api_proto_rawDescData -} - -var file_xmtpv4_metadata_api_metadata_api_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_xmtpv4_metadata_api_metadata_api_proto_msgTypes = make([]protoimpl.MessageInfo, 9) -var file_xmtpv4_metadata_api_metadata_api_proto_goTypes = []any{ - (PayerInfoGranularity)(0), // 0: xmtp.xmtpv4.metadata_api.PayerInfoGranularity - (*GetSyncCursorRequest)(nil), // 1: xmtp.xmtpv4.metadata_api.GetSyncCursorRequest - (*GetSyncCursorResponse)(nil), // 2: xmtp.xmtpv4.metadata_api.GetSyncCursorResponse - (*GetVersionRequest)(nil), // 3: xmtp.xmtpv4.metadata_api.GetVersionRequest - (*GetVersionResponse)(nil), // 4: xmtp.xmtpv4.metadata_api.GetVersionResponse - (*GetPayerInfoRequest)(nil), // 5: xmtp.xmtpv4.metadata_api.GetPayerInfoRequest - (*GetPayerInfoResponse)(nil), // 6: xmtp.xmtpv4.metadata_api.GetPayerInfoResponse - (*GetPayerInfoResponse_PeriodSummary)(nil), // 7: xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PeriodSummary - (*GetPayerInfoResponse_PayerInfo)(nil), // 8: xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PayerInfo - nil, // 9: xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PayerInfoEntry - (*envelopes.Cursor)(nil), // 10: xmtp.xmtpv4.envelopes.Cursor -} -var file_xmtpv4_metadata_api_metadata_api_proto_depIdxs = []int32{ - 10, // 0: xmtp.xmtpv4.metadata_api.GetSyncCursorResponse.latest_sync:type_name -> xmtp.xmtpv4.envelopes.Cursor - 0, // 1: xmtp.xmtpv4.metadata_api.GetPayerInfoRequest.granularity:type_name -> xmtp.xmtpv4.metadata_api.PayerInfoGranularity - 9, // 2: xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.payer_info:type_name -> xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PayerInfoEntry - 7, // 3: xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PayerInfo.period_summaries:type_name -> xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PeriodSummary - 8, // 4: xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PayerInfoEntry.value:type_name -> xmtp.xmtpv4.metadata_api.GetPayerInfoResponse.PayerInfo - 1, // 5: xmtp.xmtpv4.metadata_api.MetadataApi.GetSyncCursor:input_type -> xmtp.xmtpv4.metadata_api.GetSyncCursorRequest - 1, // 6: xmtp.xmtpv4.metadata_api.MetadataApi.SubscribeSyncCursor:input_type -> xmtp.xmtpv4.metadata_api.GetSyncCursorRequest - 3, // 7: xmtp.xmtpv4.metadata_api.MetadataApi.GetVersion:input_type -> xmtp.xmtpv4.metadata_api.GetVersionRequest - 5, // 8: xmtp.xmtpv4.metadata_api.MetadataApi.GetPayerInfo:input_type -> xmtp.xmtpv4.metadata_api.GetPayerInfoRequest - 2, // 9: xmtp.xmtpv4.metadata_api.MetadataApi.GetSyncCursor:output_type -> xmtp.xmtpv4.metadata_api.GetSyncCursorResponse - 2, // 10: xmtp.xmtpv4.metadata_api.MetadataApi.SubscribeSyncCursor:output_type -> xmtp.xmtpv4.metadata_api.GetSyncCursorResponse - 4, // 11: xmtp.xmtpv4.metadata_api.MetadataApi.GetVersion:output_type -> xmtp.xmtpv4.metadata_api.GetVersionResponse - 6, // 12: xmtp.xmtpv4.metadata_api.MetadataApi.GetPayerInfo:output_type -> xmtp.xmtpv4.metadata_api.GetPayerInfoResponse - 9, // [9:13] is the sub-list for method output_type - 5, // [5:9] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name -} - -func init() { file_xmtpv4_metadata_api_metadata_api_proto_init() } -func file_xmtpv4_metadata_api_metadata_api_proto_init() { - if File_xmtpv4_metadata_api_metadata_api_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_metadata_api_metadata_api_proto_rawDesc), len(file_xmtpv4_metadata_api_metadata_api_proto_rawDesc)), - NumEnums: 1, - NumMessages: 9, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_xmtpv4_metadata_api_metadata_api_proto_goTypes, - DependencyIndexes: file_xmtpv4_metadata_api_metadata_api_proto_depIdxs, - EnumInfos: file_xmtpv4_metadata_api_metadata_api_proto_enumTypes, - MessageInfos: file_xmtpv4_metadata_api_metadata_api_proto_msgTypes, - }.Build() - File_xmtpv4_metadata_api_metadata_api_proto = out.File - file_xmtpv4_metadata_api_metadata_api_proto_goTypes = nil - file_xmtpv4_metadata_api_metadata_api_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/metadata_api/metadata_api_grpc.pb.go b/pkg/proto/xmtpv4/metadata_api/metadata_api_grpc.pb.go deleted file mode 100644 index b2d92ac3..00000000 --- a/pkg/proto/xmtpv4/metadata_api/metadata_api_grpc.pb.go +++ /dev/null @@ -1,250 +0,0 @@ -// Metadata API - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: xmtpv4/metadata_api/metadata_api.proto - -package metadata_api - -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 ( - MetadataApi_GetSyncCursor_FullMethodName = "/xmtp.xmtpv4.metadata_api.MetadataApi/GetSyncCursor" - MetadataApi_SubscribeSyncCursor_FullMethodName = "/xmtp.xmtpv4.metadata_api.MetadataApi/SubscribeSyncCursor" - MetadataApi_GetVersion_FullMethodName = "/xmtp.xmtpv4.metadata_api.MetadataApi/GetVersion" - MetadataApi_GetPayerInfo_FullMethodName = "/xmtp.xmtpv4.metadata_api.MetadataApi/GetPayerInfo" -) - -// MetadataApiClient is the client API for MetadataApi 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 MetadataApiClient interface { - GetSyncCursor(ctx context.Context, in *GetSyncCursorRequest, opts ...grpc.CallOption) (*GetSyncCursorResponse, error) - SubscribeSyncCursor(ctx context.Context, in *GetSyncCursorRequest, opts ...grpc.CallOption) (MetadataApi_SubscribeSyncCursorClient, error) - GetVersion(ctx context.Context, in *GetVersionRequest, opts ...grpc.CallOption) (*GetVersionResponse, error) - GetPayerInfo(ctx context.Context, in *GetPayerInfoRequest, opts ...grpc.CallOption) (*GetPayerInfoResponse, error) -} - -type metadataApiClient struct { - cc grpc.ClientConnInterface -} - -func NewMetadataApiClient(cc grpc.ClientConnInterface) MetadataApiClient { - return &metadataApiClient{cc} -} - -func (c *metadataApiClient) GetSyncCursor(ctx context.Context, in *GetSyncCursorRequest, opts ...grpc.CallOption) (*GetSyncCursorResponse, error) { - out := new(GetSyncCursorResponse) - err := c.cc.Invoke(ctx, MetadataApi_GetSyncCursor_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *metadataApiClient) SubscribeSyncCursor(ctx context.Context, in *GetSyncCursorRequest, opts ...grpc.CallOption) (MetadataApi_SubscribeSyncCursorClient, error) { - stream, err := c.cc.NewStream(ctx, &MetadataApi_ServiceDesc.Streams[0], MetadataApi_SubscribeSyncCursor_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &metadataApiSubscribeSyncCursorClient{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 MetadataApi_SubscribeSyncCursorClient interface { - Recv() (*GetSyncCursorResponse, error) - grpc.ClientStream -} - -type metadataApiSubscribeSyncCursorClient struct { - grpc.ClientStream -} - -func (x *metadataApiSubscribeSyncCursorClient) Recv() (*GetSyncCursorResponse, error) { - m := new(GetSyncCursorResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *metadataApiClient) GetVersion(ctx context.Context, in *GetVersionRequest, opts ...grpc.CallOption) (*GetVersionResponse, error) { - out := new(GetVersionResponse) - err := c.cc.Invoke(ctx, MetadataApi_GetVersion_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *metadataApiClient) GetPayerInfo(ctx context.Context, in *GetPayerInfoRequest, opts ...grpc.CallOption) (*GetPayerInfoResponse, error) { - out := new(GetPayerInfoResponse) - err := c.cc.Invoke(ctx, MetadataApi_GetPayerInfo_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// MetadataApiServer is the server API for MetadataApi service. -// All implementations must embed UnimplementedMetadataApiServer -// for forward compatibility -type MetadataApiServer interface { - GetSyncCursor(context.Context, *GetSyncCursorRequest) (*GetSyncCursorResponse, error) - SubscribeSyncCursor(*GetSyncCursorRequest, MetadataApi_SubscribeSyncCursorServer) error - GetVersion(context.Context, *GetVersionRequest) (*GetVersionResponse, error) - GetPayerInfo(context.Context, *GetPayerInfoRequest) (*GetPayerInfoResponse, error) - mustEmbedUnimplementedMetadataApiServer() -} - -// UnimplementedMetadataApiServer must be embedded to have forward compatible implementations. -type UnimplementedMetadataApiServer struct { -} - -func (UnimplementedMetadataApiServer) GetSyncCursor(context.Context, *GetSyncCursorRequest) (*GetSyncCursorResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetSyncCursor not implemented") -} -func (UnimplementedMetadataApiServer) SubscribeSyncCursor(*GetSyncCursorRequest, MetadataApi_SubscribeSyncCursorServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeSyncCursor not implemented") -} -func (UnimplementedMetadataApiServer) GetVersion(context.Context, *GetVersionRequest) (*GetVersionResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetVersion not implemented") -} -func (UnimplementedMetadataApiServer) GetPayerInfo(context.Context, *GetPayerInfoRequest) (*GetPayerInfoResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetPayerInfo not implemented") -} -func (UnimplementedMetadataApiServer) mustEmbedUnimplementedMetadataApiServer() {} - -// UnsafeMetadataApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to MetadataApiServer will -// result in compilation errors. -type UnsafeMetadataApiServer interface { - mustEmbedUnimplementedMetadataApiServer() -} - -func RegisterMetadataApiServer(s grpc.ServiceRegistrar, srv MetadataApiServer) { - s.RegisterService(&MetadataApi_ServiceDesc, srv) -} - -func _MetadataApi_GetSyncCursor_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetSyncCursorRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MetadataApiServer).GetSyncCursor(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MetadataApi_GetSyncCursor_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MetadataApiServer).GetSyncCursor(ctx, req.(*GetSyncCursorRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MetadataApi_SubscribeSyncCursor_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(GetSyncCursorRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(MetadataApiServer).SubscribeSyncCursor(m, &metadataApiSubscribeSyncCursorServer{stream}) -} - -type MetadataApi_SubscribeSyncCursorServer interface { - Send(*GetSyncCursorResponse) error - grpc.ServerStream -} - -type metadataApiSubscribeSyncCursorServer struct { - grpc.ServerStream -} - -func (x *metadataApiSubscribeSyncCursorServer) Send(m *GetSyncCursorResponse) error { - return x.ServerStream.SendMsg(m) -} - -func _MetadataApi_GetVersion_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetVersionRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MetadataApiServer).GetVersion(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MetadataApi_GetVersion_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MetadataApiServer).GetVersion(ctx, req.(*GetVersionRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _MetadataApi_GetPayerInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetPayerInfoRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MetadataApiServer).GetPayerInfo(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: MetadataApi_GetPayerInfo_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MetadataApiServer).GetPayerInfo(ctx, req.(*GetPayerInfoRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// MetadataApi_ServiceDesc is the grpc.ServiceDesc for MetadataApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var MetadataApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.xmtpv4.metadata_api.MetadataApi", - HandlerType: (*MetadataApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "GetSyncCursor", - Handler: _MetadataApi_GetSyncCursor_Handler, - }, - { - MethodName: "GetVersion", - Handler: _MetadataApi_GetVersion_Handler, - }, - { - MethodName: "GetPayerInfo", - Handler: _MetadataApi_GetPayerInfo_Handler, - }, - }, - Streams: []grpc.StreamDesc{ - { - StreamName: "SubscribeSyncCursor", - Handler: _MetadataApi_SubscribeSyncCursor_Handler, - ServerStreams: true, - }, - }, - Metadata: "xmtpv4/metadata_api/metadata_api.proto", -} diff --git a/pkg/proto/xmtpv4/payer_api/payer_api.pb.go b/pkg/proto/xmtpv4/payer_api/payer_api.pb.go deleted file mode 100644 index e1feff76..00000000 --- a/pkg/proto/xmtpv4/payer_api/payer_api.pb.go +++ /dev/null @@ -1,275 +0,0 @@ -// Payer API - -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.11 -// protoc (unknown) -// source: xmtpv4/payer_api/payer_api.proto - -package payer_api - -import ( - envelopes "github.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/envelopes" - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type PublishClientEnvelopesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Envelopes []*envelopes.ClientEnvelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishClientEnvelopesRequest) Reset() { - *x = PublishClientEnvelopesRequest{} - mi := &file_xmtpv4_payer_api_payer_api_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishClientEnvelopesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishClientEnvelopesRequest) ProtoMessage() {} - -func (x *PublishClientEnvelopesRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_payer_api_payer_api_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishClientEnvelopesRequest.ProtoReflect.Descriptor instead. -func (*PublishClientEnvelopesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_payer_api_payer_api_proto_rawDescGZIP(), []int{0} -} - -func (x *PublishClientEnvelopesRequest) GetEnvelopes() []*envelopes.ClientEnvelope { - if x != nil { - return x.Envelopes - } - return nil -} - -type PublishClientEnvelopesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - OriginatorEnvelopes []*envelopes.OriginatorEnvelope `protobuf:"bytes,1,rep,name=originator_envelopes,json=originatorEnvelopes,proto3" json:"originator_envelopes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *PublishClientEnvelopesResponse) Reset() { - *x = PublishClientEnvelopesResponse{} - mi := &file_xmtpv4_payer_api_payer_api_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *PublishClientEnvelopesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PublishClientEnvelopesResponse) ProtoMessage() {} - -func (x *PublishClientEnvelopesResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_payer_api_payer_api_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use PublishClientEnvelopesResponse.ProtoReflect.Descriptor instead. -func (*PublishClientEnvelopesResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_payer_api_payer_api_proto_rawDescGZIP(), []int{1} -} - -func (x *PublishClientEnvelopesResponse) GetOriginatorEnvelopes() []*envelopes.OriginatorEnvelope { - if x != nil { - return x.OriginatorEnvelopes - } - return nil -} - -type GetNodesRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetNodesRequest) Reset() { - *x = GetNodesRequest{} - mi := &file_xmtpv4_payer_api_payer_api_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetNodesRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetNodesRequest) ProtoMessage() {} - -func (x *GetNodesRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_payer_api_payer_api_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetNodesRequest.ProtoReflect.Descriptor instead. -func (*GetNodesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_payer_api_payer_api_proto_rawDescGZIP(), []int{2} -} - -type GetNodesResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Nodes map[uint32]string `protobuf:"bytes,1,rep,name=nodes,proto3" json:"nodes,omitempty" protobuf_key:"varint,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GetNodesResponse) Reset() { - *x = GetNodesResponse{} - mi := &file_xmtpv4_payer_api_payer_api_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GetNodesResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GetNodesResponse) ProtoMessage() {} - -func (x *GetNodesResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_payer_api_payer_api_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GetNodesResponse.ProtoReflect.Descriptor instead. -func (*GetNodesResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_payer_api_payer_api_proto_rawDescGZIP(), []int{3} -} - -func (x *GetNodesResponse) GetNodes() map[uint32]string { - if x != nil { - return x.Nodes - } - return nil -} - -var File_xmtpv4_payer_api_payer_api_proto protoreflect.FileDescriptor - -const file_xmtpv4_payer_api_payer_api_proto_rawDesc = "" + - "\n" + - " xmtpv4/payer_api/payer_api.proto\x12\x15xmtp.xmtpv4.payer_api\x1a xmtpv4/envelopes/envelopes.proto\"d\n" + - "\x1dPublishClientEnvelopesRequest\x12C\n" + - "\tenvelopes\x18\x01 \x03(\v2%.xmtp.xmtpv4.envelopes.ClientEnvelopeR\tenvelopes\"~\n" + - "\x1ePublishClientEnvelopesResponse\x12\\\n" + - "\x14originator_envelopes\x18\x01 \x03(\v2).xmtp.xmtpv4.envelopes.OriginatorEnvelopeR\x13originatorEnvelopes\"\x11\n" + - "\x0fGetNodesRequest\"\x96\x01\n" + - "\x10GetNodesResponse\x12H\n" + - "\x05nodes\x18\x01 \x03(\v22.xmtp.xmtpv4.payer_api.GetNodesResponse.NodesEntryR\x05nodes\x1a8\n" + - "\n" + - "NodesEntry\x12\x10\n" + - "\x03key\x18\x01 \x01(\rR\x03key\x12\x14\n" + - "\x05value\x18\x02 \x01(\tR\x05value:\x028\x012\xf8\x01\n" + - "\bPayerApi\x12\x87\x01\n" + - "\x16PublishClientEnvelopes\x124.xmtp.xmtpv4.payer_api.PublishClientEnvelopesRequest\x1a5.xmtp.xmtpv4.payer_api.PublishClientEnvelopesResponse\"\x00\x12]\n" + - "\bGetNodes\x12&.xmtp.xmtpv4.payer_api.GetNodesRequest\x1a'.xmtp.xmtpv4.payer_api.GetNodesResponse\"\x00\x1a\x03\x88\x02\x01B\x81\x02\n" + - "3org.xmtp.android.library.push.xmtp.xmtpv4.payer_apiB\rPayerApiProtoP\x01ZIgithub.com/xmtp/example-notification-server-go/pkg/proto/xmtpv4/payer_api\xa2\x02\x03XXP\xaa\x02\x14Xmtp.Xmtpv4.PayerApi\xca\x02\x14Xmtp\\Xmtpv4\\PayerApi\xe2\x02 Xmtp\\Xmtpv4\\PayerApi\\GPBMetadata\xea\x02\x16Xmtp::Xmtpv4::PayerApib\x06proto3" - -var ( - file_xmtpv4_payer_api_payer_api_proto_rawDescOnce sync.Once - file_xmtpv4_payer_api_payer_api_proto_rawDescData []byte -) - -func file_xmtpv4_payer_api_payer_api_proto_rawDescGZIP() []byte { - file_xmtpv4_payer_api_payer_api_proto_rawDescOnce.Do(func() { - file_xmtpv4_payer_api_payer_api_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_xmtpv4_payer_api_payer_api_proto_rawDesc), len(file_xmtpv4_payer_api_payer_api_proto_rawDesc))) - }) - return file_xmtpv4_payer_api_payer_api_proto_rawDescData -} - -var file_xmtpv4_payer_api_payer_api_proto_msgTypes = make([]protoimpl.MessageInfo, 5) -var file_xmtpv4_payer_api_payer_api_proto_goTypes = []any{ - (*PublishClientEnvelopesRequest)(nil), // 0: xmtp.xmtpv4.payer_api.PublishClientEnvelopesRequest - (*PublishClientEnvelopesResponse)(nil), // 1: xmtp.xmtpv4.payer_api.PublishClientEnvelopesResponse - (*GetNodesRequest)(nil), // 2: xmtp.xmtpv4.payer_api.GetNodesRequest - (*GetNodesResponse)(nil), // 3: xmtp.xmtpv4.payer_api.GetNodesResponse - nil, // 4: xmtp.xmtpv4.payer_api.GetNodesResponse.NodesEntry - (*envelopes.ClientEnvelope)(nil), // 5: xmtp.xmtpv4.envelopes.ClientEnvelope - (*envelopes.OriginatorEnvelope)(nil), // 6: xmtp.xmtpv4.envelopes.OriginatorEnvelope -} -var file_xmtpv4_payer_api_payer_api_proto_depIdxs = []int32{ - 5, // 0: xmtp.xmtpv4.payer_api.PublishClientEnvelopesRequest.envelopes:type_name -> xmtp.xmtpv4.envelopes.ClientEnvelope - 6, // 1: xmtp.xmtpv4.payer_api.PublishClientEnvelopesResponse.originator_envelopes:type_name -> xmtp.xmtpv4.envelopes.OriginatorEnvelope - 4, // 2: xmtp.xmtpv4.payer_api.GetNodesResponse.nodes:type_name -> xmtp.xmtpv4.payer_api.GetNodesResponse.NodesEntry - 0, // 3: xmtp.xmtpv4.payer_api.PayerApi.PublishClientEnvelopes:input_type -> xmtp.xmtpv4.payer_api.PublishClientEnvelopesRequest - 2, // 4: xmtp.xmtpv4.payer_api.PayerApi.GetNodes:input_type -> xmtp.xmtpv4.payer_api.GetNodesRequest - 1, // 5: xmtp.xmtpv4.payer_api.PayerApi.PublishClientEnvelopes:output_type -> xmtp.xmtpv4.payer_api.PublishClientEnvelopesResponse - 3, // 6: xmtp.xmtpv4.payer_api.PayerApi.GetNodes:output_type -> xmtp.xmtpv4.payer_api.GetNodesResponse - 5, // [5:7] is the sub-list for method output_type - 3, // [3:5] 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_xmtpv4_payer_api_payer_api_proto_init() } -func file_xmtpv4_payer_api_payer_api_proto_init() { - if File_xmtpv4_payer_api_payer_api_proto != nil { - return - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_xmtpv4_payer_api_payer_api_proto_rawDesc), len(file_xmtpv4_payer_api_payer_api_proto_rawDesc)), - NumEnums: 0, - NumMessages: 5, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_xmtpv4_payer_api_payer_api_proto_goTypes, - DependencyIndexes: file_xmtpv4_payer_api_payer_api_proto_depIdxs, - MessageInfos: file_xmtpv4_payer_api_payer_api_proto_msgTypes, - }.Build() - File_xmtpv4_payer_api_payer_api_proto = out.File - file_xmtpv4_payer_api_payer_api_proto_goTypes = nil - file_xmtpv4_payer_api_payer_api_proto_depIdxs = nil -} diff --git a/pkg/proto/xmtpv4/payer_api/payer_api_grpc.pb.go b/pkg/proto/xmtpv4/payer_api/payer_api_grpc.pb.go deleted file mode 100644 index 15a54b4d..00000000 --- a/pkg/proto/xmtpv4/payer_api/payer_api_grpc.pb.go +++ /dev/null @@ -1,154 +0,0 @@ -// Payer API - -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc (unknown) -// source: xmtpv4/payer_api/payer_api.proto - -package payer_api - -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 ( - PayerApi_PublishClientEnvelopes_FullMethodName = "/xmtp.xmtpv4.payer_api.PayerApi/PublishClientEnvelopes" - PayerApi_GetNodes_FullMethodName = "/xmtp.xmtpv4.payer_api.PayerApi/GetNodes" -) - -// PayerApiClient is the client API for PayerApi 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. -// -// Deprecated: Do not use. -type PayerApiClient interface { - PublishClientEnvelopes(ctx context.Context, in *PublishClientEnvelopesRequest, opts ...grpc.CallOption) (*PublishClientEnvelopesResponse, error) - GetNodes(ctx context.Context, in *GetNodesRequest, opts ...grpc.CallOption) (*GetNodesResponse, error) -} - -type payerApiClient struct { - cc grpc.ClientConnInterface -} - -// Deprecated: Do not use. -func NewPayerApiClient(cc grpc.ClientConnInterface) PayerApiClient { - return &payerApiClient{cc} -} - -func (c *payerApiClient) PublishClientEnvelopes(ctx context.Context, in *PublishClientEnvelopesRequest, opts ...grpc.CallOption) (*PublishClientEnvelopesResponse, error) { - out := new(PublishClientEnvelopesResponse) - err := c.cc.Invoke(ctx, PayerApi_PublishClientEnvelopes_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *payerApiClient) GetNodes(ctx context.Context, in *GetNodesRequest, opts ...grpc.CallOption) (*GetNodesResponse, error) { - out := new(GetNodesResponse) - err := c.cc.Invoke(ctx, PayerApi_GetNodes_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// PayerApiServer is the server API for PayerApi service. -// All implementations must embed UnimplementedPayerApiServer -// for forward compatibility -// -// Deprecated: Do not use. -type PayerApiServer interface { - PublishClientEnvelopes(context.Context, *PublishClientEnvelopesRequest) (*PublishClientEnvelopesResponse, error) - GetNodes(context.Context, *GetNodesRequest) (*GetNodesResponse, error) - mustEmbedUnimplementedPayerApiServer() -} - -// UnimplementedPayerApiServer must be embedded to have forward compatible implementations. -type UnimplementedPayerApiServer struct { -} - -func (UnimplementedPayerApiServer) PublishClientEnvelopes(context.Context, *PublishClientEnvelopesRequest) (*PublishClientEnvelopesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method PublishClientEnvelopes not implemented") -} -func (UnimplementedPayerApiServer) GetNodes(context.Context, *GetNodesRequest) (*GetNodesResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetNodes not implemented") -} -func (UnimplementedPayerApiServer) mustEmbedUnimplementedPayerApiServer() {} - -// UnsafePayerApiServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to PayerApiServer will -// result in compilation errors. -type UnsafePayerApiServer interface { - mustEmbedUnimplementedPayerApiServer() -} - -// Deprecated: Do not use. -func RegisterPayerApiServer(s grpc.ServiceRegistrar, srv PayerApiServer) { - s.RegisterService(&PayerApi_ServiceDesc, srv) -} - -func _PayerApi_PublishClientEnvelopes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(PublishClientEnvelopesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(PayerApiServer).PublishClientEnvelopes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: PayerApi_PublishClientEnvelopes_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(PayerApiServer).PublishClientEnvelopes(ctx, req.(*PublishClientEnvelopesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _PayerApi_GetNodes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(GetNodesRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(PayerApiServer).GetNodes(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: PayerApi_GetNodes_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(PayerApiServer).GetNodes(ctx, req.(*GetNodesRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// PayerApi_ServiceDesc is the grpc.ServiceDesc for PayerApi service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var PayerApi_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "xmtp.xmtpv4.payer_api.PayerApi", - HandlerType: (*PayerApiServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "PublishClientEnvelopes", - Handler: _PayerApi_PublishClientEnvelopes_Handler, - }, - { - MethodName: "GetNodes", - Handler: _PayerApi_GetNodes_Handler, - }, - }, - Streams: []grpc.StreamDesc{}, - Metadata: "xmtpv4/payer_api/payer_api.proto", -} diff --git a/pkg/xmtp/client.go b/pkg/xmtp/client.go index 7f40d35b..2cec30fc 100644 --- a/pkg/xmtp/client.go +++ b/pkg/xmtp/client.go @@ -5,7 +5,7 @@ import ( "crypto/tls" "time" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + v1 "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" "google.golang.org/grpc" "google.golang.org/grpc/credentials" "google.golang.org/grpc/credentials/insecure" diff --git a/pkg/xmtp/client_test.go b/pkg/xmtp/client_test.go new file mode 100644 index 00000000..bb2a3a54 --- /dev/null +++ b/pkg/xmtp/client_test.go @@ -0,0 +1,22 @@ +package xmtp + +import ( + "testing" + + "github.com/stretchr/testify/require" + "github.com/xmtp/xmtpd/pkg/envelopes" + messageApi "github.com/xmtp/xmtpd/pkg/proto/xmtpv4/message_api" +) + +func TestXmtpdNotificationApiImportable(t *testing.T) { + // This test verifies the xmtpd notification API proto types are available. + // It will fail until xmtpd is pinned to the notification API branch. + var _ messageApi.NotificationApiClient +} + +func TestXmtpdEnvelopeTypesImportable(t *testing.T) { + // Verify that importing xmtpd/pkg/envelopes does NOT cause + // protobuf namespace conflicts after local proto dirs are deleted. + _, err := envelopes.NewOriginatorEnvelopeFromBytes([]byte{}) + require.Error(t, err) // Expected: parse error on empty bytes, not a panic +} diff --git a/pkg/xmtp/listener.go b/pkg/xmtp/listener.go index 150672b0..f96af105 100644 --- a/pkg/xmtp/listener.go +++ b/pkg/xmtp/listener.go @@ -10,7 +10,7 @@ import ( "github.com/xmtp/example-notification-server-go/pkg/interfaces" "github.com/xmtp/example-notification-server-go/pkg/options" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + v1 "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" "github.com/xmtp/example-notification-server-go/pkg/topics" topicpkg "github.com/xmtp/xmtpd/pkg/topic" "go.uber.org/zap" diff --git a/pkg/xmtp/listener_test.go b/pkg/xmtp/listener_test.go index 8abf27ad..7bacbdf5 100644 --- a/pkg/xmtp/listener_test.go +++ b/pkg/xmtp/listener_test.go @@ -12,7 +12,7 @@ import ( "github.com/xmtp/example-notification-server-go/pkg/installations" "github.com/xmtp/example-notification-server-go/pkg/interfaces" "github.com/xmtp/example-notification-server-go/pkg/options" - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + v1 "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" "github.com/xmtp/example-notification-server-go/pkg/subscriptions" "github.com/xmtp/example-notification-server-go/pkg/testutils" topicutil "github.com/xmtp/example-notification-server-go/pkg/topics" diff --git a/pkg/xmtp/message.go b/pkg/xmtp/message.go index d71b863e..5d659090 100644 --- a/pkg/xmtp/message.go +++ b/pkg/xmtp/message.go @@ -4,8 +4,8 @@ import ( "errors" "github.com/xmtp/example-notification-server-go/pkg/interfaces" - messageApi "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" - mlsV1 "github.com/xmtp/example-notification-server-go/pkg/proto/mls/api/v1" + messageApi "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" + mlsV1 "github.com/xmtp/xmtpd/pkg/proto/mls/api/v1" "github.com/xmtp/example-notification-server-go/pkg/topics" topicpkg "github.com/xmtp/xmtpd/pkg/topic" "google.golang.org/protobuf/proto" diff --git a/pkg/xmtp/message_test.go b/pkg/xmtp/message_test.go index 6e3af0e9..8ebaf1bc 100644 --- a/pkg/xmtp/message_test.go +++ b/pkg/xmtp/message_test.go @@ -7,7 +7,7 @@ import ( "testing" "github.com/stretchr/testify/require" - messageApi "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + messageApi "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" "github.com/xmtp/example-notification-server-go/pkg/topics" "google.golang.org/protobuf/proto" ) diff --git a/pkg/xmtp/utils.go b/pkg/xmtp/utils.go index bcc29ec4..b3b000d5 100644 --- a/pkg/xmtp/utils.go +++ b/pkg/xmtp/utils.go @@ -1,7 +1,7 @@ package xmtp import ( - v1 "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + v1 "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" ) func getThirtyDayPeriodsFromEpoch(env *v1.Envelope) int { diff --git a/pkg/xmtp/utils_test.go b/pkg/xmtp/utils_test.go index 4b7627c9..c945f506 100644 --- a/pkg/xmtp/utils_test.go +++ b/pkg/xmtp/utils_test.go @@ -5,7 +5,7 @@ import ( "time" "github.com/stretchr/testify/require" - message_apiv1 "github.com/xmtp/example-notification-server-go/pkg/proto/message_api/v1" + message_apiv1 "github.com/xmtp/xmtpd/pkg/proto/message_api/v1" ) func Test_get_thirty_day_periods(t *testing.T) {