QuickBase JS SDK v2 - v2.2.2
    Preparing search index...

    Interface QuickbaseClient

    QuickBase client with typed API methods

    interface QuickbaseClient {
        getAuthStrategy: () => AuthStrategy;
        getConfig: () => ResolvedConfig;
        request: <T = unknown>(
            options: {
                body?: unknown;
                dbid?: string;
                method: "GET" | "POST" | "PUT" | "DELETE" | "PATCH";
                path: string;
                query?: Record<string, string | number | boolean | undefined>;
            },
        ) => Promise<T>;
        addManagersToGroup(
            params: AddManagersToGroupParams,
            body: AddManagersToGroupRequest,
        ): Promise<AddManagersToGroupResponse>;
        addMembersToGroup(
            params: AddMembersToGroupParams,
            body: AddMembersToGroupRequest,
        ): Promise<AddMembersToGroupResponse>;
        addSubgroupsToGroup(
            params: AddSubgroupsToGroupParams,
            body: AddSubgroupsToGroupRequest,
        ): Promise<AddSubgroupsToGroupResponse>;
        audit(body: AuditRequest): Promise<AuditResponse>;
        changesetSolution(
            params: ChangesetSolutionParams,
            body: unknown,
        ): Promise<unknown>;
        changesetSolutionFromRecord(
            params: ChangesetSolutionFromRecordParams,
        ): Promise<unknown>;
        cloneUserToken(
            body: CloneUserTokenRequest,
        ): Promise<CloneUserTokenResponse>;
        copyApp(
            params: CopyAppParams,
            body: CopyAppRequest,
        ): Promise<CopyAppResponse>;
        createApp(body: CreateAppRequest): Promise<CreateAppResponse>;
        createField(
            params: CreateFieldParams,
            body: CreateFieldRequest,
        ): Promise<CreateFieldResponse>;
        createRelationship(
            params: CreateRelationshipParams,
            body: CreateRelationshipRequest,
        ): Promise<CreateRelationshipResponse>;
        createSolution(body: unknown): Promise<unknown>;
        createSolutionFromRecord(
            params: CreateSolutionFromRecordParams,
        ): Promise<unknown>;
        createTable(
            params: CreateTableParams,
            body: CreateTableRequest,
        ): Promise<CreateTableResponse>;
        deactivateUserToken(): Promise<DeactivateUserTokenResponse>;
        deleteApp(
            params: DeleteAppParams,
            body: DeleteAppRequest,
        ): Promise<DeleteAppResponse>;
        deleteFields(
            params: DeleteFieldsParams,
            body: DeleteFieldsRequest,
        ): Promise<DeleteFieldsResponse>;
        deleteFile(params: DeleteFileParams): Promise<DeleteFileResponse>;
        deleteRecords(body: DeleteRecordsRequest): Promise<DeleteRecordsResponse>;
        deleteRelationship(
            params: DeleteRelationshipParams,
        ): Promise<DeleteRelationshipResponse>;
        deleteTable(params: DeleteTableParams): Promise<DeleteTableResponse>;
        deleteUserToken(): Promise<DeleteUserTokenResponse>;
        denyUsers(
            params: DenyUsersParams,
            body: DenyUsersRequest,
        ): Promise<DenyUsersResponse>;
        denyUsersAndGroups(
            params: DenyUsersAndGroupsParams,
            body: DenyUsersAndGroupsRequest,
        ): Promise<DenyUsersAndGroupsResponse>;
        downloadFile(params: DownloadFileParams): Promise<unknown>;
        exchangeSsoToken(
            body: ExchangeSsoTokenRequest,
        ): Promise<ExchangeSsoTokenResponse>;
        exportSolution(params: ExportSolutionParams): Promise<unknown>;
        exportSolutionToRecord(
            params: ExportSolutionToRecordParams,
        ): Promise<unknown>;
        generateDocument(
            params: GenerateDocumentParams,
        ): Promise<GenerateDocumentResponse>;
        getApp(params: GetAppParams): Promise<GetAppResponse>;
        getAppEvents(params: GetAppEventsParams): Promise<GetAppEventsResponse>;
        getAppTables(params: GetAppTablesParams): Promise<GetAppTablesResponse>;
        getField(params: GetFieldParams): Promise<GetFieldResponse>;
        getFields(params: GetFieldsParams): Promise<GetFieldsResponse>;
        getFieldsUsage(
            params: GetFieldsUsageParams,
        ): Promise<GetFieldsUsageResponse>;
        getFieldUsage(params: GetFieldUsageParams): Promise<GetFieldUsageResponse>;
        getRelationships(
            params: GetRelationshipsParams,
        ): PaginatedRequest<GetRelationshipsResponse>;
        getReport(params: GetReportParams): Promise<GetReportResponse>;
        getTable(params: GetTableParams): Promise<GetTableResponse>;
        getTableReports(
            params: GetTableReportsParams,
        ): Promise<GetTableReportsResponse>;
        getTempTokenDBID(
            params: GetTempTokenDBIDParams,
        ): Promise<GetTempTokenDBIDResponse>;
        getUsers(
            params: GetUsersParams,
            body?: GetUsersRequest,
        ): PaginatedRequest<GetUsersResponse>;
        platformAnalyticEventSummaries(
            params: PlatformAnalyticEventSummariesParams,
            body?: PlatformAnalyticEventSummariesRequest,
        ): PaginatedRequest<PlatformAnalyticEventSummariesResponse>;
        platformAnalyticReads(
            params: PlatformAnalyticReadsParams,
        ): Promise<PlatformAnalyticReadsResponse>;
        removeManagersFromGroup(
            params: RemoveManagersFromGroupParams,
            body: RemoveManagersFromGroupRequest,
        ): Promise<RemoveManagersFromGroupResponse>;
        removeMembersFromGroup(
            params: RemoveMembersFromGroupParams,
            body: RemoveMembersFromGroupRequest,
        ): Promise<RemoveMembersFromGroupResponse>;
        removeSubgroupsFromGroup(
            params: RemoveSubgroupsFromGroupParams,
            body: RemoveSubgroupsFromGroupRequest,
        ): Promise<RemoveSubgroupsFromGroupResponse>;
        runFormula(body: RunFormulaRequest): Promise<RunFormulaResponse>;
        runQuery(body: RunQueryRequest): PaginatedRequest<RunQueryResponse>;
        runReport(
            params: RunReportParams,
            body?: unknown,
        ): PaginatedRequest<RunReportResponse>;
        transferUserToken(
            body: TransferUserTokenRequest,
        ): Promise<TransferUserTokenResponse>;
        undenyUsers(
            params: UndenyUsersParams,
            body: UndenyUsersRequest,
        ): Promise<UndenyUsersResponse>;
        updateApp(
            params: UpdateAppParams,
            body?: UpdateAppRequest,
        ): Promise<UpdateAppResponse>;
        updateField(
            params: UpdateFieldParams,
            body?: UpdateFieldRequest,
        ): Promise<UpdateFieldResponse>;
        updateRelationship(
            params: UpdateRelationshipParams,
            body?: UpdateRelationshipRequest,
        ): Promise<UpdateRelationshipResponse>;
        updateSolution(
            params: UpdateSolutionParams,
            body?: unknown,
        ): Promise<unknown>;
        updateSolutionToRecord(
            params: UpdateSolutionToRecordParams,
        ): Promise<unknown>;
        updateTable(
            params: UpdateTableParams,
            body?: UpdateTableRequest,
        ): Promise<UpdateTableResponse>;
        upsert(body: UpsertRequest): PaginatedRequest<UpsertResponse>;
    }

    Hierarchy (View Summary)

    Index

    Properties

    getAuthStrategy: () => AuthStrategy

    Get the auth strategy for advanced usage (e.g., XML API client). XML-API: Used by createXmlClient() to access authentication.

    getConfig: () => ResolvedConfig

    Get the resolved configuration

    request: <T = unknown>(
        options: {
            body?: unknown;
            dbid?: string;
            method: "GET" | "POST" | "PUT" | "DELETE" | "PATCH";
            path: string;
            query?: Record<string, string | number | boolean | undefined>;
        },
    ) => Promise<T>

    Execute a raw request (for custom API calls)

    Methods

    • Get audit logs

      Gathers the audit logs for a single day from a realm. By default, this API returns 10,000 entries. This can be changed with the numRows parameter. Integrators can iterate through batches to get an entire day's worth of logs. Each realm has a maximum entitlement of querying 1,000 days per year (allowing lookbacks for up to two years). Requests for paginated data do not count towards the annual limit. Transactional rate limits are 10 per 10 seconds.
      Note:* This API is available for enterprise users only.

      Parameters

      • body: AuditRequest

        Request body

        Get audit logs

        • Optionaldate?: string

          The date for which audit logs need to be fetched. This must be date-time only, as YYYY-MM-DD, and a valid date in the past.

        • OptionalnextToken?: string

          Token specifying start of page. For first page don't supply this.

        • OptionalnumRows?: number

          Number of logs to return per page, default is 10000, minimum is 1000, max is 50000.

        • OptionalqueryId?: string

          The query id of an audit log request. This id is needed to fetch subsequent paged results of a single query.

        • Optionaltopics?: string[]

          An array that may contain up to 20 topics to filter by. If empty, all topics are returned.

      Returns Promise<AuditResponse>

      Query ran successfully and has returned the events for the given time period.

    • Copy an app

      Copies the specified application. The new application will have the same schema as the original. See below for additional copy options.

      Parameters

      • params: CopyAppParams

        Copy an app

        • appId: string

          The unique identifier of an app

      • body: CopyAppRequest

        Request body

        • Optionaldescription?: string

          The description of the newly copied app

        • name: string

          The name of the newly copied app

        • Optionalproperties?: {
              assignUserToken?: boolean;
              excludeFiles?: boolean;
              keepData?: boolean;
              usersAndRoles?: boolean;
          }

          The configuration properties for performing the app copy

          • OptionalassignUserToken?: boolean

            Whether to add the user token used to make this request to the new app

          • OptionalexcludeFiles?: boolean

            If keepData is true, whether to copy the file attachments as well. If keepData is false, this property is ignored

          • OptionalkeepData?: boolean

            Whether to copy the app's data along with the schema

          • OptionalusersAndRoles?: boolean

            If true, users will be copied along with their assigned roles. If false, users and roles will be copied but roles will not be assigned

      Returns Promise<CopyAppResponse>

      Success

    • Create an app

      Creates an application in an account. You must have application creation rights in the respective account. Main properties and application variables can be set with this API.

      Parameters

      • body: CreateAppRequest

        Request body

        Create an app

        • OptionalassignToken?: boolean

          Set to true if you would like to assign the app to the user token you used to create the application. The default is false.

        • Optionaldescription?: string

          The description for the app. If this property is left out, the app description will be blank.

        • name: string

          The app name. You are allowed to create multiple apps with the same name, in the same realm, because they will have different dbid values. We urge you to be careful about doing this.

        • OptionalsecurityProperties?: {
              allowClone?: boolean;
              allowExport?: boolean;
              enableAppTokens?: boolean;
              hideFromPublic?: boolean;
              mustBeRealmApproved?: boolean;
              useIPFilter?: boolean;
          }

          Application security properties.

          • OptionalallowClone?: boolean

            Allow users who are not administrators to copy

          • OptionalallowExport?: boolean

            Allow users who are not administrators to export data

          • OptionalenableAppTokens?: boolean

            Require Application Tokens

          • OptionalhideFromPublic?: boolean

            Hide from public application searches

          • OptionalmustBeRealmApproved?: boolean

            Only "approved" users may access this application

          • OptionaluseIPFilter?: boolean

            Only users logging in from "approved" IP addresses may access this application

        • Optionalvariables?: { name: string; value: string }[]

          The app variables. A maximum of 10 variables can be inserted at a time. See About Application Variables

      Returns Promise<CreateAppResponse>

      Success

    • Create a field

      Creates a field within a table, including the custom permissions of that field.

      Parameters

      • params: CreateFieldParams

        Create a field

        • tableId: string

          The unique identifier of the table.

      • body: CreateFieldRequest

        Request body

        • OptionaladdToForms?: boolean

          Whether the field you are adding should appear on forms. Defaults to false.

        • OptionalappearsByDefault?: boolean

          Indicates if the field is marked as a default in reports. Defaults to true.

        • Optionalaudited?: boolean

          Indicates if the field is being tracked as part of Quickbase Audit Logs. You can only set this property to "true" if the app has audit logs enabled. See Enable data change logs under Quickbase Audit Logs. Defaults to false.

        • Optionalbold?: boolean

          Indicates if the field is configured to display in bold in the product. Defaults to false.

        • OptionalfieldHelp?: string

          The configured help text shown to users within the product.

        • fieldType:
              | "date"
              | "email"
              | "url"
              | "rich-text"
              | "text"
              | "numeric"
              | "currency"
              | "percent"
              | "rating"
              | "timestamp"
              | "timeofday"
              | "duration"
              | "checkbox"
              | "phone"
              | "user"
              | "multiuser"
              | "text-multiple-choice"
              | "text-multi-line"
              | "multitext"
              | "datetime"
              | "address"
              | "file"

          The field types, click on any of the field type links for more info.

        • OptionalfindEnabled?: boolean

          Indicates if the field is marked as searchable. Defaults to true.

        • label: string

          The label (name) of the field.

        • OptionalnoWrap?: boolean

          Indicates if the field is configured to not wrap when displayed in the product. Defaults to false.

        • Optionalpermissions?: { permissionType?: string; role?: string; roleId?: number }[]

          Field Permissions for different roles.

        • Optionalproperties?: {
              abbreviate?: boolean;
              allowMentions?: boolean;
              allowNewChoices?: boolean;
              appearsAs?: string;
              appendOnly?: boolean;
              autoSave?: boolean;
              blankIsZero?: boolean;
              carryChoices?: boolean;
              choices?: string[];
              commaStart?: number;
              comments?: string;
              compositeFields?: (number | Record<string, unknown>)[];
              coverText?: string;
              currencyFormat?: "left" | "right" | "middle";
              currencySymbol?: string;
              decimalPlaces?: number;
              defaultCountryCode?: string;
              defaultDomain?: string;
              defaultKind?: string;
              defaultToday?: boolean;
              defaultValue?: string;
              defaultValueLuid?: number;
              displayAsLink?: boolean;
              displayCheckboxAsText?: boolean;
              displayDayOfWeek?: boolean;
              displayEmail?: string;
              displayMonth?: string;
              displayRelative?: boolean;
              displayTime?: boolean;
              displayTimezone?: boolean;
              displayUser?: string;
              doesAverage?: boolean;
              doesTotal?: boolean;
              exact?: boolean;
              format?: number;
              formula?: string;
              hasExtension?: boolean;
              hours24?: boolean;
              linkText?: string;
              maxLength?: number;
              maxVersions?: number;
              numberFormat?: number;
              numLines?: number;
              openTargetIn?: "sameWindow" | "newWindow" | "popup";
              parentFieldId?: number;
              seeVersions?: boolean;
              snapFieldId?: number;
              sortAlpha?: boolean;
              sortAsGiven?: boolean;
              sourceFieldId?: number;
              targetFieldId?: number;
              targetTableId?: string;
              targetTableName?: string;
              units?: string;
              useI18NFormat?: boolean;
              useNewWindow?: boolean;
              versionMode?: "keepallversions" | "keeplastversions";
              width?: number;
          }

          Specific field properties.

          • Optionalabbreviate?: boolean

            Don't show the URL protocol when showing the URL.

          • OptionalallowMentions?: boolean

            If someone can

            users in the rich text field to generate an email notification.

          • OptionalallowNewChoices?: boolean

            Indicates if users can add new choices to a selection list.

          • OptionalappearsAs?: string

            The link text, if empty, the url will be used as link text.

          • OptionalappendOnly?: boolean

            Whether this field is append only.

          • OptionalautoSave?: boolean

            Whether the link field will auto save.

          • OptionalblankIsZero?: boolean

            Whether a blank value is treated the same as 0 in calculations within the product.

          • OptionalcarryChoices?: boolean

            Whether the field should carry its multiple choice fields when copied.

          • Optionalchoices?: string[]

            An array of entries that exist for a field that offers choices to the user. Note that these choices refer to the valid values of any records added in the future. You are allowed to remove values from the list of choices even if there are existing records with those values in this field. They will be displayed in red when users look at the data in the browser but there is no other effect. While updating a field with this property, the old choices are removed and replaced by the new choices.

          • OptionalcommaStart?: number

            The number of digits before commas display in the product, when applicable.

          • Optionalcomments?: string

            The comments entered on the field properties by an administrator.

          • OptionalcompositeFields?: (number | Record<string, unknown>)[]

            An array of the fields that make up a composite field (e.g., address).

          • OptionalcoverText?: string

            An alternate user friendly text that can be used to display a link in the browser.

          • OptionalcurrencyFormat?: "left" | "right" | "middle"

            The currency format used when displaying field values within the product.

          • OptionalcurrencySymbol?: string

            The current symbol used when displaying field values within the product.

          • OptionaldecimalPlaces?: number

            The number of decimal places displayed in the product for this field.

          • OptionaldefaultCountryCode?: string

            Controls the default country shown on international phone widgets on forms. Country code should be entered in the ISO 3166-1 alpha-2 format.

          • OptionaldefaultDomain?: string

            Default email domain.

          • OptionaldefaultKind?: string

            The user default type.

          • OptionaldefaultToday?: boolean

            Indicates if the field value is defaulted today for new records.

          • OptionaldefaultValue?: string

            The default value configured for a field when a new record is added.

          • OptionaldefaultValueLuid?: number

            Default user id value.

          • OptionaldisplayAsLink?: boolean

            Indicates if a field that is part of the relationship should be shown as a hyperlink to the parent record within the product.

          • OptionaldisplayCheckboxAsText?: boolean

            Indicates whether the checkbox values will be shown as text in reports.

          • OptionaldisplayDayOfWeek?: boolean

            Indicates whether to display the day of the week within the product.

          • OptionaldisplayEmail?: string

            How the email is displayed.

          • OptionaldisplayMonth?: string

            How to display months.

          • OptionaldisplayRelative?: boolean

            Whether to display time as relative.

          • OptionaldisplayTime?: boolean

            Indicates whether to display the time, in addition to the date.

          • OptionaldisplayTimezone?: boolean

            Indicates whether to display the timezone within the product.

          • OptionaldisplayUser?: string

            The configured option for how users display within the product.

          • OptionaldoesAverage?: boolean

            Whether this field averages in reports within the product.

          • OptionaldoesTotal?: boolean

            Whether this field totals in reports within the product.

          • Optionalexact?: boolean

            Whether an exact match is required for a report link.

          • Optionalformat?: number

            The format to display time.

          • Optionalformula?: string

            The formula of the field as configured in Quickbase.

          • OptionalhasExtension?: boolean

            Whether this field has a phone extension.

          • Optionalhours24?: boolean

            Indicates whether or not to display time in the 24-hour format within the product.

          • OptionallinkText?: string

            The configured text value that replaces the URL that users see within the product.

          • OptionalmaxLength?: number

            The maximum number of characters allowed for entry in Quickbase for this field.

          • OptionalmaxVersions?: number

            The maximum number of versions configured for a file attachment.

          • OptionalnumberFormat?: number

            The format used for displaying numeric values in the product (decimal, separators, digit group).

          • OptionalnumLines?: number

            The number of lines shown in Quickbase for this text field.

          • OptionalopenTargetIn?: "sameWindow" | "newWindow" | "popup"

            Indicates which target the URL should open in when a user clicks it within the product.

          • OptionalparentFieldId?: number

            The id of the parent composite field, when applicable.

          • OptionalseeVersions?: boolean

            Indicates if the user can see other versions, aside from the most recent, of a file attachment within the product.

          • OptionalsnapFieldId?: number

            The id of the field that is used to snapshot values from, when applicable.

          • OptionalsortAlpha?: boolean

            Whether to sort alphabetically, default sort is by record ID.

          • OptionalsortAsGiven?: boolean

            Indicates if the listed entries sort as entered vs alphabetically.

          • OptionalsourceFieldId?: number

            The id of the source field.

          • OptionaltargetFieldId?: number

            The id of the target field.

          • OptionaltargetTableId?: string

            The id of the target table.

          • OptionaltargetTableName?: string

            The field's target table name.

          • Optionalunits?: string

            The units label.

          • OptionaluseI18NFormat?: boolean

            Whether phone numbers should be in E.164 standard international format

          • OptionaluseNewWindow?: boolean

            Indicates if the file should open a new window when a user clicks it within the product.

          • OptionalversionMode?: "keepallversions" | "keeplastversions"

            Version modes for files. Keep all versions vs keep last version.

          • Optionalwidth?: number

            The field's html input width in the product.

      Returns Promise<CreateFieldResponse>

      Success

    • Create a relationship

      Creates a relationship in a table as well as lookup/summary fields. Relationships can only be created for tables within the same app.

      Parameters

      • params: CreateRelationshipParams

        Create a relationship

        • tableId: string

          The unique identifier (dbid) of the table. This will be the child table.

      • body: CreateRelationshipRequest

        Request body

        • OptionalforeignKeyField?: { label?: string; [key: string]: unknown }

          This property is optional. If it is not provided, the foreign key field will be created with the label ‘Related ’, where is the name of a record in the parent table.

          • Optionallabel?: string

            The label for the foreign key field.

        • OptionallookupFieldIds?: number[]

          Array of field ids in the parent table that will become lookup fields in the child table.

        • parentTableId: string

          The parent table id for the relationship.

        • OptionalsummaryFields?: {
              accumulationType:
                  | "AVG"
                  | "SUM"
                  | "MAX"
                  | "MIN"
                  | "STD-DEV"
                  | "COUNT"
                  | "COMBINED-TEXT"
                  | "COMBINED-USER"
                  | "DISTINCT-COUNT";
              label?: string;
              summaryFid?: number;
              where?: string;
              [key: string]: unknown;
          }[]

          Array of summary field objects which will turn into summary fields in the parent table. When you specify the 'COUNT' accumulation type, you have to specify 0 as the summaryFid (or not set it in the request). 'DISTINCT-COUNT' requires that summaryFid be set to an actual fid.

      Returns Promise<CreateRelationshipResponse>

      Success

    • Download file

      Downloads the file attachment, with the file attachment content encoded in base64 format. The API response returns the file name in the Content-Disposition header. Meta-data about files can be retrieved from the /records and /reports endpoints, where applicable. Use those endpoints to get the necessary information to fetch files.

      Parameters

      • params: DownloadFileParams

        Download file

        • fieldId: number

          The unique identifier of the field.

        • recordId: number

          The unique identifier of the record.

        • tableId: string

          The unique identifier of the table.

        • versionNumber: number

          The file attachment version number.

      Returns Promise<unknown>

      Success

    • Exchange an SSO token

      Use this endpoint to exchange a SAML assertion for a Quickbase token following RFC 8693. Callers can choose to return a token compatible with SCIM, XML, or RESTful APIs. The token duration is determined by the SAML timeout session time. You must be able to create a SAML assertion in your code to use this endpoint. The SAML assertion is verified against the configuration on the realm. Learn more about about SAML assertions.

      Parameters

      • body: ExchangeSsoTokenRequest

        Request body

        Exchange an SSO token

        • grant_type: "urn:ietf:params:oauth:grant-type:token-exchange"

          The value urn:ietf:params:oauth:grant-type:token-exchange indicates that a token exchange is being performed.

        • requested_token_type:
              | "urn:quickbase:params:oauth:token-type:temp_token"
              | "urn:quickbase:params:oauth:token-type:temp_ticket"

          An identifier for the type of the requested security token. For the RESTful API, use urn:quickbase:params:oauth:token-type:temp_token. For the XML or SCIM APIs use urn:quickbase:params:oauth:token-type:temp_ticket.

        • subject_token: string

          A security token that represents the identity of the party on behalf of whom the request is being made. For SAML 2.0, the value should be a base64url-encoded SAML 2.0 assertion.

        • subject_token_type: "urn:ietf:params:oauth:token-type:saml2"

          An identifier that indicates the type of the security token in the subject_token parameter.

      Returns Promise<ExchangeSsoTokenResponse>

      Success

    • Generate a document

      Generates a document from a template. This feature is only available on business or enterprise plans.

      Parameters

      • params: GenerateDocumentParams

        Generate a document

        • filename: string

          File name for the downloaded file

        • Optionalformat?: "html" | "pdf" | "docx"

          The format of the file that is returned. Default is "pdf".

        • Optionalmargin?: string

          Margin formatted as top right bottom left, separated by spaces. Add to override the value set in the template builder.

        • Optionalorientation?: "portrait" | "landscape"

          Page orientation. Default is "portrait". Add to override the value set in the template builder.

        • OptionalpageSize?: "Letter" | "Legal" | "Tabloid" | "A3" | "A4" | "A5" | "A6"

          Page size. Default is "A4". Add to override the value set in the template builder.

        • Optionalrealm?: string

          Your Quickbase domain, for example demo.quickbase.com

        • OptionalrecordId?: number

          The ID of the record

        • tableId: string

          The unique identifier of the table.

        • templateId: number

          This is the ID of document template.

        • Optionalunit?: "in" | "cm" | "nm" | "px"

          Unit of measurement for the margin. Default is "in". Add to override the value set in the template builder.

      Returns Promise<GenerateDocumentResponse>

      Success

    • Get users

      Get all users in an account or narrowed down list of users filtered by email(s). The returned users may be paginated depending on the user count. The count of the returned users may vary. When nextPageToken value in the response is not empty, that indicates that there are more results to be returned, you can use this value to get the next result set ('page').

      Parameters

      • params: GetUsersParams

        Get users

        • OptionalaccountId?: number

          The account id being used to get users. If no value is specified, the first account associated with the requesting user token is chosen.

      • Optionalbody: GetUsersRequest

        Request body (optional)

        • [key: string]: unknown
        • OptionalappIds?: string[]

          When provided, the returned users will be narrowed down only to the users assigned to the app id's provided in this list. The provided app id's should belong to the same account.

        • Optionalemails?: string[]

          When provided, the returned users will be narrowed down only to the users included in this list.

        • OptionalnextPageToken?: string

          Next page token used to get the next 'page' of results when available. When this field is empty, the first page is returned.

      Returns PaginatedRequest<GetUsersResponse>

      Success

    • Query for data

      Pass in a query in the Quickbase query language. Returns record data with intelligent pagination based on the approximate size of each record. The metadata object will include the necessary information to iterate over the response and gather more data.

      Parameters

      • body: RunQueryRequest

        Request body

        Query for data

        • [key: string]: unknown
        • from: string

          The table identifier.

        • OptionalgroupBy?: { fieldId?: number; grouping?: "equal-values"; [key: string]: unknown }[]

          An array that contains the fields to group the records by.

        • Optionaloptions?: {
              compareWithAppLocalTime?: boolean;
              skip?: number;
              top?: number;
              [key: string]: unknown;
          }

          Additional query options.

          • OptionalcompareWithAppLocalTime?: boolean

            Whether to run the query against a date time field with respect to the application's local time. The query is run with UTC time by default. This parameter is ignored when querying by ISO8601, which is always in UTC.

          • Optionalskip?: number

            The number of records to skip.

          • Optionaltop?: number

            The maximum number of records to display.

        • Optionalselect?: number[]

          An array of field ids for the fields that should be returned in the response. If empty, the default columns on the table will be returned.

        • OptionalsortBy?: false | SortField[]

          An array of field IDs and sort directions. If this attribute is not set or set to false, queries will be unsorted to improve performance.

        • Optionalwhere?: string

          The filter, using the Quickbase query language, which determines the records to return. If this parameter is omitted, the query will return all records.

      Returns PaginatedRequest<RunQueryResponse>

      Success

    • Run a report

      Runs a report, based on an ID and returns the underlying data associated with it. The format of the data will vary based on the report type. Reports that focus on record-level data (table, calendar, etc.) return the individual records. Aggregate reports (summary, chart) will return the summarized information as configured in the report. UI-specific elements are not returned, such as totals, averages and visualizations. Returns data with intelligent pagination based on the approximate size of each record. The metadata object will include the necessary information to iterate over the response and gather more data.

      Parameters

      • params: RunReportParams

        Run a report

        • reportId: string

          The identifier of the report, unique to the table.

        • Optionalskip?: number

          The number of records to skip. You can set this value when paginating through a set of results.

        • tableId: string

          The identifier of the table for the report.

        • Optionaltop?: number

          The maximum number of records to return. You can override the default Quickbase pagination to get more or fewer results. If your requested value here exceeds the dynamic maximums, we will return a subset of results and the rest can be gathered in subsequent API calls.

      • Optionalbody: unknown

        Request body (optional)

      Returns PaginatedRequest<RunReportResponse>

      Success

    • Update an app

      Updates the main properties and/or application variables for a specific application. Any properties of the app that you do not specify in the request body will remain unchanged.

      Parameters

      • params: UpdateAppParams

        Update an app

        • appId: string

          The unique identifier of an app

      • Optionalbody: UpdateAppRequest

        Request body (optional)

        • Optionaldescription?: string

          The description for the app.

        • Optionalname?: string

          The name for the app.

        • OptionalsecurityProperties?: {
              allowClone?: boolean;
              allowExport?: boolean;
              enableAppTokens?: boolean;
              hideFromPublic?: boolean;
              mustBeRealmApproved?: boolean;
              useIPFilter?: boolean;
          }

          Security properties of the application

          • OptionalallowClone?: boolean

            Allow users who are not administrators to copy

          • OptionalallowExport?: boolean

            Allow users who are not administrators to export data

          • OptionalenableAppTokens?: boolean

            Require Application Tokens

          • OptionalhideFromPublic?: boolean

            Hide from public application searches

          • OptionalmustBeRealmApproved?: boolean

            Only "approved" users may access this application

          • OptionaluseIPFilter?: boolean

            Only users logging in from "approved" IP addresses may access this application

        • Optionalvariables?: { name: string; value: string }[]

          The app variables. A maximum of 10 variables can be updated at a time. See About Application Variables

      Returns Promise<UpdateAppResponse>

      Success

    • Update a field

      Updates the properties and custom permissions of a field. The attempt to update certain properties might cause existing data to no longer obey the field’s new properties and may be rejected. See the descriptions of required, unique, and choices, below, for specific situations. Any properties of the field that you do not specify in the request body will remain unchanged.

      Parameters

      • params: UpdateFieldParams

        Update a field

        • fieldId: number

          The unique identifier (fid) of the field.

        • tableId: string

          The unique identifier of the table.

      • Optionalbody: UpdateFieldRequest

        Request body (optional)

        • OptionaladdToForms?: boolean

          Whether the field you are adding should appear on forms.

        • OptionalappearsByDefault?: boolean

          Indicates if the field is marked as a default in reports.

        • Optionalaudited?: boolean

          Indicates if the field is being tracked as part of Quickbase Audit Logs. You can only set this property to "true" if the app has audit logs enabled. See Enable data change logs under Quickbase Audit Logs.

        • Optionalbold?: boolean

          Indicates if the field is configured to display in bold in the product.

        • OptionalfieldHelp?: string

          The configured help text shown to users within the product.

        • OptionalfindEnabled?: boolean

          Indicates if the field is marked as searchable.

        • Optionallabel?: string

          The label (name) of the field.

        • OptionalnoWrap?: boolean

          Indicates if the field is configured to not wrap when displayed in the product.

        • Optionalpermissions?: { permissionType?: string; role?: string; roleId?: number }[]

          Field Permissions for different roles.

        • Optionalproperties?: {
              abbreviate?: boolean;
              allowMentions?: boolean;
              allowNewChoices?: boolean;
              appearsAs?: string;
              appendOnly?: boolean;
              autoSave?: boolean;
              blankIsZero?: boolean;
              carryChoices?: boolean;
              choices?: string[];
              commaStart?: number;
              comments?: string;
              compositeFields?: (number | Record<string, unknown>)[];
              coverText?: string;
              currencyFormat?: "left" | "right" | "middle";
              currencySymbol?: string;
              decimalPlaces?: number;
              defaultCountryCode?: string;
              defaultDomain?: string;
              defaultKind?: string;
              defaultToday?: boolean;
              defaultValue?: string;
              defaultValueLuid?: number;
              displayAsLink?: boolean;
              displayCheckboxAsText?: boolean;
              displayDayOfWeek?: boolean;
              displayEmail?: string;
              displayMonth?: string;
              displayRelative?: boolean;
              displayTime?: boolean;
              displayTimezone?: boolean;
              displayUser?: string;
              doesAverage?: boolean;
              doesTotal?: boolean;
              exact?: boolean;
              format?: number;
              formula?: string;
              hasExtension?: boolean;
              hours24?: boolean;
              linkText?: string;
              lookupReferenceFieldId?: number;
              lookupTargetFieldId?: number;
              maxLength?: number;
              maxVersions?: number;
              numberFormat?: number;
              numLines?: number;
              openTargetIn?: "sameWindow" | "newWindow" | "popup";
              parentFieldId?: number;
              seeVersions?: boolean;
              snapFieldId?: number;
              sortAlpha?: boolean;
              sortAsGiven?: boolean;
              sourceFieldId?: number;
              summaryFunction?:
                  | "AVG"
                  | "SUM"
                  | "MAX"
                  | "MIN"
                  | "STD-DEV"
                  | "COUNT"
                  | "COMBINED-TEXT"
                  | "COMBINED-USER"
                  | "DISTINCT-COUNT";
              summaryQuery?: string;
              summaryReferenceFieldId?: number;
              summaryTableId?: string;
              summaryTargetFieldId?: number;
              targetFieldId?: number;
              targetTableId?: string;
              targetTableName?: string;
              units?: string;
              useI18NFormat?: boolean;
              useNewWindow?: boolean;
              versionMode?: "keepallversions"
              | "keeplastversions";
              width?: number;
          }

          Specific field properties.

          • Optionalabbreviate?: boolean

            Don't show the URL protocol when showing the URL.

          • OptionalallowMentions?: boolean

            If someone can

            users in the rich text field to generate an email notification.

          • OptionalallowNewChoices?: boolean

            Indicates if users can add new choices to a selection list.

          • OptionalappearsAs?: string

            The link text, if empty, the url will be used as link text.

          • OptionalappendOnly?: boolean

            Whether this field is append only.

          • OptionalautoSave?: boolean

            Whether the link field will auto save.

          • OptionalblankIsZero?: boolean

            Whether a blank value is treated the same as 0 in calculations within the product.

          • OptionalcarryChoices?: boolean

            Whether the field should carry its multiple choice fields when copied.

          • Optionalchoices?: string[]

            An array of entries that exist for a field that offers choices to the user. Note that these choices refer to the valid values of any records added in the future. You are allowed to remove values from the list of choices even if there are existing records with those values in this field. They will be displayed in red when users look at the data in the browser but there is no other effect. While updating a field with this property, the old choices are removed and replaced by the new choices.

          • OptionalcommaStart?: number

            The number of digits before commas display in the product, when applicable.

          • Optionalcomments?: string

            The comments entered on the field properties by an administrator.

          • OptionalcompositeFields?: (number | Record<string, unknown>)[]

            An array of the fields that make up a composite field (e.g., address).

          • OptionalcoverText?: string

            An alternate user friendly text that can be used to display a link in the browser.

          • OptionalcurrencyFormat?: "left" | "right" | "middle"

            The currency format used when displaying field values within the product.

          • OptionalcurrencySymbol?: string

            The current symbol used when displaying field values within the product.

          • OptionaldecimalPlaces?: number

            The number of decimal places displayed in the product for this field.

          • OptionaldefaultCountryCode?: string

            Controls the default country shown on international phone widgets on forms. Country code should be entered in the ISO 3166-1 alpha-2 format.

          • OptionaldefaultDomain?: string

            Default email domain.

          • OptionaldefaultKind?: string

            The user default type.

          • OptionaldefaultToday?: boolean

            Indicates if the field value is defaulted today for new records.

          • OptionaldefaultValue?: string

            The default value configured for a field when a new record is added.

          • OptionaldefaultValueLuid?: number

            Default user id value.

          • OptionaldisplayAsLink?: boolean

            Indicates if a field that is part of the relationship should be shown as a hyperlink to the parent record within the product.

          • OptionaldisplayCheckboxAsText?: boolean

            Indicates whether the checkbox values will be shown as text in reports.

          • OptionaldisplayDayOfWeek?: boolean

            Indicates whether to display the day of the week within the product.

          • OptionaldisplayEmail?: string

            How the email is displayed.

          • OptionaldisplayMonth?: string

            How to display months.

          • OptionaldisplayRelative?: boolean

            Whether to display time as relative.

          • OptionaldisplayTime?: boolean

            Indicates whether to display the time, in addition to the date.

          • OptionaldisplayTimezone?: boolean

            Indicates whether to display the timezone within the product.

          • OptionaldisplayUser?: string

            The configured option for how users display within the product.

          • OptionaldoesAverage?: boolean

            Whether this field averages in reports within the product.

          • OptionaldoesTotal?: boolean

            Whether this field totals in reports within the product.

          • Optionalexact?: boolean

            Whether an exact match is required for a report link.

          • Optionalformat?: number

            The format to display time.

          • Optionalformula?: string

            The formula of the field as configured in Quickbase.

          • OptionalhasExtension?: boolean

            Whether this field has a phone extension.

          • Optionalhours24?: boolean

            Indicates whether or not to display time in the 24-hour format within the product.

          • OptionallinkText?: string

            The configured text value that replaces the URL that users see within the product.

          • OptionallookupReferenceFieldId?: number

            The id of the field that is the reference in the relationship for this lookup.

          • OptionallookupTargetFieldId?: number

            The id of the field that is the target on the parent table for this lookup.

          • OptionalmaxLength?: number

            The maximum number of characters allowed for entry in Quickbase for this field.

          • OptionalmaxVersions?: number

            The maximum number of versions configured for a file attachment.

          • OptionalnumberFormat?: number

            The format used for displaying numeric values in the product (decimal, separators, digit group).

          • OptionalnumLines?: number

            The number of lines shown in Quickbase for this text field.

          • OptionalopenTargetIn?: "sameWindow" | "newWindow" | "popup"

            Indicates which target the URL should open in when a user clicks it within the product.

          • OptionalparentFieldId?: number

            The id of the parent composite field, when applicable.

          • OptionalseeVersions?: boolean

            Indicates if the user can see other versions, aside from the most recent, of a file attachment within the product.

          • OptionalsnapFieldId?: number

            The id of the field that is used to snapshot values from, when applicable.

          • OptionalsortAlpha?: boolean

            Whether to sort alphabetically, default sort is by record ID.

          • OptionalsortAsGiven?: boolean

            Indicates if the listed entries sort as entered vs alphabetically.

          • OptionalsourceFieldId?: number

            The id of the source field.

          • OptionalsummaryFunction?:
                | "AVG"
                | "SUM"
                | "MAX"
                | "MIN"
                | "STD-DEV"
                | "COUNT"
                | "COMBINED-TEXT"
                | "COMBINED-USER"
                | "DISTINCT-COUNT"

            The accumulation type for the summary field.

          • OptionalsummaryQuery?: string

            The summary query.

          • OptionalsummaryReferenceFieldId?: number

            The id of the field that is the reference in the relationship for this summary.

          • OptionalsummaryTableId?: string

            The table the summary field references fields from.

          • OptionalsummaryTargetFieldId?: number

            The id of the field that is used to aggregate values from the child, when applicable. This displays 0 if the summary function doesn’t require a field selection (like count).

          • OptionaltargetFieldId?: number

            The id of the target field.

          • OptionaltargetTableId?: string

            The id of the target table.

          • OptionaltargetTableName?: string

            The field's target table name.

          • Optionalunits?: string

            The units label.

          • OptionaluseI18NFormat?: boolean

            Whether phone numbers should be in E.164 standard international format

          • OptionaluseNewWindow?: boolean

            Indicates if the file should open a new window when a user clicks it within the product.

          • OptionalversionMode?: "keepallversions" | "keeplastversions"

            Version modes for files. Keep all versions vs keep last version.

          • Optionalwidth?: number

            The field's html input width in the product.

        • Optionalrequired?: boolean

          Indicates if the field is required (i.e. if every record must have a non-null value in this field). If you attempt to change a field from not-required to required, and the table currently contains records that have null values in that field, you will get an error indicating that there are null values of the field. In this case you need to find and update those records with null values of the field before changing the field to required.

        • Optionalunique?: boolean

          Indicates if every record in the table must contain a unique value of this field. If you attempt to change a field from not-unique to unique, and the table currently contains records with the same value of this field, you will get an error. In this case you need to find and update those records with duplicate values of the field before changing the field to unique.

      Returns Promise<UpdateFieldResponse>

      Success

    • Update a relationship

      Use this endpoint to add lookup fields and summary fields to an existing relationship. Updating a relationship will not delete existing lookup/summary fields.

      Parameters

      • params: UpdateRelationshipParams

        Update a relationship

        • relationshipId: number

          The relationship id. This is the field id of the reference field on the child table.

        • tableId: string

          The unique identifier (dbid) of the table. This will be the child table.

      • Optionalbody: UpdateRelationshipRequest

        Request body (optional)

        • OptionallookupFieldIds?: number[]

          An array of field ids on the parent table that will become lookup fields on the child table.

        • OptionalsummaryFields?: {
              accumulationType:
                  | "AVG"
                  | "SUM"
                  | "MAX"
                  | "MIN"
                  | "STD-DEV"
                  | "COUNT"
                  | "COMBINED-TEXT"
                  | "COMBINED-USER"
                  | "DISTINCT-COUNT";
              label?: string;
              summaryFid?: number;
              where?: string;
              [key: string]: unknown;
          }[]

          An array of objects, each representing a configuration of one field from the child table, that will become summary fields on the parent table. When you specify the 'COUNT' accumulation type, you have to specify 0 as the summaryFid (or not set it in the request). 'DISTINCT-COUNT' requires that summaryFid be set to an actual fid.

      Returns Promise<UpdateRelationshipResponse>

      Success

    • Update a table

      Updates the main properties of a specific table. Any properties of the table that you do not specify in the request body will remain unchanged.

      Parameters

      • params: UpdateTableParams

        Update a table

        • appId: string

          The unique identifier of an app

        • tableId: string

          The unique identifier (dbid) of the table.

      • Optionalbody: UpdateTableRequest

        Request body (optional)

        • [key: string]: unknown
        • Optionaldescription?: string

          The description for the table. If this value is not passed the default value is blank.

        • Optionalname?: string

          The name for the table.

        • OptionalpluralRecordName?: string

          The plural noun for records in the table. If this value is not passed the default value is 'Records'.

        • OptionalsingleRecordName?: string

          The singular noun for records in the table. If this value is not passed the default value is 'Record'.

      Returns Promise<UpdateTableResponse>

      Success

    • Insert/Update record(s)

      Insert and/or update record(s) in a table. In this single API call, inserts and updates can be submitted. Update can use the key field on the table, or any other supported unique field. Refer to the Field types page for more information about how each field type should be formatted. This operation allows for incremental processing of successful records, even when some of the records fail.
      Note:* This endpoint supports a maximum payload size of 40MB.

      Parameters

      • body: UpsertRequest

        Request body

        Insert/Update record(s)

        • [key: string]: unknown
        • Optionaldata?: QuickbaseRecord[]

          Record data array, where each record contains key-value mappings of fields to be defined/updated and their values.

        • OptionalfieldsToReturn?: number[]

          Specify an array of field ids that will return data for any updates or added record. Record ID (FID 3) is always returned if any field ID is requested.

        • OptionalmergeFieldId?: number

          The merge field id.

        • to: string

          The table identifier.

      Returns PaginatedRequest<UpsertResponse>

      Response