### Get All Invite Settings (cURL) Source: https://developers.etrusted.com/reference/apis-2 Use this cURL command to make a GET request to retrieve all invite settings. Ensure you include the 'accept' header for JSON response. ```Shell curl --request GET \ --url https://api.etrusted.com/invite-settings \ --header 'accept: application/json' ``` -------------------------------- ### Get Event Types - Node.js Source: https://developers.etrusted.com/reference/endpoints-1 Example of retrieving event types using Node.js. Ensure you have the 'axios' library installed. ```Node.js const axios = require('axios'); const getEventTypes = async () => { try { const response = await axios.get('https://api.etrusted.com/event-types', { headers: { 'Authorization': 'Bearer YOUR_JWT_TOKEN' } }); console.log(response.data); } catch (error) { console.error('Error fetching event types:', error); } }; getEventTypes(); ``` -------------------------------- ### GET /websites/developers_etrusted_reference Source: https://developers.etrusted.com/reference/endpoints-10 Retrieves a list of reviews for the given channels or all channels. ```APIDOC ## GET /websites/developers_etrusted_reference ### Description The list of reviews for the given channels or all channels. ### Method GET ### Endpoint /websites/developers_etrusted_reference ### Response #### Success Response (200) - **reviews** (array) - The list of reviews. #### Response Example ```json { "reviews": [ { "channel": "example_channel", "rating": 5, "comment": "Great service!" } ] } ``` ``` -------------------------------- ### GET /reviews-minimal Source: https://developers.etrusted.com/reference/getminimalreviews Retrieves a list of reviews with a minimal set of properties. This endpoint can be filtered by various query parameters and supports pagination. ```APIDOC ## GET /reviews-minimal ### Description Retrieves a list of reviews with fewer properties per item. The response items have fewer properties compared to the `/reviews` endpoint. Results can be filtered by appending query parameters. ### Method GET ### Endpoint /reviews-minimal ### Query Parameters - **channels** (string) - Optional - Comma-separated list of channel IDs to filter reviews by. - **submittedAfter** (string) - Optional - Filters reviews submitted after the specified ISO 8601 timestamp. - **submittedBefore** (string) - Optional - Filters reviews submitted before the specified ISO 8601 timestamp. - **status** (string) - Optional - Filters reviews by their status (e.g., 'REJECTED'). - **count** (integer) - Optional - The number of reviews to return per page for pagination. - **after** (string) - Optional - Returns reviews submitted after the specified cursor for pagination. - **before** (string) - Optional - Returns reviews submitted before the specified cursor for pagination. ### Request Example ``` GET /reviews-minimal?channels=chl-xxx-yyyy&submittedAfter=2018-02-01T17:10:42.733Z&count=10 ``` ### Response #### Success Response (200) - **reviews** (array) - A list of review objects, each with minimal properties. - **id** (string) - The unique identifier of the review. - **rating** (integer) - The rating given in the review. - **title** (string) - The title of the review. - **body** (string) - The content of the review. - **submittedAt** (string) - The ISO 8601 timestamp when the review was submitted. - **author** (object) - Information about the reviewer. - **name** (string) - The name of the reviewer. - **channel** (object) - Information about the channel the review is associated with. - **id** (string) - The unique identifier of the channel. - **name** (string) - The name of the channel. - **status** (string) - The status of the review (e.g., 'APPROVED', 'REJECTED'). #### Response Example ```json { "reviews": [ { "id": "rev-abc123def456", "rating": 5, "title": "Excellent Product!", "body": "This product exceeded my expectations.", "submittedAt": "2023-10-27T10:00:00Z", "author": { "name": "Jane Doe" }, "channel": { "id": "chl-xxx-yyyy", "name": "Example Channel" }, "status": "APPROVED" } ] } ``` ``` -------------------------------- ### GET /websites/developers_etrusted_reference/invite_settings/{id} Source: https://developers.etrusted.com/reference/get_invite-settings-id Retrieves the invite settings for a specific invitation ID. ```APIDOC ## GET /websites/developers_etrusted_reference/invite_settings/{id} ### Description Returns invite settings for the provided ID. ### Method GET ### Endpoint /websites/developers_etrusted_reference/invite_settings/{id} ### Parameters #### Path Parameters - **id** (string) - Required - The unique identifier for the invite settings. ### Response #### Success Response (200) - **invite_settings** (object) - An object containing the invite settings. - **setting1** (string) - Description of setting 1. - **setting2** (boolean) - Description of setting 2. ``` -------------------------------- ### GET /templates Source: https://developers.etrusted.com/reference/getalltemplates Retrieves a list of available templates. The results can be filtered using various query parameters. ```APIDOC ## GET /templates ### Description This endpoint retrieves a list of available templates stored in eTrusted. The result set can be filtered by adding request parameters. All query parameters are optional and should only be set if needed. ### Method GET ### Endpoint /templates ### Parameters #### Header Parameters - **Authorization** (string) - Required - An OAuth2 authorization header with an access token, see [OAuth2](/reference/authentication-2) #### Query Parameters - **type** (TemplateTypeApi) - Optional - Filter for a specific template type. Existing template types include: `QUESTIONNAIRE`, `INVITE`, `REMINDER`, `DOUBLE_OPT_IN_REVIEW`, `REVIEW_REPLY`. If you do not set a template filter, the response will contain all templates available to you. - **transport** (TemplateTransportApi) - Optional - Filter for a specific transport type. - **version** (string) - Optional - Filter for a template specific version. Versions have the format '2.1', with major and minor version numbers. - **isGlobal** (boolean) - Optional - Filter for global templates. - **isDefault** (boolean) - Optional - Filter for default templates. - **hasTranslations** (boolean) - Optional - Filter for templates that have translations. ### Response #### Success Response (200) - **Array of Template objects** (TemplateList) - All templates matching the filter settings of the request. #### Response Example [ { "id": "tmp-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx", "type": "QUESTIONNAIRE", "name": "exampleTemplate", "version": "2.1", "description": "An example description." } ] ``` -------------------------------- ### Get Event Types Source: https://developers.etrusted.com/reference/endpoints-1 Retrieves all event types stored for your account. Requires an Authorization header. ```Shell curl -X GET \ 'https://api.etrusted.com/event-types' \ -H 'Authorization: Bearer YOUR_JWT_TOKEN' ``` -------------------------------- ### GET /channels Source: https://developers.etrusted.com/reference/get-channels-by-token Retrieves all channels for your account. Requires an OAuth2 authorization header. ```APIDOC ## GET /channels ### Description This endpoint retrieves all channels for your account. ### Method GET ### Endpoint /channels ### Parameters #### Header Parameters - **Authorization** (string) - Required - An OAuth2 authorization header with an access token. ### Response #### Success Response (200) - **ChannelDto** (array) - The list of channels associated with your account. - **id** (string) - The channel UUID. - **createdAt** (string) - The date and time when the channel was created, in the ISO 8601 and RFC3339 compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. - **updatedAt** (string) - The date and time when the channel was last modified, in the ISO 8601 and RFC3339 compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. - **name** (string) - The name of the channel. - **address** (string) - The address that is associated with the channel. - **url** (string) - A URL that to a website that the channel represents. - **logoUrl** (string) - A URL to the channel logo. - **accountRef** (string) - A UUID as account reference. - **locale** (string) - The locale that is associated with the channel. #### Error Response (401) Unauthorized #### Error Response (403) Forbidden #### Error Response (404) Not Found ### Response Example ```json [ { "id": "chl-xxxxxxxa-yyyy-xxxx-yyyy-xxxxxxxxxxxx", "createdAt": "2018-02-01T17:09:41.79Z", "updatedAt": "2018-02-01T17:09:41.79Z", "name": "my_example_channel", "address": "Anystr. 17, 12345, Anycity, Anystate 12345", "url": "https://wwww.myshop.fiction", "logoUrl": "https://wwww.myshop.fiction/logo.png", "accountRef": "acc-xxxxxxxa-yyyy-xxxx-yyyy-xxxxxxxxxxxx", "locale": "en_US" } ] ``` ``` -------------------------------- ### GET /reviews Source: https://developers.etrusted.com/reference/endpoints-10 Retrieves a list of reviews for a specific channel, a set of channels, or the entire account. The results can be filtered and paginated. ```APIDOC ## GET /reviews ### Description This endpoint retrieves reviews for a specific channel, a set of channels or for your entire account. The result set can be modified using a set of filters. Query parameters can be added to the request, separated by `&`. ### Method GET ### Endpoint https://api.etrusted.com/reviews ### Parameters #### Query Parameters - **channels** (array of strings) - Optional - The list of channels for which the list of reviews will be returned. Example: `channels=chl-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxx1,chl-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxx2` - **after** (string) - Optional - `after` is a review ID. The list of reviews in the response will only contain reviews submitted earlier than the review with this ID. Example: `rev-xxxxxxxa-yyyy-xxxx-yyyy-xxxxxxxxxxxx` - **before** (string) - Optional - `before` is a review ID. The list of reviews in the response will only contain reviews submitted later than the review with this ID. Example: `rev-xxxxxxxb-yyyy-xxxx-yyyy-xxxxxxxxxxxx` - **submittedAfter** (string) - Optional - `submittedAfter` is a timestamp in the ISO 8601 and RFC3339 compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. The list of reviews will only contain reviews submitted with a later timestamp. Example: `2018-02-01T17:10:42.733Z` - **submittedBefore** (string) - Optional - `submittedBefore` is a timestamp in the ISO 8601 and RFC3339 compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. The list of reviews will only contain reviews submitted with an earlier timestamp. Example: `2018-02-01T17:10:42.733Z` - **count** (integer) - Optional - Defaults to 50. The desired number of customer reviews to be retrieved per page. NB: This can be set to any number from 1 to 1000 with 1000 being the maximum number of records you can get per a page. - **rating** (array of integers) - Optional - length between 1 and 5. A comma-separated list of star ratings to be retrieved. If not set, all reviews are listed. Example: `1, 2, 5` - **status** (array of strings) - Optional - A comma-separated list of statuses to be retrieved. If not set, all reviews are listed. Possible values: `APPROVED`, `MODERATION`, `REJECTED`. Example: `APPROVED, MODERATION` - **type** (array of strings) - Optional - A comma-separated list of review types to be retrieved. If not set, all reviews are listed. Possible values: `SERVICE_REVIEW`, `PRODUCT_REVIEW`. Example: `PRODUCT_REVIEW` - **hasReply** (boolean) - Optional - Reduces the list of reviews to only match reviews that either have been replied to or not. If not set, all reviews are listed. Example: `true` - **additionalInformation** (array of strings) - Optional - length ≥ 1. A comma-separated list of additional pieces of information to be retrieved with the review. Currently supported values: `VETO`, `ATTACHMENTS`. Example: `[VETO]` - **ignoreStatements** (boolean) - Optional - Filters the list to ignore statements. Default is true. - **query** (string) - Optional - A full-text search query that is matched against the order reference and email properties. - **sku** (array of strings) - Optional - A comma-separated list of product's SKUs. Be aware, that this parameter does only make sense for product reviews. - **orderBy** (string) - Optional - Specify the date to sort the returned list of reviews by. Possible options: `editedAt`, `updatedAt`, `submittedAt`. Default is `submittedAt` (descending). ### Headers - **Authorization** (string) - Required - An OAuth2 authorization header with an access token. ### Responses #### Success Response (200) - **reviews** (array) - A list of review objects. - **pagination** (object) - Pagination details. #### Response Example ```json { "reviews": [ { "id": "rev-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "channelId": "chl-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "rating": 5, "title": "Great product!", "text": "I am very happy with this product.", "status": "APPROVED", "submittedAt": "2023-10-27T10:00:00Z", "updatedAt": "2023-10-27T10:05:00Z", "author": { "name": "John Doe", "email": "john.doe@example.com" }, "product": { "sku": "SKU123", "name": "Example Product" }, "additionalInformation": [] } ], "pagination": { "count": 50, "after": "rev-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "before": "rev-yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy" } } ``` ``` -------------------------------- ### GET /invite-settings/{id} Source: https://developers.etrusted.com/reference/get_invite-settings-id Retrieves the Invite Settings entity object that matches the provided identifier parameter value. ```APIDOC ## GET /invite-settings/{id} ### Description Produces the Invite Settings entity object that matches provided identifier parameter value. ### Method GET ### Endpoint /invite-settings/{id} ### Parameters #### Path Parameters - **id** (string) - Required - The Invite Settings identifier. ### Responses #### Success Response (200) - **invite settings** (object) - Description of the invite settings object. #### Error Response - **401** - Unauthorized - **404** - Not found ``` -------------------------------- ### GET /reviews Source: https://developers.etrusted.com/reference/getminimalreviews Retrieves a list of customer reviews. Supports filtering by status, type, reply status, and full-text search. ```APIDOC ## GET /reviews ### Description Retrieves a list of customer reviews. Supports filtering by status, type, reply status, and full-text search. ### Method GET ### Endpoint /reviews ### Parameters #### Query Parameters - **status** (array[string]) - Optional - A comma-separated list of statuses to be retrieved. If not set, all reviews are listed. Possible values: `APPROVED`, `MODERATION`, `REJECTED`. - **type** (array[string]) - Optional - A comma-separated list of review types to be retrieved. If not set, all reviews are listed. Possible values: `SERVICE_REVIEW`, `PRODUCT_REVIEW`. - **hasReply** (boolean) - Optional - Reduces the list of reviews to only match reviews that either have been replied to or not. If not set, all reviews are listed. - **ignoreStatements** (boolean) - Optional - Filters the list to ignore statements. Default is true. - **query** (string) - Optional - A full-text search query that is matched against the order reference and email properties. - **sku** (array[string]) - Optional - A comma-separated list of product's SKUs. This parameter is only relevant for product reviews. - **orderBy** (string) - Optional - Specify the date to sort the returned list of reviews by. Possible options: `editedAt`, `updatedAt`, `submittedAt`. ### Response #### Success Response (200) - **reviews** (array[MinimalCustomerReviewResponseDto]) - The list of reviews for the given channels or all channels. #### Response Example { "reviews": [ { "id": "rev-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx", "channelRef": "channel-123", "rating": 5, "title": "Great Product!", "comment": "I love this product, it exceeded my expectations.", "submittedAt": "2023-10-27T10:00:00Z", "state": "APPROVED" } ] } #### Error Responses - **401** - Unauthorized - **403** - Forbidden - **404** - Not found ``` -------------------------------- ### Example URL with query parameters Source: https://developers.etrusted.com/reference/getminimalreviews Use this URL format to filter reviews by channel and submission date. Remember to use `&` as a separator for multiple parameters. ```text /reviews-minimal?channels=chl-xxx-yyyy&submittedAfter=2018-02-01T17:10:42.733Z ``` -------------------------------- ### Get Event Types - PHP Source: https://developers.etrusted.com/reference/endpoints-1 Example of retrieving event types using PHP. This snippet uses cURL. ```PHP ``` -------------------------------- ### GET /reviews-minimal Source: https://developers.etrusted.com/reference/getminimalreviews Retrieves a list of reviews with fewer properties per item. This endpoint can be used to fetch reviews for a specific channel, a set of channels, or your entire account. Results can be filtered by various query parameters and paginated. ```APIDOC ## GET /reviews-minimal ### Description Retrieves a list of reviews with fewer properties per item. This endpoint can be used to fetch reviews for a specific channel, a set of channels, or your entire account. Results can be filtered by various query parameters and paginated. ### Method GET ### Endpoint https://api.etrusted.com/reviews-minimal ### Parameters #### Header Parameters - **Authorization** (string) - Required - An OAuth2 authorization header with an access token. #### Query Parameters - **channels** (array of strings) - Optional - The list of channels for which the list of reviews will be returned. Example: `channels=chl-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxx1,chl-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxx2` - **after** (string) - Optional - A review ID. The list of reviews in the response will only contain reviews submitted earlier than the review with this ID. Example: `rev-xxxxxxxa-yyyy-xxxx-yyyy-xxxxxxxxxxxx` - **before** (string) - Optional - A review ID. The list of reviews in the response will only contain reviews submitted later than the review with this ID. Example: `rev-xxxxxxxb-yyyy-xxxx-yyyy-xxxxxxxxxxxx` - **submittedAfter** (string) - Optional - A timestamp in ISO 8601 and RFC3339 compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. The list of reviews will only contain reviews submitted with a later timestamp. Example: `2018-02-01T17:10:42.733Z` - **submittedBefore** (string) - Optional - A timestamp in ISO 8601 and RFC3339 compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. The list of reviews will only contain reviews submitted with an earlier timestamp. Example: `2018-02-01T17:10:42.733Z` - **count** (integer) - Optional - The desired number of reviews to be retrieved per page. Default: 50. Maximum: 5000. - **rating** (array of integers) - Optional - A comma-separated list of star ratings to be retrieved. Example: `1, 2, 5` ### Response #### Success Response (200) - **reviews** (array) - A list of review objects. - **nextCursor** (string) - Cursor for the next page of results. - **hasMore** (boolean) - Indicates if there are more results. #### Response Example ```json { "reviews": [ { "id": "rev-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx", "channelId": "chl-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxx1", "rating": 5, "title": "Great product!", "comment": "I am very happy with this purchase.", "submittedAt": "2023-10-27T10:00:00.000Z", "author": { "displayName": "John Doe" } } ], "nextCursor": "rev-yyyyyyyy-yyyy-xxxx-yyyy-yyyyyyyyyyyy", "hasMore": true } ``` ``` -------------------------------- ### Get Event Types - Python Source: https://developers.etrusted.com/reference/endpoints-1 Example of retrieving event types using Python. This snippet uses the 'requests' library. ```Python import requests url = 'https://api.etrusted.com/event-types' headers = { 'Authorization': 'Bearer YOUR_JWT_TOKEN' } response = requests.get(url, headers=headers) print(response.json()) ``` -------------------------------- ### Get Event Types - Ruby Source: https://developers.etrusted.com/reference/endpoints-1 Example of retrieving event types using Ruby. This snippet uses the 'httparty' gem. ```Ruby require 'httparty' url = 'https://api.etrusted.com/event-types' headers = { 'Authorization' => 'Bearer YOUR_JWT_TOKEN' } response = HTTParty.get(url, headers: headers) puts response.body ``` -------------------------------- ### Sample Access Token Response Source: https://developers.etrusted.com/reference/authentication-2 This is a sample JSON response received after a successful authentication request. It contains the `access_token`, its expiration time (`expires_in`), and other relevant details. ```json { "access_token": "eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJTVHpnYzZfTEM3ZHVnZkNoZVpoUzQyd0dNWVAyM0lBTUdkWGUtWTJrb3ZjIn0.eyJleHAiOjE2MzY0NTA0NzksImlhdCI6MTYzNjQ1MDE3OSwianRpIjoiNmNiODVlMTQtZmZlMC00MzdlLTkyMmMtMjRjMDZmM2ViMjNjIiwiaXNzIjoiaHR0cHM6Ly9sb2dpbi1xYS5ldHJ1c3RlZC5jb20vYXV0aC9yZWFsbXMvYnVzaW5lc3MtUUEiLCJhdWQiOlsiYjJiLWN1c3RvbS1jbGllbnQiLCJhY2NvdW50Il0sInN1YiI6IjY3MjIxYWRiLWZhYTMtNDdiMy1hMmQ4LWM2NThkZDk5NDNkYiIsInR5cCI6IkJlYXJlciIsImF6cCI6IkpuRGFFV042NG4wbThtSlZqSGdTUG11emJHWDNua2Z0IiwiYWNyIjoiMSIsImFsbG93ZWQtb3JpZ2lucyI6WyJodHRwczovL2FwaS5ldHJ1c3RlZC5jb20iXSwicmVhbG1fYWNjZXNzIjp7InJvbGVzIjpbImIyYl91c2VyIl19LCJyZXNvdXJjZV9hY2Nlc3MiOnsiSm5EYUVXTjY0bjBtOG1KVmpIZ1NQbXV6YkdYM25rZnQiOnsicm9sZXMiOlsidW1hX3Byb3RlY3Rpb24iXX0sImFjY291bnQiOnsicm9sZXMiOlsibWFuYWdlLWFjY291bnQiLCJtYW5hZ2UtYWNjb3VudC1saW5rcyIsInZpZXctcHJvZmlsZSJdfX0sInNjb3BlIjoicHJvZmlsZSBlbWFpbCIsImFyZWFzLWFsbG93ZWQiOlsibWFycyJdLCJjbGllbnRIb3N0IjoiMTg1LjYuMjMzLjE2MyIsImVtYWlsX3ZlcmlmaWVkIjpmYWxzZSwiY2xpZW50SWQiOiJKbkRhRVdONjRuMG04bUpWakhnU1BtdXpiR1gzbmtmdCIsInByZWZlcnJlZF91c2VybmFtZSI6InNlcnZpY2UtYWNjb3VudC1qbmRhZXduNjRuMG04bWp2amhnc3BtdXpiZ3gzbmtmdCIsImh0dHBzOi8vZXRydXN0ZWQuY29tIjp7ImFjY291bnRSZWYiOiJhY2MtMWQyZTZkZWYtOTBiZi00NzY3LTg1YTEtZjg3MjM2YTc5NzA0Iiwicm9sZSI6Im93bmVyIiwicGVybWlzc2lvbnMiOnsidXJuIjoidXJuOmV0cnVzdGVkOioifX0sImlkZW50aXR5UmVmIjoiaWRuLThjYmYwYWUyLWZlODUtNDRmNC1hNTRlLTU3ODE1YzFiMWZjNSIsImNsaWVudEFkZHJlc3MiOiIxODUuNi4yMzMuMTYzIiwiZW1haWwiOiJzZXJ2aWNlLWFjY291bnQtam5kYWV3bjY0bjBtOG1qdmpoZ3NwbXV6Ymd4M25rZnRAcGxhY2Vob2xkZXIub3JnIn0.IA7Lwkw3Xn94cRCKbhETxPOZmSyHtNdLqjbriEsERDQOzTkMAibaAUCkL1emEytHplhaGv_T97JHU_hxSjTM_WexLvJcD_rDbjkcOJgqv4-48r2KqxpO_qzcNms1pnsVsj0ZGhlkVKiyD6VeeOfv04nTiZcXOwLgPa_BKrKwooem6UBC8Pkc9Rl41I0zZHCevOr_ihm7Z1gEE32_tkd4CuwNXEf-EhvM6F4-KWIQX5kYYPQciZ6CdGWYcdHfplSbh5eLI-dt-XTUBKoxNsGO52Aa3kjiGJ3YaIC_UVcKhF9QfDINMSbGYclNHovmc5b22R6AWmGMZDhd-c6glmh8lQ", "expires_in": 3600, "refresh_expires_in": 0, "token_type": "bearer", "not-before-policy": 1635873642, "scope": "profile email" } ``` -------------------------------- ### Invite Settings Configuration Source: https://developers.etrusted.com/reference/get_invite-settings Details the configuration for product and service invites, including scheduling, templates, and enablement status. ```APIDOC ## Invite Settings Configuration ### Description This section describes the structure for configuring invite settings, encompassing both product and service-specific configurations. It details parameters such as sending delay, time of day, template IDs, and enablement status. ### Request Body Example ```json { "channelId": "string", "eventTypeId": "string", "enabled": true, "productInviteConfiguration": { "sendingDelayInDays": 5, "sendingTimeOfDay": "08:00:00Z", "inviteTemplateId": "tpl-abcdef12-3456-7890-abcd-ef1234567890", "questionnaireTemplateId": "qst-abcdef12-3456-7890-abcd-ef1234567890", "enabled": true }, "serviceInviteConfiguration": { "sendingDelayInDays": 3, "sendingTimeOfDay": "07:15:00Z", "inviteTemplateId": "tpl-c31c696d-a70e-450a-a842-58370b401cd8", "questionnaireTemplateId": "qst-93fc31d6-e3f4-4554-b279-8059550995d8", "enabled": true } } ``` ### Request Body Parameters #### `channelId` (string) - Required Identifier for the communication channel. #### `eventTypeId` (string) - Required Identifier for the event type. #### `enabled` (boolean) - Required Indicates if invite settings are enabled. #### `productInviteConfiguration` (object) - Required Configuration for product review invites. - **`sendingDelayInDays`** (number) - Required - The number of days to delay sending invites. Minimum 0, Maximum 180. - **`sendingTimeOfDay`** (string) - Required - The time of day for sending invites in 24h UTC format (e.g., "07:15:00Z"). - **`inviteTemplateId`** (string) - Required - The ID of the invite template. Minimum length 1. - **`questionnaireTemplateId`** (string) - Required - The ID of the questionnaire template. Minimum length 1. - **`enabled`** (boolean) - Required - Indicates if product invite settings are enabled. #### `serviceInviteConfiguration` (object) - Required Configuration for service review invites. - **`sendingDelayInDays`** (number) - Required - The number of days to delay sending invites. Minimum 0, Maximum 180. - **`sendingTimeOfDay`** (string) - Required - The time of day for sending invites in 24h UTC format (e.g., "07:15:00Z"). - **`inviteTemplateId`** (string) - Required - The ID of the invite template. Minimum length 1. - **`questionnaireTemplateId`** (string) - Required - The ID of the questionnaire template. Minimum length 1. - **`enabled`** (boolean) - Required - Indicates if service invite settings are enabled. ### Response Example (Success) ```json { "message": "Invite settings updated successfully." } ``` ### Response Example (Error) ```json { "error": "Invalid input provided." } ``` ``` -------------------------------- ### OpenAPI Definition for Get Channels Source: https://developers.etrusted.com/reference/get-channels-by-token This JSON object defines the OpenAPI specification for the 'Get channels' endpoint. It includes details about the API, server URLs, paths, request parameters, and response schemas. ```json { "openapi": "3.0.1", "info": { "title": "Accounts API", "description": "Account application", "version": "1.0", "x-audience": "public", "x-api-key": "46837b3a-ce3c-40d3-9d76-bf040bb3fb6d" }, "servers": [ { "url": "api.etrusted.com" } ], "paths": { "/channels": { "get": { "tags": [ "Channels" ], "summary": "Get channels", "description": "This endpoint retrieves all channels for your account.\n", "operationId": "get-channels-by-token", "parameters": [ { "name": "Authorization", "in": "header", "description": "An OAuth2 authorization header with an access token, see [OAuth2](/reference/authentication-2).", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "The list of channels associated with your account.", "content": { "application/json": { "schema": { "type": "array", "items": { "$ref": "#/components/schemas/ChannelDto" } } } } }, "401": { "description": "Unauthorized", "content": {} }, "403": { "description": "Forbidden", "content": {} }, "404": { "description": "Not Found", "content": {} } } } } }, "components": { "schemas": { "ChannelDto": { "type": "object", "properties": { "id": { "type": "string", "description": "The channel UUID.", "example": "chl-xxxxxxxa-yyyy-xxxx-yyyy-xxxxxxxxxxxx" }, "createdAt": { "type": "string", "description": "The date and time when the channel was created, in the ISO 8601 and RFC3339 compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. Check the [glossary](/docs/glossory#iso-8601) for examples of valid datetime formats.", "format": "date-time", "example": "2018-02-01T17:09:41.79Z" }, "updatedAt": { "type": "string", "description": "The date and time when the channel was last modified, in the ISO 8601 and RFC3339 compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. Check the [glossary](/docs/glossory#iso-8601) for examples of valid datetime formats.", "format": "date-time", "example": "2018-02-01T17:09:41.79Z" }, "name": { "type": "string", "description": "The name of the channel.", "example": "my_example_channel" }, "address": { "type": "string", "description": "The address that is associated with the channel.", "example": "Anystr. 17, 12345, Anycity, Anystate 12345" }, "url": { "type": "string", "description": "A URL that to a website that the channel represents.", "example": "https://wwww.myshop.fiction" }, "logoUrl": { "type": "string", "description": "A URL to the channel logo.", "example": "https://wwww.myshop.fiction/logo.png" }, "accountRef": { "type": "string", "description": "A UUID as account reference.", "example": "acc-xxxxxxxa-yyyy-xxxx-yyyy-xxxxxxxxxxxx" }, "locale": { "type": "string", "description": "The locale that is associated with the channel.", "format": "locale", "example": "en_US" } } } } }, "x-readme": { "explorer-enabled": false, "proxy-enabled": true }, "_id": { "buffer": { "0": 100, "1": 106, "2": 65, "3": 40, "4": 135, "5": 77, "6": 235, "7": 0, "8": 17, "9": 186, "10": 187, "11": 126 } } } ``` -------------------------------- ### GET /event_types Source: https://developers.etrusted.com/reference/get-event-types-1 Retrieves all event types stored for your account. ```APIDOC ## GET /event_types ### Description This method retrieves all event types stored for your account. ### Method GET ### Endpoint /event_types ### Parameters ### Request Example (No request body for GET requests) ### Response #### Success Response (200) - **event_types** (array) - A list of event types. - **id** (integer) - The unique identifier for the event type. - **name** (string) - The name of the event type. #### Response Example ```json { "event_types": [ { "id": 1, "name": "User Login" }, { "id": 2, "name": "Order Placed" } ] } ``` ``` -------------------------------- ### List Available Templates (cURL) Source: https://developers.etrusted.com/reference/endpoints-5 Use this cURL request to retrieve a list of all available templates. You can filter the results by adding query parameters such as type, transport, version, isGlobal, isDefault, or hasTranslations. ```shell curl --request GET \ --url https://api.etrusted.com/templates \ --header 'accept: application/json' ``` -------------------------------- ### GET /websites/developers_etrusted_reference/{reviewId} Source: https://developers.etrusted.com/reference/getreview Retrieves a specific review using its ID. ```APIDOC ## GET /websites/developers_etrusted_reference/{reviewId} ### Description This endpoint retrieves a review by its ID. ### Method GET ### Endpoint /websites/developers_etrusted_reference/{reviewId} ### Parameters #### Path Parameters - **reviewId** (string) - Required - The unique identifier of the review to retrieve. ``` -------------------------------- ### OriginalReview Object Source: https://developers.etrusted.com/reference/getreview Represents the initial customer review, including rating, comment, title, and any associated reply. ```APIDOC ## OriginalReview Object ### Description This is the initial unedited customer review. This object will not change when the review gets edited. ### Properties - **rating** (number) - The original core review star rating. The value ranges from 1 to 5. - **comment** (string) - The original review comment. It is a string of up to 4000 characters. - **title** (string) - The original review title. - **reply** (object) - The original reply to the customer review, written by the channel owner. - **replyComment** (string) - The text message of the reply. - **replyCreatedAt** (string) - The date and time when the reply was stored initially, in the [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) and [RFC 3339](https://tools.ietf.org/html/rfc3339) compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. Check the [glossary](/docs/glossory#iso-8601) for examples of valid datetime formats. - **replyUpdatedAt** (string) - The date and time when the reply was last updated, in the [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) and [RFC 3339](https://tools.ietf.org/html/rfc3339) compliant format `yyyy-MM-dd’T’HH:mm:ss.SSSZ`. Check the [glossary](/docs/glossory#iso-8601) for examples of valid datetime formats. ### Example ```json { "rating": 4, "comment": "It was a very good experience. The service team is very friendly and the prices are good. I can only recommend this store.", "title": "It was a very good experience.", "reply": { "replyComment": "We appreciate your feedback.", "replyCreatedAt": "2018-02-01T17:10:42.733Z", "replyUpdatedAt": "2018-02-01T17:11:33.121Z" } } ``` ``` -------------------------------- ### Get a review Veto by reviewID Source: https://developers.etrusted.com/reference/getreviewveto This endpoint retrieves the veto for a specific review. ```APIDOC ## GET /reviews/{reviewId}/vetos ### Description This endpoint retrieves the veto for a specific review. ### Method GET ### Endpoint /reviews/{reviewId}/vetos ### Parameters #### Path Parameters - **reviewId** (string) - Required - The review ID. #### Header Parameters - **Authorization** (string) - Required - An OAuth2 authorization header with an access token. ### Responses #### Success Response (200) - **id** (string) - The veto UUID. - **ticketId** (string) - A reference to the ticket that was created internally at Trusted Shops for this veto. - **comment** (string) - The comment in the ticket that was created internally at Trusted Shops for this veto. - **reason** (string) - The reason for this veto. Possible values: `UNTRUTHFUL`, `ABUSIVE`, `VIOLATES_THE_TERMS_OF_USE`, `INAPPROPRIATE_IMAGE`. - **createdAt** (string) - The date and time when the veto was created, in ISO 8601 and RFC 3339 compliant format. - **updatedAt** (string) - The date and time when the veto was last modified, in ISO 8601 and RFC 3339 compliant format. #### Response Example (200) { "id": "vet-xxxxxxxx-yyyy-xxxx-yyyy-xxxxxxxxxxxx", "ticketId": "123123", "comment": "example comment", "reason": "UNTRUTHFUL", "createdAt": "2018-02-01T17:09:41.790Z", "updatedAt": "2018-02-01T17:09:41.790Z" } #### Error Responses - **401** - Unauthorized - **403** - Forbidden - **404** - Not found ```