APPLICATION_LOGS response_payload always null for non-streaming Strands agents
- Lingua principale
- TypeScript
- Stelle
- 283
- Fork
- 95
- Merge medio
- 1g 2h
- PR unite (30g)
- 183
Descrizione
### Description
## Problem
`response_payload` in APPLICATION_LOGS is always `null`, even though `request_payload` works fine.
## Setup
- Strands Agent deployed via `agentcore deploy`
- Non-streaming: `@app.entrypoint def invoke(...)` returns plain dict
- `bedrock-agentcore 1.6.3`, `strands-agents 1.35.0`, region `us-east-1`
- APPLICATION_LOGS delivery: CWL, `response_payload` is in `recordFields`
## What I see
```json
{
"request_payload": {"message": "hi", "user_type": "tourist"},
"response_payload": null
}
```
## What I tried
Changed return format to {"result": "..."} → still null
Toggled recordFields → still null
IAM permissions correct, Tracing enabled
## Question
Is response_payload only populated for SSE streaming responses (not plain JSON return)?
Or is there a config I'm missing?
### Steps to Reproduce
1. Deploy a Strands agent with `agentcore deploy` — use non-streaming entrypoint:
```python
@app.entrypoint
def invoke(payload, context):
agent = Agent(model=..., tools=[...])
result = agent(payload.get("message"))
return {"result": str(result)}
```
2.Enable APPLICATION_LOGS delivery to CloudWatch (via console or put-delivery-source)
3.Invoke the deployed agent via Agent Sandbox or invoke_agent_runtime API
4.Open CloudWatch → log group /aws/vendedlogs/bedrock-agentcore/runtime/APPLICATION_LOGS/
5.Observe: response_payload is null while request_payload is populated
### Expected Behavior
`response_payload` in APPLICATION_LOGS should contain the agent's return dict, e.g. `{"result": "..."}`.
### Actual Behavior
`response_payload` is always `null`, even though `request_payload` is populated and the agent responds correctly to clients.
### CLI Version
0.8.2
### Operating System
Windows
### Additional Context
_No response_
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia riproducendo il problema con l’esempio Python non-streaming @app.entrypoint e la configurazione documentata di agentcore deploy e APPLICATION_LOGS. Traccia il modo in cui l’integrazione della CLI o di AgentCore gestisce request_payload e response_payload, quindi verifica se il dizionario della risposta appare nei log di CloudWatch oppure individua la configurazione mancante o il comportamento non supportato.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- aws, python, typescript
- Ambito
- cloud, observability
- Tipo di issue
- Bug
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Tranquilla
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 38/100