@hsuite/smart-engines-sdk 3.5.0 → 3.6.0

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/index.d.ts CHANGED
@@ -1874,6 +1874,7 @@ export type HttpClientConfig = {
1874
1874
  authToken?: string;
1875
1875
  apiKey?: string;
1876
1876
  timeout?: number;
1877
+ onUnauthorized?: () => Promise<void>;
1877
1878
  };
1878
1879
  export declare class SdkHttpError extends Error {
1879
1880
  readonly statusCode: number;
@@ -2118,6 +2119,13 @@ export type SubscriptionStatusResponse = {
2118
2119
  lockedUntil?: string;
2119
2120
  };
2120
2121
  subscriptionNftSerial?: number;
2122
+ chainNfts?: {
2123
+ xrpl?: {
2124
+ nftId?: string;
2125
+ issuerAddress?: string;
2126
+ offerTxId?: string;
2127
+ };
2128
+ } & Record<string, unknown>;
2121
2129
  expiresAt?: string;
2122
2130
  remainingBalance?: string;
2123
2131
  createdAt?: string;
@@ -2304,6 +2312,48 @@ export declare class SubscriptionClient {
2304
2312
  getBilling(appId: string, options?: GetBillingOptions): Promise<SubscriptionBillingResponse>;
2305
2313
  mintCustomer(request: MintCustomerSubscriptionRequest): Promise<MintCustomerSubscriptionResponse>;
2306
2314
  }
2315
+ export type FaucetChallenge = {
2316
+ challengeId: string;
2317
+ message: string;
2318
+ expiresInSeconds: number;
2319
+ };
2320
+ export type FaucetDispenseRequest = {
2321
+ chain: string;
2322
+ recipientAddress: string;
2323
+ challengeId: string;
2324
+ signature: string;
2325
+ publicKey?: string;
2326
+ };
2327
+ export type FaucetDispensed = {
2328
+ status: "dispensed";
2329
+ amount: string;
2330
+ txHash: string;
2331
+ remainingDailyAllowance: string;
2332
+ };
2333
+ export type FaucetTrustlineRequired = {
2334
+ status: "trustline_required";
2335
+ trustLine: {
2336
+ currency: string;
2337
+ issuer: string;
2338
+ limit: string;
2339
+ };
2340
+ };
2341
+ export type FaucetRateLimited = {
2342
+ status: "rate_limited";
2343
+ retryAfterSeconds: number;
2344
+ };
2345
+ export type FaucetDispenseResult = FaucetDispensed | FaucetTrustlineRequired | FaucetRateLimited;
2346
+ export type FaucetStatusResponse = {
2347
+ dispensedToday: string;
2348
+ [key: string]: unknown;
2349
+ };
2350
+ export declare class FaucetClient {
2351
+ private readonly http;
2352
+ constructor(http: HttpClient);
2353
+ requestChallenge(chain: string, recipientAddress: string): Promise<FaucetChallenge>;
2354
+ dispense(req: FaucetDispenseRequest): Promise<FaucetDispenseResult>;
2355
+ getStatus(chain: string, recipientAddress: string): Promise<FaucetStatusResponse>;
2356
+ }
2307
2357
  export type EntityType = "account" | "token" | "topic";
2308
2358
  export type EntityCreationOptions = {
2309
2359
  entityType: EntityType;
@@ -4089,6 +4139,7 @@ export type BaasDeployRequest = {
4089
4139
  tag: string;
4090
4140
  port?: number;
4091
4141
  replicas?: number;
4142
+ degree?: number;
4092
4143
  env?: Record<string, string>;
4093
4144
  resources?: {
4094
4145
  cpu?: string;
@@ -4535,6 +4586,7 @@ export declare class SmartEngineClient {
4535
4586
  private readonly txHttp;
4536
4587
  private lastHttpError?;
4537
4588
  readonly subscription: SubscriptionClient;
4589
+ readonly faucet: FaucetClient;
4538
4590
  readonly tss: TSSClient;
4539
4591
  readonly ipfs: IPFSClient;
4540
4592
  readonly transactions: TransactionsClient;
@@ -5243,7 +5295,6 @@ export declare class StorageClient {
5243
5295
  delete(cid: string): Promise<{
5244
5296
  success: boolean;
5245
5297
  }>;
5246
- getFile(cid: string): Promise<BaasFileInfo>;
5247
5298
  listFiles(pagination?: {
5248
5299
  limit?: number;
5249
5300
  offset?: number;
@@ -25093,6 +25144,7 @@ export declare class BaasClient {
25093
25144
  private readonly allowInsecure;
25094
25145
  private readonly http;
25095
25146
  private lastHttpError?;
25147
+ private authContext?;
25096
25148
  readonly db: DatabaseClient;
25097
25149
  readonly storage: StorageClient;
25098
25150
  readonly functions: FunctionsClient;
@@ -25114,6 +25166,7 @@ export declare class BaasClient {
25114
25166
  };
25115
25167
  private requireAppId;
25116
25168
  authenticate(options: AuthenticateOptions): Promise<BaasAuthResult>;
25169
+ private reauthenticate;
25117
25170
  validateSession(): Promise<BaasSessionInfo>;
25118
25171
  logout(): Promise<void>;
25119
25172
  private requireAuth;
@@ -25216,7 +25269,7 @@ export type VerifyResult = {
25216
25269
  readonly thresholdMet?: boolean;
25217
25270
  };
25218
25271
  export declare function verifyPqcAttestation(cert: unknown, payload: unknown, registrySnapshot?: ValidatorRegistrySnapshot): Promise<VerifyResult>;
25219
- export type EnvelopeVersionLiteral = "kyber-aes-v1" | "aes-v0";
25272
+ export type EnvelopeVersionLiteral = "kyber-aes-v1";
25220
25273
  export type SchemaValidationResult = {
25221
25274
  ok: true;
25222
25275
  version: EnvelopeVersionLiteral;
@@ -25286,6 +25339,9 @@ declare namespace chains {
25286
25339
  declare namespace subscription {
25287
25340
  export { ActiveSubscriptionForWalletResponse, BalanceResponse, CancelTierChangeRequest, CancelTierChangeResponse, DepositWalletStatus, DowngradeSubscriptionRequest, DowngradeSubscriptionResponse, GetBillingOptions, MintCustomerSubscriptionRequest, MintCustomerSubscriptionResponse, MintNftResponse, PendingTierChange, SubscriptionBillingLedgerEntry, SubscriptionBillingResponse, SubscriptionClient, SubscriptionConfig, SubscriptionListResponse, SubscriptionRenewalRequest, SubscriptionRenewalResponse, SubscriptionRequest, SubscriptionResponse, SubscriptionStatus, SubscriptionStatusResponse, SubscriptionTierInfo, SubscriptionTierName, SubscriptionUsageStatusResponse, SubscriptionUsageSummaryResponse, UpgradeSubscriptionRequest, UpgradeSubscriptionResponse };
25288
25341
  }
25342
+ declare namespace faucet {
25343
+ export { FaucetChallenge, FaucetClient, FaucetDispenseRequest, FaucetDispenseResult, FaucetDispensed, FaucetRateLimited, FaucetStatusResponse, FaucetTrustlineRequired };
25344
+ }
25289
25345
  declare namespace bridge {
25290
25346
  export { BridgeChain, BridgeClaimRecord, BridgeClaimStatus, BridgeClient, BridgeConfig, BridgeDestinationConfig, BridgeDirection, BridgeGenesisBinding, BridgeMode, BridgeOperationConfig, BridgeRulesConfig, BridgeSourceConfig, BridgeStatus, BridgeSupply, BridgeTrustLevel, CreateBridgeRequest, CreateBridgeResponse, ListBridgesOptions, ListBridgesResponse, ListClaimsOptions, ListClaimsResponse, PortRequest, PortResult, ReturnRequest };
25291
25347
  }
@@ -25330,6 +25386,7 @@ export {
25330
25386
  dao,
25331
25387
  discovery,
25332
25388
  envelope,
25389
+ faucet,
25333
25390
  governance,
25334
25391
  operator,
25335
25392
  personhood,