EDM Import
Import on-premise EDMs to the Intelligent Risk Platform using the Import API
Overview
The Import API defines resources for importing data into the Intelligent Risk Platform.
The Import API faciliates the import of EDM data modules to the Intelligent Risk Platform by leveraging Amazon S3 storage buckets and Amazon SDK APIs.
Import API resources enable client applications to securely connect to Amazon S3 and access temporary storage buckets on Amazon S3 for uploading exposure data.
Step 1: Create database artifact
The Import API supports the uploading of EDM databases from on-premise SQL Server instances to the Intelligent Risk Platform in the BAK or MDF format. No other file formats or file extensions are supported.
- The database artifact name must have use the
.bak
or.mdf
file extension. - The database artifact name is limited to 80 characters, and can include only
0
-9
,A
-Z
,a
-z
, underscore (_
), hyphen (-
) and space. - Each database artifact must have a unique file name that is not used by any other uploaded database in the platform. Databases with non-unique file names will generate an error during upload.
If you need to import an RMS EDM or RDM database, note that certain restrictions do apply. Data Bridge enables you to import database artifacts representing EDMs and RDMs managed in RiskLink/RiskBrowser versions 13.0, 15.0, 16.0, 17.0, and 18.0. During import to Data Bridge, EDMs and RDMs are automatically updated to Microsoft SQL Server 2019.
Step 2 : Create import folder
The Create Import Folder resource enables you to create a temporary storage location (a storage bucket) on AWS S3. An import folder is a temporary storage location and a logical path on AWS S3 to upload the relevant for performing an import.
The resource takes two required body parameters: the folderType
parameter and a properties
object that defines the extension of the output file.
curl --request POST \
--url https://api-euw1.rms.com/platform/import/v1/folders \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '
{
"folderType": "edm",
"properties": {
"fileExtension": "bak"
}
}
The folderType
body parameter identifies the format of the data to be uploaded to the Intelligent Risk Platform. Depending on the value specified (one of CEDE
, EDM
, OED
, or MRI
), you may upload a set of flat files (for OED or MRI import) or a database artifact in BAK or MDF format (for CEDE or EDM import).
The properties
object specifies the fileExtension
of the data to be uploaded to the import folder and the fileTypes
array, which lists the names of the files to be uploaded.
If successful, the response returns a 201 Created
response and the credentials required to upload the files to the import folder.
Step 3: Upload files
In this step, we will use the credentials returned in Step 2, to upload data to an import folder on AWS S3.
The Import API does not provide a service for uploading the EDM to Amazon S3. For that, you can use Amazon AWS API. Amazon S3 APIs enable tenants to upload database artifacts (BAK or MDF files) to storage buckets on Amazon Simple Storage Service (Amazon S3). Once uploaded to Amazon S3, use File Storage API operations to initiate a workflow job for creating a cloud-based EDM using the uploaded exposure data.
Step 4: Import files
The Create Import Job resource enables you import the data that you have uploaded to the import folder on AWS S3 into the Intelligent Risk Platform.
curl --request POST \
--url https://api-euw1.rms.com/platform/import/v1/jobs \
--header 'accept: application/json' \
--header 'content-type: application/json'
--header 'X-Rms-Resource-Group-Id: 080c4d42-beeb-40d2-b10d-22a3f0d5b5b4' \
All request parameters are specified in the request body:
{
"importType": "edm",
"settings": {
"folderId": "5555",
"exposureName": "exportFile",
"serverId": 56
}
}
'
The importType
and settings
parameters are required.
- The
importType
parameter specifies the import job type. One ofCEDE
,EDM
,OED
, orMRI
. Depending on theimportType
specified, different properties are required depending on the specified. - The
resourceUri
parameter specifies where the import needs to be performed - The
settings
object specifies the properties needed to import data. If you are importing an EDM, thefolderId
andexposureName
are required. ThefolderId
identifies the ID numberof the import folder and theexposureName
identifies the name of the EDM into which the data is imported. The optionalserverId
identifies the ID number of a SQL Server instance.
If successful, returns a 201 Accepted
HTTP response and initiates an import job on the workflow engine. Use the Get import jobs resource to track the status of the job.
Step 5:Track Status
The Get job status operation enables you to track the status of the MRI import job you just ran. The job ID is specified in the endpoint path.
curl --location --request GET 'https://{host}/platform/import/v1/jobs/451289' \
--header 'Authorization: XXXXXXXXXXXX'
A successful response returns the Job
object, which provides detailed information about this import job including the submittedAt
, startedAt
, type
, status
.
When the job status is FINISHED
, EDM will have been imported into the platform.
Updated about 1 year ago