Bulk upload Lookup Tables

Purpose: Create or Edit lookup tables by uploading excel file containing Table data

URL: https://www.commcarehq.org/a/[domain]/fixtures/fixapi/

Method: POST

Authorization: Basic Authorization

Input Parameters:

Name

Description

Example

Name

Description

Example

file-to-upload

Path to the excel file containing Table Data

/home/username/fixtures.xlsx

replace

True if the existing tables should be deleted, otherwise False

false

async

If true, the upload will be queued and processed in the background. A status URL will be provided to view progress

false

Sample cURL request:

curl -v https://www.commcarehq.org/a/myproject/fixtures/fixapi/ -u user@domain.com:password -F "file-to-upload=@fixtures.xlsx" -F "replace=true"

(You may also omit the ':' and password and curl will request it. This will have the benefit of not showing your password on your screen or storing it in your history.)

Response: JSON output with following Parameters.

Name

Description

Example

Name

Description

Example

code

200: Success

402: Warning

405: Fail

402

message

Warning or Failure message

"Error processing your file. Submit a valid (.xlsx) file"

status_url

URL for the progress of the lookup table upload

Only applicable when async=true



https://www.commcarehq.org/a/demo/fixtures/fixapi/status/dl-2998e6834a654ab5ba74f372246caa75/