v1

latestOpenAPI 3.0.12026-07-243266138.0 KB
Endpoints

Retrieve a questionnaire link

Each questionnaire link points to a specific rendered questionnaire. The link will expire after a set amount of time.

post/questionnaire-links

Request body

typestring

The type parameter defines the transactional event type. This parameter is useful to connect a feedback with a specific transaction type (e.g. sales, after-sales, checkout, etc.). By default the type is link_generation.

metadataobject

This object can be used to add information (besides what eTrusted provides by default) about the customer, event or anything else, e.g. for analysis purposes.

systemstring required

The system property identifies the system that issued the questionnaire link API call (e.g. “salesforce”, “sap”, etc.).

systemVersionstring required

The systemVersion property identifies the version of the source system (e.g. “1.0”). This offers organisations the option to use different versions of the same integration without putting this information into the system name.

Example request

{
  "type": "sales",
  "questionnaireTemplate": {
    "id": "tpl-qst-12261ad3-d36b-4a3a-a4ab-850920d7b11f"
  },
  "customer": {
    "id": "cst-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx",
    "firstName": "John",
    "lastName": "Doe",
    "email": "john.doe@example.com",
    "mobile": "+49123456789",
    "address": "Anystr. 17, 12345"
  },
  "channel": {
    "id": "example_unique_identifier",
    "type": "etrusted"
  },
  "transaction": {
    "reference": "order-12345",
    "date": "2017-01-01T13:30:15Z"
  },
  "products": [
    {
      "gtin": "1234567890123",
      "imageUrl": "https://www.specialbrandshop.com/article123-TS-WH-M/image.jpg",
      "name": "Specialbrand T-Shirt White M",
      "mpn": "23687778",
      "sku": "1234-TS-WH-M",
      "brand": "specialbrand",
      "url": "https://www.specialbrandshop.com/article123-TS-WH-M/"
    }
  ],
  "metadata": {
    "metaKey1": "metaValue1",
    "metaKey2": "metaValue2"
  },
  "system": "customer_system_name",
  "systemVersion": "1.0"
}

Response

OK

idstring required

The property id identifies the actual questionnaire which was rendered (e.g. qre-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx).

linkstring required

This is a link to the questionnaire which can be provided to the customer via the channel the organisation chooses (e.g., SMS, email, etc.). The link is shortened automatically so that it can also be used for channels with space limitations (e.g. SMS).

tokenstring required

The questionnaireToken is the jwt token of the questionnaire which was rendered. eTrusted uses the compact serialisation format as defined in JSON Web Signature (JWS) standard rfc7515, like "head.payload.signature".

Example response

{
  "id": "qre-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx",
  "link": "https://etru.st/imo2h79nl",
  "token": "eyJraWQiOiIvdG1wbHMvand0X3B1YmxpY19rZXkvZDRhMmQ2YjYtNzRjNS00NjZlLWI3MWQtNTQ1NTk4OGY0YjliIiwidHlwIjoiSldUIiwiYWxnIjoiUlMyNTYifQ.eyJxdWVzdGlvbm5haXJlUmVmIjoicXJlLTdjMGJkNzM4LTM3NWItNDk4Ni05N2E2LTlhZjg2OThlMjRmMiIsImlzcyI6Imh0dHBzOi8vd3d3LmV0cnVzdGVkLmNvbSIsImV2ZW50UmVmIjoiZXZ0LTBjYTk1MTU2L WE5NDQtNDhlNC04Mjc1LTdlZGViMTY2MGUyYyIsInF1ZXN0aW9ubmFpcmVMb2NhbGUiOiJlbl9HQiIsInN5c3RlbVZlcnNpb24iOiIxLjAuMCIsImF1ZCI6Imh0dHBzOi8vZmVlZGJhY2suZXRydXN0ZWQuY29tIiwicXVlc3Rpb25uYWlyZVRlbXBsYXRlUmVmIjoicXJ0LTRhNjFkN2JmLTVkYTMtNDE4Yi1hOThmLWU2MDM1MzRkOWZkNV9lbi1HQiIsInN5c3RlbSI6ImN1c3R vbWVyX3N5c3RlbV9uYW1lIiwiYXBpVmVyc2lvbiI6IjEuMS4wIiwiY29sbGVjdGlvblByb2Nlc3MiOiJDTE9TRURfRkVFREJBQ0siLCJjaGFubmVsUmVmIjoiY2hsLTRiOTQxYjEzLWJiMDEtNDBhOS1iZGZkLWE2ZjA0ZTVjYTEwZSIsImFjY291bnRSZWYiOiJhY2MtODYzYzlkOGQtMTEwOC00NTkxLTg2OGQtNWUwYWFhZDI2Y2Y0IiwiaWF0IjoxNTM2NzY5NjQ3fQ.A8EZkvjUEwFXT_U9bgVgIKfQkyxFY3K3G4YNN3tZzoc50eG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