remote-pay-cloud
Advanced tools
Comparing version 3.1.0 to 3.2.1-5
@@ -24,2 +24,4 @@ "use strict"; | ||
MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.CAPTURE_PREAUTH] = remote_pay_cloud_api_1.remotemessage.CapturePreAuthMessage; | ||
MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.INCREMENT_PREAUTH_RESPONSE] = remote_pay_cloud_api_1.remotemessage.IncrementPreAuthResponseMessage; | ||
MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.INCREMENT_PREAUTH_REQUEST] = remote_pay_cloud_api_1.remotemessage.IncrementPreAuthMessage; | ||
MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.CONFIRM_PAYMENT_MESSAGE] = remote_pay_cloud_api_1.remotemessage.ConfirmPaymentMessage; | ||
@@ -103,2 +105,5 @@ MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.LAST_MSG_REQUEST] = remote_pay_cloud_api_1.remotemessage.LastMessageRequestMessage; | ||
MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.SHOW_RECEIPT_OPTIONS_RESPONSE] = remote_pay_cloud_api_1.remotemessage.ShowReceiptOptionsResponseMessage; | ||
MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.BALANCE_INQUIRY_RESPONSE] = remote_pay_cloud_api_1.remotemessage.BalanceInquiryResponseMessage; | ||
MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.REQUEST_SIGNATURE_RESPONSE] = remote_pay_cloud_api_1.remotemessage.SignatureResponseMessage; | ||
MethodToMessage.methodToType[remote_pay_cloud_api_1.remotemessage.Method.REQUEST_TIP_RESPONSE] = remote_pay_cloud_api_1.remotemessage.RequestTipResponseMessage; | ||
}; | ||
@@ -105,0 +110,0 @@ MethodToMessage.methodToType = null; |
@@ -191,3 +191,2 @@ "use strict"; | ||
listener.onDeviceDisconnected(); // changed from onDisconnected in 1.3 | ||
listener.onDisconnected(); // left here for backwards compatibility. Deprecated in 1.3* | ||
} | ||
@@ -205,3 +204,2 @@ catch (e) { | ||
listener.onDeviceReady(merchantInfo); // changed from onReady in 1.3 | ||
listener.onReady(merchantInfo); // left here for backwards compatibility. Deprecated in 1.3* | ||
} | ||
@@ -261,2 +259,14 @@ catch (e) { | ||
}; | ||
CloverConnectorBroadcaster.prototype.notifyOnIncrementPreAuthResponse = function (response) { | ||
var _this = this; | ||
this.logger.debug('Sending IncrementPreAuth notification to listeners'); | ||
this.listeners.forEach(function (listener) { | ||
try { | ||
listener.onIncrementPreAuthResponse(response); | ||
} | ||
catch (e) { | ||
_this.logger.error(e); | ||
} | ||
}); | ||
}; | ||
CloverConnectorBroadcaster.prototype.notifyOnDeviceError = function (errorEvent) { | ||
@@ -499,2 +509,35 @@ var _this = this; | ||
}; | ||
CloverConnectorBroadcaster.prototype.notifyOnSignatureCollected = function (response) { | ||
var _this = this; | ||
this.listeners.forEach(function (listener) { | ||
try { | ||
listener.onRequestSignatureResponse(response); | ||
} | ||
catch (e) { | ||
_this.logger.error(e); | ||
} | ||
}); | ||
}; | ||
CloverConnectorBroadcaster.prototype.notifyOnCheckBalanceResponse = function (response) { | ||
var _this = this; | ||
this.listeners.forEach(function (listener) { | ||
try { | ||
listener.onCheckBalanceResponse(response); | ||
} | ||
catch (e) { | ||
_this.logger.error(e); | ||
} | ||
}); | ||
}; | ||
CloverConnectorBroadcaster.prototype.notifyOnTipResponse = function (response) { | ||
var _this = this; | ||
this.listeners.forEach(function (listener) { | ||
try { | ||
listener.onRequestTipResponse(response); | ||
} | ||
catch (e) { | ||
_this.logger.error(e); | ||
} | ||
}); | ||
}; | ||
return CloverConnectorBroadcaster; | ||
@@ -501,0 +544,0 @@ }()); |
@@ -54,10 +54,6 @@ "use strict"; | ||
variables[Endpoints.WEBSOCKET_FORCE_CONNECT_KEY] = forceConnect; | ||
variables[Endpoints.WEBSOCKET_MERCHANT_ID_KEY] = merchantId; | ||
variables[Endpoints.WEBSOCKET_ACCESS_TOKEN_KEY] = accessToken; | ||
var deviceWebSocketEndpointPath = Endpoints.DOMAIN_PATH + Endpoints.WEBSOCKET_PATH + | ||
Endpoints.WEBSOCKET_TOKEN_SUFFIX + | ||
Endpoints.WEBSOCKET_FRIENDLY_ID_SUFFIX + | ||
Endpoints.WEBSOCKET_FORCE_CONNECT_SUFFIX + | ||
Endpoints.WEBSOCKET_MERCHANT_ID_SUFFIX + | ||
Endpoints.WEBSOCKET_ACCESS_TOKEN_SUFFIX; | ||
Endpoints.WEBSOCKET_FORCE_CONNECT_SUFFIX; | ||
if (notificationResponse.serverIdentifier) { | ||
@@ -201,6 +197,2 @@ deviceWebSocketEndpointPath += "&" + Endpoints.CLOUD_SERVER_IDENTIFIER_KEY + "=" + notificationResponse.serverIdentifier; | ||
Endpoints.WEBSOCKET_FORCE_CONNECT_SUFFIX = "&forceConnect={" + Endpoints.WEBSOCKET_FORCE_CONNECT_KEY + "}"; | ||
Endpoints.WEBSOCKET_MERCHANT_ID_KEY = "mid"; | ||
Endpoints.WEBSOCKET_MERCHANT_ID_SUFFIX = "&wsMid={" + Endpoints.WEBSOCKET_MERCHANT_ID_KEY + "}"; | ||
Endpoints.WEBSOCKET_ACCESS_TOKEN_KEY = "accessToken"; | ||
Endpoints.WEBSOCKET_ACCESS_TOKEN_SUFFIX = "&wsAccessToken={" + Endpoints.WEBSOCKET_ACCESS_TOKEN_KEY + "}"; | ||
Endpoints.OAUTH_PATH = "oauth/authorize?response_type=token"; | ||
@@ -207,0 +199,0 @@ Endpoints.OAUTH_CLIENT_ID_KEY = "client_id"; |
@@ -12,3 +12,3 @@ "use strict"; | ||
*/ | ||
Version.CLOVER_CLOUD_SDK_VERSION = "3.1.0"; | ||
Version.CLOVER_CLOUD_SDK_VERSION = "4.0.0"; | ||
/** | ||
@@ -15,0 +15,0 @@ * @type {string} - The current SDK name. |
@@ -60,2 +60,3 @@ import * as sdk from 'remote-pay-cloud-api'; | ||
capturePreAuth(request: sdk.remotepay.CapturePreAuthRequest): void; | ||
incrementPreAuth(request: sdk.remotepay.IncrementPreAuthRequest): void; | ||
tipAdjustAuth(request: sdk.remotepay.TipAdjustAuthRequest): void; | ||
@@ -98,2 +99,5 @@ vaultCard(cardEntryMethods: number): void; | ||
startCustomActivity(request: sdk.remotepay.CustomActivityRequest): void; | ||
checkBalance(request: sdk.remotepay.CheckBalanceRequest): void; | ||
requestSignature(request: sdk.remotepay.SignatureRequest): void; | ||
requestTip(request: sdk.remotepay.TipRequest): void; | ||
static populateBaseResponse(response: sdk.remotepay.BaseResponse, success: boolean, responseCode: sdk.remotepay.ResponseCode, reason?: string, message?: string): void; | ||
@@ -149,2 +153,4 @@ static populatePaymentResponse(response: sdk.remotepay.PaymentResponse, success: boolean, responseCode: sdk.remotepay.ResponseCode, payment: sdk.payments.Payment, signature?: sdk.base.Signature, reason?: string, message?: string): void; | ||
onCapturePreAuth(capturePreAuthResponseMessage: sdk.remotemessage.CapturePreAuthResponseMessage): void; | ||
onIncrementPreAuthError(result: sdk.remotepay.ResponseCode, reason: string, message: string): void; | ||
onIncrementPreAuthResponse(responseMsg: sdk.remotemessage.IncrementPreAuthResponseMessage): void; | ||
onCloseoutResponse(status: sdk.remotemessage.ResultStatus, reason: string, batch: sdk.payments.Batch): void; | ||
@@ -175,13 +181,6 @@ onDeviceDisconnected(device: CloverDevice, message?: string): void; | ||
onDisplayReceiptOptionsResponse(status: sdk.remotemessage.ResultStatus, reason: string): void; | ||
onSignatureCollected(signatureResponseMessage: sdk.remotemessage.SignatureResponseMessage): void; | ||
onBalanceInquiryResponse(balanceInquiryResponseMessage: sdk.remotemessage.BalanceInquiryResponseMessage): void; | ||
onRequestTipResponse(requestTipResponseMessage: sdk.remotemessage.RequestTipResponseMessage): void; | ||
} | ||
namespace InnerDeviceObserver { | ||
class SVR extends sdk.remotepay.VerifySignatureRequest { | ||
cloverDevice: CloverDevice; | ||
constructor(device: CloverDevice); | ||
accept(): void; | ||
reject(): void; | ||
setSignature(signature: sdk.base.Signature): void; | ||
setPayment(payment: sdk.payments.Payment): void; | ||
} | ||
} | ||
} |
@@ -32,2 +32,3 @@ import * as sdk from 'remote-pay-cloud-api'; | ||
notifyOnCapturePreAuth(response: sdk.remotepay.CapturePreAuthResponse): void; | ||
notifyOnIncrementPreAuthResponse(response: sdk.remotepay.IncrementPreAuthResponse): void; | ||
notifyOnDeviceError(errorEvent: sdk.remotepay.CloverDeviceErrorEvent): void; | ||
@@ -53,2 +54,5 @@ notifyOnPrintRefundPaymentReceipt(printRefundPaymentReceiptResponse: sdk.remotepay.PrintRefundPaymentReceiptResponse): void; | ||
notifyOnInvalidStateTransitionResponse(response: sdk.remotepay.InvalidStateTransitionResponse): void; | ||
notifyOnSignatureCollected(response: sdk.remotepay.SignatureResponse): void; | ||
notifyOnCheckBalanceResponse(response: sdk.remotepay.CheckBalanceResponse): void; | ||
notifyOnTipResponse(response: sdk.remotepay.TipResponse): void; | ||
} |
@@ -132,2 +132,3 @@ import * as sdk from 'remote-pay-cloud-api'; | ||
onCapturePreAuth(capturePreAuthResponseMessage: sdk.remotemessage.CapturePreAuthResponseMessage): void; | ||
onIncrementPreAuthResponse(incrementPreAuthResponseMessage: sdk.remotemessage.IncrementPreAuthResponseMessage): void; | ||
/** | ||
@@ -300,2 +301,5 @@ * Closeout Response | ||
onDisplayReceiptOptionsResponse(result: sdk.remotemessage.ResultStatus, reason: string): any; | ||
onSignatureCollected(msg: sdk.remotemessage.SignatureResponseMessage): any; | ||
onBalanceInquiryResponse(msg: sdk.remotemessage.BalanceInquiryResponseMessage): any; | ||
onRequestTipResponse(msg: sdk.remotemessage.RequestTipResponseMessage): any; | ||
} |
@@ -59,2 +59,5 @@ import * as sdk from 'remote-pay-cloud-api'; | ||
* @param {sdk.order.VoidReason} reason | ||
* @param {boolean} disablePrinting | ||
* @param {boolean} disableReceiptSelection | ||
* @param {object} extras | ||
*/ | ||
@@ -80,2 +83,10 @@ abstract doVoidPayment(payment: sdk.payments.Payment, reason: sdk.order.VoidReason, disablePrinting: boolean, disableReceiptSelection: boolean, extras: object): void; | ||
/** | ||
* Capture Auth | ||
* | ||
* @param {string} paymentId | ||
* @param {number} amount | ||
* @param {number} amount | ||
*/ | ||
abstract doIncrementPreAuth(paymentId: string, amount: number): void; | ||
/** | ||
* Order Update | ||
@@ -109,2 +120,3 @@ * | ||
* @param {boolean} disableReceiptSelection | ||
* @param {object} extras | ||
*/ | ||
@@ -130,2 +142,4 @@ abstract doPaymentRefund(orderId: string, paymentId: string, amount: number, fullRefund: boolean, disablePrinting?: boolean, disableReceiptSelection?: boolean, extras?: object): void; | ||
* @param {Array<string>} textLines | ||
* @param {string} printRequestId - an optional id that will be used for the printjob. This id will be used in notification calls about the status of the job. | ||
* @param {string} printDeviceId - the printer id to use when printing. If left unset the default is used | ||
*/ | ||
@@ -156,2 +170,3 @@ abstract doPrintText(textLines: Array<string>, printRequestId?: string, printDeviceId?: string): void; | ||
* @param {string} reason | ||
* @param {string} deviceId (optional) | ||
*/ | ||
@@ -163,2 +178,4 @@ abstract doOpenCashDrawer(reason: string, deviceId?: string): void; | ||
* @param {any} bitmap | ||
* @param printRequestId | ||
* @param printDeviceId | ||
*/ | ||
@@ -170,2 +187,4 @@ abstract doPrintImageObject(bitmap: any, printRequestId?: string, printDeviceId?: string): void; | ||
* @param {string} url | ||
* @param printRequestId | ||
* @param printDeviceId | ||
*/ | ||
@@ -268,2 +287,5 @@ abstract doPrintImageUrl(url: string, printRequestId?: string, printDeviceId?: string): void; | ||
getSupportsVoidPaymentResponse(): boolean; | ||
abstract doCheckBalance(cardEntryMethods: number): void; | ||
abstract doCollectSignature(acknowledgementMessage: string): void; | ||
abstract doRequestTip(tippableAmount: number, suggestions: Array<sdk.merchant.TipSuggestion>): void; | ||
} |
@@ -89,3 +89,4 @@ import * as sdk from 'remote-pay-cloud-api'; | ||
/** | ||
* @param transport | ||
* @param transport - the way to notify is defined by the transport | ||
* @param message - the optional message to send | ||
* @deprecated - see onDisconnected. | ||
@@ -189,2 +190,3 @@ */ | ||
notifyObserversCapturePreAuth(capturePreAuthResponseMessage: sdk.remotemessage.CapturePreAuthResponseMessage): void; | ||
notifyObserversIncrementPreAuth(incrementPreAuthResponseMessage: sdk.remotemessage.IncrementPreAuthResponseMessage): void; | ||
notifyObserversCloseout(closeoutResponseMessage: sdk.remotemessage.CloseoutResponseMessage): void; | ||
@@ -195,2 +197,5 @@ notifyObserversPendingPaymentsResponse(retrievePendingPaymentsResponseMessage: sdk.remotemessage.RetrievePendingPaymentsResponseMessage): void; | ||
notifyObserversFinishOk(finishOkMessage: sdk.remotemessage.FinishOkMessage): void; | ||
notifyObserverDisplayCollectedSignature(msg: sdk.remotemessage.SignatureResponseMessage): void; | ||
notifyObserverBalanceInquiryResponse(msg: sdk.remotemessage.BalanceInquiryResponseMessage): void; | ||
notifyObserverTipResponse(msg: sdk.remotemessage.RequestTipResponseMessage): void; | ||
notifyObserversInvalidStateTransitionResponse(invalidStateTransitionMessage: sdk.remotemessage.InvalidStateTransitionMessage): void; | ||
@@ -290,2 +295,4 @@ notifyObserverDisplayReceiptOptionsResponse(showReceiptOptionsResponseMessage: sdk.remotemessage.ShowReceiptOptionsResponseMessage): void; | ||
* @param {Array<string>} textLines | ||
* @param printRequestId - an optional id that will be used for the printjob. This id will be used in notification calls about the status of the job. | ||
* @param printDeviceId - the printer id to use when printing. If left unset the default is used | ||
*/ | ||
@@ -320,3 +327,3 @@ doPrintText(textLines: Array<string>, printRequestId?: string, printDeviceId?: string): void; | ||
* @param {sdk.payments.Payment} payment | ||
* @param {sdk.order.VoidReason} reason | ||
* @param {sdk.order.VoidReason} voidReason | ||
* @param {boolean} disablePrinting | ||
@@ -368,2 +375,10 @@ * @param {boolean} disableReceiptSelection | ||
/** | ||
* Capture Auth | ||
* | ||
* @param {string} paymentId | ||
* @param {number} amount | ||
* @param {number} amount | ||
*/ | ||
doIncrementPreAuth(paymentId: string, amount: number): void; | ||
/** | ||
* Accept Payment | ||
@@ -405,2 +420,5 @@ * | ||
doSetCustomerInfo(customerInfo: sdk.remotepay.CustomerInfo): void; | ||
doCheckBalance(cardEntryMethods: number): void; | ||
doCollectSignature(acknowledge: string): void; | ||
doRequestTip(tippableAmount: number, suggestions: Array<sdk.merchant.TipSuggestion>): void; | ||
/** | ||
@@ -407,0 +425,0 @@ * Dispose |
@@ -41,6 +41,2 @@ /** | ||
static WEBSOCKET_FORCE_CONNECT_SUFFIX: string; | ||
static WEBSOCKET_MERCHANT_ID_KEY: string; | ||
static WEBSOCKET_MERCHANT_ID_SUFFIX: string; | ||
static WEBSOCKET_ACCESS_TOKEN_KEY: string; | ||
static WEBSOCKET_ACCESS_TOKEN_SUFFIX: string; | ||
static OAUTH_PATH: string; | ||
@@ -47,0 +43,0 @@ static OAUTH_CLIENT_ID_KEY: string; |
{ | ||
"name": "remote-pay-cloud", | ||
"version": "3.1.0", | ||
"version": "3.2.1-5", | ||
"description": "Access Clover devices through the cloud.", | ||
@@ -35,3 +35,3 @@ "keywords": [ | ||
"eventemitter3": "3.1.0", | ||
"remote-pay-cloud-api": "3.1.0" | ||
"remote-pay-cloud-api": "4.0.0" | ||
}, | ||
@@ -47,3 +47,3 @@ "devDependencies": { | ||
"jsdoc": "3.4.3", | ||
"merge2": "^1.2.3", | ||
"merge2": "^1.3.0", | ||
"mocha": "4.0.1", | ||
@@ -50,0 +50,0 @@ "path": "0.12.7", |
@@ -12,3 +12,3 @@ ![Clover logo](https://www.clover.com/assets/images/public-site/press/clover_primary_gray_rgb.png) | ||
Current version: 3.1.0 | ||
Current version: 4.0.0 | ||
@@ -43,7 +43,7 @@ ## Platforms supported | ||
### Additional resources | ||
- [Online Docs](http://clover.github.io/remote-pay-cloud/1.4.3/) | ||
- [Online Docs](http://clover.github.io/remote-pay-cloud/3.2.0/) | ||
- [Release Notes](https://github.com/clover/remote-pay-cloud/releases) | ||
- [Secure Network Pay Display](https://docs.clover.com/clover-platform/docs/pay-display-apps#section--secure-network-pay-display-) | ||
- [Tutorial for the Cloud SDK](https://docs.clover.com/clover-platform/docs/cloud-sdk-v3) | ||
- [API Class Documentation](http://clover.github.io/remote-pay-cloud-api/1.4.2/) | ||
- [API Class Documentation](http://clover.github.io/remote-pay-cloud-api/3.2.0/) | ||
- [Clover Developer Community](https://community.clover.com/index.html) | ||
@@ -50,0 +50,0 @@ |
@@ -25,2 +25,4 @@ import {remotemessage} from 'remote-pay-cloud-api'; | ||
MethodToMessage.methodToType[remotemessage.Method.CAPTURE_PREAUTH] = remotemessage.CapturePreAuthMessage; | ||
MethodToMessage.methodToType[remotemessage.Method.INCREMENT_PREAUTH_RESPONSE] = remotemessage.IncrementPreAuthResponseMessage; | ||
MethodToMessage.methodToType[remotemessage.Method.INCREMENT_PREAUTH_REQUEST] = remotemessage.IncrementPreAuthMessage; | ||
MethodToMessage.methodToType[remotemessage.Method.CONFIRM_PAYMENT_MESSAGE] = remotemessage.ConfirmPaymentMessage; | ||
@@ -104,3 +106,6 @@ MethodToMessage.methodToType[remotemessage.Method.LAST_MSG_REQUEST] = remotemessage.LastMessageRequestMessage; | ||
MethodToMessage.methodToType[remotemessage.Method.SHOW_RECEIPT_OPTIONS_RESPONSE] = remotemessage.ShowReceiptOptionsResponseMessage; | ||
MethodToMessage.methodToType[remotemessage.Method.BALANCE_INQUIRY_RESPONSE] = remotemessage.BalanceInquiryResponseMessage; | ||
MethodToMessage.methodToType[remotemessage.Method.REQUEST_SIGNATURE_RESPONSE] = remotemessage.SignatureResponseMessage; | ||
MethodToMessage.methodToType[remotemessage.Method.REQUEST_TIP_RESPONSE] = remotemessage.RequestTipResponseMessage; | ||
} | ||
} |
@@ -181,3 +181,2 @@ import * as sdk from 'remote-pay-cloud-api'; | ||
listener.onDeviceDisconnected(); // changed from onDisconnected in 1.3 | ||
listener.onDisconnected(); // left here for backwards compatibility. Deprecated in 1.3* | ||
} catch (e) { | ||
@@ -194,3 +193,2 @@ this.logger.error(e); | ||
listener.onDeviceReady(merchantInfo); // changed from onReady in 1.3 | ||
listener.onReady(merchantInfo); // left here for backwards compatibility. Deprecated in 1.3* | ||
} catch (e) { | ||
@@ -246,2 +244,13 @@ this.logger.error(e); | ||
public notifyOnIncrementPreAuthResponse(response: sdk.remotepay.IncrementPreAuthResponse): void { | ||
this.logger.debug('Sending IncrementPreAuth notification to listeners'); | ||
this.listeners.forEach((listener: sdk.remotepay.ICloverConnectorListener) => { | ||
try { | ||
listener.onIncrementPreAuthResponse(response); | ||
} catch (e) { | ||
this.logger.error(e); | ||
} | ||
}); | ||
} | ||
public notifyOnDeviceError(errorEvent: sdk.remotepay.CloverDeviceErrorEvent): void { | ||
@@ -465,2 +474,32 @@ this.logger.debug('Sending DeviceError notification to listeners'); | ||
public notifyOnSignatureCollected(response: sdk.remotepay.SignatureResponse): void { | ||
this.listeners.forEach((listener: sdk.remotepay.ICloverConnectorListener) => { | ||
try { | ||
listener.onRequestSignatureResponse(response); | ||
} catch (e) { | ||
this.logger.error(e); | ||
} | ||
}); | ||
} | ||
public notifyOnCheckBalanceResponse(response: sdk.remotepay.CheckBalanceResponse): void { | ||
this.listeners.forEach((listener: sdk.remotepay.ICloverConnectorListener) => { | ||
try { | ||
listener.onCheckBalanceResponse(response); | ||
} catch (e) { | ||
this.logger.error(e); | ||
} | ||
}); | ||
} | ||
public notifyOnTipResponse(response: sdk.remotepay.TipResponse): void { | ||
this.listeners.forEach((listener: sdk.remotepay.ICloverConnectorListener) => { | ||
try { | ||
listener.onRequestTipResponse(response); | ||
} catch (e) { | ||
this.logger.error(e); | ||
} | ||
}); | ||
} | ||
} |
@@ -152,2 +152,4 @@ import * as sdk from 'remote-pay-cloud-api'; | ||
onIncrementPreAuthResponse(incrementPreAuthResponseMessage: sdk.remotemessage.IncrementPreAuthResponseMessage): void; | ||
/** | ||
@@ -345,2 +347,7 @@ * Closeout Response | ||
onSignatureCollected(msg: sdk.remotemessage.SignatureResponseMessage); | ||
onBalanceInquiryResponse(msg: sdk.remotemessage.BalanceInquiryResponseMessage); | ||
onRequestTipResponse(msg: sdk.remotemessage.RequestTipResponseMessage); | ||
} |
@@ -80,2 +80,5 @@ import * as sdk from 'remote-pay-cloud-api'; | ||
* @param {sdk.order.VoidReason} reason | ||
* @param {boolean} disablePrinting | ||
* @param {boolean} disableReceiptSelection | ||
* @param {object} extras | ||
*/ | ||
@@ -104,2 +107,11 @@ public abstract doVoidPayment(payment: sdk.payments.Payment, reason: sdk.order.VoidReason, disablePrinting: boolean, disableReceiptSelection: boolean, extras: object): void; | ||
/** | ||
* Capture Auth | ||
* | ||
* @param {string} paymentId | ||
* @param {number} amount | ||
* @param {number} amount | ||
*/ | ||
public abstract doIncrementPreAuth(paymentId: string, amount: number): void; | ||
/** | ||
* Order Update | ||
@@ -136,2 +148,3 @@ * | ||
* @param {boolean} disableReceiptSelection | ||
* @param {object} extras | ||
*/ | ||
@@ -160,2 +173,4 @@ public abstract doPaymentRefund(orderId: string, paymentId: string, amount: number, fullRefund: boolean, disablePrinting?: boolean, disableReceiptSelection?: boolean, extras?: object): void; | ||
* @param {Array<string>} textLines | ||
* @param {string} printRequestId - an optional id that will be used for the printjob. This id will be used in notification calls about the status of the job. | ||
* @param {string} printDeviceId - the printer id to use when printing. If left unset the default is used | ||
*/ | ||
@@ -192,2 +207,3 @@ public abstract doPrintText(textLines: Array<string>, printRequestId?: string, printDeviceId?: string): void; | ||
* @param {string} reason | ||
* @param {string} deviceId (optional) | ||
*/ | ||
@@ -200,2 +216,4 @@ public abstract doOpenCashDrawer(reason: string, deviceId?: string): void; | ||
* @param {any} bitmap | ||
* @param printRequestId | ||
* @param printDeviceId | ||
*/ | ||
@@ -208,2 +226,4 @@ public abstract doPrintImageObject(bitmap: any, printRequestId?: string, printDeviceId?: string): void; | ||
* @param {string} url | ||
* @param printRequestId | ||
* @param printDeviceId | ||
*/ | ||
@@ -334,2 +354,8 @@ public abstract doPrintImageUrl(url: string, printRequestId?: string, printDeviceId?: string): void; | ||
} | ||
public abstract doCheckBalance(cardEntryMethods: number): void; | ||
public abstract doCollectSignature(acknowledgementMessage: string): void; | ||
public abstract doRequestTip(tippableAmount: number, suggestions: Array<sdk.merchant.TipSuggestion>): void; | ||
} |
@@ -52,6 +52,2 @@ /** | ||
static WEBSOCKET_FORCE_CONNECT_SUFFIX = "&forceConnect={" + Endpoints.WEBSOCKET_FORCE_CONNECT_KEY + "}"; | ||
static WEBSOCKET_MERCHANT_ID_KEY: string = "mid"; | ||
static WEBSOCKET_MERCHANT_ID_SUFFIX = "&wsMid={" + Endpoints.WEBSOCKET_MERCHANT_ID_KEY + "}"; | ||
static WEBSOCKET_ACCESS_TOKEN_KEY: string = "accessToken"; | ||
static WEBSOCKET_ACCESS_TOKEN_SUFFIX = "&wsAccessToken={" + Endpoints.WEBSOCKET_ACCESS_TOKEN_KEY + "}"; | ||
@@ -111,4 +107,2 @@ static OAUTH_PATH: string = "oauth/authorize?response_type=token"; | ||
variables[Endpoints.WEBSOCKET_FORCE_CONNECT_KEY] = forceConnect; | ||
variables[Endpoints.WEBSOCKET_MERCHANT_ID_KEY] = merchantId; | ||
variables[Endpoints.WEBSOCKET_ACCESS_TOKEN_KEY] = accessToken; | ||
@@ -118,5 +112,3 @@ let deviceWebSocketEndpointPath: string = Endpoints.DOMAIN_PATH + Endpoints.WEBSOCKET_PATH + | ||
Endpoints.WEBSOCKET_FRIENDLY_ID_SUFFIX + | ||
Endpoints.WEBSOCKET_FORCE_CONNECT_SUFFIX + | ||
Endpoints.WEBSOCKET_MERCHANT_ID_SUFFIX + | ||
Endpoints.WEBSOCKET_ACCESS_TOKEN_SUFFIX; | ||
Endpoints.WEBSOCKET_FORCE_CONNECT_SUFFIX | ||
@@ -123,0 +115,0 @@ if (notificationResponse.serverIdentifier) { |
@@ -9,3 +9,3 @@ /** | ||
*/ | ||
public static CLOVER_CLOUD_SDK_VERSION = "3.1.0"; | ||
public static CLOVER_CLOUD_SDK_VERSION = "4.0.0"; | ||
@@ -12,0 +12,0 @@ /** |
@@ -11,4 +11,4 @@ export {Logger} from "../src/com/clover/remote/client/util/Logger"; | ||
export {WebSocketCloverDeviceConfiguration} from "../src/com/clover/remote/client/device/WebSocketCloverDeviceConfiguration"; | ||
export {WebSocketPairedCloverDeviceConfiguration} from "../src/com/clover/remote/client/device/WebSocketPairedCloverDeviceConfiguration"; | ||
export {WebSocketCloudCloverDeviceConfiguration} from "../src/com/clover/remote/client/device/WebSocketCloudCloverDeviceConfiguration"; | ||
export {WebSocketPairedCloverDeviceConfiguration, WebSocketPairedCloverDeviceConfigurationBuilder} from "../src/com/clover/remote/client/device/WebSocketPairedCloverDeviceConfiguration"; | ||
export {WebSocketCloudCloverDeviceConfiguration, WebSocketCloudCloverDeviceConfigurationBuilder} from "../src/com/clover/remote/client/device/WebSocketCloudCloverDeviceConfiguration"; | ||
@@ -33,3 +33,3 @@ export {CloverTransport} from "../src/com/clover/remote/client/transport/CloverTransport"; | ||
guid(): string; | ||
} | ||
}; | ||
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5702734
87149
233
3
+ Addedremote-pay-cloud-api@4.0.0(transitive)
- Removedremote-pay-cloud-api@3.1.0(transitive)
Updatedremote-pay-cloud-api@4.0.0