Testify API Documentation

Table of contents

Overview

In our Technical Documentation the required information when working with the Testify API is listed.

The Testify API can be used to query information from Testify, but also to create and update information. With help of the Testify API it is easily possible to connect Testify to your own systems and exchange information in an automated way. Testify Webhooks can be used to respond on events that occur in Testify in an automated way (more information below).

The Testify API is a REST API which can be accessed via authenticated HTTP requests (using an API key). The documentation with all available endpoints can be found at https://cloud.testify.io/core/services/swagger/index.html and it is recommended to use the most recent version, which at the moment of writing this documentation is Testify API v3.0. Note that as of now all listed versions are supported, but it is not recommended to any other than v3.0 as the older versions might get deprecated in the future.

Fundamentals

HTTP Methods

With GET requests the details of an entity can be queried.

image-20240719-054732.png

A POST request method is used when a new entity should be created and the data is sent as JSON in the request body.

image-20240719-054835.png

The PATCH endpoints can be used to update single properties of an existing entity.

If a property is included in the JSON request body, it's value should be updated with the value from the JSON. All other properties that are not included will stay the same as before. To delete an optional property value this can be done by setting the property in the JSON to NULL.

For properties that contain lists, NULL and an empty array both will mean the list will be emptied after the update. If you want to update a list you have to provide the complete list of entries again that should be set after the update operation.

Path Parameter vs. Query Parameter

The Parameters section in swagger shows the type of the parameter.

  • Path Parameter: /public/testObjects/my-testobject?api-version=3.0

    • all path parameters are seperated by a /

  • Query Paremeter: /public/testObjects/my-testobject?api-version=3.0

    • the first query parameter must start with an ?

    • all following query parameters are appended starting with an &

Here also the three mandatory authentication HTTP headers are listed, for details see below section (Authentication).

Versioning

A version of the API contains a certain set of attributes, it is ensured that these are always available, the name of the attribute does not change and no new mandatory attributes are added in the same version. New optional fields are allowed, which can also affect the order of attributes.

Every HTTP request must contain the API version 3.0 as query parameter
e.g. ?api-version=3.0 or ?<other-parameter=value>&api-version=3.0

StageBaseUrl

The StageBaseUrl can differ and must be adapted in the request URL (and also in the Swagger UI URL) if a private stage is used. All examples in this documentation use https://cloud.testify.io as StageBaseUrl and assume that the Testify stage is used.

Id, ExternalId, Identifier in Testify Public API v3

  • Id: Internal Testify id (required, unique, guid-format)

  • ExternalId: Third-party-system id (optional, unique)

  • Identifier: Professional id (unique, human-readable)

Each entity in Testify has an (internal) id which is globally unique in the format of “00000000-0000-0000-0000-000000000000“ which is always automatically generated by the system itself if not set explicitly.

Some entities namely testobjects, testobject-types, checklists, checklist templates, checks, testequipments, testequipment-types, customfields, issue categories, groups and users additionally have an optional, unique ExternalId, which can be used for correlating to entities in another system. For example, when testobjects are synced from an ERP system, the IDs of the ERP system can be used as the ExternalId in Testify. This will make it easy later on to find the correlating test object for an entity in your ERP system by just doing an ID lookup. When creating an object without providing an externalId, it automatically gets set to the value of the internal Id.

Many entities namely testobjects, checks, testequipments, customfields and groups have an identifier property which can be used as professional unique identification of the object.

E.g. id: 9033d3c6-5897-484c-a247-61cc4e636920, externalId: sap-object-1 , identifier: my-testobject-1

Testify entities

  • Checklist Template: Defines the structure of a checklist with its pages, sections and checks.

  • Checklist Instance: Is an instance of a checklist template which is assigned to a certain user or group and where check results are added. A checklist instance can be created from a published checklist template.

  • Check & Check Result : A checklist can contain 13 different check types of checks with different parameters and result values. Adding a check result is only possible for following kinds of check types:

Check Type

Add Check Result

Check Type

Add Check Result

Calculation

Date

FileUpload

GeoPosition

Logical

MultipleChoice

Numeric

Photo

Signature

