Salesforce Integration: Custom Objects and their Fields

by Skilljar Customer Training
Follow

This article contains a detailed list of all the custom Salesforce objects, and their fields. This documentation is designed to share with your Salesforce developers or anyone needing detailed information about Skilljar's Salesforce integration. 

Please note that not all text fields in Skilljar currently allow for that many characters, but that moving forward all text fields in Salesforce will allow for the max 255 characters.

Your SFDC admin can also install the Salesforce Example Reports Managed Package which will create some example reports and custom report types to begin interacting with Skilljar data.

 

Table of Contents:

 

Common Fields

There are a few fields that are common to many of the Skilljar objects and have special usage.

skilljar__Obfuscated_Id__c

This field represents the Skilljar ID of the object instance within the Skilljar platform.  This ID is consistent across our API, the SFDC App and our BI connector.

skilljar__Contact__c

The Contact field is an optional lookup from our Skilljar objects to a SFDC Contact.  If you’ve checked the “Link contacts” checkbox in Skilljar, then when one of these objects is updated, we look for a corresponding Contact object with the same email address as the associated skilljar__Student__c object.  If we find a Contact (or more than one) - we link to the most recently created Contact object.  If we do not find a Contact with the same email address, we create a new Contact record and link to that.

Most times, these newly created “orphaned contacts” will need to be associated to an Account.  Skilljar does not attempt to do this - as it often requires human intervention, or business-specific logic to map accordingly.  Most customers of ours write a custom Apex Trigger, or have created a process to manually assign orphaned contacts on a periodic basis.

skilljar__Lead__c

This field is deprecated and should not be used.  It will be removed in future versions of the SFDC application.  If you want to link Leads to Skilljar objects, we recommend that you extend the Skilljar object and add your own custom field for this purpose.

Custom Objects

Here is a list of all custom objects in the Skilljar Salesforce app:

Student

Signup Field

Course (Published Course)

Enrollment

Course Progress (and certifications) 

Offer

Purchase

Promo Code Pool

Promo Code

Access Code Pool

Access Code

Domain Membership

Group

Group Membership

Vilt Session Event

Vilt Session

Vilt Session Registration

Tag

Published Course Tag

Course

Lesson

Lesson Progress 

Course Series

Course Series Published Course

Student

"skilljar__Student__c": {

"skilljar__Contact__c": {

"length": 18, "type": "reference", "label": "Contact" },

"skilljar__Email__c": {

"length": 80, "required": true, "type": "email", "label": "Email" },

"skilljar__First_Name__c": {

"length": 255, "type": "string", "label": "First Name" },

"skilljar__Last_Name__c": {

"length": 255, "type": "string", "label": "Last Name" },

"skilljar__Lead__c": {

"length": 18, "type": "reference", "label": "Lead" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string"

}

}

Signup Field

"skilljar__Signup_Field__c": {

"skilljar__Student__c": {

"length": 18, "required": true, "type": "reference", "label": "Student" },

"skilljar__Contact__c": {

"length": 18, "type": "reference", "label": "Contact" },

"skilljar__Domain_Name__c": {

"length": 255, "required": true, "type": "string",

"label": "Domain Name" },

"skilljar__Label__c": {

"length": 255, "required": true, "type": "string", "label": "Label" },

"skilljar__Lead__c": {

"length": 18, "type": "reference", "label": "Lead" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Value__c": {

"length": 255, "type": "string", "label": "Value" }

}

Course (Published Course)

