Skip to main content
This walkthrough takes one short conversation from the first call to a settled place. The examples are real answers from a position at 17th and Folsom Street in San Francisco.

1. Get a key

Open api.kviria.com/key and create a key. It is shown once, so copy it. Every call carries it in the Authorization header. In the examples below it is $KVIRIA_KEY. An MCP client can connect with OAuth instead: see Connect and pay. Every call also names your agent with ?agent= in the URL. The name keeps your agent’s context apart from other agents’. It is not a secret.

2. Send the request

Your agent parses the user’s words into the request’s fields. The user asks “is there a cafe near here”: that is search with the kind cafe. Send it with an empty state and the user’s position as anchor:
Three cafes match, so the decision is many:
Ask the user which one, with the names and distances: “Stable Cafe, 8 m away, Rite Spot Cafe, 59 m away, or Robin’s Cafe, 102 m away?“

3. Send the choice with the state

The user says “the second one”: that is pick with the number 2. Send it with the state from the last response. The user has not moved, so leave anchor out:
The place is settled:
Keep calling on the user’s next turns with the newest state. “What’s across the street from it” is now across with the place’s ref, the gers of Rite Spot Cafe. The states shown here are examples. Yours come from your own responses, so always send back the one you received.

4. Confirm a place named in part

A new conversation starts with an empty state and the position again. The user says “take me to rite spot”: that is find with the place’s name as the user said it, { "name": "rite spot" }. It names Rite Spot Cafe only in part, so the answer waits for the user’s yes, and its target has no location yet:
Ask the user to confirm the place, and send the answer as confirm with "answer": "yes" or "no". A yes comes back as one with the location and "confirmed": true. A no comes back as unclear here, so ask the user to say more. See Confirmation.

5. Let your agent answer small talk

When the user’s words are not about a place, such as “thanks, that’s all”, do not call Kviria. Reply to the user yourself.

Before you build

  • Give your agent Kviria’s system prompt. It is in the skill.
  • An account gets free turns every day, and pays per turn from a balance after them. See Rate limits and Payments.
  • Coverage is the contiguous United States.
  • Your agent speaks MCP? Connect the MCP server instead.
  • Each error and what to do about it: Errors.