Update a file
PUT
/uploads/{uploadId}
Base URL
https://app.testsigma.com/api/v1
Upload a new version of an existing file in Testsigma Uploads, identified by its upload ID.
Authenticate with your API key as a
Bearer token in the
Authorization header. Generate a key →PATH PARAMETERS
uploadId | ID of the upload to update. Available from the API response when the file was created, or via the Copy Path option on the Uploads page. |
REQUEST BODY
projectId | ID of the project the file belongs to. |
name | Name for the upload. |
uploadType | Type of upload — e.g. Attachment. |
platformType | Platform the file targets — e.g. TestsigmaLab. |
isPublic | Whether the file is publicly accessible. |
applicationId | ID of the associated application. |
version | Version label for the file. |
fileContent | The new file content (multipart file part). |
RESPONSE ATTRIBUTES
id | Unique upload identifier. |
createdById | ID of the user who created the upload. |
updatedById | ID of the user who last updated the upload. |
createdDate | Epoch timestamp when the upload was created. |
updatedDate | Epoch timestamp when the upload was last updated. |
name | Name of the upload. |
latestVersionId | ID of the latest version of the file. |
latestVersion | Object describing the latest version (id, path, fileName, fileSize, status, preSignedURL, etc.). |
versions | Placeholder field, not currently used. |
supportedDeviceType | Placeholder field, not currently used. |
isFlutter | Whether the upload is a Flutter project. |
REQUEST
curl -X PUT \
'https://app.testsigma.com/api/v1/uploads/{uploadId}' \
-H 'Authorization: Bearer <API_KEY>' \
-F 'projectId=24' \
-F 'name=APIFileUpdated' \
-F 'uploadType=Attachment' \
-F 'platformType=TestsigmaLab' \
-F 'isPublic=true' \
-F 'applicationId=43' \
-F 'version=v101' \
-F 'fileContent=@app.apk'const form = new FormData();
form.append('projectId', '24');
form.append('name', 'APIFileUpdated');
form.append('uploadType', 'Attachment');
form.append('platformType', 'TestsigmaLab');
form.append('isPublic', 'true');
form.append('applicationId', '43');
form.append('version', 'v101');
form.append('fileContent', fileInput.files[0]);
const response = await fetch('https://app.testsigma.com/api/v1/uploads/{uploadId}', {
method: 'PUT',
headers: { 'Authorization': 'Bearer <API_KEY>' },
body: form
});
const data = await response.json();import requests
response = requests.put(
'https://app.testsigma.com/api/v1/uploads/{uploadId}',
headers={ 'Authorization': 'Bearer <API_KEY>' },
data={
'projectId': '24',
'name': 'APIFileUpdated',
'uploadType': 'Attachment',
'platformType': 'TestsigmaLab',
'isPublic': 'true',
'applicationId': '43',
'version': 'v101'
},
files={
'fileContent': open('app.apk', 'rb')
}
)
data = response.json()RESPONSE200OK
{
"id": 62,
"createdById": 10,
"updatedById": 10,
"createdDate": 1681974023000,
"updatedDate": 1681974187126,
"name": "APIFileUpdated",
"latestVersionId": 68,
"latestVersion": {
"id": 68,
"createdById": 10,
"updatedById": 10,
"createdDate": 1681974023000,
"updatedDate": 1681974023000,
"name": "v101",
"path": "46091/uploads/24/68/example.png",
"fileName": "example.png",
"uploadType": "Attachment",
"testsigmaSauceLabsAppId": null,
"testsigmaBrowserstackAppId": null,
"fileSize": 181368,
"preSignedURL": "https://s3.amazonaws.com/.../Testfile.pdf?X-Amz-Signature=...",
"signed": false,
"status": "SUCCESS",
"uploadName": "APIFileUpdated",
"signStatus": "NONE",
"uploadId": 62
},
"versions": null,
"supportedDeviceType": null,
"isFlutter": false
}