Skip to main content
POST
/
api
/
v1
/
apps
/
{app_id}
/
is-allowed
Check if app deployment is allowed on-chain
curl --request POST \
  --url https://cloud-api.phala.com/api/v1/apps/{app_id}/is-allowed \
  --header 'Content-Type: application/json' \
  --data '
{
  "compose_hash": "<string>",
  "node_id": 123,
  "device_id": "<string>",
  "chain_id": 123
}
'
{
  "app_contract_address": "<string>",
  "compose_hash": "<string>",
  "device_id": "<string>",
  "compose_hash_allowed": true,
  "allow_any_device": true,
  "is_allowed": true,
  "device_id_allowed": true,
  "error": "<string>"
}

Path Parameters

app_id
string
required

Body

application/json
compose_hash
string
required

Compose hash to check (hex)

node_id
integer | null

Node ID (resolves device_id from DB)

device_id
string | null

Device ID (hex, direct)

chain_id
integer | null

Chain ID for RPC URL resolution. If omitted, resolved from DB via CVM/KMS records.

Response

Successful Response

app_contract_address
string
required
compose_hash
string
required
device_id
string
required
compose_hash_allowed
boolean
required
allow_any_device
boolean
required
is_allowed
boolean
required
device_id_allowed
boolean | null
error
string | null