linxcommerce-webapi-sdk 1.0.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.
- package/README.md +116 -0
- package/dist/index.d.ts +2908 -0
- package/dist/index.js +4634 -0
- package/dist/index.mjs +4586 -0
- package/package.json +44 -0
package/README.md
ADDED
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
# LinxcommerceWebapiSdk TypeScript SDK 1.0.0
|
|
2
|
+
|
|
3
|
+
Welcome to the LinxcommerceWebapiSdk SDK documentation. This guide will help you get started with integrating and using the LinxcommerceWebapiSdk SDK in your project.
|
|
4
|
+
|
|
5
|
+
This SDK was generated by [Postman](https://www.postman.com)
|
|
6
|
+
|
|
7
|
+
## Versions
|
|
8
|
+
|
|
9
|
+
- SDK version: `1.0.0`
|
|
10
|
+
|
|
11
|
+
## Table of Contents
|
|
12
|
+
|
|
13
|
+
- [Setup & Configuration](#setup--configuration)
|
|
14
|
+
- [Supported Language Versions](#supported-language-versions)
|
|
15
|
+
- [Installation](#installation)
|
|
16
|
+
- [Setting a Custom Timeout](#setting-a-custom-timeout)
|
|
17
|
+
- [Sample Usage](#sample-usage)
|
|
18
|
+
- [Services](#services)
|
|
19
|
+
- [Models](#models)
|
|
20
|
+
|
|
21
|
+
# Setup & Configuration
|
|
22
|
+
|
|
23
|
+
## Supported Language Versions
|
|
24
|
+
|
|
25
|
+
This SDK is compatible with the following versions: `TypeScript >= 4.8.4`
|
|
26
|
+
|
|
27
|
+
## Installation
|
|
28
|
+
|
|
29
|
+
To get started with the SDK, we recommend installing using `npm` or `yarn`:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
npm install linxcommerce-webapi-sdk
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
or
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
yarn add linxcommerce-webapi-sdk
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Setting a Custom Timeout
|
|
42
|
+
|
|
43
|
+
You can set a custom timeout for the SDK's HTTP requests as follows:
|
|
44
|
+
|
|
45
|
+
```ts
|
|
46
|
+
const linxcommerceWebapiSdk = new LinxcommerceWebapiSdk({ timeout: 10000 });
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
# Sample Usage
|
|
50
|
+
|
|
51
|
+
Below is a comprehensive example demonstrating how to authenticate and call a simple endpoint:
|
|
52
|
+
|
|
53
|
+
```ts
|
|
54
|
+
import { LinxcommerceWebapiSdk } from 'linxcommerce-webapi-sdk';
|
|
55
|
+
|
|
56
|
+
(async () => {
|
|
57
|
+
const linxcommerceWebapiSdk = new LinxcommerceWebapiSdk({});
|
|
58
|
+
|
|
59
|
+
const data = await linxcommerceWebapiSdk.customers.consumerDetail({
|
|
60
|
+
customerId: '{{CustomerID}}',
|
|
61
|
+
sessionId: '{{SessionID}}',
|
|
62
|
+
});
|
|
63
|
+
|
|
64
|
+
console.log(data);
|
|
65
|
+
})();
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## Services
|
|
69
|
+
|
|
70
|
+
The SDK provides various services to interact with the API.
|
|
71
|
+
|
|
72
|
+
<details>
|
|
73
|
+
<summary>Below is a list of all available services with links to their detailed documentation:</summary>
|
|
74
|
+
|
|
75
|
+
| Name |
|
|
76
|
+
| :----------------------------------------------------------------------------- |
|
|
77
|
+
| CustomersService |
|
|
78
|
+
| ProductsService |
|
|
79
|
+
| AddressService |
|
|
80
|
+
| DeliveryService |
|
|
81
|
+
| BasketService |
|
|
82
|
+
| CheckoutService |
|
|
83
|
+
| OrdersService |
|
|
84
|
+
| WsService |
|
|
85
|
+
| WidgetService |
|
|
86
|
+
| OndeEncontrarJsonService |
|
|
87
|
+
|
|
88
|
+
</details>
|
|
89
|
+
|
|
90
|
+
## Models
|
|
91
|
+
|
|
92
|
+
The SDK includes several models that represent the data structures used in API requests and responses. These models help in organizing and managing the data efficiently.
|
|
93
|
+
|
|
94
|
+
<details>
|
|
95
|
+
<summary>Below is a list of all available models with links to their detailed documentation:</summary>
|
|
96
|
+
|
|
97
|
+
| Name | Description |
|
|
98
|
+
| :--------------------------------------------------------------------------------------------------- | :---------- |
|
|
99
|
+
| CreateConsumerRequest | |
|
|
100
|
+
| CreateConsumerRequestCustomer | |
|
|
101
|
+
| CustomerContact1 | |
|
|
102
|
+
| CreateBusinessAccountRequest | |
|
|
103
|
+
| CreateBusinessAccountRequestCustomer | |
|
|
104
|
+
| CustomerContact2 | |
|
|
105
|
+
| Addresses | |
|
|
106
|
+
| ExtendedProperties | |
|
|
107
|
+
| HtmlAttributes | |
|
|
108
|
+
| LoginRequest | |
|
|
109
|
+
| RecoverPasswordRequest | |
|
|
110
|
+
| ProductsDatasourceRequest | |
|
|
111
|
+
| BrandsRequest | |
|
|
112
|
+
| RetornaOpODeEntregaParaOmsRequest | |
|
|
113
|
+
| DetailsOrderRequest | |
|
|
114
|
+
| AccountOrderRequest | |
|
|
115
|
+
|
|
116
|
+
</details>
|