No assistant found with id 'asst-...'

I am using the API to try and create a chatbot with an assistant. When I go to create a run, I put the assistant_id in the body and I get this error:
{
“error”: {
“message”: “No assistant found with id ‘asst_…’.”,
“type”: “invalid_request_error”,
“param”: null,
“code”: null
}
}
This is only true for my assistants that are a part of an organazation. Ones that are “Personal” work perfectly. I have had this issue with multiple different assistants, made at different times. But when the assistants are under an organzation it does not work.

1 Like

Hi

Having a similar issue (possibly minus the Organization bit). The assistant is retrieved successfully but when it’s id is passed to Create Run the endpoint with the correct thread_id the response is always “No assistant found with id…”

Would greatly appreciate some help as this is blocking me at the moment.

Thanks.

1 Like

Ok, solved this one, developer error: on serialisation and before sending the request to OpenAI the entire string is converted to lower case. Things like thread_id and assistant_id are case sensitive at the OpenAI endpoint and contain a mixture of CAPs and non-caps. So the assitant_id is kinda the same but not exactly. Hence the bug
:man_facepalming:

2 Likes

Thanks for coming back to let us know. Hope you stick around. We’ve got a great community growing here.

3 Likes

Hopefully, others will now not make the same mistake. :+1:
Not going anywhere for the moment :slight_smile:

1 Like

Thanks for the feedback.

We often get problems or complaints, try to help and then dead air.

It is nice to see a solution to a problem posted and even nicer when the one posting the solution is by the one posting the question.

I agree with what Paul said.

1 Like

@lewissummers

Does the solution by @lewissummers solve your problem?

If so can you mark that as the solution by clicking image

Do you have any more questions?

Is it OK if a moderator closes this topic?

Also, please be specific when giving answers, all to often I see Yep and then have no idea what Yep applies to.

We are also getting a 404 error for our assistant created through the playground. I am wondering if the bug still exists?

We created the assistant at the playground and now trying to call it via the APIs.

Have you solved your issue?

I see the same - the assistant created in the platform UI is not available in the API, and vice-versa - an assistant created with API does not show up in the platform UI.

We created the assistant programmatically in code and use it and then we destroy the assistant after the task is complete. Spawn it again and this cycle continues.

This way the assistant_id remains in session of the task.

1 Like

Thanks for the reply.
In my case the issue was that the API created assistant, had its key assigned to a different project than the one created in UI, so basically the two assistants were on different projects and that’s why I couldn’t see/use them in the same context.