Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

modern-treasury

Package Overview
Dependencies
Maintainers
0
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

modern-treasury - npm Package Compare versions

Comparing version 2.30.0 to 2.31.0

internal/qs/formats.d.ts

2

_shims/node-types.d.ts

@@ -10,3 +10,3 @@ /**

export { type ReadStream as FsReadStream } from 'node:fs';
export { ReadableStream } from 'web-streams-polyfill';
export { ReadableStream } from 'node:stream/web';

@@ -13,0 +13,0 @@ export const fetch: typeof nf.default;

@@ -100,3 +100,5 @@

private calculateContentLength;
buildRequest<Req>(options: FinalRequestOptions<Req>): {
buildRequest<Req>(options: FinalRequestOptions<Req>, { retryCount }?: {
retryCount?: number;
}): {
req: RequestInit;

@@ -234,3 +236,4 @@ url: string;

export declare const isHeadersProtocol: (headers: any) => headers is HeadersProtocol;
export declare const getRequiredHeader: (headers: HeadersLike, header: string) => string;
export declare const getRequiredHeader: (headers: HeadersLike | Headers, header: string) => string;
export declare const getHeader: (headers: HeadersLike | Headers, header: string) => string | undefined;
/**

@@ -237,0 +240,0 @@ * Encodes a string to Base64 format.

@@ -15,3 +15,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.isObj = exports.toBase64 = exports.getRequiredHeader = exports.isHeadersProtocol = exports.isRunningInBrowser = exports.debug = exports.hasOwn = exports.isEmptyObj = exports.maybeCoerceBoolean = exports.maybeCoerceFloat = exports.maybeCoerceInteger = exports.coerceBoolean = exports.coerceFloat = exports.coerceInteger = exports.readEnv = exports.ensurePresent = exports.castToError = exports.sleep = exports.safeJSON = exports.isRequestOptions = exports.createResponseHeaders = exports.PagePromise = exports.AbstractPage = exports.APIClient = exports.APIPromise = exports.createForm = exports.multipartFormRequestOptions = exports.maybeMultipartFormRequestOptions = void 0;
exports.isObj = exports.toBase64 = exports.getHeader = exports.getRequiredHeader = exports.isHeadersProtocol = exports.isRunningInBrowser = exports.debug = exports.hasOwn = exports.isEmptyObj = exports.maybeCoerceBoolean = exports.maybeCoerceFloat = exports.maybeCoerceInteger = exports.coerceBoolean = exports.coerceFloat = exports.coerceInteger = exports.readEnv = exports.ensurePresent = exports.castToError = exports.sleep = exports.safeJSON = exports.isRequestOptions = exports.createResponseHeaders = exports.PagePromise = exports.AbstractPage = exports.APIClient = exports.APIPromise = exports.createForm = exports.multipartFormRequestOptions = exports.maybeMultipartFormRequestOptions = void 0;
const version_1 = require("./version.js");

@@ -194,3 +194,3 @@ const error_1 = require("./error.js");

}
buildRequest(options) {
buildRequest(options, { retryCount = 0 } = {}) {
const { method, path, query, headers: headers = {} } = options;

@@ -222,3 +222,3 @@ const body = ArrayBuffer.isView(options.body) || (options.__binaryRequest && typeof options.body === 'string') ?

}
const reqHeaders = this.buildHeaders({ options, headers, contentLength });
const reqHeaders = this.buildHeaders({ options, headers, contentLength, retryCount });
const req = {

@@ -235,3 +235,3 @@ method,

}
buildHeaders({ options, headers, contentLength, }) {
buildHeaders({ options, headers, contentLength, retryCount, }) {
const reqHeaders = {};

@@ -248,2 +248,7 @@ if (contentLength) {

}
// Don't set the retry count header if it was already set or removed by the caller. We check `headers`,
// which can contain nulls, instead of `reqHeaders` to account for the removal case.
if ((0, exports.getHeader)(headers, 'x-stainless-retry-count') === undefined) {
reqHeaders['x-stainless-retry-count'] = String(retryCount);
}
this.validateHeaders(reqHeaders, headers);

@@ -277,7 +282,8 @@ return reqHeaders;

const options = await optionsInput;
const maxRetries = options.maxRetries ?? this.maxRetries;
if (retriesRemaining == null) {
retriesRemaining = options.maxRetries ?? this.maxRetries;
retriesRemaining = maxRetries;
}
await this.prepareOptions(options);
const { req, url, timeout } = this.buildRequest(options);
const { req, url, timeout } = this.buildRequest(options, { retryCount: maxRetries - retriesRemaining });
await this.prepareRequest(req, { url, options });

@@ -848,2 +854,10 @@ debug('request', url, options, req.headers);

const getRequiredHeader = (headers, header) => {
const foundHeader = (0, exports.getHeader)(headers, header);
if (foundHeader === undefined) {
throw new Error(`Could not find ${header} header`);
}
return foundHeader;
};
exports.getRequiredHeader = getRequiredHeader;
const getHeader = (headers, header) => {
const lowerCasedHeader = header.toLowerCase();

@@ -872,5 +886,5 @@ if ((0, exports.isHeadersProtocol)(headers)) {

}
throw new Error(`Could not find ${header} header`);
return undefined;
};
exports.getRequiredHeader = getRequiredHeader;
exports.getHeader = getHeader;
/**

@@ -877,0 +891,0 @@ * Encodes a string to Base64 format.

@@ -31,3 +31,3 @@ "use strict";

const Uploads = __importStar(require("./uploads.js"));
const qs = __importStar(require("qs"));
const qs = __importStar(require("./internal/qs/index.js"));
const Core = __importStar(require("./core.js"));

@@ -34,0 +34,0 @@ const Pagination = __importStar(require("./pagination.js"));

{
"name": "modern-treasury",
"version": "2.30.0",
"version": "2.31.0",
"description": "The official TypeScript library for the Modern Treasury API",

@@ -27,3 +27,2 @@ "author": "Modern Treasury <sdk-feedback@moderntreasury.com>",

"@types/node-fetch": "^2.6.4",
"@types/qs": "^6.9.15",
"abort-controller": "^3.0.0",

@@ -33,4 +32,3 @@ "agentkeepalive": "^4.2.1",

"formdata-node": "^4.3.2",
"node-fetch": "^2.6.7",
"qs": "^6.10.3"
"node-fetch": "^2.6.7"
},

@@ -37,0 +35,0 @@ "sideEffects": [

@@ -126,3 +126,3 @@ import { APIResource } from "../resource.js";

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -168,3 +168,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -248,3 +248,3 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -290,3 +290,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -293,0 +293,0 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

@@ -438,3 +438,3 @@ import { APIResource } from "../resource.js";

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -480,3 +480,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -560,3 +560,3 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -602,3 +602,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -605,0 +605,0 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

@@ -107,3 +107,3 @@ import { APIResource } from "../../resource.js";

*/
metadata: Record<string, string>;
metadata: Record<string, string> | null;
/**

@@ -290,2 +290,8 @@ * Emails in addition to the counterparty email to send invoice status

/**
* When true, the invoice will progress to unpaid automatically and cannot be
* edited after entering that state. If the invoice fails to progress to unpaid,
* the errors will be returned and the invoice will not be created.
*/
auto_advance?: boolean | null;
/**
* The invoicer's contact details displayed at the top of the invoice.

@@ -336,2 +342,7 @@ */

