const options = {
method: 'POST',
headers: {
'Operator-Version': '<operator-version>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
name: '<string>',
description: '<string>',
config: {
filter_statuses: [],
runtime: {prompt: {text: '<string>', type: 'fixed'}, reasoning_effort: 'medium'},
tool: {tools: [{name: '<string>'}]},
output: {slack_channel: null, output_schema: null, post_url: null},
filter_condition: null
}
})
};
fetch('https://api.operator.xyz/procedural_agents', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));