Photo by Lukáš Kováčik on Pexels.com

The method for geting this info is under the Engagement REST API here.

The call includes a parameter which is filtering by the Member Name as follows:

curl -X GET -k -H 'Authorization: Basic whatever' -i 'https://serverdomain/crmRestApi/resources/11.13.18.05/serviceRequests?q=LoyMemberName="menbernamehere"&onlyData=true'

Example:

curl -X GET -k -H 'Authorization: Basic am9ob........DM3Mzg=' -i 'https://xxxx-xxxx-xx-ext.oracledemos.com/crmRestApi/resources/11.13.18.05/serviceRequests?q=LoyMemberName="ad pepelu"&onlyData=true'

{
   "items" : [ {
     "SrId" : 300000183643204,
     "SrNumber" : "SR105156",
     "Title" : "bbbbb",
     "ProblemDescription" : null,
     "SeverityCdMeaning" : "High",
     "SeverityCd" : "ORA_SVC_SEV1",
     "AssigneeResourceId" : 300000129858698,
     ...
     "PrimaryContactPartyId" : 300000183643142,
     "PrimaryContactPartyUniqueName" : "ad pepelu",
     "PrimaryContactPartyName" : "ad pepelu",
     ...
     "ExtnsrMgmtFuseCreateLayout_InstallBase_1554923756871Expr" : "false"
   } ],
   "count" : 1,
   "hasMore" : false,
   "limit" : 25,
   "offset" : 0,
   ...
     "name" : "serviceRequests",
     "kind" : "collection"
   } ]

Following same API, here an example of how to update an existing SR:

curl -X PATCH -k -H 'Content-Type: application/vnd.oracle.adf.resourceitem+json' -H 'Authorization: Basic am9ob...3Mzg=' -i 'https://serverdomain/crmRestApi/resources/11.13.18.05/serviceRequests/SR105156' --data '{
"ProblemDescription" : "Me duele la cara de ser tan feo"}'
...
{
   "SrId" : 300000183643204,
   "SrNumber" : "SR105156",
   "Title" : "bbbbb",
   "ProblemDescription" : "Me duele la cara de ser tan feo",
   ...
   "links" : [ {
     "rel" : "self",
...
.com:443/crmRestApi/resources/11.13.18.05/serviceRequests/SR105156/child/resourceMembers",
     "name" : "resourceMembers",
     "kind" : "collection"
   } ]

Hope it helps! 🙂

Comments

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.