SymetryML Documentation
Encoders

Bulk-create encoder key values

Bulk-insert raw key/value/count/sum rows into an Encoder — the lower-level counterpart to [Update encoder from an inline DataFrame](/docs/api-reference/encoders/encoders-encodername-learn-post)/ [Update encoder from a data source (async job)](/docs/api-reference/encoders/encoders-encodername-learnds-post), used to seed or migrate an encoder's internal counts directly rather than deriving them from a DataFrame/data source. Each row: - **`Key`**: the categorical attribute name. - **`Value`**: one of that attribute's observed values. - **`Count`**/**`Sum`**: accumulate against whatever the encoder already holds for that key/value pair — this endpoint *adds*, it does not replace (see [Overwrite encoder key values](/docs/api-reference/encoders/encoders-encodername-keyvals-key-setvalues-post) for a per-key overwrite). Send in chunks for large uploads; there's no single-request size limit enforced, but the reference client chunks at 8192 rows.

POST
/{user}/encoders/{encodername}/createKeyValues

Bulk-insert raw key/value/count/sum rows into an Encoder — the lower-level counterpart to Update encoder from an inline DataFrame/ Update encoder from a data source (async job), used to seed or migrate an encoder's internal counts directly rather than deriving them from a DataFrame/data source. Each row:

  • Key: the categorical attribute name.
  • Value: one of that attribute's observed values.
  • Count/Sum: accumulate against whatever the encoder already holds for that key/value pair — this endpoint adds, it does not replace (see Overwrite encoder key values for a per-key overwrite).

Send in chunks for large uploads; there's no single-request size limit enforced, but the reference client chunks at 8192 rows.

Authorization

SymetryMLAuth
AuthorizationBearer <token>

HMAC-SHA256 signature-based authentication: requests are signed with your secret key and sent with the Customer-ID, Sym-date, Authorization, Content-MD5 and sym-version headers. See SymetryML REST API Security for the signature algorithm and a complete example.

In: header

Path Parameters

user*string

User/Customer identifier

encodername*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

curl -X POST "https://example.com/c1/encoders/superenc0/createKeyValues" \  -H "Content-Type: application/json" \  -d '{    "attributeNames": [      "Key",      "Value",      "Type",      "Count",      "Sum"    ],    "data": [      [        "device_country",        "ca",        "s",        "123",        "45"      ],      [        "device_country",        "us",        "s",        "456",        "7"      ]    ]  }'
{  "statusCode": 200,  "statusString": "OK",  "values": {}}
{  "statusCode": 400,  "statusString": "Cannot Find Encoder[nosuchenc] for Customer[c1].",  "values": {}}