├── .gitignore ├── src ├── .npmignore ├── types │ └── global.d.ts ├── tests │ └── quickbaseError.ts └── code-generation │ └── build.ts ├── .env.example ├── docs ├── _config.yml ├── .nojekyll ├── assets │ ├── navigation.js │ └── highlight.css └── types │ ├── QuickBaseResponseDownloadFile.html │ ├── QuickBaseResponseCreateSolution.html │ ├── QuickBaseResponseExportSolution.html │ ├── QuickBaseResponseUpdateSolution.html │ ├── QuickBaseRequestCreateSolution.html │ ├── QuickBaseRequestDeleteUserToken.html │ ├── QuickBaseRequestDeactivateUserToken.html │ ├── QuickBaseResponseRunFormula.html │ ├── QuickBaseResponseDeleteUserToken.html │ ├── QuickBaseResponseDeleteApp.html │ ├── QuickBaseResponseDeleteTable.html │ ├── QuickBaseResponseDeactivateUserToken.html │ ├── QuickBaseResponseDeleteRecords.html │ ├── QuickBaseResponseDeleteRelationship.html │ ├── QuickBaseResponseGetTempTokenDBID.html │ ├── QuickBaseRequestGetApp.html │ ├── QuickBaseRequestGetAppEvents.html │ ├── QuickBaseRequestGetAppTables.html │ ├── QuickBaseRequestExportSolution.html │ ├── QuickBaseRequestUpdateSolution.html │ ├── QuickBaseRequestGetTableReports.html │ ├── QuickBaseRequestGetTempTokenDBID.html │ ├── QuickBaseRequestAddMembersToGroup.html │ ├── QuickBaseRequestAddManagersToGroup.html │ ├── QuickBaseRequestAddSubgroupsToGroup.html │ ├── QuickBaseRequestRemoveMembersFromGroup.html │ ├── QuickBaseRequestRemoveManagersFromGroup.html │ ├── QuickBaseRequestRemoveSubgroupsFromGroup.html │ ├── QuickBaseRequestDenyUsers.html │ ├── QuickBaseRequestUndenyUsers.html │ ├── QuickBaseRequest.html │ ├── QuickBaseRequestPlatformAnalyticReads.html │ ├── QuickBaseRequestGetTable.html │ ├── QuickBaseRequestDeleteApp.html │ └── QuickBaseRequestDeleteTable.html ├── dist ├── .npmignore └── .gitignore ├── .npmignore ├── ava.config.mjs ├── .editorconfig ├── LICENSE ├── tsconfig.json ├── package.json └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules/ 2 | .env 3 | -------------------------------------------------------------------------------- /src/.npmignore: -------------------------------------------------------------------------------- 1 | * 2 | !quickbase.ts 3 | -------------------------------------------------------------------------------- /.env.example: -------------------------------------------------------------------------------- 1 | QB_REALM=www 2 | QB_USERTOKEN= -------------------------------------------------------------------------------- /docs/_config.yml: -------------------------------------------------------------------------------- 1 | include: 2 | - "_*_.html" 3 | - "_*_.*.html" -------------------------------------------------------------------------------- /src/types/global.d.ts: -------------------------------------------------------------------------------- 1 | interface Window { 2 | QuickBase: any; 3 | } 4 | -------------------------------------------------------------------------------- /dist/.npmignore: -------------------------------------------------------------------------------- 1 | tests/ 2 | quickbase.browserify.min.js 3 | quickbase.browserify.min.js.map 4 | -------------------------------------------------------------------------------- /dist/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !.gitignore 3 | !.npmignore 4 | !quickbase.browserify.min.js 5 | !quickbase.browserify.min.js.map 6 | -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | assets/ 2 | docs/ 3 | .editorconfig 4 | .env 5 | .env.example 6 | ava.config.mjs 7 | package-lock.json 8 | tsconfig.json 9 | -------------------------------------------------------------------------------- /docs/.nojekyll: -------------------------------------------------------------------------------- 1 | TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false. -------------------------------------------------------------------------------- /ava.config.mjs: -------------------------------------------------------------------------------- 1 | export default { 2 | "files": [ 3 | "./src/tests/**/*" 4 | ], 5 | "failFast": true, 6 | "failWithoutAssertions": false, 7 | "verbose": true, 8 | "timeout": "1m", 9 | "typescript": { 10 | "extensions": [ 11 | "ts" 12 | ], 13 | "rewritePaths": { 14 | "src/": "dist/" 15 | }, 16 | "compile": false 17 | } 18 | } -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | charset = utf-8 5 | end_of_line = lf 6 | indent_style = tab 7 | # Omitting indent_size allows developers to define their own tab width 8 | # indent_size = 4 9 | insert_final_newline = true 10 | trim_trailing_whitespace = true 11 | 12 | # Ignore Dependencies and Generated Material 13 | [{node_modules,docs,dist,assets}/**] 14 | charset = unset 15 | end_of_line = unset 16 | indent_size = unset 17 | indent_style = unset 18 | trim_trailing_whitespace = unset 19 | insert_final_newline = unset 20 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2014 Tristian Flanagan 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. 14 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "lib": [ 4 | "ES6", 5 | "DOM" 6 | ], 7 | "target": "ES6", 8 | "module": "CommonJS", 9 | "moduleResolution": "Node", 10 | "outDir": "./dist/", 11 | "declaration": true, 12 | "allowJs": false, 13 | "sourceMap": true, 14 | "rootDir": "./src/", 15 | "removeComments": false, 16 | "strict": true, 17 | "noUnusedLocals": true, 18 | "noUnusedParameters": true, 19 | "noImplicitReturns": true, 20 | "noFallthroughCasesInSwitch": true, 21 | "esModuleInterop": true, 22 | "forceConsistentCasingInFileNames": true 23 | }, 24 | "include": [ 25 | "./src/types/**/*", 26 | "./src/tests/**/*", 27 | "./src/quickbase.ts" 28 | ], 29 | "ts-node": { 30 | "files": true 31 | }, 32 | "typedocOptions": { 33 | "readme": "./README.md", 34 | "out": "./docs/", 35 | "theme": "default", 36 | "name": "Node-Quickbase", 37 | "includeVersion": true, 38 | "excludeExternals": true 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /src/tests/quickbaseError.ts: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | /* Dependencies */ 4 | import ava from 'ava'; 5 | import { QuickBaseError } from '../quickbase'; 6 | 7 | /* Tests */ 8 | const errObj = { 9 | code: 403, 10 | message: 'Access Denied', 11 | description: 'User token is invalid', 12 | rayId: 'xxxx' 13 | }; 14 | 15 | const qbErr = new QuickBaseError(errObj.code, errObj.message, errObj.description, errObj.rayId); 16 | 17 | ava.serial('QuickBaseError', async (t) => { 18 | return t.truthy(qbErr.code === errObj.code && qbErr.message === errObj.message && qbErr.description === errObj.description && qbErr.rayId === errObj.rayId); 19 | }); 20 | 21 | ava.serial('toJSON()', async (t) => { 22 | return t.truthy(JSON.stringify(qbErr.toJSON()) === JSON.stringify(errObj)); 23 | }); 24 | 25 | ava.serial('fromJSON()', async (t) => { 26 | qbErr.fromJSON(errObj); 27 | 28 | return t.truthy(JSON.stringify(qbErr.toJSON()) === JSON.stringify(errObj)); 29 | }); 30 | 31 | ava.serial('FromJSON()', async (t) => { 32 | const nQbErr = QuickBaseError.fromJSON(errObj); 33 | 34 | return t.truthy(JSON.stringify(nQbErr.toJSON()) === JSON.stringify(errObj)); 35 | }); 36 | -------------------------------------------------------------------------------- /docs/assets/navigation.js: -------------------------------------------------------------------------------- 1 | window.navigationData = "data:application/octet-stream;base64,H4sIAAAAAAAAE6WYzW6bQBhF38XrqG0iVW2zc5oftVKbxk5WVRYTM41RgKH8pLGqvnsxGDLA4Lnf9dY+9zsGhgHfn39nhX4pZqezmzJcPZ2pXM+OZqkq1tVHq0jluc7fdl+9WRdxVH3/FCbB7PT45OO/o3H+IstMtmdI/T0+6evy+vvrtGKTjmZtif68k3efPhy/P3HNvE6L0CT55MTd9/C8hf5d6ryYnLf7XjpvHgTfVKIedZbfmqvMlKnPME4wTh0/yJS9AGFclg+P26jAOYyIrWUQei9YDUknf45Mou9ynd2aJ534FH1a7DLpZp56z9cOE0/PtCo0Mr8FOcNlqKMAc9QoZ1noSNW39ToED8hOcM6licrtBMzX0pzrVj1EGhPVqNRyrtWqCJ+rOLy4HRG5NdLQGuxAzlAvrOkngoNlPf6L9EpyjoVemQw9mB3MmvB7apzgnNA6t1DOIljjPVxuSzbbMHC1diBtmCdB/ajEVV1C7DR/ksioAFrtFiv1XLys1ip51MvcQBdryMt9qckKdFfv01LXlS6Aba+huNkXzzopvKvBZjlPfRuCnoYlPNBLRMux8+/y6t0aldQwa0JOF/cc6oKig8nZo7E3fOSgejzl2950kGgLEgboAdRy7Pzm1yEnzMYZm47Tei88P/tyjuhsnvBBD7uWk87/Ua2dXyaL54mKNkW4qnetZRnHKgv9O9D+9KG/ZaGV/652hqTmhY7Ns26LgMvMxNC/6okYaW86Aal8kOLcXTcgtI9zYn+ZXFZXr4yU19iRhOOm1NkGMNQcMR/bQztQarhLAvSt10LFljTA2osO5AzQi4eFchbJP61xgnOi77l9mnNBD1ULlVuqNeRd0g0lmJ2n1QnWoqJ2KkJZ0ap2IsE4BWXtZEbu9dS1FiWeDRe2Llxu81a2PU4+HyhtByTp8G18I5b0gFvfVIS0ApufCydtvu1vxIo9svp2MkN4/QXugCQd3v/NY5g2AReLanHtqL/GddC0S3CPHdTk2iOwVc91uXZWsuLZNrfN+19sByTvQArdqYjcilW6Y1hsEpS67gBhBGtdFy62eYtdGyOne6vdMUyavOXuGGZM2MsG0e/2g75O1EHTLuikkc8puOR14YwNrXndAc7oKSkGJOPAHlBE19sP+steJ0/5wLrXHWCM2OOQaHybIF35IvGDf42v9N2TErvlte/eHOvHi999MdIuqn73B+W/ACl/hyhj8dW/fZAxgHsr0wA3SawCHrFyD1ACD0jSgb2gcD2wnRX9UzuoCbZHwO/GdBdsx7HHLtcGt1lPHWxj7un3/wFgylnwNy0AAA==" -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "quickbase", 3 | "version": "6.0.0", 4 | "description": "A lightweight, typed, promise-based Quickbase API, autogenerated from the OpenAPI spec", 5 | "keywords": [ 6 | "QuickBase", 7 | "quickbase", 8 | "Quick Base", 9 | "quick base", 10 | "qb", 11 | "api" 12 | ], 13 | "homepage": "https://github.com/tflanagan/node-quickbase", 14 | "bugs": { 15 | "url": "https://github.com/tflanagan/node-quickbase/issues", 16 | "email": "contact@tristianflanagan.com" 17 | }, 18 | "license": "Apache-2.0", 19 | "author": { 20 | "name": "Tristian Flanagan", 21 | "url": "https://github.com/tflanagan", 22 | "email": "contact@tristianflanagan.com" 23 | }, 24 | "maintainers": [], 25 | "contributors": [], 26 | "main": "./dist/quickbase.js", 27 | "types": "./dist/quickbase.d.ts", 28 | "repository": { 29 | "type": "git", 30 | "url": "git://github.com/tflanagan/node-quickbase.git" 31 | }, 32 | "scripts": { 33 | "build": "ts-node ./src/code-generation/build.ts", 34 | "cleanup": "rm -rf ./dist/quickbase* && rm -rf ./dist/tests", 35 | "compile": "npm run cleanup && npm run generate && npm run build && npm run test && npm run docs", 36 | "docs": "mv ./docs/_config.yml ./ && npx typedoc src/quickbase.ts && mv ./_config.yml ./docs/", 37 | "generate": "ts-node ./src/code-generation/generate.ts", 38 | "test": "npx ava" 39 | }, 40 | "dependencies": { 41 | "axios": "^1.6.8", 42 | "debug": "^4.3.4", 43 | "deepmerge": "^4.3.1", 44 | "generic-throttle": "^3.1.0" 45 | }, 46 | "devDependencies": { 47 | "@ava/typescript": "^3.0.1", 48 | "@types/debug": "^4.1.12", 49 | "@types/node": "^20.12.7", 50 | "ava": "^4.3.3", 51 | "dotenv": "^16.4.5", 52 | "esbuild": "^0.21.1", 53 | "ts-node": "^10.9.2", 54 | "typedoc": "^0.25.13", 55 | "typescript": "^5.4.5" 56 | }, 57 | "git": "git://github.com/tflanagan/node-quickbase.git" 58 | } 59 | -------------------------------------------------------------------------------- /docs/assets/highlight.css: -------------------------------------------------------------------------------- 1 | :root { 2 | --light-hl-0: #0070C1; 3 | --dark-hl-0: #4FC1FF; 4 | --light-hl-1: #000000; 5 | --dark-hl-1: #D4D4D4; 6 | --light-hl-2: #098658; 7 | --dark-hl-2: #B5CEA8; 8 | --light-hl-3: #001080; 9 | --dark-hl-3: #9CDCFE; 10 | --light-hl-4: #AF00DB; 11 | --dark-hl-4: #C586C0; 12 | --light-hl-5: #0000FF; 13 | --dark-hl-5: #569CD6; 14 | --light-hl-6: #000000; 15 | --dark-hl-6: #C8C8C8; 16 | --light-hl-7: #A31515; 17 | --dark-hl-7: #CE9178; 18 | --light-hl-8: #CD3131; 19 | --dark-hl-8: #F44747; 20 | --light-hl-9: #795E26; 21 | --dark-hl-9: #DCDCAA; 22 | --light-hl-10: #008000; 23 | --dark-hl-10: #6A9955; 24 | --light-hl-11: #267F99; 25 | --dark-hl-11: #4EC9B0; 26 | --light-code-background: #FFFFFF; 27 | --dark-code-background: #1E1E1E; 28 | } 29 | 30 | @media (prefers-color-scheme: light) { :root { 31 | --hl-0: var(--light-hl-0); 32 | --hl-1: var(--light-hl-1); 33 | --hl-2: var(--light-hl-2); 34 | --hl-3: var(--light-hl-3); 35 | --hl-4: var(--light-hl-4); 36 | --hl-5: var(--light-hl-5); 37 | --hl-6: var(--light-hl-6); 38 | --hl-7: var(--light-hl-7); 39 | --hl-8: var(--light-hl-8); 40 | --hl-9: var(--light-hl-9); 41 | --hl-10: var(--light-hl-10); 42 | --hl-11: var(--light-hl-11); 43 | --code-background: var(--light-code-background); 44 | } } 45 | 46 | @media (prefers-color-scheme: dark) { :root { 47 | --hl-0: var(--dark-hl-0); 48 | --hl-1: var(--dark-hl-1); 49 | --hl-2: var(--dark-hl-2); 50 | --hl-3: var(--dark-hl-3); 51 | --hl-4: var(--dark-hl-4); 52 | --hl-5: var(--dark-hl-5); 53 | --hl-6: var(--dark-hl-6); 54 | --hl-7: var(--dark-hl-7); 55 | --hl-8: var(--dark-hl-8); 56 | --hl-9: var(--dark-hl-9); 57 | --hl-10: var(--dark-hl-10); 58 | --hl-11: var(--dark-hl-11); 59 | --code-background: var(--dark-code-background); 60 | } } 61 | 62 | :root[data-theme='light'] { 63 | --hl-0: var(--light-hl-0); 64 | --hl-1: var(--light-hl-1); 65 | --hl-2: var(--light-hl-2); 66 | --hl-3: var(--light-hl-3); 67 | --hl-4: var(--light-hl-4); 68 | --hl-5: var(--light-hl-5); 69 | --hl-6: var(--light-hl-6); 70 | --hl-7: var(--light-hl-7); 71 | --hl-8: var(--light-hl-8); 72 | --hl-9: var(--light-hl-9); 73 | --hl-10: var(--light-hl-10); 74 | --hl-11: var(--light-hl-11); 75 | --code-background: var(--light-code-background); 76 | } 77 | 78 | :root[data-theme='dark'] { 79 | --hl-0: var(--dark-hl-0); 80 | --hl-1: var(--dark-hl-1); 81 | --hl-2: var(--dark-hl-2); 82 | --hl-3: var(--dark-hl-3); 83 | --hl-4: var(--dark-hl-4); 84 | --hl-5: var(--dark-hl-5); 85 | --hl-6: var(--dark-hl-6); 86 | --hl-7: var(--dark-hl-7); 87 | --hl-8: var(--dark-hl-8); 88 | --hl-9: var(--dark-hl-9); 89 | --hl-10: var(--dark-hl-10); 90 | --hl-11: var(--dark-hl-11); 91 | --code-background: var(--dark-code-background); 92 | } 93 | 94 | .hl-0 { color: var(--hl-0); } 95 | .hl-1 { color: var(--hl-1); } 96 | .hl-2 { color: var(--hl-2); } 97 | .hl-3 { color: var(--hl-3); } 98 | .hl-4 { color: var(--hl-4); } 99 | .hl-5 { color: var(--hl-5); } 100 | .hl-6 { color: var(--hl-6); } 101 | .hl-7 { color: var(--hl-7); } 102 | .hl-8 { color: var(--hl-8); } 103 | .hl-9 { color: var(--hl-9); } 104 | .hl-10 { color: var(--hl-10); } 105 | .hl-11 { color: var(--hl-11); } 106 | pre, code { background: var(--code-background); } 107 | -------------------------------------------------------------------------------- /src/code-generation/build.ts: -------------------------------------------------------------------------------- 1 | /* Types */ 2 | type Person = { 3 | name: string; 4 | email: string; 5 | url: string; 6 | }; 7 | 8 | /* Dependencies */ 9 | import { 10 | readFile, 11 | writeFile 12 | } from 'fs/promises'; 13 | import { 14 | exec as execNode 15 | } from 'child_process'; 16 | 17 | import Debug from 'debug'; 18 | import * as esbuild from 'esbuild'; 19 | 20 | const pkg = require('../../package.json'); 21 | const debug = Debug('quickbase:build'); 22 | 23 | /* Helpers */ 24 | const exec = async (cmd: string): Promise => { 25 | return new Promise((resolve, reject) => { 26 | execNode(cmd, (err, stdout, stderr) => { 27 | if(err){ 28 | return reject(err); 29 | } 30 | 31 | if(stderr && !stderr.match(/ExperimentalWarning/)){ 32 | err = new Error(`Command failed: ${cmd}`); 33 | 34 | return reject(err); 35 | } 36 | 37 | resolve(stdout); 38 | }); 39 | }); 40 | }; 41 | 42 | const formatPerson = (person: Person) => { 43 | if(typeof(person) === 'string'){ 44 | return person; 45 | } 46 | 47 | const parts: string[] = []; 48 | 49 | if(person.name){ 50 | parts.push(person.name); 51 | } 52 | 53 | if(person.email){ 54 | parts.push(`<${person.email}>`); 55 | } 56 | 57 | if(person.url){ 58 | parts.push(`(${person.url})`); 59 | } 60 | 61 | return parts.join(' '); 62 | }; 63 | 64 | /* Build */ 65 | (async () => { 66 | try { 67 | const mainFilename = pkg.name; 68 | 69 | debug('Compiling TypeScript...'); 70 | await exec('npx tsc'); 71 | 72 | debug('Compiling for Browser...'); 73 | await esbuild.build({ 74 | entryPoints: [ `./dist/${mainFilename}.js` ], 75 | bundle: true, 76 | minify: true, 77 | sourcemap: true, 78 | target: ['es2015'], 79 | outfile: `./dist/${mainFilename}.browserify.min.js` 80 | }); 81 | 82 | debug('Loading Source...'); 83 | const browserSource = await readFile(`./dist/${mainFilename}.browserify.min.js`).then((val) => val.toString().trim()); 84 | const cjsSrc = await readFile(`./dist/${mainFilename}.js`).then((val) => val.toString().trim()); 85 | 86 | debug('Loading License...'); 87 | const license = (await readFile('./LICENSE')).toString().trim(); 88 | 89 | debug('Prepending Build and Package Information...'); 90 | const projectInfo = [ 91 | '/*!', 92 | ` * Package Name: ${pkg.name}`, 93 | ` * Package Description: ${pkg.description}`, 94 | ` * Version: ${pkg.version}`, 95 | ` * Build Timestamp: ${new Date().toISOString()}`, 96 | ` * Package Homepage: ${pkg.homepage}`, 97 | ` * Git Location: ${pkg.repository.url}`, 98 | ` * Authored By: ${formatPerson(pkg.author)}`, 99 | pkg.maintainers && pkg.maintainers.length > 0 ? [ 100 | ' * Maintained By:', 101 | pkg.maintainers.map((maintainer: Person) => { 102 | return ` * - ${formatPerson(maintainer)}`; 103 | }).join('\n'), 104 | ].join('\n') : '', 105 | pkg.contributors && pkg.contributors.length > 0 ? [ 106 | ' * Contributors:', 107 | pkg.contributors.map((contributor: Person) => { 108 | return ` * - ${formatPerson(contributor)}`; 109 | }).join('\n'), 110 | ].join('\n') : '', 111 | ` * License: ${pkg.license}`, 112 | ' *', 113 | license.split('\n').map((line) => { 114 | return ' * ' + line; 115 | }).join('\n'), 116 | '*/', 117 | ].filter((val) => { 118 | return !!val; 119 | }).join('\n').trim(); 120 | 121 | await Promise.all([ 122 | writeFile(`./dist/${mainFilename}.browserify.min.js`, [ 123 | projectInfo, 124 | browserSource.trim() 125 | ].join('\n')), 126 | writeFile(`./dist/${mainFilename}.js`, [ 127 | projectInfo, 128 | cjsSrc.trim() 129 | ].join('\n')) 130 | ]); 131 | 132 | debug('Done building.'); 133 | }catch(err){ 134 | console.error(err); 135 | } 136 | })(); 137 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | quickbase 2 | ========= 3 | 4 | [![npm license](https://img.shields.io/npm/l/quickbase.svg)](https://www.npmjs.com/package/quickbase) [![npm version](https://img.shields.io/npm/v/quickbase.svg)](https://www.npmjs.com/package/quickbase) [![npm downloads](https://img.shields.io/npm/dm/quickbase.svg)](https://www.npmjs.com/package/quickbase) 5 | 6 | A lightweight, typed, promise-based Quickbase API, autogenerated from the OpenAPI spec 7 | 8 | Written in TypeScript, targets Nodejs and the Browser. 9 | 10 | A large chunk of this library is generated based on the OpenAPI definition found at [https://developer.quickbase.com/](https://developer.quickbase.com/). 11 | 12 | All the types and public methods are generated and kept updated directly from the OpenAPI definition. 13 | 14 | You can find this code in `src/code-generation/`. 15 | 16 | This library targets the RESTful, JSON-based API, not the XML-based API. If you want to use the XML-based API, then please use [v2.x](https://github.com/tflanagan/node-quickbase/tree/v2.x/) of this library. 17 | 18 | ``` 19 | IE 11 Users, if you are receiving this error: 20 | XMLHttpRequest: Network Error 0x80070005, Access is denied. 21 | 22 | This is not a limitation of the library, just how Quickbase's new API works. 23 | In order to use the new RESTful JSON-based API in Internet Explorer, you must 24 | change a security setting: 25 | 26 | - Go to Internet Options -> Security -> Custom Level 27 | - Scroll down to and find the "Miscellaneous" section 28 | - Ensure "Access data sources across domains" is set to "Enable" 29 | - Click "OK", "Yes", "OK" 30 | ``` 31 | 32 | Install 33 | ------- 34 | ``` 35 | # Install 36 | $ npm install --save quickbase 37 | ``` 38 | 39 | Documentation 40 | ------------- 41 | 42 | [TypeDoc Documentation](https://tflanagan.github.io/node-quickbase/) 43 | [Quickbase Documentation](https://developer.quickbase.com/) 44 | 45 | Server-Side Example 46 | ------------------- 47 | ```typescript 48 | import { QuickBase } from 'quickbase'; 49 | 50 | const quickbase = new QuickBase({ 51 | realm: 'www', 52 | userToken: 'xxxxxx_xxx_xxxxxxxxxxxxxxxxxxxxxxxxxx' 53 | // Use tempToken if utilizing an authentication token sent 54 | // up from client-side code. If possible, this is preferred. 55 | // tempToken: 'xxxxxx_xxx_xxxxxxxxxxxxxxxxxxxxxxxxxx', 56 | // appToken: 'xxxxxxxxxxxxxxxxxxxxxxxxxxxx' 57 | }); 58 | 59 | (async () => { 60 | try { 61 | const results = await quickbase.getApp({ 62 | appId: 'xxxxxxxxx' 63 | }); 64 | 65 | console.log(results.name); 66 | }catch(err){ 67 | console.error(err); 68 | } 69 | })(); 70 | ``` 71 | 72 | Client-Side Example 73 | ------------------- 74 | Import `QuickBase` by loading `quickbase.browserify.min.js` 75 | 76 | ```javascript 77 | var quickbase = new QuickBase({ 78 | realm: 'www', 79 | appToken: 'xxxxxxxxxxxxxxxxxxxxxxxxxxxx' 80 | }); 81 | 82 | // Using a Temporary Token 83 | quickbase.getTempTokenDBID({ 84 | dbid: 'xxxxxxxxx' 85 | }).then(function(results){ 86 | return quickbase.getApp({ 87 | appId: 'xxxxxxxxx' 88 | }); 89 | }).then(function(results){ 90 | console.log(results.name); 91 | }).catch(function(err){ 92 | console.error(err); 93 | }); 94 | ``` 95 | 96 | Debugging 97 | --------- 98 | 99 | Server-side, set the environment variable `DEBUG` to `quickbase:*`. 100 | 101 | In the browser, open the dev console and enter: `window.localStorage.debug = 'quickbase:*'`. 102 | 103 | The used debug namespaces: `main`, `request`, `response` and for development: `build` and `generate`. 104 | 105 | Development 106 | ----------- 107 | 108 | ``` 109 | # Fork and clone the repository 110 | $ yarn install 111 | $ git checkout -b feature/branch 112 | # Download the latest OAS definition and replace in `assets/QuickBase_RESTful_API.json` 113 | $ yarn run generate 114 | # Manually modify as required 115 | $ yarn run build 116 | $ yarn run test 117 | $ yarn run docs 118 | $ git add 119 | $ git commit 120 | $ git push -u origin feature/branch 121 | ``` 122 | 123 | License 124 | ------- 125 | Copyright 2014 Tristian Flanagan 126 | 127 | Licensed under the Apache License, Version 2.0 (the "License"); 128 | you may not use this file except in compliance with the License. 129 | You may obtain a copy of the License at 130 | 131 | http://www.apache.org/licenses/LICENSE-2.0 132 | 133 | Unless required by applicable law or agreed to in writing, software 134 | distributed under the License is distributed on an "AS IS" BASIS, 135 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 136 | See the License for the specific language governing permissions and 137 | limitations under the License. 138 | -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseDownloadFile.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseDownloadFile | Node-Quickbase - v6.0.0

