@ecency/sdk 2.3.46 → 2.3.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/browser/index.d.ts
CHANGED
|
@@ -957,6 +957,15 @@ declare function withTimeoutSignal(timeoutMs: number, signal?: AbortSignal): Abo
|
|
|
957
957
|
declare const INTERNAL_API_TIMEOUT_MS = 10000;
|
|
958
958
|
declare const CONFIG: {
|
|
959
959
|
privateApiHost: string;
|
|
960
|
+
/**
|
|
961
|
+
* First-party client identifier sent as the `X-Ecency-Client` header on
|
|
962
|
+
* search/private API requests. Lets the origin distinguish Ecency's own
|
|
963
|
+
* web/mobile/SSR traffic from third-party integrators (who should use the
|
|
964
|
+
* keyed api.hivesearcher.com backend instead of the public proxy). This is
|
|
965
|
+
* a routing marker, not a secret. Apps may override via
|
|
966
|
+
* `ConfigManager.setClientId` (e.g. "web" or "mobile") for observability.
|
|
967
|
+
*/
|
|
968
|
+
clientId: string;
|
|
960
969
|
imageHost: string;
|
|
961
970
|
/** Current Hive RPC nodes. Reads from the unified hive-tx config. */
|
|
962
971
|
readonly hiveNodes: string[];
|
|
@@ -983,6 +992,14 @@ declare namespace ConfigManager {
|
|
|
983
992
|
* @param host - The private API host URL (e.g., "https://ecency.com" or "" for relative URLs)
|
|
984
993
|
*/
|
|
985
994
|
function setPrivateApiHost(host: string): void;
|
|
995
|
+
/**
|
|
996
|
+
* Set the first-party client identifier sent as the `X-Ecency-Client` header
|
|
997
|
+
* on search/private API requests (e.g. "web" or "mobile"). Defaults to
|
|
998
|
+
* "ecency-sdk". Used by the origin to tell Ecency's own apps apart from
|
|
999
|
+
* third-party integrators.
|
|
1000
|
+
* @param clientId - Short client label
|
|
1001
|
+
*/
|
|
1002
|
+
function setClientId(clientId: string): void;
|
|
986
1003
|
/**
|
|
987
1004
|
* Get a validated base URL for API requests
|
|
988
1005
|
* Returns a valid base URL that can be used with new URL(path, baseUrl)
|