Oracle CRM On Demand REST API Developer's Guide > Using the Oracle CRM On Demand REST API > Updating Oracle CRM On Demand Resources >

Updating Oracle CRM On Demand Top-Level Resources


You can update Oracle CRM On Demand top-level resources by sending an HTTP PATCH request to the resource's URL.

The following details are for a request to update an Accounts resource on the Oracle CRM On Demand Server:

  • URL: OnDemand/user/Rest/latest/Accounts/1QA2-21SEFX
  • HTTP Method: PATCH
  • Content-Type: application/vnd.oracle.adf.resource+json
  • Request body:

{
  "Accounts": [
     {
       "AccountName": "test put",
       "Location": "Hometown2",
       "AccountType": "Customer",
       "PublicCompany": false,
       "Region": "East",
       "MarketShare": 30,
       "NumberEmployees": 10,
       "OptimizedCustomNumber0":99
     }
  ]
}

The following are the details for the response to a successful request:

  • HTTP Code: 200
  • Content-Type: application/vnd.oracle.adf.resource+json
  • Response body:

{
  "Accounts": [
    {
       "Region": "East",
       "PublicCompany": false,
       "OptimizedCustomNumber0": 99,
       "MarketShare": 30,
       "Location": "Hometown2",
       "AccountName": "test put",
       "NumberEmployees": 10,
       "AccountType": "Customer",
       "links": {
          "self": {
          "rel": "self",
          "href": "/OnDemand/user/Rest/latest/Accounts/1QA2-21SEFX"
          },
       "canonical": {
          "rel": "canonical",
          "href": "/OnDemand/user/Rest/latest/Accounts/1QA2-21SEFX"
          },
        "Opportunities": {
          "rel": "child",
          "href": "/OnDemand/user/Rest/latest/Accounts/1QA2-21SEFX/child/Opportunities"
         }
       }
     }
  ]
}

Oracle CRM On Demand REST API Developer's Guide, Release 32 Copyright © 2016, Oracle and/or its affiliates. All rights reserved. Legal Notices.