@devicepark/sdk
v1.0.3
Published
Unified SDK for DevicePark clients
Downloads
97
Readme
@devicepark/sdk
Unified SDK for interacting with the DevicePark API Suite.
This package combines allocation, session, management, and storage clients into a single configurable SDK.
✨ Features
- ✅ One-line initialization for all APIs
- ✅ OAuth2 Client Credentials support (via shared config)
- ♻️ Token caching, retry and error handling (powered by Axios interceptors)
- 📦 Includes allocation, session, management, and storage clients
📦 Installation
npm install @devicepark/sdk🚀 Usage
import { DeviceParkSDK } from '@devicepark/sdk';
const sdk = DeviceParkSDK.init({
apiUrl: 'https://<devicepark_api_uri>',
authentication: {
clientId: 'your-client-id',
clientSecret: 'your-client-secret',
issuerUri: 'https://<devicepark_auth_uri>',
}
});
await sdk.management.getDevices(...);
await sdk.allocation.createAllocation(...);
await sdk.session.startSession(...);
await sdk.storage.uploadFileStream(...);🔗 Related
@devicepark/management-client@devicepark/allocation-client@devicepark/session-client@devicepark/storage-client
🛡 License
MIT
