@marcohefti/request-network-api-client 0.5.5 → 0.5.7

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.
@@ -3656,33 +3656,6 @@ interface RequestClient {
3656
3656
  * ```
3657
3657
  */
3658
3658
  declare function createRequestClient(options?: CreateClientOptions): RequestClient;
3659
- interface EnvOptions {
3660
- env?: NodeJS.ProcessEnv;
3661
- }
3662
- /**
3663
- * Creates a Request Network API client from environment variables.
3664
- *
3665
- * Reads configuration from the following environment variables (in order of preference):
3666
- * - `REQUEST_API_URL` (or legacy `REQUEST_SDK_BASE_URL`)
3667
- * - `REQUEST_API_KEY` (or legacy `REQUEST_SDK_API_KEY`)
3668
- * - `REQUEST_CLIENT_ID` (or legacy `REQUEST_SDK_CLIENT_ID`)
3669
- *
3670
- * @param options - Optional environment override
3671
- * @param options.env - Custom environment object (defaults to process.env)
3672
- *
3673
- * @returns RequestClient instance configured from environment
3674
- *
3675
- * @example
3676
- * ```ts
3677
- * import { createRequestClientFromEnv } from '@marcohefti/request-network-api-client';
3678
- *
3679
- * const client = createRequestClientFromEnv();
3680
- * // Reads REQUEST_API_KEY, REQUEST_CLIENT_ID, REQUEST_API_URL from process.env
3681
- *
3682
- * const tokens = await client.currencies.list({ network: 'sepolia' });
3683
- * ```
3684
- */
3685
- declare function createRequestClientFromEnv(options?: EnvOptions): RequestClient;
3686
3659
 
3687
3660
  declare const RequestEnvironment: {
3688
3661
  readonly production: "https://api.request.network";
@@ -5526,4 +5499,4 @@ declare namespace index {
5526
5499
  export { type index_CreateWebhookMiddlewareOptions as CreateWebhookMiddlewareOptions, index_DEFAULT_SIGNATURE_ALGORITHM as DEFAULT_SIGNATURE_ALGORITHM, index_DEFAULT_SIGNATURE_HEADER as DEFAULT_SIGNATURE_HEADER, type index_GetRawBody as GetRawBody, type index_InferDispatcherPayload as InferDispatcherPayload, type NormalisedHeaders as NormalizedWebhookHeaders, type index_ParseWebhookEventOptions as ParseWebhookEventOptions, type index_ParsedWebhookEvent as ParsedWebhookEvent, index_RequestWebhookSignatureError as RequestWebhookSignatureError, type index_ShouldSkipVerification as ShouldSkipVerification, type index_VerifyWebhookSignatureOptions as VerifyWebhookSignatureOptions, type index_VerifyWebhookSignatureResult as VerifyWebhookSignatureResult, index_WEBHOOK_EVENT_NAMES as WEBHOOK_EVENT_NAMES, type index_WebhookDispatchContext as WebhookDispatchContext, index_WebhookDispatcher as WebhookDispatcher, type index_WebhookEventName as WebhookEventName, type index_WebhookHandler as WebhookHandler, type index_WebhookHeaders as WebhookHeaders, type index_WebhookLogger as WebhookLogger, type index_WebhookPayload as WebhookPayload, type index_WebhookPayloadMap as WebhookPayloadMap, type index_WebhookRequest as WebhookRequest, type index_WebhookSignatureErrorReason as WebhookSignatureErrorReason, index_createWebhookDispatcher as createWebhookDispatcher, index_createWebhookMiddleware as createWebhookMiddleware, index$1 as events, index_getWebhookSchema as getWebhookSchema, index_isRequestWebhookSignatureError as isRequestWebhookSignatureError, index_parseWebhookEvent as parseWebhookEvent, testing_webhook as testing, index_verifyWebhookSignature as verifyWebhookSignature };
5527
5500
  }
5528
5501
 
5529
- export { type BuildRequestApiErrorOptions, type CreateClientOptions, HttpAdapter, HttpClient, Interceptor, type ParseRegistryOptions, type ParseResult, type ParseWithSchemaOptions, RequestApiError, type RequestClient, RequestEnvironment, type RequestEnvironmentName, type RequestErrorDetail, type RequestErrorMetadata, RequestOptions, RetryConfig, RuntimeValidationOption, type SchemaKey, type SchemaKind, type SchemaOutput, SchemaRegistry, ValidationError, browserFetchAdapter, buildRequestApiError, createHttpClient, createRequestClient, createRequestClientFromEnv, index$8 as currenciesV1, isRequestApiError, nodeFetchAdapter, parseWithRegistry, parseWithSchema, index$6 as pay, index$7 as payV1, index$5 as payerV1, index$4 as payerV2, index$3 as payments, index$2 as requestsV1, schemaRegistry, index as webhooks };
5502
+ export { type BuildRequestApiErrorOptions, type CreateClientOptions, HttpAdapter, HttpClient, Interceptor, type ParseRegistryOptions, type ParseResult, type ParseWithSchemaOptions, RequestApiError, type RequestClient, RequestEnvironment, type RequestEnvironmentName, type RequestErrorDetail, type RequestErrorMetadata, RequestOptions, RetryConfig, RuntimeValidationOption, type SchemaKey, type SchemaKind, type SchemaOutput, SchemaRegistry, ValidationError, browserFetchAdapter, buildRequestApiError, createHttpClient, createRequestClient, index$8 as currenciesV1, isRequestApiError, nodeFetchAdapter, parseWithRegistry, parseWithSchema, index$6 as pay, index$7 as payV1, index$5 as payerV1, index$4 as payerV2, index$3 as payments, index$2 as requestsV1, schemaRegistry, index as webhooks };
package/dist/esm/index.js CHANGED
@@ -2308,13 +2308,6 @@ function createRequestClient(options) {
2308
2308
  pay: createPayApi(http)
2309
2309
  };
2310
2310
  }
2311
- function createRequestClientFromEnv(options) {
2312
- const env = options?.env ?? process.env;
2313
- const baseUrl = env.REQUEST_API_URL ?? env.REQUEST_SDK_BASE_URL;
2314
- const apiKey = env.REQUEST_API_KEY ?? env.REQUEST_SDK_API_KEY;
2315
- const clientId = env.REQUEST_CLIENT_ID ?? env.REQUEST_SDK_CLIENT_ID;
2316
- return createRequestClient({ baseUrl, apiKey, clientId });
2317
- }
2318
2311
 
2319
2312
  // src/core/config/request-environment.config.ts
2320
2313
  var RequestEnvironment = {
@@ -3430,6 +3423,6 @@ function assertRequestRecurringEvent(event) {
3430
3423
  }
3431
3424
  }
3432
3425
 
3433
- export { DEFAULT_RETRY_CONFIG, RequestApiError, RequestEnvironment, SchemaRegistry, ValidationError, browserFetchAdapter, buildRequestApiError, client_ids_exports as clientIds, computeRetryDelay, createHttpClient, createRequestClient, createRequestClientFromEnv, currencies_exports as currencies, v1_exports as currenciesV1, isRequestApiError, nodeFetchAdapter, parseWithRegistry, parseWithSchema, pay_exports as pay, v1_exports2 as payV1, payer_exports as payer, v1_exports3 as payerV1, v2_exports as payerV2, payments_exports as payments, payouts_exports as payouts, requests_exports as requests, v1_exports4 as requestsV1, schemaRegistry, shouldRetryRequest, webhooks_exports as webhooks };
3426
+ export { DEFAULT_RETRY_CONFIG, RequestApiError, RequestEnvironment, SchemaRegistry, ValidationError, browserFetchAdapter, buildRequestApiError, client_ids_exports as clientIds, computeRetryDelay, createHttpClient, createRequestClient, currencies_exports as currencies, v1_exports as currenciesV1, isRequestApiError, nodeFetchAdapter, parseWithRegistry, parseWithSchema, pay_exports as pay, v1_exports2 as payV1, payer_exports as payer, v1_exports3 as payerV1, v2_exports as payerV2, payments_exports as payments, payouts_exports as payouts, requests_exports as requests, v1_exports4 as requestsV1, schemaRegistry, shouldRetryRequest, webhooks_exports as webhooks };
3434
3427
  //# sourceMappingURL=index.js.map
3435
3428
  //# sourceMappingURL=index.js.map