juan_rodriguez Absent Member.
Absent Member.
4552 views

Verastream 7.7 Rest Service with Jquery getJSON Help

All,

I'm trying to use the Rest services provided by Verastream after I deploy my model. However, I can only manage to get back the json file for the rest services that outlines what is provided. I'm not getting back the actual data I am seeking from connecting to the model and querying the screens.

Here is my jquery:

$(document).ready(function(){
$.getJSON('http://localhost:9680/vhi-rs/model/facilitatedInstall/readBPI', {
modVars: {
userID: "myId", password: "fakepass",
Access_Code: "bbbb", Payloc: "210",
System: "i", TOPSRegion: "abcd", PolicyNumber: "123456",
PlanVariation: "7777", CTITable: "000010"
}
})

.done(function (json){
alert("Worked" + JSON.stringify(json))})
.fail(function (jqxhr, textStatus, error){
var err = textStatus + "," + error;
alert(err);
});


});


This returns this, not what I am really after:

{
"modelName" : "facilitatedInstall",
"version" : "Verastream Host Integrator - Apptrieve 7.7.34 Model v1464368961:1:0471651823 ",
"modVars" : [ {
"name" : "userID",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "password",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "cursorPosition",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "Access_Code",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "Payloc",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "System",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "TOPSRegion",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "PolicyNumber",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "PlanVariation",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "CTITable",
"type" : "string",
"nullable" : true,
"optional" : true
} ],
"envVars" : [ {
"name" : "DomainName",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "ServerName",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "SessionId",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "Password",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "Username",
"type" : "string",
"nullable" : true,
"optional" : true
} ],
"procedures" : [ {
"name" : "InsertBPI",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/InsertBPI",
"filters" : null,
"inputs" : [ {
"name" : "policy",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "bankAccount",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "system",
"type" : "string",
"nullable" : true,
"optional" : true
} ],
"result" : null,
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "InsertMMI_11",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/InsertMMI_11",
"filters" : null,
"inputs" : [ {
"name" : "coreDualOop",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreOopNcap",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSal",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSaleNbr",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSalMult",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSalType",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSalType2",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "ee1CoreDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "ee1CoreInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "eeChCoreDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "eeChCoreInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "eeSpCoreDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "eeSpCoreInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famCoreDualOOP",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famCoreInnOop",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famCoreT1",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famMaxCopayDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famMaxCopayInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famMaxCopayT1",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indCoreInnOop",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indCoreOOPCode",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indCoreOOPCodePd",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indCoreT1",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indMaxCopayCo",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indMaxCopayDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indMaxCopayInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indMaxCopayT1",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "nonEmbCoreOOP",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "nonEmbMaxCopay",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "xapplyCoreOopInd",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "xapplyMaxCopayInd2",
"type" : "string",
"nullable" : true,
"optional" : true
} ],
"result" : null,
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readBPI",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readBPI",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "policy",
"type" : "string"
}, {
"name" : "bankAccount",
"type" : "string"
}, {
"name" : "system",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTI",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTI",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTIActiveInactive",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTIActiveInactive",
"filters" : [ {
"name" : "sts",
"type" : "string",
"nullable" : true,
"optional" : false
} ],
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTIByCreateDate",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTIByCreateDate",
"filters" : [ {
"name" : "createDate",
"type" : "string",
"nullable" : true,
"optional" : false
} ],
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTIByProductionStatus",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTIByProductionStatus",
"filters" : [ {
"name" : "pi",
"type" : "string",
"nullable" : true,
"optional" : false
} ],
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTIByUpdateDate",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTIByUpdateDate",
"filters" : [ {
"name" : "updateDate",
"type" : "string",
"nullable" : true,
"optional" : false
} ],
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTISelectionScreenHeader",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTISelectionScreenHeader",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "action",
"type" : "string"
}, {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "coinCopay",
"type" : "string"
}, {
"name" : "combLevels",
"type" : "string"
}, {
"name" : "combPcpSpec",
"type" : "string"
}, {
"name" : "copayMax",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "erWaive",
"type" : "string"
}, {
"name" : "iVisitLimitER",
"type" : "string"
}, {
"name" : "iVisitLimitPcp",
"type" : "string"
}, {
"name" : "iVisitLimitSpec",
"type" : "string"
}, {
"name" : "iVisitLimitUC",
"type" : "string"
}, {
"name" : "newTableNumber",
"type" : "string"
}, {
"name" : "oVisitLimitER",
"type" : "string"
}, {
"name" : "oVisitLimitPcp",
"type" : "string"
}, {
"name" : "oVisitLimitSpec",
"type" : "string"
}, {
"name" : "oVisitLimitUC",
"type" : "string"
}, {
"name" : "pcpInd",
"type" : "string"
}, {
"name" : "prod",
"type" : "string"
}, {
"name" : "tableNumber",
"type" : "string"
}, {
"name" : "tVisitLimitPCP",
"type" : "string"
}, {
"name" : "tVisitLimitPcpEr",
"type" : "string"
}, {
"name" : "tVisitLimitPcpSpec",
"type" : "string"
}, {
"name" : "tVisitLimitPcpUC",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTISelectionScreenRecords",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTISelectionScreenRecords",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "a",
"type" : "string"
}, {
"name" : "ageFR",
"type" : "string"
}, {
"name" : "ageTo",
"type" : "string"
}, {
"name" : "C",
"type" : "string"
}, {
"name" : "CC",
"type" : "string"
}, {
"name" : "L",
"type" : "string"
}, {
"name" : "md",
"type" : "string"
}, {
"name" : "md1",
"type" : "string"
}, {
"name" : "net",
"type" : "string"
}, {
"name" : "nonPcpCopay",
"type" : "string"
}, {
"name" : "oop",
"type" : "string"
}, {
"name" : "org",
"type" : "string"
}, {
"name" : "pcpCopay",
"type" : "string"
}, {
"name" : "pr",
"type" : "string"
}, {
"name" : "procFrom",
"type" : "string"
}, {
"name" : "procTo",
"type" : "string"
}, {
"name" : "ps",
"type" : "string"
}, {
"name" : "rel",
"type" : "string"
}, {
"name" : "scs",
"type" : "string"
}, {
"name" : "srvcCode",
"type" : "string"
}, {
"name" : "t",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readMMI_11",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readMMI_11",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "coreDualOop",
"type" : "string"
}, {
"name" : "coreOopNcap",
"type" : "string"
}, {
"name" : "coreSal",
"type" : "string"
}, {
"name" : "coreSaleNbr",
"type" : "string"
}, {
"name" : "coreSalMult",
"type" : "string"
}, {
"name" : "coreSalType",
"type" : "string"
}, {
"name" : "coreSalType2",
"type" : "string"
}, {
"name" : "ee1CoreDual",
"type" : "string"
}, {
"name" : "ee1CoreInn",
"type" : "string"
}, {
"name" : "eeChCoreDual",
"type" : "string"
}, {
"name" : "eeChCoreInn",
"type" : "string"
}, {
"name" : "eeSpCoreDual",
"type" : "string"
}, {
"name" : "eeSpCoreInn",
"type" : "string"
}, {
"name" : "famCoreDualOOP",
"type" : "string"
}, {
"name" : "famCoreInnOop",
"type" : "string"
}, {
"name" : "famCoreT1",
"type" : "string"
}, {
"name" : "famMaxCopayDual",
"type" : "string"
}, {
"name" : "famMaxCopayInn",
"type" : "string"
}, {
"name" : "famMaxCopayT1",
"type" : "string"
}, {
"name" : "indCoreInnOop",
"type" : "string"
}, {
"name" : "indCoreOOPCode",
"type" : "string"
}, {
"name" : "indCoreOOPCodePd",
"type" : "string"
}, {
"name" : "indCoreT1",
"type" : "string"
}, {
"name" : "indMaxCopayCo",
"type" : "string"
}, {
"name" : "indMaxCopayDual",
"type" : "string"
}, {
"name" : "indMaxCopayInn",
"type" : "string"
}, {
"name" : "indMaxCopayT1",
"type" : "string"
}, {
"name" : "newPolicyNumber",
"type" : "string"
}, {
"name" : "nonEmbCoreOOP",
"type" : "string"
}, {
"name" : "nonEmbMaxCopay",
"type" : "string"
}, {
"name" : "planVari",
"type" : "string"
}, {
"name" : "xapplyCoreOopInd",
"type" : "string"
}, {
"name" : "xapplyMaxCopayInd2",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "rsResourceCreate",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/rsResourceCreate",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "SessionId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "JsonProcessingException", "ResourceUnavailableException" ]
}
}, {
"name" : "rsResourceDestroy",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/rsResourceDestroy",
"filters" : null,
"inputs" : null,
"result" : null,
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "JsonProcessingException", "ResourceUnavailableException" ]
}
} ]
}