/**
* Additional data represented as key-value pairs. Both the key and value must be
* strings.
*/
metadata?: Record<string, string> | null;
/**
* Emails in addition to the counterparty email to send invoice status

@@ -569,2 +580,7 @@ * notifications to. At least one email is required if notifications are enabled

/**
* Additional data represented as key-value pairs. Both the key and value must be
* strings.
*/
metadata?: Record<string, string> | null;
/**
* Emails in addition to the counterparty email to send invoice status

@@ -571,0 +587,0 @@ * notifications to. At least one email is required if notifications are enabled

@@ -90,3 +90,3 @@ import { APIResource } from "../resource.js";

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -142,3 +142,3 @@ risk_rating: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -217,3 +217,3 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -259,3 +259,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -339,3 +339,3 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -381,3 +381,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -441,3 +441,3 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -444,0 +444,0 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

@@ -102,3 +102,3 @@ import { APIResource } from "../resource.js";

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -154,3 +154,3 @@ risk_rating: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -254,3 +254,3 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -296,3 +296,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

*/
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
id_type: 'ar_cuil' | 'ar_cuit' | 'br_cnpj' | 'br_cpf' | 'cl_run' | 'cl_rut' | 'co_cedulas' | 'co_nit' | 'hn_id' | 'hn_rtn' | 'in_lei' | 'kr_brn' | 'kr_crn' | 'kr_rrn' | 'passport' | 'sa_tin' | 'sa_vat' | 'us_ein' | 'us_itin' | 'us_ssn' | 'vn_tin';
/**

@@ -299,0 +299,0 @@ * The ISO 3166-1 alpha-2 country code of the country that issued the

@@ -38,3 +38,3 @@ import { APIResource } from "../resource.js";

*/
reference_number_type: 'ach_original_trace_number' | 'ach_trace_number' | 'bankprov_payment_activity_date' | 'bankprov_payment_id' | 'bnk_dev_prenotification_id' | 'bnk_dev_transfer_id' | 'bofa_end_to_end_id' | 'bofa_transaction_id' | 'check_number' | 'citibank_reference_number' | 'citibank_worldlink_clearing_system_reference_number' | 'column_fx_quote_id' | 'column_reversal_pair_transfer_id' | 'column_transfer_id' | 'cross_river_payment_id' | 'cross_river_service_message' | 'cross_river_transaction_id' | 'currencycloud_conversion_id' | 'currencycloud_payment_id' | 'dc_bank_transaction_id' | 'dwolla_transaction_id' | 'eft_trace_number' | 'evolve_transaction_id' | 'fedwire_imad' | 'fedwire_omad' | 'first_republic_internal_id' | 'goldman_sachs_collection_request_id' | 'goldman_sachs_end_to_end_id' | 'goldman_sachs_payment_request_id' | 'goldman_sachs_request_id' | 'goldman_sachs_unique_payment_id' | 'interac_message_id' | 'jpmc_ccn' | 'jpmc_clearing_system_reference' | 'jpmc_customer_reference_id' | 'jpmc_end_to_end_id' | 'jpmc_firm_root_id' | 'jpmc_fx_trn_id' | 'jpmc_p3_id' | 'jpmc_payment_batch_id' | 'jpmc_payment_information_id' | 'jpmc_payment_returned_datetime' | 'lob_check_id' | 'other' | 'partial_swift_mir' | 'pnc_clearing_reference' | 'pnc_instruction_id' | 'pnc_multipayment_id' | 'pnc_payment_trace_id' | 'rspec_vendor_payment_id' | 'rtp_instruction_id' | 'signet_api_reference_id' | 'signet_confirmation_id' | 'signet_request_id' | 'silvergate_payment_id' | 'svb_end_to_end_id' | 'svb_payment_id' | 'svb_transaction_cleared_for_sanctions_review' | 'svb_transaction_held_for_sanctions_review' | 'swift_mir' | 'swift_uetr' | 'umb_product_partner_account_number' | 'usbank_payment_id' | 'usbank_pending_rtp_payment_id' | 'usbank_posted_rtp_payment_id' | 'wells_fargo_end_to_end_id' | 'wells_fargo_payment_id' | 'wells_fargo_trace_number' | 'wells_fargo_uetr';
reference_number_type: 'ach_original_trace_number' | 'ach_trace_number' | 'bankprov_payment_activity_date' | 'bankprov_payment_id' | 'bnk_dev_prenotification_id' | 'bnk_dev_transfer_id' | 'bofa_end_to_end_id' | 'bofa_transaction_id' | 'check_number' | 'citibank_reference_number' | 'citibank_worldlink_clearing_system_reference_number' | 'column_fx_quote_id' | 'column_reversal_pair_transfer_id' | 'column_transfer_id' | 'cross_river_payment_id' | 'cross_river_service_message' | 'cross_river_transaction_id' | 'currencycloud_conversion_id' | 'currencycloud_payment_id' | 'dc_bank_transaction_id' | 'dwolla_transaction_id' | 'eft_trace_number' | 'evolve_transaction_id' | 'fedwire_imad' | 'fedwire_omad' | 'first_republic_internal_id' | 'goldman_sachs_collection_request_id' | 'goldman_sachs_end_to_end_id' | 'goldman_sachs_payment_request_id' | 'goldman_sachs_request_id' | 'goldman_sachs_unique_payment_id' | 'interac_message_id' | 'jpmc_ccn' | 'jpmc_clearing_system_reference' | 'jpmc_customer_reference_id' | 'jpmc_end_to_end_id' | 'jpmc_firm_root_id' | 'jpmc_fx_trn_id' | 'jpmc_p3_id' | 'jpmc_payment_batch_id' | 'jpmc_payment_information_id' | 'jpmc_payment_returned_datetime' | 'lob_check_id' | 'other' | 'partial_swift_mir' | 'pnc_clearing_reference' | 'pnc_instruction_id' | 'pnc_multipayment_id' | 'pnc_payment_trace_id' | 'rspec_vendor_payment_id' | 'rtp_instruction_id' | 'signet_api_reference_id' | 'signet_confirmation_id' | 'signet_request_id' | 'silvergate_payment_id' | 'svb_end_to_end_id' | 'svb_payment_id' | 'svb_transaction_cleared_for_sanctions_review' | 'svb_transaction_held_for_sanctions_review' | 'swift_mir' | 'swift_uetr' | 'umb_product_partner_account_number' | 'usbank_payment_application_reference_id' | 'usbank_payment_id' | 'usbank_pending_rtp_payment_id' | 'usbank_posted_rtp_payment_id' | 'wells_fargo_end_to_end_id' | 'wells_fargo_payment_id' | 'wells_fargo_trace_number' | 'wells_fargo_uetr';
/**

@@ -41,0 +41,0 @@ * The id of the referenceable to search for. Must be accompanied by the

@@ -130,3 +130,3 @@ import { APIResource } from "../resource.js";

*/
reference_number_type: 'ach_original_trace_number' | 'ach_trace_number' | 'bankprov_payment_activity_date' | 'bankprov_payment_id' | 'bnk_dev_prenotification_id' | 'bnk_dev_transfer_id' | 'bofa_end_to_end_id' | 'bofa_transaction_id' | 'check_number' | 'citibank_reference_number' | 'citibank_worldlink_clearing_system_reference_number' | 'column_fx_quote_id' | 'column_reversal_pair_transfer_id' | 'column_transfer_id' | 'cross_river_payment_id' | 'cross_river_service_message' | 'cross_river_transaction_id' | 'currencycloud_conversion_id' | 'currencycloud_payment_id' | 'dc_bank_transaction_id' | 'dwolla_transaction_id' | 'eft_trace_number' | 'evolve_transaction_id' | 'fedwire_imad' | 'fedwire_omad' | 'first_republic_internal_id' | 'goldman_sachs_collection_request_id' | 'goldman_sachs_end_to_end_id' | 'goldman_sachs_payment_request_id' | 'goldman_sachs_request_id' | 'goldman_sachs_unique_payment_id' | 'interac_message_id' | 'jpmc_ccn' | 'jpmc_clearing_system_reference' | 'jpmc_customer_reference_id' | 'jpmc_end_to_end_id' | 'jpmc_firm_root_id' | 'jpmc_fx_trn_id' | 'jpmc_p3_id' | 'jpmc_payment_batch_id' | 'jpmc_payment_information_id' | 'jpmc_payment_returned_datetime' | 'lob_check_id' | 'other' | 'partial_swift_mir' | 'pnc_clearing_reference' | 'pnc_instruction_id' | 'pnc_multipayment_id' | 'pnc_payment_trace_id' | 'rspec_vendor_payment_id' | 'rtp_instruction_id' | 'signet_api_reference_id' | 'signet_confirmation_id' | 'signet_request_id' | 'silvergate_payment_id' | 'svb_end_to_end_id' | 'svb_payment_id' | 'svb_transaction_cleared_for_sanctions_review' | 'svb_transaction_held_for_sanctions_review' | 'swift_mir' | 'swift_uetr' | 'umb_product_partner_account_number' | 'usbank_payment_id' | 'usbank_pending_rtp_payment_id' | 'usbank_posted_rtp_payment_id' | 'wells_fargo_end_to_end_id' | 'wells_fargo_payment_id' | 'wells_fargo_trace_number' | 'wells_fargo_uetr';
reference_number_type: 'ach_original_trace_number' | 'ach_trace_number' | 'bankprov_payment_activity_date' | 'bankprov_payment_id' | 'bnk_dev_prenotification_id' | 'bnk_dev_transfer_id' | 'bofa_end_to_end_id' | 'bofa_transaction_id' | 'check_number' | 'citibank_reference_number' | 'citibank_worldlink_clearing_system_reference_number' | 'column_fx_quote_id' | 'column_reversal_pair_transfer_id' | 'column_transfer_id' | 'cross_river_payment_id' | 'cross_river_service_message' | 'cross_river_transaction_id' | 'currencycloud_conversion_id' | 'currencycloud_payment_id' | 'dc_bank_transaction_id' | 'dwolla_transaction_id' | 'eft_trace_number' | 'evolve_transaction_id' | 'fedwire_imad' | 'fedwire_omad' | 'first_republic_internal_id' | 'goldman_sachs_collection_request_id' | 'goldman_sachs_end_to_end_id' | 'goldman_sachs_payment_request_id' | 'goldman_sachs_request_id' | 'goldman_sachs_unique_payment_id' | 'interac_message_id' | 'jpmc_ccn' | 'jpmc_clearing_system_reference' | 'jpmc_customer_reference_id' | 'jpmc_end_to_end_id' | 'jpmc_firm_root_id' | 'jpmc_fx_trn_id' | 'jpmc_p3_id' | 'jpmc_payment_batch_id' | 'jpmc_payment_information_id' | 'jpmc_payment_returned_datetime' | 'lob_check_id' | 'other' | 'partial_swift_mir' | 'pnc_clearing_reference' | 'pnc_instruction_id' | 'pnc_multipayment_id' | 'pnc_payment_trace_id' | 'rspec_vendor_payment_id' | 'rtp_instruction_id' | 'signet_api_reference_id' | 'signet_confirmation_id' | 'signet_request_id' | 'silvergate_payment_id' | 'svb_end_to_end_id' | 'svb_payment_id' | 'svb_transaction_cleared_for_sanctions_review' | 'svb_transaction_held_for_sanctions_review' | 'swift_mir' | 'swift_uetr' | 'umb_product_partner_account_number' | 'usbank_payment_application_reference_id' | 'usbank_payment_id' | 'usbank_pending_rtp_payment_id' | 'usbank_posted_rtp_payment_id' | 'wells_fargo_end_to_end_id' | 'wells_fargo_payment_id' | 'wells_fargo_trace_number' | 'wells_fargo_uetr';
updated_at: string;

