UNPKG

@simpleapps-com/augur-api

Version:

TypeScript client library for Augur microservices API endpoints

60 lines 3.14 kB
import { BaseServiceClient } from '../../core/base-client'; import { createHealthCheckResource, createHealthCheckDataResource, createCategoriesResource, createCategoriesDataResource, } from './resources'; /** * Brand Folder Service Client * @description Client for interacting with Brand Folder API endpoints for category focus management and brand organization * @fullPath api.brandFolder * @service brand-folder * @domain brand-management * @discoverable true * @searchTerms ["brand-folder", "category focus", "brand management", "category organization", "brand configuration", "focus management"] * @relatedEndpoints ["api.brandFolder.healthCheck.get", "api.brandFolder.categories.focus.create", "api.items.categories.list", "api.commerce.brands.list"] * @commonPatterns ["Brand management", "Category focus configuration", "Brand organization", "Category prioritization"] * @workflow ["brand-management", "category-organization", "content-management", "merchandising"] * @functionalArea "brand-and-category-management" * @businessRules ["Requires valid bearer authentication", "Category focus configuration", "Brand-category associations", "Priority-based organization"] * @performance "Optimized for brand management workflows and category focus operations" * @example * ```typescript * import { HTTPClient } from '@augur/api-client/core'; * import { BrandFolderClient } from '@augur/api-client/services/brand-folder'; * * const http = new HTTPClient('brand-folder', { siteId: 'your-site-id', bearerToken: 'your-token' }); * const brandFolder = new BrandFolderClient(http); * * // Check service health * const health = await brandFolder.healthCheck.get(); * const healthData = await brandFolder.healthCheckData.get(); * * // Set category focus * const focusConfig = { * categoryId: 'cat-123', * focusLevel: 'primary' as const, * priority: 95, * isActive: true * }; * const focus = await brandFolder.categories.focus.create(focusConfig); * const focusData = await brandFolder.categoriesData.focus.create(focusConfig); * ``` */ export class BrandFolderClient extends BaseServiceClient { constructor(http, baseUrl) { super('brand-folder', http, baseUrl || 'https://brand-folder.augur-api.com'); // Bind executeRequest for resource factories const boundExecuteRequest = (config, params, pathParams) => { if (params !== undefined || config.paramsSchema !== undefined) { return this.executeRequest(config, params, pathParams); } return this.executeRequest(config, undefined, pathParams); }; // Initialize resources this.healthCheck = createHealthCheckResource(boundExecuteRequest); this.healthCheckData = createHealthCheckDataResource(this.healthCheck); this.categories = createCategoriesResource(boundExecuteRequest); this.categoriesData = createCategoriesDataResource(this.categories); } getServiceDescription() { return 'Brand folder management service for category focus configuration and brand organization'; } } //# sourceMappingURL=client.js.map