Get CVM attestation
curl --request GET \
--url https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestationimport requests
url = "https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation', 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://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation")
.asString();require 'uri'
require 'net/http'
url = URI("https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"is_online": true,
"is_public": true,
"error": "<string>",
"name": "<string>",
"app_certificates": [
{
"subject": {
"common_name": "<string>",
"organization": "<string>",
"country": "<string>",
"state": "<string>",
"locality": "<string>"
},
"issuer": {
"common_name": "<string>",
"organization": "<string>",
"country": "<string>"
},
"serial_number": "<string>",
"not_before": "2023-11-07T05:31:56Z",
"not_after": "2023-11-07T05:31:56Z",
"version": "<string>",
"fingerprint": "<string>",
"signature_algorithm": "<string>",
"sans": [
"<string>"
],
"is_ca": false,
"position_in_chain": 123,
"quote": "<string>",
"app_id": "<string>",
"cert_usage": "<string>"
}
],
"tcb_info": {
"mrtd": "<string>",
"rtmr0": "<string>",
"rtmr1": "<string>",
"rtmr2": "<string>",
"rtmr3": "<string>",
"event_log": [
{
"imr": 123,
"event_type": 123,
"digest": "<string>",
"event": "<string>",
"event_payload": "<string>"
}
],
"app_compose": "<string>",
"rootfs_hash": "<string>"
},
"compose_file": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}CVMs
Get CVM attestation
Returns TEE attestation data including TCB info and app certificates.
GET
/
api
/
v1
/
cvms
/
{cvm_id}
/
attestation
Get CVM attestation
curl --request GET \
--url https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestationimport requests
url = "https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation', 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://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation")
.asString();require 'uri'
require 'net/http'
url = URI("https://cloud-api.phala.com/api/v1/cvms/{cvm_id}/attestation")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"is_online": true,
"is_public": true,
"error": "<string>",
"name": "<string>",
"app_certificates": [
{
"subject": {
"common_name": "<string>",
"organization": "<string>",
"country": "<string>",
"state": "<string>",
"locality": "<string>"
},
"issuer": {
"common_name": "<string>",
"organization": "<string>",
"country": "<string>"
},
"serial_number": "<string>",
"not_before": "2023-11-07T05:31:56Z",
"not_after": "2023-11-07T05:31:56Z",
"version": "<string>",
"fingerprint": "<string>",
"signature_algorithm": "<string>",
"sans": [
"<string>"
],
"is_ca": false,
"position_in_chain": 123,
"quote": "<string>",
"app_id": "<string>",
"cert_usage": "<string>"
}
],
"tcb_info": {
"mrtd": "<string>",
"rtmr0": "<string>",
"rtmr1": "<string>",
"rtmr2": "<string>",
"rtmr3": "<string>",
"event_log": [
{
"imr": 123,
"event_type": 123,
"digest": "<string>",
"event": "<string>",
"event_payload": "<string>"
}
],
"app_compose": "<string>",
"rootfs_hash": "<string>"
},
"compose_file": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Path Parameters
Response
Attestation report (may have error if CVM offline)
Was this page helpful?
⌘I

