API_CreateDatabase

Overview

Use API_CreateDatabase to create a new Quick Base application. Quick Base creates the main application table populated only with built-in fields and returns an application token for your API application. After you create the application, you'll need to:

Quick Base returns the application-level dbid (appdbid) in the response to API_CreateDatabase. Some API calls require the use of the application-level dbid, and some require a table-level dbid. Calls requiring application-level dbids are application-wide calls; calls requiring table-level dbids are those that manipulate tables. If you are going to manipulate the table or application after creating it, you will find it useful to extract and save these values from the response values.

top

Request parameters

Parameter Value Required?

dbname

The name of the new application

yes

dbdesc

The description for the new application.

yes

ticket

The ticket needed for application access.

yes

createapptoken

Set this parameter to 1 to generate an application token for your applications.

App tokens can also be generated from within Quick Base, but this method is provided for your convenience.

no

udata

A string value that you want returned. It will not be handled by Quick Base but it will be returned in the response.

no

top

Response values

Element Name Value

action

Echoes the originating request, for example, API_CreateDatabase.

errcode

Identifies the error code, if any. (See the Error Codes appendix for a list of possible error codes.)

0 indicates that no error was encountered.

errtext

Text that explains the error code.

"No error" indicates that no error was encountered.

udata

Contains any udata value supplied in the request.

dbid

The table-level dbid of the new application’s default table.

appdbid

The application-level dbid of the new application.

apptoken

An application token for your application to use in subsequent interactions with the Quick Base you just created. Returned only if you specified createapptoken with a value of 1 in the request.

top

Header and XML

POST https://target_domain/db/main HTTP/1.0
Content-Type: application/xml
Content-Length:
QUICKBASE-ACTION: API_CreateDatabase

top

Sample XML Request

<qdbapi>
   <dbname>FuelCharter</dbname>
   <dbdesc>Vehicle and Fuel Cost Tracker</dbdesc>
   <ticket>auth_ticket</ticket>
   <createapptoken>1</createapptoken>
</qdbapi>

top

URL alternative

https://target_domain/db/main?a=API_CreateDatabase&ticket=auth_ticket
&dbname=FuelCharter&dbdesc=Vehicle and Fuel Cost Tracker&createapptoken=1

where target_domain is the domain against which you are invoking this call, for example, quickbase.com. Read about this notation.

top

Sample response

<?xml version="1.0" ?>
<qdbapi>
   <action>API_CreateDatabase</action>
   <errcode>0</errcode>
   <errtext>No error</errtext>
   <dbid>bddnn3uz9</dbid>
   <appdbid>bddnn3ub7</appdbid>
   <apptoken>cmzaaz3dgdmmwwksdb7zcd7a9wg</apptoken>
</qdbapi>

 

Go back    |     |  

© 1999-2018 QuickBase, Inc. All rights reserved. Legal Notices.