@@ -133,0 +133,0 @@ }

@@ -50,2 +50,7 @@ import { APIResource } from "../../resource.js";

as_of_time: string | null;
/**
* The timezone in which the `as_of_time` is represented. Can be `null` if the bank
* does not provide timezone info.
*/
as_of_timezone: string | null;
created_at: string;

@@ -52,0 +57,0 @@ /**

import * as types from "../_shims/node-types.js";

@@ -5,0 +6,0 @@ declare module '../_shims/manual-types' {

@@ -10,3 +10,3 @@ /**

export { type ReadStream as FsReadStream } from 'node:fs';
export { ReadableStream } from 'web-streams-polyfill';
export { ReadableStream } from 'node:stream/web';

@@ -13,0 +13,0 @@ export const fetch: typeof nf.default;

@@ -277,3 +277,6 @@ import { VERSION } from './version';

buildRequest<Req>(options: FinalRequestOptions<Req>): { req: RequestInit; url: string; timeout: number } {
buildRequest<Req>(
options: FinalRequestOptions<Req>,
{ retryCount = 0 }: { retryCount?: number } = {},
): { req: RequestInit; url: string; timeout: number } {
const { method, path, query, headers: headers = {} } = options;

@@ -310,3 +313,3 @@

const reqHeaders = this.buildHeaders({ options, headers, contentLength });
const reqHeaders = this.buildHeaders({ options, headers, contentLength, retryCount });

@@ -330,2 +333,3 @@ const req: RequestInit = {

contentLength,
retryCount,
}: {

@@ -335,2 +339,3 @@ options: FinalRequestOptions;

contentLength: string | null | undefined;
retryCount: number;
}): Record<string, string> {

@@ -351,2 +356,8 @@ const reqHeaders: Record<string, string> = {};

// Don't set the retry count header if it was already set or removed by the caller. We check `headers`,
// which can contain nulls, instead of `reqHeaders` to account for the removal case.
if (getHeader(headers, 'x-stainless-retry-count') === undefined) {
reqHeaders['x-stainless-retry-count'] = String(retryCount);
}
this.validateHeaders(reqHeaders, headers);

@@ -403,4 +414,5 @@

const options = await optionsInput;
const maxRetries = options.maxRetries ?? this.maxRetries;
if (retriesRemaining == null) {
retriesRemaining = options.maxRetries ?? this.maxRetries;
retriesRemaining = maxRetries;
}

@@ -410,3 +422,3 @@

const { req, url, timeout } = this.buildRequest(options);
const { req, url, timeout } = this.buildRequest(options, { retryCount: maxRetries - retriesRemaining });

@@ -1131,3 +1143,11 @@ await this.prepareRequest(req, { url, options });

export const getRequiredHeader = (headers: HeadersLike, header: string): string => {
export const getRequiredHeader = (headers: HeadersLike | Headers, header: string): string => {
const foundHeader = getHeader(headers, header);
if (foundHeader === undefined) {
throw new Error(`Could not find ${header} header`);
}
return foundHeader;
};
export const getHeader = (headers: HeadersLike | Headers, header: string): string | undefined => {
const lowerCasedHeader = header.toLowerCase();

@@ -1158,3 +1178,3 @@ if (isHeadersProtocol(headers)) {

throw new Error(`Could not find ${header} header`);
return undefined;
};

@@ -1161,0 +1181,0 @@

@@ -6,3 +6,3 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

import { type Agent } from './_shims/index';
import * as qs from 'qs';
import * as qs from './internal/qs';
import * as Core from './core';

@@ -9,0 +9,0 @@ import * as Pagination from './pagination';

@@ -215,3 +215,3 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -272,2 +272,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -394,3 +395,3 @@ | 'co_cedulas'

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -451,2 +452,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -453,0 +455,0 @@ | 'co_cedulas'

@@ -692,3 +692,3 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -749,2 +749,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -871,3 +872,3 @@ | 'co_cedulas'

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -928,2 +929,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -930,0 +932,0 @@ | 'co_cedulas'

@@ -173,3 +173,3 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

*/
metadata: Record<string, string>;
metadata: Record<string, string> | null;

