quickbase-js 2.3.0 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +145 -1107
- package/dist/auth/ticket.d.ts.map +1 -1
- package/dist/auth/ticket.js +4 -3
- package/dist/auth/ticket.js.map +1 -1
- package/dist/client/request.d.ts +4 -0
- package/dist/client/request.d.ts.map +1 -1
- package/dist/client/request.js +15 -3
- package/dist/client/request.js.map +1 -1
- package/dist/generated/client.d.ts +2 -0
- package/dist/generated/client.d.ts.map +1 -1
- package/dist/generated/client.js +134 -113
- package/dist/generated/client.js.map +1 -1
- package/dist/generated/types.d.ts +2700 -2256
- package/dist/generated/types.d.ts.map +1 -1
- package/dist/generated/types.js +0 -2
- package/dist/generated/types.js.map +1 -1
- package/dist/quickbase.esm.js +3 -3
- package/dist/quickbase.esm.js.map +3 -3
- package/dist/quickbase.min.js +3 -3
- package/dist/quickbase.min.js.map +3 -3
- package/package.json +16 -13
- package/src/auth/index.ts +55 -0
- package/src/auth/sso-token.ts +143 -0
- package/src/auth/temp-token.ts +160 -0
- package/src/auth/ticket.ts +329 -0
- package/src/auth/token-cache.ts +97 -0
- package/src/auth/types.ts +50 -0
- package/src/auth/user-token.ts +38 -0
- package/src/cli/schema.ts +512 -0
- package/src/client/index.ts +36 -0
- package/src/client/pagination.ts +337 -0
- package/src/client/request.ts +544 -0
- package/src/client/retry.ts +169 -0
- package/src/client/throttle.ts +105 -0
- package/src/core/config.ts +160 -0
- package/src/core/dates.ts +63 -0
- package/src/core/errors.ts +349 -0
- package/src/core/index.ts +50 -0
- package/src/core/logger.ts +113 -0
- package/src/core/schema.ts +213 -0
- package/src/core/transform.ts +295 -0
- package/src/core/types.ts +337 -0
- package/src/generated/client.ts +1785 -0
- package/src/generated/operations.json +672 -0
- package/src/generated/types.ts +4884 -0
- package/src/index.ts +259 -0
- package/src/xml/codepages.ts +119 -0
- package/src/xml/dbvars.ts +75 -0
- package/src/xml/errors.ts +133 -0
- package/src/xml/fields.ts +121 -0
- package/src/xml/groups.ts +560 -0
- package/src/xml/html.ts +152 -0
- package/src/xml/index.ts +1196 -0
- package/src/xml/metadata.ts +111 -0
- package/src/xml/records.ts +301 -0
- package/src/xml/request.ts +238 -0
- package/src/xml/roles.ts +321 -0
- package/src/xml/schema.ts +436 -0
- package/src/xml/transform.ts +381 -0
- package/src/xml/types.ts +602 -0
- package/src/xml/users.ts +221 -0
- package/src/xml/webhooks.ts +260 -0
package/dist/generated/client.js
CHANGED
|
@@ -17,9 +17,9 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
17
17
|
*
|
|
18
18
|
* @param body - Request body
|
|
19
19
|
* @param body.assignToken - 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. (optional)
|
|
20
|
-
* @param body.variables - The app variables. A maximum of 10 variables can be inserted at a time. See [About Application Variables](https://help.quickbase.com/
|
|
20
|
+
* @param body.variables - The app variables. A maximum of 10 variables can be inserted at a time. See [About Application Variables](https://help.quickbase.com/docs/creating-and-using-application-variables) (optional)
|
|
21
21
|
* @param body.name - 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.
|
|
22
|
-
* @param body.securityProperties -
|
|
22
|
+
* @param body.securityProperties - Security properties of the application (optional)
|
|
23
23
|
* @param body.description - The description for the app. If this property is left out, the app description will be blank. (optional)
|
|
24
24
|
*
|
|
25
25
|
* @returns Success
|
|
@@ -58,7 +58,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
58
58
|
* @param params.appId - The unique identifier of an app
|
|
59
59
|
*
|
|
60
60
|
* @param body - Request body (optional)
|
|
61
|
-
* @param body.variables - The app variables. A maximum of 10 variables can be
|
|
61
|
+
* @param body.variables - The app variables. A maximum of 10 variables can be inserted at a time. See [About Application Variables](https://help.quickbase.com/docs/creating-and-using-application-variables) (optional)
|
|
62
62
|
* @param body.name - The name for the app. (optional)
|
|
63
63
|
* @param body.securityProperties - Security properties of the application (optional)
|
|
64
64
|
* @param body.description - The description for the app. (optional)
|
|
@@ -293,13 +293,13 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
293
293
|
*
|
|
294
294
|
* Creates a relationship in a table as well as lookup/summary fields. Relationships can only be created for tables within the same app.
|
|
295
295
|
*
|
|
296
|
-
* @param params.tableId - The unique identifier (dbid) of the
|
|
296
|
+
* @param params.tableId - The unique identifier (dbid) of the child table.
|
|
297
297
|
*
|
|
298
298
|
* @param body - Request body
|
|
299
|
-
* @param body.summaryFields - 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. (optional)
|
|
300
|
-
* @param body.lookupFieldIds - Array of field IDs in the parent table that will become lookup fields in the child table. (optional)
|
|
301
299
|
* @param body.parentTableId - The parent table id for the relationship.
|
|
302
|
-
* @param body.foreignKeyField - This property is optional.
|
|
300
|
+
* @param body.foreignKeyField - This property is optional. If it is not provided, the foreign key field will be created with the label 'Related <record>', where <record> is the name of a record in the parent table. (optional)
|
|
301
|
+
* @param body.summaryFields - 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. (optional)
|
|
302
|
+
* @param body.lookupFieldIds - An array of field IDs in the parent table that will become lookup fields in the child table. (optional)
|
|
303
303
|
*
|
|
304
304
|
* @returns Success
|
|
305
305
|
*
|
|
@@ -317,12 +317,12 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
317
317
|
*
|
|
318
318
|
* Use this endpoint to add lookup fields and summary fields to an existing relationship. Updating a relationship will not delete existing lookup/summary fields.
|
|
319
319
|
*
|
|
320
|
-
* @param params.tableId - The unique identifier (dbid) of the
|
|
320
|
+
* @param params.tableId - The unique identifier (dbid) of the child table.
|
|
321
321
|
* @param params.relationshipId - The relationship id. This is the field id of the reference field on the child table.
|
|
322
322
|
*
|
|
323
323
|
* @param body - Request body (optional)
|
|
324
324
|
* @param body.summaryFields - 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. (optional)
|
|
325
|
-
* @param body.lookupFieldIds - An array of field IDs
|
|
325
|
+
* @param body.lookupFieldIds - An array of field IDs in the parent table that will become lookup fields in the child table. (optional)
|
|
326
326
|
*
|
|
327
327
|
* @returns Success
|
|
328
328
|
*
|
|
@@ -340,7 +340,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
340
340
|
*
|
|
341
341
|
* Use this endpoint to delete an entire relationship, including all lookup and summary fields. The reference field in the relationship will not be deleted.
|
|
342
342
|
*
|
|
343
|
-
* @param params.tableId - The unique identifier (dbid) of the
|
|
343
|
+
* @param params.tableId - The unique identifier (dbid) of the child table.
|
|
344
344
|
* @param params.relationshipId - The relationship id. This is the field id of the reference field on the child table.
|
|
345
345
|
*
|
|
346
346
|
* @returns Success
|
|
@@ -358,7 +358,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
358
358
|
*
|
|
359
359
|
* Get the schema (properties) of all reports for a table. If the user running the API is an application administrator, the API will also return all personal reports with owner's user id.
|
|
360
360
|
*
|
|
361
|
-
* @param params.tableId - The unique identifier of the table.
|
|
361
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
362
362
|
*
|
|
363
363
|
* @returns Success
|
|
364
364
|
*
|
|
@@ -376,7 +376,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
376
376
|
*
|
|
377
377
|
* Get the schema (properties) of an individual report.
|
|
378
378
|
*
|
|
379
|
-
* @param params.tableId - The unique identifier of table.
|
|
379
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
380
380
|
* @param params.reportId - The identifier of the report, unique to the table.
|
|
381
381
|
*
|
|
382
382
|
* @returns Success
|
|
@@ -395,44 +395,28 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
395
395
|
*
|
|
396
396
|
* 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.
|
|
397
397
|
*
|
|
398
|
-
* @param params.tableId - The identifier of the table
|
|
398
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
399
399
|
* @param params.skip - The number of records to skip. You can set this value when paginating through a set of results. (optional)
|
|
400
400
|
* @param params.top - 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. (optional)
|
|
401
401
|
* @param params.reportId - The identifier of the report, unique to the table.
|
|
402
402
|
*
|
|
403
|
-
* @param body - Request body (optional)
|
|
404
|
-
*
|
|
405
403
|
* @returns Success
|
|
406
404
|
*
|
|
407
405
|
* @see https://developer.quickbase.com/operation/runReport
|
|
408
406
|
*/
|
|
409
|
-
runReport(params
|
|
407
|
+
runReport(params) {
|
|
410
408
|
const executor = () => {
|
|
411
409
|
return request({
|
|
412
410
|
method: 'POST',
|
|
413
411
|
path: `/reports/${params.reportId}/run`,
|
|
414
412
|
query: { tableId: params.tableId, skip: params.skip, top: params.top },
|
|
415
|
-
body,
|
|
416
413
|
});
|
|
417
414
|
};
|
|
418
415
|
const paginatedExecutor = (paginationParams) => {
|
|
419
|
-
const bodyRecord = body;
|
|
420
|
-
const paginatedBody = paginationParams.skip !== undefined || paginationParams.nextPageToken || paginationParams.nextToken
|
|
421
|
-
? {
|
|
422
|
-
...(bodyRecord || {}),
|
|
423
|
-
options: {
|
|
424
|
-
...(bodyRecord?.options || {}),
|
|
425
|
-
...(paginationParams.skip !== undefined ? { skip: paginationParams.skip } : {}),
|
|
426
|
-
},
|
|
427
|
-
...(paginationParams.nextPageToken ? { nextPageToken: paginationParams.nextPageToken } : {}),
|
|
428
|
-
...(paginationParams.nextToken ? { nextToken: paginationParams.nextToken } : {}),
|
|
429
|
-
}
|
|
430
|
-
: body;
|
|
431
416
|
return request({
|
|
432
417
|
method: 'POST',
|
|
433
418
|
path: `/reports/${params.reportId}/run`,
|
|
434
|
-
query: { tableId: params.tableId, skip: params.skip, top: params.top },
|
|
435
|
-
body: paginatedBody,
|
|
419
|
+
query: { tableId: params.tableId, skip: params.skip, top: params.top, ...paginationParams },
|
|
436
420
|
});
|
|
437
421
|
};
|
|
438
422
|
return createPaginatedRequest(executor, { paginatedExecutor, autoPaginate });
|
|
@@ -461,7 +445,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
461
445
|
*
|
|
462
446
|
* Creates a field within a table, including the custom permissions of that field.
|
|
463
447
|
*
|
|
464
|
-
* @param params.tableId - The unique identifier of the table.
|
|
448
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
465
449
|
*
|
|
466
450
|
* @param body - Request body
|
|
467
451
|
* @param body.audited - 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](https://help.quickbase.com/docs/audit-logs). Defaults to false. (optional)
|
|
@@ -493,7 +477,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
493
477
|
*
|
|
494
478
|
* Deletes one or many fields in a table, based on field id. This will also permanently delete any data or calculations in that field.
|
|
495
479
|
*
|
|
496
|
-
* @param params.tableId - The unique identifier of the table.
|
|
480
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
497
481
|
*
|
|
498
482
|
* @param body - Request body
|
|
499
483
|
* @param body.fieldIds - List of field IDs to be deleted.
|
|
@@ -536,7 +520,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
536
520
|
*
|
|
537
521
|
* 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.
|
|
538
522
|
*
|
|
539
|
-
* @param params.tableId - The unique identifier of the table.
|
|
523
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
540
524
|
* @param params.fieldId - The unique identifier (fid) of the field.
|
|
541
525
|
*
|
|
542
526
|
* @param body - Request body (optional)
|
|
@@ -632,12 +616,12 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
632
616
|
**Note:** This endpoint supports a maximum payload size of 40MB.
|
|
633
617
|
*
|
|
634
618
|
* @param body - Request body
|
|
635
|
-
* @param body.to - The
|
|
636
|
-
* @param body.data - Record data array, where each record contains key-value mappings of fields to be defined/updated and their values.
|
|
619
|
+
* @param body.to - The unique identifier (dbid) of the table.
|
|
620
|
+
* @param body.data - Record data array, where each record contains key-value mappings of fields to be defined/updated and their values.
|
|
637
621
|
* @param body.mergeFieldId - The merge field id. (optional)
|
|
638
622
|
* @param body.fieldsToReturn - 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. (optional)
|
|
639
623
|
*
|
|
640
|
-
* @returns
|
|
624
|
+
* @returns The response
|
|
641
625
|
*
|
|
642
626
|
* @see https://developer.quickbase.com/operation/upsert
|
|
643
627
|
*/
|
|
@@ -676,7 +660,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
676
660
|
* Deletes record(s) in a table based on a query. Alternatively, all records in the table can be deleted.
|
|
677
661
|
*
|
|
678
662
|
* @param body - Request body
|
|
679
|
-
* @param body.from - The unique identifier of the table.
|
|
663
|
+
* @param body.from - The unique identifier (dbid) of the table.
|
|
680
664
|
* @param body.where - The filter to delete records. To delete all records specify a filter that will include all records, for example {3.GT.0} where 3 is the ID of the Record ID field. Or supply a JSON array of Record IDs.
|
|
681
665
|
*
|
|
682
666
|
* @returns Successful delete records response.
|
|
@@ -701,7 +685,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
701
685
|
* @param body.groupBy - An array that contains the fields to group the records by. (optional)
|
|
702
686
|
* @param body.sortBy - The sortBy (optional)
|
|
703
687
|
* @param body.select - 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. (optional)
|
|
704
|
-
* @param body.from - The
|
|
688
|
+
* @param body.from - The unique identifier (dbid) of the table.
|
|
705
689
|
*
|
|
706
690
|
* @returns Success
|
|
707
691
|
*
|
|
@@ -739,7 +723,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
739
723
|
/**
|
|
740
724
|
* Get records modified since
|
|
741
725
|
*
|
|
742
|
-
* Checks for record changes on the current table and crawls the record dependency graph based on a provided field list. This determines if records on the table changed after the provided timestamp, when factoring in their dependencies. This API requires app admin permissions and only reviews lookup and summary fields in supported relationships.
|
|
726
|
+
* Checks for record changes on the current table and crawls the record dependency graph based on a provided field list. This determines if records on the table changed after the provided timestamp, when factoring in their dependencies. This API requires app admin permissions and only reviews lookup and summary fields in [supported relationships](https://helpv2.quickbase.com/hc/en-us/articles/4570306993940-Limits-in-Quickbase#:~:text=on%20scalar%20fields-,Summary%20fields,-Text%20summary%20fields).
|
|
743
727
|
To return deleted records for the current table, 'Index record changes' must be enabled.
|
|
744
728
|
Dependent tables only evaluate current records, and deleted records are not supported.
|
|
745
729
|
*
|
|
@@ -747,7 +731,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
747
731
|
* @param body.after - A timestamp, formatted in ISO-8601 UTC, representing the date and time to search.
|
|
748
732
|
* @param body.fieldList - List of field IDs. Each field is crawled across the entire record dependency graph to find its source record's date modified. If one is not provided, only the current table will be referenced. (optional)
|
|
749
733
|
* @param body.includeDetails - When true, the individual record IDs and timestamps will be returned. If false, only the count of changes will be returned. (optional)
|
|
750
|
-
* @param body.from - The
|
|
734
|
+
* @param body.from - The unique identifier (dbid) of the table.
|
|
751
735
|
*
|
|
752
736
|
* @returns Success
|
|
753
737
|
*
|
|
@@ -808,7 +792,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
808
792
|
* @param body.name - The new name for the cloned user token. (optional)
|
|
809
793
|
* @param body.description - The description for the cloned user token. (optional)
|
|
810
794
|
*
|
|
811
|
-
* @returns
|
|
795
|
+
* @returns The response
|
|
812
796
|
*
|
|
813
797
|
* @see https://developer.quickbase.com/operation/cloneUserToken
|
|
814
798
|
*/
|
|
@@ -822,14 +806,14 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
822
806
|
/**
|
|
823
807
|
* Transfer a user token
|
|
824
808
|
*
|
|
825
|
-
* Transfers the specified user token. Application associations will remain intact. For security, permissions must manually be reconciled.
|
|
809
|
+
* Transfers the specified user token. Application associations will remain intact. For security, permissions must manually be reconciled. Only realm or account admins can use this API.
|
|
826
810
|
*
|
|
827
811
|
* @param body - Request body
|
|
828
|
-
* @param body.id - The id of the user token to transfer
|
|
829
|
-
* @param body.from - The id of the user to transfer the user token from
|
|
830
|
-
* @param body.to - The id of the user to transfer the user token to
|
|
812
|
+
* @param body.id - The id of the user token to transfer
|
|
813
|
+
* @param body.from - The id of the user to transfer the user token from
|
|
814
|
+
* @param body.to - The id of the user to transfer the user token to
|
|
831
815
|
*
|
|
832
|
-
* @returns
|
|
816
|
+
* @returns The response
|
|
833
817
|
*
|
|
834
818
|
* @see https://developer.quickbase.com/operation/transferUserToken
|
|
835
819
|
*/
|
|
@@ -845,7 +829,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
845
829
|
*
|
|
846
830
|
* Deactivates the authenticated user token. Once this is done, the user token must be reactivated in the user interface.
|
|
847
831
|
*
|
|
848
|
-
* @returns
|
|
832
|
+
* @returns The response
|
|
849
833
|
*
|
|
850
834
|
* @see https://developer.quickbase.com/operation/deactivateUserToken
|
|
851
835
|
*/
|
|
@@ -860,7 +844,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
860
844
|
*
|
|
861
845
|
* Deletes the authenticated user token. This is not reversible.
|
|
862
846
|
*
|
|
863
|
-
* @returns
|
|
847
|
+
* @returns The response
|
|
864
848
|
*
|
|
865
849
|
* @see https://developer.quickbase.com/operation/deleteUserToken
|
|
866
850
|
*/
|
|
@@ -875,9 +859,9 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
875
859
|
*
|
|
876
860
|
* 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.
|
|
877
861
|
*
|
|
878
|
-
* @param params.tableId - The unique identifier of the table.
|
|
862
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
879
863
|
* @param params.recordId - The unique identifier of the record.
|
|
880
|
-
* @param params.fieldId - The unique identifier of the field.
|
|
864
|
+
* @param params.fieldId - The unique identifier (fid) of the field.
|
|
881
865
|
* @param params.versionNumber - The file attachment version number.
|
|
882
866
|
*
|
|
883
867
|
* @returns Success
|
|
@@ -888,6 +872,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
888
872
|
return request({
|
|
889
873
|
method: 'GET',
|
|
890
874
|
path: `/files/${params.tableId}/${params.recordId}/${params.fieldId}/${params.versionNumber}`,
|
|
875
|
+
responseType: 'text',
|
|
891
876
|
});
|
|
892
877
|
},
|
|
893
878
|
/**
|
|
@@ -895,10 +880,10 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
895
880
|
*
|
|
896
881
|
* Deletes one file attachment version. Meta-data about files can be retrieved from the /records and /reports endpoints, where applicable. Use those endpoints to get the necessary information to delete file versions.
|
|
897
882
|
*
|
|
898
|
-
* @param params.tableId - The unique identifier of the table.
|
|
883
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
899
884
|
* @param params.recordId - The unique identifier of the record.
|
|
900
|
-
* @param params.fieldId - The unique identifier of the field.
|
|
901
|
-
* @param params.versionNumber - The file attachment version number.
|
|
885
|
+
* @param params.fieldId - The unique identifier (fid) of the field.
|
|
886
|
+
* @param params.versionNumber - The file attachment version number. Passing versionNumber 0 will delete the most recent version.
|
|
902
887
|
*
|
|
903
888
|
* @returns Successfully Deleted the File Attachment
|
|
904
889
|
*
|
|
@@ -913,7 +898,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
913
898
|
/**
|
|
914
899
|
* Get users
|
|
915
900
|
*
|
|
916
|
-
* 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').
|
|
901
|
+
* 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'). Only realm or account admins can use this API.
|
|
917
902
|
*
|
|
918
903
|
* @param params.accountId - The account id being used to get users. If no value is specified, the first account associated with the requesting user token is chosen. (optional)
|
|
919
904
|
*
|
|
@@ -960,17 +945,20 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
960
945
|
/**
|
|
961
946
|
* Deny users
|
|
962
947
|
*
|
|
963
|
-
* Denies users access to the realm but leaves them listed in groups they have been added to.
|
|
948
|
+
* Denies users access to the realm but leaves them listed in groups they have been added to. Only realm or account admins can use this API.
|
|
964
949
|
*
|
|
965
950
|
* @param params.accountId - The account id being used to deny users. If no value is specified, the first account associated with the requesting user token is chosen. (optional)
|
|
966
951
|
*
|
|
967
|
-
* @param body -
|
|
952
|
+
* @param body - A list of user IDs that need to be denied.
|
|
968
953
|
*
|
|
969
954
|
* @returns Success
|
|
970
955
|
*
|
|
971
956
|
* @see https://developer.quickbase.com/operation/denyUsers
|
|
972
957
|
*/
|
|
973
|
-
denyUsers(
|
|
958
|
+
denyUsers(paramsOrBody, maybeBody) {
|
|
959
|
+
const [params, body] = maybeBody === undefined
|
|
960
|
+
? [{}, paramsOrBody]
|
|
961
|
+
: [paramsOrBody, maybeBody];
|
|
974
962
|
return request({
|
|
975
963
|
method: 'PUT',
|
|
976
964
|
path: '/users/deny',
|
|
@@ -981,12 +969,12 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
981
969
|
/**
|
|
982
970
|
* Deny and remove users from groups
|
|
983
971
|
*
|
|
984
|
-
* Denies users access to the realm and allows you to remove them from groups.
|
|
972
|
+
* Denies users access to the realm and allows you to remove them from groups. Only realm or account admins can use this API.
|
|
985
973
|
*
|
|
986
974
|
* @param params.accountId - The account id being used to deny users. If no value is specified, the first account associated with the requesting user token is chosen. (optional)
|
|
987
975
|
* @param params.shouldDeleteFromGroups - Specifies if the users should also be removed from all groups.
|
|
988
976
|
*
|
|
989
|
-
* @param body -
|
|
977
|
+
* @param body - A list of user IDs that need to be denied.
|
|
990
978
|
*
|
|
991
979
|
* @returns Success
|
|
992
980
|
*
|
|
@@ -1003,17 +991,20 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1003
991
|
/**
|
|
1004
992
|
* Undeny users
|
|
1005
993
|
*
|
|
1006
|
-
* Grants users that have previously been denied access to the realm.
|
|
994
|
+
* Grants users that have previously been denied access to the realm. Only realm or account admins can use this API.
|
|
1007
995
|
*
|
|
1008
996
|
* @param params.accountId - The account id being used to undeny users. If no value is specified, the first account associated with the requesting user token is chosen. (optional)
|
|
1009
997
|
*
|
|
1010
|
-
* @param body -
|
|
998
|
+
* @param body - A list of user IDs that need to be undenied.
|
|
1011
999
|
*
|
|
1012
1000
|
* @returns Success
|
|
1013
1001
|
*
|
|
1014
1002
|
* @see https://developer.quickbase.com/operation/undenyUsers
|
|
1015
1003
|
*/
|
|
1016
|
-
undenyUsers(
|
|
1004
|
+
undenyUsers(paramsOrBody, maybeBody) {
|
|
1005
|
+
const [params, body] = maybeBody === undefined
|
|
1006
|
+
? [{}, paramsOrBody]
|
|
1007
|
+
: [paramsOrBody, maybeBody];
|
|
1017
1008
|
return request({
|
|
1018
1009
|
method: 'PUT',
|
|
1019
1010
|
path: '/users/undeny',
|
|
@@ -1021,6 +1012,25 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1021
1012
|
body,
|
|
1022
1013
|
});
|
|
1023
1014
|
},
|
|
1015
|
+
/**
|
|
1016
|
+
* Get apps for a user
|
|
1017
|
+
*
|
|
1018
|
+
* Returns a list of applications that a specific user has access to within an account. Only account admins can use this API.
|
|
1019
|
+
*
|
|
1020
|
+
* @param params.userId - The unique identifier of the user, including the hashed value (for example, 59913288.d772).
|
|
1021
|
+
* @param params.accountId - The account id used to scope the request.
|
|
1022
|
+
*
|
|
1023
|
+
* @returns Success
|
|
1024
|
+
*
|
|
1025
|
+
* @see https://developer.quickbase.com/operation/getUserApps
|
|
1026
|
+
*/
|
|
1027
|
+
getUserApps(params) {
|
|
1028
|
+
return request({
|
|
1029
|
+
method: 'GET',
|
|
1030
|
+
path: `/users/${params.userId}/apps`,
|
|
1031
|
+
query: { accountId: params.accountId },
|
|
1032
|
+
});
|
|
1033
|
+
},
|
|
1024
1034
|
/**
|
|
1025
1035
|
* Add members
|
|
1026
1036
|
*
|
|
@@ -1028,7 +1038,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1028
1038
|
*
|
|
1029
1039
|
* @param params.gid - This is the ID of the group being modified.
|
|
1030
1040
|
*
|
|
1031
|
-
* @param body -
|
|
1041
|
+
* @param body - A list of user IDs that will be added to a group.
|
|
1032
1042
|
*
|
|
1033
1043
|
* @returns Success
|
|
1034
1044
|
*
|
|
@@ -1048,7 +1058,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1048
1058
|
*
|
|
1049
1059
|
* @param params.gid - This is the ID of the group being modified.
|
|
1050
1060
|
*
|
|
1051
|
-
* @param body -
|
|
1061
|
+
* @param body - A list of user IDs that will be removed from a group.
|
|
1052
1062
|
*
|
|
1053
1063
|
* @returns Success
|
|
1054
1064
|
*
|
|
@@ -1068,7 +1078,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1068
1078
|
*
|
|
1069
1079
|
* @param params.gid - This is the ID of the group being modified.
|
|
1070
1080
|
*
|
|
1071
|
-
* @param body -
|
|
1081
|
+
* @param body - A list of user IDs that will be added to a group.
|
|
1072
1082
|
*
|
|
1073
1083
|
* @returns Success
|
|
1074
1084
|
*
|
|
@@ -1088,7 +1098,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1088
1098
|
*
|
|
1089
1099
|
* @param params.gid - This is the ID of the group being modified.
|
|
1090
1100
|
*
|
|
1091
|
-
* @param body -
|
|
1101
|
+
* @param body - A list of user IDs that will be removed from a group.
|
|
1092
1102
|
*
|
|
1093
1103
|
* @returns Success
|
|
1094
1104
|
*
|
|
@@ -1108,7 +1118,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1108
1118
|
*
|
|
1109
1119
|
* @param params.gid - This is the ID of the group being modified.
|
|
1110
1120
|
*
|
|
1111
|
-
* @param body -
|
|
1121
|
+
* @param body - A list of group IDs that will be added to a group.
|
|
1112
1122
|
*
|
|
1113
1123
|
* @returns Success
|
|
1114
1124
|
*
|
|
@@ -1128,7 +1138,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1128
1138
|
*
|
|
1129
1139
|
* @param params.gid - This is the ID of the group being modified.
|
|
1130
1140
|
*
|
|
1131
|
-
* @param body -
|
|
1141
|
+
* @param body - A list of group IDs that will be removed from a group.
|
|
1132
1142
|
*
|
|
1133
1143
|
* @returns Success
|
|
1134
1144
|
*
|
|
@@ -1171,7 +1181,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1171
1181
|
* Get user read and integration read summaries for any day in the past.
|
|
1172
1182
|
**Note:** This API is available for enterprise users only.
|
|
1173
1183
|
*
|
|
1174
|
-
* @param params.day - The date for which read summaries need to be fetched. This must be date-time only, as YYYY-MM-DD, and a valid date in the past.
|
|
1184
|
+
* @param params.day - The date for which read summaries need to be fetched. This must be date-time only, as YYYY-MM-DD, and a valid date in the past.
|
|
1175
1185
|
*
|
|
1176
1186
|
* @returns Summaries returned succesfully
|
|
1177
1187
|
*
|
|
@@ -1188,13 +1198,13 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1188
1198
|
* Get event summaries
|
|
1189
1199
|
*
|
|
1190
1200
|
* Get event summaries for any span of days up to one year and excluding future dates.
|
|
1191
|
-
**Note:** This API is available for enterprise users only. Data is updated hourly
|
|
1201
|
+
**Note:** This API is available for enterprise users only. Data is updated hourly. To ensure accuracy, query dates should be at least one hour in the past. Transactional rate limits are 100 per hour.
|
|
1192
1202
|
*
|
|
1193
1203
|
* @param params.accountId - The ID of the account to query. If no value is specified, the first account matching the provided domain is chosen. (optional)
|
|
1194
1204
|
*
|
|
1195
|
-
* @param body - Request body
|
|
1196
|
-
* @param body.start -
|
|
1197
|
-
* @param body.end -
|
|
1205
|
+
* @param body - Request body (optional)
|
|
1206
|
+
* @param body.start - Supply whole-hour timestamps (YYYY-MM-DDTHH:00:00Z) to ensure the boundary hour is included in results. Summary data is available in hourly chunks only. Timestamps are evaluated in UTC; if your timestamp includes a timezone offset, confirm which UTC hour it maps to. Example: A start of 2:00 PM UTC includes the 2:00 PM bucket. A sub-hour value like 2:15 PM UTC does not.
|
|
1207
|
+
* @param body.end - Supply whole-hour timestamps (YYYY-MM-DDTHH:00:00Z) to ensure results stop at your intended boundary. Summary data is available in hourly chunks only. Timestamps are evaluated in UTC; if your timestamp includes a timezone offset, confirm which UTC hour it maps to. Example: An end of 3:00 PM UTC returns data through the end of the 3:00 PM bucket. A sub-hour value like 2:33 PM UTC returns the full 2:00 PM bucket instead.
|
|
1198
1208
|
* @param body.nextToken - A pagination token from a previous response made using the same parameters. Used to fetch the next page. (optional)
|
|
1199
1209
|
* @param body.groupBy - How the events should be grouped.
|
|
1200
1210
|
* @param body.where - A list of items to filter events by. Only events which match ALL criteria will be included in the results. (optional)
|
|
@@ -1234,11 +1244,38 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1234
1244
|
};
|
|
1235
1245
|
return createPaginatedRequest(executor, { paginatedExecutor, autoPaginate });
|
|
1236
1246
|
},
|
|
1247
|
+
/**
|
|
1248
|
+
* Generate a document
|
|
1249
|
+
*
|
|
1250
|
+
* Generates a document from a template. After changing a template, allow up to 15 minutes for documents generated via the API to reflect the changes. This feature is only available on business or enterprise plans.
|
|
1251
|
+
*
|
|
1252
|
+
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
1253
|
+
* @param params.recordId - The ID of the record (optional)
|
|
1254
|
+
* @param params.filename - File name for the downloaded file (optional)
|
|
1255
|
+
* @param params.templateId - This is the ID of document template.
|
|
1256
|
+
* @param params.format - The format of the file that is returned. Default is "pdf". (optional)
|
|
1257
|
+
* @param params.margin - Margin formatted as top right bottom left, separated by spaces. Add to override the value set in the template builder. (optional)
|
|
1258
|
+
* @param params.unit - Unit of measurement for the margin. Default is "in". Add to override the value set in the template builder. (optional)
|
|
1259
|
+
* @param params.pageSize - Page size. Default is "A4". Add to override the value set in the template builder. (optional)
|
|
1260
|
+
* @param params.orientation - Page orientation. Default is "portrait". Add to override the value set in the template builder. (optional)
|
|
1261
|
+
* @param params.realm - Your Quickbase domain, for example demo.quickbase.com (optional)
|
|
1262
|
+
*
|
|
1263
|
+
* @returns Success
|
|
1264
|
+
*
|
|
1265
|
+
* @see https://developer.quickbase.com/operation/generateDocument
|
|
1266
|
+
*/
|
|
1267
|
+
generateDocument(params) {
|
|
1268
|
+
return request({
|
|
1269
|
+
method: 'GET',
|
|
1270
|
+
path: `/docTemplates/${params.templateId}/generate`,
|
|
1271
|
+
query: { tableId: params.tableId, recordId: params.recordId, filename: params.filename, format: params.format, margin: params.margin, unit: params.unit, pageSize: params.pageSize, orientation: params.orientation, realm: params.realm },
|
|
1272
|
+
});
|
|
1273
|
+
},
|
|
1237
1274
|
/**
|
|
1238
1275
|
* Export a solution
|
|
1239
1276
|
*
|
|
1240
1277
|
* Returns the QBL for the specified solution. Learn more about [QBL syntax](https://help.quickbase.com/docs/qbl-definition-structure-and-syntax).
|
|
1241
|
-
|
|
1278
|
+
We are releasing schema coverage for QBL in stages. See [what's supported today](https://help.quickbase.com/docs/qbl-versions) in our QBL documentation.
|
|
1242
1279
|
*
|
|
1243
1280
|
* @param params.solutionId - The unique identifier (UUID) or the alias of the solution.
|
|
1244
1281
|
*
|
|
@@ -1250,17 +1287,18 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1250
1287
|
return request({
|
|
1251
1288
|
method: 'GET',
|
|
1252
1289
|
path: `/solutions/${params.solutionId}`,
|
|
1290
|
+
responseType: 'text',
|
|
1253
1291
|
});
|
|
1254
1292
|
},
|
|
1255
1293
|
/**
|
|
1256
1294
|
* Update a solution
|
|
1257
1295
|
*
|
|
1258
1296
|
* Updates the solution using the provided QBL. Learn more about [QBL syntax](https://help.quickbase.com/hc/en-us/articles/24845511223828-What-is-QBL).
|
|
1259
|
-
|
|
1297
|
+
We are releasing schema coverage for QBL in stages. See [what's supported today](https://helpv2.quickbase.com/hc/en-us/sections/26699387198228-QBL-Versions) in our QBL documentation.
|
|
1260
1298
|
*
|
|
1261
1299
|
* @param params.solutionId - The unique identifier (UUID) or the alias of the solution.
|
|
1262
1300
|
*
|
|
1263
|
-
* @param body - The QBL to be used for the update.
|
|
1301
|
+
* @param body - The QBL to be used for the update.
|
|
1264
1302
|
*
|
|
1265
1303
|
* @returns Success
|
|
1266
1304
|
*
|
|
@@ -1271,13 +1309,16 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1271
1309
|
method: 'PUT',
|
|
1272
1310
|
path: `/solutions/${params.solutionId}`,
|
|
1273
1311
|
body,
|
|
1312
|
+
bodyType: 'application/x-yaml',
|
|
1274
1313
|
});
|
|
1275
1314
|
},
|
|
1276
1315
|
/**
|
|
1277
1316
|
* Create a solution
|
|
1278
1317
|
*
|
|
1279
1318
|
* Creates a solution using the provided QBL. Learn more about [QBL syntax](https://help.quickbase.com/hc/en-us/articles/24845511223828-What-is-QBL).
|
|
1280
|
-
|
|
1319
|
+
We are releasing schema coverage for QBL in stages. See [what's supported today](https://helpv2.quickbase.com/hc/en-us/sections/26699387198228-QBL-Versions) in our QBL documentation.
|
|
1320
|
+
*
|
|
1321
|
+
* @param params.alias - An optional alias to identify the solution. This can be used instead of the UUID in subsequent API calls. (optional)
|
|
1281
1322
|
*
|
|
1282
1323
|
* @param body - The QBL to be used for the create.
|
|
1283
1324
|
*
|
|
@@ -1285,11 +1326,16 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1285
1326
|
*
|
|
1286
1327
|
* @see https://developer.quickbase.com/operation/createSolution
|
|
1287
1328
|
*/
|
|
1288
|
-
createSolution(
|
|
1329
|
+
createSolution(paramsOrBody, maybeBody) {
|
|
1330
|
+
const [params, body] = maybeBody === undefined
|
|
1331
|
+
? [{}, paramsOrBody]
|
|
1332
|
+
: [paramsOrBody, maybeBody];
|
|
1289
1333
|
return request({
|
|
1290
1334
|
method: 'POST',
|
|
1291
1335
|
path: '/solutions',
|
|
1336
|
+
query: { alias: params.alias },
|
|
1292
1337
|
body,
|
|
1338
|
+
bodyType: 'application/x-yaml',
|
|
1293
1339
|
});
|
|
1294
1340
|
},
|
|
1295
1341
|
/**
|
|
@@ -1298,7 +1344,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1298
1344
|
* Exports the solution and outputs the resulting QBL in a new record in the specified table. The QBL will be saved to a file in the file attachment field that is specified. The table cannot have any required fields besides the file attachment field.
|
|
1299
1345
|
We are releasing schema coverage for QBL in stages. See [what's supported today](https://helpv2.quickbase.com/hc/en-us/sections/26699387198228-QBL-Versions) in our QBL documentation.
|
|
1300
1346
|
*
|
|
1301
|
-
* @param params.solutionId - The unique identifier of the solution.
|
|
1347
|
+
* @param params.solutionId - The unique identifier (UUID) or the alias of the solution.
|
|
1302
1348
|
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
1303
1349
|
* @param params.fieldId - The unique identifier (fid) of the field. It needs to be a file attachment field.
|
|
1304
1350
|
*
|
|
@@ -1319,6 +1365,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1319
1365
|
* Creates a solution using the QBL from the specified record.
|
|
1320
1366
|
We are releasing schema coverage for QBL in stages. See [what's supported today](https://helpv2.quickbase.com/hc/en-us/sections/26699387198228-QBL-Versions) in our QBL documentation.
|
|
1321
1367
|
*
|
|
1368
|
+
* @param params.alias - An optional alias to identify the solution. This can be used instead of the UUID in subsequent API calls. (optional)
|
|
1322
1369
|
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
1323
1370
|
* @param params.fieldId - The unique identifier (fid) of the field. It needs to be a file attachment field.
|
|
1324
1371
|
* @param params.recordId - The unique identifier of the record.
|
|
@@ -1331,7 +1378,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1331
1378
|
return request({
|
|
1332
1379
|
method: 'GET',
|
|
1333
1380
|
path: '/solutions/fromrecord',
|
|
1334
|
-
query: { tableId: params.tableId, fieldId: params.fieldId, recordId: params.recordId },
|
|
1381
|
+
query: { alias: params.alias, tableId: params.tableId, fieldId: params.fieldId, recordId: params.recordId },
|
|
1335
1382
|
});
|
|
1336
1383
|
},
|
|
1337
1384
|
/**
|
|
@@ -1340,7 +1387,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1340
1387
|
* Updates a solution using the QBL from the specified record.
|
|
1341
1388
|
We are releasing schema coverage for QBL in stages. See [what's supported today](https://helpv2.quickbase.com/hc/en-us/sections/26699387198228-QBL-Versions) in our QBL documentation.
|
|
1342
1389
|
*
|
|
1343
|
-
* @param params.solutionId - The unique identifier of the solution.
|
|
1390
|
+
* @param params.solutionId - The unique identifier (UUID) or the alias of the solution.
|
|
1344
1391
|
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
1345
1392
|
* @param params.fieldId - The unique identifier (fid) of the field. It needs to be a file attachment field.
|
|
1346
1393
|
* @param params.recordId - The unique identifier of the record.
|
|
@@ -1359,10 +1406,10 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1359
1406
|
/**
|
|
1360
1407
|
* List solution changes
|
|
1361
1408
|
*
|
|
1362
|
-
* Returns a list of changes that would occur if the provided QBL were to be applied. Learn more about [QBL syntax](https://help.quickbase.com/hc/en-us/articles/24845511223828-What-is-QBL).
|
|
1363
|
-
|
|
1409
|
+
* Returns a list of changes that would occur if the provided QBL were to be applied to the solution, without actually making those changes. This is useful for validating changes or previewing the impact before updating a solution. Learn more about [QBL syntax](https://help.quickbase.com/hc/en-us/articles/24845511223828-What-is-QBL).
|
|
1410
|
+
We are releasing schema coverage for QBL in stages. See [what's supported today](https://helpv2.quickbase.com/hc/en-us/sections/26699387198228-QBL-Versions) in our QBL documentation.
|
|
1364
1411
|
*
|
|
1365
|
-
* @param params.solutionId - The unique identifier of the solution.
|
|
1412
|
+
* @param params.solutionId - The unique identifier (UUID) or the alias of the solution.
|
|
1366
1413
|
*
|
|
1367
1414
|
* @param body - The QBL to be used for the changeset.
|
|
1368
1415
|
*
|
|
@@ -1375,6 +1422,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1375
1422
|
method: 'PUT',
|
|
1376
1423
|
path: `/solutions/${params.solutionId}/changeset`,
|
|
1377
1424
|
body,
|
|
1425
|
+
bodyType: 'application/x-yaml',
|
|
1378
1426
|
});
|
|
1379
1427
|
},
|
|
1380
1428
|
/**
|
|
@@ -1383,7 +1431,7 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1383
1431
|
* Returns a list of changes that would occur if the QBL from the provided record were to be applied.
|
|
1384
1432
|
We are releasing schema coverage for QBL in stages. See [what's supported today](https://helpv2.quickbase.com/hc/en-us/sections/26699387198228-QBL-Versions) in our QBL documentation.
|
|
1385
1433
|
*
|
|
1386
|
-
* @param params.solutionId - The unique identifier of the solution.
|
|
1434
|
+
* @param params.solutionId - The unique identifier (UUID) or the alias of the solution.
|
|
1387
1435
|
* @param params.tableId - The unique identifier (dbid) of the table.
|
|
1388
1436
|
* @param params.fieldId - The unique identifier (fid) of the field. It needs to be a file attachment field.
|
|
1389
1437
|
* @param params.recordId - The unique identifier of the record.
|
|
@@ -1399,33 +1447,6 @@ export function createApiMethods(request, autoPaginate = false) {
|
|
|
1399
1447
|
query: { tableId: params.tableId, fieldId: params.fieldId, recordId: params.recordId },
|
|
1400
1448
|
});
|
|
1401
1449
|
},
|
|
1402
|
-
/**
|
|
1403
|
-
* Generate a document
|
|
1404
|
-
*
|
|
1405
|
-
* Generates a document from a template. After changing a template, allow up to 15 minutes for documents generated via the API to reflect the changes. This feature is only available on business or enterprise plans.
|
|
1406
|
-
*
|
|
1407
|
-
* @param params.templateId - This is the ID of document template.
|
|
1408
|
-
* @param params.tableId - The unique identifier of the table.
|
|
1409
|
-
* @param params.recordId - The ID of the record (optional)
|
|
1410
|
-
* @param params.filename - File name for the downloaded file
|
|
1411
|
-
* @param params.format - The format of the file that is returned. Default is "pdf". (optional)
|
|
1412
|
-
* @param params.margin - Margin formatted as top right bottom left, separated by spaces. Add to override the value set in the template builder. (optional)
|
|
1413
|
-
* @param params.unit - Unit of measurement for the margin. Default is "in". Add to override the value set in the template builder. (optional)
|
|
1414
|
-
* @param params.pageSize - Page size. Default is "A4". Add to override the value set in the template builder. (optional)
|
|
1415
|
-
* @param params.orientation - Page orientation. Default is "portrait". Add to override the value set in the template builder. (optional)
|
|
1416
|
-
* @param params.realm - Your Quickbase domain, for example demo.quickbase.com (optional)
|
|
1417
|
-
*
|
|
1418
|
-
* @returns Success
|
|
1419
|
-
*
|
|
1420
|
-
* @see https://developer.quickbase.com/operation/generateDocument
|
|
1421
|
-
*/
|
|
1422
|
-
generateDocument(params) {
|
|
1423
|
-
return request({
|
|
1424
|
-
method: 'GET',
|
|
1425
|
-
path: `/docTemplates/${params.templateId}/generate`,
|
|
1426
|
-
query: { tableId: params.tableId, recordId: params.recordId, filename: params.filename, format: params.format, margin: params.margin, unit: params.unit, pageSize: params.pageSize, orientation: params.orientation, realm: params.realm },
|
|
1427
|
-
});
|
|
1428
|
-
},
|
|
1429
1450
|
/**
|
|
1430
1451
|
* Get solution information
|
|
1431
1452
|
*
|