@sellout/models 0.0.424 → 0.0.426

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.
Files changed (44) hide show
  1. package/.dist/graphql/fragments/event.fragment.js +1 -0
  2. package/.dist/graphql/fragments/event.fragment.js.map +1 -1
  3. package/.dist/graphql/fragments/season.fragment.js +2 -0
  4. package/.dist/graphql/fragments/season.fragment.js.map +1 -1
  5. package/.dist/graphql/mutations/connectHive.mutation.d.ts +2 -0
  6. package/.dist/graphql/mutations/connectHive.mutation.js +16 -0
  7. package/.dist/graphql/mutations/connectHive.mutation.js.map +1 -0
  8. package/.dist/graphql/mutations/updateOrganization.mutation.js +3 -0
  9. package/.dist/graphql/mutations/updateOrganization.mutation.js.map +1 -1
  10. package/.dist/graphql/queries/profile.query.js +4 -0
  11. package/.dist/graphql/queries/profile.query.js.map +1 -1
  12. package/.dist/interfaces/IEvent.d.ts +1 -0
  13. package/.dist/interfaces/IHiveIntegration.d.ts +8 -0
  14. package/.dist/interfaces/IHiveIntegration.js +3 -0
  15. package/.dist/interfaces/IHiveIntegration.js.map +1 -0
  16. package/.dist/interfaces/IOrganization.d.ts +2 -0
  17. package/.dist/interfaces/IOrganization.js.map +1 -1
  18. package/.dist/interfaces/IPerformance.d.ts +1 -0
  19. package/.dist/schemas/Event.d.ts +8 -0
  20. package/.dist/schemas/Event.js +8 -0
  21. package/.dist/schemas/Event.js.map +1 -1
  22. package/.dist/schemas/Organization.d.ts +32 -0
  23. package/.dist/schemas/Organization.js +34 -1
  24. package/.dist/schemas/Organization.js.map +1 -1
  25. package/.dist/schemas/Season.d.ts +4 -0
  26. package/.dist/schemas/Season.js +4 -0
  27. package/.dist/schemas/Season.js.map +1 -1
  28. package/.dist/sellout-proto.js +1881 -286
  29. package/package.json +3 -3
  30. package/src/graphql/fragments/event.fragment.ts +1 -0
  31. package/src/graphql/fragments/season.fragment.ts +2 -0
  32. package/src/graphql/mutations/connectHive.mutation.ts +15 -0
  33. package/src/graphql/mutations/updateOrganization.mutation.ts +4 -1
  34. package/src/graphql/queries/profile.query.ts +5 -1
  35. package/src/interfaces/IEvent.ts +1 -0
  36. package/src/interfaces/IHiveIntegration.ts +8 -0
  37. package/src/interfaces/IOrganization.ts +3 -1
  38. package/src/interfaces/IPerformance.ts +1 -0
  39. package/src/proto/event.proto +2 -0
  40. package/src/proto/order.proto +1 -0
  41. package/src/proto/organization.proto +41 -0
  42. package/src/schemas/Event.ts +8 -0
  43. package/src/schemas/Organization.ts +35 -1
  44. package/src/schemas/Season.ts +4 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sellout/models",
3
- "version": "0.0.424",
3
+ "version": "0.0.426",
4
4
  "description": "Sellout.io models",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -18,7 +18,7 @@
18
18
  "dependencies": {
19
19
  "@apollo/client": "^3.9.6",
20
20
  "@hapi/joi": "^17.1.1",
21
- "@sellout/utils": "^0.0.424",
21
+ "@sellout/utils": "^0.0.426",
22
22
  "@types/hapi__joi": "^16.0.1",
23
23
  "@types/shortid": "^0.0.29",
24
24
  "@types/zen-observable": "^0.8.7",
@@ -33,5 +33,5 @@
33
33
  "protobufjs": "^6.11.2",
34
34
  "typescript": "^4.9.5"
35
35
  },
36
- "gitHead": "ab705bb5a92ec53ad74fdf6c2945880990129aa7"
36
+ "gitHead": "b18d4f5bd2294d8ddec96fa059978b8af8c89fc8"
37
37
  }
