creating documents under case via REST api

HI all,
i am facing a problem here , when i try creating documents under case via REST api , documents get created but not under Cases. Documents and Cases have many-many relationship with each other and the link field to pass while creating documents under case is "case_id".


{"session":"cc7kjujeogmm1pkpua2pesv4l3",
"module_name":"Documents",
"name_value_list":[
{"name":"document_name","value":"document 2"},
{"name":"revision","value":"1"},
{"name":"case_id","value":"d9220283-2fcc-ce12-0e10-550fa302d010"}
]}
the above is the JSON body request for creating documents under case , when i hit it documents get created but not under case whose id is provided and when i search for error log it says "undefined Index: case_id not found".