curl --request GET \
--url https://app.base44.com/api/apps/{app_id}/imported/main-update \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.base44.com/api/apps/{app_id}/imported/main-update"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.base44.com/api/apps/{app_id}/imported/main-update', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.base44.com/api/apps/{app_id}/imported/main-update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.base44.com/api/apps/{app_id}/imported/main-update"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.base44.com/api/apps/{app_id}/imported/main-update")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.base44.com/api/apps/{app_id}/imported/main-update")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"phase": "idle",
"active_generation": {
"id": "5f1c0e2a9b7d4c3e8a6f1b2d3c4e5f60",
"commit": "9fceb02d0ae598e95dc970b74767f19372d61af8"
},
"failure": {
"id": "0d4c2b1a9e8f7a6b5c4d3e2f1a0b9c8d",
"commit": "1a2b3c4d5e6f708192a3b4c5d6e7f8091a2b3c4d",
"stage": "verification",
"diagnostics": "The web service didn't become healthy.",
"investigation_branch_id": "<string>"
},
"initial_setup_pending": false
}{
"error": {
"code": "not_found",
"message": "App not found",
"details": {}
}
}{
"error": {
"code": "not_found",
"message": "App not found",
"details": {}
}
}{
"error": {
"code": "not_found",
"message": "Not found",
"details": {}
}
}{
"error": {
"code": "not_found",
"message": "App not found",
"details": {}
}
}Get main sandbox update status
Returns the state of the imported app’s main sandbox: the preview that runs the branch the app was imported from, usually your repository’s default branch.
When that branch moves, Base44 builds a new candidate at that commit, checks that its services come up healthy, and then switches the preview to it. phase says where that is, and active_generation is the commit the preview serves now. The editor asks for updates while the app is open in it. From CI or a script, call Check for main sandbox updates after a merge, then poll this endpoint.
failure describes the last build or verification failure of your repository’s code. A failed phase can still come with a null failure when the cause was on Base44’s side or during the app’s first setup.
This endpoint is limited to 120 requests per minute per user, reported in the X-RateLimit-* headers.
api_key query parameter is refused.curl --request GET \
--url https://app.base44.com/api/apps/{app_id}/imported/main-update \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.base44.com/api/apps/{app_id}/imported/main-update"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.base44.com/api/apps/{app_id}/imported/main-update', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.base44.com/api/apps/{app_id}/imported/main-update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.base44.com/api/apps/{app_id}/imported/main-update"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.base44.com/api/apps/{app_id}/imported/main-update")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.base44.com/api/apps/{app_id}/imported/main-update")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"phase": "idle",
"active_generation": {
"id": "5f1c0e2a9b7d4c3e8a6f1b2d3c4e5f60",
"commit": "9fceb02d0ae598e95dc970b74767f19372d61af8"
},
"failure": {
"id": "0d4c2b1a9e8f7a6b5c4d3e2f1a0b9c8d",
"commit": "1a2b3c4d5e6f708192a3b4c5d6e7f8091a2b3c4d",
"stage": "verification",
"diagnostics": "The web service didn't become healthy.",
"investigation_branch_id": "<string>"
},
"initial_setup_pending": false
}{
"error": {
"code": "not_found",
"message": "App not found",
"details": {}
}
}{
"error": {
"code": "not_found",
"message": "App not found",
"details": {}
}
}{
"error": {
"code": "not_found",
"message": "Not found",
"details": {}
}
}{
"error": {
"code": "not_found",
"message": "App not found",
"details": {}
}
}Authorizations
Personal access token, sent as Authorization: Bearer <token>. Each operation lists the permission it needs: read_only or full_access. A full-access token can call every operation. A read-only token can call only the operations that list read_only; anything else returns 403 read_only_credential_route_not_allowed.
Path Parameters
ID of the imported app whose main sandbox to read or update.
Response
Successful Response
Where the update is: idle when nothing is running, preparing, building, verifying and publishing while a commit moves to the preview, retiring while an old build is removed, and failed when the last update failed.
idle, preparing, building, verifying, publishing, retiring, failed "idle"
The build the preview serves now, or null before the first one.
Show child attributes
Show child attributes
The last failure in your repository's code, or null when there's none to act on.
Show child attributes
Show child attributes
true while the app's first setup is still pending. Updates don't run until it finishes.
false
Was this page helpful?