Anyone know how to actually get the data from the model?

I reviewed the rest example application (which works), but they are using angular.js and I'm having a hard time translating that to simple jQuery.

Any help would be greatly appreciated.
0 Likes
3 Replies
darnelho Absent Member.
Absent Member.

Re: Verastream 7.7 Rest Service with Jquery getJSON Help

What data are you trying to get back?

modVars are set not retrieved why do you have them specified in your Jquery.getJSON request?

-Microfocus Technical Support.


juan_rodriguez;2430335 wrote:
All,

I'm trying to use the Rest services provided by Verastream after I deploy my model. However, I can only manage to get back the json file for the rest services that outlines what is provided. I'm not getting back the actual data I am seeking from connecting to the model and querying the screens.

Here is my jquery:

$(document).ready(function(){
$.getJSON('http://localhost:9680/vhi-rs/model/facilitatedInstall/readBPI', {
modVars: {
userID: "myId", password: "fakepass",
Access_Code: "bbbb", Payloc: "210",
System: "i", TOPSRegion: "abcd", PolicyNumber: "123456",
PlanVariation: "7777", CTITable: "000010"
}
})

.done(function (json){
alert("Worked" + JSON.stringify(json))})
.fail(function (jqxhr, textStatus, error){
var err = textStatus + "," + error;
alert(err);
});


});


