curl --request DELETE \
--url https://api.example.com/credential/revoke/{credentialId} \
--header 'Content-Type: application/json' \
--data '
{
"reason": "user_initiated"
}
'import requests
url = "https://api.example.com/credential/revoke/{credentialId}"
payload = { "reason": "user_initiated" }
headers = {"Content-Type": "application/json"}
response = requests.delete(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'DELETE',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({reason: 'user_initiated'})
};
fetch('https://api.example.com/credential/revoke/{credentialId}', 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://api.example.com/credential/revoke/{credentialId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_POSTFIELDS => json_encode([
'reason' => 'user_initiated'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/credential/revoke/{credentialId}"
payload := strings.NewReader("{\n \"reason\": \"user_initiated\"\n}")
req, _ := http.NewRequest("DELETE", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.example.com/credential/revoke/{credentialId}")
.header("Content-Type", "application/json")
.body("{\n \"reason\": \"user_initiated\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/credential/revoke/{credentialId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"reason\": \"user_initiated\"\n}"
response = http.request(request)
puts response.read_body{
"credentialId": "urn:via:credential:550e8400-e29b-41d4-a716-446655440000",
"status": "REVOKED",
"revokedAt": "2026-05-02T10:15:30.000Z"
}{
"statusCode": 400,
"message": "Credential is not in a revocable status",
"error": "Bad Request"
}{
"statusCode": 403,
"message": "Credential is not accessible by this API key",
"error": "Forbidden"
}{
"statusCode": 404,
"message": "Credential not found",
"error": "Not Found"
}{
"statusCode": 409,
"message": "Credential is already revoked",
"error": "Unknown Error"
}Revoke Credential
Permanently revoke an active credential. Flips status to REVOKED, records revokedAt and revocationReason,
appends a REVOKE proof to the credential, and emits a MANDATE_REVOKED activity event.
Optionally include a reason (max 200 chars) in the request body to record why the credential was revoked; it is stored as the credential revocationReason and included in the MANDATE_REVOKED event.
Subsequent /vp and /verify calls for this credential are denied with reason credential_revoked.
curl --request DELETE \
--url https://api.example.com/credential/revoke/{credentialId} \
--header 'Content-Type: application/json' \
--data '
{
"reason": "user_initiated"
}
'import requests
url = "https://api.example.com/credential/revoke/{credentialId}"
payload = { "reason": "user_initiated" }
headers = {"Content-Type": "application/json"}
response = requests.delete(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'DELETE',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({reason: 'user_initiated'})
};
fetch('https://api.example.com/credential/revoke/{credentialId}', 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://api.example.com/credential/revoke/{credentialId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_POSTFIELDS => json_encode([
'reason' => 'user_initiated'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.example.com/credential/revoke/{credentialId}"
payload := strings.NewReader("{\n \"reason\": \"user_initiated\"\n}")
req, _ := http.NewRequest("DELETE", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.example.com/credential/revoke/{credentialId}")
.header("Content-Type", "application/json")
.body("{\n \"reason\": \"user_initiated\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/credential/revoke/{credentialId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"reason\": \"user_initiated\"\n}"
response = http.request(request)
puts response.read_body{
"credentialId": "urn:via:credential:550e8400-e29b-41d4-a716-446655440000",
"status": "REVOKED",
"revokedAt": "2026-05-02T10:15:30.000Z"
}{
"statusCode": 400,
"message": "Credential is not in a revocable status",
"error": "Bad Request"
}{
"statusCode": 403,
"message": "Credential is not accessible by this API key",
"error": "Forbidden"
}{
"statusCode": 404,
"message": "Credential not found",
"error": "Not Found"
}{
"statusCode": 409,
"message": "Credential is already revoked",
"error": "Unknown Error"
}Headers
Pin request, response, and webhook shapes to a specific dated API version (YYYY-MM-DD). Omit to use the version pinned to your API key (set when the key is created; new keys default to the latest version). New integrations should target the latest version.
^\d{4}-\d{2}-\d{2}$"2026-07-06"
Path Parameters
URN of the credential to revoke
"urn:via:credential:550e8400-e29b-41d4-a716-446655440000"
Body
Free-text reason for revocation, recorded on the credential as revocationReason. Recommended values from VIA protocol §5.5.1: "user_initiated", "organization_policy", "system_expiry".
200"user_initiated"
Response
Credential revoked. The revocation is recorded as a REVOKE proof on the credential.
URN of the revoked credential
"urn:via:credential:550e8400-e29b-41d4-a716-446655440000"
Always REVOKED on a successful response
DRAFT, ACTIVE, REJECTED, CANCELED, REVOKED, EXPIRED "REVOKED"
When the credential was revoked (ISO 8601)
"2026-05-02T10:15:30.000Z"