Update secret
curl --request PUT \
--url https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId} \
--header 'Content-Type: application/json' \
--header 'X-AUTH-TOKEN: <x-auth-token>' \
--data '
{
"kind": "prophecy",
"subKind": "text",
"properties": {
"name": "service_account_1",
"value": "<new-value>"
}
}
'import requests
url = "https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}"
payload = {
"kind": "prophecy",
"subKind": "text",
"properties": {
"name": "service_account_1",
"value": "<new-value>"
}
}
headers = {
"X-AUTH-TOKEN": "<x-auth-token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-AUTH-TOKEN': '<x-auth-token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
kind: 'prophecy',
subKind: 'text',
properties: {name: 'service_account_1', value: '<new-value>'}
})
};
fetch('https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}', 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://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'kind' => 'prophecy',
'subKind' => 'text',
'properties' => [
'name' => 'service_account_1',
'value' => '<new-value>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-AUTH-TOKEN: <x-auth-token>"
],
]);
$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://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}"
payload := strings.NewReader("{\n \"kind\": \"prophecy\",\n \"subKind\": \"text\",\n \"properties\": {\n \"name\": \"service_account_1\",\n \"value\": \"<new-value>\"\n }\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-AUTH-TOKEN", "<x-auth-token>")
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.put("https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}")
.header("X-AUTH-TOKEN", "<x-auth-token>")
.header("Content-Type", "application/json")
.body("{\n \"kind\": \"prophecy\",\n \"subKind\": \"text\",\n \"properties\": {\n \"name\": \"service_account_1\",\n \"value\": \"<new-value>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-AUTH-TOKEN"] = '<x-auth-token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"kind\": \"prophecy\",\n \"subKind\": \"text\",\n \"properties\": {\n \"name\": \"service_account_1\",\n \"value\": \"<new-value>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "4656"
}
}{
"success": false,
"message": "Update Secret failed due to : Secret Store not found for Secret ID: propcy"
}Secrets
Update secret
Update the properties of a specific secret
PUT
/
api
/
orchestration
/
fabric
/
{fabricId}
/
secret
/
id
/
{secretId}
Update secret
curl --request PUT \
--url https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId} \
--header 'Content-Type: application/json' \
--header 'X-AUTH-TOKEN: <x-auth-token>' \
--data '
{
"kind": "prophecy",
"subKind": "text",
"properties": {
"name": "service_account_1",
"value": "<new-value>"
}
}
'import requests
url = "https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}"
payload = {
"kind": "prophecy",
"subKind": "text",
"properties": {
"name": "service_account_1",
"value": "<new-value>"
}
}
headers = {
"X-AUTH-TOKEN": "<x-auth-token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'X-AUTH-TOKEN': '<x-auth-token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
kind: 'prophecy',
subKind: 'text',
properties: {name: 'service_account_1', value: '<new-value>'}
})
};
fetch('https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}', 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://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'kind' => 'prophecy',
'subKind' => 'text',
'properties' => [
'name' => 'service_account_1',
'value' => '<new-value>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-AUTH-TOKEN: <x-auth-token>"
],
]);
$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://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}"
payload := strings.NewReader("{\n \"kind\": \"prophecy\",\n \"subKind\": \"text\",\n \"properties\": {\n \"name\": \"service_account_1\",\n \"value\": \"<new-value>\"\n }\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("X-AUTH-TOKEN", "<x-auth-token>")
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.put("https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}")
.header("X-AUTH-TOKEN", "<x-auth-token>")
.header("Content-Type", "application/json")
.body("{\n \"kind\": \"prophecy\",\n \"subKind\": \"text\",\n \"properties\": {\n \"name\": \"service_account_1\",\n \"value\": \"<new-value>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.prophecy.io/api/orchestration/fabric/{fabricId}/secret/id/{secretId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-AUTH-TOKEN"] = '<x-auth-token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"kind\": \"prophecy\",\n \"subKind\": \"text\",\n \"properties\": {\n \"name\": \"service_account_1\",\n \"value\": \"<new-value>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "4656"
}
}{
"success": false,
"message": "Update Secret failed due to : Secret Store not found for Secret ID: propcy"
}Open the secret in the Prophecy UI to see which properties can be updated.
Headers
Prophecy authentication token. Required for all API requests.
Path Parameters
The unique ID of the parent fabric
The unique ID of the secret
Body
application/json
Secret object with updated fields
Secret management provider
Available options:
prophecy Secret sub-type
Available options:
text, binary, username_password, m2m_oauth Secret properties that vary by subKind.
Find specific properties in the Secrets > Properties section of the API documentation.
Was this page helpful?
⌘I

