Creating an integration

Get in touch with your Contentsquare contact to provide the required information.

You will need to provide:

  • A data schema (in the form of a JSON object): see below
  • A name, logo and description of what the integration does and related use cases to be listed in the Contentsquare integrations catalog.
{
"fields": [
// the list of fields
{
"name": "FIELD_NAME_1", // max 50 bytes
"type": "STRING", // either "DATETIME", "INT", "FLOAT", "STRING" or "BOOL"
"optional": true, // either true or false to make this field optional or not
"label": "Field 1", // a business name that can be used in user interfaces
"description": "A first field" // a business description that can be displayed in documentation pages and user interfaces
},
{
"name": "FIELD_NAME_2",
"type": "INT",
"optional": false,
"label": "Field 2",
"description": "Another field"
}
]
}

An enrichment field can be of one of the following types:

  • "STRING":
    • Min length: 0
    • Max length: 50 bytes
  • "INT":
    • Min integer: -2147483648
    • Max integer: 2147483647
  • "FLOAT":
    • Min float: -1.79769e+308
    • Min float: 1.79769eE+308
  • "BOOL":
    • Boolean values: true / false
  • "DATETIME":
    • Format: YYYY-MM-DDThh:mm:ssZ (example: “2022-07-26T14:47:35Z”).
  • A schema cannot include more than 10 fields of each type (so there can be up to 10 strings, 10 integers, 10 booleans etc.)
  • Key names length is limited to 30 bytes
  • Strings are limited to 50 bytes

An example schema for a provider sending phone call data could look like this:

{
"fields": [
{
"name": "answered",
"type": "BOOL",
"optional": true,
"label": "Call answered",
"description": "Whether the call was answered (true) or not (false)"
},
{
"name": "call_duration",
"type": "INT",
"optional": false,
"label": "Call duration",
"description": "The call duration in milliseconds"
},
{
"name": "call_client_rating",
"type": "FLOAT",
"optional": true,
"label": "Client rating",
"description": "The call rating left by the client after the call if any"
},
{
"name": "call_center_name",
"type": "STRING",
"optional": false,
"label": "Call center name",
"description": "The name of the call center that made the call"
},
{
"name": "call_datetime",
"type": "DATETIME",
"optional": false,
"label": "Call date and time",
"description": "The date and time at which the call started"
}
]
}