Technical Articles
How can we run END-END Performance Appraisal process using ODATA APIs in SAP SuccessFactors?
Here is another way to run Appraisal Process of an employee with ODATA APIs without login to SAP Success Factors, i am throwing light on this process, which will help you in Integration of performance module with ‘CHATBOT’ & integration of ‘Performance and Gola management’ with existing tools of clients.
We all know following are limitations currently in SAP Success Factors, however we can achieve this through APIs…In those some are mentioned below:
1. Importing Goal ratings
2. Importing Goal item Comments
3. Importing Competency ratings
4. Importing Competency item Comments
5. Importing Custom Element Values in Custom fields in PM Forms
Prerequisites to run the process:
1. User – with all permission of ‘ODATA APIs in SF Tenant.
2. Tool – To QUERY , UPSERT ODATA APIs ( Ex: Postman )
3. PMV12 Acceleration – PM Template
Postman Tool:
I am using Postman tool for query, ‘UPSERT’ operations in SF Tenant, it requires basic ‘Authorizations & Header’ to perform the task.
Basic Authorization:
Use any user form SF Tenant, who has ODATA APIs permissions and include this user in ‘Password Policy Settings’ as exception from expiry of password.
Headers:
Headers require below keys with values.
When we want query APIs then use ‘GET’ command option & for UPSERT use POST command option, as we are trying to UPSERT Data in to SAP Success Factors we are using POST command. Once you click on “POST” command then you can access ‘Body’ which helps you to Post Data.
- POST–> Body –>Raw
Route Map for the process:
- Adding Goal
- Adding activity, Align Activity to ‘Goal’, update feedback for Activity with Red flag Adding -Achievement
- Launch process
- Insert Goal rating & Goal Item comment
- Insert competency custom element value
- Send to next / previous step
- Sign/ Reject form
- Audit Trail for PM forms
Goal Management:
- Adding Goal & Edit Goal :
First query Goals using ‘Goal APIs’ for the Goal Plan that you want to UPSERT Goals.
- We can find ODATA APIs list from ODATA Data dictionary in SF tenant.
- Pick Goal APIs and GET data form APIs.
- Use the same Json format in Body – Raw in web Tool.
- Use UPSERT URL to Post data.
- Insert all Goal fields with Data as we required and Insert New Goal ID to Add New Goal, use Existing Goal ID to modify.
- Click on SEND button to post data into SF.
Steps to Insert goals are given below:
- In below example I Inserted
- Goal Name
- Metric
- Weight
- Achievement
- Start Date
- End Date
Screenshot in Postman Tool:
Output in SF Screen:
Continues Performance Management:
- Creation of an Activity in CPM and Link it with Goal:
- Follow the same way to pick activity ODATA APIs, query and use the Same JSON format to UPSERT Data in to CPM.
- If we want to link with Goal then we need to add Goal ID in Goal Details list.
- Activity Name, User ID, Activity status, Goal ID are required for this UPSERT Operation
- ODATA API : Activity
Screenshot in Postman Tool:
Output Screenshot in SF Tenant:
Activity linked with Goal:
2. Adding “updates” Using ODATA APIs:
- Follow same way to pick “Status Update “API & query using GET command and use the same JSON format to Upsert Data in to CPM.
- Comment, commenter, Flag and Activity ID is required to Upsert.
- ODATA API : Activity Feedback
Screenshot in Web Tool:
Output:Screenshot in SF Tenant:
Adding Achievement in CPM Using ODATA APIs:
- Follow same way to pick “Achievement” API & Query using GET command and Use the same JSON format to Upsert Data in to CPM.
- ParentTypeEnum, Achievement name, Achievement Date, subject user is required to Upsert.
- ODATA API : Achievement
Screenshot in Web Tool:
Output-Screenshot in SF Tenant:
Launching Form:
We can Launch PM forms using this below URL for an employee:
Required fields to create PM form for an employee:
- Host Name = APIs Url of DC
- Username
- Template ID
https://<hostname>/odata/v2/createPerformanceReviewForm?formSubjectId=’<username>‘&formTemplateId=<template_ID>L&sendEmail=false&enRouteCopy=false
Output-Screenshot:
Once status is SUCCESS then PM form will be in user INBOX for evaluation.
Inserting Goal ratings & Item Comments into Goals in PM Forms:
- Follow same way to Pick Performance form API & Query using GET command and Use the same JSON format to Upsert Data into forms.
- Content ID, section INDEX, Item ID, Subject User ID, Goal rating, Goal Comment are required to Upsert.
- In below example I Inserted rating as “4” and Item comments as “Employee Goal comment added using APIs”
- ODATA API: FormPMReviewcontenetDetails
Screenshot in Web Tool:
Output-Screenshot in SF Tenant:
Competency Section:
- Pick Competency Section API in Performance form and Query using GET Command in Web tool and Use the Same JSON format to Upsert Data in to forms.
- Content ID, Item ID, Section INDEX, Subject User ID, Element Key and Custom Comment are required to Upsert.
- In below example I Inserted comments as “Custom filed Values updated by ODATA APIS for Competency Section” against to Value field
- ODATA API: FormCompetency
Screenshot in Web Tool:
Output-Screenshot in SF Tenant:
The same way we can Insert Goal Section Comments , Competency ratings, Competency Item Comments , Competency Section Comments , Behaviour ratings and All type of Custom fields in PM Forms and overall ratings as well.
Send to NEXT/Previous Step:
We can send the PM forms from one step to another step as per route map process using the below APIs.
Required:
- Data ID
- ODATA APIS for Next Step: SendToNextStep
- ODATA APIS for Previous Step: sendToPreviousStep
Sign/Reject Step:
We can Sign or Reject the PM forms using the below APIs.
Required:
- Data ID
- ODATA APIS for Sign: SignForm
- ODATA APIS for Reject: RejectForm
Sign / Reject Screenshot:
Output-Screenshot in SF Tenant:
Audit Trails:
We can use this entity to track the form routing details as this entity contains the audit trail information about a Performance Management form.
Required:
Form Data ID
ODATA API: Form Header
Screenshot of Output:
If you liked this post, I’d be grateful if you help sharing this across SAP SuccessFactors Consultants.
Looking forward to your questions and feedback in the comments section!!!
Happy to help!! Happy Integrating 🙂
Regards,
Venkatkrishnah Togara,
Hi Venkat,
Quite elaborate. Great work. Specifically I like the api for launching forms. We can use it to build extensions in so many use cases.
Thanks and regards,
Soumyajit
Thank you 🙂
this is great work. is this done for some client or you have experimented by yourself yet. Also, can we do it for bulk users and run a schedule job?
i am just trying to explore on ODATA APIs..we can schedule Jobs to Upsert Data in to SuccessFactors.
Dear Venkat, Can I call you to discuss the above logic. Promise will make it quick. My number 9769995590. Whatsapp me if you can chat.
Dear Venkat,
Can you please explain to me how you found the itemID coming from FormCompetency? I have a difficult to find it and make a teste calling the right parameter to this item.
Thanks!
Hi Venkat,
Thanks for the detailed document. Can you share me how exactly we can get the exact API URL for specific Goal Plan like the one in the Integration guide?
"uri": "https://<API-Server>/odata/v2/Goal_18(8049L)",
"type": "SFOData.Goal_18"
Hi Venkat,
I have a question about the "Send to NEXT/Previous Step:" section in your post.
You've specified that the following is required:
ODATA APIS for Next Step: SendToNextStep
ODATA APIS for Previous Step: sendToPreviousStep
What part of RBP is that, is it Manage Documents>Route Document or something else?
I have found a few links about issues with this:
https://answers.sap.com/questions/548958/odata-api-sendtonext-step-function-fails.html
https://me.sap.com/support/article/0002557089
We are trying to route forms using an admin API account, similar to how a front end user performs the "Route Forms" option in instance.
Thanks,
James
Hi Venkat,
Thanks for the article, very interesting!
Just one additional question: do you know if it's possible to change form start date via API? I cant find a way to do it during the creation or after the creation of the form. Unfortunately this is very important to business that needs to change the start date to the past via API.
Thanks
Regards
Carla
Hi Venkat,
In this statement -
What is Item ID and how do i find it?
Please help, Thanks in Advance.