{
  "$type": "site.standard.document",
  "bskyPostRef": {
    "cid": "bafyreihzgdxqifkmsocr7zy3h3ftbf4lwt6uaeqdwqkwpl4eily4ic5uz4",
    "uri": "at://did:plc:lk3jfj3zq4k4wxnk474axylu/app.bsky.feed.post/3mksrxlnwask2"
  },
  "path": "/t/responses-corrupts-previous-conversations-assistant-item/1380154#post_2",
  "publishedAt": "2026-05-01T18:07:17.000Z",
  "site": "https://community.openai.com",
  "textContent": "I can’t repro that.\n\nLet’s make a script:\n\n\n    #!/usr/bin/env bash\n    set -euo pipefail\n\n    : \"${OPENAI_API_KEY:?Set OPENAI_API_KEY first}\"\n\n    BASE=\"https://api.openai.com/v1\"\n    AUTH=(-H \"Authorization: Bearer $OPENAI_API_KEY\" -H \"Content-Type: application/json\")\n\n    echo \"1) Create conversation\"\n    CONV_ID=$(\n      curl -sS \"$BASE/conversations\" \\\n        \"${AUTH[@]}\" \\\n        -d '{}' | jq -r '.id'\n    )\n    echo \"CONV_ID=$CONV_ID\"\n\n    echo \"2) Add hard-coded bot/assistant message to conversation\"\n    ADD_ITEM_JSON=$(\n      curl -sS \"$BASE/conversations/$CONV_ID/items\" \\\n        \"${AUTH[@]}\" \\\n        -d '{\n          \"items\": [\n            {\n              \"type\": \"message\",\n              \"role\": \"assistant\",\n              \"content\": \"This is a hard-coded bot message that should remain in the conversation.\"\n            }\n          ]\n        }'\n    )\n    echo \"$ADD_ITEM_JSON\" | jq .\n\n    ITEM_ID=$(echo \"$ADD_ITEM_JSON\" | jq -r '.data[0].id')\n    echo \"ITEM_ID=$ITEM_ID\"\n\n    echo \"3) Retrieve that item before Responses call\"\n    curl -sS \"$BASE/conversations/$CONV_ID/items/$ITEM_ID\" \\\n      \"${AUTH[@]}\" | jq .\n\n    echo \"4) List all items before Responses call\"\n    curl -sS \"$BASE/conversations/$CONV_ID/items?order=asc\" \\\n      \"${AUTH[@]}\" | jq .\n\n    echo \"5) Create a model response using the conversation\"\n    curl -sS \"$BASE/responses\" \\\n      \"${AUTH[@]}\" \\\n      -d \"{\n        \\\"model\\\": \\\"gpt-4.1-mini\\\",\n        \\\"conversation\\\": \\\"$CONV_ID\\\",\n        \\\"input\\\": \\\"Please respond briefly. What was the hard-coded bot message?\\\"\n      }\" | jq .\n\n    echo \"6) Retrieve original hard-coded item after Responses call\"\n    curl -sS \"$BASE/conversations/$CONV_ID/items/$ITEM_ID\" \\\n      \"${AUTH[@]}\" | jq .\n\n    echo \"7) List all items after Responses call\"\n    curl -sS \"$BASE/conversations/$CONV_ID/items?order=asc\" \\\n      \"${AUTH[@]}\" | jq .\n\n\nnow run it:\n\n\n    export OPENAI_API_KEY=\"sk-...\"\n    chmod +x repro.sh\n    ./repro.sh\n\n\nresult:\n\n\n    1) Create conversation\n    CONV_ID=conv_<redacted>\n\n    2) Add hard-coded bot/assistant message to conversation\n    {\n      \"object\": \"list\",\n      \"data\": [\n        {\n          \"id\": \"msg_<redacted>\",\n          \"type\": \"message\",\n          \"status\": \"completed\",\n          \"content\": [\n            {\n              \"type\": \"input_text\",\n              \"text\": \"This is a hard-coded bot message that should remain in the conversation.\"\n            }\n          ],\n          \"role\": \"assistant\"\n        }\n      ],\n      \"first_id\": \"msg_<redacted>\",\n      \"has_more\": false,\n      \"last_id\": \"msg_<redacted>\"\n    }\n    ITEM_ID=msg_<redacted>\n\n    3) Retrieve that item before Responses call\n    {\n      \"id\": \"msg_<redacted>\",\n      \"type\": \"message\",\n      \"status\": \"completed\",\n      \"content\": [\n        {\n          \"type\": \"input_text\",\n          \"text\": \"This is a hard-coded bot message that should remain in the conversation.\"\n        }\n      ],\n      \"role\": \"assistant\"\n    }\n\n    4) List all items before Responses call\n    {\n      \"object\": \"list\",\n      \"data\": [\n        {\n          \"id\": \"msg_<redacted>\",\n          \"type\": \"message\",\n          \"status\": \"completed\",\n          \"content\": [\n            {\n              \"type\": \"input_text\",\n              \"text\": \"This is a hard-coded bot message that should remain in the conversation.\"\n            }\n          ],\n          \"role\": \"assistant\"\n        }\n      ],\n      \"first_id\": \"msg_<redacted>\",\n      \"has_more\": false,\n      \"last_id\": \"msg_<redacted>\"\n    }\n\n    5) Create a model response using the conversation\n    {\n      \"id\": \"resp_<redacted>\",\n      \"object\": \"response\",\n      \"created_at\": 1777658589,\n      \"status\": \"completed\",\n      \"background\": false,\n      \"billing\": {\n        \"payer\": \"openai\"\n      },\n      \"completed_at\": 1777658591,\n      \"conversation\": {\n        \"id\": \"conv_<redacted>\"\n      },\n      \"error\": null,\n      \"frequency_penalty\": 0.0,\n      \"incomplete_details\": null,\n      \"instructions\": null,\n      \"max_output_tokens\": null,\n      \"max_tool_calls\": null,\n      \"model\": \"gpt-4.1-mini-2025-04-14\",\n      \"moderation\": null,\n      \"output\": [\n        {\n          \"id\": \"msg_<redacted>\",\n          \"type\": \"message\",\n          \"status\": \"completed\",\n          \"content\": [\n            {\n              \"type\": \"output_text\",\n              \"annotations\": [],\n              \"logprobs\": [],\n              \"text\": \"The hard-coded bot message was:  \\n\\\"This is a hard-coded bot message that should remain in the conversation.\\\"\"\n            }\n          ],\n          \"role\": \"assistant\"\n        }\n      ],\n      \"parallel_tool_calls\": true,\n      \"presence_penalty\": 0.0,\n      \"previous_response_id\": null,\n      \"prompt_cache_key\": null,\n      \"prompt_cache_retention\": \"in_memory\",\n      \"reasoning\": {\n        \"effort\": null,\n        \"summary\": null\n      },\n      \"safety_identifier\": null,\n      \"service_tier\": \"default\",\n      \"store\": true,\n      \"temperature\": 1.0,\n      \"text\": {\n        \"format\": {\n          \"type\": \"text\"\n        },\n        \"verbosity\": \"medium\"\n      },\n      \"tool_choice\": \"auto\",\n      \"tools\": [],\n      \"top_logprobs\": 0,\n      \"top_p\": 1.0,\n      \"truncation\": \"disabled\",\n      \"usage\": {\n        \"input_tokens\": 37,\n        \"input_tokens_details\": {\n          \"cached_tokens\": 0\n        },\n        \"output_tokens\": 23,\n        \"output_tokens_details\": {\n          \"reasoning_tokens\": 0\n        },\n        \"total_tokens\": 60\n      },\n      \"user\": null,\n      \"metadata\": {}\n    }\n\n    6) Retrieve original hard-coded item after Responses call\n    {\n      \"id\": \"msg_<redacted>\",\n      \"type\": \"message\",\n      \"status\": \"completed\",\n      \"content\": [\n        {\n          \"type\": \"input_text\",\n          \"text\": \"This is a hard-coded bot message that should remain in the conversation.\"\n        }\n      ],\n      \"role\": \"assistant\"\n    }\n\n    7) List all items after Responses call\n    {\n      \"object\": \"list\",\n      \"data\": [\n        {\n          \"id\": \"msg_<redacted>\",\n          \"type\": \"message\",\n          \"status\": \"completed\",\n          \"content\": [\n            {\n              \"type\": \"input_text\",\n              \"text\": \"This is a hard-coded bot message that should remain in the conversation.\"\n            }\n          ],\n          \"role\": \"assistant\"\n        },\n        {\n          \"id\": \"msg_<redacted>\",\n          \"type\": \"message\",\n          \"status\": \"completed\",\n          \"content\": [\n            {\n              \"type\": \"input_text\",\n              \"text\": \"Please respond briefly. What was the hard-coded bot message?\"\n            }\n          ],\n          \"role\": \"user\"\n        },\n        {\n          \"id\": \"msg_<redacted>\",\n          \"type\": \"message\",\n          \"status\": \"completed\",\n          \"content\": [\n            {\n              \"type\": \"output_text\",\n              \"annotations\": [],\n              \"logprobs\": [],\n              \"text\": \"The hard-coded bot message was:  \\n\\\"This is a hard-coded bot message that should remain in the conversation.\\\"\"\n            }\n          ],\n          \"role\": \"assistant\"\n        }\n      ],\n      \"first_id\": \"msg_<redacted>\",\n      \"has_more\": false,\n      \"last_id\": \"msg_<redacted>\"\n    }\n\n\nI wonder if your data shape is wrong or you are using the wrong properties?",
  "title": "`responses` corrupts previous conversations `assistant` item"
}