Skip to main content

Bluefactory Restore - Request Configuration

Restore Request Reference

KeyDescription
objectsobjects we want to migrate
object.nameApi name of the root object
object.soqlFilterYou can filter root records using where clause
parents[optional]: Array of parent objects
children[optional]: Array of child objects
operation[optional]: Operation that you want to perform with the current SObject.
Available values are:
"Insert" - creates new records on the target org even old versions of these records already exist.
"Update" - only updates existing records. The operation overrides all record fields.
"Upsert" - Inserts new and updates old records, overriding all values.
If the operation is not specified the "insert" operation will be applied.
masterData[optional]: Objects used for data mapping but not migrated
keyFields[optional]: Maps input records to records in destination org which match specified key field value.
fieldsToExclude[optional]: Array of field names that should not be migrated.

Sample JSON Mappings

Example 1: Insert Opportunities that satisfies the 'soqlFilter' and their related Accounts
{
"objects": {
"name": "Opportunity",
"soqlFilter": "ORDER BY CreatedDate LIMIT 10",
"parents": [
{
"name": "Account",
"relationshipName": "AccountId",
}
],
},
}
Example 2: Insert Opportunities that satisfies the 'soqlFilter' their related Accounts and Contacts related to Account
{
"objects":{
"name":"Opportunity",
"soqlFilter":"ORDER BY CreatedDate LIMIT 10",
"parents":[
{
"name":"Account",
"relationshipName":"AccountId",
"children":[
{
"name":"Contact",
"relationshipName":"AccountId"
}
]
}
]
}
}
Example 3: Advanced example:
{
"objects":{
"name":"Opportunity",
"soqlFilter":"ORDER BY CreatedDate LIMIT 10",
"parents":[
{
"name":"Account",
"relationshipName":"AccountId",
"children":[
{
"name":"Contact",
"relationshipName":"AccountId"
}
],
"parents":[
{
"name":"Country__c",
"relationshipName":"AccountCountry__c"
}
]
}
],
"children":[
{
"name":"ObjectA__c",
"relationshipName":"Opportunity__c",
"parents":[
{
"name":"ObjectB__c",
"relationshipName":"ObjectA_Lookup__c"
}
],
"children":[
{
"name":"ObjectC__c",
"relationshipName":"ObjectC_Lookup__c"
}
]
}
]
},
"operation":"upsert",
"masterData":{
"Country__c":"Name"
},
"keyFields":{
"ObjectB__c":"Code__c,Name"
},
"fieldsToExclude":{
"Opportunity":[
"Field1__c",
"Field2__c"
],
"ObjectA__c":[
"Field3__c",
"Field4__c"
]
}
}