Skip to content

Fetch agent association

GET
/api/v1/agent_association/{agent_association_id}
curl --request GET \
--url https://app.prefactorai.com/api/v1/agent_association/013xrzp12g3nqk8ns6jadrqmpgrjkeny \
--header 'Authorization: Bearer <token>'
agent_association_id
required
AgentAssociation_Id

A valid agent association ID

string
Example
013xrzp12g3nqk8ns6jadrqmpgrjkeny
idempotency_key
One of:

Optional idempotency key for ensuring request idempotency

string

Success

Media typeapplication/json
object
details
required
AgentAssociation_Details
object
account_id
required
Account_Id

A valid account ID

string
association_type
required

Kind of association. For judge, from_agent is the judge and to_agent is the agent it scores

string
Allowed values: judge
from_agent_id
required
Agent_Id

A valid agent ID

string
id
required
AgentAssociation_Id

A valid agent association ID

string
inserted_at
required

When the association was created

string format: date-time
to_agent_id
required
Agent_Id

A valid agent ID

string
trigger
required

When the association runs: on_demand or on_completion. There is no default

string
Allowed values: on_demand on_completion
type
required

Type of resource (always ‘agent_association’)

string
Allowed values: agent_association
updated_at
required

When the association was last updated

string format: date-time
status
required

Response status when the query succeeds

string
Allowed values: success
Example
{
"details": {
"account_id": "013xrzp12g3nqk8ns6jadrqmpgrjkeny",
"association_type": "judge",
"from_agent_id": "013xrzp12g3nqk8ns6jadrqmpgrjkeny",
"id": "013xrzp12g3nqk8ns6jadrqmpgrjkeny",
"inserted_at": "2024-01-01T00:00:00Z",
"to_agent_id": "013xrzp12g3nqk8ns6jadrqmpgrjkeny",
"trigger": "on_demand",
"type": "agent_association",
"updated_at": "2024-01-01T00:00:00Z"
},
"status": "success"
}

Error

Media typeapplication/json
One of:
object
code
required
string
Allowed values: bad_request bad_authtoken not_authenticated not_permitted not_implemented unknown not_found unexpected_ref_type unexpected invalid_action invalid_state alert_unknown alert_already_cleared invalid_value required_value idempotency_key_already_used temporarily_unavailable conflict
message
required
string
status
required
string
Allowed values: error
Example
{
"code": "bad_request",
"status": "error"
}