POST
/
partner
/
schema-definitions
/
{schemaIdOrName}
Update Schema
curl --request POST \
  --url https://api.embedreach.com/partner/schema-definitions/{schemaIdOrName} \
  --header 'Content-Type: application/json' \
  --data '{
  "description": "<string>",
  "schema": {},
  "fieldsToExpose": [
    {
      "name": "<string>",
      "description": "<string>",
      "jsonPath": "<string>",
      "exposure": [
        "segments"
      ]
    }
  ],
  "exposeNameJsonPath": "<string>",
  "external_id_field": "<string>",
  "externalIdField": "<string>",
  "category": "contacts_schema"
}'
{
  "success": true,
  "message": "<string>",
  "data": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "platform_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "name": "<string>",
    "plural_name": "<string>",
    "pluralName": "<string>",
    "description": "<string>",
    "category": "contacts_schema",
    "version_number": 123,
    "versionNumber": 123,
    "partner_db_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "partnerDbId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "partner_db_query": "<string>",
    "partnerDbQuery": "<string>",
    "reference_schemas": [
      "<string>"
    ],
    "referenceSchemas": [
      "<string>"
    ],
    "schema": {},
    "external_id_field": "<string>",
    "externalIdField": "<string>",
    "deactivated_at": "<string>",
    "deactivatedAt": "<string>",
    "created_at": "<string>",
    "createdAt": "<string>",
    "updated_at": "<string>",
    "updatedAt": "<string>",
    "fieldsToExpose": [
      {
        "name": "<string>",
        "description": "<string>",
        "jsonPath": "<string>",
        "exposure": [
          "segments"
        ]
      }
    ],
    "exposeNameJsonPath": "<string>"
  }
}

Path Parameters

schemaIdOrName
string
required

The ID or name of the schema definition to update

Body

application/json
description
string

The description of the schema

schema
object

The JSONSchema schema definition for the resource

fieldsToExpose
object[]

The fields to expose on the segment builder or merge fields.

exposeNameJsonPath
string

The JSON path to the field in the schema that will be used to expose the resource to the user. If not provided, the resource will not be exposed to the user.

external_id_field
string

[Deprecated] Please use externalIdField instead. The field in the schema that is used as the unique ID in the partner system.

externalIdField
string

The field in the schema that is used as the unique ID in the partner system.

category
enum<string>

The category of the schema. Cannot be changed if it is used in active schema mappings.

Available options:
contacts_schema,
transactions_schema,
custom_schema,
combined_schema,
locations_schema,
customer_fields

Response

Status 200 response

success
boolean
required
message
string
data
object