Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions generated/.openapi-generator/FILES
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.gitignore
README.md
docs/AccountMonthToDateInfo.md
docs/Action.md
docs/ActionList.md
docs/ActionsApi.md
Expand Down Expand Up @@ -41,6 +42,7 @@ docs/LabelValue.md
docs/LabelValueRequest.md
docs/LabelsApi.md
docs/ModeEnum.md
docs/MonthToDateAccountInfoApi.md
docs/MultiClassModeConfiguration.md
docs/MultiClassificationResult.md
docs/Note.md
Expand Down Expand Up @@ -77,13 +79,15 @@ groundlight_openapi_client/api/detectors_api.py
groundlight_openapi_client/api/edge_api.py
groundlight_openapi_client/api/image_queries_api.py
groundlight_openapi_client/api/labels_api.py
groundlight_openapi_client/api/month_to_date_account_info_api.py
groundlight_openapi_client/api/notes_api.py
groundlight_openapi_client/api/user_api.py
groundlight_openapi_client/api_client.py
groundlight_openapi_client/apis/__init__.py
groundlight_openapi_client/configuration.py
groundlight_openapi_client/exceptions.py
groundlight_openapi_client/model/__init__.py
groundlight_openapi_client/model/account_month_to_date_info.py
groundlight_openapi_client/model/action.py
groundlight_openapi_client/model/action_list.py
groundlight_openapi_client/model/all_notes.py
Expand Down Expand Up @@ -150,6 +154,4 @@ setup.cfg
setup.py
test-requirements.txt
test/__init__.py
test/test_label.py
test/test_source.py
tox.ini
2 changes: 2 additions & 0 deletions generated/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,13 +137,15 @@ Class | Method | HTTP request | Description
*ImageQueriesApi* | [**list_image_queries**](docs/ImageQueriesApi.md#list_image_queries) | **GET** /v1/image-queries |
*ImageQueriesApi* | [**submit_image_query**](docs/ImageQueriesApi.md#submit_image_query) | **POST** /v1/image-queries |
*LabelsApi* | [**create_label**](docs/LabelsApi.md#create_label) | **POST** /v1/labels |
*MonthToDateAccountInfoApi* | [**month_to_date_account_info**](docs/MonthToDateAccountInfoApi.md#month_to_date_account_info) | **GET** /v1/month-to-date-account-info |
*NotesApi* | [**create_note**](docs/NotesApi.md#create_note) | **POST** /v1/notes |
*NotesApi* | [**get_notes**](docs/NotesApi.md#get_notes) | **GET** /v1/notes |
*UserApi* | [**who_am_i**](docs/UserApi.md#who_am_i) | **GET** /v1/me |


## Documentation For Models

- [AccountMonthToDateInfo](docs/AccountMonthToDateInfo.md)
- [Action](docs/Action.md)
- [ActionList](docs/ActionList.md)
- [AllNotes](docs/AllNotes.md)
Expand Down
18 changes: 18 additions & 0 deletions generated/docs/AccountMonthToDateInfo.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# AccountMonthToDateInfo

Account usage information for the current month

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**iqs** | **int** | The number of image queries in the current month. |
**escalations** | **int** | The number of escalations in the current month. |
**active_detectors** | **int** | The number of active detectors in the current month. |
**iqs_limit** | **int, none_type** | The limit on the number of image queries in the current month. |
**escalations_limit** | **int, none_type** | The limit on the number of escalations in the current month. |
**active_detectors_limit** | **int, none_type** | The limit on the number of active detectors in the current month. |
**any string name** | **bool, date, datetime, dict, float, int, list, str, none_type** | any string name can be used but the value must be the correct type | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


4 changes: 3 additions & 1 deletion generated/docs/ActionsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -396,11 +396,12 @@ with groundlight_openapi_client.ApiClient(configuration) as api_client:
api_instance = actions_api.ActionsApi(api_client)
page = 1 # int | A page number within the paginated result set. (optional)
page_size = 1 # int | Number of results to return per page. (optional)
predictor_id = "predictor_id_example" # str | Filter rules by predictor ID (optional)

# example passing only required values which don't have defaults set
# and optional values
try:
api_response = api_instance.list_rules(page=page, page_size=page_size)
api_response = api_instance.list_rules(page=page, page_size=page_size, predictor_id=predictor_id)
pprint(api_response)
except groundlight_openapi_client.ApiException as e:
print("Exception when calling ActionsApi->list_rules: %s\n" % e)
Expand All @@ -413,6 +414,7 @@ Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**page** | **int**| A page number within the paginated result set. | [optional]
**page_size** | **int**| Number of results to return per page. | [optional]
**predictor_id** | **str**| Filter rules by predictor ID | [optional]

### Return type

Expand Down
82 changes: 82 additions & 0 deletions generated/docs/MonthToDateAccountInfoApi.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
# groundlight_openapi_client.MonthToDateAccountInfoApi

All URIs are relative to *https://api.groundlight.ai/device-api*

Method | HTTP request | Description
------------- | ------------- | -------------
[**month_to_date_account_info**](MonthToDateAccountInfoApi.md#month_to_date_account_info) | **GET** /v1/month-to-date-account-info |


# **month_to_date_account_info**
> AccountMonthToDateInfo month_to_date_account_info()



Fetches and returns the account-specific metrics based on the current user's group.

### Example

* Api Key Authentication (ApiToken):

```python
import time
import groundlight_openapi_client
from groundlight_openapi_client.api import month_to_date_account_info_api
from groundlight_openapi_client.model.account_month_to_date_info import AccountMonthToDateInfo
from pprint import pprint
# Defining the host is optional and defaults to https://api.groundlight.ai/device-api
# See configuration.py for a list of all supported configuration parameters.
configuration = groundlight_openapi_client.Configuration(
host = "https://api.groundlight.ai/device-api"
)

# 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: ApiToken
configuration.api_key['ApiToken'] = 'YOUR_API_KEY'

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

# Enter a context with an instance of the API client
with groundlight_openapi_client.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = month_to_date_account_info_api.MonthToDateAccountInfoApi(api_client)

# example, this endpoint has no required or optional parameters
try:
api_response = api_instance.month_to_date_account_info()
pprint(api_response)
except groundlight_openapi_client.ApiException as e:
print("Exception when calling MonthToDateAccountInfoApi->month_to_date_account_info: %s\n" % e)
```


### Parameters
This endpoint does not need any parameter.

### Return type

[**AccountMonthToDateInfo**](AccountMonthToDateInfo.md)

### Authorization

[ApiToken](../README.md#ApiToken)

### HTTP request headers

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


### HTTP response details

| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

2 changes: 1 addition & 1 deletion generated/docs/Source.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**value** | **str** | | must be one of ["STILL_PROCESSING", "CLOUD", "USER", "CLOUD_ENSEMBLE", "ALGORITHM", "EDGE", ]
**value** | **str** | | must be one of ["STILL_PROCESSING", "CLOUD", "USER", "CLOUD_ENSEMBLE", "ALGORITHM", "AI_CLOUD", "AI_CLOUD_ENSEMBLE", "HUMAN_AI_CLOUD_ENSEMBLE", "EDGE", ]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
2 changes: 1 addition & 1 deletion generated/docs/SourceEnum.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**value** | **str** | | must be one of ["INITIAL_PLACEHOLDER", "CLOUD", "CUST", "HUMAN_CLOUD_ENSEMBLE", "ALG", "ALG_REC", "ALG_UNCLEAR", "EDGE", ]
**value** | **str** | | must be one of ["INITIAL_PLACEHOLDER", "CLOUD", "CUST", "HUMAN_CLOUD_ENSEMBLE", "AI_CLOUD", "AI_CLOUD_ENSEMBLE", "HUMAN_AI_CLOUD_ENSEMBLE", "ALG", "ALG_REC", "ALG_UNCLEAR", "EDGE", ]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
5 changes: 5 additions & 0 deletions generated/groundlight_openapi_client/api/actions_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,7 @@ def __init__(self, api_client=None):
"all": [
"page",
"page_size",
"predictor_id",
],
"required": [],
"nullable": [],
Expand All @@ -234,14 +235,17 @@ def __init__(self, api_client=None):
"openapi_types": {
"page": (int,),
"page_size": (int,),
"predictor_id": (str,),
},
"attribute_map": {
"page": "page",
"page_size": "page_size",
"predictor_id": "predictor_id",
},
"location_map": {
"page": "query",
"page_size": "query",
"predictor_id": "query",
},
"collection_format_map": {},
},
Expand Down Expand Up @@ -502,6 +506,7 @@ def list_rules(self, **kwargs):
Keyword Args:
page (int): A page number within the paginated result set.. [optional]
page_size (int): Number of results to return per page.. [optional]
predictor_id (str): Filter rules by predictor ID. [optional]
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
"""
Groundlight API

Groundlight makes it simple to understand images. You can easily create computer vision detectors just by describing what you want to know using natural language. # noqa: E501

The version of the OpenAPI document: 0.18.2
Contact: support@groundlight.ai
Generated by: https://openapi-generator.tech
"""

import re # noqa: F401
import sys # noqa: F401

from groundlight_openapi_client.api_client import ApiClient, Endpoint as _Endpoint
from groundlight_openapi_client.model_utils import ( # noqa: F401
check_allowed_values,
check_validations,
date,
datetime,
file_type,
none_type,
validate_and_convert_types,
)
from groundlight_openapi_client.model.account_month_to_date_info import AccountMonthToDateInfo


class MonthToDateAccountInfoApi(object):
"""NOTE: This class is auto generated by OpenAPI Generator
Ref: https://openapi-generator.tech

Do not edit the class manually.
"""

def __init__(self, api_client=None):
if api_client is None:
api_client = ApiClient()
self.api_client = api_client
self.month_to_date_account_info_endpoint = _Endpoint(
settings={
"response_type": (AccountMonthToDateInfo,),
"auth": ["ApiToken"],
"endpoint_path": "/v1/month-to-date-account-info",
"operation_id": "month_to_date_account_info",
"http_method": "GET",
"servers": None,
},
params_map={"all": [], "required": [], "nullable": [], "enum": [], "validation": []},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {},
"attribute_map": {},
"location_map": {},
"collection_format_map": {},
},
headers_map={
"accept": ["application/json"],
"content_type": [],
},
api_client=api_client,
)

def month_to_date_account_info(self, **kwargs):
"""month_to_date_account_info # noqa: E501

Fetches and returns the account-specific metrics based on the current user's group. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

>>> thread = api.month_to_date_account_info(async_req=True)
>>> result = thread.get()


Keyword Args:
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously

Returns:
AccountMonthToDateInfo
If the method is called asynchronously, returns the request
thread.
"""
kwargs["async_req"] = kwargs.get("async_req", False)
kwargs["_return_http_data_only"] = kwargs.get("_return_http_data_only", True)
kwargs["_preload_content"] = kwargs.get("_preload_content", True)
kwargs["_request_timeout"] = kwargs.get("_request_timeout", None)
kwargs["_check_input_type"] = kwargs.get("_check_input_type", True)
kwargs["_check_return_type"] = kwargs.get("_check_return_type", True)
kwargs["_spec_property_naming"] = kwargs.get("_spec_property_naming", False)
kwargs["_content_type"] = kwargs.get("_content_type")
kwargs["_host_index"] = kwargs.get("_host_index")
return self.month_to_date_account_info_endpoint.call_with_http_info(**kwargs)
1 change: 1 addition & 0 deletions generated/groundlight_openapi_client/apis/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,6 @@
from groundlight_openapi_client.api.edge_api import EdgeApi
from groundlight_openapi_client.api.image_queries_api import ImageQueriesApi
from groundlight_openapi_client.api.labels_api import LabelsApi
from groundlight_openapi_client.api.month_to_date_account_info_api import MonthToDateAccountInfoApi
from groundlight_openapi_client.api.notes_api import NotesApi
from groundlight_openapi_client.api.user_api import UserApi
Loading
Loading