Use this resource to import code values, value mappings, and hierarchy relationships.
Import code values
Imports code values with optional custom headers into a code list.
Note: Validation checks are not performed when you import code values.
POST request
To import code values into a code list, submit a POST request with the following URI:
/rdm-service/external/v2/import
The request contains form-data with the following parameters:
file
Specify a CSV file that contains the code value attributes. The columns specified depend on your data model. The CSV must contain one or two header rows, followed by the data rows. If the occurrence of header row is one in the import CSV file, you must set the repeatHeaders field to false.
Note: You can provide a single header row in the CSV file because it no longer requires two header rows.
For example, you might have the following code values:
CountryName,CountryCode CountryName,CountryCode Afghanistan,AFG Aland Islands,ALA Albania,ALB Algeria,DZA American Samoa,ASM
Note: You can provide additional information about a code value. For example, you might want to assign a code value to the Approved status. In the status.key column for the code value, enter the key value for the system reference data value that you want to assign. For more information about your configured system reference data values, see Get system reference data values.
If an import file doesn't contain business IDs, Reference 360 automatically generates them based on the business ID configuration in a code list.
importSettings
Specify the file-specific configuration and container details.
The importSettings parameter includes the following attributes:
Field
Type
Description
headerLinePresent
Boolean
Indicates whether the header line is present. Value is true or false. Default is true.
nestedFieldSeparator
String
Separator used to separate a nested field. Value is SEMICOLON or DOT. Default is DOT.
headerLineNumber
String
Line number from which the header line starts. Default is 1.
delimiter
String
Delimiter used to separate values. Value must be COMMA, SEMICOLON, SPACE, or TAB.
textQualifier
String
Symbol used to indicate where a text begins and ends. Value must be DOUBLE_QUOTE, SINGLE_QUOTE, or NO_QUOTE.
codepage
String
Code page used for the import file. Value must be UTF8 or MS_WINDOWS.
dateFormat
String
Format used for dates. Use one of the following formats:
- DE. For dd.mm.yyyy format.
- ISO. For yyyy-mm-dd format.
- US. For mm/dd/yyyy format.
containerType
String
Type of asset that contains code values. Value must be codelist.
containerId
String
The ID of the code list to which you want to import code values.
Note: You can find the ID of assets in Reference 360 or use REST APIs to retrieve the IDs. For more information, see Asset IDs.
startingRow
String
Line number from which to start importing data. By default, all rows are imported.
repeatHeaders
Boolean
Optional. Indicates whether the file has two headers. Value is true or false. Default is true.
mappings
Object
Optional. Maps the column headers in the CSV file with the target attributes of code lists in the key-value format.
- You can map the user-defined column name to source field name if required.
- You can either choose to ignore the mapping or map all the columns in an import CSV file.
Note: The key represents the header in the CSV file, and the value represents the field names in Reference 360.
For example, if the business ID column in the input CSV is labeled as sequence, the following mapping represents the mapping for the business ID column:
"sequence" : "businessID"
If mappings aren't specified in the import settings, Reference 360 selects the businessID column by default.
approvalOptions
-
Includes details about the approval parameters.
priority
String
Optional. Defines the priority of the approval request. Value can be LOW, MEDIUM, HIGH, or CRITICAL.
dueDate
String
Use the following format: yyyy-MM-dd.
Comments
String
Comments that the requester adds to explain the changes.
POST response
The response contains the details of the import job.
The response contains the following attributes:
Field
Type
Description
jobId
String
ID of the job.
state
String
Status of the job. Values are CREATED, INPROGRESS, COMPLETED, SUSPENDED, FAILED, STOPPED, QUEUED or WARNING.
startTime
Number
Time, in milliseconds, when the job started.
numOfRecordsProcessed
Number
Number of records processed.
numOfRecordsFailed
Number
Number of records that failed to be imported.
numOfRecordsSucceeded
Number
Number of records successfully imported.
POST example
To import code values, you might use the following request:
POST https://use4-mdm.dm-us.informaticacloud.com/rdm-service/external/v2/import HTTP/1.1 Content-Type: multipart/form-data; boundary=6o2knFse3p53ty9dmcQvWAIx1zInP11uCfbm IDS-SESSION-ID: XXXXXXXXXXXXXXXXXXXXXX
To import value mappings into a crosswalk, submit a POST request with the following URI:
/rdm-service/external/v2/import
The request contains form-data with two parameters:
file
Specify a CSV file that contains the code value attributes. The columns specified depend on your data model. The CSV must contain one or two header rows, followed by the data rows. If the occurrence of header row is one in the import CSV file, you must set the repeatHeaders field to false.
Note: You can provide a single header row in the CSV file as it no longer requires two header rows.
For example, you might have the following code values:
key,from, to key,from, to AF_AFG,AF,AFG AL_ALA,AL,ALA ALB_ALB,ALB,ALB DZ_DZA,DZ,DZA AS_ASM,AS,ASM
importSettings
Specify the file-specific configuration and container details.
The importSettings includes the following attributes:
Field
Type
Description
delimiter
String
Delimiter used to separate values. Value must be COMMA, SEMICOLON, SPACE, or TAB.
textQualifier
String
Symbol used to indicate where a text begins and ends. Value must be DOUBLE_QUOTE, SINGLE_QUOTE, or NO_QUOTE.
codepage
String
Code page used for the import file. Value must be UTF8 or MS_WINDOWS.
dateFormat
String
Format used for dates. Use one of the following formats:
- DE. For dd.mm.yyyy format.
- ISO. For yyyy-mm-dd format.
- US. For mm/dd/yyyy format.
containerType
String
Type of asset that contains value mappings. Value must be crosswalk.
containerId
String
The ID of the crosswalk to which you want to import value mappings.
Note: You can find the ID of assets in Reference 360 or use REST APIs to retrieve the IDs. For more information, see Asset IDs.
startingRow
String
Line number from which to start importing data. By default, all rows are imported.
repeatHeaders
Boolean
Optional. Indicates whether the file has two headers. Value is true or false. Default is true.
mappings
Object
Optional. Maps the column headers in the CSV file with the target attributes of code lists in the key-value format.
- You can map the user-defined column name to source field name if required.
- You can either choose to ignore the mapping or map all the columns in an import CSV file.
Note: The key represents the header in the CSV file, and the value represents the field names in Reference 360.
approvalOptions
-
Includes details about the approval parameters.
priority
String
Optional. Defines the priority of the approval request. Value can be LOW, MEDIUM, HIGH, or CRITICAL.
dueDate
String
Use the following format: yyyy-MM-dd.
Comments
String
Comments that the requester adds to explain the changes.
POST response
The response contains the details of the import job.
The following table describes the attributes in the response:
Field
Type
Description
jobId
String
ID of the job.
state
String
Status of the job. Values are CREATED, INPROGRESS, COMPLETED, SUSPENDED, FAILED, STOPPED, QUEUED or WARNING.
startTime
Number
Time, in milliseconds, when the job started.
numOfRecordsProcessed
Number
Number of records processed.
numOfRecordsFailed
Number
Number of records that failed to be imported.
numOfRecordsSucceeded
Number
Number of records successfully imported.
POST example
To import value mappings into a crosswalk, you might use the following request:
POST https://use4-mdm.dm-us.informaticacloud.com/rdm-service/external/v2/import HTTP/1.1 Content-Type: multipart/form-data; boundary=6o2knFse3p53ty9dmcQvWAIx1zInP11uCfbm IDS-SESSION-ID: XXXXXXXXXXXXXXXXXXXXXX
Imports hierarchy relationships for code values and top-level code values into a hierarchy, with custom headers as optional settings.
POST request
To import hierarchy relationships, submit a POST request with the following URI:
/rdm-service/external/v2/import/hierarchy
The request contains form-data with two parameters:
file
Specify a CSV file that contains the hierarchy relationships. The CSV file contains one header row with two columns: Code and ParentCode. You can list the related code values below the header.
For example, you might have the following relationships in the CSV file:
Code,ParentCode C1,P1 C2,P2 C1,P3
If you import top-level code values, only use the Code column in the header row.
For example, you might have the following top-level code values:
Code P1 P2 P3
importSettings
Specify the file specific configuration and container details.
The importSettings includes the following attributes:
Field
Type
Description
delimiter
String
Delimiter used to separate values. Value must be COMMA, SEMICOLON, SPACE, or TAB.
textQualifier
String
Symbol used to indicate where a text begins and ends. Value must be DOUBLE_QUOTE, SINGLE_QUOTE, or NO_QUOTE.
codepage
String
Code page used for the import file. Value must be UTF8 or MS_WINDOWS.
hierarchyId
String
ID of the hierarchy to which you want to import relationships.
Note: You can find the ID of assets in Reference 360 or use REST APIs to retrieve the IDs. For more information, see Asset IDs.
parentCodeListId
String
ID of the parent code list.
Note: If you import top-level code values, you do not need to provide this attribute.
childCodeListId
String
ID of the child code list.
startingRow
String
Line number from which to start importing data. By default, all rows are imported.
repeatHeaders
Boolean
Optional. Indicates whether the file has two headers. Value is true or false. Default is true.
mappings
Object
Optional. Maps the column headers in the CSV file with the target attributes of code lists in the key-value format.
- You can map the user-defined column name to source field name if required.
- You can either choose to ignore the mapping or map all the columns in an import CSV file.
Note: The key represents the header in the CSV file, and the value represents the field names in Reference 360.
POST response
The response contains details of the import job.
The following table describes the attributes in the response:
Field
Type
Description
jobId
String
ID of the job.
state
String
Status of the job. Values are CREATED, INPROGRESS, COMPLETED, SUSPENDED, FAILED, STOPPED, QUEUED or WARNING.
startTime
Number
Time, in milliseconds, when the job started.
numOfRecordsProcessed
Number
Number of records processed.
numOfRecordsFailed
Number
Number of records that failed to be imported.
numOfRecordsSucceeded
Number
Number of records successfully imported.
POST example
To import hierarchy relationships into a hierarchy, you might use the following request:
POST https://use4-mdm.dm-us.informaticacloud.com/rdm-service/external/v2/import/hierarchy HTTP/1.1 Content-Type: multipart/form-data; boundary=6o2knFse3p53ty9dmcQvWAIx1zInP11uCfbm IDS-SESSION-ID: XXXXXXXXXXXXXXXXXXXXXX