ASSISTANTS API: Where and how long are entities saved

2025-01-31T15:58:55.82+00:00

Question 1:

When creating a new thread with the Assistants API, thereby creating a stateful entity of: Threads, messages, where is this data stored, can I access the resource that stores these? Or is the resource managed entirely by Microsoft, and inaccessible to me?

Question 2:

If a thread with messages is created via the API, and the ID is lost, is there then no route to access and delete this thread? As in, would there be a way to somehow fetch all threads related to a specific OpenAI Azure resource?

Question 3:

Is stateful entities stored INDEFINITELY unless deleted? Or is the a time to live if not used?

Kind regards

Jesper

Azure OpenAI Service
Azure OpenAI Service
An Azure service that provides access to OpenAI’s GPT-3 models with enterprise capabilities.
3,597 questions
0 comments No comments
{count} vote

1 answer

Sort by: Most helpful
  1. Pavankumar Purilla 3,005 Reputation points Microsoft Vendor
    2025-02-01T00:29:49.65+00:00

    Hi Jesper Alkestrup - The Tech Collective,
    Greetings & Welcome to Microsoft Q&A forum! Thanks for posting your query!

    When creating a new thread with the Assistants API, thereby creating a stateful entity of: Threads, messages, where is this data stored, can I access the resource that stores these? Or is the resource managed entirely by Microsoft, and inaccessible to me?
    When you create a new thread with the Assistants API, the data (threads, messages, etc.) is stored in a secure, Microsoft-managed storage account. This storage is logically separated to ensure data security. As a user, you do not have direct access to the underlying storage resources. Instead, you interact with the data through the API endpoints provided by Microsoft.

    If a thread with messages is created via the API, and the ID is lost, is there then no route to access and delete this thread? As in, would there be a way to somehow fetch all threads related to a specific OpenAI Azure resource?
    If you lose the thread ID, there is no direct way to retrieve or delete the thread through the API. The Assistants API does not currently provide a method to list all threads associated with a specific OpenAI Azure resource. Therefore, it's crucial to manage and store thread IDs securely within your application to ensure you can access and manage them as needed.

    Is stateful entities stored INDEFINITELY unless deleted? Or is the a time to live if not used?
    All used data persists in this system unless you explicitly delete this data. Use the delete function with the thread ID of the thread you want to delete. Clearing the Run in the Assistants Playground does not delete threads, however deleting them using delete function will not list them in the thread page.

    Hope this helps. Do let us know if you have any further queries.


    If this answers your query, do click Accept Answer and Yes for was this answer helpful.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.