Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

Freeflo Demo Backend

  • POST /webhook – Receives an incoming message, calls the LLM to parse intent (book / pay / inquire) and generate a reply.
  • POST /booking – Mock “confirm booking” endpoint to show a second Lambda and extensibility.

Test LLM locally (no AWS)

.venv\Scripts\activate
python test_webhook_local.py "I want to book a table for 2 tomorrow at 7pm"

Run Locally (SAM)

sam build
sam local start-api --env-vars env.json

Create env.json from env.json.example and set your OPENAI_API_KEY there for local Lambda runs.

Then:

  • Webhook (simulate incoming message)
    POST http://127.0.0.1:3000/webhook
    Body (JSON): { "message": "I want to book a table for 2 tomorrow at 7pm" }

  • Booking (mock confirm)
    POST http://127.0.0.1:3000/booking
    Body (JSON): { "intent": "book", "details": { "guests": 2, "time": "19:00" } }

Deploy to AWS

sam build
sam deploy --guided

Follow the prompts (stack name, region, etc.). After deploy, use the reported API Gateway URL for /webhook and /booking.

Environment Variables (Lambda)

For local run, use .env. For deployed Lambdas, set in template.yaml (or use Parameter Store/Secrets Manager):

  • OPENAI_API_KEY – required for LLM calls
  • OPENAI_BASE_URL – optional
  • OPENAI_MODEL – optional (default: gpt-4o-mini)

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages