UNPKG

kii-aggregator-sdk-test

Version:

KII Aggregator SDK

51 lines (35 loc) 953 B
# KII Aggregator SDK A TypeScript SDK for the KII Marketplace Aggregator API. ## Installation ```bash npm install kii-aggregator-sdk-test ``` ## Usage ```typescript import { KiiAggregatorSdk } from 'kii-aggregator-sdk-test'; // Initialize the SDK const sdk = new KiiAggregatorSdk({ clientId: 'your-client-id', apiKey: 'your-api-key', sdkVersion: '1.0.0' }); // Validate the SDK const isValid = await sdk.validate(); if (isValid) { console.log('SDK validated successfully'); // Send events await sdk.sendEvent('product.fetched', { product_id: 'prod_123' }); } ``` ## API Reference ### Constructor ```typescript new KiiAggregatorSdk(config: SdkConfig) ``` ### Methods - `validate()`: Validate the SDK credentials - `sendEvent(payload, additionalData?)`: Send webhook events - `getLicense()`: Get license information - `isValidated()`: Check if SDK is validated ## License MIT