Instalar app
curl --request POST \
--url https://api.upag.io/v1/apps/{appId}/install \
--header 'Authorization: Bearer <token>'const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.upag.io/v1/apps/{appId}/install', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://api.upag.io/v1/apps/{appId}/install';
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));Apps
Instalar app
Instala o script de checkout (ScriptTag) na loja Shopify conectada
POST
https://api.upag.io
/
v1
/
apps
/
{appId}
/
install
Instalar app
curl --request POST \
--url https://api.upag.io/v1/apps/{appId}/install \
--header 'Authorization: Bearer <token>'const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.upag.io/v1/apps/{appId}/install', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://api.upag.io/v1/apps/{appId}/install';
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));Executa o instalador do provedor. Hoje só o
shopify suporta instalação: remove ScriptTags antigos do checkout e cria um novo na loja, gravando o scriptTagId na config.
Permissão: app.write (chave secreta).
Endpoint
curl -X POST https://api.upag.dev/v1/apps/c8d9e0f1-a2b3-4c4d-9e5f-6a7b8c9d0e12/install \
-H "Authorization: Bearer sk_test_your_api_key"
import { Upag } from 'upag';
const upag = new Upag('sk_test_your_api_key');
const app = await upag.apps.install('c8d9e0f1-a2b3-4c4d-9e5f-6a7b8c9d0e12');
Em produção use
https://api.upag.io/v1 com sk_live_....Parâmetros
string (uuid)
required
ID do app Shopify.
Resposta
200 OK — o app, agora com scriptTagId na config.
Response
{
"id": "c8d9e0f1-a2b3-4c4d-9e5f-6a7b8c9d0e12",
"type": "integration",
"provider": "shopify",
"scope": "private",
"name": "Loja Shopify",
"config": {
"shop": "minha-loja.myshopify.com",
"clientId": "a1b2c3d4e5f6",
"clientSecret": "********9f0a",
"connectedAt": "2026-03-18T11:35:00.000Z",
"scriptTagId": "175450112345"
},
"active": true,
"appliesTo": "all",
"appliesToProducts": null,
"createdAt": "2026-03-18T11:35:00.000Z",
"updatedAt": "2026-03-18T11:40:00.000Z"
}
404(APP_NOT_FOUND).400—APP_INSTALL_NOT_SUPPORTED(provedor sem instalação),SHOPIFY_CREDENTIALS_INCOMPLETEouSHOPIFY_SCRIPT_SRC_NOT_CONFIGURED.502(SHOPIFY_SCRIPT_TAG_FAILED) — a Shopify falhou ao criar o script; tente novamente.