@datenkraft/bb-fulfillment-api-ts-client
TypeScript icon, indicating that this package has built-in type declarations

2.5.20 • Public • Published

Backbone - Fulfillment API TS Client

Introduction

The Fulfillment API TS Client enables you to work with the Fulfillment API.

Prerequisites

  • npm

Installation

You can use npm to install the package.

npm install @datenkraft/bb-fulfillment-api-ts-client

Using the package

The package can be used to communicate with the Fulfillment API. The Client includes functionalities for every endpoint defined in the openapi.json. The Client is auto-generated with ferdikoomen/openapi-typescript-codegen using an openapi.json file.

Initializing the Client

import { ConfigOptions } from '@datenkraft/bb-base-api-ts-client';
import { FulfillmentApiClient } from '@datenkraft/bb-fulfillment-api-ts-client';

const configOptions: ConfigOptions = {
  clientId: 'clientId',
  clientSecret: 'clientSecret',
  oAuthTokenHost: 'oAuthTokenHost',
  tokenTradeInPath: 'tokenTradeInPath',
  externalIdToken: 'externalIdToken',
  useExternalIdToken: true,
};

FulfillmentApiClient.init(configOptions).then(() => {
  // Client is initialized
});

Example Endpoint: Get DebtLineItemCollection

FulfillmentApiClient.Generated.SkuService.getSku('skuCode')
  .then((sku) => {
    // Request succeeded
  })
  .catch((error) => {
    // An error occured
  });

License

This repository is available under the MIT license.

Package Sidebar

Install

Weekly Downloads

644

Version

2.5.20

License

MIT

Unpacked Size

273 kB

Total Files

225

Last publish

Collaborators

  • stefanmeindl
  • stefan.k
  • datenkraft-admin
  • floflock
  • raphael.p
  • philipp_kern