@chevre/factory 5.1.0-alpha.3 → 5.1.0-alpha.4

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.
@@ -4,6 +4,7 @@ import { ActionType } from '../actionType';
4
4
  import * as AssetTransactionFactory from '../assetTransaction';
5
5
  import { AssetTransactionType } from '../assetTransactionType';
6
6
  import { IExtendId } from '../autoGenerated';
7
+ import { IEligibleQuantity } from '../offer';
7
8
  import { IOrder } from '../order';
8
9
  import { PermitType } from '../permit';
9
10
  import { ProductType } from '../product';
@@ -275,6 +276,39 @@ export interface ITokenizedMemberProgramTier {
275
276
  identifier: string;
276
277
  };
277
278
  }
279
+ /**
280
+ * オファートークンの中身
281
+ * 予約対象イベント識別子、オファー有効期間、販売アプリケーションコード、対象数量を定義する
282
+ */
283
+ export interface IOfferTokenPayload {
284
+ /**
285
+ * YYYY-MM-DDTHH:mm:ssZ
286
+ */
287
+ validFrom: string;
288
+ /**
289
+ * YYYY-MM-DDTHH:mm:ssZ
290
+ */
291
+ validThrough: string;
292
+ availableAtOrFrom: {
293
+ /**
294
+ * 販売アプリケーションコード
295
+ * イベント管理で設定されたアプリケーションコード
296
+ */
297
+ identifier: string;
298
+ };
299
+ /**
300
+ * 対象数量
301
+ * 最大n席まで
302
+ */
303
+ eligibleQuantity: Pick<IEligibleQuantity, 'maxValue'>;
304
+ itemOffered: {
305
+ /**
306
+ * イベント識別子
307
+ */
308
+ identifier: string;
309
+ };
310
+ }
311
+ export type IOfferToken = string;
278
312
  export interface IObjectWithoutDetail {
279
313
  acceptedOffer?: IAcceptedTicketOfferWithoutDetail[];
280
314
  broker?: ReservationFactory.IBroker;
@@ -286,6 +320,11 @@ export interface IObjectWithoutDetail {
286
320
  * メンバープログラムティアごとにオファー有効期間が管理されている場合、検証されたトークンに基づいて有効期間が検証されます
287
321
  */
288
322
  validForMemberTier?: ITokenizedMemberProgramTier;
323
+ /**
324
+ * support オファートークン
325
+ * 2025-10-21~
326
+ */
327
+ token?: IOfferToken;
289
328
  };
290
329
  };
291
330
  }
@@ -20,7 +20,7 @@ export interface IDistributor {
20
20
  * コンテンツ
21
21
  * {@link https://schema.org/Movie}
22
22
  */
23
- export interface ICreativeWork extends Pick<CreativeWorkFactory.ICreativeWork, 'additionalProperty' | 'alternativeHeadline' | 'contentRating' | 'copyrightHolder' | 'datePublished' | 'headline' | 'thumbnailUrl' | 'typeOf' | 'name' | 'identifier' | 'id'> {
23
+ export interface ICreativeWork extends Pick<CreativeWorkFactory.ICreativeWork, 'additionalProperty' | 'alternativeHeadline' | 'contentRating' | 'datePublished' | 'headline' | 'thumbnailUrl' | 'typeOf' | 'name' | 'identifier' | 'id'> {
24
24
  project: Pick<IProject, 'id' | 'typeOf'>;
25
25
  identifier: string;
26
26
  /**
@@ -2,9 +2,6 @@ import type * as COA from '@motionpicture/coa-service';
2
2
  import { CreativeWorkType } from './creativeWorkType';
3
3
  import { IPropertyValue } from './propertyValue';
4
4
  import { IThing } from './thing';
5
- export interface ICopyrightHolder {
6
- name: string;
7
- }
8
5
  export type IContentRating = COA.factory.master.IKubunNameResult | string;
9
6
  /**
10
7
  * 作品
@@ -15,7 +12,6 @@ export interface ICreativeWork extends Pick<IThing, 'name' | 'identifier'> {
15
12
  id?: string;
16
13
  alternativeHeadline?: string;
17
14
  contentRating?: IContentRating;
18
- copyrightHolder?: ICopyrightHolder;
19
15
  copyrightYear?: number;
20
16
  datePublished?: Date;
21
17
  headline?: string;
@@ -1,7 +1,14 @@
1
1
  import { issuer } from '../issuer';
2
2
  import { IAvailableAtOrFrom, IOffer } from '../offer';
3
3
  import { OfferType } from '../offerType';
4
- type IOfferAvailableAtOrFrom = Pick<IAvailableAtOrFrom, 'id'>;
4
+ type IOfferAvailableAtOrFrom = Pick<IAvailableAtOrFrom, 'id'> & {
5
+ /**
6
+ * アプリケーションコード
7
+ * イベントの販売アプリケーション間でユニーク必須
8
+ * オファートークン利用時に必須(トークンのpayloadで必要)
9
+ */
10
+ identifier?: string;
11
+ };
5
12
  type IMemberProgramTier = Pick<issuer.IMemberProgramTier, 'typeOf'>;
6
13
  /**
7
14
  * イベントに対する単一オファー
@@ -27,6 +34,17 @@ interface ISingleEventOffer extends Pick<IOffer, 'typeOf' | 'availabilityEnds' |
27
34
  validThrough: Date;
28
35
  availableAtOrFrom?: IOfferAvailableAtOrFrom | IOfferAvailableAtOrFrom[];
29
36
  validForMemberTier?: never;
37
+ /**
38
+ * support issuedBy
39
+ * オファー発行者が定義された場合、オファー承認時にオファー発行者によって署名されたオファートークンが必須
40
+ * その場合、有効期間、適用数量、対応アプリケーションはオファートークンのpayloadに従う
41
+ */
42
+ issuedBy?: {
43
+ /**
44
+ * オファートークン発行者コード
45
+ */
46
+ identifier?: string;
47
+ };
30
48
  }
31
49
  /**
32
50
  * メンバープログラムティア適用のイベントオファー
@@ -39,6 +57,7 @@ interface IEventOfferForMemberTier extends Pick<ISingleEventOffer, 'typeOf' | 'a
39
57
  * また、オファーの有効期間がメンバープログラムティアごとのイベントオファーに依存する
40
58
  */
41
59
  validForMemberTier: IMemberProgramTier;
60
+ issuedBy?: never;
42
61
  }
43
62
  /**
44
63
  * アプリケーションごとのイベントに対するオファー
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chevre/factory",
3
- "version": "5.1.0-alpha.3",
3
+ "version": "5.1.0-alpha.4",
4
4
  "description": "Chevre Factory Library for Javascript",
5
5
  "main": "./lib/index.js",
6
6
  "types": "./lib/index.d.ts",