DecideApprovalAPI mirrors erdo_decide_approval.
curl --request POST \
--url https://api.erdo.ai/v1/approvals/{id}/decide \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"decided_by_external_ref": "<string>",
"decision": "<string>",
"parameter_constraints": {},
"reason": "<string>",
"scope": "<string>"
}
'import requests
url = "https://api.erdo.ai/v1/approvals/{id}/decide"
payload = {
"decided_by_external_ref": "<string>",
"decision": "<string>",
"parameter_constraints": {},
"reason": "<string>",
"scope": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
decided_by_external_ref: '<string>',
decision: '<string>',
parameter_constraints: {},
reason: '<string>',
scope: '<string>'
})
};
fetch('https://api.erdo.ai/v1/approvals/{id}/decide', 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.erdo.ai/v1/approvals/{id}/decide",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'decided_by_external_ref' => '<string>',
'decision' => '<string>',
'parameter_constraints' => [
],
'reason' => '<string>',
'scope' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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.erdo.ai/v1/approvals/{id}/decide"
payload := strings.NewReader("{\n \"decided_by_external_ref\": \"<string>\",\n \"decision\": \"<string>\",\n \"parameter_constraints\": {},\n \"reason\": \"<string>\",\n \"scope\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <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.post("https://api.erdo.ai/v1/approvals/{id}/decide")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"decided_by_external_ref\": \"<string>\",\n \"decision\": \"<string>\",\n \"parameter_constraints\": {},\n \"reason\": \"<string>\",\n \"scope\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.erdo.ai/v1/approvals/{id}/decide")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"decided_by_external_ref\": \"<string>\",\n \"decision\": \"<string>\",\n \"parameter_constraints\": {},\n \"reason\": \"<string>\",\n \"scope\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"message": "<string>",
"success": true
}{
"code": "not_found",
"details": {},
"message": "<string>"
}API Reference
DecideApprovalAPI mirrors erdo_decide_approval.
POST
/
v1
/
approvals
/
{id}
/
decide
DecideApprovalAPI mirrors erdo_decide_approval.
curl --request POST \
--url https://api.erdo.ai/v1/approvals/{id}/decide \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"decided_by_external_ref": "<string>",
"decision": "<string>",
"parameter_constraints": {},
"reason": "<string>",
"scope": "<string>"
}
'import requests
url = "https://api.erdo.ai/v1/approvals/{id}/decide"
payload = {
"decided_by_external_ref": "<string>",
"decision": "<string>",
"parameter_constraints": {},
"reason": "<string>",
"scope": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
decided_by_external_ref: '<string>',
decision: '<string>',
parameter_constraints: {},
reason: '<string>',
scope: '<string>'
})
};
fetch('https://api.erdo.ai/v1/approvals/{id}/decide', 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.erdo.ai/v1/approvals/{id}/decide",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'decided_by_external_ref' => '<string>',
'decision' => '<string>',
'parameter_constraints' => [
],
'reason' => '<string>',
'scope' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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.erdo.ai/v1/approvals/{id}/decide"
payload := strings.NewReader("{\n \"decided_by_external_ref\": \"<string>\",\n \"decision\": \"<string>\",\n \"parameter_constraints\": {},\n \"reason\": \"<string>\",\n \"scope\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <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.post("https://api.erdo.ai/v1/approvals/{id}/decide")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"decided_by_external_ref\": \"<string>\",\n \"decision\": \"<string>\",\n \"parameter_constraints\": {},\n \"reason\": \"<string>\",\n \"scope\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.erdo.ai/v1/approvals/{id}/decide")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"decided_by_external_ref\": \"<string>\",\n \"decision\": \"<string>\",\n \"parameter_constraints\": {},\n \"reason\": \"<string>\",\n \"scope\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"message": "<string>",
"success": true
}{
"code": "not_found",
"details": {},
"message": "<string>"
}Authorizations
An Erdo API key (erdo_api_...) or scoped token (erdo_token_...).
Path Parameters
Body
application/json
who decided, recorded beside the Erdo account the API key belongs to.
REST ONLY, and deliberately absent from DecideApprovalInput above: the MCP tool is answered by a model, which has no user of its own to name and would fill the field with something invented. An application does have one — a whole desk shares one organization key, so without this every approval any of them makes is attributed to the key's owner.
ATTRIBUTION, NEVER AUTHENTICATION. Erdo stores it verbatim and never verifies, parses or resolves it; anything holding the key can send any value. It may name a person on a card and must never gate anything.
DecideApprovalInput.Reason for what a rejection's reason does.

