hi ,
In Unity Connection 10.0 version i tried to Add local user and Import Active directory User but for both request iam getting the error like [Fatal Error] :1:1: Content is not allowed in prolog. iam using REST API to Add User for Post request only iam getting this error ,but USER is added into the server for DELETE ,PUT and GET request iam getting response 204. for POST Not getting any response code instead of this getting the above error what i mentioned.
my code
=============================================================
req = new CUPIRESTRequest( 'path': path , body: [ "Alias":"raghu","DtmfAccessId":"112233","FirstName":"Raghavendra","LastName":"Mankar","EmailAddress":"raghu@ymail.com" ], contentType: 'application/json' );
def res=client.post( req );
public Response post(CUPIRESTRequest cupiRequest) {
log.info "Executing CUPI Request For ${cupiRequest.path} - Start"
def res = client?.post(path: cupiRequest.path) {
type cupiRequest.contentType
json cupiRequest.body
}
log.info "Executing CUPI Request For ${cupiRequest.path} - Start"
return res;
}
======================================================================================
In cisco developer api given as follow
===============================
POST https://<Connection-server>/vmrest/users?templateAlias=voicemailusertemplate
Accept: application/json
Content_type: application/json
Connection: keep_alive
Request Body:
{
"Alias":"voicemailusertemplate1",
"DisplayName":"Voice Mail User Template 1"
}
Thanks,