2.3.1 • Published 1 month ago

@ecomplus/client v2.3.1

Weekly downloads
404
License
MIT
Repository
github
Last release
1 month ago

E-Com Plus Client

Publish CodeFactor npm version License MIT

JS client for E-Com Plus REST APIs

CHANGELOG

Usage

TL;DR: We have methods to run requests for almost all E-Com Plus APIs, but you're probably searching for Store API.

The @ecomplus/client package provides a list of methods, each one is a function to request a specific E-Com Plus REST API, using axios HTTP client and returning a Promise.

It's available for both Node.js and browser environments.

Store API request example

import { store } from '@ecomplus/client'

const authenticationId = 'myAuthenticationId'
const accessToken = 'myAccessToken'

ecomClient.store({
  url: '/products.json',
  authenticationId,
  accessToken,
  method: 'post',
  data: { sku: '123', name: 'Sample Prduct 123' }
})
  .then(({ data, status }) => console.log(status, data))
  .catch(error => console.error(error))

Dependencies

It requires and may not include core-js, axios and @ecomplus/utils.

Node.js

npm i --save @ecomplus/utils @ecomplus/client

Webpack

npm i --save core-js @ecomplus/utils @ecomplus/client

CDN

<script src="https://cdn.jsdelivr.net/npm/@ecomplus/client/dist/ecom-client.polyfill.min.js"></script>

axios and ecomUtils libraries must be included separately and available on window scope.

Development

Fork/clone this repository and install dependencies normally:

git clone https://github.com/ecomplus/client
cd client
npm i

Then you can edit source files and test locally with npm run serve.

Contributing

Please read the contribution guidelines.

Deploy

Take a look on package.json scripts:

  • npm run doc - Update jsdoc/docdash generated documentation;
  • npm run release - Generate changelog and new version;
2.3.1

1 month ago

2.2.1

3 years ago

2.2.0

3 years ago

2.1.4

3 years ago

2.1.3

3 years ago

2.1.2

4 years ago

2.1.1

4 years ago

2.1.0

4 years ago

2.0.4

4 years ago

2.0.3

4 years ago

2.0.2

4 years ago

2.0.1

4 years ago

2.0.0

4 years ago

1.1.3

5 years ago

1.1.2

5 years ago

1.1.1

5 years ago

1.1.0

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago

0.8.0

5 years ago

0.7.1

5 years ago

0.7.0

5 years ago

0.6.0

5 years ago

0.5.1

5 years ago

0.5.0

5 years ago

0.4.3

5 years ago

0.4.2

5 years ago

0.4.1

5 years ago

0.4.0

5 years ago

0.3.0

5 years ago

0.2.1

5 years ago

0.2.0

5 years ago

0.0.1

5 years ago