@chevre/factory 4.267.0 → 4.268.0-alpha.0

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.
@@ -1,3 +1,4 @@
1
+ import { AccountType } from '../../accountType';
1
2
  import * as ActionFactory from '../../action';
2
3
  import { ActionStatusType } from '../../actionStatusType';
3
4
  import { ActionType } from '../../actionType';
@@ -8,7 +9,7 @@ import { AccountTransactionType } from '../transactionType';
8
9
  export declare type IAgent = ActionFactory.IParticipant;
9
10
  export declare type IRecipient = ActionFactory.IParticipant;
10
11
  /**
11
- * 口座以外の匿名場所インターフェース
12
+ * 口座以外の匿名ロケーション
12
13
  */
13
14
  export interface IAnonymousLocation extends Pick<IThing, 'identifier' | 'name'> {
14
15
  /**
@@ -21,10 +22,10 @@ export interface IAnonymousLocation extends Pick<IThing, 'identifier' | 'name'>
21
22
  id?: string;
22
23
  }
23
24
  /**
24
- * 口座インターフェース
25
+ * 口座
25
26
  */
26
27
  export interface IAccount {
27
- typeOf: string;
28
+ typeOf: AccountType.Account;
28
29
  /**
29
30
  * 通貨
30
31
  */
@@ -39,14 +40,14 @@ export interface IAccount {
39
40
  name?: string;
40
41
  }
41
42
  /**
42
- * 転送元あるいは転送先の場所インターフェース
43
+ * 転送元あるいは転送先の場所
43
44
  */
44
45
  export declare type ILocation = IAnonymousLocation | IAccount;
45
46
  export declare type IObject = any;
46
47
  export declare type IResult = any;
47
48
  export declare type IPotentialActions = any;
48
49
  /**
49
- * アクションの目的インターフェース
50
+ * アクションの目的
50
51
  * ここでは、取引が目的となる
51
52
  */
52
53
  export interface IPurpose {
@@ -67,6 +68,7 @@ export interface IPurpose {
67
68
  */
68
69
  identifier?: string;
69
70
  }
71
+ export declare type IAmount = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'value'>;
70
72
  export interface IAttributes extends ActionFactory.IAttributes<ActionType.MoneyTransfer, IObject, IResult> {
71
73
  typeOf: ActionType.MoneyTransfer;
72
74
  /**
@@ -76,7 +78,7 @@ export interface IAttributes extends ActionFactory.IAttributes<ActionType.MoneyT
76
78
  /**
77
79
  * 金額
78
80
  */
79
- amount: IMonetaryAmount;
81
+ amount: IAmount;
80
82
  /**
81
83
  * 転送元
82
84
  */
@@ -88,7 +90,7 @@ export interface IAttributes extends ActionFactory.IAttributes<ActionType.MoneyT
88
90
  }
89
91
  export declare type IAction = ActionFactory.IAction<IAttributes>;
90
92
  /**
91
- * ソート条件インターフェース
93
+ * ソート条件
92
94
  */
93
95
  export interface ISortOrder {
94
96
  /**
@@ -103,7 +105,7 @@ export interface IProjectSearchConditions {
103
105
  };
104
106
  }
105
107
  /**
106
- * 検索条件インターフェース
108
+ * 検索条件
107
109
  */
108
110
  export interface ISearchConditions {
109
111
  limit?: number;
@@ -1,40 +1,20 @@
1
1
  import { IExtendId } from '../../autoGenerated';
2
- import { IClientUser } from '../../clientUser';
3
- import { IAccount, IAnonymousLocation, IAttributes as IMoneyTransferActionAttributes } from '../action/moneyTransfer';
2
+ import { IAccount, IAnonymousLocation } from '../action/moneyTransfer';
4
3
  import * as TransactionFactory from '../transaction';
5
4
  import { AccountTransactionType } from '../transactionType';
6
- export declare type IRecipient = TransactionFactory.IRecipient;
7
- export declare type IAgent = TransactionFactory.IAgent;
8
- export declare type IStartParamsWithoutDetail = TransactionFactory.IStartParams<AccountTransactionType.Deposit, IAgent, IRecipient, IObjectWithoutDetail>;
5
+ export declare type IStartParamsWithoutDetail = TransactionFactory.IStartParams<AccountTransactionType.Deposit, IObjectWithoutDetail>;
9
6
  /**
10
- * 取引開始パラメーターインターフェース
7
+ * 取引開始パラメーター
11
8
  */
12
- export declare type IStartParams = TransactionFactory.IStartParams<AccountTransactionType.Deposit, IAgent, IRecipient, IObject>;
13
- export declare type IResult = any;
14
- /**
15
- * エラーインターフェース
16
- */
17
- export declare type IError = any;
18
- export interface IObjectWithoutDetail {
19
- clientUser?: IClientUser;
20
- amount: {
21
- value: number;
22
- };
9
+ export declare type IStartParams = TransactionFactory.IStartParams<AccountTransactionType.Deposit, IObject>;
10
+ export interface IObjectWithoutDetail extends TransactionFactory.IObjectWithoutDetail {
23
11
  fromLocation?: IAnonymousLocation;
24
12
  toLocation: TransactionFactory.ISimpleAccount;
25
- description?: string;
26
13
  }
27
14
  /**
28
- * 取引対象物インターフェース
15
+ * 取引対象物
29
16
  */
30
- export interface IObject {
31
- clientUser?: IClientUser;
32
- /**
33
- * 金額
34
- */
35
- amount: {
36
- value: number;
37
- };
17
+ export interface IObject extends TransactionFactory.IObject {
38
18
  /**
39
19
  * 入金元
40
20
  */
@@ -43,14 +23,10 @@ export interface IObject {
43
23
  * 入金先
44
24
  */
45
25
  toLocation: IAccount;
46
- description?: string;
47
26
  }
48
- export interface IPotentialActions {
49
- moneyTransfer: IMoneyTransferActionAttributes;
50
- }
51
- export declare type ITransaction = IExtendId<IAttributes>;
52
27
  /**
53
- * 入金取引属性インターフェース
28
+ * 入金取引属性
54
29
  */
55
- export interface IAttributes extends TransactionFactory.IAttributes<IStartParams, IResult, IError, IPotentialActions> {
30
+ export interface IAttributes extends TransactionFactory.IAttributes<IStartParams> {
56
31
  }
32
+ export declare type ITransaction = IExtendId<IAttributes>;
@@ -1,40 +1,20 @@
1
1
  import { IExtendId } from '../../autoGenerated';
2
- import { IClientUser } from '../../clientUser';
3
- import { IAccount, IAttributes as IMoneyTransferActionAttributes } from '../action/moneyTransfer';
2
+ import { IAccount } from '../action/moneyTransfer';
4
3
  import * as TransactionFactory from '../transaction';
5
4
  import { AccountTransactionType } from '../transactionType';
6
- export declare type IRecipient = TransactionFactory.IRecipient;
7
- export declare type IAgent = TransactionFactory.IAgent;
8
- export declare type IStartParamsWithoutDetail = TransactionFactory.IStartParams<AccountTransactionType.Transfer, IAgent, IRecipient, IObjectWithoutDetail>;
5
+ export declare type IStartParamsWithoutDetail = TransactionFactory.IStartParams<AccountTransactionType.Transfer, IObjectWithoutDetail>;
9
6
  /**
10
- * 取引開始パラメーターインターフェース
7
+ * 取引開始パラメーター
11
8
  */
12
- export declare type IStartParams = TransactionFactory.IStartParams<AccountTransactionType.Transfer, IAgent, IRecipient, IObject>;
13
- export declare type IResult = any;
14
- /**
15
- * エラーインターフェース
16
- */
17
- export declare type IError = any;
18
- export interface IObjectWithoutDetail {
19
- clientUser?: IClientUser;
20
- amount: {
21
- value: number;
22
- };
9
+ export declare type IStartParams = TransactionFactory.IStartParams<AccountTransactionType.Transfer, IObject>;
10
+ export interface IObjectWithoutDetail extends TransactionFactory.IObjectWithoutDetail {
23
11
  fromLocation: TransactionFactory.ISimpleAccount;
24
12
  toLocation: TransactionFactory.ISimpleAccount;
25
- description?: string;
26
13
  }
27
14
  /**
28
- * 取引対象物インターフェース
15
+ * 取引対象物
29
16
  */
30
- export interface IObject {
31
- clientUser?: IClientUser;
32
- /**
33
- * 金額
34
- */
35
- amount: {
36
- value: number;
37
- };
17
+ export interface IObject extends TransactionFactory.IObject {
38
18
  /**
39
19
  * 転送元
40
20
  */
@@ -43,14 +23,10 @@ export interface IObject {
43
23
  * 転送先
44
24
  */
45
25
  toLocation: IAccount;
46
- description?: string;
47
26
  }
48
- export interface IPotentialActions {
49
- moneyTransfer: IMoneyTransferActionAttributes;
50
- }
51
- export declare type ITransaction = IExtendId<IAttributes>;
52
27
  /**
53
- * 転送取引インターフェース
28
+ * 転送取引
54
29
  */
55
- export interface IAttributes extends TransactionFactory.IAttributes<IStartParams, IResult, IError, IPotentialActions> {
30
+ export interface IAttributes extends TransactionFactory.IAttributes<IStartParams> {
56
31
  }
32
+ export declare type ITransaction = IExtendId<IAttributes>;
@@ -1,44 +1,24 @@
1
1
  import { IExtendId } from '../../autoGenerated';
2
- import { IClientUser } from '../../clientUser';
3
- import { IAccount, IAnonymousLocation, IAttributes as IMoneyTransferActionAttributes } from '../action/moneyTransfer';
2
+ import { IAccount, IAnonymousLocation } from '../action/moneyTransfer';
4
3
  import * as TransactionFactory from '../transaction';
5
4
  import { AccountTransactionType } from '../transactionType';
6
- export declare type IRecipient = TransactionFactory.IRecipient;
7
- export declare type IAgent = TransactionFactory.IAgent;
8
- export declare type IStartParamsWithoutDetail = TransactionFactory.IStartParams<AccountTransactionType.Withdraw, IAgent, IRecipient, IObjectWithoutDetail>;
5
+ export declare type IStartParamsWithoutDetail = TransactionFactory.IStartParams<AccountTransactionType.Withdraw, IObjectWithoutDetail>;
9
6
  /**
10
- * 取引開始パラメーターインターフェース
7
+ * 取引開始パラメーター
11
8
  */
12
- export declare type IStartParams = TransactionFactory.IStartParams<AccountTransactionType.Withdraw, IAgent, IRecipient, IObject>;
13
- export declare type IResult = any;
14
- /**
15
- * エラーインターフェース
16
- */
17
- export declare type IError = any;
18
- export interface IObjectWithoutDetail {
19
- clientUser?: IClientUser;
20
- amount: {
21
- value: number;
22
- };
9
+ export declare type IStartParams = TransactionFactory.IStartParams<AccountTransactionType.Withdraw, IObject>;
10
+ export interface IObjectWithoutDetail extends TransactionFactory.IObjectWithoutDetail {
23
11
  fromLocation: TransactionFactory.ISimpleAccount;
24
12
  toLocation?: IAnonymousLocation;
25
- description?: string;
26
13
  /**
27
14
  * 利用可能金額確認をしない場合、force: true
28
15
  */
29
16
  force?: boolean;
30
17
  }
31
18
  /**
32
- * 取引対象物インターフェース
19
+ * 取引対象物
33
20
  */
34
- export interface IObject {
35
- clientUser?: IClientUser;
36
- /**
37
- * 金額
38
- */
39
- amount: {
40
- value: number;
41
- };
21
+ export interface IObject extends TransactionFactory.IObject {
42
22
  /**
43
23
  * 出金元
44
24
  */
@@ -47,14 +27,11 @@ export interface IObject {
47
27
  * 出金先
48
28
  */
49
29
  toLocation?: IAnonymousLocation;
50
- description?: string;
51
30
  }
52
- export interface IPotentialActions {
53
- moneyTransfer: IMoneyTransferActionAttributes;
54
- }
55
- export declare type ITransaction = IExtendId<IAttributes>;
31
+ export import IPotentialActions = TransactionFactory.IPotentialActions;
56
32
  /**
57
- * 出金取引インターフェース
33
+ * 出金取引
58
34
  */
59
- export interface IAttributes extends TransactionFactory.IAttributes<IStartParams, IResult, IError, IPotentialActions> {
35
+ export interface IAttributes extends TransactionFactory.IAttributes<IStartParams> {
60
36
  }
37
+ export declare type ITransaction = IExtendId<IAttributes>;
@@ -13,10 +13,25 @@ export interface IProject {
13
13
  id: string;
14
14
  typeOf: OrganizationType.Project;
15
15
  }
16
+ export interface IObjectWithoutDetail {
17
+ amount: {
18
+ value: number;
19
+ };
20
+ description?: string;
21
+ }
22
+ export interface IObject {
23
+ /**
24
+ * 金額
25
+ */
26
+ amount: {
27
+ value: number;
28
+ };
29
+ description?: string;
30
+ }
16
31
  /**
17
32
  * 口座取引開始パラメータ
18
33
  */
19
- export interface IStartParams<T extends AccountTransactionType, TAgent extends IAgent, TRecipient extends IRecipient, TObject> {
34
+ export interface IStartParams<T extends AccountTransactionType, TObject extends IObject> {
20
35
  project: IProject;
21
36
  /**
22
37
  * 取引タイプ
@@ -30,16 +45,17 @@ export interface IStartParams<T extends AccountTransactionType, TAgent extends I
30
45
  /**
31
46
  * 取引番号
32
47
  * サービス使用側が指定するグローバルユニークな番号
48
+ * 必須化(2022-09-26~)
33
49
  */
34
- transactionNumber?: string;
50
+ transactionNumber: string;
35
51
  /**
36
52
  * 取引主体
37
53
  */
38
- agent: TAgent;
54
+ agent: IAgent;
39
55
  /**
40
56
  * 取引物受取者
41
57
  */
42
- recipient: TRecipient;
58
+ recipient: IRecipient;
43
59
  /**
44
60
  * 取引対象
45
61
  */
@@ -49,14 +65,19 @@ export interface IStartParams<T extends AccountTransactionType, TAgent extends I
49
65
  */
50
66
  expires: Date;
51
67
  }
68
+ export interface IPotentialActions {
69
+ moneyTransfer: MoneyTransferActionFactory.IAttributes;
70
+ }
52
71
  /**
53
- * 口座取引
72
+ * エラー
54
73
  */
55
- export declare type ITransaction<TStartParams, TResult, TError, TPotentialActions> = IExtendId<IAttributes<TStartParams, TResult, TError, TPotentialActions>>;
74
+ export declare type IError = any;
75
+ export interface IResult {
76
+ }
56
77
  /**
57
78
  * 口座取引属性
58
79
  */
59
- export declare type IAttributes<TStartParams, TResult, TError, TPotentialActions> = TStartParams & {
80
+ export declare type IAttributes<TStartParams> = TStartParams & {
60
81
  /**
61
82
  * 取引状態
62
83
  */
@@ -64,15 +85,15 @@ export declare type IAttributes<TStartParams, TResult, TError, TPotentialActions
64
85
  /**
65
86
  * 取引結果
66
87
  */
67
- result?: TResult;
88
+ result?: IResult;
68
89
  /**
69
90
  * 取引エラー
70
91
  */
71
- error?: TError;
92
+ error?: IError;
72
93
  /**
73
94
  * 取引開始日時
74
95
  */
75
- startDate?: Date;
96
+ startDate: Date;
76
97
  /**
77
98
  * 取引終了日時
78
99
  */
@@ -88,5 +109,9 @@ export declare type IAttributes<TStartParams, TResult, TError, TPotentialActions
88
109
  /**
89
110
  * 事後に発生するアクション
90
111
  */
91
- potentialActions?: TPotentialActions;
112
+ potentialActions?: IPotentialActions;
92
113
  };
114
+ /**
115
+ * 口座取引
116
+ */
117
+ export declare type ITransaction<TStartParams> = IExtendId<IAttributes<TStartParams>>;
package/lib/account.d.ts CHANGED
@@ -24,11 +24,13 @@ export declare namespace action {
24
24
  export import moneyTransfer = MoneyTransferActionFactory;
25
25
  }
26
26
  export declare namespace transaction {
27
- type IStartParams<T extends AccountTransactionType> = T extends AccountTransactionType.Deposit ? DepositTransactionFactory.IStartParams : T extends AccountTransactionType.Withdraw ? WithdrawTransactionFactory.IStartParams : T extends AccountTransactionType.Transfer ? TransferTransactionFactory.IStartParams : TransactionFactory.IStartParams<AccountTransactionType, any, any, any>;
28
- type IAttributes<T> = T extends AccountTransactionType.Deposit ? DepositTransactionFactory.IAttributes : T extends AccountTransactionType.Withdraw ? WithdrawTransactionFactory.IAttributes : T extends AccountTransactionType.Transfer ? TransferTransactionFactory.IAttributes : TransactionFactory.IAttributes<any, any, any, any>;
29
- type ITransaction<T> = T extends AccountTransactionType.Deposit ? DepositTransactionFactory.ITransaction : T extends AccountTransactionType.Withdraw ? WithdrawTransactionFactory.ITransaction : T extends AccountTransactionType.Transfer ? TransferTransactionFactory.ITransaction : TransactionFactory.ITransaction<any, any, any, any>;
30
- type IResult<T> = T extends AccountTransactionType.Deposit ? DepositTransactionFactory.IResult : T extends AccountTransactionType.Withdraw ? WithdrawTransactionFactory.IResult : T extends AccountTransactionType.Transfer ? TransferTransactionFactory.IResult : any;
31
- type IPotentialActions<T> = T extends AccountTransactionType.Deposit ? DepositTransactionFactory.IPotentialActions : T extends AccountTransactionType.Withdraw ? WithdrawTransactionFactory.IPotentialActions : T extends AccountTransactionType.Transfer ? TransferTransactionFactory.IPotentialActions : any;
27
+ export import IAgent = TransactionFactory.IAgent;
28
+ export import IRecipient = TransactionFactory.IRecipient;
29
+ export import IPotentialActions = TransactionFactory.IPotentialActions;
30
+ export import IResult = TransactionFactory.IResult;
31
+ type IStartParams<T extends AccountTransactionType> = T extends AccountTransactionType.Deposit ? DepositTransactionFactory.IStartParams : T extends AccountTransactionType.Withdraw ? WithdrawTransactionFactory.IStartParams : T extends AccountTransactionType.Transfer ? TransferTransactionFactory.IStartParams : never;
32
+ type IAttributes<T> = T extends AccountTransactionType.Deposit ? DepositTransactionFactory.IAttributes : T extends AccountTransactionType.Withdraw ? WithdrawTransactionFactory.IAttributes : T extends AccountTransactionType.Transfer ? TransferTransactionFactory.IAttributes : never;
33
+ type ITransaction<T> = T extends AccountTransactionType.Deposit ? DepositTransactionFactory.ITransaction : T extends AccountTransactionType.Withdraw ? WithdrawTransactionFactory.ITransaction : T extends AccountTransactionType.Transfer ? TransferTransactionFactory.ITransaction : never;
32
34
  export import withdraw = WithdrawTransactionFactory;
33
35
  export import deposit = DepositTransactionFactory;
34
36
  export import transfer = TransferTransactionFactory;
@@ -68,15 +70,15 @@ export interface IAccount {
68
70
  /**
69
71
  * 口座名義
70
72
  */
71
- name?: string;
73
+ name: string;
72
74
  /**
73
75
  * 残高
74
76
  */
75
- balance?: number;
77
+ balance: number;
76
78
  /**
77
79
  * 利用可能残高
78
80
  */
79
- availableBalance?: number;
81
+ availableBalance: number;
80
82
  /**
81
83
  * 進行中取引リスト
82
84
  */
@@ -84,7 +86,7 @@ export interface IAccount {
84
86
  /**
85
87
  * 口座開設日時
86
88
  */
87
- openDate?: Date;
89
+ openDate: Date;
88
90
  /**
89
91
  * 口座閉鎖日時
90
92
  */
@@ -92,7 +94,7 @@ export interface IAccount {
92
94
  /**
93
95
  * 口座ステータス
94
96
  */
95
- status?: AccountStatusType;
97
+ status: AccountStatusType;
96
98
  }
97
99
  /**
98
100
  * ソート条件
@@ -1,10 +1,10 @@
1
1
  import * as COA from '@motionpicture/coa-service';
2
2
  import * as ActionFactory from '../../../action';
3
+ import { ITotalPaymentDue } from '../../../action/trade/pay';
3
4
  import { ActionType } from '../../../actionType';
4
5
  import * as ReserveTransactionFactory from '../../../assetTransaction/reserve';
5
6
  import { AssetTransactionType } from '../../../assetTransactionType';
6
7
  import * as ScreeningEventFactory from '../../../event/screeningEvent';
7
- import { IMonetaryAmount } from '../../../monetaryAmount';
8
8
  import * as OfferFactory from '../../../offer';
9
9
  import * as OrderFactory from '../../../order';
10
10
  import { PriceCurrency } from '../../../priceCurrency';
@@ -33,7 +33,7 @@ export interface IResult<T extends WebAPIFactory.Identifier> {
33
33
  * オファーに対して必要な金額
34
34
  * currencyを口座タイプとして扱う
35
35
  */
36
- amount: IMonetaryAmount[];
36
+ amount: ITotalPaymentDue[];
37
37
  /**
38
38
  * 外部リクエストエンドポイント
39
39
  */
@@ -1,15 +1,15 @@
1
1
  import * as ActionFactory from '../../../action';
2
2
  import * as CheckMovieTicketActionFactory from '../../../action/check/paymentMethod/movieTicket';
3
+ import { ITotalPaymentDue } from '../../../action/trade/pay';
3
4
  import * as MoneyTransferActionFactory from '../../../action/transfer/moneyTransfer';
4
5
  import { ActionType } from '../../../actionType';
5
6
  import * as PayTransactionFactory from '../../../assetTransaction/pay';
6
7
  import { AssetTransactionType } from '../../../assetTransactionType';
7
- import { IMonetaryAmount } from '../../../monetaryAmount';
8
+ import { IPaymentMethodIssuedThrough } from '../../../order';
8
9
  import * as CreditCardFactory from '../../../paymentMethod/paymentCard/creditCard';
9
10
  import * as MovieTicketFactory from '../../../paymentMethod/paymentCard/movieTicket';
10
11
  import { PaymentStatusType } from '../../../paymentStatusType';
11
12
  import { IPropertyValue } from '../../../propertyValue';
12
- import { PaymentServiceType } from '../../../service/paymentService';
13
13
  import { TransactionType } from '../../../transactionType';
14
14
  import * as AuthorizeActionFactory from '../../authorize';
15
15
  export declare type IAgent = ActionFactory.IParticipantAsWebApplication | ActionFactory.IParticipantAsPerson;
@@ -111,23 +111,6 @@ export interface IObject {
111
111
  movieTickets?: IMovieTicket[];
112
112
  }
113
113
  export declare type IPaymentServiceOutput = IMovieTicket[];
114
- /**
115
- * 決済方法の発行サービス
116
- */
117
- export interface IPaymentMethodIssuedThrough {
118
- /**
119
- * 決済サービスタイプ
120
- */
121
- typeOf: PaymentServiceType;
122
- /**
123
- * サービスID
124
- */
125
- id: string;
126
- /**
127
- * 決済サービスによって発行された決済カード
128
- */
129
- serviceOutput?: IPaymentServiceOutput;
130
- }
131
114
  export interface IResult {
132
115
  /**
133
116
  * The identifier for the account the payment will be applied to.
@@ -156,7 +139,7 @@ export interface IResult {
156
139
  /**
157
140
  * The total amount due.
158
141
  */
159
- totalPaymentDue?: IMonetaryAmount;
142
+ totalPaymentDue?: ITotalPaymentDue;
160
143
  /**
161
144
  * 追加特性
162
145
  */
@@ -211,3 +194,4 @@ export interface IAttributes extends AuthorizeActionFactory.IAttributes<IObject,
211
194
  * 決済承認アクション
212
195
  */
213
196
  export declare type IAction = ActionFactory.IAction<IAttributes>;
197
+ export { ITotalPaymentDue };
@@ -2,12 +2,6 @@ import { AssetTransactionType } from '../../../assetTransactionType';
2
2
  import { ISimpleOrder } from '../../../order';
3
3
  import { TransactionType } from '../../../transactionType';
4
4
  import * as ConfirmActionFactory from '../confirm';
5
- /**
6
- * 匿名ロケーションインターフェース
7
- */
8
- /**
9
- * 決済方法インターフェース
10
- */
11
5
  /**
12
6
  * 転送元あるいは転送先の場所インターフェース
13
7
  */
@@ -4,8 +4,7 @@ import * as ActionFactory from '../../action';
4
4
  import { IAttributes as IReturnOrderActionAttributes } from '../../action/transfer/return/order';
5
5
  import { ActionType } from '../../actionType';
6
6
  import { AssetTransactionType } from '../../assetTransactionType';
7
- import { IPaymentServiceOutput } from '../../invoice';
8
- import { IMonetaryAmount } from '../../monetaryAmount';
7
+ import { IPaymentServiceOutput, ITotalPaymentDue } from '../../invoice';
9
8
  import { OrderType } from '../../order';
10
9
  import { IMovieTicket } from '../../paymentMethod/paymentCard/movieTicket';
11
10
  import { IPropertyValue } from '../../propertyValue';
@@ -69,7 +68,7 @@ export interface IPaymentMethod {
69
68
  /**
70
69
  * The total amount due.
71
70
  */
72
- totalPaymentDue?: IMonetaryAmount;
71
+ totalPaymentDue?: ITotalPaymentDue;
73
72
  /**
74
73
  * 追加特性
75
74
  */
@@ -126,3 +125,4 @@ export interface IAttributes extends ActionFactory.IAttributes<ActionType.PayAct
126
125
  * 決済アクション
127
126
  */
128
127
  export declare type IAction = ActionFactory.IAction<IAttributes>;
128
+ export { ITotalPaymentDue };
@@ -11,7 +11,7 @@ export interface IPendingTransaction {
11
11
  typeOf: AccountFactory.transactionType;
12
12
  id: string;
13
13
  identifier?: string;
14
- transactionNumber?: string;
14
+ transactionNumber: string;
15
15
  }
16
16
  export declare type IAgent = ActionFactory.IParticipantAsProject | ActionFactory.IParticipantAsPerson | ActionFactory.IParticipantAsSeller;
17
17
  export declare type IRecipient = ActionFactory.IParticipant;
@@ -43,6 +43,7 @@ export interface ITransactionPurpose {
43
43
  identifier?: string;
44
44
  }
45
45
  export declare type IPurpose = ITransactionPurpose;
46
+ export declare type IAmount = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'value'>;
46
47
  export interface IAttributes extends ActionFactory.IAttributes<ActionType.MoneyTransfer, IObject, IResult> {
47
48
  typeOf: ActionType.MoneyTransfer;
48
49
  agent: IAgent;
@@ -51,7 +52,7 @@ export interface IAttributes extends ActionFactory.IAttributes<ActionType.MoneyT
51
52
  /**
52
53
  * 金額
53
54
  */
54
- amount: IMonetaryAmount;
55
+ amount: IAmount;
55
56
  /**
56
57
  * 転送元
57
58
  */
@@ -1,8 +1,7 @@
1
- import { IAttributes as IMoneyTransferActionAttributes, ILocation, IPendingTransaction, IRecipient as IMoneyTransferRecipient } from '../action/transfer/moneyTransfer';
1
+ import { IAmount as IMoneyTransferAmount, IAttributes as IMoneyTransferActionAttributes, ILocation, IPendingTransaction, IRecipient as IMoneyTransferRecipient } from '../action/transfer/moneyTransfer';
2
2
  import * as AssetTransactionFactory from '../assetTransaction';
3
3
  import { AssetTransactionType } from '../assetTransactionType';
4
4
  import { IExtendId } from '../autoGenerated';
5
- import { IMonetaryAmount } from '../monetaryAmount';
6
5
  import { OrderType } from '../order';
7
6
  import { PermitType } from '../permit';
8
7
  export import IAgent = AssetTransactionFactory.IAgent;
@@ -47,7 +46,7 @@ export interface IObject {
47
46
  /**
48
47
  * 金額
49
48
  */
50
- amount: IMonetaryAmount;
49
+ amount: IMoneyTransferAmount;
51
50
  /**
52
51
  * 転送元
53
52
  */
@@ -71,7 +70,7 @@ export interface IObjectBeforeStart {
71
70
  /**
72
71
  * 金額
73
72
  */
74
- amount: IMonetaryAmount;
73
+ amount: IMoneyTransferAmount;
75
74
  /**
76
75
  * 転送元
77
76
  */
@@ -84,7 +83,10 @@ export interface IObjectBeforeStart {
84
83
  * 取引説明
85
84
  */
86
85
  description?: string;
87
- pendingTransaction?: IPendingTransaction;
86
+ /**
87
+ * 口座取引タイプの確認ために指定
88
+ */
89
+ pendingTransaction: Pick<IPendingTransaction, 'typeOf'>;
88
90
  /**
89
91
  * 負の残高でも強制的に出金するかどうか
90
92
  */
@@ -1,9 +1,8 @@
1
1
  import * as GMO from '@motionpicture/gmo-service';
2
- import { IAttributes as IPayActionAttributes, IOrderAsPayPurpose, IPayPurpose, IPendingTransaction, IRecipient as IPayRecipient } from '../action/trade/pay';
2
+ import { IAttributes as IPayActionAttributes, IOrderAsPayPurpose, IPayPurpose, IPendingTransaction, IRecipient as IPayRecipient, ITotalPaymentDue } from '../action/trade/pay';
3
3
  import * as AssetTransactionFactory from '../assetTransaction';
4
4
  import { AssetTransactionType } from '../assetTransactionType';
5
5
  import { IExtendId } from '../autoGenerated';
6
- import { IMonetaryAmount } from '../monetaryAmount';
7
6
  import { IUnauthorizedCardOfMember, IUncheckedCardRaw, IUncheckedCardTokenized } from '../paymentMethod/paymentCard/creditCard';
8
7
  import { IMovieTicket } from '../paymentMethod/paymentCard/movieTicket';
9
8
  import { IOnPaymentStatusChanged } from '../project';
@@ -53,7 +52,7 @@ export interface IPaymentMethod {
53
52
  /**
54
53
  * The total amount due.
55
54
  */
56
- totalPaymentDue?: IMonetaryAmount;
55
+ totalPaymentDue?: ITotalPaymentDue;
57
56
  /**
58
57
  * 決済方法タイプ
59
58
  */
package/lib/invoice.d.ts CHANGED
@@ -33,6 +33,7 @@ export interface IPaymentMethod {
33
33
  typeOf: PaymentServiceType;
34
34
  serviceOutput?: IPaymentServiceOutput;
35
35
  }
36
+ export declare type ITotalPaymentDue = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'value'>;
36
37
  /**
37
38
  * インボイスインターフェース
38
39
  * {@link https://schema.org/Invoice}
@@ -101,7 +102,7 @@ export interface IInvoice {
101
102
  /**
102
103
  * The total amount due.
103
104
  */
104
- totalPaymentDue?: IMonetaryAmount;
105
+ totalPaymentDue?: ITotalPaymentDue;
105
106
  }
106
107
  /**
107
108
  * ソート条件インターフェース
@@ -41,6 +41,7 @@ export declare enum MerchantReturnEnumeration {
41
41
  */
42
42
  MerchantReturnUnspecified = "MerchantReturnUnspecified"
43
43
  }
44
+ export declare type IRestockingFee = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'value'>;
44
45
  export interface IMerchantReturnPolicy extends Pick<IThing, 'name' | 'url'> {
45
46
  typeOf: 'MerchantReturnPolicy';
46
47
  /**
@@ -72,7 +73,7 @@ export interface IMerchantReturnPolicy extends Pick<IThing, 'name' | 'url'> {
72
73
  * Use MonetaryAmount to specify a fixed restocking fee for product returns,
73
74
  * or use Number to specify a percentage of the product price paid by the customer.
74
75
  */
75
- restockingFee?: IMonetaryAmount | number;
76
+ restockingFee?: IRestockingFee | number;
76
77
  /**
77
78
  * Indicates (via enumerated options) the return fees policy for a MerchantReturnPolicy
78
79
  */
package/lib/offer.d.ts CHANGED
@@ -4,6 +4,7 @@ import { ItemAvailability } from './itemAvailability';
4
4
  import { IMonetaryAmount } from './monetaryAmount';
5
5
  import { OfferType } from './offerType';
6
6
  import { OrganizationType } from './organizationType';
7
+ import { IAmount as IPermitAmount, IDepositAmount, IPaymentAmount } from './permit';
7
8
  import { PriceCurrency } from './priceCurrency';
8
9
  import { IPriceSpecification } from './priceSpecification';
9
10
  import { IPriceSpecification as ICategoryCodeChargeSpecification } from './priceSpecification/categoryCodeChargeSpecification';
@@ -11,7 +12,7 @@ import { IPriceSpecification as ICompoundPriceSpecification } from './priceSpeci
11
12
  import { IPriceSpecification as IMovieTicketTypeChargeSpecification } from './priceSpecification/movieTicketTypeChargeSpecification';
12
13
  import { IAppliesToMovieTicket, IPriceSpecification as IUnitPriceSpecification } from './priceSpecification/unitPriceSpecification';
13
14
  import { PriceSpecificationType } from './priceSpecificationType';
14
- import { ProductType } from './product';
15
+ import { IPointAwardAmount, ProductType } from './product';
15
16
  import { IProject } from './project';
16
17
  import { IPropertyValue } from './propertyValue';
17
18
  import { IQuantitativeValue } from './quantitativeValue';
@@ -34,7 +35,7 @@ export interface ICategory {
34
35
  */
35
36
  export declare type IAddOn = IOffer;
36
37
  export declare type IEligibleCategoryCode = Pick<ICategoryCode, 'project' | 'typeOf' | 'id' | 'codeValue' | 'inCodeSet'>;
37
- export declare type IEligibleMonetaryAmount = IMonetaryAmount;
38
+ export declare type IEligibleMonetaryAmount = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'value'>;
38
39
  /**
39
40
  * 適用サブ予約条件
40
41
  */
@@ -208,15 +209,15 @@ export interface IItemOffered {
208
209
  /**
209
210
  * ペイメントカード初期金額
210
211
  */
211
- amount?: IMonetaryAmount;
212
+ amount?: IPermitAmount;
212
213
  /**
213
214
  * ペイメントカード入金設定
214
215
  */
215
- depositAmount?: IMonetaryAmount;
216
+ depositAmount?: IDepositAmount;
216
217
  /**
217
218
  * ペイメントカード決済設定
218
219
  */
219
- paymentAmount?: IMonetaryAmount;
220
+ paymentAmount?: IPaymentAmount;
220
221
  };
221
222
  /**
222
223
  * 特典
@@ -225,7 +226,7 @@ export interface IItemOffered {
225
226
  /**
226
227
  * 付与金額
227
228
  */
228
- amount?: IMonetaryAmount;
229
+ amount?: IPointAwardAmount;
229
230
  /**
230
231
  * 特典説明
231
232
  */
package/lib/order.d.ts CHANGED
@@ -1,12 +1,11 @@
1
1
  import { IParticipant } from './action';
2
- import { IPaymentMethodIssuedThrough } from './action/authorize/paymentMethod/any';
2
+ import { IPaymentService, ITotalPaymentDue } from './action/trade/pay';
3
+ import { IAmount as IMoneyTransferAmount, IPaymentCard as IPaymentCardAsMoneyTransferToLocation } from './action/transfer/moneyTransfer';
3
4
  import { ActionType } from './actionType';
4
- import { IPaymentCard } from './assetTransaction/moneyTransfer';
5
5
  import { AssetTransactionType } from './assetTransactionType';
6
6
  import { ICreativeWork as IWebApplication } from './creativeWork/softwareApplication/webApplication';
7
7
  import { ICustomer as ICustomerOrganization } from './customer';
8
8
  import { EventType } from './eventType';
9
- import * as MonetaryAmountFactory from './monetaryAmount';
10
9
  import { IMultilingualString } from './multilingualString';
11
10
  import { IOffer, ITicketPriceSpecification } from './offer';
12
11
  import { OrderStatus } from './orderStatus';
@@ -30,6 +29,7 @@ export interface IProject {
30
29
  export declare enum OrderType {
31
30
  Order = "Order"
32
31
  }
32
+ export declare type IPaymentMethodIssuedThrough = Pick<IPaymentService, 'typeOf' | 'id' | 'serviceOutput'>;
33
33
  /**
34
34
  * 決済方法
35
35
  */
@@ -53,7 +53,7 @@ export interface IPaymentMethod {
53
53
  /**
54
54
  * The total amount due.
55
55
  */
56
- totalPaymentDue?: MonetaryAmountFactory.IMonetaryAmount;
56
+ totalPaymentDue?: ITotalPaymentDue;
57
57
  /**
58
58
  * 追加特性
59
59
  */
@@ -105,17 +105,18 @@ export interface IMoneyTransferPendingTransaction {
105
105
  */
106
106
  transactionNumber: string;
107
107
  }
108
+ export declare type IMoneyTransferToLocation = Pick<IPaymentCardAsMoneyTransferToLocation, 'typeOf' | 'identifier' | 'issuedThrough'>;
108
109
  export interface IMoneyTransfer {
109
110
  typeOf: ActionType.MoneyTransfer;
110
111
  /**
111
112
  * 金額
112
113
  */
113
- amount: MonetaryAmountFactory.IMonetaryAmount;
114
+ amount: IMoneyTransferAmount;
114
115
  description?: string;
115
116
  /**
116
117
  * 転送先
117
118
  */
118
- toLocation: IPaymentCard;
119
+ toLocation: IMoneyTransferToLocation;
119
120
  object: {
120
121
  /**
121
122
  * 入金処理の資産取引
@@ -1,5 +1,6 @@
1
1
  import { IMonetaryAmount } from '../monetaryAmount';
2
2
  import { IPaymentMethod } from '../paymentMethod';
3
+ export declare type IAmount = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'validThrough'>;
3
4
  /**
4
5
  * payment card interface
5
6
  */
@@ -12,7 +13,7 @@ export interface IPaymentCard extends IPaymentMethod {
12
13
  /**
13
14
  * The amount of money.
14
15
  */
15
- amount?: IMonetaryAmount;
16
+ amount?: IAmount;
16
17
  serviceOutput?: any;
17
18
  serviceType?: any;
18
19
  }
package/lib/permit.d.ts CHANGED
@@ -9,6 +9,11 @@ export declare enum PermitType {
9
9
  Permit = "Permit"
10
10
  }
11
11
  export declare type IIssuedThrough = Pick<IProduct, 'id' | 'project' | 'serviceType' | 'typeOf'>;
12
+ export declare type IPaymentAccount = Pick<IAccount, 'project' | 'typeOf' | 'accountNumber' | 'accountType'>;
13
+ export declare type IAmount = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'value'>;
14
+ export declare type IDepositAmount = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'maxValue' | 'minValue'>;
15
+ export declare type IPaymentAmount = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'maxValue' | 'minValue'>;
16
+ export declare type IIssuedBy = Pick<IOrganization, 'typeOf' | 'id' | 'name'>;
12
17
  /**
13
18
  * A permit issued by an organization, e.g. a parking pass.
14
19
  * {@link https://schema.org/Permit}
@@ -19,15 +24,15 @@ export interface IPermit extends Pick<IThing, 'name'> {
19
24
  identifier?: string;
20
25
  accessCode?: string;
21
26
  additionalProperty?: IPropertyValue<string>[];
22
- amount?: IMonetaryAmount;
23
- depositAmount?: IMonetaryAmount;
24
- paymentAmount?: IMonetaryAmount;
25
- paymentAccount?: IAccount;
27
+ amount?: IAmount;
28
+ depositAmount?: IDepositAmount;
29
+ paymentAmount?: IPaymentAmount;
30
+ paymentAccount?: IPaymentAccount;
26
31
  dateIssued?: Date;
27
32
  /**
28
33
  * The organization issuing the ticket or permit.
29
34
  */
30
- issuedBy?: IOrganization;
35
+ issuedBy?: IIssuedBy;
31
36
  /**
32
37
  * The service through with the permit was granted.
33
38
  */
package/lib/product.d.ts CHANGED
@@ -37,12 +37,13 @@ export declare type IServiceOutput = IPermit & {
37
37
  membershipPointsEarned?: IQuantitativeValue<any>;
38
38
  automaticRenewal?: boolean;
39
39
  };
40
+ export declare type IPointAwardAmount = Pick<IMonetaryAmount, 'typeOf' | 'currency' | 'value'>;
40
41
  /**
41
42
  * ポイント特典インターフェース
42
43
  */
43
44
  export interface IPointAward {
44
45
  typeOf: ActionType.MoneyTransfer;
45
- amount?: IMonetaryAmount;
46
+ amount?: IPointAwardAmount;
46
47
  /**
47
48
  * 特典付与先
48
49
  */
@@ -1,10 +1,10 @@
1
1
  import * as waiter from '@waiter/factory';
2
2
  import { IAction as IAuthorizeAction, IAttributes as IAuthorizeActionAttributes } from '../action/authorize';
3
3
  import { IAttributes as IMoneyTransferActionAttributes } from '../action/interact/confirm/moneyTransfer';
4
+ import { IAmount as IMoneyTransferAmount } from '../action/transfer/moneyTransfer';
4
5
  import * as MoneyTransferAssetTransactionFactory from '../assetTransaction/moneyTransfer';
5
6
  import { AssetTransactionType } from '../assetTransactionType';
6
7
  import { IExtendId } from '../autoGenerated';
7
- import { IMonetaryAmount } from '../monetaryAmount';
8
8
  import { PersonType } from '../personType';
9
9
  import { IProject } from '../project';
10
10
  import * as TransactionFactory from '../transaction';
@@ -57,7 +57,7 @@ export interface IStartParamsWithoutDetail {
57
57
  /**
58
58
  * 金額
59
59
  */
60
- amount: IMonetaryAmount;
60
+ amount: IMoneyTransferAmount;
61
61
  /**
62
62
  * 転送元
63
63
  */
@@ -98,7 +98,7 @@ export interface IObject {
98
98
  /**
99
99
  * 金額
100
100
  */
101
- amount: IMonetaryAmount;
101
+ amount: IMoneyTransferAmount;
102
102
  /**
103
103
  * 転送元
104
104
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chevre/factory",
3
- "version": "4.267.0",
3
+ "version": "4.268.0-alpha.0",
4
4
  "description": "Chevre Factory Library for Javascript",
5
5
  "main": "./lib/index.js",
6
6
  "types": "./lib/index.d.ts",