This returns this, not what I am really after:

{
"modelName" : "facilitatedInstall",
"version" : "Verastream Host Integrator - Apptrieve 7.7.34 Model v1464368961:1:0471651823 ",
"modVars" : [ {
"name" : "userID",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "password",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "cursorPosition",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "Access_Code",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "Payloc",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "System",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "TOPSRegion",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "PolicyNumber",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "PlanVariation",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "CTITable",
"type" : "string",
"nullable" : true,
"optional" : true
} ],
"envVars" : [ {
"name" : "DomainName",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "ServerName",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "SessionId",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "Password",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "Username",
"type" : "string",
"nullable" : true,
"optional" : true
} ],
"procedures" : [ {
"name" : "InsertBPI",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/InsertBPI",
"filters" : null,
"inputs" : [ {
"name" : "policy",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "bankAccount",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "system",
"type" : "string",
"nullable" : true,
"optional" : true
} ],
"result" : null,
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "InsertMMI_11",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/InsertMMI_11",
"filters" : null,
"inputs" : [ {
"name" : "coreDualOop",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreOopNcap",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSal",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSaleNbr",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSalMult",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSalType",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "coreSalType2",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "ee1CoreDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "ee1CoreInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "eeChCoreDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "eeChCoreInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "eeSpCoreDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "eeSpCoreInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famCoreDualOOP",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famCoreInnOop",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famCoreT1",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famMaxCopayDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famMaxCopayInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "famMaxCopayT1",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indCoreInnOop",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indCoreOOPCode",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indCoreOOPCodePd",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indCoreT1",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indMaxCopayCo",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indMaxCopayDual",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indMaxCopayInn",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "indMaxCopayT1",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "nonEmbCoreOOP",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "nonEmbMaxCopay",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "xapplyCoreOopInd",
"type" : "string",
"nullable" : true,
"optional" : true
}, {
"name" : "xapplyMaxCopayInd2",
"type" : "string",
"nullable" : true,
"optional" : true
} ],
"result" : null,
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readBPI",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readBPI",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "policy",
"type" : "string"
}, {
"name" : "bankAccount",
"type" : "string"
}, {
"name" : "system",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTI",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTI",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTIActiveInactive",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTIActiveInactive",
"filters" : [ {
"name" : "sts",
"type" : "string",
"nullable" : true,
"optional" : false
} ],
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTIByCreateDate",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTIByCreateDate",
"filters" : [ {
"name" : "createDate",
"type" : "string",
"nullable" : true,
"optional" : false
} ],
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTIByProductionStatus",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTIByProductionStatus",
"filters" : [ {
"name" : "pi",
"type" : "string",
"nullable" : true,
"optional" : false
} ],
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTIByUpdateDate",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTIByUpdateDate",
"filters" : [ {
"name" : "updateDate",
"type" : "string",
"nullable" : true,
"optional" : false
} ],
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "copay",
"type" : "string"
}, {
"name" : "createDate",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "pi",
"type" : "string"
}, {
"name" : "sel",
"type" : "string"
}, {
"name" : "sts",
"type" : "string"
}, {
"name" : "updateDate",
"type" : "string"
}, {
"name" : "userId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTISelectionScreenHeader",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTISelectionScreenHeader",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "action",
"type" : "string"
}, {
"name" : "cancDate",
"type" : "string"
}, {
"name" : "coinCopay",
"type" : "string"
}, {
"name" : "combLevels",
"type" : "string"
}, {
"name" : "combPcpSpec",
"type" : "string"
}, {
"name" : "copayMax",
"type" : "string"
}, {
"name" : "description",
"type" : "string"
}, {
"name" : "effDate",
"type" : "string"
}, {
"name" : "erWaive",
"type" : "string"
}, {
"name" : "iVisitLimitER",
"type" : "string"
}, {
"name" : "iVisitLimitPcp",
"type" : "string"
}, {
"name" : "iVisitLimitSpec",
"type" : "string"
}, {
"name" : "iVisitLimitUC",
"type" : "string"
}, {
"name" : "newTableNumber",
"type" : "string"
}, {
"name" : "oVisitLimitER",
"type" : "string"
}, {
"name" : "oVisitLimitPcp",
"type" : "string"
}, {
"name" : "oVisitLimitSpec",
"type" : "string"
}, {
"name" : "oVisitLimitUC",
"type" : "string"
}, {
"name" : "pcpInd",
"type" : "string"
}, {
"name" : "prod",
"type" : "string"
}, {
"name" : "tableNumber",
"type" : "string"
}, {
"name" : "tVisitLimitPCP",
"type" : "string"
}, {
"name" : "tVisitLimitPcpEr",
"type" : "string"
}, {
"name" : "tVisitLimitPcpSpec",
"type" : "string"
}, {
"name" : "tVisitLimitPcpUC",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readCTISelectionScreenRecords",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readCTISelectionScreenRecords",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "a",
"type" : "string"
}, {
"name" : "ageFR",
"type" : "string"
}, {
"name" : "ageTo",
"type" : "string"
}, {
"name" : "C",
"type" : "string"
}, {
"name" : "CC",
"type" : "string"
}, {
"name" : "L",
"type" : "string"
}, {
"name" : "md",
"type" : "string"
}, {
"name" : "md1",
"type" : "string"
}, {
"name" : "net",
"type" : "string"
}, {
"name" : "nonPcpCopay",
"type" : "string"
}, {
"name" : "oop",
"type" : "string"
}, {
"name" : "org",
"type" : "string"
}, {
"name" : "pcpCopay",
"type" : "string"
}, {
"name" : "pr",
"type" : "string"
}, {
"name" : "procFrom",
"type" : "string"
}, {
"name" : "procTo",
"type" : "string"
}, {
"name" : "ps",
"type" : "string"
}, {
"name" : "rel",
"type" : "string"
}, {
"name" : "scs",
"type" : "string"
}, {
"name" : "srvcCode",
"type" : "string"
}, {
"name" : "t",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "readMMI_11",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/readMMI_11",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "coreDualOop",
"type" : "string"
}, {
"name" : "coreOopNcap",
"type" : "string"
}, {
"name" : "coreSal",
"type" : "string"
}, {
"name" : "coreSaleNbr",
"type" : "string"
}, {
"name" : "coreSalMult",
"type" : "string"
}, {
"name" : "coreSalType",
"type" : "string"
}, {
"name" : "coreSalType2",
"type" : "string"
}, {
"name" : "ee1CoreDual",
"type" : "string"
}, {
"name" : "ee1CoreInn",
"type" : "string"
}, {
"name" : "eeChCoreDual",
"type" : "string"
}, {
"name" : "eeChCoreInn",
"type" : "string"
}, {
"name" : "eeSpCoreDual",
"type" : "string"
}, {
"name" : "eeSpCoreInn",
"type" : "string"
}, {
"name" : "famCoreDualOOP",
"type" : "string"
}, {
"name" : "famCoreInnOop",
"type" : "string"
}, {
"name" : "famCoreT1",
"type" : "string"
}, {
"name" : "famMaxCopayDual",
"type" : "string"
}, {
"name" : "famMaxCopayInn",
"type" : "string"
}, {
"name" : "famMaxCopayT1",
"type" : "string"
}, {
"name" : "indCoreInnOop",
"type" : "string"
}, {
"name" : "indCoreOOPCode",
"type" : "string"
}, {
"name" : "indCoreOOPCodePd",
"type" : "string"
}, {
"name" : "indCoreT1",
"type" : "string"
}, {
"name" : "indMaxCopayCo",
"type" : "string"
}, {
"name" : "indMaxCopayDual",
"type" : "string"
}, {
"name" : "indMaxCopayInn",
"type" : "string"
}, {
"name" : "indMaxCopayT1",
"type" : "string"
}, {
"name" : "newPolicyNumber",
"type" : "string"
}, {
"name" : "nonEmbCoreOOP",
"type" : "string"
}, {
"name" : "nonEmbMaxCopay",
"type" : "string"
}, {
"name" : "planVari",
"type" : "string"
}, {
"name" : "xapplyCoreOopInd",
"type" : "string"
}, {
"name" : "xapplyMaxCopayInd2",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "ModelDataException", "ModelDefException", "UserException", "OperationUndefinedException", "JsonProcessingException", "ResourceUnavailableException", "ResourceUnknownException" ]
}
}, {
"name" : "rsResourceCreate",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/rsResourceCreate",
"filters" : null,
"inputs" : null,
"result" : {
"description" : "Zero or more result records may be returned containing one or more columns.",
"columns" : [ {
"name" : "SessionId",
"type" : "string"
} ]
},
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "JsonProcessingException", "ResourceUnavailableException" ]
}
}, {
"name" : "rsResourceDestroy",
"path" : "http://localhost:9680/vhi-rs/model/facilitatedInstall/rsResourceDestroy",
"filters" : null,
"inputs" : null,
"result" : null,
"fault" : {
"description" : "One of the following exception messages may be returned if this procedure fails.",
"exceptions" : [ "JsonProcessingException", "ResourceUnavailableException" ]
}
} ]
}

