Skip to content

Latest commit

 

History

History
177 lines (126 loc) · 6.71 KB

File metadata and controls

177 lines (126 loc) · 6.71 KB

testgear_api_client.TagsApi

All URIs are relative to http://localhost

Method HTTP request Description
api_v2_tags_get GET /api/v2/tags Get all Tags
api_v2_tags_test_plans_tags_get GET /api/v2/tags/testPlansTags Get all Tags that are used in TestPlans

api_v2_tags_get

[TagShortModel] api_v2_tags_get()

Get all Tags


Use case
User runs method execution
System returns tags (listed in the response example)

Example

  • Api Key Authentication (Bearer or PrivateToken):
import time
import testgear_api_client
from testgear_api_client.api import tags_api
from testgear_api_client.model.problem_details import ProblemDetails
from testgear_api_client.model.tag_short_model import TagShortModel
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 = testgear_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: Bearer or PrivateToken
configuration.api_key['Bearer or PrivateToken'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Bearer or PrivateToken'] = 'Bearer'

# Enter a context with an instance of the API client
with testgear_api_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = tags_api.TagsApi(api_client)

    # example, this endpoint has no required or optional parameters
    try:
        # Get all Tags
        api_response = api_instance.api_v2_tags_get()
        pprint(api_response)
    except testgear_api_client.ApiException as e:
        print("Exception when calling TagsApi->api_v2_tags_get: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

[TagShortModel]

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Successful operation -
401 Unauthorized -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

api_v2_tags_test_plans_tags_get

[TagShortModel] api_v2_tags_test_plans_tags_get()

Get all Tags that are used in TestPlans


Use case
User runs method execution
System returns tags (listed in the response example)

Example

  • Api Key Authentication (Bearer or PrivateToken):
import time
import testgear_api_client
from testgear_api_client.api import tags_api
from testgear_api_client.model.problem_details import ProblemDetails
from testgear_api_client.model.validation_problem_details import ValidationProblemDetails
from testgear_api_client.model.tag_short_model import TagShortModel
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 = testgear_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: Bearer or PrivateToken
configuration.api_key['Bearer or PrivateToken'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['Bearer or PrivateToken'] = 'Bearer'

# Enter a context with an instance of the API client
with testgear_api_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = tags_api.TagsApi(api_client)
    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)

    # example passing only required values which don't have defaults set
    # and optional values
    try:
        # Get all Tags that are used in TestPlans
        api_response = api_instance.api_v2_tags_test_plans_tags_get(skip=skip, take=take, order_by=order_by, search_field=search_field, search_value=search_value)
        pprint(api_response)
    except testgear_api_client.ApiException as e:
        print("Exception when calling TagsApi->api_v2_tags_test_plans_tags_get: %s\n" % e)

Parameters

Name Type Description Notes
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]

Return type

[TagShortModel]

Authorization

[Bearer or PrivateToken](../README.md#Bearer or PrivateToken)

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Successful operation * Pagination-Skip - Skipped amount of items
* Pagination-Take - Taken items
* Pagination-Pages - Expected number of pages
* Pagination-Total-Items - Total count of items
400 <br>orderByStatement must have one '.' and no ',' symbols <br>orderByStatement has invalid length <br>orderByStatement must have uuid as attribute key <br>Search field not found -
401 Unauthorized -

[Back to top] [Back to API list] [Back to Model list] [Back to README]