curl --request GET \
--url https://api.goyappr.com/agents/{id}/workflow \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.goyappr.com/agents/{id}/workflow"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.goyappr.com/agents/{id}/workflow', 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.goyappr.com/agents/{id}/workflow",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <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"
"net/http"
"io"
)
func main() {
url := "https://api.goyappr.com/agents/{id}/workflow"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.goyappr.com/agents/{id}/workflow")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.goyappr.com/agents/{id}/workflow")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"execution_version": "legacy",
"draft": {
"version": 2,
"document": {
"id": "<string>",
"name": "<string>",
"conversation": {
"entry_node_id": "<string>",
"nodes": [
{
"id": "<string>",
"label": "<string>",
"type": "conversation",
"instructions": "<string>",
"available_binding_ids": [
"<string>"
],
"binding_overrides": {}
}
],
"edges": [
{
"id": "<string>",
"source": "<string>",
"target": "<string>",
"kind": "conversation",
"condition": "<string>"
}
],
"global_edges": [
{
"id": "<string>",
"target": "<string>",
"condition": "<string>"
}
]
},
"schema_version": "1",
"strict_mode": false,
"global_instructions": "",
"channels": [
"phone"
],
"request_schema": {},
"stored_schema": {},
"bindings": [
{
"id": "<string>",
"tool_revision_id": "<string>",
"tool_revision_policy": "follow_current",
"inputs": {}
}
],
"before": {
"steps": [
{
"id": "<string>",
"label": "<string>",
"binding_id": "<string>",
"depends_on": [
"<string>"
],
"requires": [
"transcript"
],
"on_failure": "stop",
"when": {
"kind": "compare",
"source": {
"kind": "literal",
"value": true
},
"op": "exists",
"value": {
"kind": "literal",
"value": true
}
},
"on_succeeded": "<string>",
"on_failed": "<string>"
}
],
"on_failure": "stop_admission"
},
"after": [
{
"id": "<string>",
"event": "call.answered",
"steps": [
{
"id": "<string>",
"label": "<string>",
"binding_id": "<string>",
"depends_on": [
"<string>"
],
"requires": [
"transcript"
],
"on_failure": "stop",
"when": {
"kind": "compare",
"source": {
"kind": "literal",
"value": true
},
"op": "exists",
"value": {
"kind": "literal",
"value": true
}
},
"on_succeeded": "<string>",
"on_failed": "<string>"
}
],
"when": {
"kind": "compare",
"source": {
"kind": "literal",
"value": true
},
"op": "exists",
"value": {
"kind": "literal",
"value": true
}
}
}
],
"sequences": [
{
"id": "<string>",
"name": "<string>",
"steps": [
{
"id": "<string>",
"label": "<string>",
"binding_id": "<string>",
"depends_on": [
"<string>"
],
"requires": [
"transcript"
],
"on_failure": "stop",
"when": {
"kind": "compare",
"source": {
"kind": "literal",
"value": true
},
"op": "exists",
"value": {
"kind": "literal",
"value": true
}
},
"on_succeeded": "<string>",
"on_failed": "<string>"
}
],
"description": "",
"input_schema": {},
"output_schema": {},
"output_mapping": {}
}
],
"editor": {
"positions": {}
},
"integrations": [
{
"id": "<string>",
"connection_id": "<string>",
"app": "<string>",
"actions": [
{
"action": "<string>",
"binding_id": "<string>"
}
]
}
]
},
"updated_at": "2023-11-07T05:31:56Z"
},
"published": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"version": 2,
"content_hash": "<string>",
"published_at": "2023-11-07T05:31:56Z",
"environment": "local"
}
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}Read workflow
Read the canonical saved draft and publication pointer.
curl --request GET \
--url https://api.goyappr.com/agents/{id}/workflow \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.goyappr.com/agents/{id}/workflow"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.goyappr.com/agents/{id}/workflow', 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.goyappr.com/agents/{id}/workflow",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <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"
"net/http"
"io"
)
func main() {
url := "https://api.goyappr.com/agents/{id}/workflow"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.goyappr.com/agents/{id}/workflow")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.goyappr.com/agents/{id}/workflow")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"agent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"execution_version": "legacy",
"draft": {
"version": 2,
"document": {
"id": "<string>",
"name": "<string>",
"conversation": {
"entry_node_id": "<string>",
"nodes": [
{
"id": "<string>",
"label": "<string>",
"type": "conversation",
"instructions": "<string>",
"available_binding_ids": [
"<string>"
],
"binding_overrides": {}
}
],
"edges": [
{
"id": "<string>",
"source": "<string>",
"target": "<string>",
"kind": "conversation",
"condition": "<string>"
}
],
"global_edges": [
{
"id": "<string>",
"target": "<string>",
"condition": "<string>"
}
]
},
"schema_version": "1",
"strict_mode": false,
"global_instructions": "",
"channels": [
"phone"
],
"request_schema": {},
"stored_schema": {},
"bindings": [
{
"id": "<string>",
"tool_revision_id": "<string>",
"tool_revision_policy": "follow_current",
"inputs": {}
}
],
"before": {
"steps": [
{
"id": "<string>",
"label": "<string>",
"binding_id": "<string>",
"depends_on": [
"<string>"
],
"requires": [
"transcript"
],
"on_failure": "stop",
"when": {
"kind": "compare",
"source": {
"kind": "literal",
"value": true
},
"op": "exists",
"value": {
"kind": "literal",
"value": true
}
},
"on_succeeded": "<string>",
"on_failed": "<string>"
}
],
"on_failure": "stop_admission"
},
"after": [
{
"id": "<string>",
"event": "call.answered",
"steps": [
{
"id": "<string>",
"label": "<string>",
"binding_id": "<string>",
"depends_on": [
"<string>"
],
"requires": [
"transcript"
],
"on_failure": "stop",
"when": {
"kind": "compare",
"source": {
"kind": "literal",
"value": true
},
"op": "exists",
"value": {
"kind": "literal",
"value": true
}
},
"on_succeeded": "<string>",
"on_failed": "<string>"
}
],
"when": {
"kind": "compare",
"source": {
"kind": "literal",
"value": true
},
"op": "exists",
"value": {
"kind": "literal",
"value": true
}
}
}
],
"sequences": [
{
"id": "<string>",
"name": "<string>",
"steps": [
{
"id": "<string>",
"label": "<string>",
"binding_id": "<string>",
"depends_on": [
"<string>"
],
"requires": [
"transcript"
],
"on_failure": "stop",
"when": {
"kind": "compare",
"source": {
"kind": "literal",
"value": true
},
"op": "exists",
"value": {
"kind": "literal",
"value": true
}
},
"on_succeeded": "<string>",
"on_failed": "<string>"
}
],
"description": "",
"input_schema": {},
"output_schema": {},
"output_mapping": {}
}
],
"editor": {
"positions": {}
},
"integrations": [
{
"id": "<string>",
"connection_id": "<string>",
"app": "<string>",
"actions": [
{
"action": "<string>",
"binding_id": "<string>"
}
]
}
]
},
"updated_at": "2023-11-07T05:31:56Z"
},
"published": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"version": 2,
"content_hash": "<string>",
"published_at": "2023-11-07T05:31:56Z",
"environment": "local"
}
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}{
"error": "<string>",
"code": "<string>",
"issues": [
{
"code": "<string>",
"message": "<string>",
"path": "<string>"
}
]
}agents:read. Use the explicit active workspace in x-company-id.
curl 'https://api.goyappr.com/agents/AGENT_ID/workflow' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'x-company-id: COMPANY_ID'
agent_id, read-only execution_version, draft and
published. draft has its own version, complete document and updated_at.
published is null until explicitly published; otherwise it contains id,
version, content_hash and published_at.
Disabled, unarchived agents remain editable without reactivation. Archived
agents are hidden from this authoring endpoint. Published summaries are not
execution receipts and do not prove media or account readiness.
Use a lossless JSON reader for arbitrary schema defaults, constraints and fixed
values. Do not round large integers or high-precision decimal tokens. The
canonical document schema is generated from the same
contract used by the compiler.Authorizations
Your Yappr API key (e.g. ypr_live_...). Generate one in the dashboard under Settings → API Keys. No key is 401 MISSING_KEY; a key that is not one of ours, or is revoked, is 401 INVALID_KEY; an expired one is 401 EXPIRED_KEY. A valid key without the scope an operation needs is 403 INSUFFICIENT_SCOPE on every operation, and the message names the scope. Every response, a 401 included, carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset: the budget is 60 requests a minute per API key. Every 429, whatever its code, carries Retry-After (whole seconds, never zero): the per-key budget's RATE_LIMIT asks for what is left of the minute, a route's daily cap (RATE_LIMITED) for the time until that cap resets. All four headers are listed in Access-Control-Expose-Headers, so a browser can read them. A path the API does not serve (an unknown sub-path, an id left empty) is 404 ROUTE_NOT_FOUND, and a method a served path does not take is 405 METHOD_NOT_ALLOWED with an Allow header; both are answered before any scope check, and nothing is read or changed. A trailing slash is ignored where it cannot be an id left empty (POST /calls/ is POST /calls) and refused where it can (GET /calls/). A doubled slash inside a path is merged into one before the request reaches the API (GET //calls is GET /calls).