Tricentis Webhook API

Webhook

OpenAPI Specification

tricentis-webhook-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  description: "[Introduction to qTest API Specification](https://documentation.tricentis.com/qtest/od/en/content/apis/overview/qtest_api_specification.htm) \n[How to use interactive API Doc](https://documentation.tricentis.com/qtest/od/en/content/apis/overview/how_to_use_interactive_api_documentation.htm)\n The bearer token can be found at `[qtestUrl/p/{projectId}/portal/project#tab=resource]` under the API & SDK tab."
  version: v3.0
  title: qTest Manager API Version 3.0 Webhook API
servers:
- url: https://apitryout.qtestnet.com/
tags:
- name: webhook
  description: Webhook
paths:
  /api/v3/webhooks:
    get:
      tags:
      - webhook
      summary: Gets list of all registered webhooks
      description: To retrieve list of all registered webhooks
      operationId: getAllWebhooks
      responses:
        200:
          description: successful operation
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/WebhookVM'
      security:
      - Authorization: []
    post:
      tags:
      - webhook
      summary: Registers a webhook
      description: To register a webhook
      operationId: createWebhook
      responses:
        201:
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WebhookVM'
        400:
          description: Bad Request if missing or invalid input value in body
      security:
      - Authorization: []
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WebhookRequest'
        description: '<em>name (required):</em> name of the webhook


          <em>URL (required):</em> where the callback should be sent


          <em>secretkey (required):</em> secretkey is used to ensure that POST requests sent to the URL are from qTest


          <em>responseType (optional):</em> content-type of the callback message. Allow values: "text" for <b>text/plain</b>, "json" for <b>application/json</b>. Default value is "text"


          <em>events (required):</em> list event(s) to register. Its valid values include


          - testcase_created


          - testcase_updated


          - testcase_deleted


          - testcase_approved


          - testrun_created


          - testrun_updated


          - testrun_deleted


          - testlog_submitted


          - testlog_modified


          - project_created


          - project_updated


          - defect_submitted


          - defect_modified


          - requirement_created


          - requirement_updated


          - requirement_deleted


          - requirement_linked


          - requirement_unlinked


          - defect_linked


          - defect_unlinked


          <em>projectIds (optional):</em> list valid projectid(s) to register. Its valid values include only Active Projects'
        required: true
  /api/v3/webhooks/events:
    get:
      tags:
      - webhook
      summary: Get list of webhook event names
      description: To retrieve list of all available event names for webhook registering
      operationId: getAllEventNames
      responses:
        200:
          description: successful operation
          content:
            application/json:
              schema:
                type: array
                items:
                  type: string
      security:
      - Authorization: []
  /api/v3/webhooks/{webhookId}:
    get:
      tags:
      - webhook
      summary: Gets a webhook
      description: To retrieve details of a registered webhook
      operationId: getWebhookById
      parameters:
      - name: webhookId
        in: path
        description: ID of the webhook
        required: true
        schema:
          type: string
      responses:
        200:
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WebhookVM'
      security:
      - Authorization: []
    put:
      tags:
      - webhook
      summary: Updates a webhook
      description: ''
      operationId: updateWebhook
      parameters:
      - name: webhookId
        in: path
        description: ID of the webhook
        required: true
        schema:
          type: string
      responses:
        200:
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WebhookVM'
      security:
      - Authorization: []
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WebhookRequest'
        description: 'Update webhook''s information


          <em>name:</em> New name of the webhook


          <em>URL:</em> New URL of the webhook


          <em>secretkey:</em> New secret key of the webhook


          <em>responseType:</em> New content-type of the callback message. Allow values: "text" for <b>text/plain</b>, "json" for <b>application/json</b>


          <em>events (required):</em> New list event(s) to register. Its valid values include


          - testcase_created


          - testcase_updated


          - testcase_deleted


          - testcase_approved


          - testrun_created


          - testrun_updated


          - testrun_deleted


          - testlog_submitted


          - testlog_modified


          - project_created


          - project_updated


          - defect_submitted


          - defect_modified


          - requirement_created


          - requirement_updated


          - requirement_deleted


          - requirement_linked


          - requirement_unlinked


          - defect_linked


          - defect_unlinked


          <em>projectIds (optional):</em> list valid projectid(s) to register. Its valid values include only Active Projects'
        required: true
    delete:
      tags:
      - webhook
      summary: Deletes a webhook
      description: To delete a registered webhook
      operationId: deleteWebhookById
      parameters:
      - name: webhookId
        in: path
        description: ID of the webhook
        required: true
        schema:
          type: string
      responses:
        200:
          description: successful operation
          content:
            application/json:
              schema:
                type: object
      security:
      - Authorization: []
components:
  schemas:
    WebhookVM:
      type: object
      properties:
        id:
          type: integer
          format: int64
        name:
          type: string
        url:
          type: string
        events:
          type: array
          items:
            type: string
        createdDate:
          type: string
          format: date-time
        lastModifiedDate:
          type: string
          format: date-time
        secretKey:
          type: string
        responseType:
          type: string
        projectIds:
          type: array
          items:
            type: integer
            format: int64
    WebhookRequest:
      type: object
      properties:
        name:
          type: string
        url:
          type: string
        events:
          type: array
          items:
            type: string
        secretKey:
          type: string
        responseType:
          type: string
        projectIds:
          type: array
          items:
            type: integer
            format: int64
  securitySchemes:
    Authorization:
      type: apiKey
      name: Authorization
      in: header