SingleChoice

TestObjectSelection

Text

Time

  • Issue & IssueCategory & IssueSeverity: An issue must be categorized and must have a severtiy.

  • TestEquipment & TestEquipmentType: A testequipment is a tool that is used when executing a check and it is categorized by a test equipment type.

  • TestObject & TestObjectType: A testobject can be linked to a checklist instance or an issue and it is categorized by a test object type.

Authentication

To access the Testify API a Testify user with a valid API key is needed. This API key must then be sent in every requests header.

Please be aware that a user in Testify has roles and permissions and is allowed to make certain requests based on that. An API key is always generated for a certain Testify user and when making a request with an API key the permissions of that user are used. Therefore, it is advised to create an own Interface User that has all roles and permissions needed for accessing the endpoints.

Create Interface User and generate API Key

  1. Go to https://cloud.testify.io/todos and Log In with your regular account.

  2. Go to “Administration” → “Users” and create a new Interface User with a self defined password and all roles assigned.

  3. Within the User’s Profile, click on the context menu and select “Generate API key”.

  4. Note the API key that consists of secret, Subject and Tenant.

Please be aware that this API key can only be viewed once and must be regenerated otherwise. Regenerating means disabling the previous used API key.

Authenticate with API Key

  1. Place secret, Subject and Tenant in request header.

Pagination

All /search endpoints have a mandatory top(integer) property, an optional skip(integer) property and an optional count(boolean) property in their request body.

The top property must be set to a maximum value of 80 and defines the number of elements that get sent in the response.

The skip property can be set and defines the number of elements that should be skipped.

The count property is a boolean flag which tells if the count of all elements the sent back in the response. It should be set to true when trying to query all elements and can be then used to query all the elements in batches.

Request

Response

Request

Response

Number of Request

Top

Skip

Count

Value

Count

1.

80

0

true

First 80 elements

200

2.

80

80

true

Second 80 elements

200

3.

40

160

true

Last 40 elements

200

Checklist Template Creation

A checklist template defines the structure of a checklist with its pages, sections and checks. In Testify there is a revisioning mechanism for checklist templates, and these checklist template revisions can be in different states (Draft, Published, Disabled).

When the “id” or “externalId” of an already existing checklist template is set, only a new checklist template revision will be created according to the given “state”.

When no checklist template exists, a new checklist template with it´s associated checklist template revision will be created.

