export type LocalePolicyTab = {addressFormat?: string | undefined, calendarType?: string | undefined, cultureName?: string | undefined, currencyCode?: string | undefined, currencyNegativeFormat?: string | undefined, currencyPositiveFormat?: string | undefined, customDateFormat?: string | undefined, customTimeFormat?: string | undefined, dateFormat?: string | undefined, initialFormat?: string | undefined, nameFormat?: string | undefined, timeFormat?: string | undefined, timeZone?: string | undefined, useLongCurrencyFormat?: string | undefined}; export type PropertyMetadata = {options?: Array | undefined, rights?: string | undefined}; export type PathExtendedElement = {name?: string | undefined, type?: string | undefined, typeName?: string | undefined}; export type MergeField = {allowSenderToEdit?: string | undefined, allowSenderToEditMetadata?: PropertyMetadata | undefined, configurationType?: string | undefined, configurationTypeMetadata?: PropertyMetadata | undefined, path?: string | undefined, pathExtended?: Array | undefined, pathExtendedMetadata?: PropertyMetadata | undefined, pathMetadata?: PropertyMetadata | undefined, row?: string | undefined, rowMetadata?: PropertyMetadata | undefined, writeBack?: string | undefined, writeBackMetadata?: PropertyMetadata | undefined}; export type TabMetadata = {anchor?: string | undefined, anchorCaseSensitive?: string | undefined, anchorHorizontalAlignment?: string | undefined, anchorIgnoreIfNotPresent?: string | undefined, anchorMatchWholeWord?: string | undefined, anchorUnits?: string | undefined, anchorXOffset?: string | undefined, anchorYOffset?: string | undefined, bold?: string | undefined, collaborative?: string | undefined, concealValueOnDocument?: string | undefined, createdByDisplayName?: string | undefined, createdByUserId?: string | undefined, customTabId?: string | undefined, disableAutoSize?: string | undefined, editable?: string | undefined, font?: string | undefined, fontColor?: string | undefined, fontSize?: string | undefined, height?: string | undefined, includedInEmail?: string | undefined, initialValue?: string | undefined, italic?: string | undefined, items?: Array | undefined, lastModified?: string | undefined, lastModifiedByDisplayName?: string | undefined, lastModifiedByUserId?: string | undefined, localePolicy?: LocalePolicyTab | undefined, locked?: string | undefined, maximumLength?: string | undefined, maxNumericalValue?: string | undefined, mergeField?: MergeField | undefined, minNumericalValue?: string | undefined, name?: string | undefined, numericalValue?: string | undefined, paymentItemCode?: string | undefined, paymentItemDescription?: string | undefined, paymentItemName?: string | undefined, requireAll?: string | undefined, required?: string | undefined, requireInitialOnSharedChange?: string | undefined, scaleValue?: string | undefined, selected?: string | undefined, shared?: string | undefined, signatureProviderId?: string | undefined, stampType?: string | undefined, stampTypeMetadata?: PropertyMetadata | undefined, tabLabel?: string | undefined, type?: string | undefined, underline?: string | undefined, validationMessage?: string | undefined, validationPattern?: string | undefined, validationType?: string | undefined, width?: string | undefined}; export type UpdateApiV21AccountsAccountIdTabDefinitionsCustomTabIdArgs = {accountId: string, customTabId: string, body: TabMetadata}; export type UpdateApiV21AccountsAccountIdTabDefinitionsCustomTabIdOptions = {baseUrl?: string | undefined, fetch?: typeof fetch | undefined}; /** * Updates custom tab information. * * * * PUT /v2.1/accounts/{accountId}/tab_definitions/{customTabId} */ export const updateApiV21AccountsAccountIdTabDefinitionsCustomTabId = async (args: UpdateApiV21AccountsAccountIdTabDefinitionsCustomTabIdArgs, options?: UpdateApiV21AccountsAccountIdTabDefinitionsCustomTabIdOptions) => { const {baseUrl = "https://www.docusign.net/restapi", fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() headers.set('content-type', "application/json") headers.set('accept', "*/*") const url = `${baseUrl.replace(/\/+$/, '')}/v2.1/accounts/${encodeURIComponent(String(args.accountId))}/tab_definitions/${encodeURIComponent(String(args.customTabId))}${query.size > 0 ? `?${query}` : ''}` const res = await fetchFn(url, {method: "PUT", headers, body: JSON.stringify(args.body)}) if (!res.ok) throw new Error(`Request failed with status ${res.status}`, {cause: {status: res.status, body: await res.text()}}) return res.blob() };