@testcollab/sdk 3.8.0 → 3.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.openapi-generator/FILES +16 -0
- package/dist/esm/models/QacConversationFeedback.d.ts +93 -0
- package/dist/esm/models/QacConversationFeedback.js +80 -0
- package/dist/esm/models/QacConversationFeedbackPayload.d.ts +62 -0
- package/dist/esm/models/QacConversationFeedbackPayload.js +63 -0
- package/dist/esm/models/QacConversationMessage.d.ts +135 -0
- package/dist/esm/models/QacConversationMessage.js +105 -0
- package/dist/esm/models/QacConversationMessagePayload.d.ts +88 -0
- package/dist/esm/models/QacConversationMessagePayload.js +71 -0
- package/dist/esm/models/QacConversationThread.d.ts +130 -0
- package/dist/esm/models/QacConversationThread.js +90 -0
- package/dist/esm/models/QacConversationThreadPayload.d.ts +81 -0
- package/dist/esm/models/QacConversationThreadPayload.js +65 -0
- package/dist/esm/models/QacConversationThreadWithMessages.d.ts +40 -0
- package/dist/esm/models/QacConversationThreadWithMessages.js +45 -0
- package/dist/esm/models/QacConversationTokenUsage.d.ts +44 -0
- package/dist/esm/models/QacConversationTokenUsage.js +45 -0
- package/dist/esm/models/SuiteTree.d.ts +0 -6
- package/dist/esm/models/SuiteTree.js +0 -4
- package/dist/esm/models/TrainingArtifactPayload.d.ts +4 -4
- package/dist/esm/models/TrainingArtifactPayload.js +4 -4
- package/dist/esm/models/TrainingSession.d.ts +1 -0
- package/dist/esm/models/TrainingSession.js +2 -1
- package/dist/esm/models/index.d.ts +8 -0
- package/dist/esm/models/index.js +8 -0
- package/dist/models/QacConversationFeedback.d.ts +93 -0
- package/dist/models/QacConversationFeedback.js +88 -0
- package/dist/models/QacConversationFeedbackPayload.d.ts +62 -0
- package/dist/models/QacConversationFeedbackPayload.js +71 -0
- package/dist/models/QacConversationMessage.d.ts +135 -0
- package/dist/models/QacConversationMessage.js +113 -0
- package/dist/models/QacConversationMessagePayload.d.ts +88 -0
- package/dist/models/QacConversationMessagePayload.js +79 -0
- package/dist/models/QacConversationThread.d.ts +130 -0
- package/dist/models/QacConversationThread.js +98 -0
- package/dist/models/QacConversationThreadPayload.d.ts +81 -0
- package/dist/models/QacConversationThreadPayload.js +73 -0
- package/dist/models/QacConversationThreadWithMessages.d.ts +40 -0
- package/dist/models/QacConversationThreadWithMessages.js +52 -0
- package/dist/models/QacConversationTokenUsage.d.ts +44 -0
- package/dist/models/QacConversationTokenUsage.js +52 -0
- package/dist/models/SuiteTree.d.ts +0 -6
- package/dist/models/SuiteTree.js +0 -4
- package/dist/models/TrainingArtifactPayload.d.ts +4 -4
- package/dist/models/TrainingArtifactPayload.js +4 -4
- package/dist/models/TrainingSession.d.ts +1 -0
- package/dist/models/TrainingSession.js +2 -1
- package/dist/models/index.d.ts +8 -0
- package/dist/models/index.js +8 -0
- package/docs/QacConversationFeedback.md +48 -0
- package/docs/QacConversationFeedbackPayload.md +38 -0
- package/docs/QacConversationMessage.md +58 -0
- package/docs/QacConversationMessagePayload.md +46 -0
- package/docs/QacConversationThread.md +62 -0
- package/docs/QacConversationThreadPayload.md +46 -0
- package/docs/QacConversationThreadWithMessages.md +36 -0
- package/docs/QacConversationTokenUsage.md +38 -0
- package/docs/SuiteTree.md +0 -2
- package/docs/TrainingArtifactPayload.md +2 -2
- package/package.json +1 -1
- package/src/models/QacConversationFeedback.ts +155 -0
- package/src/models/QacConversationFeedbackPayload.ts +104 -0
- package/src/models/QacConversationMessage.ts +222 -0
- package/src/models/QacConversationMessagePayload.ts +136 -0
- package/src/models/QacConversationThread.ts +203 -0
- package/src/models/QacConversationThreadPayload.ts +127 -0
- package/src/models/QacConversationThreadWithMessages.ts +88 -0
- package/src/models/QacConversationTokenUsage.ts +81 -0
- package/src/models/SuiteTree.ts +0 -9
- package/src/models/TrainingArtifactPayload.ts +8 -8
- package/src/models/TrainingSession.ts +2 -1
- package/src/models/index.ts +8 -0
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
|
|
2
|
+
# QacConversationThread
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type
|
|
8
|
+
------------ | -------------
|
|
9
|
+
`id` | number
|
|
10
|
+
`project` | number
|
|
11
|
+
`company` | number
|
|
12
|
+
`createdBy` | [UserMinified](UserMinified.md)
|
|
13
|
+
`title` | string
|
|
14
|
+
`status` | string
|
|
15
|
+
`sourceUrl` | string
|
|
16
|
+
`contextRefs` | { [key: string]: any; }
|
|
17
|
+
`messagesCount` | number
|
|
18
|
+
`lastMessageAt` | string
|
|
19
|
+
`lastMessagePreview` | string
|
|
20
|
+
`pinned` | boolean
|
|
21
|
+
`metadata` | { [key: string]: any; }
|
|
22
|
+
`createdAt` | string
|
|
23
|
+
`updatedAt` | string
|
|
24
|
+
|
|
25
|
+
## Example
|
|
26
|
+
|
|
27
|
+
```typescript
|
|
28
|
+
import type { QacConversationThread } from '@testcollab/sdk'
|
|
29
|
+
|
|
30
|
+
// TODO: Update the object below with actual values
|
|
31
|
+
const example = {
|
|
32
|
+
"id": 45,
|
|
33
|
+
"project": 12,
|
|
34
|
+
"company": 3,
|
|
35
|
+
"createdBy": null,
|
|
36
|
+
"title": Checkout regression draft,
|
|
37
|
+
"status": open,
|
|
38
|
+
"sourceUrl": https://app.testcollab.io/project/12/test_cases/101,
|
|
39
|
+
"contextRefs": null,
|
|
40
|
+
"messagesCount": 14,
|
|
41
|
+
"lastMessageAt": 2019-04-30T17:11:24.000Z,
|
|
42
|
+
"lastMessagePreview": Drafted 5 test cases for checkout happy path.,
|
|
43
|
+
"pinned": false,
|
|
44
|
+
"metadata": null,
|
|
45
|
+
"createdAt": 2019-04-30T17:11:24.000Z,
|
|
46
|
+
"updatedAt": 2019-04-30T17:11:24.000Z,
|
|
47
|
+
} satisfies QacConversationThread
|
|
48
|
+
|
|
49
|
+
console.log(example)
|
|
50
|
+
|
|
51
|
+
// Convert the instance to a JSON string
|
|
52
|
+
const exampleJSON: string = JSON.stringify(example)
|
|
53
|
+
console.log(exampleJSON)
|
|
54
|
+
|
|
55
|
+
// Parse the JSON string back to an object
|
|
56
|
+
const exampleParsed = JSON.parse(exampleJSON) as QacConversationThread
|
|
57
|
+
console.log(exampleParsed)
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
61
|
+
|
|
62
|
+
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
|
|
2
|
+
# QacConversationThreadPayload
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type
|
|
8
|
+
------------ | -------------
|
|
9
|
+
`project` | number
|
|
10
|
+
`company` | number
|
|
11
|
+
`title` | string
|
|
12
|
+
`status` | string
|
|
13
|
+
`sourceUrl` | string
|
|
14
|
+
`contextRefs` | { [key: string]: any; }
|
|
15
|
+
`metadata` | { [key: string]: any; }
|
|
16
|
+
|
|
17
|
+
## Example
|
|
18
|
+
|
|
19
|
+
```typescript
|
|
20
|
+
import type { QacConversationThreadPayload } from '@testcollab/sdk'
|
|
21
|
+
|
|
22
|
+
// TODO: Update the object below with actual values
|
|
23
|
+
const example = {
|
|
24
|
+
"project": 12,
|
|
25
|
+
"company": 3,
|
|
26
|
+
"title": Checkout regression draft,
|
|
27
|
+
"status": open,
|
|
28
|
+
"sourceUrl": https://app.testcollab.io/project/12/test_cases/101,
|
|
29
|
+
"contextRefs": null,
|
|
30
|
+
"metadata": null,
|
|
31
|
+
} satisfies QacConversationThreadPayload
|
|
32
|
+
|
|
33
|
+
console.log(example)
|
|
34
|
+
|
|
35
|
+
// Convert the instance to a JSON string
|
|
36
|
+
const exampleJSON: string = JSON.stringify(example)
|
|
37
|
+
console.log(exampleJSON)
|
|
38
|
+
|
|
39
|
+
// Parse the JSON string back to an object
|
|
40
|
+
const exampleParsed = JSON.parse(exampleJSON) as QacConversationThreadPayload
|
|
41
|
+
console.log(exampleParsed)
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
45
|
+
|
|
46
|
+
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
|
|
2
|
+
# QacConversationThreadWithMessages
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type
|
|
8
|
+
------------ | -------------
|
|
9
|
+
`thread` | [QacConversationThread](QacConversationThread.md)
|
|
10
|
+
`messages` | [Array<QacConversationMessage>](QacConversationMessage.md)
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```typescript
|
|
15
|
+
import type { QacConversationThreadWithMessages } from '@testcollab/sdk'
|
|
16
|
+
|
|
17
|
+
// TODO: Update the object below with actual values
|
|
18
|
+
const example = {
|
|
19
|
+
"thread": null,
|
|
20
|
+
"messages": null,
|
|
21
|
+
} satisfies QacConversationThreadWithMessages
|
|
22
|
+
|
|
23
|
+
console.log(example)
|
|
24
|
+
|
|
25
|
+
// Convert the instance to a JSON string
|
|
26
|
+
const exampleJSON: string = JSON.stringify(example)
|
|
27
|
+
console.log(exampleJSON)
|
|
28
|
+
|
|
29
|
+
// Parse the JSON string back to an object
|
|
30
|
+
const exampleParsed = JSON.parse(exampleJSON) as QacConversationThreadWithMessages
|
|
31
|
+
console.log(exampleParsed)
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
35
|
+
|
|
36
|
+
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
|
|
2
|
+
# QacConversationTokenUsage
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type
|
|
8
|
+
------------ | -------------
|
|
9
|
+
`promptTokens` | number
|
|
10
|
+
`completionTokens` | number
|
|
11
|
+
`totalTokens` | number
|
|
12
|
+
|
|
13
|
+
## Example
|
|
14
|
+
|
|
15
|
+
```typescript
|
|
16
|
+
import type { QacConversationTokenUsage } from '@testcollab/sdk'
|
|
17
|
+
|
|
18
|
+
// TODO: Update the object below with actual values
|
|
19
|
+
const example = {
|
|
20
|
+
"promptTokens": 512,
|
|
21
|
+
"completionTokens": 1024,
|
|
22
|
+
"totalTokens": 1536,
|
|
23
|
+
} satisfies QacConversationTokenUsage
|
|
24
|
+
|
|
25
|
+
console.log(example)
|
|
26
|
+
|
|
27
|
+
// Convert the instance to a JSON string
|
|
28
|
+
const exampleJSON: string = JSON.stringify(example)
|
|
29
|
+
console.log(exampleJSON)
|
|
30
|
+
|
|
31
|
+
// Parse the JSON string back to an object
|
|
32
|
+
const exampleParsed = JSON.parse(exampleJSON) as QacConversationTokenUsage
|
|
33
|
+
console.log(exampleParsed)
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
37
|
+
|
|
38
|
+
|
package/docs/SuiteTree.md
CHANGED
|
@@ -8,7 +8,6 @@ Name | Type
|
|
|
8
8
|
------------ | -------------
|
|
9
9
|
`id` | number
|
|
10
10
|
`title` | string
|
|
11
|
-
`description` | string
|
|
12
11
|
`suitecount` | number
|
|
13
12
|
`createdBy` | number
|
|
14
13
|
`testcasecount` | number
|
|
@@ -28,7 +27,6 @@ import type { SuiteTree } from '@testcollab/sdk'
|
|
|
28
27
|
const example = {
|
|
29
28
|
"id": 1,
|
|
30
29
|
"title": Suite 1,
|
|
31
|
-
"description": Used for abc, def...,
|
|
32
30
|
"suitecount": 23,
|
|
33
31
|
"createdBy": 23,
|
|
34
32
|
"testcasecount": 23,
|
|
@@ -15,10 +15,10 @@ Name | Type
|
|
|
15
15
|
`subStepTxt` | string
|
|
16
16
|
`imgFull` | string
|
|
17
17
|
`imgThumb` | string
|
|
18
|
-
`timestamp` |
|
|
18
|
+
`timestamp` | string
|
|
19
19
|
`browserLocation` | string
|
|
20
20
|
`otherInfoJson` | { [key: string]: any; }
|
|
21
|
-
`created` |
|
|
21
|
+
`created` | string
|
|
22
22
|
|
|
23
23
|
## Example
|
|
24
24
|
|
package/package.json
CHANGED
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* TC API
|
|
5
|
+
* TestCollab is a test management tool that helps development teams carry out testing effectively and avoid failures. # Introduction This is an API documentation for TestCollab 2. # Authentication TestCollab supports two forms of authentication: - An <b>API token</b> is required to make API calls. The token can be generated from user\'s profile; to obtain it login to your TestCollab account and go to [\'My Profile Settings\'](https://testcollab.io/my_profile) and switch to API Token tab. Click on \"Generate new API token\", Once the token is generated it can be sent as a query parameter for the API calls made - https://api.testcollab.io/projects?token=<generated-API-token> - <b>Bearer authentication</b> (also called token authentication) is an HTTP authentication scheme that involves security tokens called bearer tokens. You can generate bearer auth token using [Login](#operation/login) API. Send this token as the Authorization header while making requests to protected resources: `Authorization: Bearer <token>` For making API calls, we recommend using the <b>API token</b> generated from user profile page as it won\'t affect the on-going user session and will be available until it is revoked by the user who generated it. # Error Handling Error responses - `Not Found` - Error is sent when requested resource is not available. - `Unauthorized - invalid token` - Error is sent when API token sent with the request is invalid or revoked. Error contains status code 401 - `Forbidden` - Error is sent when logged in user is not part of the company, project or his role does not allow to complete given action. Response consist of 403 status code and more information is given in error message.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.3.1
|
|
8
|
+
* Contact: support@testcollab.com
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { UserMinified } from './UserMinified';
|
|
17
|
+
import {
|
|
18
|
+
UserMinifiedFromJSON,
|
|
19
|
+
UserMinifiedFromJSONTyped,
|
|
20
|
+
UserMinifiedToJSON,
|
|
21
|
+
UserMinifiedToJSONTyped,
|
|
22
|
+
} from './UserMinified';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface QacConversationFeedback
|
|
28
|
+
*/
|
|
29
|
+
export interface QacConversationFeedback {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof QacConversationFeedback
|
|
34
|
+
*/
|
|
35
|
+
id: number;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {number}
|
|
39
|
+
* @memberof QacConversationFeedback
|
|
40
|
+
*/
|
|
41
|
+
message: number;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {UserMinified}
|
|
45
|
+
* @memberof QacConversationFeedback
|
|
46
|
+
*/
|
|
47
|
+
givenBy?: UserMinified;
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
* @type {string}
|
|
51
|
+
* @memberof QacConversationFeedback
|
|
52
|
+
*/
|
|
53
|
+
rating: QacConversationFeedbackRatingEnum;
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* @type {string}
|
|
57
|
+
* @memberof QacConversationFeedback
|
|
58
|
+
*/
|
|
59
|
+
reason?: QacConversationFeedbackReasonEnum;
|
|
60
|
+
/**
|
|
61
|
+
*
|
|
62
|
+
* @type {string}
|
|
63
|
+
* @memberof QacConversationFeedback
|
|
64
|
+
*/
|
|
65
|
+
comment?: string;
|
|
66
|
+
/**
|
|
67
|
+
* Time when the activity was performed
|
|
68
|
+
* @type {string}
|
|
69
|
+
* @memberof QacConversationFeedback
|
|
70
|
+
*/
|
|
71
|
+
createdAt: string;
|
|
72
|
+
/**
|
|
73
|
+
* Time when the activity was performed
|
|
74
|
+
* @type {string}
|
|
75
|
+
* @memberof QacConversationFeedback
|
|
76
|
+
*/
|
|
77
|
+
updatedAt?: string;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* @export
|
|
83
|
+
*/
|
|
84
|
+
export const QacConversationFeedbackRatingEnum = {
|
|
85
|
+
Up: 'up',
|
|
86
|
+
Down: 'down'
|
|
87
|
+
} as const;
|
|
88
|
+
export type QacConversationFeedbackRatingEnum = typeof QacConversationFeedbackRatingEnum[keyof typeof QacConversationFeedbackRatingEnum];
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* @export
|
|
92
|
+
*/
|
|
93
|
+
export const QacConversationFeedbackReasonEnum = {
|
|
94
|
+
Irrelevant: 'irrelevant',
|
|
95
|
+
Incorrect: 'incorrect',
|
|
96
|
+
Offensive: 'offensive',
|
|
97
|
+
Other: 'other'
|
|
98
|
+
} as const;
|
|
99
|
+
export type QacConversationFeedbackReasonEnum = typeof QacConversationFeedbackReasonEnum[keyof typeof QacConversationFeedbackReasonEnum];
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* Check if a given object implements the QacConversationFeedback interface.
|
|
104
|
+
*/
|
|
105
|
+
export function instanceOfQacConversationFeedback(value: object): value is QacConversationFeedback {
|
|
106
|
+
if (!('id' in value) || value['id'] === undefined) return false;
|
|
107
|
+
if (!('message' in value) || value['message'] === undefined) return false;
|
|
108
|
+
if (!('rating' in value) || value['rating'] === undefined) return false;
|
|
109
|
+
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
|
|
110
|
+
return true;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export function QacConversationFeedbackFromJSON(json: any): QacConversationFeedback {
|
|
114
|
+
return QacConversationFeedbackFromJSONTyped(json, false);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export function QacConversationFeedbackFromJSONTyped(json: any, ignoreDiscriminator: boolean): QacConversationFeedback {
|
|
118
|
+
if (json == null) {
|
|
119
|
+
return json;
|
|
120
|
+
}
|
|
121
|
+
return {
|
|
122
|
+
|
|
123
|
+
'id': json['id'],
|
|
124
|
+
'message': json['message'],
|
|
125
|
+
'givenBy': json['given_by'] == null ? undefined : UserMinifiedFromJSON(json['given_by']),
|
|
126
|
+
'rating': json['rating'],
|
|
127
|
+
'reason': json['reason'] == null ? undefined : json['reason'],
|
|
128
|
+
'comment': json['comment'] == null ? undefined : json['comment'],
|
|
129
|
+
'createdAt': json['created_at'],
|
|
130
|
+
'updatedAt': json['updated_at'] == null ? undefined : json['updated_at'],
|
|
131
|
+
};
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
export function QacConversationFeedbackToJSON(json: any): QacConversationFeedback {
|
|
135
|
+
return QacConversationFeedbackToJSONTyped(json, false);
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
export function QacConversationFeedbackToJSONTyped(value?: QacConversationFeedback | null, ignoreDiscriminator: boolean = false): any {
|
|
139
|
+
if (value == null) {
|
|
140
|
+
return value;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
return {
|
|
144
|
+
|
|
145
|
+
'id': value['id'],
|
|
146
|
+
'message': value['message'],
|
|
147
|
+
'given_by': UserMinifiedToJSON(value['givenBy']),
|
|
148
|
+
'rating': value['rating'],
|
|
149
|
+
'reason': value['reason'],
|
|
150
|
+
'comment': value['comment'],
|
|
151
|
+
'created_at': value['createdAt'],
|
|
152
|
+
'updated_at': value['updatedAt'],
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* TC API
|
|
5
|
+
* TestCollab is a test management tool that helps development teams carry out testing effectively and avoid failures. # Introduction This is an API documentation for TestCollab 2. # Authentication TestCollab supports two forms of authentication: - An <b>API token</b> is required to make API calls. The token can be generated from user\'s profile; to obtain it login to your TestCollab account and go to [\'My Profile Settings\'](https://testcollab.io/my_profile) and switch to API Token tab. Click on \"Generate new API token\", Once the token is generated it can be sent as a query parameter for the API calls made - https://api.testcollab.io/projects?token=<generated-API-token> - <b>Bearer authentication</b> (also called token authentication) is an HTTP authentication scheme that involves security tokens called bearer tokens. You can generate bearer auth token using [Login](#operation/login) API. Send this token as the Authorization header while making requests to protected resources: `Authorization: Bearer <token>` For making API calls, we recommend using the <b>API token</b> generated from user profile page as it won\'t affect the on-going user session and will be available until it is revoked by the user who generated it. # Error Handling Error responses - `Not Found` - Error is sent when requested resource is not available. - `Unauthorized - invalid token` - Error is sent when API token sent with the request is invalid or revoked. Error contains status code 401 - `Forbidden` - Error is sent when logged in user is not part of the company, project or his role does not allow to complete given action. Response consist of 403 status code and more information is given in error message.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 2.3.1
|
|
8
|
+
* Contact: support@testcollab.com
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface QacConversationFeedbackPayload
|
|
20
|
+
*/
|
|
21
|
+
export interface QacConversationFeedbackPayload {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof QacConversationFeedbackPayload
|
|
26
|
+
*/
|
|
27
|
+
rating: QacConversationFeedbackPayloadRatingEnum;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof QacConversationFeedbackPayload
|
|
32
|
+
*/
|
|
33
|
+
reason?: QacConversationFeedbackPayloadReasonEnum;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof QacConversationFeedbackPayload
|
|
38
|
+
*/
|
|
39
|
+
comment?: string;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* @export
|
|
45
|
+
*/
|
|
46
|
+
export const QacConversationFeedbackPayloadRatingEnum = {
|
|
47
|
+
Up: 'up',
|
|
48
|
+
Down: 'down'
|
|
49
|
+
} as const;
|
|
50
|
+
export type QacConversationFeedbackPayloadRatingEnum = typeof QacConversationFeedbackPayloadRatingEnum[keyof typeof QacConversationFeedbackPayloadRatingEnum];
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* @export
|
|
54
|
+
*/
|
|
55
|
+
export const QacConversationFeedbackPayloadReasonEnum = {
|
|
56
|
+
Irrelevant: 'irrelevant',
|
|
57
|
+
Incorrect: 'incorrect',
|
|
58
|
+
Offensive: 'offensive',
|
|
59
|
+
Other: 'other'
|
|
60
|
+
} as const;
|
|
61
|
+
export type QacConversationFeedbackPayloadReasonEnum = typeof QacConversationFeedbackPayloadReasonEnum[keyof typeof QacConversationFeedbackPayloadReasonEnum];
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Check if a given object implements the QacConversationFeedbackPayload interface.
|
|
66
|
+
*/
|
|
67
|
+
export function instanceOfQacConversationFeedbackPayload(value: object): value is QacConversationFeedbackPayload {
|
|
68
|
+
if (!('rating' in value) || value['rating'] === undefined) return false;
|
|
69
|
+
return true;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function QacConversationFeedbackPayloadFromJSON(json: any): QacConversationFeedbackPayload {
|
|
73
|
+
return QacConversationFeedbackPayloadFromJSONTyped(json, false);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export function QacConversationFeedbackPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): QacConversationFeedbackPayload {
|
|
77
|
+
if (json == null) {
|
|
78
|
+
return json;
|
|
79
|
+
}
|
|
80
|
+
return {
|
|
81
|
+
|
|
82
|
+
'rating': json['rating'],
|
|
83
|
+
'reason': json['reason'] == null ? undefined : json['reason'],
|
|
84
|
+
'comment': json['comment'] == null ? undefined : json['comment'],
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export function QacConversationFeedbackPayloadToJSON(json: any): QacConversationFeedbackPayload {
|
|
89
|
+
return QacConversationFeedbackPayloadToJSONTyped(json, false);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export function QacConversationFeedbackPayloadToJSONTyped(value?: QacConversationFeedbackPayload | null, ignoreDiscriminator: boolean = false): any {
|
|
93
|
+
if (value == null) {
|
|
94
|
+
return value;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
return {
|
|
98
|
+
|
|
99
|
+
'rating': value['rating'],
|
|
100
|
+
'reason': value['reason'],
|
|
101
|
+
'comment': value['comment'],
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
|