"skilljar__Published_Course__c": {

"skilljar__Course_Id__c": {

"length": 255, "type": "string", "label": "Course Id" },

"skilljar__Course_Title__c": {

"length": 255, "required": true, "type": "string",

"label": "Course Title" },

"skilljar__Course_URL__c": {

"length": 255, "required": true, "type": "url", "label": "Course URL" },

"skilljar__Domain__c": {

"length": 255, "required": true, "type": "string", "label": "Domain" },

"skilljar__Lesson_Count__c": {

"length": 0, "required": true, "type": "double", "label": "Lesson Count" },

"skilljar__Live__c": {

"length": 0, "required": true, "type": "boolean", "label": "Live" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" }

}

Enrollment

"skilljar__Enrollment__c": {

"skilljar__Published_Course__c": {

"length": 18, "required": true, "type": "reference",

"label": "Published Course" },

"skilljar__Student__c": {

"length": 18, "required": true, "type": "reference", "label": "Student" },

"skilljar__Active__c": {

"length": 0, "required": true, "type": "boolean", "label": "Active" },

"skilljar__Contact__c": {

"length": 18, "type": "reference", "label": "Contact" },

"skilljar__Enrolled_At__c": {

"length": 0, "required": true, "type": "datetime",

"label": "Enrolled At" },

"skilljar__Expires_At__c": {

"length": 0, "type": "datetime", "label": "Expires At" },

"skilljar__Lead__c": {

"length": 18, "type": "reference", "label": "Lead" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Promocode__c": {

"length": 255, "type": "string", "label": "Promocode" },

"skilljar__Purchase_Currency_Code__c": {

"length": 255, "type": "string", "label": "Purchase Currency Code" },

"skilljar__Purchase_Price__c": {

"length": 0, "type": "currency", "label": "Purchase Price" },

"skilljar__Purchase__c": {

"length": 18, "type": "reference", "label": "Purchase" }

}

Course Progress

"skilljar__Course_Progress__c": {

"skilljar__Published_Course__c": {

"length": 18, "required": true, "type": "reference",

"label": "Published Course" },

"skilljar__Student__c": {

"length": 18, "required": true, "type": "reference", "label": "Student" },

"skilljar__Certificate_Code__c": {

"length": 255, "type": "string", "label": "Certificate Code" },

"skilljar__Certificate_Validation_Url__c": {

"length": 255, "type": "url", "label": "Certificate Validation Url" },

"skilljar__Completed_At__c": {

"length": 0, "type": "datetime", "label": "Completed At" },

"skilljar__Completed_Lesson_Count__c": {

"length": 0, "type": "double", "label": "Completed Lesson Count" },

"skilljar__Contact__c": {

"length": 18, "type": "reference", "label": "Contact" },

"skilljar__Credit_Unit_Plural__c": {

"length": 255, "type": "string", "label": "Credit Unit Plural" },

"skilljar__Credits_Earned__c": {

"length": 255, "type": "string", "label": "Credits Earned" },

"skilljar__Enrolled_At__c": {

"length": 0, "type": "datetime", "label": "Enrolled At" },

"skilljar__Latest_Activity__c": {

"length": 0, "type": "datetime", "label": "Latest Activity" },

"skilljar__Lead__c": { 

"length": 18, "type": "reference", "label": "Lead" },

"skilljar__Lesson_Count__c": {

"length": 0, "type": "double", "label": "Lesson Count" },

"skilljar__Max_Score__c": {

"length": 0, "type": "double", "label": "Max Score" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Score__c": {

"length": 0, "type": "double", "label": "Score" },

"skilljar__Success_Status__c": {

"length": 255, "type": "picklist", "label": "Success Status" }

}

Offer

"skilljar__Offer__c": {

"skilljar__Currency_Code__c": {

"length": 255, "required": true, "type": "string",

"label": "Currency Code" },

"skilljar__Description__c": {

"length": 255, "required": true, "type": "string",

"label": "Description" },

"skilljar__Domain_Name__c": {

"length": 255, "type": "string", "label": "Domain Name" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Price__c": {

"length": 0, "required": true, "type": "currency", "label": "Price" },

"skilljar__Published_Course__c": {

"length": 18, "type": "reference", "label": "Published Course" },

"skilljar__Sku__c": {

"length": 255, "type": "string", "label": "Sku" },

"skilljar__Type__c": {

"length": 255, "type": "picklist", "label": "Type" }

}

Purchase

"skilljar__Purchase__c": {

"skilljar__Student__c": {

"length": 18, "required": true, "type": "reference", "label": "Student" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Offer_Currency_Code__c": {

"length": 255, "required": true, "type": "string",

"label": "Offer Currency Code" },

"skilljar__Offer_Price__c": {

"length": 0, "required": true, "type": "currency",

"label": "Offer Price" },

"skilljar__Offer_Sku__c": {

"length": 255, "type": "string", "label": "Offer Sku" },

"skilljar__Offer__c": {

"length": 18, "type": "reference", "label": "Offer" },

"skilljar__Order_Id__c": {

"Length": 255, "type": "string", "label": "Order Id" },

"skilljar__Payment_Processor_Order_Id__c": {

"length": 255, "type": "string", "label": "Payment Processor Order Id" },

"skilljar__Payment_Processor_Purchase_Data__c": {

"length": 32768, "type": "textarea",

"label": "Payment Processor Purchase Data" },

"skilljar__Payment_Processor__c": {

"length": 255, "type": "picklist", "label": "Payment Processor" },

"skilljar__Promo_Code_Price__c": {

"length": 0, "type": "currency", "label": "Promo Code Price" },

"skilljar__Promo_Code_Quantity__c": {

"length": 0, "type": "double", "label": "Promo Code Quantity" },

"skilljar__Promo_Code__c": {

"length": 18, "type": "reference", "label": "Promo Code" },

"skilljar__Purchased_At__c": {

"length": 0, "required": true, "type": "datetime",

"label": "Purchased At" },

"skilljar__Quantity__c": {

"length": 0, "required": true, "type": "double", "label": "Quantity" },

"skilljar__Refunded_At__c": {

"length": 0, "type": "datetime", "label": "Refunded At" },

"skilljar__State__c": {

"length": 255, "type": "picklist", "label": "State" },

"skilljar__Tax_Price__c": {

"length": 0, "type": "currency", "label": "Tax Price" }

}

Promo Code Pool

"skilljar__Promo_Code_Pool__c": {

"skilljar__Active__c": {

"length": 0, "required": true, "type": "boolean", "label": "Active" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Purchase__c": {

"length": 18, "type": "reference", "label": "Purchase" }

}

Promo Code

"skilljar__Promo_Code__c": {

"skilljar__Promo_Code_Pool__c": {

"length": 18, "required": true, "type": "reference",

"label": "Promo Code Pool" },

"skilljar__Active__c": {

"length": 0, "required": true, "type": "boolean", "label": "Active" },

"skilljar__Code__c": {

"length": 255, "required": true, "type": "string", "label": "Code" },

"skilljar__Max_Uses__c": {

"length": 0, "required": true, "type": "double", "label": "Max Uses" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Use_Count__c": {

"length": 0, "required": true, "type": "double", "label": "Use Count" }

}

Access Code Pool

"skilljar__Access_Code_Pool__c": {

"skilljar__Active__c": {

"length": 0, "required": true, "type": "boolean", "label": "Active" },

"skilljar__Domain_Name__c": {

"length": 255, "type": "string", "label": "Domain Name" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Purchase__c": {

"length": 18, "type": "reference", "label": "Purchase" }

}

Access Code

"skilljar__Access_Code__c": {

"skilljar__Access_Code_Pool__c": {

"length": 18, "required": true, "type": "reference",

"label": "Access Code Pool" },

"skilljar__Active__c": {

"length": 0, "required": true, "type": "boolean", "label": "Active" },

"skilljar__Code__c": {

"length": 255, "required": true, "type": "string", "label": "Code" },

"skilljar__Max_Uses__c": {

"length": 0, "required": true, "type": "double", "label": "Max Uses" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" },

"skilljar__Use_Count__c": {

"length": 0, "required": true, "type": "double", "label": "Use Count" }

}

Domain Membership

"skilljar__Domain_Membership__c": {

"skilljar__Student__c": {

"length": 18, "required": true, "type": "reference", "label": "Student" },

"skilljar__Access_Code__c": {

"length": 18, "type": "reference", "label": "Access Code" },

"skilljar__Active__c": {

"length": 0, "required": true, "type": "boolean", "label": "Active" },

"skilljar__Domain_Name__c": {

"length": 255, "type": "string", "label": "Domain Name" },

"skilljar__Expires_At__c": {

"length": 0, "type": "datetime", "label": "Expires At" },

"skilljar__Obfuscated_Id__c": {

"required": true, "label": "Skilljar Id", "length": 255, "externalId": true,

"unique": true, "type": "string" }

}

Group

"skilljar__Group__c": {

"skilljar__Skilljar_Id__c": {

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Name__c": {

"label": "Name", "length": 255,     "type": "string"}

}

 

Group Membership

"skilljar__Group_Membership__c": {

"skilljar__Group__c": {

"label": "Group", "length": 18, "type": "reference"}, 

"skilljar__Skilljar_Id__c": {

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Student__c": { "label": "Student", "length": 18,  "type": "reference"}

}

 

Vilt Session Event

"skilljar__Vilt_Session_Event__c": {

"skilljar__Timezone__c": {  

"label": "Timezone", "length": 255, "type": "string"}, 

"skilljar__Ends_At__c": {  

"label": "Ends At", "length": 0, "type": "datetime"}, 

"skilljar__Skilljar_Id__c": {  

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Starts_At__c": {

"label": "Starts At", "length": 0, "type": "datetime"}, 

"skilljar__Vilt_Session__c": {

"label": "Vilt Session", "length": 18, "type": "reference"}, 

"skilljar__Location__c": {

"label": "Location", "length": 255, "type": "string"}

}

Vilt Session

"skilljar__Vilt_Session__c": {

"skilljar__Lesson__c": {

"label": "Lesson", "length": 18, "type": "reference"}, 

"skilljar__Skilljar_Id__c": {

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Display_Name__c": {

"label": "Display Name", "length": 255, "type": "string"}, "skilljar__Instructor_Name__c": {

"label": "Instructor Name", "length": 255, "type": "string"}

}

 

Vilt Session Registration

"skilljar__Vilt_Session_Registration__c": {

"skilljar__Attended__c": {

"label": "Attended", "length": 0, "type": "boolean"}, 

"skilljar__Skilljar_Id__c": {

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Student__c": {

"label": "Student", "length": 18, "type": "reference"}, 

"skilljar__Vilt_Session__c": {

"label": "Vilt Session", "length": 18, "type": "reference"}, "skilljar__Lesson_Progress__c": {

"label": "Lesson Progress", "length": 18, "type": "reference"}

}

 

Tag

"skilljar__Tag__c": {

"skilljar__Skilljar_Id__c": {  

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Name__c": {  

"label": "Name", "length": 255,     "type": "string"},

"skilljar__Slug__c": {  

"label": "Slug", "length": 255,"type": "string"}

}

 

Published Course Tag

"skilljar__Published_Course_Tag__c": {

"skilljar__Skilljar_Id__c": {  

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Tag__c": {  

"label": "Tag", "length": 18, "type": "reference"}, "skilljar__Published_Course__c": {

"label": "Published Course", "length": 18, "type": "reference"}

}

 

Course

"skilljar__Course__c": {

"skilljar__Skilljar_Id__c": {

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Short_Description__c": {  

"label": "Short Description", "length": 255, "type": "textarea"}, 

"skilljar__Title__c": { "label": "Title", "length": 255, "type": "string"}

}

 

Lesson

"skilljar__Lesson__c": {

"skilljar__Skilljar_Id__c": {  

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Course__c": {

"label": "Course", "length": 18,"type": "reference"},

"skilljar__Title__c": {  

"label": "Title", "length": 255, "type": "string"}

}

 

Lesson Progress

"skilljar__Lesson_Progress__c": {

"skilljar__Last_Viewed_At__c": {  

"label": "Last Viewed At", "length": 0, "type": "datetime"}, 

"skilljar__View_Count__c": {  

"label": "View Count", "length": 0,     "type": "double"}, 

"skilljar__Success_Status__c": {  

"label": "Success Status", "length": 4099, "type": "multipicklist"}, "skilljar__Course_Progress__c": {  

"label": "Course Progress", "length": 18, "type": "reference"}, 

"skilljar__Skilljar_Id__c": {  

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Student__c": {  

"label": "Student", "length": 18, "type": "reference"}, "skilljar__Max_Score__c": {  

"label": "Max Score", "length": 0, "type": "double"},

"skilljar__Score__c": {  

"label": "Score", "length": 0, "type": "double"},

"skilljar__Lesson__c": {  

"label": "Lesson", "length": 18, "type": "reference"}, "skilljar__Completed_At__c": {  

"label": "Completed At", "length": 0,   "type": "datetime"}

}

 

Course Series

"skilljar__Course_Series__c": {

"skilljar__Course_Series_Title__c": {

"label": "Course Series Title", "length": 255, "type": "string"},

"skilljar__Domain_Name__c": {

"length": 255, "type": "string", "label": "Domain Name" },

"skilljar__Skilljar_Id__c": {

"label": "Skilljar Id", "length": 255, "externalId": True, "unique": True, "type": "string"},

"skilljar__Slug__c": {  

"label": "Slug", "length": 255,"type": "string"}

},

 

Course Series Published Course

"skilljar__Course_Series_Published_Course__c": {

"skilljar__Course_Series__c": {

"label": "Group", "required": true, "length": 18, "type": "reference"},

"skilljar__Published_Course__c": { 

"length": 18, "required": true, "type": "reference", "label": "Published Course" },

"skilljar__Skilljar_Id__c": {

"label": "Skilljar Id", "length": 255, "externalId": true, "unique": true, "type": "string"}

},

 

Appendix A: Example Payment Processor Purchase Data

Each payment gateway that Skilljar integrates with returns a different set of fields related to the transaction.  Skilljar places the payment processor data in a JSON dictionary and includes this data in the skilljar__Payment_Processor_Purchase_Data__c field of the skilljar__Purchase__c object.

 

Accessing Payment Processor Data via Apex Code (Example)

In Salesforce Apex code, JSON can be easily parsed by the JSONParser class.  The following example shows how to retrieve a value (in this case, the transaction_id) from th the skilljar__Payment_Processor_Purchase_Data__c field:

 

skilljar__Purchase__c purchase = [SELECT skilljar__Payment_Processor_Purchase_Data__c FROM skilljar__Purchase__c WHERE skilljar__Obfuscated_Id__c = 'abcd12345'];

 

String responseData = purchase.skilljar__Payment_Processor_Purchase_Data__c;

 

Map<String, Object> data = (Map<String, Object>)JSON.deserializeUntyped(responseData);

 

String transactionId = (String)data.get('transaction_id');

 

Apex Trigger to add Transaction ID to Purchase (Example)

You may extend the Skilljar custom objects with your own fields.  Building on the previous section, if you added a custom “Transaction ID” field (Transaction_Id__c) to the skilljar__Purchase__c object, you could write an Apex Trigger to automatically set the new field value after a skilljar__Purchase__c was updated:

 

trigger addTransactionId on skilljar__Purchase__c (after insert, after update) {

   List<skilljar__Purchase__c> p = [SELECT Id, Transaction_Id__c, skilljar__Payment_Processor_Purchase_Data__c FROM skilljar__Purchase__c WHERE Id IN: Trigger.newMap.keySet()];

   for (skilljar__Purchase__c purchase: p) {

      if (purchase.Transaction_Id__c == Null && purchase.skilljar__Payment_Processor_Purchase_Data__c != Null){

           String responseData = purchase.skilljar__Payment_Processor_Purchase_Data__c;

           Map<String, Object> data = (Map<String, Object>)JSON.deserializeUntyped(responseData);

           if (data.containsKey('transaction_id')) {

               String transactionId = (String)data.get('transaction_id');

               purchase.Transaction_Id__c = transactionId;

               update purchase;

           }

       }

 

   }

}

 

Appendix B: Skilljar Custom Object Schema

This can be created in your instance of SFDC by using the Schema Builder and by only selecting the Skilljar Custom Objects - This Static image was updated on 7/9/2021 - future changes may impact this schema

mceclip0.png

Powered by Zendesk