cybersource-rest-client 0.0.52 → 0.0.53

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 (29) hide show
  1. package/README.md +49 -20
  2. package/docs/CheckPayerAuthEnrollmentRequest.md +1 -1
  3. package/docs/CreateBundledDecisionManagerCaseRequest.md +1 -1
  4. package/docs/InvoicingV2InvoicesAllGet404Response.md +1 -1
  5. package/docs/PostPaymentCredentialsRequest.md +8 -0
  6. package/docs/PtsV2PaymentsCapturesPost201Response.md +1 -1
  7. package/docs/PtsV2PaymentsCapturesPost201ResponseProcessorInformation.md +1 -0
  8. package/docs/PtsV2PaymentsPost201ResponseEmbeddedActionsCAPTURE.md +1 -1
  9. package/docs/Ptsv2paymentsAcquirerInformation.md +1 -0
  10. package/docs/Riskv1authenticationresultsOrderInformation.md +0 -1
  11. package/docs/Riskv1decisionsAcquirerInformation.md +11 -0
  12. package/docs/Tmsv2customersEmbeddedDefaultPaymentInstrumentEmbeddedInstrumentIdentifierTokenizedCard.md +3 -1
  13. package/docs/TokenApi.md +5 -2
  14. package/package.json +10 -10
  15. package/src/api/TokenApi.js +16 -9
  16. package/src/index.js +13 -8
  17. package/src/model/CheckPayerAuthEnrollmentRequest.js +6 -6
  18. package/src/model/CreateBundledDecisionManagerCaseRequest.js +6 -6
  19. package/src/model/InvoicingV2InvoicesAllGet404Response.js +1 -1
  20. package/src/model/PostPaymentCredentialsRequest.js +82 -0
  21. package/src/model/PtsV2PaymentsCapturesPost201Response.js +1 -1
  22. package/src/model/PtsV2PaymentsCapturesPost201ResponseProcessorInformation.js +9 -0
  23. package/src/model/PtsV2PaymentsPost201ResponseEmbeddedActionsCAPTURE.js +1 -1
  24. package/src/model/Ptsv2paymentsAcquirerInformation.js +9 -0
  25. package/src/model/Riskv1authenticationresultsOrderInformation.js +4 -12
  26. package/src/model/Riskv1decisionsAcquirerInformation.js +109 -0
  27. package/src/model/Tmsv2customersEmbeddedDefaultPaymentInstrumentEmbeddedInstrumentIdentifierTokenizedCard.js +19 -1
  28. package/docs/Riskv1authenticationresultsOrderInformationLineItems.md +0 -10
  29. package/src/model/Riskv1authenticationresultsOrderInformationLineItems.js +0 -101
package/README.md CHANGED
@@ -1,11 +1,13 @@
1
+
1
2
  # Node.JS Client SDK for the CyberSource REST API
2
3
 
