Customer Relationship Management Blogs by SAP
Stay up-to-date on the latest developments and product news about intelligent customer experience and CRM technologies through blog posts from SAP experts.
cancel
Showing results for 
Search instead for 
Did you mean: 
Former Member

Then let us start the test process step-by-step.


Notes: we will create a new Task by copy a already one. 

In this case, I will use Task(guid'FA163EEF-573D-1EE5-9686-8E98F573FCA3') as a create sample.


Step1. We use get method receive the details of Task(guid'FA163EEF-573D-1EE5-9686-8E98F573FCA3').

HTTP method: GET

URI:/sap/opu/odata/sap/CRM_ODATA/TaskCollection(guid'FA163EEF-573D-1EE5-9686-8E98F573FCA3')

Action: F8

Result: You will get a HTTP Respond, show all the details of Task(guid'FA163EEF-573D-1EE5-9686-8E98F573FCA3').

Step2. Click on [Use as Request], trans the HTTP Response to HTTP Request.






Step3. For creating a new Task, we need change the values in the request body as required.

(1)One action is required.

field <d:guid> need change to as below.   For <d:guid> is the key of a Task and it's format is '00000000-0000-0000-0000-000000000000', and can be generated auto when a Task is created.


<d:guid>00000000-0000-0000-0000-000000000000</d:guid>


(2) In this case I will change some other fields for the new Task, I will change discription.


Step4: Change the URI to URI:/sap/opu/odata/sap/CRM_ODATA/TaskCollection.

           For when create a new Task, we do not need a guid in URI.



Step5:

Set HTTP method: POST





Step6:

Click F8.

Result: If the HTTP Respond code is 201, then you create it successfully.

Result:

HTTP respond code: 201

New Task(guid'FA163EEF-573D-1ED5-968A-741ED0990906')  and with<d:description>Sara test for create demo</d:description> generated.


Step7:

Do double check in DB.



Step8:

Do double check in Webpage.


2 Comments