Skip to main content
POST
Import an NPS response

Authorizations

Authorization
string
header
required

Bearer API key. Secret server keys start with gt_live_; client-safe browser keys start with gt_pub_ (write-only, origin-pinned). Create and scope keys in Settings → API Keys.

Body

application/json

One NPS answer from another tool. Send contactId, or send both accountId and email. Fields not listed here are rejected.

provider
string
required

The tool the answer came from, for example retently.

Required string length: 1 - 64
Pattern: ^[a-zA-Z0-9_-]+$
externalId
string
required

The answer's id in that tool. With provider, it makes the import idempotent.

Required string length: 1 - 255
score
integer
required
Required range: 0 <= x <= 10
respondedAt
string<date-time>
required

ISO 8601 with a UTC offset.

accountId
string<uuid>

The Company id.

contactId
string<uuid>

The Person id. GainTrace takes the Company and email from this Person.

email
string<email>
Maximum string length: 254
comment
string
Maximum string length: 5000
campaignId
string
Maximum string length: 255

Response

The stored answer, whether it was new or an update.

data
object