4
+ ## Description
5
+
3
6
  The CyberSource Node client provides convenient access to the [CyberSource REST API](https://developer.cybersource.com/api/reference/api-reference.html) from your Node application.
4
7
 
5
- ## Requirements
8
+ ## System Requirements
6
9
 
7
- * Node.js version 14.21.3 or higher
8
- * A CyberSource account (see _Registration & Configuration_ section below)
10
+ * Node.js version 14.21.3 or higher.
9
11
 
10
12
  ## Installation
11
13
 
@@ -13,13 +15,17 @@ The CyberSource Node client provides convenient access to the [CyberSource REST
13
15
  npm install cybersource-rest-client
14
16
  ```
15
17
 
16
- ## Registration & Configuration
18
+ ## Account Registration and Configuration
19
+
20
+ * Account Registration
21
+
22
+ Follow the first step mentioned in [Getting Started with CyberSource REST SDKs](https://developer.cybersource.com/hello-world/rest-api-sdks.html#gettingstarted) to create a sandbox account.
17
23
 
18
- Use of this SDK and the CyberSource APIs requires having an account on our system. You can find details of getting a test account and creating your keys [here](https://developer.cybersource.com/api/developer-guides/dita-gettingstarted/registration.html)
24
+ * Configuration
19
25
 
20
- Remember this SDK is for use in server-side Node applications that access the CyberSource REST API and credentials should always be securely stored and accessed appropriately.
26
+ Follow the second step mentioned in [Getting Started with CyberSource REST SDKs](https://developer.cybersource.com/hello-world/rest-api-sdks.html#gettingstarted) to configure the SDK by inputting your credentials.
21
27
 
22
- ## SDK Usage Examples and Sample Code
28
+ ## How to Use
23
29
 
24
30
  To get started using this SDK, it's highly recommended to download our sample code repository:
25
31
 
@@ -33,19 +39,18 @@ Additionally, you can find details and examples of how our API is structured in
33
39
 
34
40
  The API Reference Guide provides examples of what information is needed for a particular request and how that information would be formatted. Using those examples, you can easily determine what methods would be necessary to include that information in a request using this SDK.
35
41
 
36
- ## MetaKey Support
37
-
38
- A Meta Key is a single key that can be used by one, some, or all merchants (or accounts, if created by a Portfolio user) in the portfolio.
39
-
40
- The Portfolio or Parent Account owns the key and is considered the transaction submitter when a Meta Key is used, while the merchant owns the transaction.
42
+ ### Example using Sample Code Application
41
43
 
42
- MIDs continue to be able to create keys for themselves, even if a Meta Key is generated.
44
+ * Add the [CyberSource REST client as a dependency](https://github.com/CyberSource/cybersource-rest-samples-node/blob/2dceb63f2fc5eb01150d1c7a9d935b291f52012f/package.json#L16C5-L16C41) in your Node.JS project.
45
+ * Configure your credentials in a [Config Object](https://github.com/CyberSource/cybersource-rest-samples-node/blob/2dceb63f2fc5eb01150d1c7a9d935b291f52012f/Data/Configuration.js#L40C1-L70C2).
46
+ * Create an instance of [ApiClient](https://github.com/CyberSource/cybersource-rest-samples-node/blob/2dceb63f2fc5eb01150d1c7a9d935b291f52012f/Samples/Payments/Payments/simple-authorizationinternet.js#L11).
47
+ * Use the created ApiClient instance to call CyberSource APIs. For example [SimpleAuthorizationInternet](https://github.com/CyberSource/cybersource-rest-samples-node/blob/2dceb63f2fc5eb01150d1c7a9d935b291f52012f/Samples/Payments/Payments/simple-authorizationinternet.js#L56C3-L71C6)
43
48
 
44
- Further information on MetaKey can be found in [New Business Center User Guide](https://developer.cybersource.com/library/documentation/dev_guides/Business_Center/New_Business_Center_User_Guide.pdf).
49
+ For more detailed examples, refer to the [cybersource-rest-samples-node](https://github.com/CyberSource/cybersource-rest-samples-node) repository.
45
50
 
46
- ### Switching between the sandbox environment and the production environment
51
+ ### Switching between Test environment and Production environment
47
52
 
48
- Cybersource maintains a complete sandbox environment for testing and development purposes. This sandbox environment is an exact duplicate of our production environment with the transaction authorization and settlement process simulated. By default, this SDK is configured to communicate with the sandbox environment. To switch to the production environment, set the `runEnvironment` in the SDK Configuration. See our sample at <https://github.com/CyberSource/cybersource-rest-samples-node/blob/master/Data/Configuration.js>.
53
+ CyberSource maintains a complete sandbox environment for testing and development purposes. This sandbox environment is an exact duplicate of our production environment with the transaction authorization and settlement process simulated. By default, this SDK is configured to communicate with the sandbox environment. To switch to the production environment, set the `runEnvironment` in the SDK Configuration. See our sample at <https://github.com/CyberSource/cybersource-rest-samples-node/blob/master/Data/Configuration.js>.
49
54
 
50
55
  ```javascript
51
56
  // For TESTING use
@@ -56,7 +61,7 @@ Cybersource maintains a complete sandbox environment for testing and development
56
61
 
57
62
  API credentials are different for each environment, so be sure to switch to the appropriate credentials when switching environments.
58
63
 
59
- ### Logging
64
+ ## Logging
60
65
 
61
66
  [![Generic badge](https://img.shields.io/badge/LOGGING-NEW-GREEN.svg)](https://shields.io/)
62
67
 
@@ -64,10 +69,34 @@ Since v0.0.35, a new logging framework has been introduced in the SDK. This new
64
69
 
65
70
  More information about this new logging framework can be found in this file : [Logging.md](Logging.md)
66
71
 
67
- ## License
72
+ ## Features
68
73
 
69
- This repository is distributed under a proprietary license. See the provided [`LICENSE.txt`](/LICENSE.txt) file.
74
+ ### MetaKey Support
75
+
76
+ A Meta Key is a single key that can be used by one, some, or all merchants (or accounts, if created by a Portfolio user) in the portfolio.
77
+
78
+ The Portfolio or Parent Account owns the key and is considered the transaction submitter when a Meta Key is used, while the merchant owns the transaction.
79
+
80
+ MIDs continue to be able to create keys for themselves, even if a Meta Key is generated.
81
+
82
+ Further information on MetaKey can be found in [New Business Center User Guide](https://developer.cybersource.com/library/documentation/dev_guides/Business_Center/New_Business_Center_User_Guide.pdf).
83
+
84
+ ## How to Contribute
85
+
86
+ * Fork the repo and create your branch from `master`.
87
+ * If you've added code that should be tested, add tests.
88
+ * Ensure the test suite passes.
89
+ * Submit your pull request! (Ensure you have [synced your fork](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork) with the original repository before initiating the PR).
90
+
91
+
92
+ ## Need Help?
93
+
94
+ For any help, you can reach out to us at our [Discussion Forum](https://community.developer.cybersource.com/t5/cybersource-APIs/bd-p/api).
70
95
 
71
96
  ## Disclaimer
72
97
 
73
- Cybersource may allow Customer to access, use, and/or test a Cybersource product or service that may still be in development or has not been market-tested (“Beta Product”) solely for the purpose of evaluating the functionality or marketability of the Beta Product (a “Beta Evaluation”). Notwithstanding any language to the contrary, the following terms shall apply with respect to Customer’s participation in any Beta Evaluation (and the Beta Product(s)) accessed thereunder): The Parties will enter into a separate form agreement detailing the scope of the Beta Evaluation, requirements, pricing, the length of the beta evaluation period (“Beta Product Form”). Beta Products are not, and may not become, Transaction Services and have not yet been publicly released and are offered for the sole purpose of internal testing and non-commercial evaluation. Customer’s use of the Beta Product shall be solely for the purpose of conducting the Beta Evaluation. Customer accepts all risks arising out of the access and use of the Beta Products. Cybersource may, in its sole discretion, at any time, terminate or discontinue the Beta Evaluation. Customer acknowledges and agrees that any Beta Product may still be in development and that Beta Product is provided “AS IS” and may not perform at the level of a commercially available service, may not operate as expected and may be modified prior to release. CYBERSOURCE SHALL NOT BE RESPONSIBLE OR LIABLE UNDER ANY CONTRACT, TORT (INCLUDING NEGLIGENCE), OR OTHERWISE RELATING TO A BETA PRODUCT OR THE BETA EVALUATION (A) FOR LOSS OR INACCURACY OF DATA OR COST OF PROCUREMENT OF SUBSTITUTE GOODS, SERVICES OR TECHNOLOGY, (B) ANY CLAIM, LOSSES, DAMAGES, OR CAUSE OF ACTION ARISING IN CONNECTION WITH THE BETA PRODUCT; OR (C) FOR ANY INDIRECT, INCIDENTAL OR CONSEQUENTIAL DAMAGES INCLUDING, BUT NOT LIMITED TO, LOSS OF REVENUES AND LOSS OF PROFITS.
98
+ CyberSource may allow Customer to access, use, and/or test a CyberSource product or service that may still be in development or has not been market-tested (“Beta Product”) solely for the purpose of evaluating the functionality or marketability of the Beta Product (a “Beta Evaluation”). Notwithstanding any language to the contrary, the following terms shall apply with respect to Customer’s participation in any Beta Evaluation (and the Beta Product(s)) accessed thereunder): The Parties will enter into a separate form agreement detailing the scope of the Beta Evaluation, requirements, pricing, the length of the beta evaluation period (“Beta Product Form”). Beta Products are not, and may not become, Transaction Services and have not yet been publicly released and are offered for the sole purpose of internal testing and non-commercial evaluation. Customer’s use of the Beta Product shall be solely for the purpose of conducting the Beta Evaluation. Customer accepts all risks arising out of the access and use of the Beta Products. CyberSource may, in its sole discretion, at any time, terminate or discontinue the Beta Evaluation. Customer acknowledges and agrees that any Beta Product may still be in development and that Beta Product is provided “AS IS” and may not perform at the level of a commercially available service, may not operate as expected and may be modified prior to release. CYBERSOURCE SHALL NOT BE RESPONSIBLE OR LIABLE UNDER ANY CONTRACT, TORT (INCLUDING NEGLIGENCE), OR OTHERWISE RELATING TO A BETA PRODUCT OR THE BETA EVALUATION (A) FOR LOSS OR INACCURACY OF DATA OR COST OF PROCUREMENT OF SUBSTITUTE GOODS, SERVICES OR TECHNOLOGY, (B) ANY CLAIM, LOSSES, DAMAGES, OR CAUSE OF ACTION ARISING IN CONNECTION WITH THE BETA PRODUCT; OR (C) FOR ANY INDIRECT, INCIDENTAL OR CONSEQUENTIAL DAMAGES INCLUDING, BUT NOT LIMITED TO, LOSS OF REVENUES AND LOSS OF PROFITS.
99
+
100
+ ## License
101
+
102
+ This repository is distributed under a proprietary license. See the provided [`LICENSE.txt`](/LICENSE.txt) file
@@ -11,7 +11,7 @@ Name | Type | Description | Notes
11
11
  **buyerInformation** | [**Riskv1authenticationsBuyerInformation**](Riskv1authenticationsBuyerInformation.md) | | [optional]
12
12
  **deviceInformation** | [**Riskv1authenticationsDeviceInformation**](Riskv1authenticationsDeviceInformation.md) | | [optional]
13
13
  **merchantInformation** | [**Riskv1decisionsMerchantInformation**](Riskv1decisionsMerchantInformation.md) | | [optional]
14
- **acquirerInformation** | [**Ptsv2paymentsAcquirerInformation**](Ptsv2paymentsAcquirerInformation.md) | | [optional]
14
+ **acquirerInformation** | [**Riskv1decisionsAcquirerInformation**](Riskv1decisionsAcquirerInformation.md) | | [optional]
15
15
  **recurringPaymentInformation** | [**Ptsv2paymentsRecurringPaymentInformation**](Ptsv2paymentsRecurringPaymentInformation.md) | | [optional]
16
16
  **consumerAuthenticationInformation** | [**Riskv1decisionsConsumerAuthenticationInformation**](Riskv1decisionsConsumerAuthenticationInformation.md) | | [optional]
17
17
  **riskInformation** | [**Riskv1authenticationsRiskInformation**](Riskv1authenticationsRiskInformation.md) | | [optional]
@@ -14,7 +14,7 @@ Name | Type | Description | Notes
14
14
  **travelInformation** | [**Riskv1decisionsTravelInformation**](Riskv1decisionsTravelInformation.md) | | [optional]
15
15
  **merchantDefinedInformation** | [**[Riskv1decisionsMerchantDefinedInformation]**](Riskv1decisionsMerchantDefinedInformation.md) | | [optional]
16
16
  **merchantInformation** | [**Riskv1decisionsMerchantInformation**](Riskv1decisionsMerchantInformation.md) | | [optional]
17
- **acquirerInformation** | [**Ptsv2paymentsAcquirerInformation**](Ptsv2paymentsAcquirerInformation.md) | | [optional]
17
+ **acquirerInformation** | [**Riskv1decisionsAcquirerInformation**](Riskv1decisionsAcquirerInformation.md) | | [optional]
18
18
  **recurringPaymentInformation** | [**Ptsv2paymentsRecurringPaymentInformation**](Ptsv2paymentsRecurringPaymentInformation.md) | | [optional]
19
19
  **consumerAuthenticationInformation** | [**Riskv1decisionsConsumerAuthenticationInformation**](Riskv1decisionsConsumerAuthenticationInformation.md) | | [optional]
20
20
  **watchlistScreeningInformation** | [**Ptsv2paymentsWatchlistScreeningInformation**](Ptsv2paymentsWatchlistScreeningInformation.md) | | [optional]
@@ -4,7 +4,7 @@
4
4
  Name | Type | Description | Notes
5
5
  ------------ | ------------- | ------------- | -------------
6
6
  **submitTimeUtc** | **String** | Time of request in UTC. Format: &#x60;YYYY-MM-DDThh:mm:ssZ&#x60; **Example** &#x60;2016-08-11T22:47:57Z&#x60; equals August 11, 2016, at 22:47:57 (10:47:57 p.m.). The &#x60;T&#x60; separates the date and the time. The &#x60;Z&#x60; indicates UTC. Returned by Cybersource for all services. | [optional]
7
- **status** | **String** | The status of the invoice. Possible values: - NOTFOUND | [optional]
7
+ **status** | **String** | The status of the invoice. Possible values: - NOTFOUND | [optional]
8
8
  **reason** | **String** | The reason of the status. Possible values: - MISSING_FIELD - INVALID_DATA - DUPLICATE_REQUEST - INVALID_MERCHANT_CONFIGURATION - PROCESSOR_UNAVAILABLE | [optional]
9
9
  **message** | **String** | The detail message related to the status and reason listed above. | [optional]
10
10
  **details** | [**[PtsV2PaymentsPost201ResponseErrorInformationDetails]**](PtsV2PaymentsPost201ResponseErrorInformationDetails.md) | | [optional]
@@ -0,0 +1,8 @@
1
+ # CyberSource.PostPaymentCredentialsRequest
2
+
3
+ ## Properties
4
+ Name | Type | Description | Notes
5
+ ------------ | ------------- | ------------- | -------------
6
+ **paymentCredentialType** | **String** | The type of payment credentials to be returned. By default, payment credentials include network token and cryptogram or dynamic CVV. If \&quot;NETWORK_TOKEN\&quot; is supplied then only network token will be returned and cryptogram or dynamic CVV will be excluded. Possible Values: - NETWORK_TOKEN | [optional]
7
+
8
+
@@ -6,7 +6,7 @@ Name | Type | Description | Notes
6
6
  **links** | [**PtsV2PaymentsCapturesPost201ResponseLinks**](PtsV2PaymentsCapturesPost201ResponseLinks.md) | | [optional]
7
7
  **id** | **String** | An unique identification number generated by Cybersource to identify the submitted request. Returned by all services. It is also appended to the endpoint of the resource. On incremental authorizations, this value with be the same as the identification number returned in the original authorization response. | [optional]
8
8
  **submitTimeUtc** | **String** | Time of request in UTC. Format: &#x60;YYYY-MM-DDThh:mm:ssZ&#x60; **Example** &#x60;2016-08-11T22:47:57Z&#x60; equals August 11, 2016, at 22:47:57 (10:47:57 p.m.). The &#x60;T&#x60; separates the date and the time. The &#x60;Z&#x60; indicates UTC. Returned by Cybersource for all services. | [optional]
9
- **status** | **String** | The status of the submitted transaction. Possible values: - PENDING | [optional]
9
+ **status** | **String** | The status of the submitted transaction. Possible values: - PENDING - TRANSMITTED (Only for Online Capture enabled merchants) | [optional]
10
10
  **reconciliationId** | **String** | Reference number for the transaction. Depending on how your Cybersource account is configured, this value could either be provided in the API request or generated by CyberSource. The actual value used in the request to the processor is provided back to you by Cybersource in the response. | [optional]
11
11
  **clientReferenceInformation** | [**PtsV2PaymentsPost201ResponseClientReferenceInformation**](PtsV2PaymentsPost201ResponseClientReferenceInformation.md) | | [optional]
12
12
  **processorInformation** | [**PtsV2PaymentsCapturesPost201ResponseProcessorInformation**](PtsV2PaymentsCapturesPost201ResponseProcessorInformation.md) | | [optional]
@@ -4,5 +4,6 @@
4
4
  Name | Type | Description | Notes
5
5
  ------------ | ------------- | ------------- | -------------
6
6
  **transactionId** | **String** | Processor transaction ID. This value identifies the transaction on a host system. This value is supported only for Moneris. It contains this information: - Terminal used to process the transaction - Shift during which the transaction took place - Batch number - Transaction number within the batch You must store this value. If you give the customer a receipt, display this value on the receipt. Example For the value 66012345001069003: - Terminal ID &#x3D; 66012345 - Shift number &#x3D; 001 - Batch number &#x3D; 069 - Transaction number &#x3D; 003 | [optional]
7
+ **networkTransactionId** | **String** | Network Transaction Identifier Applicable for online capture transactions only. | [optional]
7
8
 
8
9
 
@@ -3,7 +3,7 @@
3
3
  ## Properties
4
4
  Name | Type | Description | Notes
5
5
  ------------ | ------------- | ------------- | -------------
6
- **status** | **String** | The status of the submitted transaction. Possible values: - PENDING | [optional]
6
+ **status** | **String** | The status of the submitted transaction. Possible values: - PENDING - TRANSMITTED (Only for Online Capture enabled merchants) | [optional]
7
7
  **reason** | **String** | The reason of the status. Possible values: - MISSING_FIELD - INVALID_DATA - DUPLICATE_REQUEST - INVALID_MERCHANT_CONFIGURATION - EXCEEDS_AUTH_AMOUNT - AUTH_ALREADY_REVERSED - TRANSACTION_ALREADY_SETTLED - INVALID_AMOUNT - MISSING_AUTH - TRANSACTION_ALREADY_REVERSED_OR_SETTLED - NOT_SUPPORTED | [optional]
8
8
  **message** | **String** | The detail message related to the status and reason listed above. | [optional]
9
9
 
@@ -7,5 +7,6 @@ Name | Type | Description | Notes
7
7
  **country** | **String** | Issuers need to be aware of the Acquirer&#39;s Country Code when the Acquirer country differs from the Merchant country and the Acquirer is in the EEA (European Economic Area). | [optional]
8
8
  **password** | **String** | Registered password for the Visa directory server. | [optional]
9
9
  **merchantId** | **String** | Username for the visa directory server that is created when your acquirer sets up your account. This ID might be the same as your merchant ID. the username can be 15 or 23 characters. | [optional]
10
+ **acquirerMerchantId** | **String** | Acquirer assigned merchant id. Check if your processor supports this field. | [optional]
10
11
 
11
12
 
@@ -4,6 +4,5 @@
4
4
  Name | Type | Description | Notes
5
5
  ------------ | ------------- | ------------- | -------------
6
6
  **amountDetails** | [**Riskv1authenticationresultsOrderInformationAmountDetails**](Riskv1authenticationresultsOrderInformationAmountDetails.md) | | [optional]
7
- **lineItems** | [**[Riskv1authenticationresultsOrderInformationLineItems]**](Riskv1authenticationresultsOrderInformationLineItems.md) | | [optional]
8
7
 
9
8
 
@@ -0,0 +1,11 @@
1
+ # CyberSource.Riskv1decisionsAcquirerInformation
2
+
3
+ ## Properties
4
+ Name | Type | Description | Notes
5
+ ------------ | ------------- | ------------- | -------------
6
+ **acquirerBin** | **String** | Acquirer bank ID number that corresponds to a certificate that Cybersource already has.This ID has this format. 4XXXXX for Visa and 5XXXXX for Mastercard. | [optional]
7
+ **country** | **String** | Issuers need to be aware of the Acquirer&#39;s Country Code when the Acquirer country differs from the Merchant country and the Acquirer is in the EEA (European Economic Area). | [optional]
8
+ **password** | **String** | Registered password for the Visa directory server. | [optional]
9
+ **merchantId** | **String** | Username for the visa directory server that is created when your acquirer sets up your account. This ID might be the same as your merchant ID. the username can be 15 or 23 characters. | [optional]
10
+
11
+
@@ -3,8 +3,10 @@
3
3
  ## Properties
4
4
  Name | Type | Description | Notes
5
5
  ------------ | ------------- | ------------- | -------------
6
- **type** | **String** | The network token card association brand Possible Values: - visa - mastercard | [optional]
6
+ **type** | **String** | The network token card association brand Possible Values: - visa - mastercard - americanexpress | [optional]
7
7
  **state** | **String** | State of the network token or network token provision Possible Values: - ACTIVE : Network token is active. - SUSPENDED : Network token is suspended. This state can change back to ACTIVE. - DELETED : This is a final state for a network token instance. - UNPROVISIONED : A previous network token provision was unsuccessful. | [optional]
8
+ **enrollmentId** | **String** | Unique Identifier for the enrolled PAN. This Id is provided by the card association when a network token is provisioned successfully. | [optional]
9
+ **tokenReferenceId** | **String** | Unique Identifier for the network token. This Id is provided by the card association when a network token is provisioned successfully. | [optional]
8
10
  **reason** | **String** | Issuers state for the network token Possible Values: - INVALID_REQUEST : The network token provision request contained invalid data. - CARD_VERIFICATION_FAILED : The network token provision request contained data that could not be verified. - CARD_NOT_ELIGIBLE : Card can currently not be used with issuer for tokenization. - CARD_NOT_ALLOWED : Card can currently not be used with card association for tokenization. - DECLINED : Card can currently not be used with issuer for tokenization. - SERVICE_UNAVAILABLE : The network token service was unavailable or timed out. - SYSTEM_ERROR : An unexpected error occurred with network token service, check configuration. | [optional]
9
11
  **_number** | **String** | The token requestors network token | [optional]
10
12
  **expirationMonth** | **String** | Two-digit month in which the network token expires. Format: &#x60;MM&#x60;. Possible Values: &#x60;01&#x60; through &#x60;12&#x60;. | [optional]
package/docs/TokenApi.md CHANGED
@@ -9,7 +9,7 @@ Method | HTTP request | Description
9
9
 
10
10
  <a name="postTokenPaymentCredentials"></a>
11
11
  # **postTokenPaymentCredentials**
12
- > &#39;String&#39; postTokenPaymentCredentials(tokenId, opts)
12
+ > &#39;String&#39; postTokenPaymentCredentials(tokenId, postPaymentCredentialsRequest, opts)
13
13
 
14
14
  Generate Payment Credentials for a TMS Token
15
15
 
@@ -23,6 +23,8 @@ var apiInstance = new CyberSource.TokenApi();
23
23
 
24
24
  var tokenId = "tokenId_example"; // String | The Id of a token representing a Customer, Payment Instrument or Instrument Identifier.
25
25
 
26
+ var postPaymentCredentialsRequest = new CyberSource.PostPaymentCredentialsRequest(); // PostPaymentCredentialsRequest |
27
+
26
28
  var opts = {
27
29
  'profileId': "profileId_example" // String | The Id of a profile containing user specific TMS configuration.
28
30
  };
@@ -34,7 +36,7 @@ var callback = function(error, data, response) {
34
36
  console.log('API called successfully. Returned data: ' + data);
35
37
  }
36
38
  };
37
- apiInstance.postTokenPaymentCredentials(tokenId, opts, callback);
39
+ apiInstance.postTokenPaymentCredentials(tokenId, postPaymentCredentialsRequest, opts, callback);
38
40
  ```
39
41
 
40
42
  ### Parameters
@@ -42,6 +44,7 @@ apiInstance.postTokenPaymentCredentials(tokenId, opts, callback);
42
44
  Name | Type | Description | Notes
43
45
  ------------- | ------------- | ------------- | -------------
44
46
  **tokenId** | **String**| The Id of a token representing a Customer, Payment Instrument or Instrument Identifier. |
47
+ **postPaymentCredentialsRequest** | [**PostPaymentCredentialsRequest**](PostPaymentCredentialsRequest.md)| |
45
48
  **profileId** | **String**| The Id of a profile containing user specific TMS configuration. | [optional]
46
49
 
47
50
  ### Return type
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cybersource-rest-client",
3
- "version": "0.0.52",
3
+ "version": "0.0.53",
4
4
  "description": "Node.js SDK for the CyberSource REST API",
5
5
  "author": "developer@cybersource.com",
6
6
  "license": "CyberSource",
@@ -12,30 +12,30 @@
12
12
  "fs": false
13
13
  },
14
14
  "dependencies": {
15
- "axios": "1.6.0",
15
+ "axios": "1.6.4",
16
16
  "axios-cookiejar-support": "4.0.7",
17
17
  "tough-cookie": "4.1.3",
18
18
  "https-proxy-agent": "^7.0.0",
19
- "app-root-path": "^2.1.0",
20
- "chai": "^4.1.2",
19
+ "app-root-path": "^3.1.0",
20
+ "chai": "^4.3.1",
21
21
  "chai-as-promised": "^7.1.1",
22
- "jwt-simple": "^0.5.1",
22
+ "jwt-simple": "^0.5.6",
23
23
  "memory-cache": "^0.2.0",
24
24
  "node-forge": ">=1.0.0",
25
- "promise": "^8.0.1",
26
- "winston": "^3.3.3",
27
- "winston-daily-rotate-file": "^4.5.1",
25
+ "promise": "^8.3.0",
26
+ "winston": "^3.11.0",
27
+ "winston-daily-rotate-file": "^4.7.1",
28
28
  "node-jose": "^2.2.0"
29
29
  },
30
30
  "keywords": [
31
31
  "nodeJS"
32
32
  ],
33
33
  "devDependencies": {
34
- "@sinonjs/formatio": "3.0.0",
34
+ "@sinonjs/formatio": "5.0.1",
35
35
  "expect.js": "~0.3.1",
36
36
  "jwk-to-pem": "^2.0.5",
37
37
  "mocha": "^10.2.0",
38
- "mocha-sonarqube-reporter": "^1.0.1",
38
+ "mocha-sonarqube-reporter": "^1.0.2",
39
39
  "nyc": "^15.1.0",
40
40
  "sonar-scanner": "^3.1.0"
41
41
  }
@@ -16,18 +16,18 @@
16
16
  (function(root, factory) {
17
17
  if (typeof define === 'function' && define.amd) {
18
18
  // AMD. Register as an anonymous module.
19
- define(['ApiClient', 'model/InlineResponse400', 'model/InlineResponse403', 'model/InlineResponse410', 'model/InlineResponse424', 'model/InlineResponse500'], factory);
19
+ define(['ApiClient', 'model/InlineResponse400', 'model/InlineResponse403', 'model/InlineResponse410', 'model/InlineResponse424', 'model/InlineResponse500', 'model/PostPaymentCredentialsRequest'], factory);
20
20
  } else if (typeof module === 'object' && module.exports) {
21
21
  // CommonJS-like environments that support module.exports, like Node.
22
- module.exports = factory(require('../ApiClient'), require('../model/InlineResponse400'), require('../model/InlineResponse403'), require('../model/InlineResponse410'), require('../model/InlineResponse424'), require('../model/InlineResponse500'));
22
+ module.exports = factory(require('../ApiClient'), require('../model/InlineResponse400'), require('../model/InlineResponse403'), require('../model/InlineResponse410'), require('../model/InlineResponse424'), require('../model/InlineResponse500'), require('../model/PostPaymentCredentialsRequest'));
23
23
  } else {
24
24
  // Browser globals (root is window)
25
25
  if (!root.CyberSource) {
26
26
  root.CyberSource = {};
27
27
  }
28
- root.CyberSource.TokenApi = factory(root.CyberSource.ApiClient, root.CyberSource.InlineResponse400, root.CyberSource.InlineResponse403, root.CyberSource.InlineResponse410, root.CyberSource.InlineResponse424, root.CyberSource.InlineResponse500);
28
+ root.CyberSource.TokenApi = factory(root.CyberSource.ApiClient, root.CyberSource.InlineResponse400, root.CyberSource.InlineResponse403, root.CyberSource.InlineResponse410, root.CyberSource.InlineResponse424, root.CyberSource.InlineResponse500, root.CyberSource.PostPaymentCredentialsRequest);
29
29
  }
30
- }(this, function(ApiClient, InlineResponse400, InlineResponse403, InlineResponse410, InlineResponse424, InlineResponse500) {
30
+ }(this, function(ApiClient, InlineResponse400, InlineResponse403, InlineResponse410, InlineResponse424, InlineResponse500, PostPaymentCredentialsRequest) {
31
31
  'use strict';
32
32
 
33
33
  /**
@@ -61,23 +61,30 @@
61
61
  * Generate Payment Credentials for a TMS Token
62
62
  * | | | | | --- | --- | --- | |**Token**&lt;br&gt;A Token can represent your tokenized Customer, Payment Instrument or Instrument Identifier information.|&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;|**Payment Credentials**&lt;br&gt;Contains payment information such as the network token, generated cryptogram for Visa &amp; MasterCard or dynamic CVV for Amex in a JSON Web Encryption (JWE) response.&lt;br&gt;Your system can use this API to retrieve the Payment Credentials for an existing Customer, Payment Instrument or Instrument Identifier.
63
63
  * @param {String} tokenId The Id of a token representing a Customer, Payment Instrument or Instrument Identifier.
64
+ * @param {module:model/PostPaymentCredentialsRequest} postPaymentCredentialsRequest
64
65
  * @param {Object} opts Optional parameters
65
66
  * @param {String} opts.profileId The Id of a profile containing user specific TMS configuration.
66
67
  * @param {module:api/TokenApi~postTokenPaymentCredentialsCallback} callback The callback function, accepting three arguments: error, data, response
67
68
  * data is of type: {@link 'String'}
68
69
  */
69
- this.postTokenPaymentCredentials = function(tokenId, opts, callback) {
70
+ this.postTokenPaymentCredentials = function(tokenId, postPaymentCredentialsRequest, opts, callback) {
70
71
  opts = opts || {};
71
- var postBody = null;
72
- if ('POST' == 'POST') {
73
- postBody = '{}';
74
- }
72
+ var postBody = postPaymentCredentialsRequest;
75
73
 
76
74
  // verify the required parameter 'tokenId' is set
77
75
  if (tokenId === undefined || tokenId === null) {
78
76
  throw new Error("Missing the required parameter 'tokenId' when calling postTokenPaymentCredentials");
79
77
  }
80
78
 
79
+ // verify the required parameter 'postPaymentCredentialsRequest' is set
80
+ if (postPaymentCredentialsRequest === undefined || postPaymentCredentialsRequest === null) {
81
+ throw new Error("Missing the required parameter 'postPaymentCredentialsRequest' when calling postTokenPaymentCredentials");
82
+ }
83
+
84
+ var SdkTracker = require('../utilities/tracking/SdkTracker');
85
+
86
+ var sdkTracker = new SdkTracker();
87
+ postBody = sdkTracker.insertDeveloperIdTracker(postBody, 'module:model/PostPaymentCredentialsRequest', this.apiClient.merchantConfig.runEnvironment);
81
88
 
82
89
  var pathParams = {
83
90
  'tokenId': tokenId