diff --git a/Makefile b/Makefile index 62981eb..8d07ac0 100644 --- a/Makefile +++ b/Makefile @@ -28,9 +28,12 @@ chat: python3.13 testclient/client.py sample: - curl -XPOST http://127.0.0.1:8000/api/agent/run \ + @echo "Set FIREBASE_ID_TOKEN or SKIP_TOKEN_AUTH_HEADER/SKIP_TOKEN_AUTH_KEY before running make sample." + curl -XPOST http://127.0.0.1:8000/api/v2/agent/run \ -H "Content-Type: application/json" \ + $(if $(FIREBASE_ID_TOKEN),-H "Authorization: Bearer $(FIREBASE_ID_TOKEN)") \ + $(if $(and $(SKIP_TOKEN_AUTH_HEADER),$(SKIP_TOKEN_AUTH_KEY)),-H "$(SKIP_TOKEN_AUTH_HEADER): $(SKIP_TOKEN_AUTH_KEY)") \ -d @sample-payload.json | jq format: - ruff format . \ No newline at end of file + ruff format . diff --git a/sample-payload.json b/sample-payload.json index 671bf3a..2801ab9 100644 --- a/sample-payload.json +++ b/sample-payload.json @@ -1,10 +1,12 @@ { - "context": { - "address": "0x1234567890123456789012345678901234567890", - "conversationHistory": [], - }, - "message": { - "type": "user", - "message": "What is the price of BTC?" - } -} \ No newline at end of file + "context": { + "address": "0x1234567890123456789012345678901234567890", + "conversationHistory": [] + }, + "message": { + "type": "user", + "message": "What is the price of BTC?" + }, + "agent": "analytics_agent", + "captchaToken": "test-captcha-token" +}