Skip to main content
This walks you from zero to a published agent you can talk to. Every step is a single API call against the base URL https://builder.flowyte.com/api/v1.
All requests authenticate with a secret API key: Authorization: Bearer flowyte_sk_…. See Authentication for how to mint one.

1. Create an agent

curl -X POST https://builder.flowyte.com/api/v1/agents \
  -H "Authorization: Bearer $FLOWYTE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Acme Support" }'
The response is the ApiResponse<Agent> envelope. Capture data.id — that’s your agentId.

2. Give it knowledge

Add a source the agent can answer from. Knowledge ingestion is asynchronous — poll the source until its status is indexed.
curl -X POST https://builder.flowyte.com/api/v1/agents/$AGENT_ID/knowledge/sources \
  -H "Authorization: Bearer $FLOWYTE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "kind": "url", "label": "Help center", "url": "https://acme.com/help" }'

# poll until indexed
curl https://builder.flowyte.com/api/v1/agents/$AGENT_ID/knowledge/sources/$SOURCE_ID \
  -H "Authorization: Bearer $FLOWYTE_API_KEY"

3. Publish

The tester runs your draft; phone and chat run the last published version. Publish to freeze a version your channels can serve.
curl -X POST https://builder.flowyte.com/api/v1/agents/$AGENT_ID/publish \
  -H "Authorization: Bearer $FLOWYTE_API_KEY"
If you connect a channel before publishing, you’ll get 409 no_published_version. Publish first.

4. Test it

Simulate a conversation. This streams over Server-Sent Events — read it with fetch() streaming and stop on the event: done frame.
curl -N -X POST https://builder.flowyte.com/api/v1/agents/$AGENT_ID/simulate \
  -H "Authorization: Bearer $FLOWYTE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "message": "Do you offer same-day appointments?", "draftMode": false }'

5. Go live

Put the agent on an embeddable chat widget by minting a publishable key (browser-safe, origin-allowlisted), or assign it a phone number from the Numbers API.
curl -X POST https://builder.flowyte.com/api/v1/agents/$AGENT_ID/publishable-keys \
  -H "Authorization: Bearer $FLOWYTE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Website", "allowedOrigins": ["https://acme.com"] }'
Drop the returned loader snippet on your site and the agent is live.

Next: explore the concepts

Learn how agents, skills, knowledge, guardrails, and playbooks fit together.