Anyone know how to actually get the data from the model?

I reviewed the rest example application (which works), but they are using angular.js and I'm having a hard time translating that to simple jQuery.

Any help would be greatly appreciated.
0 Likes
juan_rodriguez Absent Member.
Absent Member.

Re: Verastream 7.7 Rest Service with Jquery getJSON Help

I'm trying to get back the data I would get if I called my procedure in the design tool (but in json format).

In my Jquery, I'm setting those variables to get sent to the server for the model variables that are required for the verastream procedure call.

$(document).ready(function(){
$.getJSON('http://localhost:9680/vhi-rs/model/facilitatedInstall/readBPI', {
modVars: {
userID: "myId", password: "fakepass",
Access_Code: "bbbb", Payloc: "210",
System: "i", TOPSRegion: "abcd", PolicyNumber: "123456",
PlanVariation: "7777", CTITable: "000010"

}
})


When I look at the example your company provides in the REST example website, you guys also send variables to the server needed by the model:

$http.post('proxy/model/CICSAcctsDemo/GetAccountDetail',
{ "filters": {"AcctNum": $scope.acctNum}, "envVars": {"Username": "admin", "Password": 12345}})
.success(function (data, status, headers, config) {
if(data.result == null){
$scope.results = data;
$scope.keys = data.fault;
}else{
$scope.results = data.result;
$scope.keys = data.result[0];
}
});


The only difference is that I want to use JQuery and not Angular.js as I am not familiar with this framework.

A working demo calling any model REST service with Jquery would be awesome. This way I could have a working prototype of how it is one and mimic it. Otherwise the verastream documentation has nothing on how to call the REST services other than the example provided which uses different technology.

Any help would be greatly appreciated.
0 Likes
darnelho Absent Member.
Absent Member.

Re: Verastream 7.7 Rest Service with Jquery getJSON Help

Juan.

Can you try this instead.

$(document).ready(function(){
$.getJSON('http://localhost:9680/vhi-rs/model/facilitatedInstall/readBPI', {
"envVars": {
userID: "myId", password: "fakepass"
},
{
"filters":{
Access_Code: "bbbb",
Payloc: "210",
System: "i", TOPSRegion: "abcd", PolicyNumber: "123456",
PlanVariation: "7777", CTITable: "000010"
}
}
})


Test and reply letting us know if you got the data you desired.

-Microfocus Customer Care.

juan_rodriguez;2431798 wrote:
I'm trying to get back the data I would get if I called my procedure in the design tool (but in json format).

In my Jquery, I'm setting those variables to get sent to the server for the model variables that are required for the verastream procedure call.

$(document).ready(function(){
$.getJSON('http://localhost:9680/vhi-rs/model/facilitatedInstall/readBPI', {
modVars: {
userID: "myId", password: "fakepass",
Access_Code: "bbbb", Payloc: "210",
System: "i", TOPSRegion: "abcd", PolicyNumber: "123456",
PlanVariation: "7777", CTITable: "000010"

}
})


When I look at the example your company provides in the REST example website, you guys also send variables to the server needed by the model:

$http.post('proxy/model/CICSAcctsDemo/GetAccountDetail',
{ "filters": {"AcctNum": $scope.acctNum}, "envVars": {"Username": "admin", "Password": 12345}})
.success(function (data, status, headers, config) {
if(data.result == null){
$scope.results = data;
$scope.keys = data.fault;
}else{
$scope.results = data.result;
$scope.keys = data.result[0];
}
});


The only difference is that I want to use JQuery and not Angular.js as I am not familiar with this framework.

A working demo calling any model REST service with Jquery would be awesome. This way I could have a working prototype of how it is one and mimic it. Otherwise the verastream documentation has nothing on how to call the REST services other than the example provided which uses different technology.

Any help would be greatly appreciated.
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.