Use API_UploadFile to upload base64-encoded file attachments in Quick Base.
Specify values for file attachment fields using either the fid attribute or name attribute of the <field> element.
In the opening <field> tag, insert the filename attribute in addition to the fid or name attribute.
The filename attribute value should be set to the name of the file with no path specified. Insert the base64-encoded text from the encoded file between the opening and closing <field> tags.
The file attachment must be a base64-encoded file. See Managing Files for more information about uploading files.
Note that you must not use MIME encoding and must not include MIME headers. Many base64 encoders or base64 encoding methods are for MIME type encoding and will not work with Quick Base.
You must not insert any new line characters when you base64 encode the file. If your file attachments appear to upload but don’t display in Quick Base, double check for presence of these characters.
The id of the record that will contain the file attachment
A valid authentication ticket.
The authentication ticket is returned via the API_Authenticate call.
yes, one of:
The user token is an alternative means of authentication, used for API access. User tokens cannot be used to access the Quick Base UI.
yes, one of:
A valid application token
yes, if the application requires application tokens
The originating request, for example, API_UploadFile.
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.
Text that explains the error code.
"No error" indicates that no error was encountered.
Contains a list of <field> elements for the uploaded file(s). Each <field> element includes a <url> element that can be used to fetch a specific uploaded file.
See XML Request example with a truncated base64-encoded file attachment.
<?xml version="1.0" ?>
<field id="13"> <!--(Uploaded File Name)-->
Did this help you? Give us a rating:
© 1999-2020 QuickBase, Inc. All rights reserved. Legal Notices.