QUICK LINKS

GETTING STARTED

COMPONENTS

TUTORIALS

Uploading data through API

First, obtain the API Token for the Project by navigating to Workspace > Projects > Documentation.

Please note that the project token (as well as the Client ID) is exclusively accessible to project administrators. You can refresh your API token by utilizing the 'Refresh token' option located adjacent to the Client ID.

Below this section, you'll find the project URL for data uploads, along with the provided Python script. This script can be directly utilized within your compiler.

Ensure to define the header XAI token, while the Client ID and project name are automatically specified.


headers = 
{    
"x-api-token": your project access secret token 
} 
base_format = 
{
"client_id": test_user_arya,
"project_name": Risk-monitoring_FW6FSKJQRE
}

Next, prepare Data in the format of a dictionary, where multiple data points can be uploaded as a list of dictionaries.

Define the unique identifier for the data.

For single data points, a dictionary with one unique identifier and 3-4 columns can be directly passed through the API. However, for multiple data points, you must create a list containing unique identifiers and corresponding columns.

Finally, you will need to issue a POST request:


resp = requests.post(url,headers= headers json=base_format)

For every post request, data successful responses and acknowledgements are provided, so you are updated on the status.