All URIs are relative to http://localhost
| Method | HTTP request | Description |
|---|---|---|
| create_projects_attribute | POST /api/v2/projects/{projectId}/attributes | Create project attribute |
| delete_projects_attribute | DELETE /api/v2/projects/{projectId}/attributes/{attributeId} | Delete project attribute |
| get_attribute_by_project_id | GET /api/v2/projects/{projectId}/attributes/{attributeId} | Get project attribute |
| get_attributes_by_project_id | GET /api/v2/projects/{projectId}/attributes | Get project attributes |
| search_attributes_in_project | POST /api/v2/projects/{projectId}/attributes/search | Search for attributes used in the project |
| update_projects_attribute | PUT /api/v2/projects/{projectId}/attributes | Edit attribute of the project |
CustomAttributeModel create_projects_attribute(project_id)
Create project attribute
Use case User sets attribute parameters (listed in request example) and runs method execution System search project System creates attribute and relates it to the project System returns project attribute properties (example listed in response parameters)
- Api Key Authentication (PrivateToken):
- Api Key Authentication (Identity.Application):
import time
import testit_api_client
from testit_api_client.api import project_attributes_api
from testit_api_client.model.problem_details import ProblemDetails
from testit_api_client.model.create_projects_attribute_request import CreateProjectsAttributeRequest
from testit_api_client.model.custom_attribute_model import CustomAttributeModel
from testit_api_client.model.validation_problem_details import ValidationProblemDetails
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = testit_api_client.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: PrivateToken
configuration.api_key['PrivateToken'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['PrivateToken'] = 'Bearer'
# Configure API key authorization: Identity.Application
configuration.api_key['Identity.Application'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Identity.Application'] = 'Bearer'
# Enter a context with an instance of the API client
with testit_api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = project_attributes_api.ProjectAttributesApi(api_client)
project_id = "projectId_example" # str | Project internal (UUID) or global (integer) identifier
create_projects_attribute_request = CreateProjectsAttributeRequest(None) # CreateProjectsAttributeRequest | (optional)
# example passing only required values which don't have defaults set
try:
# Create project attribute
api_response = api_instance.create_projects_attribute(project_id)
pprint(api_response)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->create_projects_attribute: %s\n" % e)
# example passing only required values which don't have defaults set
# and optional values
try:
# Create project attribute
api_response = api_instance.create_projects_attribute(project_id, create_projects_attribute_request=create_projects_attribute_request)
pprint(api_response)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->create_projects_attribute: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project internal (UUID) or global (integer) identifier | |
| create_projects_attribute_request | CreateProjectsAttributeRequest | [optional] |
PrivateToken, Identity.Application
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 201 | Created | - |
| 400 | - Attribute is `null` - Priority is invalid - Attribute with `Options` type must have an options - ID is not `null` - Option ID is not `null` | - |
| 401 | Unauthorized | - |
| 403 | Update permission for project settings is required | - |
| 404 | Project with provided ID was not found | - |
| 409 | `CustomAttribute.Name` or `CustomAttribute.Id` are not unique in attributes schemes `CustomAttributeOptionModel.Id` or `CustomAttributeOptionModel.Value` are not unique in `attributesScheme.Options` | - |
| 422 | Cannot add new attribute from template which is in use | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
delete_projects_attribute(project_id, attribute_id)
Delete project attribute
Use case User sets project identifier and runs method execution User sets attribute identifier User runs method execution System search project System search and delete attribute System returns no content response
- Api Key Authentication (PrivateToken):
- Api Key Authentication (Identity.Application):
import time
import testit_api_client
from testit_api_client.api import project_attributes_api
from testit_api_client.model.problem_details import ProblemDetails
from testit_api_client.model.validation_problem_details import ValidationProblemDetails
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = testit_api_client.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: PrivateToken
configuration.api_key['PrivateToken'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['PrivateToken'] = 'Bearer'
# Configure API key authorization: Identity.Application
configuration.api_key['Identity.Application'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Identity.Application'] = 'Bearer'
# Enter a context with an instance of the API client
with testit_api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = project_attributes_api.ProjectAttributesApi(api_client)
project_id = "projectId_example" # str | Project internal (UUID) or global (integer) identifier
attribute_id = "attributeId_example" # str | Project attribute internal (UUID)
# example passing only required values which don't have defaults set
try:
# Delete project attribute
api_instance.delete_projects_attribute(project_id, attribute_id)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->delete_projects_attribute: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project internal (UUID) or global (integer) identifier | |
| attribute_id | str | Project attribute internal (UUID) |
void (empty response body)
PrivateToken, Identity.Application
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 204 | Successful operation | - |
| 400 | - Project ID is invalid - Project attribute ID is invalid - Attribute is empty | - |
| 401 | Unauthorized | - |
| 403 | Update permission for project settings is required | - |
| 404 | Project with provided ID was not found | - |
| 409 | Conflict | - |
| 422 | Unprocessable Entity | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
CustomAttributeModel get_attribute_by_project_id(project_id, attribute_id)
Get project attribute
Use case User sets project internal or global identifier User sets project attribute identifier User runs method execution System search project System search project attribute System returns project attribute (listed in response model)
- Api Key Authentication (PrivateToken):
- Api Key Authentication (Identity.Application):
import time
import testit_api_client
from testit_api_client.api import project_attributes_api
from testit_api_client.model.problem_details import ProblemDetails
from testit_api_client.model.custom_attribute_model import CustomAttributeModel
from testit_api_client.model.validation_problem_details import ValidationProblemDetails
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = testit_api_client.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: PrivateToken
configuration.api_key['PrivateToken'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['PrivateToken'] = 'Bearer'
# Configure API key authorization: Identity.Application
configuration.api_key['Identity.Application'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Identity.Application'] = 'Bearer'
# Enter a context with an instance of the API client
with testit_api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = project_attributes_api.ProjectAttributesApi(api_client)
project_id = "projectId_example" # str | Project internal (UUID) or global (integer) identifier
attribute_id = "attributeId_example" # str | Project attribute internal (UUID) or global (integer) identifier
# example passing only required values which don't have defaults set
try:
# Get project attribute
api_response = api_instance.get_attribute_by_project_id(project_id, attribute_id)
pprint(api_response)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->get_attribute_by_project_id: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project internal (UUID) or global (integer) identifier | |
| attribute_id | str | Project attribute internal (UUID) or global (integer) identifier |
PrivateToken, Identity.Application
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Read permission for test library is required | - |
| 404 | - Project with provided ID was not found - Project attribute with provided ID was not found | - |
| 409 | Conflict | - |
| 422 | Unprocessable Entity | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[CustomAttributeModel] get_attributes_by_project_id(project_id)
Get project attributes
Use case User sets project internal or global identifier [Optional] User sets isDeleted field value User runs method execution System search project [Optional] If User sets isDeleted field value as true, System search all deleted attributes related to project [Optional] If User sets isDeleted field value as false, System search all attributes related to project which are not deleted [Optional] If User did not set isDeleted field value, System search all attributes related to project System returns array of found attributes (listed in response model)
- Api Key Authentication (PrivateToken):
- Api Key Authentication (Identity.Application):
import time
import testit_api_client
from testit_api_client.api import project_attributes_api
from testit_api_client.model.problem_details import ProblemDetails
from testit_api_client.model.custom_attribute_model import CustomAttributeModel
from testit_api_client.model.deletion_state import DeletionState
from testit_api_client.model.validation_problem_details import ValidationProblemDetails
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = testit_api_client.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: PrivateToken
configuration.api_key['PrivateToken'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['PrivateToken'] = 'Bearer'
# Configure API key authorization: Identity.Application
configuration.api_key['Identity.Application'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Identity.Application'] = 'Bearer'
# Enter a context with an instance of the API client
with testit_api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = project_attributes_api.ProjectAttributesApi(api_client)
project_id = "projectId_example" # str | Project internal (UUID) or global (integer) identifier
is_deleted = None # DeletionState | (optional)
# example passing only required values which don't have defaults set
try:
# Get project attributes
api_response = api_instance.get_attributes_by_project_id(project_id)
pprint(api_response)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->get_attributes_by_project_id: %s\n" % e)
# example passing only required values which don't have defaults set
# and optional values
try:
# Get project attributes
api_response = api_instance.get_attributes_by_project_id(project_id, is_deleted=is_deleted)
pprint(api_response)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->get_attributes_by_project_id: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Project internal (UUID) or global (integer) identifier | |
| is_deleted | DeletionState | [optional] |
PrivateToken, Identity.Application
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Read permission for test library is required | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 422 | Unprocessable Entity | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[CustomAttributeGetModel] search_attributes_in_project(project_id)
Search for attributes used in the project
- Api Key Authentication (PrivateToken):
- Api Key Authentication (Identity.Application):
import time
import testit_api_client
from testit_api_client.api import project_attributes_api
from testit_api_client.model.custom_attribute_get_model import CustomAttributeGetModel
from testit_api_client.model.problem_details import ProblemDetails
from testit_api_client.model.search_attributes_in_project_request import SearchAttributesInProjectRequest
from testit_api_client.model.validation_problem_details import ValidationProblemDetails
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = testit_api_client.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: PrivateToken
configuration.api_key['PrivateToken'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['PrivateToken'] = 'Bearer'
# Configure API key authorization: Identity.Application
configuration.api_key['Identity.Application'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Identity.Application'] = 'Bearer'
# Enter a context with an instance of the API client
with testit_api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = project_attributes_api.ProjectAttributesApi(api_client)
project_id = "projectId_example" # str | Unique or global project ID
skip = 1 # int | Amount of items to be skipped (offset) (optional)
take = 1 # int | Amount of items to be taken (limit) (optional)
order_by = "OrderBy_example" # str | SQL-like ORDER BY statement (column1 ASC|DESC , column2 ASC|DESC) (optional)
search_field = "SearchField_example" # str | Property name for searching (optional)
search_value = "SearchValue_example" # str | Value for searching (optional)
search_attributes_in_project_request = SearchAttributesInProjectRequest(None) # SearchAttributesInProjectRequest | (optional)
# example passing only required values which don't have defaults set
try:
# Search for attributes used in the project
api_response = api_instance.search_attributes_in_project(project_id)
pprint(api_response)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->search_attributes_in_project: %s\n" % e)
# example passing only required values which don't have defaults set
# and optional values
try:
# Search for attributes used in the project
api_response = api_instance.search_attributes_in_project(project_id, skip=skip, take=take, order_by=order_by, search_field=search_field, search_value=search_value, search_attributes_in_project_request=search_attributes_in_project_request)
pprint(api_response)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->search_attributes_in_project: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Unique or global project ID | |
| skip | int | Amount of items to be skipped (offset) | [optional] |
| take | int | Amount of items to be taken (limit) | [optional] |
| order_by | str | SQL-like ORDER BY statement (column1 ASC | DESC , column2 ASC |
| search_field | str | Property name for searching | [optional] |
| search_value | str | Value for searching | [optional] |
| search_attributes_in_project_request | SearchAttributesInProjectRequest | [optional] |
PrivateToken, Identity.Application
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | OK | * Pagination-Skip - Skipped amount of items * Pagination-Take - Taken items * Pagination-Pages - Expected number of pages * Pagination-Total-Items - Total count of items |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Read permission for project is required | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 422 | Unprocessable Entity | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
update_projects_attribute(project_id)
Edit attribute of the project
- Api Key Authentication (PrivateToken):
- Api Key Authentication (Identity.Application):
import time
import testit_api_client
from testit_api_client.api import project_attributes_api
from testit_api_client.model.update_projects_attribute_request import UpdateProjectsAttributeRequest
from testit_api_client.model.problem_details import ProblemDetails
from testit_api_client.model.validation_problem_details import ValidationProblemDetails
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = testit_api_client.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: PrivateToken
configuration.api_key['PrivateToken'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['PrivateToken'] = 'Bearer'
# Configure API key authorization: Identity.Application
configuration.api_key['Identity.Application'] = 'YOUR_API_KEY'
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Identity.Application'] = 'Bearer'
# Enter a context with an instance of the API client
with testit_api_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = project_attributes_api.ProjectAttributesApi(api_client)
project_id = "projectId_example" # str | Unique or global project ID
update_projects_attribute_request = UpdateProjectsAttributeRequest(None) # UpdateProjectsAttributeRequest | (optional)
# example passing only required values which don't have defaults set
try:
# Edit attribute of the project
api_instance.update_projects_attribute(project_id)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->update_projects_attribute: %s\n" % e)
# example passing only required values which don't have defaults set
# and optional values
try:
# Edit attribute of the project
api_instance.update_projects_attribute(project_id, update_projects_attribute_request=update_projects_attribute_request)
except testit_api_client.ApiException as e:
print("Exception when calling ProjectAttributesApi->update_projects_attribute: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| project_id | str | Unique or global project ID | |
| update_projects_attribute_request | UpdateProjectsAttributeRequest | [optional] |
void (empty response body)
PrivateToken, Identity.Application
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 204 | No Content | - |
| 400 | Bad Request | - |
| 401 | Unauthorized | - |
| 403 | Update permission for project settings is required | - |
| 404 | Not Found | - |
| 409 | Conflict | - |
| 422 | Unprocessable Entity | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]