Integrations and APIs for Service

Get Involved. Join the Conversation.


  • David Wright
    REST API - analyticsReportResults return nested JSON format95.0
    Topic posted July 18, 2017 by David WrightBlue Ribbon: 750+ Points, tagged REST 
    REST API - analyticsReportResults return nested JSON format

    Does anyone know if it is possible to change the format / nesting of the JSON as returned by the analyticsReportResults function of the REST api?

    Ideally we want something like:




    If not possible using the Analytics report function would there be any other way to achieve it using the REST API?

    Thanks, David

  • Mike Waldron
    REST queryResults Resource/Endpoint Not WorkingAnswered155.0
    Topic posted July 25, 2016 by Mike WaldronGold Medal: 3,500+ Points, tagged REST 
    REST queryResults Resource/Endpoint Not Working

    I'm trying to run a ROQL tabular query with the REST queryResults resource/endpoint. According to the documentation, I should be able to do this, but...ain't workin', even when I copy-and-paste the example directly out of the documentation.

    One peculiarity I've noticed is if I hit
    ?query=select id,subject from incidents where id<=10;

    (query from the documentation) there's an extraneous space in between the last slash and the question mark...which may be an artifact of the line break. If I leave it, I get a 200 OK...but no results. If I take it out, I get a 400 Bad Request. Neither result is useful.

    I'm trying to do this on Feb '16. Is there a bug in this REST resource, is something missing from the documentation, or is some other thing going on? Anyone dealt with/resolved this before?





  • Nancy Strickland
    REST API introductory videos5.0
    Topic posted April 9, 2016 by Nancy StricklandGreen Ribbon: 100+ Points, tagged REST 
    REST API introductory videos

    For those who're new to the REST API in Service Cloud, links to short (2-5 minute) introductory videos and code examples are posted here:

    (Scroll down toward the bottom of the page.)

  • Janusz Jasinski
    OSC-CREST-00013 - Unrecognised resource25.0
    Topic posted July 17, 2019 by Janusz JasinskiBronze Crown: 15,000+ Points, tagged Connect PHP, REST 
    OSC-CREST-00013 - Unrecognised resource


    Please see code below - so I'm trying to upload Base64 data as an attachment to an incident.

    However I get this error:

        "type": "",
        "title": "Unrecognised resource",
        "status": 404,
        "detail": "Resource with id 705951 not found",
        "instance": "",
        "o:errorCode": "OSC-CREST-00013"

    This incident exists though - I can confirm this by going to the link the error says does not exist. This code sits in the model.

    Am I doing anything obviously wrong?

    Code Snippet:
  • Vijay Krishna
    Chat REST ServiceAnswered25.0
    Topic posted October 16, 2019 by Vijay KrishnaBlue Ribbon: 750+ Points, tagged REST 
    Chat REST Service
    Issue with establish session - Chat REST API


    I'm trying to invoke Chat REST services for a custom integration. But I am getting an error while calling establish session REST API. Please find the details below. .



     "sessionInformation": {
     "emailAddress" : "", 
     "firstName" : "Vijay",
     "lastName": "Krishna", 
     "question" : "Test Chat",
     "auxiliaryData" : {
    "BROWSER" : "Mobile Safari 11.0", 
    "OPERATING_SYSTEM" : "iPhone OS", 
    "USER_AGENT" : "Mozilla/5.0 (iPhone; CPU iPhone OS 11_4_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.0 Mobile/15E148 Safari/604.1"

    "type": "",
    "title": "An attempt to write a resource failed",
    "status": 400,
    "detail": "A problem setting a property was encountered: not an object; EstablishSession.SessionInformation",
    "instance": "",
    "o:errorCode": "OSC-CREST-00006"


     Please suggest if any parameter is missing.


    Vijay Krishna

  • Sristy Arya
    Unable to download File Attachment using CURL5.0
    Topic posted September 29, 2019 by Sristy AryaBronze Trophy: 5,000+ Points, tagged Connect PHP, REST 
    Unable to download File Attachment using CURL

    Hi Everyone,


    I am stuck in downloading a file attachment from portal using CURL. I am able to get the response but unable to download the attachment. Anyone knows about this or has done this before can help.


    PFA the code .



    Code Snippet:
  • Camilo Peña
    ¿How to? API RN OSvC connected to DialogFlow5.0
    Topic posted June 17, 2019 by Camilo Peña, tagged REST 
    ¿How to? API RN OSvC connected to DialogFlow
    Hi, I need to retrieve or create an incident with the fullfillment option in dialogflow, obtaining an answer from the API REST of OSvC

    The Main idea is to connect the RN API REST to DialogFlow, and with a fullfillment option, retrieve info of an incident or maybe create one. 

    If you could help me, would be great.



  • Sreedhar Loorthu
    How to use CURLFile() with File Attachment of...15.0
    Topic posted June 10, 2019 by Sreedhar Loorthu, tagged Connect PHP, Custom Process Models - CPMs, REST 
    How to use CURLFile() with File Attachment of Incident
    Fetch File Attachment from Incident and Pass it to CURLFile() function using PHP
    As part of Integration, I need to pass an image file to REST API. 
    It was recommended to use CURLFile('') function for assigning file.
    So, I need to get the file from a particular Incident's FileAttachment and assign it in JSON using PHP.
    Find the bleow sample code for CURLOPT_POSTFIELDS.
    array('file'=> new CURLFILE('imagefile.jpg'),
      'method' => 'method_name',
      'api_key' => 'XXXXXXXAPIKEYXXXXXXX',
      'body' => '{
    "type": "image", 
    "image" : {
    "caption" : "Image File"
    'from' => 'from_number',
    'format' => 'json')
    How to get the file from Incident and pass it to CURLFILE('') function?
  • Sathya Rajendran
    REST API: OSC-CREST-00008Answered65.0
    Topic posted May 6, 2019 by Sathya RajendranGold Medal: 3,500+ Points, tagged REST 

    Hello All,

    When create contact using rest api i am getting below error. And it throw error after refresh only in live it is working perfectly. Any idea why it is?

        "type": "",
        "title": "An internal error has occurred",
        "status": 500,
        "detail": "Cannot save/update: Contact(ID=0): \nDB API Error\n",
        "instance": "Unexpected internal problem: %s",
        "o:errorCode": "OSC-CREST-00008"

  • Andy Townshend
    Update IncidentQueue Name25.0
    Topic posted April 4, 2019 by Andy TownshendSilver Medal: 2,000+ Points, tagged Connect PHP, REST 
    Update IncidentQueue Name
    Is it possible to rename queues outside of the agent console?

    I am looking to create a tool that allows our agents to log into and perform various configuration changes. This is to avoid giving a profile blanket access to all of the configuration permissions, but still allowing them to perform certain actions.


    I am able to pull a list of all our Queue names by using a RNCPHP\ROQL::query on the IncidentQueue object. However, I do not see any documentation about updating/saving to this object. 

    I have also located the same records using a REST call to /services/rest/connect/v1.4/namedIDs/incidents/queue/, but this seems to only support GET and not PATCH.


    Is there a way to overwrite a queue name using these or other methods?



    Oracle Service Cloud 18B

Filter by Date

< < October 2019 > >
    1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31    

Filter by Type