Creating a TEI with associated event via API - working inconsistently

Hi there,

We are using the API to create TEI’s with an associated event.
This has been working fine but every so often just the TEI gets created but the associated event isn’t. The API response seems to indicate that everything went through fine but there is no event linked to the TEI.

Can anyone advise what to look at and maybe this has been seen before?

Thanks

Peter

Hi @Peter,

Can you give examples of the API calls you are using, and in which version you are doing this?

Thanks,
Karoline

Hi Karoline,

Thanks for the reply and apologies for the late reply.

We managed to work out that the OU being referenced hadn’t been assigned to the Program. So the TEI was created but then the event wouldn’t be created.
Once the OU was assigned to the Program then it worked.

Thanks

Peter

Hi @Peter,

I am wondering if you could share your script on how to create a TEI with an associated event via API.
I have always sought to do this, but I am not quite familiar with web API.

Thanks.