Skip to main content
POST
/
context
/
entitymatching
JavaScript SDK
const result = await client.entityMatching.create({
 sources: [{externalId: 'asset1', name: 'asset1'}, {externalId: 'asset2', name: 'asset2'}],
 targets: [{externalId: 'ts1', name: 'ts1'}, {externalId: 'ts2', name: 'ts2'}],
 externalId: 'model123',
 name: 'model123',
});
{
  "id": 4503599627370496,
  "externalId": "my.known.id",
  "status": "Queued",
  "createdTime": 1730204346000,
  "startTime": 1730204346000,
  "statusTime": 1730204346000,
  "name": "simple_model_1",
  "description": "Simple model 1",
  "errorMessage": null,
  "featureType": "simple",
  "matchFields": [
    {
      "source": "name",
      "target": "name"
    },
    {
      "source": "name",
      "target": "someField"
    }
  ],
  "ignoreMissingFields": true,
  "classifier": "randomforest",
  "originalId": 111
}

Authorizations

Authorization
string
header
required

Access token issued by the CDF project's configured identity provider. Access token must be an OpenID Connect token, and the project must be configured to accept OpenID Connect tokens. Use a header key of 'Authorization' with a value of 'Bearer $accesstoken'. The token can be obtained through any flow supported by the identity provider.

Body

application/json
sources
object[]
required

List of custom source object to match from, for example, time series. String key -> value. Only string values are considered in the matching. Both id and externalId fields are optional, only mandatory if the item is to be referenced in trueMatches.

Maximum array length: 2000000
targets
object[]
required

List of custom target object to match to, for example, assets. String key -> value. Only string values are considered in the matching. Both id and externalId fields are optional, only mandatory if the item is to be referenced in trueMatches.

Required array length: 1 - 2000000 elements
trueMatches
object[]

A list of confirmed source/target matches, which will be used to train the model. If omitted, an unsupervised model is trained.

Required array length: 1 - 2000000 elements

A pair of source ID and target ID, that indicates a match between two entities in the source and target spaces. Internal and external IDs are supported.

Example:
{
"sourceId": 23,
"targetExternalId": "my.known.id"
}
externalId
string

The external ID provided by the client. Must be unique for the resource type.

Maximum string length: 255
Example:

"my.known.id"

name
string

User defined name.

Maximum string length: 256
Example:

"simple_model_1"

description
string

User defined description.

Maximum string length: 500
Example:

"Simple model 1"

featureType
enum<string>
default:simple

Each feature type defines one combination of features that will be created and used in the entity matcher model. All features are based on matching tokens. Tokens are defined at the top of the Entity matching section. The options are:

  • Simple: Calculates the cosine-distance similarity score for each of the pairs of fields defined in matchFields. This is the fastest option.
  • Insensitive: Similar to Simple, but ignores lowercase/uppercase differences.
  • Bigram: Similar to simple, but adds similarity score based on matching bigrams of the tokens.
  • FrequencyWeightedBigram: Similar to bigram, but give higher weights to less commonly occurring tokens.
  • BigramExtraTokenizers: Similar to bigram, but able to learn that leading zeros, spaces, and uppercase/lowercase differences should be ignored in matching.
  • BigramCombo: Calculates all of the above options, relying on the model to determine the appropriate features to use. Hence, this option is only appropriate if there are labeled data/trueMatches. This is the slowest option.
Available options:
simple,
insensitive,
bigram,
frequencyweightedbigram,
bigramextratokenizers,
bigramcombo
Example:

"simple"

matchFields
object[]

List of pairs of fields from the target and source items, used to calculate features. All source and target items should have all the source and target fields specified here.

Example:
[
{ "source": "name", "target": "name" },
{ "source": "name", "target": "someField" }
]
classifier
enum<string>
default:randomforest

The classifier used in the model. Only relevant if there are trueMatches/labeled data and a supervised model is fitted.

Available options:
randomforest,
decisiontree,
logisticregression,
augmentedlogisticregression,
augmentedrandomforest
Example:

"randomforest"

ignoreMissingFields
boolean
default:false

If True, replaces missing fields in sources or targets entities, for fields set in set in matchFields, with empty strings. Else, returns an error if there are missing data.

Example:

true

Response

Success

id
integer<int64>
required

A server-generated ID for the object.

Required range: 1 <= x <= 9007199254740991
externalId
string
required

The external ID provided by the client. Must be unique for the resource type.

Maximum string length: 255
Example:

"my.known.id"

status
enum<string>
required

The status of the job.

Available options:
Queued,
Running,
Completed,
Failed
createdTime
integer<int64>
required

The number of milliseconds since 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC), minus leap seconds.

Required range: x >= 0
Example:

1730204346000

startTime
integer<int64>
required

The number of milliseconds since 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC), minus leap seconds.

Required range: x >= 0
Example:

1730204346000

statusTime
integer<int64>
required

The number of milliseconds since 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC), minus leap seconds.

Required range: x >= 0
Example:

1730204346000

name
string
required

User defined name.

Maximum string length: 256
Example:

"simple_model_1"

description
string
required

User defined description.

Maximum string length: 500
Example:

"Simple model 1"

errorMessage
string

If the job failed, some more information about the error cause.

Example:

null

featureType
enum<string>
default:simple

Each feature type defines the combination of features that will be created and used in the entity matcher model.

Available options:
simple,
insensitive,
bigram,
frequencyweightedbigram,
bigramextratokenizers,
bigramcombo
Example:

"simple"

matchFields
object[]

List of pairs of fields from the target and source items, used to calculate features. All source and target items should have all the source and target fields specified here.

Example:
[
{ "source": "name", "target": "name" },
{ "source": "name", "target": "someField" }
]
ignoreMissingFields
boolean
default:false

If True, missing fields in sources or targets entities set in matchFields, are replaced with empty strings.

Example:

true

classifier
enum<string>
default:randomforest

Name of the classifier used in the model, "Unsupervised" if unsupervised model.

Available options:
randomforest,
decisiontree,
logisticregression,
augmentedlogisticregression,
augmentedrandomforest
Example:

"randomforest"

originalId
integer

The ID of original model, only relevant when the model is a retrained model.

Example:

111

Last modified on April 23, 2026