@@ -405,2 +405,9 @@ /**

/**
* When true, the invoice will progress to unpaid automatically and cannot be
* edited after entering that state. If the invoice fails to progress to unpaid,
* the errors will be returned and the invoice will not be created.
*/
auto_advance?: boolean | null;
/**
* The invoicer's contact details displayed at the top of the invoice.

@@ -461,2 +468,8 @@ */

/**
* Additional data represented as key-value pairs. Both the key and value must be
* strings.
*/
metadata?: Record<string, string> | null;
/**
* Emails in addition to the counterparty email to send invoice status

@@ -749,2 +762,8 @@ * notifications to. At least one email is required if notifications are enabled

/**
* Additional data represented as key-value pairs. Both the key and value must be
* strings.
*/
metadata?: Record<string, string> | null;
/**
* Emails in addition to the counterparty email to send invoice status

@@ -751,0 +770,0 @@ * notifications to. At least one email is required if notifications are enabled

@@ -165,3 +165,3 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -241,2 +241,3 @@ risk_rating: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -358,3 +359,3 @@ | 'co_cedulas'

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -415,2 +416,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -537,3 +539,3 @@ | 'co_cedulas'

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -594,2 +596,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -690,3 +693,3 @@ | 'co_cedulas'

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -693,0 +696,0 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

@@ -158,3 +158,3 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -234,2 +234,3 @@ risk_rating: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -381,3 +382,3 @@ | 'co_cedulas'

/**
* Translation missing: en.openapi.descriptions.legal_entity.schema.risk_rating
* The risk rating of the legal entity. One of low, medium, high.
*/

