Adding unschedule visit
Hello,
I need to add an event of unschedule visit for a subject.
Which API or payload can be used to add an unscheduled visit?

I am not sure RWS provides functionality for this. What have you tried?
I was trying to post similar clinical data
<ClinicalData StudyOID="XXXX" MetaDataVersionOID="xxx"> <SubjectData SubjectKey="QUERY1"> <SiteRef LocationOID="000000"/> <StudyEventData StudyEventOID="UNSVIS" StudyEventRepeatKey="1" TransactionType="Insert"> <FormData FormOID="SV_GEN_U01"> <ItemGroupData ItemGroupOID="SV_GEN_U01"> </ItemGroupData> </FormData> </StudyEventData> </SubjectData> </ClinicalData>
There's an example in the learn.mdsol.com page for this, maybe it will help:
<ODM xmlns="http://www.cdisc.org/ns/odm/v1.3" ODMVersion="1.3" FileType="Transactional" FileOID="Example-4" CreationDateTime="2008-01-01T00:00:00">
<ClinicalData StudyOID="Mediflex(Dev)" MetaDataVersionOID="1">
<SubjectData SubjectKey="123 ABC" TransactionType="Update">
<SiteRef LocationOID="4567"/>
<StudyEventData StudyEventOID="UNSCHEDULED" StudyEventRepeatKey="1" TransactionType="Insert">
<FormData FormOID="VISIT">
<ItemGroupData ItemGroupOID="VISIT">
<ItemData ItemOID="DTC" Value="21 FEB 2008"/>
</ItemGroupData>
</FormData>
</StudyEventData>
</SubjectData>
</ClinicalData>
</ODM>
This is supposed to add a new folder, so there is support. Note that the SubjectData has a transaction type of "Update". Try adding that to your example. If it doesn't work, what is the error message?
Thanks @isparks Yes, i had tried this payload and it had worked by adding unscheduled folder along with data of visit form.
When i tried to add a unschedule visit via "Add Event" from UI, it adds lot more CRFs under unscheduled visit. Do i need ti add more CRF within this payload as i am assuming that Rave may be executing some custom functions.
Adding an "event" in the UI is really adding a Matrix, no? And a Matrix means folder/form combinations being added. I think this is why you are seeing more CRF's when you do this from the UI. When you add an "event" via ODM you're adding an ODM StudyEvent which is a Folder in Rave, so these are no the same thing. I don't know that there is a way to add a Matrix via ODM POST.
I think you are right.. adding a matrix is an issue
I think all you can do here is add all the forms/folders you need in the ODM post.