@aldiokta/protocgen 1.1.65 → 1.1.66

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,82 @@
1
+ // GENERATED CODE -- DO NOT EDIT!
2
+
3
+ 'use strict';
4
+ var grpc = require('@grpc/grpc-js');
5
+ var prisca_v1_core_subscription_subscription_pb = require('../../../../prisca/v1/core/subscription/subscription_pb.js');
6
+ var prisca_v1_global_meta_meta_pb = require('../../../../prisca/v1/global/meta/meta_pb.js');
7
+
8
+ function serialize_GetEntitlementRequest(arg) {
9
+ if (!(arg instanceof prisca_v1_core_subscription_subscription_pb.GetEntitlementRequest)) {
10
+ throw new Error('Expected argument of type GetEntitlementRequest');
11
+ }
12
+ return Buffer.from(arg.serializeBinary());
13
+ }
14
+
15
+ function deserialize_GetEntitlementRequest(buffer_arg) {
16
+ return prisca_v1_core_subscription_subscription_pb.GetEntitlementRequest.deserializeBinary(new Uint8Array(buffer_arg));
17
+ }
18
+
19
+ function serialize_GetEntitlementResponse(arg) {
20
+ if (!(arg instanceof prisca_v1_core_subscription_subscription_pb.GetEntitlementResponse)) {
21
+ throw new Error('Expected argument of type GetEntitlementResponse');
22
+ }
23
+ return Buffer.from(arg.serializeBinary());
24
+ }
25
+
26
+ function deserialize_GetEntitlementResponse(buffer_arg) {
27
+ return prisca_v1_core_subscription_subscription_pb.GetEntitlementResponse.deserializeBinary(new Uint8Array(buffer_arg));
28
+ }
29
+
30
+ function serialize_ProcessSubscriptionEventRequest(arg) {
31
+ if (!(arg instanceof prisca_v1_core_subscription_subscription_pb.ProcessSubscriptionEventRequest)) {
32
+ throw new Error('Expected argument of type ProcessSubscriptionEventRequest');
33
+ }
34
+ return Buffer.from(arg.serializeBinary());
35
+ }
36
+
37
+ function deserialize_ProcessSubscriptionEventRequest(buffer_arg) {
38
+ return prisca_v1_core_subscription_subscription_pb.ProcessSubscriptionEventRequest.deserializeBinary(new Uint8Array(buffer_arg));
39
+ }
40
+
41
+ function serialize_ProcessSubscriptionEventResponse(arg) {
42
+ if (!(arg instanceof prisca_v1_core_subscription_subscription_pb.ProcessSubscriptionEventResponse)) {
43
+ throw new Error('Expected argument of type ProcessSubscriptionEventResponse');
44
+ }
45
+ return Buffer.from(arg.serializeBinary());
46
+ }
47
+
48
+ function deserialize_ProcessSubscriptionEventResponse(buffer_arg) {
49
+ return prisca_v1_core_subscription_subscription_pb.ProcessSubscriptionEventResponse.deserializeBinary(new Uint8Array(buffer_arg));
50
+ }
51
+
52
+
53
+ // SubscriptionService is Prisca's side of the Subscription System control-plane
54
+ // integration (PRISCA-95). The HMAC verification itself happens at the REST
55
+ // gateway (prisca-v2-backend) — by the time a call reaches here the request is
56
+ // already authenticated, so this service never sees the shared secret.
57
+ var SubscriptionServiceService = exports.SubscriptionServiceService = {
58
+ processSubscriptionEvent: {
59
+ path: '/SubscriptionService/ProcessSubscriptionEvent',
60
+ requestStream: false,
61
+ responseStream: false,
62
+ requestType: prisca_v1_core_subscription_subscription_pb.ProcessSubscriptionEventRequest,
63
+ responseType: prisca_v1_core_subscription_subscription_pb.ProcessSubscriptionEventResponse,
64
+ requestSerialize: serialize_ProcessSubscriptionEventRequest,
65
+ requestDeserialize: deserialize_ProcessSubscriptionEventRequest,
66
+ responseSerialize: serialize_ProcessSubscriptionEventResponse,
67
+ responseDeserialize: deserialize_ProcessSubscriptionEventResponse,
68
+ },
69
+ getEntitlement: {
70
+ path: '/SubscriptionService/GetEntitlement',
71
+ requestStream: false,
72
+ responseStream: false,
73
+ requestType: prisca_v1_core_subscription_subscription_pb.GetEntitlementRequest,
74
+ responseType: prisca_v1_core_subscription_subscription_pb.GetEntitlementResponse,
75
+ requestSerialize: serialize_GetEntitlementRequest,
76
+ requestDeserialize: deserialize_GetEntitlementRequest,
77
+ responseSerialize: serialize_GetEntitlementResponse,
78
+ responseDeserialize: deserialize_GetEntitlementResponse,
79
+ },
80
+ };
81
+
82
+ exports.SubscriptionServiceClient = grpc.makeGenericClientConstructor(SubscriptionServiceService, 'SubscriptionService');