@ritas-inc/sapb1commandapi-client
Version:
A stateless TypeScript client for SAP B1 Service Layer Command API with comprehensive error handling, type safety, and batch operations
11 lines (10 loc) • 744 B
TypeScript
import type { HTTPClient } from '../utils/http.client.js';
import { type CreatePlanResponse, type UpdatePlanStatusResponse, type UpdatePlanProductsResponse, type CancelPlanResponse, type PlanProduct, type PlanStatus } from '../schemas/plans.schema.js';
export declare class PlansService {
private httpClient;
constructor(httpClient: HTTPClient);
create(userId: string, user: number, products: PlanProduct[]): Promise<CreatePlanResponse>;
updateStatus(userId: string, planId: number, status: PlanStatus): Promise<UpdatePlanStatusResponse>;
updateProducts(userId: string, planId: number, products: PlanProduct[]): Promise<UpdatePlanProductsResponse>;
cancel(userId: string, planId: number): Promise<CancelPlanResponse>;
}