POST /api/v202403/import/record

This endpoint allows the import of a emission records import file. The file should be a base64-encoded delimited text file with a UTF8 character set.

ImportEmissionRecordsWithProfileV202403 Permissions: Records (Create)

Request Headers

Header Value Required Description
ECI-ApiKey string Yes Your API key. See Authentication.
Content-Type application/json Yes All requests must specify JSON content type, including the request body.

Request Body

RecordImportRequestV202403
Property Description Type
fileContent The base64 encoded file Required string
fileName FileName for the import file. Should include extension. The extension allows the importer to read the data in the proper format (csv, xlsx) Required string
importNote Optional note/comment. string
inlineProfile RecordImportProfileV202403
RecordImportProfileV202403 properties
Property Description Type
costColumnIndex The index of the column that holds the cost for a record. Required if no value is set for either the Use Or Direct/Offset column numbers Must be between 1 and 104 At least one of UseColumnIndex, CostColumnIndex, DirectOffsetColumnIndex must not be null integer (int32)
costUnitId The identifier for the cost unit to use. Required if CostColumnIndex is set Required when CostColumnIndex is set integer (int32)
createNewEntities Flag to indicate if new emission sources or suppliers should be created if they do not already exist Required boolean
dateFormat The format for the record start/end dates. It represents the regional convention for the order of day, month, and year. It is not a date format itself. Required One of ‘MM/dd/yyyy’, ‘dd/MM/yyyy’, ‘yyyy/MM/dd’ Case sensitive string
directOffsetColumnIndex The index of the column that holds direct emissions/emission offsets for a record. Required if no value is set for either the Use Or Cost column numbers Must be between 1 and 104 At least one of UseColumnIndex, CostColumnIndex, DirectOffsetColumnIndex must not be null integer (int32)
directOffsetUnitId The identifier for the direct emissions/emission offset unit to use. Required if DirectOffsetColumnIndex is set Required when DirectOffsetColumnIndex is set integer (int32)
emissionSourceCodeColumnIndex The index of the column that holds the emission source code Required Must be between 1 and 104 integer (int32)
emissionSourceNameColumnIndex The index of the column that holds the emission source name Must be between 1 and 104 Required when CreateNewEntities is set to True, case sensitive. Must be null when CreateNewEntities is set to False, case sensitive integer (int32)
emissionSourceTypeColumnIndex The index of the column that holds the emission source type Must be between 1 and 104 Required when CreateNewEntities is set to True, case sensitive. Must be null when CreateNewEntities is set to False, case sensitive integer (int32)
endDateColumnIndex The index of the column that holds the emission record end date Required Must be between 1 and 104 integer (int32)
notes Optional notes field Max length of 255 string
notesColumnIndex The index of the column that holds the notes for a record. This field is optional Must be between 1 and 104 integer (int32)
numberOfHeaderRows The number of header rows before the data begins Required Must be between 0 and 9 integer (int32)
startDateColumnIndex The index of the column that holds the emission record start date Required Must be between 1 and 104 integer (int32)
supplierColumnIndex The index of the column that holds the supplier name. This field is optional Must be between 1 and 104 integer (int32)
useColumnIndex The index of the column that holds the use for a record. Required if no value is set for either the Cost Or Direct/Offset column numbers Must be between 1 and 104 At least one of UseColumnIndex, CostColumnIndex, DirectOffsetColumnIndex must not be null integer (int32)
useUnitId The identifier for the use unit to use. Required if UseColumnIndex is set Required when UseColumnIndex is set integer (int32)
profileCode Name of the import profile Must be between 0 and 64 characters Only one of ProfileCode, InlineProfile can be set string
Example Request Body application/json
{  "fileContent": "string",  "fileName": "string",  "importNote": "string",  "inlineProfile": {    "costColumnIndex": 1,    "costUnitId": 1,    "createNewEntities": false,    "dateFormat": "string",    "directOffsetColumnIndex": 1,    "directOffsetUnitId": 1,    "emissionSourceCodeColumnIndex": 1,    "emissionSourceNameColumnIndex": 1,    "emissionSourceTypeColumnIndex": 1,    "endDateColumnIndex": 1,    "notes": "string",    "notesColumnIndex": 1,    "numberOfHeaderRows": 1,    "startDateColumnIndex": 1,    "supplierColumnIndex": 1,    "useColumnIndex": 1,    "useUnitId": 1
  },  "profileCode": "string"
}

Responses

200 OK The request succeeded and the response body contains the requested data.

Response Body Parameters

GuidResponse
Property Description Type
taskGUId A guid that identifies the current task string (uuid)
Example Response application/json
{  "taskGUId": "string"
}