Help centerAPI referenceInstallable app
Installable app
A PWA with the customer's brand on each domain.
Get the installable app
GET
/domains/{id}/pwadomains:readParameters
idpath · stringrequiredResource id (prj_…, dom_…)
Request
cURL
curl "https://api.tenanci.com/v2/domains/dom_4h7n1q/pwa" \
-H "Authorization: Bearer tnc_live_xxxxxxxx_xxxxxxxxxxxx"Response 200
{
"enabled": true,
"settings": {
"name": "Barbearia do Zé",
"shortName": "Zé",
"description": "Agende seu corte",
"themeColor": "#1f2937",
"backgroundColor": "#ffffff",
"display": "standalone",
"startUrl": "/",
"lang": "pt-BR",
"icons": {
"icon192": "https://assets.tenanci.com/org_5t1v/i192.png",
"icon512": "https://assets.tenanci.com/org_5t1v/i512.png",
"maskable": "https://assets.tenanci.com/org_5t1v/mask.png",
"apple": "https://assets.tenanci.com/org_5t1v/apple.png"
},
"prompt": {
"enabled": true,
"text": "Instale o app da Barbearia do Zé",
"delaySeconds": 20
},
"offline": true,
"serviceWorker": true,
"screenshots": [
{
"url": "https://assets.tenanci.com/org_5t1v/tela-agenda.png",
"width": 1080,
"height": 1920,
"formFactor": "narrow",
"label": "Agenda do dia"
},
{
"url": "https://assets.tenanci.com/org_5t1v/tela-painel.png",
"width": 1920,
"height": 1080,
"formFactor": "wide",
"label": null
}
]
}
}Configure the installable app
PUT
/domains/{id}/pwadomains:writeIcons must be https URLs (upload them with POST /assets). In the dashboard, icons and iOS splash screens are generated from the logo. screenshots (optional, up to 8) goes into the manifest and gives Android and desktop Chrome/Edge a richer install dialog with the app's screens: narrow for phones (portrait) and wide for desktop; 320 to 3840 px per side, the longer side at most 2.3 times the shorter one.
Parameters
idpath · stringrequiredResource id (prj_…, dom_…)
Body
enabledbooleansettingsobjectnamestringrequiredmin 1, max 60shortNamestringrequiredmin 1, max 30descriptionstring | nullrequiredthemeColorstringrequiredbackgroundColorstringrequireddisplay"standalone" | "fullscreen" | "minimal-ui"requiredstartUrlstringrequiredlangstring | nullrequirediconsobjectrequiredicon192stringrequiredmax 2048icon512stringrequiredmax 2048maskablestringrequiredmax 2048applestringrequiredmax 2048
promptobjectrequiredenabledbooleanrequiredtextstring | nullrequireddelaySecondsintegerrequired≥ 0, ≤ 600
offlinebooleanrequiredserviceWorkerbooleanrequiredsplashobject[]≤ 24 itenswidthintegerrequired≥ 320, ≤ 4096heightintegerrequired≥ 320, ≤ 4096ratiointegerrequired≥ 1, ≤ 3urlstringrequiredmax 2048
screenshotsobject[]≤ 8 itensurlstringrequiredmax 2048widthintegerrequired≥ 320, ≤ 3840heightintegerrequired≥ 320, ≤ 3840formFactor"narrow" | "wide"requiredlabelstring | nullrequired
Request
cURL
curl -X PUT "https://api.tenanci.com/v2/domains/dom_4h7n1q/pwa" \
-H "Authorization: Bearer tnc_live_xxxxxxxx_xxxxxxxxxxxx" \
-H "Content-Type: application/json" \
-d '{"enabled":true,"settings":{"name":"Barbearia do Zé","shortName":"Zé","description":"Agende seu corte","themeColor":"#1f2937","backgroundColor":"#ffffff","display":"standalone","startUrl":"/","lang":"pt-BR","icons":{"icon192":"https://assets.tenanci.com/org_5t1v/i192.png","icon512":"https://assets.tenanci.com/org_5t1v/i512.png","maskable":"https://assets.tenanci.com/org_5t1v/mask.png","apple":"https://assets.tenanci.com/org_5t1v/apple.png"},"prompt":{"enabled":true,"text":"Instale o app da Barbearia do Zé","delaySeconds":20},"offline":true,"serviceWorker":true,"screenshots":[{"url":"https://assets.tenanci.com/org_5t1v/tela-agenda.png","width":1080,"height":1920,"formFactor":"narrow","label":"Agenda do dia"},{"url":"https://assets.tenanci.com/org_5t1v/tela-painel.png","width":1920,"height":1080,"formFactor":"wide","label":null}]}}'Response 200
{
"enabled": true,
"settings": {
"name": "Barbearia do Zé",
"shortName": "Zé",
"description": "Agende seu corte",
"themeColor": "#1f2937",
"backgroundColor": "#ffffff",
"display": "standalone",
"startUrl": "/",
"lang": "pt-BR",
"icons": {
"icon192": "https://assets.tenanci.com/org_5t1v/i192.png",
"icon512": "https://assets.tenanci.com/org_5t1v/i512.png",
"maskable": "https://assets.tenanci.com/org_5t1v/mask.png",
"apple": "https://assets.tenanci.com/org_5t1v/apple.png"
},
"prompt": {
"enabled": true,
"text": "Instale o app da Barbearia do Zé",
"delaySeconds": 20
},
"offline": true,
"serviceWorker": true,
"screenshots": [
{
"url": "https://assets.tenanci.com/org_5t1v/tela-agenda.png",
"width": 1080,
"height": 1920,
"formFactor": "narrow",
"label": "Agenda do dia"
},
{
"url": "https://assets.tenanci.com/org_5t1v/tela-painel.png",
"width": 1920,
"height": 1080,
"formFactor": "wide",
"label": null
}
]
}
}