@@ -80,6 +80,7 @@ Event.fragments = {
80
80
  price
81
81
  posterImageUrl
82
82
  videoLink
83
+ vimeoLink
83
84
  songLink
84
85
  schedule {
85
86
  doorsAt
@@ -81,6 +81,7 @@ Season.fragments = {
81
81
  price
82
82
  posterImageUrl
83
83
  videoLink
84
+ vimeoLink
84
85
  songLink
85
86
  schedule {
86
87
  doorsAt
@@ -333,6 +334,7 @@ Season.fragments = {
333
334
  price
334
335
  posterImageUrl
335
336
  videoLink
337
+ vimeoLink
336
338
  songLink
337
339
  schedule {
338
340
  doorsAt
@@ -0,0 +1,15 @@
1
+ import { gql } from "@apollo/client";
2
+
3
+ const mutation = gql`
4
+ mutation ConnectHive($code: String!, $codeVerifier: String!, $clientId: String!, $clientSecret: String!) {
5
+ connectHive(code: $code, codeVerifier: $codeVerifier, clientId: $clientId, clientSecret: $clientSecret) {
6
+ _id
7
+ hiveIntegration {
8
+ isHiveIntegration
9
+ isConnected
10
+ }
11
+ }
12
+ }
13
+ `;
14
+
15
+ export default mutation;
@@ -1,4 +1,4 @@
1
- import {gql} from "@apollo/client";
1
+ import { gql } from "@apollo/client";
2
2
 
3
3
  const mutation = gql`
4
4
  mutation updateOrganization($organization: OrganizationInput!) {
@@ -13,6 +13,9 @@ const mutation = gql`
13
13
  ticketFormat
14
14
  ticketShareExpiration
15
15
  isWeb3Integration
16
+ hiveIntegration {
17
+ isHiveIntegration
18
+ }
16
19
  }
17
20
  }
18
21
  `;
@@ -1,4 +1,4 @@
1
- import {gql} from "@apollo/client";
1
+ import { gql } from "@apollo/client";
2
2
 
3
3
  const query = gql`
4
4
  query Profile {
@@ -51,6 +51,10 @@ const query = gql`
51
51
  isSeasonTickets
52
52
  isTegIntegration
53
53
  isWeb3Integration
54
+ hiveIntegration {
55
+ isHiveIntegration
56
+ isConnected
57
+ }
54
58
  validateMemberId
55
59
  stripeConnectAccount {
56
60
  name
@@ -85,6 +85,7 @@ export default interface IEvent {
85
85
  subtitle?: string;
86
86
  description?: string;
87
87
  posterImageUrl?: IEventPosterUrl;
88
+ additionalPhotos?: string[];
88
89
  venueId?: string;
89
90
  createdAt: number;
90
91
  publishable?: boolean;
@@ -0,0 +1,8 @@
1
+ export default interface IHiveIntegration {
2
+ isHiveIntegration?: boolean;
3
+ clientId?: string;
4
+ clientSecret?: string;
5
+ accessToken?: string;
6
+ refreshToken?: string;
7
+ tokenExpiresAt?: number;
8
+ }
@@ -1,5 +1,6 @@
1
1
  import IAddress from "./IAddress";
2
- import IOrderIntegration from "./IOrderIntegration"
2
+ import IOrderIntegration from "./IOrderIntegration";
3
+ import IHiveIntegration from "./IHiveIntegration";
3
4
 
4
5
  export enum TicketFormatAsEnum {
5
6
  Standard = "Standard",
@@ -40,4 +41,5 @@ export default interface IOrganization {
40
41
  isOrgDeletable?: boolean;
41
42
  isWeb3Integration?: boolean;
42
43
  ticketShareExpiration?: string;
44
+ hiveIntegration?: IHiveIntegration;
43
45
  }
@@ -15,6 +15,7 @@ export default interface IPerformance {
15
15
  price?: number;
16
16
  posterImageUrl?: string;
17
17
  videoLink?: string;
18
+ vimeoLink?: string;
18
19
  songLink?: string;
19
20
  schedule?: [IPerformanceSchedule];
20
21
  }
@@ -53,6 +53,7 @@ message Event {
53
53
  string web3Hash = 45;
54
54
  string googleWalletClassId = 46;
55
55
  bool isEventTegIntegration = 47;
56
+ repeated string additionalPhotos = 48;
56
57
  }
57
58
 
58
59
  message PublicEvent {
@@ -200,6 +201,7 @@ message Performance {
200
201
  string videoLink = 8;
201
202
  string songLink = 9;
202
203
  repeated PerformanceSchedule schedule = 10;
204
+ string vimeoLink = 11;
203
205
  }
204
206
 
205
207
  message SubscriptionSalesReport {
@@ -369,6 +369,7 @@ message RefundOrderRequest {
369
369
  bool processingFee = 8;
370
370
  string eventType = 9;
371
371
  bool promoterFee = 10;
372
+ bool skipHivePush = 11;
372
373
 
373
374
  }
374
375
 
@@ -31,6 +31,7 @@ message Organization {
31
31
  bool isOrgDeletable = 24;
32
32
  bool isWeb3Integration = 25;
33
33
  string ticketShareExpiration = 26;
34
+ HiveIntegration hiveIntegration = 27;
34
35
  }
35
36
 
36
37
  message OrderIntegration {
@@ -39,6 +40,15 @@ message OrderIntegration {
39
40
  string orderIntegrationAuthToken = 2;
40
41
  }
41
42
 
43
+ message HiveIntegration {
44
+ bool isHiveIntegration = 1;
45
+ string accessToken = 2;
46
+ string refreshToken = 3;
47
+ int32 tokenExpiresAt = 4;
48
+ string clientId = 5;
49
+ string clientSecret = 6;
50
+ }
51
+
42
52
  // Create Organization
43
53
  message CreateOrganizationRequest {
44
54
  string spanContext = 0;
@@ -146,6 +156,33 @@ message RemoveOrganizationStripeIdResponse {
146
156
  Organization organization = 2;
147
157
  }
148
158
 
159
+ // Connect Hive
160
+ message ConnectHiveRequest {
161
+ string spanContext = 1;
162
+ string orgId = 2;
163
+ string code = 3;
164
+ string codeVerifier = 4;
165
+ string clientId = 5;
166
+ string clientSecret = 6;
167
+ }
168
+
169
+ message ConnectHiveResponse {
170
+ StatusCode status = 1;
171
+ repeated Error errors = 2;
172
+ Organization organization = 3;
173
+ }
174
+
175
+ message RefreshHiveTokenRequest {
176
+ string spanContext = 1;
177
+ string orgId = 2;
178
+ }
179
+
180
+ message RefreshHiveTokenResponse {
181
+ StatusCode status = 1;
182
+ repeated Error errors = 2;
183
+ Organization organization = 3;
184
+ }
185
+
149
186
  service OrganizationService {
150
187
  // Create
151
188
  rpc createOrganization(CreateOrganizationRequest) returns (CreateOrganizationResponse) {}
@@ -162,4 +199,8 @@ service OrganizationService {
162
199
  rpc deleteOrganization(DeleteOrganizationRequest) returns (DeleteOrganizationResponse) {}
163
200
  // Remove Stripe ID
164
201
  rpc removeOrganizationStripeId(RemoveOrganizationStripeIdRequest) returns (RemoveOrganizationStripeIdResponse) {}
202
+ // Connect Hive
203
+ rpc connectHive(ConnectHiveRequest) returns (ConnectHiveResponse) {}
204
+ // Refresh Hive
205
+ rpc refreshHiveToken(RefreshHiveTokenRequest) returns (RefreshHiveTokenResponse) {}
165
206
  }
@@ -306,6 +306,10 @@ const Performance = {
306
306
  videoLink: {
307
307
  type: String,
308
308
  required: false,
309
+ },
310
+ vimeoLink: {
311
+ type: String,
312
+ required: false,
309
313
  },
310
314
  songLink: {
311
315
  type: String,
@@ -548,6 +552,10 @@ export default {
548
552
  required: false
549
553
  },
550
554
  posterImageUrl: PosterImageUrl,
555
+ additionalPhotos: {
556
+ type: [String],
557
+ required: false
558
+ },
551
559
  venueId: {
552
560
  type: String,
553
561
  required: false
@@ -16,6 +16,39 @@ const OrderIntegration = {
16
16
  required: false
17
17
  }
18
18
  };
19
+
20
+ const HiveIntegration = {
21
+ isHiveIntegration: {
22
+ type: Boolean,
23
+ required: false,
24
+ default: false,
25
+ },
26
+ clientId: {
27
+ type: String,
28
+ required: false,
29
+ default: null,
30
+ },
31
+ clientSecret: {
32
+ type: String,
33
+ required: false,
34
+ default: null,
35
+ },
36
+ accessToken: {
37
+ type: String,
38
+ required: false,
39
+ default: null,
40
+ },
41
+ refreshToken: {
42
+ type: String,
43
+ required: false,
44
+ default: null,
45
+ },
46
+ tokenExpiresAt: {
47
+ type: Number,
48
+ required: false,
49
+ default: null,
50
+ },
51
+ };
19
52
  export default {
20
53
  _id: {
21
54
  type: String,
@@ -126,5 +159,6 @@ export default {
126
159
  type:String,
127
160
  required:false,
128
161
  default:TicketShareExpirationEnum.Never
129
- }
162
+ },
163
+ hiveIntegration: HiveIntegration,
130
164
  };
@@ -275,6 +275,10 @@ const Performance = {
275
275
  type: String,
276
276
  required: false,
277
277
  },
278
+ vimeoLink: {
279
+ type: String,
280
+ required: false,
281
+ },
278
282
  songLink: {
279
283
  type: String,
280
284
  required: false,