@@ -438,2 +439,3 @@ risk_rating?: 'low' | 'medium' | 'high' | null;

| 'br_cpf'
| 'cl_run'
| 'cl_rut'

@@ -440,0 +442,0 @@ | 'co_cedulas'

@@ -127,2 +127,3 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

| 'umb_product_partner_account_number'
| 'usbank_payment_application_reference_id'
| 'usbank_payment_id'

@@ -129,0 +130,0 @@ | 'usbank_pending_rtp_payment_id'

@@ -322,2 +322,3 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

| 'umb_product_partner_account_number'
| 'usbank_payment_application_reference_id'
| 'usbank_payment_id'

@@ -324,0 +325,0 @@ | 'usbank_pending_rtp_payment_id'

@@ -110,2 +110,8 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

/**
* The timezone in which the `as_of_time` is represented. Can be `null` if the bank
* does not provide timezone info.
*/
as_of_timezone: string | null;
created_at: string;

@@ -112,0 +118,0 @@

@@ -1,1 +0,1 @@

export const VERSION = '2.30.0'; // x-release-please-version
export const VERSION = '2.31.0'; // x-release-please-version

@@ -1,2 +0,2 @@

export declare const VERSION = "2.30.0";
export declare const VERSION = "2.31.0";
//# sourceMappingURL=version.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.VERSION = void 0;
exports.VERSION = '2.30.0'; // x-release-please-version
exports.VERSION = '2.31.0'; // x-release-please-version
//# sourceMappingURL=version.js.map

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc