ChemPare Documentation - v0.0.0
    Preparing search index...

    Interface Supplier

    Base interface for product supplier implementation. Defines the common structure and functionality that all suppliers must implement.

    class MySupplier implements Supplier {
    supplierName = "MySupplier";
    query = "";
    queryResults = [];
    baseURL = "https://mysupplier.com";
    controller = new AbortController();
    limit = 10;
    httpRequestHardLimit = 50;
    headers = { "Content-Type": "application/json" };
    }
    interface Supplier {
        supplierName: string;
        query: string;
        queryResults: Record<string, unknown>[];
        baseURL: string;
        controller: AbortController;
        limit: number;
        httpRequestHardLimit: number;
        headers: HeadersInit;
    }
    Index

    Properties

    supplierName: string

    Display name of the supplier

    query: string

    Current active search query

    queryResults: Record<string, unknown>[]

    Raw results from the last search query

    baseURL: string

    Base URL for supplier's API endpoints

    controller: AbortController

    AbortController for canceling in-flight requests

    limit: number

    Maximum number of results to return

    httpRequestHardLimit: number

    Maximum number of concurrent HTTP requests

    headers: HeadersInit

    Custom headers for API requests