This request is intended to get the download token of a build and its download URL.
Step 1 - Generate download token #
- Method: GET
- URL:
https://api.applivery.io/v1/organizations/:orgId/apps/:appId/builds/:buildId/downloadToken
- Authentication, organization ID, application ID, build ID, type: required
- Headers:
Content-Type: application/json
Authorization: Bearer <token>
Params #
Param | Type | Description |
---|---|---|
type
|
String |
Type of build: auto ,
file , aab
|
Example request #
curl 'https://api.applivery.io/v1/organizations/_ORGANIZATION_SLUG_/apps/_APPLICATION_ID_/builds/_BUILD_ID_/downloadToken?type=file'
-H 'accept: application/json'
-H 'authorization: Bearer _BEARERTOKEN_'
Responses #
200 - Success
400 - Bad request
401 - Unauthorized
404 - Not found
Content type:
application/json
{
"status": true,
"data": {
"token": "string",
"expiresAt": "string"
}
}
Content type:
application/json
{
"status": false,
"error": {
"code": 5014,
"message": "Build Not Processed"
}
}
Content type:
application/json
{
"status": false,
"error": {
"code": 4002,
"message": "No auth token"
}
}
Content type:
application/json
{
"status": false,
"error": {
"code": 3001,
"message": "Entity not found"
}
}
Step 2 - Get download URL #
- Method: GET
- URL:
https://download-api.applivery.io/v1/download/:downloadTokenId
- Download token ID: required
Example request #
curl 'https://download-api.applivery.io/v1/download/_DOWNLOAD_TOKEN_'
You will be redirected to the URL returned in the location parameter of the response header.
- In Android, the redirection URL will be the .apk file if the build is a .aab and the download token was generated with the type=aab. In this case, the redirect will be the .aab file.
- In Apple, the redirection URL will be the manifest.plist if the download token was generated with the type=file. In this case, the redirect will be the .ipa or .pkg file.
Responses #
301 - Redirect
401 - Unauthorized
404 - Not found
Content type:
application/json
{
"status": true
}
Content type:
application/json
{
"status": false,
"error": {
"code": 3002,
"message": "Token Expired"
}
}
Content type:
application/json
{
"status": false,
"error": {
"code": 3001,
"message": "Entity not found"
}
}