Type alias QuickBaseResponseDownloadFile

QuickBaseResponseDownloadFile: string
-------------------------------------------------------------------------------- /docs/types/QuickBaseResponseCreateSolution.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseCreateSolution | Node-Quickbase - v6.0.0

Type alias QuickBaseResponseCreateSolution

QuickBaseResponseCreateSolution: any
-------------------------------------------------------------------------------- /docs/types/QuickBaseResponseExportSolution.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseExportSolution | Node-Quickbase - v6.0.0

Type alias QuickBaseResponseExportSolution

QuickBaseResponseExportSolution: any
-------------------------------------------------------------------------------- /docs/types/QuickBaseResponseUpdateSolution.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseUpdateSolution | Node-Quickbase - v6.0.0

Type alias QuickBaseResponseUpdateSolution

QuickBaseResponseUpdateSolution: any
-------------------------------------------------------------------------------- /docs/types/QuickBaseRequestCreateSolution.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestCreateSolution | Node-Quickbase - v6.0.0

Type alias QuickBaseRequestCreateSolution

QuickBaseRequestCreateSolution: QuickBaseRequest & {}

Type declaration

    -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestDeleteUserToken.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestDeleteUserToken | Node-Quickbase - v6.0.0

    Type alias QuickBaseRequestDeleteUserToken

    QuickBaseRequestDeleteUserToken: QuickBaseRequest & {}

    Type declaration

      -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestDeactivateUserToken.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestDeactivateUserToken | Node-Quickbase - v6.0.0

      Type alias QuickBaseRequestDeactivateUserToken

      QuickBaseRequestDeactivateUserToken: QuickBaseRequest & {}

      Type declaration

        -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseRunFormula.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseRunFormula | Node-Quickbase - v6.0.0

        Type alias QuickBaseResponseRunFormula

        QuickBaseResponseRunFormula: {
            result: string;
        }

        Type declaration

        • result: string

          The formula execution result.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseDeleteUserToken.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseDeleteUserToken | Node-Quickbase - v6.0.0

        Type alias QuickBaseResponseDeleteUserToken

        QuickBaseResponseDeleteUserToken: {
            id: number;
        }

        Type declaration

        • id: number

          The user token id.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseDeleteApp.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseDeleteApp | Node-Quickbase - v6.0.0

        Type alias QuickBaseResponseDeleteApp

        QuickBaseResponseDeleteApp: {
            deletedAppId: string;
        }

        Type declaration

        • deletedAppId: string

          An ID of deleted application.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseDeleteTable.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseDeleteTable | Node-Quickbase - v6.0.0

        Type alias QuickBaseResponseDeleteTable

        QuickBaseResponseDeleteTable: {
            deletedTableId: string;
        }

        Type declaration

        • deletedTableId: string

          The deleted table id.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseDeactivateUserToken.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseDeactivateUserToken | Node-Quickbase - v6.0.0

        Type alias QuickBaseResponseDeactivateUserToken

        QuickBaseResponseDeactivateUserToken: {
            id: number;
        }

        Type declaration

        • id: number

          The user token id.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseDeleteRecords.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseDeleteRecords | Node-Quickbase - v6.0.0

        Type alias QuickBaseResponseDeleteRecords

        QuickBaseResponseDeleteRecords: {
            numberDeleted: number;
        }

        Type declaration

        • numberDeleted: number

          The number of records deleted.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseDeleteRelationship.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseDeleteRelationship | Node-Quickbase - v6.0.0

        Type alias QuickBaseResponseDeleteRelationship

        QuickBaseResponseDeleteRelationship: {
            relationshipId: number;
        }

        Type declaration

        • relationshipId: number

          The relationship id.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseResponseGetTempTokenDBID.html: -------------------------------------------------------------------------------- 1 | QuickBaseResponseGetTempTokenDBID | Node-Quickbase - v6.0.0

        Type alias QuickBaseResponseGetTempTokenDBID

        QuickBaseResponseGetTempTokenDBID: {
            temporaryAuthorization: string;
        }

        Type declaration

        • temporaryAuthorization: string

          Temporary authorization token.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestGetApp.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestGetApp | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestGetApp

        QuickBaseRequestGetApp: QuickBaseRequest & {
            appId: string;
        }

        Type declaration

        • appId: string

          The unique identifier of an app

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestGetAppEvents.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestGetAppEvents | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestGetAppEvents

        QuickBaseRequestGetAppEvents: QuickBaseRequest & {
            appId: string;
        }

        Type declaration

        • appId: string

          The unique identifier of an app

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestGetAppTables.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestGetAppTables | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestGetAppTables

        QuickBaseRequestGetAppTables: QuickBaseRequest & {
            appId: string;
        }

        Type declaration

        • appId: string

          The unique identifier of an app

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestExportSolution.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestExportSolution | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestExportSolution

        QuickBaseRequestExportSolution: QuickBaseRequest & {
            solutionId: string;
        }

        Type declaration

        • solutionId: string

          The unique identifier of a solution

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestUpdateSolution.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestUpdateSolution | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestUpdateSolution

        QuickBaseRequestUpdateSolution: QuickBaseRequest & {
            solutionId: string;
        }

        Type declaration

        • solutionId: string

          The unique identifier of a solution

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestGetTableReports.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestGetTableReports | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestGetTableReports

        QuickBaseRequestGetTableReports: QuickBaseRequest & {
            tableId: string;
        }

        Type declaration

        • tableId: string

          The unique identifier of the table.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestGetTempTokenDBID.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestGetTempTokenDBID | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestGetTempTokenDBID

        QuickBaseRequestGetTempTokenDBID: QuickBaseRequest & {
            dbid: string;
        }

        Type declaration

        • dbid: string

          The unique identifier of an app or table.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestAddMembersToGroup.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestAddMembersToGroup | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestAddMembersToGroup

        QuickBaseRequestAddMembersToGroup: QuickBaseRequest & {
            gid: number;
        }

        Type declaration

        • gid: number

          This is the ID of the group being modified.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestAddManagersToGroup.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestAddManagersToGroup | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestAddManagersToGroup

        QuickBaseRequestAddManagersToGroup: QuickBaseRequest & {
            gid: number;
        }

        Type declaration

        • gid: number

          This is the ID of the group being modified.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestAddSubgroupsToGroup.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestAddSubgroupsToGroup | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestAddSubgroupsToGroup

        QuickBaseRequestAddSubgroupsToGroup: QuickBaseRequest & {
            gid: number;
        }

        Type declaration

        • gid: number

          This is the ID of the group being modified.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestRemoveMembersFromGroup.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestRemoveMembersFromGroup | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestRemoveMembersFromGroup

        QuickBaseRequestRemoveMembersFromGroup: QuickBaseRequest & {
            gid: number;
        }

        Type declaration

        • gid: number

          This is the ID of the group being modified.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestRemoveManagersFromGroup.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestRemoveManagersFromGroup | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestRemoveManagersFromGroup

        QuickBaseRequestRemoveManagersFromGroup: QuickBaseRequest & {
            gid: number;
        }

        Type declaration

        • gid: number

          This is the ID of the group being modified.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestRemoveSubgroupsFromGroup.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestRemoveSubgroupsFromGroup | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestRemoveSubgroupsFromGroup

        QuickBaseRequestRemoveSubgroupsFromGroup: QuickBaseRequest & {
            gid: number;
        }

        Type declaration

        • gid: number

          This is the ID of the group being modified.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestDenyUsers.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestDenyUsers | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestDenyUsers

        QuickBaseRequestDenyUsers: QuickBaseRequest & {
            accountId?: number;
        }

        Type declaration

        • Optional accountId?: number

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

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestUndenyUsers.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestUndenyUsers | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestUndenyUsers

        QuickBaseRequestUndenyUsers: QuickBaseRequest & {
            accountId?: number;
        }

        Type declaration

        • Optional accountId?: number

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

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequest.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequest | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequest

        QuickBaseRequest: {
            requestOptions?: AxiosRequestConfig;
            returnAxios?: boolean;
        }

        Type declaration

        • Optional requestOptions?: AxiosRequestConfig
        • Optional returnAxios?: boolean
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestPlatformAnalyticReads.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestPlatformAnalyticReads | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestPlatformAnalyticReads

        QuickBaseRequestPlatformAnalyticReads: QuickBaseRequest & {
            day?: string;
        }

        Type declaration

        • Optional day?: string

          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.

          2 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestGetTable.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestGetTable | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestGetTable

        QuickBaseRequestGetTable: QuickBaseRequest & {
            appId: string;
            tableId: string;
        }

        Type declaration

        • appId: string

          The unique identifier of an app

          2 |
        • tableId: string

          The unique identifier (dbid) of the table.

          3 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestDeleteApp.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestDeleteApp | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestDeleteApp

        QuickBaseRequestDeleteApp: QuickBaseRequest & {
            appId: string;
            name: string;
        }

        Type declaration

        • appId: string

          The unique identifier of an app

          2 |
        • name: string

          To confirm application deletion we ask for application name.

          3 |
        -------------------------------------------------------------------------------- /docs/types/QuickBaseRequestDeleteTable.html: -------------------------------------------------------------------------------- 1 | QuickBaseRequestDeleteTable | Node-Quickbase - v6.0.0

        Type alias QuickBaseRequestDeleteTable

        QuickBaseRequestDeleteTable: QuickBaseRequest & {
            appId: string;
            tableId: string;
        }

        Type declaration

        • appId: string

          The unique identifier of an app

          2 |
        • tableId: string

          The unique identifier (dbid) of the table.

          3 |
        --------------------------------------------------------------------------------