{ "id": <guid>, "externalId": "my-checklist-template", "title": { "deAT": "Checkliste", "enUS": "Checklist" }, "description": { "deAT": "Checkliste mit allen Checks", "enUS": "Checklist with all Checks" }, "pages": [ { "externalId": "page1", "identifier": "page1", "title": { "deAT": "Seite 1", "enUS": "Page 1" }, "description": { "deAT": "Seite 1", "enUS": "Page 1 " }, "pages": [], "sections": [ { "externalId": "section1", "identifier": "section1", "title": { "deAT": "Sektion 1", "enUS": "Section 1" }, "description": { "deAT": "Sektion 1", "enUS": "Section 1 " }, "optionalSetting": "Required", "checks": [ { "externalId": "calculation-check", "identifier": "calculation-check", "title": { "deAT": "Berechnungs-Check", "enUS": "Calculation Check" }, "description": { "deAT": "Berechnungs-Check", "enUS": "Calculation Check" }, "type": "Calculation", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "calculationCheck": { "decimalPlaces": 2, "function": "Sum", "maxValue": 30.00, "maxWarnValue": 28.00, "minValue": 0.00, "minWarnValue": 2.00, "resultFieldLabel": { "deAT": "Ergebnis", "enUS": "Result" }, "setPointValue": 15.00, "unitSuffix": { "deAT": "m", "enUS": "m" }, "warnText": { "deAT": "Warnung", "enUS": "Warning" }, "formula": null, "checkScoreNegativeResult": null, "checkScorePositiveResult": null, "inputValues": [ { "label": { "deAT": "Erster Wert", "enUS": "First Value" }, "defaultValue": null, "referredCheckIdentifier": null }, { "label": { "deAT": "Zweiter Wert", "enUS": "Second Value" }, "defaultValue": null, "referredCheckIdentifier": null } ] } }, { "externalId": "date-check", "identifier": "date-check", "title": { "deAT": "Datums-Check", "enUS": "Date Check" }, "description": { "deAT": "Datums-Check", "enUS": "Date Check" }, "type": "Date", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "dateCheck": { "placeholderText": { "deAT": "Datum", "enUs": "Date" }, "maxValue": "2025-12-31", "minValue": "2024-01-01", "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "file-upload-check", "identifier": "file-upload-check", "title": { "deAT": "Datei Upload Check", "enUS": "File Upload Check" }, "description": { "deAT": "Datei Upload Check", "enUS": "File Upload Check" }, "type": "FileUpload", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "fileUploadCheck": { "maxNumberOfFiles": 2, "minNumberOfFiles": 1, "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "geo-position-check", "identifier": "geo-position-check", "title": { "deAT": "GPS Check", "enUS": "Geo Position Check" }, "description": { "deAT": "GPS Check", "enUS": "Geo Position Check" }, "type": "GeoPosition", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "geoPositionCheck": { "placeholderText": { "deAT": "GPS Position", "enUs": "Geo Position" }, "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "logical-check", "identifier": "logical-check", "title": { "deAT": "Logischer Check", "enUS": "Logical Check" }, "description": { "deAT": "Logischer Check", "enUS": "Logical Check" }, "type": "Logical", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "logicalCheck": { "isQuickInput": false, "labelFalse": null, "labelTrue": null, "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "multiple-choice-check", "identifier": "multiple-choice-check", "title": { "deAT": "Mehrfachauswahl Check", "enUS": "Multiple Choice Check" }, "description": { "deAT": "Mehrfachauswahl Check", "enUS": "Multiple Choice Check" }, "type": "MultipleChoice", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "multipleChoiceCheck": { "positiveValidationType": "AnyOptionSelected", "options": [ { "label": { "deAT": "Erste Option", "enUs": "First Option" } }, { "label": { "deAT": "Zweite Option", "enUs": "Second Option" } } ] } }, { "externalId": "numeric-check", "identifier": "numeric-check", "title": { "deAT": "Numerischer Check", "enUS": "Numeric Check" }, "description": { "deAT": "Numerischer Check", "enUS": "Numeric Check" }, "type": "Numeric", "isScoringEnabled": false, "checkCategories": null, "numericCheck": { "placeholderText": { "deAT": "Wert", "enUs": "Value" }, "decimalPlaces": 2, "maxValue": 30.00, "maxWarnValue": 28.00, "minValue": 0.00, "minWarnValue": 2.00, "isQuickInput": null, "setPointValue": 25.00, "unitSuffix": { "deAT": "m", "enUS": "m" }, "warnText": { "deAT": "Warnung", "enUS": "Warning" }, "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "photo-check", "identifier": "photo-check", "title": { "deAT": "Foto Check", "enUS": "Photo Check" }, "description": { "deAT": "Foto Check", "enUS": "Photo Check" }, "type": "Photo", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "photoCheck": { "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "signature-check", "identifier": "signature-check", "title": { "deAT": "Unterschrifts-Check", "enUS": "Signature Check" }, "description": { "deAT": "Unterschrifts-Check", "enUS": "Signature Check" }, "type": "Signature", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "signatureCheck": { "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "single-choice-check", "identifier": "single-choice-check", "title": { "deAT": "Einzelauswahl Check", "enUS": "SingleChoice Check" }, "description": { "deAT": "Einzelauswahl Check", "enUS": "SingleChoice Check" }, "type": "SingleChoice", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "singleChoiceCheck": { "options": [ { "label": { "deAT": "Erste Option", "enUs": "First Option" } }, { "label": { "deAT": "Zweite Option", "enUs": "Second Option" } } ], "isQuickInput": null, "showOptionsHorizontally": true } }, { "externalId": "test-object-selection-check", "identifier": "test-object-selection-check", "title": { "deAT": "Testobjektauswahl-Check", "enUS": "Test Object Selection Check" }, "description": { "deAT": "Testobjektauswahl-Check", "enUS": "Test Object Selection Check" }, "type": "TestObjectSelection", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "testObjectSelectionCheck": { "isMultiSelect": false, "positiveValidation": false, "selectionType": "AllTestObjects", "restrictedTestObjectTypes": null, "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "text-check", "identifier": "text-check", "title": { "deAT": "Text Check", "enUS": "Text Check" }, "description": { "deAT": "Text Check", "enUS": "Text Check" }, "type": "Text", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "textCheck": { "placeholderText": { "deAT": "Text", "enUs": "Text" }, "isQuickInput": null, "matchString": null, "checkScoreNegativeResult": null, "checkScorePositiveResult": null } }, { "externalId": "time-check", "identifier": "time-check", "title": { "deAT": "Zeit Check", "enUS": "Time Check" }, "description": { "deAT": "Zeit Check", "enUS": "Time Check" }, "type": "Time", "isScoringEnabled": false, "startScore": null, "checkCategories": null, "timeCheck": { "placeholderText": { "deAT": "Zeit", "enUs": "Time" }, "maxValue": null, "minValue": null, "checkScoreNegativeResult": null, "checkScorePositiveResult": null } } ] }], "checks": [] } ], "sections": [], "checks": [], "state": "Draft", "testObjectTypeRestrictions": [ { "id": "<guid>" } ], "testObjectRestrictions": [ { "id": "<guid>" } ], "closingRestrictions": [], "groupRestrictions": [ { "id": "<guid>" } ], "customFieldMappings": [ { "customField": { "id": "<guid>" }, "state": "Optional" } ], "tags": [ "my-checklist-tag" ], "isCheckScanEnabled": true, "isAutomaticNaviationToNextPageOrSectionEnabled": false, "isAutomaticNaviationToNextCheckEnabled": true, "isReuseLastCheckResultEnabled": true, "isFocusCheckScanAfterCheckEnabled": true, "signatureSetting": "Disabled", "checklistLimitation": "NoLimit", "startScore": null, "publishNotes": null }

Webhooks

Webhooks allow you to respond on events that occur in Testify in an automated way, without the need to make requests repeatedly. To use webhooks a HTTP server where Testify is allowed to send POST requests is needed. When this is available, it can be easily configured within Testify on what events should be reacted to and to which URL the request should be sent to.

How to define a webhook within Testify

  1. As logged in User go to “Administration” → “Workflows” and create a new Workflow.

  2. Define a Name.

  3. Define an Event.

  4. Define an Action with scope “Webhook” and type “trigger”.

  5. Click on “Parameters” and provide the URL of the webhook that should be called and can be accessed by Testify via POST request. As an optional parameter, an Identifier can be specified, which then will be sent in the request body. Also, the request timeout and the HTTP status codes that indicate success can be customized, as well as some authorization options containing of a secret and HTTP headers. Please consider that Content-Type: application/json and Content-Length HTTP headers are set implicitly as default by Testify and can't be added here.

  6. Save newly created workflow, which then automatically gets invoked when the specified event occurs.

  7. To see when a webhook has been executed and whether the execution has been successful, go to the workflow details, click on the context menu and select “History”.

Samples of what information will be sent in the webhook payload

The HTTP method is always POST and the payload depends on the event that triggered the webhook.

Property

Description

Property

Description

WebHookIdentifier

This is set to the identifier that can be set as an optional parameter at the webhook configuration (see above).

IssueFilter, ChecklistFilter, TestObjectFilter, PdfFilter, UserFilter, or TimerFilter

Depending on the event that triggered the workflow these are set.

TriggeredByWorkflowId

Id of the workflow that triggered the event. Only set if the event was triggered by a workflow.

TenantId

Id of the tenant.

EntityType

Gives information about the event that triggered the webhook: 1 (issue), 2 (checklist), 3 (testobject), 4 (pdf), 5 (user), or 6 (timertrigger).

Action

Tells whether 1 (created) or 2 (updated) triggered the webhook.

In our case a checklist has been created, so 1 is set.

ChangedValues

Only set if the triggering event is an update event. Shows the values that were changed in this update.

EntityId

External Id of the object that triggered the webhook.

In our case this is the external id of the created checklist.

EntityUrl

URL where details of the object that triggered the webhook can be found.

In our case the created checklist can be queried via GET-request to this URL.

CreatedAt

Date and time when the event took place.

{ "webHookIdentifier": "string", "issueFilter": { "createdById": "00000000-0000-0000-0000-000000000000", "modifiedById": "00000000-0000-0000-0000-000000000000", "assignedToId": "00000000-0000-0000-0000-000000000000", "testObjectId": "00000000-0000-0000-0000-000000000000", "testObjectExternalId": "string", "testObjectTypeId": "00000000-0000-0000-0000-000000000000", "state": "issueState", "issueCategoryId": "00000000-0000-0000-0000-000000000000", "issueSeverityId": "00000000-0000-0000-0000-000000000000", "title": "string", "description": "string", "scheduledFor": "2023-03-27T11:08:24.661Z" }, "checklistFilter": { "externalId": "string", "createdById": "00000000-0000-0000-0000-000000000000", "modifiedById": "00000000-0000-0000-0000-000000000000", "assignedToId": "00000000-0000-0000-0000-000000000000", "testObjectId": "00000000-0000-0000-0000-000000000000", "testObjectExternalId": "string", "testObjectTypeId": "00000000-0000-0000-0000-000000000000", "state": "testItemState", "checklistTemplateId": "00000000-0000-0000-0000-000000000000", "scheduledFor": "2023-03-27T11:08:24.661Z", "score": 0 }, "testObjectFilter": { "createdById": "00000000-0000-0000-0000-000000000000", "testObjectTypeId": "00000000-0000-0000-0000-000000000000", "testObjectId": "00000000-0000-0000-0000-000000000000", "testObjectExternalId": "string" }, "pdfFilter": { "pdfProfileId": "00000000-0000-0000-0000-000000000000", "userId": "00000000-0000-0000-0000-000000000000" }, "userFilter": { "userId": "00000000-0000-0000-0000-000000000000", "groupIds": [ "00000000-0000-0000-0000-000000000000" ], "roleIds": [ "string" ] }, "timerFilter": { "actorId": "00000000-0000-0000-0000-000000000000", "cronExpression": "string" }, "triggeredByWorkflowId": "00000000-0000-0000-0000-000000000000", "tenantId": "00000000-0000-0000-0000-000000000000", "entityType": "subscriptionEntityType", "action": "eventActions", "changedValues": { "additionalProp1": { "oldValue": {}, "newValue": {} }, "additionalProp2": { "oldValue": {}, "newValue": {} }, "additionalProp3": { "oldValue": {}, "newValue": {} } }, "entityId": "00000000-0000-0000-0000-000000000000", "entityUrl": "string", "createdAt": "2023-03-27T11:08:24.661Z", "testifyCorrelationId": "string" }

IssueState

Draft = 0, Opened = 1, Resolved = 2, Verified = 3, Deleted = 99

TestItemState

SubscriptionEntityType

EventActions

Here are some samples of sent information in the webhook payload:

  • Checklist created:

  • Issue created:

    • Everything looks very similar to the checklist created event, but here the IssueFilter is set and EntityType is set to 1 (issue).

  • Issue updated:

    • The issue has been resolved with a duration of 5 minutes.

    • Note the ChangedValues attribute that shows that duration and state were changed. Also Action has value 2 (updated) now.

Authenticated webhook requests

As mentioned above additional parameters for sending authenticated webhook requests can be specified in the webhook “Parameters”. So the target of the webhook is able to verify the integrity of an incoming webhook request. This is possible by 2 differnt mechanisms:

  1. Adding arbitrary HTTP-Headers: This consists of key-value pairs which are then sent in the HTTP headers, e.g. Username: {Username}, Password: {Password}. Please be aware that this should only be done when using a secure channel like HTTPS, TLS.

  2. Signing the webhook request with a pre-shared secret: This adds the following two additional HTTP headers to the webhook request - Testify-Webhook-Signature and Testify-Webhook-Signature-Timestamp. The Testify-Webhook-Signature is a hashed value, which is created from a timestamp and the request payload by using SHA256 HMAC with the provided “secret” in the webhook parameters and then base64 encoding. Represented as: base64(HMACSHA256(TIMESTAMP + BODY))
    To verify the signature, create the same SHA256 HMAC signature (containing of the Testify-Webhook-Signature-Timestamp and the request payload) with the provided secret, then base64 encoding and compare it to the Testify-Webhook-Signature sent in the request header. See following example:

 

Public API v2

External vs. Internal ID in Testify Public API v2

Many entities in Testify namely checklist templates, checklist instances, testobjects, testobject-types testequipments, testequipment-types, customfields, issue categories, groups and users have an external and an internal ID. The internal id must be a globally unique identifier in the format of “00000000-0000-0000-0000-000000000000“, whereas the external id can be in a format more readable for humans to better recognize the object and must also be unique.

E.g. internal id: 9033d3c6-5897-484c-a247-61cc4e636920, external id: my-testobject

Users can choose an external ID to make it easy to correlate the entities to entities in other systems. For example, when testobjects are synced with an ERP system, you could reuse the IDs of the ERP system and set the external IDs in testify with that value. That will make it easy later on to find the correlationg test object for an entity in your ERP system by just doing an ID lookup.

Where does the Testify Public API v2 use External IDs?

In General, all IDs used by the Testify Public API v2 are external IDs.

What happens when no External ID is provided when creating objects?

An internal ID is always automatically generated by the system itself. The external ID can be chosen when creating the entity via the API v2 by just assigning a value to the ID property. This value has to be unique, though. When creating an object without providing an external ID, it automatically gets set to the value of the generated internal ID.

Webhooks - Example of a complete use case using Public API v2

This example shows a complete use case using Testify API v2. First a testobject is created and for this testobject a checklist is instantiated. When the checklist is completed in Testify two webhooks are called, one that fetches the check results and one that informs us about a generated PDF for that checklist and downloads it.

  1. Create testobject via Testify API v2:

    1. Send POST-request

      • Endpoint: {StageBaseUrl}/public/testobjects?api-version=2.0

      • HTTP method: POST

      • HTTP headers: API key (secret, Subject, Tenant), Content-Type: application/json, Content-Length

      • Payload (approach 1): Both the internal id and the external id are automatically set by the system and are the same.

      • OR Payload (approach 2) including self-assigned external id: The external id is set to my-testobject and the internal id is automatically set by the system.

    2. Testobject has successfully been created if response has statuscode 200 OK and payload contains external id of new testobject. If response statuscode is 400 Bad Request something in the request is wrong, but error details are provided in the payload.

  2. Instantiate checklist for newly created testobject via Testify API v2:

    1. Send POST-request:

      • Endpoint: {StageBaseUrl}/public/checklists?api-version=2.0

      • HTTP method: POST

      • HTTP headers: API key (secret, Subject, Tenant), Content-Type: application/json, Content-Length

      • Payload (approach 1): testObjectId contains the external id of the above created testobject.

      • OR Payload (approach 2) including self-assigned external id:

    2. Checklist has successfully been started when response has statuscode 200 OK and payload contains external id of new checklist instance. If response statuscode is 400 Bad Request something in the request is wrong, but error details are provided in the payload.

  3. React to webhook informing us of completed checklist and fetch check results:

    Prerequisites 1 - Before completing the checklist: Configure webhook that should be triggered (see above).
    Event details: Scope: “Checklist”, Type: “updated”, Triggers: State = “Done”
    Action details: Scope “Webhook”, Type: “trigger”, provide URL

    1. Parse Webhook payload:

      • ChangedValues shows state change from 0 (open) to 3 (done) and new modifiedAt date.

      • EntityId is needed to fetch the checklist results.

    2. Send GET-Request to fetch checklist results:

      • Endpoint: {StageBaseUrl}/public/checklists/{EntityId}/results/flat?api-version=2.0

      • HTTP method: GET

      • HTTP headers: API key (secret, Subject, Tenant)

      • Payload: no payload

    3. The response should have status code 200 OK and gives details of the checklist instance with all testcases. Details to this response can be found below at “Structure of checklist results” section.

       

  4. React to webhook informing us of generated PDF for checklist and download it:

    Prerequisites 1 - Before completing the checklist: Configure workflow that automatically generates PDF.
    Event details: Scope: “Checklist”, Type: “updated”, Triggers: State = “Done”
    Action details: Scope: “PDF”, Type: “generate”, select PDF protocol profile and language

    Prerequisites 2 - Before completing the checklist: Configure webhook that should be triggered.
    Event details: Scope: “PDF”, Type: “Checklist PDF generated”
    Action details: Scope “Webhook”, Type: “trigger”, provide URL

    1. Parse Webhook payload:

      • EntityUrl is needed to get created PDF.

    2. Send GET-Request to get created PDF and download it:

      • Endpoint: EntityUrl

      • HTTP method: GET

      • HTTP headers: no headers

      • Payload: no payload

    3. The response should have status code 200 OK and gives the created PDF as payload.

Localization

All localizations implemented in Testify can also be used in the Testify API v2. Every tenant has a default language which normally is English (US). Following languages are available:

Iso-Code

Title

Iso-Code

Title

bs

Bosanski

de-AT

Deutsch

en-GB

English (UK)

en-IN

English (India)

en-US

English (US)

es-MX

Español

fr

Français

nl

Nederlands

pt-BR

Português

ru

русский

zh-CN

中文(中国)

zh-TW

中文(台灣)

Example for creating a custom field with a title in multiple languages

  1. Send POST-Request:

    • Endpoint: {StageBaseUrl}/public/customfields?api-version=2.0

    • HTTP method: POST

    • HTTP headers: API key (secret, Subject, Tenant), Content-Type: application/json, Content-Length

    • Payload:

      • The label contains the respective iso code with the localized content and the default language must always be provided.

  2. The response should have status code 200 OK and gives the custom field key of the newly created custom field.

Attachments

Testobject attachments can be uploaded via the POST /attachments/testobject/{externalId} endpoint and the request body must have following format:

Structure of Testify checklists in Public API v2

Entities

  • Checklist Template: Defines the structure of a checklist with its pages, sections and checks.

  • Checklist Template Revision: Is a revisioning mechanism for checklist templates. A checklist template revision can be in different states (see Enumeration types below).

  • Checklist Instance: Is an instance of a checklist template which is assigned to a certain user or group and where check results are added. A checklist instance can be created from a checklist template´s current (published) revision.

  • Check(Testcase): A checklist can contain 11 different types of checks with different parameters and result values (see details below).

Enumeration types

Many endpoints use enumeration types in their request or response body. In the Testify API v2 they are represented by their integer value. Some important examples are listed below:

Checklist Template Revision State (revisionState)

Checklist Instance State

Testcase Result Value Type

Testcase Plugin Parameter Type

List of Check Types (TestCase Plugins) with result and parameter structure

The result type always refers to the TestCase Result Value Typeand the parameter type always refers to TestCase Plugin Parameter Type (see above, with examples about how the value can look like)

Testify offers 13 different check types (internally called TestCase Plugins). The different check types contain different types of data which are described in this section.

Logical Check - testify_booleantestcase

Calculation Check - testify_calculation_testcase

Date Check - testify_datetestcase

File Upload Check - testify_file_upload_testcase

Multi Select Check - testify_multi_selection_testcase

Numeric Check - testify_numerictestcase

Photo Upload Check - testify_photo_upload_testcase

Single Choice Check - testify_single_choice_testcase

Test Object Selection Check - testify_test_object_selection_testcase

Text Check - testify_texttestcase

Time Check - testify_timetestcase

Geoposition Check - testify_geopositioncheck

Signature Check - testify_signaturecheck

Add check result

Endpoints

There are two endpoints where check results can be added. They differ in whether the checkId or the checkIdentifier ist set. Both - checkId and checkIdentifier- can be queried at the GET /public/checklists/{externalId}/results/flat endpoint. (which is described above)

  1. POST /public/checklists/checkresult: Add check result by checkId.

  2. POST /public/checklists/checkresult/identifier: Add check result by human-readable checkIdentifier.

Request Body for different Check Types