diff --git a/package-lock.json b/package-lock.json index 4c259ae..b4aa664 100644 --- a/package-lock.json +++ b/package-lock.json @@ -17,7 +17,7 @@ "gulp-util": "3.0.8", "json-merge-patch": "1.0.2", "portfinder": "1.0.28", - "shelljs": "0.8.5", + "shelljs": "^0.8.5", "swagger-repo": "1.5.1", "swagger-ui": "5.3.1" } diff --git a/package.json b/package.json index cd708d0..b045cba 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,7 @@ "gulp-util": "3.0.8", "json-merge-patch": "1.0.2", "portfinder": "1.0.28", - "shelljs": "0.8.5", + "shelljs": "^0.8.5", "swagger-repo": "1.5.1", "swagger-ui": "5.3.1" } diff --git a/spec/definitions/Payout.yaml b/spec/definitions/Payout.yaml deleted file mode 100644 index 59c7820..0000000 --- a/spec/definitions/Payout.yaml +++ /dev/null @@ -1,43 +0,0 @@ -type: object -required: - - id - - shopID - - createdAt - - amount - - currency - - payoutToolDetails -properties: - id: - description: Payout ID - type: string - shopID: - description: Shop ID - type: string - createdAt: - description: Date and time of creation - type: string - format: date-time - cancellationDetails: - description: Details of the canceled payout - type: string - maxLength: 1000 - amount: - description: > - Payout amount, in minor monetary units, e.g. cents if US dollars are - specified as the currency. - type: integer - format: int64 - minimum: 1 - fee: - description: System fee in minor monetary units - type: integer - format: int64 - minimum: 0 - currency: - x-rebillyMerge: - - $ref: "#/definitions/Currency" - payoutToolDetails: - $ref: "#/definitions/PayoutToolDetails" - status: - description: Payout status - type: string diff --git a/spec/definitions/PayoutID.yaml b/spec/definitions/PayoutID.yaml deleted file mode 100644 index 925cd6f..0000000 --- a/spec/definitions/PayoutID.yaml +++ /dev/null @@ -1,4 +0,0 @@ -description: Payout ID -type: string -maxLength: 40 -minLength: 1 diff --git a/spec/definitions/PayoutParams.yaml b/spec/definitions/PayoutParams.yaml deleted file mode 100644 index 0091ce0..0000000 --- a/spec/definitions/PayoutParams.yaml +++ /dev/null @@ -1,29 +0,0 @@ -type: object -required: - - shopID - - payoutToolID - - amount - - currency -properties: - id: - x-rebillyMerge: - - $ref: "#/definitions/PayoutID" - shopID: - description: Shop ID - type: string - partyID: - x-rebillyMerge: - - $ref: "#/definitions/PartyID" - payoutToolID: - description: Payout tool ID - type: string - amount: - description: > - Payout amount, in minor monetary units, e.g. cents if US dollars are - specified as the currency. - type: integer - format: int64 - minimum: 1 - currency: - x-rebillyMerge: - - $ref: "#/definitions/Currency" diff --git a/spec/definitions/PayoutTool.yaml b/spec/definitions/PayoutTool.yaml deleted file mode 100644 index cb5a31a..0000000 --- a/spec/definitions/PayoutTool.yaml +++ /dev/null @@ -1,10 +0,0 @@ -description: Payout tool -allOf: - - type: object - required: - - id - properties: - id: - description: Payout tool ID - type: string - - $ref: "#/definitions/PayoutToolParams" diff --git a/spec/definitions/PayoutToolDetails.yaml b/spec/definitions/PayoutToolDetails.yaml deleted file mode 100644 index 37e7dbb..0000000 --- a/spec/definitions/PayoutToolDetails.yaml +++ /dev/null @@ -1,9 +0,0 @@ -description: Payout tool details -type: object -discriminator: detailsType -properties: - detailsType: - description: Payout tool type - type: string -required: - - detailsType diff --git a/spec/definitions/PayoutToolDetailsBankAccount.yaml b/spec/definitions/PayoutToolDetailsBankAccount.yaml deleted file mode 100644 index f16cf42..0000000 --- a/spec/definitions/PayoutToolDetailsBankAccount.yaml +++ /dev/null @@ -1,4 +0,0 @@ -type: object -allOf: - - $ref: "#/definitions/PayoutToolDetails" - - $ref: "#/definitions/BankAccount" diff --git a/spec/definitions/PayoutToolDetailsInternationalBankAccount.yaml b/spec/definitions/PayoutToolDetailsInternationalBankAccount.yaml deleted file mode 100644 index f17b1b8..0000000 --- a/spec/definitions/PayoutToolDetailsInternationalBankAccount.yaml +++ /dev/null @@ -1,4 +0,0 @@ -type: object -allOf: - - $ref: "#/definitions/PayoutToolDetails" - - $ref: "#/definitions/InternationalBankAccount" diff --git a/spec/definitions/PayoutToolDetailsPaymentInstitutionAccount.yaml b/spec/definitions/PayoutToolDetailsPaymentInstitutionAccount.yaml deleted file mode 100644 index 17e6baf..0000000 --- a/spec/definitions/PayoutToolDetailsPaymentInstitutionAccount.yaml +++ /dev/null @@ -1,4 +0,0 @@ -type: object -allOf: - - $ref: "#/definitions/PayoutToolDetails" - - $ref: "#/definitions/PaymentInstitutionAccount" diff --git a/spec/definitions/PayoutToolDetailsWalletInfo.yaml b/spec/definitions/PayoutToolDetailsWalletInfo.yaml deleted file mode 100644 index 339fd3b..0000000 --- a/spec/definitions/PayoutToolDetailsWalletInfo.yaml +++ /dev/null @@ -1,12 +0,0 @@ -type: object -allOf: - - $ref: "#/definitions/PayoutToolDetails" - - type: object - required: - - walletID - properties: - walletID: - description: Identifier of the wallet - type: string - maxLength: 40 - minLength: 1 diff --git a/spec/definitions/PayoutToolParams.yaml b/spec/definitions/PayoutToolParams.yaml deleted file mode 100644 index ccc1415..0000000 --- a/spec/definitions/PayoutToolParams.yaml +++ /dev/null @@ -1,10 +0,0 @@ -type: object -required: - - currency - - details -properties: - currency: - description: Payout currency - type: string - details: - $ref: "#/definitions/PayoutToolDetails" diff --git a/spec/definitions/Shop.yaml b/spec/definitions/Shop.yaml index 59c3f5c..98c4edc 100644 --- a/spec/definitions/Shop.yaml +++ b/spec/definitions/Shop.yaml @@ -39,12 +39,3 @@ properties: description: > Contract identifier on the basis of which the shop is serviced type: string - payoutToolID: - description: > - Payout tool identifier within the contract used in the payout process - by shop - type: string - scheduleID: - description: Payout schedule identifier - type: integer - format: int32 diff --git a/spec/paths/analytics@shops@{shopID}@payouts.yaml b/spec/paths/analytics@shops@{shopID}@payouts.yaml deleted file mode 100644 index af6b12f..0000000 --- a/spec/paths/analytics@shops@{shopID}@payouts.yaml +++ /dev/null @@ -1,50 +0,0 @@ -get: - description: Search for payouts - tags: - - Search - operationId: searchPayouts - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/shopID" - - $ref: "#/parameters/fromTime" - - $ref: "#/parameters/toTime" - - $ref: "#/parameters/limit" - - $ref: "#/parameters/offset" - - name: payoutID - in: query - description: Payout ID - required: false - type: string - maxLength: 40 - minLength: 1 - - name: payoutToolType - in: query - required: false - type: string - enum: - - PayoutAccount - - Wallet - - PaymentInstitutionAccount - description: > - Type of payout to search * PayoutAccount - payout to bank account * - Wallet - payout to wallet * PaymentInstitutionAccount - payout to - payment institution account - responses: - "200": - description: Payouts found - schema: - type: object - properties: - totalCount: - type: integer - result: - type: array - items: - $ref: "#/definitions/Payout" - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@contracts@{contractID}@payout_tools.yaml b/spec/paths/processing@contracts@{contractID}@payout_tools.yaml deleted file mode 100644 index 2c2f37b..0000000 --- a/spec/paths/processing@contracts@{contractID}@payout_tools.yaml +++ /dev/null @@ -1,22 +0,0 @@ -get: - description: Get all payout tools to the specified contract - operationId: getPayoutTools - tags: - - Payouts - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/contractID" - responses: - "200": - description: List of payout tools - schema: - type: array - items: - $ref: "#/definitions/PayoutTool" - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@contracts@{contractID}@payout_tools@{payoutToolID}.yaml b/spec/paths/processing@contracts@{contractID}@payout_tools@{payoutToolID}.yaml deleted file mode 100644 index 274e87a..0000000 --- a/spec/paths/processing@contracts@{contractID}@payout_tools@{payoutToolID}.yaml +++ /dev/null @@ -1,21 +0,0 @@ -get: - description: Get a payout tool data by identifier - operationId: getPayoutToolByID - tags: - - Payouts - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/contractID" - - $ref: "#/parameters/payoutToolID" - responses: - "200": - description: Payout tool details - schema: - $ref: "#/definitions/PayoutTool" - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@parties@{partyID}@contracts@{contractID}@payout_tools.yaml b/spec/paths/processing@parties@{partyID}@contracts@{contractID}@payout_tools.yaml deleted file mode 100644 index 3fa5c21..0000000 --- a/spec/paths/processing@parties@{partyID}@contracts@{contractID}@payout_tools.yaml +++ /dev/null @@ -1,23 +0,0 @@ -get: - description: Get all payout tools to the specified contract - operationId: getPayoutToolsForParty - tags: - - Payouts - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/contractID" - - $ref: "#/parameters/partyID" - responses: - "200": - description: List of payout tools - schema: - type: array - items: - $ref: "#/definitions/PayoutTool" - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@parties@{partyID}@contracts@{contractID}@payout_tools@{payoutToolID}.yaml b/spec/paths/processing@parties@{partyID}@contracts@{contractID}@payout_tools@{payoutToolID}.yaml deleted file mode 100644 index 0174c89..0000000 --- a/spec/paths/processing@parties@{partyID}@contracts@{contractID}@payout_tools@{payoutToolID}.yaml +++ /dev/null @@ -1,22 +0,0 @@ -get: - description: Get a payout tool data by identifier - operationId: getPayoutToolByIDForParty - tags: - - Payouts - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/contractID" - - $ref: "#/parameters/payoutToolID" - - $ref: "#/parameters/partyID" - responses: - "200": - description: Payout tool details - schema: - $ref: "#/definitions/PayoutTool" - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@parties@{partyID}@payment-institutions@{paymentInstitutionID}@terms@payouts@methods.yaml b/spec/paths/processing@parties@{partyID}@payment-institutions@{paymentInstitutionID}@terms@payouts@methods.yaml deleted file mode 100644 index 83f5d63..0000000 --- a/spec/paths/processing@parties@{partyID}@payment-institutions@{paymentInstitutionID}@terms@payouts@methods.yaml +++ /dev/null @@ -1,36 +0,0 @@ -get: - description: Get payout methods for the payment institution - tags: - - PaymentInstitutions - operationId: getPaymentInstitutionPayoutMethodsForParty - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/partyID" - - $ref: "#/parameters/paymentInstitutionID" - - name: currency - in: query - required: false - description: > - Currency character code according to - [ISO 4217](http://www.iso.org/iso/home/standards/currency_codes.htm). - type: string - pattern: "^[A-Z]{3}$" - responses: - "200": - description: Payout method - schema: - type: array - items: - type: string - enum: - - BankAccount - - InternationalBankAccount - - Wallet - - PaymentInstitutionAccount - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@parties@{partyID}@payment-institutions@{paymentInstitutionID}@terms@payouts@schedules.yaml b/spec/paths/processing@parties@{partyID}@payment-institutions@{paymentInstitutionID}@terms@payouts@schedules.yaml deleted file mode 100644 index dc45253..0000000 --- a/spec/paths/processing@parties@{partyID}@payment-institutions@{paymentInstitutionID}@terms@payouts@schedules.yaml +++ /dev/null @@ -1,41 +0,0 @@ -get: - description: Get available payout schedules for the payment institution - tags: - - PaymentInstitutions - operationId: getPaymentInstitutionPayoutSchedulesForParty - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/partyID" - - $ref: "#/parameters/paymentInstitutionID" - - name: currency - in: query - required: false - description: > - Currency character code according to - [ISO 4217](http://www.iso.org/iso/home/standards/currency_codes.htm). - type: string - pattern: "^[A-Z]{3}$" - - name: payoutMethod - in: query - required: false - description: Payout method - type: string - enum: - - BankAccount - - InternationalBankAccount - - Wallet - responses: - "200": - description: Payout schedule identifiers - schema: - type: array - items: - type: integer - format: int32 - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@payment-institutions@{paymentInstitutionID}@terms@payouts@methods.yaml b/spec/paths/processing@payment-institutions@{paymentInstitutionID}@terms@payouts@methods.yaml deleted file mode 100644 index 83b28f4..0000000 --- a/spec/paths/processing@payment-institutions@{paymentInstitutionID}@terms@payouts@methods.yaml +++ /dev/null @@ -1,35 +0,0 @@ -get: - description: Get payout methods for the payment institution - tags: - - PaymentInstitutions - operationId: getPaymentInstitutionPayoutMethods - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/paymentInstitutionID" - - name: currency - in: query - required: false - description: > - Currency character code according to - [ISO 4217](http://www.iso.org/iso/home/standards/currency_codes.htm). - type: string - pattern: "^[A-Z]{3}$" - responses: - "200": - description: Payout method - schema: - type: array - items: - type: string - enum: - - BankAccount - - InternationalBankAccount - - Wallet - - PaymentInstitutionAccount - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@payment-institutions@{paymentInstitutionID}@terms@payouts@schedules.yaml b/spec/paths/processing@payment-institutions@{paymentInstitutionID}@terms@payouts@schedules.yaml deleted file mode 100644 index 1e577715..0000000 --- a/spec/paths/processing@payment-institutions@{paymentInstitutionID}@terms@payouts@schedules.yaml +++ /dev/null @@ -1,40 +0,0 @@ -get: - description: Get available payout schedules for the payment organization - tags: - - PaymentInstitutions - operationId: getPaymentInstitutionPayoutSchedules - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/paymentInstitutionID" - - name: currency - in: query - required: false - description: > - Currency character code according to - [ISO 4217](http://www.iso.org/iso/home/standards/currency_codes.htm). - type: string - pattern: "^[A-Z]{3}$" - - name: payoutMethod - in: query - required: false - description: Payout method - type: string - enum: - - BankAccount - - InternationalBankAccount - - Wallet - responses: - "200": - description: Payout schedule identifiers - schema: - type: array - items: - type: integer - format: int32 - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@payouts.yaml b/spec/paths/processing@payouts.yaml deleted file mode 100644 index 4fccbda..0000000 --- a/spec/paths/processing@payouts.yaml +++ /dev/null @@ -1,44 +0,0 @@ -post: - description: > - Create a new payout and send it to pre-moderation. - operationId: createPayout - tags: - - Payouts - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - name: payoutParams - in: body - required: true - schema: - $ref: "#/definitions/PayoutParams" - responses: - "201": - description: Payout created - schema: - $ref: "#/definitions/Payout" - "401": - $ref: "#/responses/Unauthorized" - "400": - description: Invalid data - schema: - type: object - required: - - code - - message - properties: - code: - description: > - [Error code](#tag/Error-Codes) - type: string - enum: - - invalidPartyID - - invalidPayoutTool - - invalidCash - - invalidRequest - - invalidDeadline - - ambiguousPartyID - message: - description: Human-readable description of the error - type: string - example: invalid payout id diff --git a/spec/paths/processing@payouts@{payoutID}.yaml b/spec/paths/processing@payouts@{payoutID}.yaml deleted file mode 100644 index 25cc637..0000000 --- a/spec/paths/processing@payouts@{payoutID}.yaml +++ /dev/null @@ -1,20 +0,0 @@ -get: - description: Get payout data - tags: - - Payouts - operationId: getPayout - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - $ref: "#/parameters/payoutID" - responses: - "200": - description: Payout found - schema: - $ref: "#/definitions/Payout" - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/paths/processing@schedules@{scheduleID}.yaml b/spec/paths/processing@schedules@{scheduleID}.yaml deleted file mode 100644 index 266c2cd..0000000 --- a/spec/paths/processing@schedules@{scheduleID}.yaml +++ /dev/null @@ -1,25 +0,0 @@ -get: - description: Get payout schedule data by identifier - tags: - - Payouts - operationId: getScheduleByRef - parameters: - - $ref: "#/parameters/requestID" - - $ref: "#/parameters/deadline" - - name: scheduleID - in: path - description: Schedule reference - required: true - type: integer - format: int32 - responses: - "200": - description: Schedule found - schema: - $ref: "#/definitions/Schedule" - "404": - $ref: "#/responses/NotFound" - "401": - $ref: "#/responses/Unauthorized" - "400": - $ref: "#/responses/DefaultLogicError" diff --git a/spec/swagger.yaml b/spec/swagger.yaml index 497155e..ca31308 100644 --- a/spec/swagger.yaml +++ b/spec/swagger.yaml @@ -207,22 +207,6 @@ parameters: type: string maxLength: 40 minLength: 1 - payoutToolID: - name: payoutToolID - in: path - description: Payout tool ID - required: true - type: string - maxLength: 40 - minLength: 1 - payoutID: - name: payoutID - in: path - description: Withdrawal ID - required: true - type: string - maxLength: 40 - minLength: 1 invoiceID: name: invoiceID in: path @@ -573,13 +557,6 @@ tags: Any changes of the shops require system verification by creating change requests. - - name: Payouts - x-displayName: Payouts - description: > - You have to specify payout data within the contract with the system to - receive automatic payouts of all accepted ones to your bank account. The - system will then initiate bank transfers based on the payment amounts - accepted for all active shops. Any data changes require system verification by creating change requests. - name: Webhooks