weave-python 0.26.1__py3-none-any.whl → 0.27.0__py3-none-any.whl
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.
- weave/weaveapi/auth/v1/service_pb2.py +228 -0
- weave/weaveapi/auth/v1/service_pb2.pyi +1406 -0
- weave/weaveapi/auth/v1/service_pb2_grpc.py +1091 -0
- weave/weaveapi/auth/v1/service_pb2_grpc.pyi +606 -0
- weave/weaveapi/auth/v1/session_pb2.py +38 -0
- weave/weaveapi/auth/v1/session_pb2.pyi +111 -0
- weave/weaveapi/auth/v1/session_pb2_grpc.py +2 -0
- weave/weaveapi/auth/v1/session_pb2_grpc.pyi +20 -0
- weave/weaveapi/auth/v1/usage_pb2.py +52 -0
- weave/weaveapi/auth/v1/usage_pb2.pyi +241 -0
- weave/weaveapi/auth/v1/usage_pb2_grpc.py +2 -0
- weave/weaveapi/auth/v1/usage_pb2_grpc.pyi +20 -0
- weave/weaveapi/auth/v1/user_pb2.py +52 -0
- weave/weaveapi/auth/v1/user_pb2.pyi +594 -0
- weave/weaveapi/auth/v1/user_pb2_grpc.py +2 -0
- weave/weaveapi/auth/v1/user_pb2_grpc.pyi +20 -0
- weave/weaveapi/generate/v1/configuration_pb2.py +3 -3
- weave/weaveapi/generate/v1/generate_pb2.py +2 -2
- weave/weaveapi/generate/v1/service_pb2.py +2 -2
- weave/weaveapi/mcpregistry/v1/server_pb2.py +2 -2
- weave/weaveapi/mcpregistry/v1/service_pb2.py +3 -3
- weave/weaveapi/modex/v1/model_pb2.py +58 -0
- weave/weaveapi/modex/v1/model_pb2.pyi +642 -0
- weave/weaveapi/modex/v1/model_pb2_grpc.py +2 -0
- weave/weaveapi/modex/v1/model_pb2_grpc.pyi +20 -0
- weave/weaveapi/modex/v1/provider_pb2.py +38 -0
- weave/weaveapi/modex/v1/provider_pb2.pyi +91 -0
- weave/weaveapi/modex/v1/provider_pb2_grpc.py +2 -0
- weave/weaveapi/modex/v1/provider_pb2_grpc.pyi +20 -0
- weave/weaveapi/modex/v1/service_pb2.py +180 -0
- weave/weaveapi/modex/v1/service_pb2.pyi +1641 -0
- weave/weaveapi/modex/v1/service_pb2_grpc.py +602 -0
- weave/weaveapi/modex/v1/service_pb2_grpc.pyi +268 -0
- weave/weaveapi/payment/v1/invoice_pb2.py +46 -0
- weave/weaveapi/payment/v1/invoice_pb2.pyi +349 -0
- weave/weaveapi/payment/v1/invoice_pb2_grpc.py +2 -0
- weave/weaveapi/payment/v1/invoice_pb2_grpc.pyi +20 -0
- weave/weaveapi/payment/v1/service_pb2.py +244 -0
- weave/weaveapi/payment/v1/service_pb2.pyi +1492 -0
- weave/weaveapi/payment/v1/service_pb2_grpc.py +957 -0
- weave/weaveapi/payment/v1/service_pb2_grpc.pyi +572 -0
- weave/weaveapi/payment/v1/subscription_pb2.py +59 -0
- weave/weaveapi/payment/v1/subscription_pb2.pyi +695 -0
- weave/weaveapi/payment/v1/subscription_pb2_grpc.py +2 -0
- weave/weaveapi/payment/v1/subscription_pb2_grpc.pyi +20 -0
- weave/weaveapi/storage/v1/auth_pb2.py +2 -2
- weave/weaveapi/storage/v1/nosql_database_pb2.py +3 -3
- weave/weaveapi/storage/v1/object_store_pb2.py +3 -3
- weave/weaveapi/storage/v1/service_pb2.py +2 -2
- weave/weaveapi/storage/v1/sql_database_pb2.py +3 -3
- weave/weaveapi/storage/v1/storage_pb2.py +2 -2
- weave/weaveapi/synthesize/v1/dataset_pb2.py +2 -2
- weave/weaveapi/synthesize/v1/inline_data_pb2.py +3 -3
- weave/weaveapi/synthesize/v1/relationship_pb2.py +3 -3
- weave/weaveapi/synthesize/v1/service_pb2.py +2 -2
- weave/weaveapi/synthesize/v1/training_pb2.py +3 -3
- weave/weavesql/{db → weavedb}/queries.py +1 -1
- {weave_python-0.26.1.dist-info → weave_python-0.27.0.dist-info}/METADATA +1 -1
- weave_python-0.27.0.dist-info/RECORD +109 -0
- weave_python-0.26.1.dist-info/RECORD +0 -69
- /weave/weavesql/{db → weavedb}/models.py +0 -0
- {weave_python-0.26.1.dist-info → weave_python-0.27.0.dist-info}/WHEEL +0 -0
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
"""
|
|
2
|
+
@generated by mypy-protobuf. Do not edit manually!
|
|
3
|
+
isort:skip_file
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
import builtins
|
|
7
|
+
import google.protobuf.descriptor
|
|
8
|
+
import google.protobuf.message
|
|
9
|
+
import google.protobuf.timestamp_pb2
|
|
10
|
+
import typing
|
|
11
|
+
|
|
12
|
+
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
|
13
|
+
|
|
14
|
+
@typing.final
|
|
15
|
+
class Session(google.protobuf.message.Message):
|
|
16
|
+
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
|
17
|
+
|
|
18
|
+
ID_FIELD_NUMBER: builtins.int
|
|
19
|
+
USER_ID_FIELD_NUMBER: builtins.int
|
|
20
|
+
TOKEN_ID_FIELD_NUMBER: builtins.int
|
|
21
|
+
IP_ADDRESS_FIELD_NUMBER: builtins.int
|
|
22
|
+
USER_AGENT_FIELD_NUMBER: builtins.int
|
|
23
|
+
LOCATION_FIELD_NUMBER: builtins.int
|
|
24
|
+
DEVICE_TYPE_FIELD_NUMBER: builtins.int
|
|
25
|
+
IS_ACTIVE_FIELD_NUMBER: builtins.int
|
|
26
|
+
EXPIRES_AT_FIELD_NUMBER: builtins.int
|
|
27
|
+
LAST_ACTIVITY_AT_FIELD_NUMBER: builtins.int
|
|
28
|
+
REQUEST_COUNT_FIELD_NUMBER: builtins.int
|
|
29
|
+
CREATED_AT_FIELD_NUMBER: builtins.int
|
|
30
|
+
id: builtins.str
|
|
31
|
+
user_id: builtins.str
|
|
32
|
+
token_id: builtins.str
|
|
33
|
+
"""JWT token ID"""
|
|
34
|
+
ip_address: builtins.str
|
|
35
|
+
"""Session details"""
|
|
36
|
+
user_agent: builtins.str
|
|
37
|
+
location: builtins.str
|
|
38
|
+
"""Geo-location if available"""
|
|
39
|
+
device_type: builtins.str
|
|
40
|
+
"""desktop, mobile, tablet"""
|
|
41
|
+
is_active: builtins.bool
|
|
42
|
+
"""Status"""
|
|
43
|
+
request_count: builtins.int
|
|
44
|
+
@property
|
|
45
|
+
def expires_at(self) -> google.protobuf.timestamp_pb2.Timestamp: ...
|
|
46
|
+
@property
|
|
47
|
+
def last_activity_at(self) -> google.protobuf.timestamp_pb2.Timestamp:
|
|
48
|
+
"""Activity"""
|
|
49
|
+
|
|
50
|
+
@property
|
|
51
|
+
def created_at(self) -> google.protobuf.timestamp_pb2.Timestamp:
|
|
52
|
+
"""Metadata"""
|
|
53
|
+
|
|
54
|
+
def __init__(
|
|
55
|
+
self,
|
|
56
|
+
*,
|
|
57
|
+
id: builtins.str = ...,
|
|
58
|
+
user_id: builtins.str = ...,
|
|
59
|
+
token_id: builtins.str = ...,
|
|
60
|
+
ip_address: builtins.str = ...,
|
|
61
|
+
user_agent: builtins.str = ...,
|
|
62
|
+
location: builtins.str = ...,
|
|
63
|
+
device_type: builtins.str = ...,
|
|
64
|
+
is_active: builtins.bool = ...,
|
|
65
|
+
expires_at: google.protobuf.timestamp_pb2.Timestamp | None = ...,
|
|
66
|
+
last_activity_at: google.protobuf.timestamp_pb2.Timestamp | None = ...,
|
|
67
|
+
request_count: builtins.int = ...,
|
|
68
|
+
created_at: google.protobuf.timestamp_pb2.Timestamp | None = ...,
|
|
69
|
+
) -> None: ...
|
|
70
|
+
def HasField(
|
|
71
|
+
self,
|
|
72
|
+
field_name: typing.Literal[
|
|
73
|
+
"created_at",
|
|
74
|
+
b"created_at",
|
|
75
|
+
"expires_at",
|
|
76
|
+
b"expires_at",
|
|
77
|
+
"last_activity_at",
|
|
78
|
+
b"last_activity_at",
|
|
79
|
+
],
|
|
80
|
+
) -> builtins.bool: ...
|
|
81
|
+
def ClearField(
|
|
82
|
+
self,
|
|
83
|
+
field_name: typing.Literal[
|
|
84
|
+
"created_at",
|
|
85
|
+
b"created_at",
|
|
86
|
+
"device_type",
|
|
87
|
+
b"device_type",
|
|
88
|
+
"expires_at",
|
|
89
|
+
b"expires_at",
|
|
90
|
+
"id",
|
|
91
|
+
b"id",
|
|
92
|
+
"ip_address",
|
|
93
|
+
b"ip_address",
|
|
94
|
+
"is_active",
|
|
95
|
+
b"is_active",
|
|
96
|
+
"last_activity_at",
|
|
97
|
+
b"last_activity_at",
|
|
98
|
+
"location",
|
|
99
|
+
b"location",
|
|
100
|
+
"request_count",
|
|
101
|
+
b"request_count",
|
|
102
|
+
"token_id",
|
|
103
|
+
b"token_id",
|
|
104
|
+
"user_agent",
|
|
105
|
+
b"user_agent",
|
|
106
|
+
"user_id",
|
|
107
|
+
b"user_id",
|
|
108
|
+
],
|
|
109
|
+
) -> None: ...
|
|
110
|
+
|
|
111
|
+
global___Session = Session
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"""
|
|
2
|
+
@generated by mypy-protobuf. Do not edit manually!
|
|
3
|
+
isort:skip_file
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
import abc
|
|
7
|
+
import collections.abc
|
|
8
|
+
import grpc
|
|
9
|
+
import grpc.aio
|
|
10
|
+
import typing
|
|
11
|
+
|
|
12
|
+
_T = typing.TypeVar("_T")
|
|
13
|
+
|
|
14
|
+
class _MaybeAsyncIterator(
|
|
15
|
+
collections.abc.AsyncIterator[_T],
|
|
16
|
+
collections.abc.Iterator[_T],
|
|
17
|
+
metaclass=abc.ABCMeta,
|
|
18
|
+
): ...
|
|
19
|
+
class _ServicerContext(grpc.ServicerContext, grpc.aio.ServicerContext): # type: ignore[misc, type-arg]
|
|
20
|
+
...
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
+
# NO CHECKED-IN PROTOBUF GENCODE
|
|
4
|
+
# source: weaveapi/auth/v1/usage.proto
|
|
5
|
+
# Protobuf Python Version: 6.32.0
|
|
6
|
+
"""Generated protocol buffer code."""
|
|
7
|
+
|
|
8
|
+
from google.protobuf import descriptor as _descriptor
|
|
9
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
10
|
+
from google.protobuf import runtime_version as _runtime_version
|
|
11
|
+
from google.protobuf import symbol_database as _symbol_database
|
|
12
|
+
from google.protobuf.internal import builder as _builder
|
|
13
|
+
|
|
14
|
+
_runtime_version.ValidateProtobufRuntimeVersion(
|
|
15
|
+
_runtime_version.Domain.PUBLIC, 6, 32, 0, "", "weaveapi/auth/v1/usage.proto"
|
|
16
|
+
)
|
|
17
|
+
# @@protoc_insertion_point(imports)
|
|
18
|
+
|
|
19
|
+
_sym_db = _symbol_database.Default()
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
|
|
23
|
+
b'\n\x1cweaveapi/auth/v1/usage.proto\x12\x10weaveapi.auth.v1\x1a\x1fgoogle/protobuf/timestamp.proto"\xac\x08\n\nUsageStats\x12\x16\n\x06period\x18\x01 \x01(\tR\x06period\x12\x39\n\nstart_date\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tstartDate\x12\x35\n\x08\x65nd_date\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x07\x65ndDate\x12%\n\x0etotal_requests\x18\x04 \x01(\x03R\rtotalRequests\x12/\n\x13successful_requests\x18\x05 \x01(\x03R\x12successfulRequests\x12\'\n\x0f\x66\x61iled_requests\x18\x06 \x01(\x03R\x0e\x66\x61iledRequests\x12\x32\n\x15rate_limited_requests\x18\x07 \x01(\x03R\x13rateLimitedRequests\x12\x66\n\x14requests_by_endpoint\x18\x08 \x03(\x0b\x32\x34.weaveapi.auth.v1.UsageStats.RequestsByEndpointEntryR\x12requestsByEndpoint\x12W\n\x0frequests_by_day\x18\t \x03(\x0b\x32/.weaveapi.auth.v1.UsageStats.RequestsByDayEntryR\rrequestsByDay\x12\x61\n\x13requests_by_api_key\x18\n \x03(\x0b\x32\x32.weaveapi.auth.v1.UsageStats.RequestsByApiKeyEntryR\x10requestsByApiKey\x12/\n\x14\x61vg_response_time_ms\x18\x0b \x01(\x01R\x11\x61vgResponseTimeMs\x12/\n\x14p95_response_time_ms\x18\x0c \x01(\x01R\x11p95ResponseTimeMs\x12/\n\x14p99_response_time_ms\x18\r \x01(\x01R\x11p99ResponseTimeMs\x12(\n\x10total_bytes_sent\x18\x0e \x01(\x03R\x0etotalBytesSent\x12\x30\n\x14total_bytes_received\x18\x0f \x01(\x03R\x12totalBytesReceived\x1a\x45\n\x17RequestsByEndpointEntry\x12\x10\n\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n\x05value\x18\x02 \x01(\x03R\x05value:\x02\x38\x01\x1a@\n\x12RequestsByDayEntry\x12\x10\n\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n\x05value\x18\x02 \x01(\x03R\x05value:\x02\x38\x01\x1a\x43\n\x15RequestsByApiKeyEntry\x12\x10\n\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n\x05value\x18\x02 \x01(\x03R\x05value:\x02\x38\x01"\xcc\x02\n\x0bUsageLimits\x12\x12\n\x04tier\x18\x01 \x01(\tR\x04tier\x12*\n\x11requests_per_hour\x18\x02 \x01(\x03R\x0frequestsPerHour\x12(\n\x10requests_per_day\x18\x03 \x01(\x03R\x0erequestsPerDay\x12,\n\x12requests_per_month\x18\x04 \x01(\x03R\x10requestsPerMonth\x12(\n\x10\x61pi_keys_allowed\x18\x05 \x01(\x05R\x0e\x61piKeysAllowed\x12/\n\x13\x63oncurrent_requests\x18\x06 \x01(\x05R\x12\x63oncurrentRequests\x12%\n\x0ewebhook_access\x18\x07 \x01(\x08R\rwebhookAccess\x12#\n\rexport_access\x18\x08 \x01(\x08R\x0c\x65xportAccessB\xba\x01\n\x14\x63om.weaveapi.auth.v1B\nUsageProtoP\x01Z4github.com/weave-labs/weave-go/weaveapi/auth/v1;auth\xa2\x02\x03WAX\xaa\x02\x10Weaveapi.Auth.V1\xca\x02\x10Weaveapi\\Auth\\V1\xe2\x02\x1cWeaveapi\\Auth\\V1\\GPBMetadata\xea\x02\x12Weaveapi::Auth::V1b\x06proto3'
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
_globals = globals()
|
|
27
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
28
|
+
_builder.BuildTopDescriptorsAndMessages(
|
|
29
|
+
DESCRIPTOR, "weaveapi.auth.v1.usage_pb2", _globals
|
|
30
|
+
)
|
|
31
|
+
if not _descriptor._USE_C_DESCRIPTORS:
|
|
32
|
+
_globals["DESCRIPTOR"]._loaded_options = None
|
|
33
|
+
_globals[
|
|
34
|
+
"DESCRIPTOR"
|
|
35
|
+
]._serialized_options = b"\n\024com.weaveapi.auth.v1B\nUsageProtoP\001Z4github.com/weave-labs/weave-go/weaveapi/auth/v1;auth\242\002\003WAX\252\002\020Weaveapi.Auth.V1\312\002\020Weaveapi\\Auth\\V1\342\002\034Weaveapi\\Auth\\V1\\GPBMetadata\352\002\022Weaveapi::Auth::V1"
|
|
36
|
+
_globals["_USAGESTATS_REQUESTSBYENDPOINTENTRY"]._loaded_options = None
|
|
37
|
+
_globals["_USAGESTATS_REQUESTSBYENDPOINTENTRY"]._serialized_options = b"8\001"
|
|
38
|
+
_globals["_USAGESTATS_REQUESTSBYDAYENTRY"]._loaded_options = None
|
|
39
|
+
_globals["_USAGESTATS_REQUESTSBYDAYENTRY"]._serialized_options = b"8\001"
|
|
40
|
+
_globals["_USAGESTATS_REQUESTSBYAPIKEYENTRY"]._loaded_options = None
|
|
41
|
+
_globals["_USAGESTATS_REQUESTSBYAPIKEYENTRY"]._serialized_options = b"8\001"
|
|
42
|
+
_globals["_USAGESTATS"]._serialized_start = 84
|
|
43
|
+
_globals["_USAGESTATS"]._serialized_end = 1152
|
|
44
|
+
_globals["_USAGESTATS_REQUESTSBYENDPOINTENTRY"]._serialized_start = 948
|
|
45
|
+
_globals["_USAGESTATS_REQUESTSBYENDPOINTENTRY"]._serialized_end = 1017
|
|
46
|
+
_globals["_USAGESTATS_REQUESTSBYDAYENTRY"]._serialized_start = 1019
|
|
47
|
+
_globals["_USAGESTATS_REQUESTSBYDAYENTRY"]._serialized_end = 1083
|
|
48
|
+
_globals["_USAGESTATS_REQUESTSBYAPIKEYENTRY"]._serialized_start = 1085
|
|
49
|
+
_globals["_USAGESTATS_REQUESTSBYAPIKEYENTRY"]._serialized_end = 1152
|
|
50
|
+
_globals["_USAGELIMITS"]._serialized_start = 1155
|
|
51
|
+
_globals["_USAGELIMITS"]._serialized_end = 1487
|
|
52
|
+
# @@protoc_insertion_point(module_scope)
|
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
"""
|
|
2
|
+
@generated by mypy-protobuf. Do not edit manually!
|
|
3
|
+
isort:skip_file
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
import builtins
|
|
7
|
+
import collections.abc
|
|
8
|
+
import google.protobuf.descriptor
|
|
9
|
+
import google.protobuf.internal.containers
|
|
10
|
+
import google.protobuf.message
|
|
11
|
+
import google.protobuf.timestamp_pb2
|
|
12
|
+
import typing
|
|
13
|
+
|
|
14
|
+
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
|
15
|
+
|
|
16
|
+
@typing.final
|
|
17
|
+
class UsageStats(google.protobuf.message.Message):
|
|
18
|
+
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
|
19
|
+
|
|
20
|
+
@typing.final
|
|
21
|
+
class RequestsByEndpointEntry(google.protobuf.message.Message):
|
|
22
|
+
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
|
23
|
+
|
|
24
|
+
KEY_FIELD_NUMBER: builtins.int
|
|
25
|
+
VALUE_FIELD_NUMBER: builtins.int
|
|
26
|
+
key: builtins.str
|
|
27
|
+
value: builtins.int
|
|
28
|
+
def __init__(
|
|
29
|
+
self,
|
|
30
|
+
*,
|
|
31
|
+
key: builtins.str = ...,
|
|
32
|
+
value: builtins.int = ...,
|
|
33
|
+
) -> None: ...
|
|
34
|
+
def ClearField(
|
|
35
|
+
self, field_name: typing.Literal["key", b"key", "value", b"value"]
|
|
36
|
+
) -> None: ...
|
|
37
|
+
|
|
38
|
+
@typing.final
|
|
39
|
+
class RequestsByDayEntry(google.protobuf.message.Message):
|
|
40
|
+
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
|
41
|
+
|
|
42
|
+
KEY_FIELD_NUMBER: builtins.int
|
|
43
|
+
VALUE_FIELD_NUMBER: builtins.int
|
|
44
|
+
key: builtins.str
|
|
45
|
+
value: builtins.int
|
|
46
|
+
def __init__(
|
|
47
|
+
self,
|
|
48
|
+
*,
|
|
49
|
+
key: builtins.str = ...,
|
|
50
|
+
value: builtins.int = ...,
|
|
51
|
+
) -> None: ...
|
|
52
|
+
def ClearField(
|
|
53
|
+
self, field_name: typing.Literal["key", b"key", "value", b"value"]
|
|
54
|
+
) -> None: ...
|
|
55
|
+
|
|
56
|
+
@typing.final
|
|
57
|
+
class RequestsByApiKeyEntry(google.protobuf.message.Message):
|
|
58
|
+
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
|
59
|
+
|
|
60
|
+
KEY_FIELD_NUMBER: builtins.int
|
|
61
|
+
VALUE_FIELD_NUMBER: builtins.int
|
|
62
|
+
key: builtins.str
|
|
63
|
+
value: builtins.int
|
|
64
|
+
def __init__(
|
|
65
|
+
self,
|
|
66
|
+
*,
|
|
67
|
+
key: builtins.str = ...,
|
|
68
|
+
value: builtins.int = ...,
|
|
69
|
+
) -> None: ...
|
|
70
|
+
def ClearField(
|
|
71
|
+
self, field_name: typing.Literal["key", b"key", "value", b"value"]
|
|
72
|
+
) -> None: ...
|
|
73
|
+
|
|
74
|
+
PERIOD_FIELD_NUMBER: builtins.int
|
|
75
|
+
START_DATE_FIELD_NUMBER: builtins.int
|
|
76
|
+
END_DATE_FIELD_NUMBER: builtins.int
|
|
77
|
+
TOTAL_REQUESTS_FIELD_NUMBER: builtins.int
|
|
78
|
+
SUCCESSFUL_REQUESTS_FIELD_NUMBER: builtins.int
|
|
79
|
+
FAILED_REQUESTS_FIELD_NUMBER: builtins.int
|
|
80
|
+
RATE_LIMITED_REQUESTS_FIELD_NUMBER: builtins.int
|
|
81
|
+
REQUESTS_BY_ENDPOINT_FIELD_NUMBER: builtins.int
|
|
82
|
+
REQUESTS_BY_DAY_FIELD_NUMBER: builtins.int
|
|
83
|
+
REQUESTS_BY_API_KEY_FIELD_NUMBER: builtins.int
|
|
84
|
+
AVG_RESPONSE_TIME_MS_FIELD_NUMBER: builtins.int
|
|
85
|
+
P95_RESPONSE_TIME_MS_FIELD_NUMBER: builtins.int
|
|
86
|
+
P99_RESPONSE_TIME_MS_FIELD_NUMBER: builtins.int
|
|
87
|
+
TOTAL_BYTES_SENT_FIELD_NUMBER: builtins.int
|
|
88
|
+
TOTAL_BYTES_RECEIVED_FIELD_NUMBER: builtins.int
|
|
89
|
+
period: builtins.str
|
|
90
|
+
total_requests: builtins.int
|
|
91
|
+
"""Request counts"""
|
|
92
|
+
successful_requests: builtins.int
|
|
93
|
+
failed_requests: builtins.int
|
|
94
|
+
rate_limited_requests: builtins.int
|
|
95
|
+
avg_response_time_ms: builtins.float
|
|
96
|
+
"""Response times"""
|
|
97
|
+
p95_response_time_ms: builtins.float
|
|
98
|
+
p99_response_time_ms: builtins.float
|
|
99
|
+
total_bytes_sent: builtins.int
|
|
100
|
+
"""Data transfer"""
|
|
101
|
+
total_bytes_received: builtins.int
|
|
102
|
+
@property
|
|
103
|
+
def start_date(self) -> google.protobuf.timestamp_pb2.Timestamp: ...
|
|
104
|
+
@property
|
|
105
|
+
def end_date(self) -> google.protobuf.timestamp_pb2.Timestamp: ...
|
|
106
|
+
@property
|
|
107
|
+
def requests_by_endpoint(
|
|
108
|
+
self,
|
|
109
|
+
) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.int]:
|
|
110
|
+
"""Breakdown"""
|
|
111
|
+
|
|
112
|
+
@property
|
|
113
|
+
def requests_by_day(
|
|
114
|
+
self,
|
|
115
|
+
) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.int]: ...
|
|
116
|
+
@property
|
|
117
|
+
def requests_by_api_key(
|
|
118
|
+
self,
|
|
119
|
+
) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.int]: ...
|
|
120
|
+
def __init__(
|
|
121
|
+
self,
|
|
122
|
+
*,
|
|
123
|
+
period: builtins.str = ...,
|
|
124
|
+
start_date: google.protobuf.timestamp_pb2.Timestamp | None = ...,
|
|
125
|
+
end_date: google.protobuf.timestamp_pb2.Timestamp | None = ...,
|
|
126
|
+
total_requests: builtins.int = ...,
|
|
127
|
+
successful_requests: builtins.int = ...,
|
|
128
|
+
failed_requests: builtins.int = ...,
|
|
129
|
+
rate_limited_requests: builtins.int = ...,
|
|
130
|
+
requests_by_endpoint: collections.abc.Mapping[builtins.str, builtins.int]
|
|
131
|
+
| None = ...,
|
|
132
|
+
requests_by_day: collections.abc.Mapping[builtins.str, builtins.int]
|
|
133
|
+
| None = ...,
|
|
134
|
+
requests_by_api_key: collections.abc.Mapping[builtins.str, builtins.int]
|
|
135
|
+
| None = ...,
|
|
136
|
+
avg_response_time_ms: builtins.float = ...,
|
|
137
|
+
p95_response_time_ms: builtins.float = ...,
|
|
138
|
+
p99_response_time_ms: builtins.float = ...,
|
|
139
|
+
total_bytes_sent: builtins.int = ...,
|
|
140
|
+
total_bytes_received: builtins.int = ...,
|
|
141
|
+
) -> None: ...
|
|
142
|
+
def HasField(
|
|
143
|
+
self,
|
|
144
|
+
field_name: typing.Literal[
|
|
145
|
+
"end_date", b"end_date", "start_date", b"start_date"
|
|
146
|
+
],
|
|
147
|
+
) -> builtins.bool: ...
|
|
148
|
+
def ClearField(
|
|
149
|
+
self,
|
|
150
|
+
field_name: typing.Literal[
|
|
151
|
+
"avg_response_time_ms",
|
|
152
|
+
b"avg_response_time_ms",
|
|
153
|
+
"end_date",
|
|
154
|
+
b"end_date",
|
|
155
|
+
"failed_requests",
|
|
156
|
+
b"failed_requests",
|
|
157
|
+
"p95_response_time_ms",
|
|
158
|
+
b"p95_response_time_ms",
|
|
159
|
+
"p99_response_time_ms",
|
|
160
|
+
b"p99_response_time_ms",
|
|
161
|
+
"period",
|
|
162
|
+
b"period",
|
|
163
|
+
"rate_limited_requests",
|
|
164
|
+
b"rate_limited_requests",
|
|
165
|
+
"requests_by_api_key",
|
|
166
|
+
b"requests_by_api_key",
|
|
167
|
+
"requests_by_day",
|
|
168
|
+
b"requests_by_day",
|
|
169
|
+
"requests_by_endpoint",
|
|
170
|
+
b"requests_by_endpoint",
|
|
171
|
+
"start_date",
|
|
172
|
+
b"start_date",
|
|
173
|
+
"successful_requests",
|
|
174
|
+
b"successful_requests",
|
|
175
|
+
"total_bytes_received",
|
|
176
|
+
b"total_bytes_received",
|
|
177
|
+
"total_bytes_sent",
|
|
178
|
+
b"total_bytes_sent",
|
|
179
|
+
"total_requests",
|
|
180
|
+
b"total_requests",
|
|
181
|
+
],
|
|
182
|
+
) -> None: ...
|
|
183
|
+
|
|
184
|
+
global___UsageStats = UsageStats
|
|
185
|
+
|
|
186
|
+
@typing.final
|
|
187
|
+
class UsageLimits(google.protobuf.message.Message):
|
|
188
|
+
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
|
189
|
+
|
|
190
|
+
TIER_FIELD_NUMBER: builtins.int
|
|
191
|
+
REQUESTS_PER_HOUR_FIELD_NUMBER: builtins.int
|
|
192
|
+
REQUESTS_PER_DAY_FIELD_NUMBER: builtins.int
|
|
193
|
+
REQUESTS_PER_MONTH_FIELD_NUMBER: builtins.int
|
|
194
|
+
API_KEYS_ALLOWED_FIELD_NUMBER: builtins.int
|
|
195
|
+
CONCURRENT_REQUESTS_FIELD_NUMBER: builtins.int
|
|
196
|
+
WEBHOOK_ACCESS_FIELD_NUMBER: builtins.int
|
|
197
|
+
EXPORT_ACCESS_FIELD_NUMBER: builtins.int
|
|
198
|
+
tier: builtins.str
|
|
199
|
+
"""free, pro"""
|
|
200
|
+
requests_per_hour: builtins.int
|
|
201
|
+
requests_per_day: builtins.int
|
|
202
|
+
requests_per_month: builtins.int
|
|
203
|
+
api_keys_allowed: builtins.int
|
|
204
|
+
concurrent_requests: builtins.int
|
|
205
|
+
webhook_access: builtins.bool
|
|
206
|
+
export_access: builtins.bool
|
|
207
|
+
def __init__(
|
|
208
|
+
self,
|
|
209
|
+
*,
|
|
210
|
+
tier: builtins.str = ...,
|
|
211
|
+
requests_per_hour: builtins.int = ...,
|
|
212
|
+
requests_per_day: builtins.int = ...,
|
|
213
|
+
requests_per_month: builtins.int = ...,
|
|
214
|
+
api_keys_allowed: builtins.int = ...,
|
|
215
|
+
concurrent_requests: builtins.int = ...,
|
|
216
|
+
webhook_access: builtins.bool = ...,
|
|
217
|
+
export_access: builtins.bool = ...,
|
|
218
|
+
) -> None: ...
|
|
219
|
+
def ClearField(
|
|
220
|
+
self,
|
|
221
|
+
field_name: typing.Literal[
|
|
222
|
+
"api_keys_allowed",
|
|
223
|
+
b"api_keys_allowed",
|
|
224
|
+
"concurrent_requests",
|
|
225
|
+
b"concurrent_requests",
|
|
226
|
+
"export_access",
|
|
227
|
+
b"export_access",
|
|
228
|
+
"requests_per_day",
|
|
229
|
+
b"requests_per_day",
|
|
230
|
+
"requests_per_hour",
|
|
231
|
+
b"requests_per_hour",
|
|
232
|
+
"requests_per_month",
|
|
233
|
+
b"requests_per_month",
|
|
234
|
+
"tier",
|
|
235
|
+
b"tier",
|
|
236
|
+
"webhook_access",
|
|
237
|
+
b"webhook_access",
|
|
238
|
+
],
|
|
239
|
+
) -> None: ...
|
|
240
|
+
|
|
241
|
+
global___UsageLimits = UsageLimits
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"""
|
|
2
|
+
@generated by mypy-protobuf. Do not edit manually!
|
|
3
|
+
isort:skip_file
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
import abc
|
|
7
|
+
import collections.abc
|
|
8
|
+
import grpc
|
|
9
|
+
import grpc.aio
|
|
10
|
+
import typing
|
|
11
|
+
|
|
12
|
+
_T = typing.TypeVar("_T")
|
|
13
|
+
|
|
14
|
+
class _MaybeAsyncIterator(
|
|
15
|
+
collections.abc.AsyncIterator[_T],
|
|
16
|
+
collections.abc.Iterator[_T],
|
|
17
|
+
metaclass=abc.ABCMeta,
|
|
18
|
+
): ...
|
|
19
|
+
class _ServicerContext(grpc.ServicerContext, grpc.aio.ServicerContext): # type: ignore[misc, type-arg]
|
|
20
|
+
...
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
+
# NO CHECKED-IN PROTOBUF GENCODE
|
|
4
|
+
# source: weaveapi/auth/v1/user.proto
|
|
5
|
+
# Protobuf Python Version: 6.32.0
|
|
6
|
+
"""Generated protocol buffer code."""
|
|
7
|
+
|
|
8
|
+
from google.protobuf import descriptor as _descriptor
|
|
9
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
10
|
+
from google.protobuf import runtime_version as _runtime_version
|
|
11
|
+
from google.protobuf import symbol_database as _symbol_database
|
|
12
|
+
from google.protobuf.internal import builder as _builder
|
|
13
|
+
|
|
14
|
+
_runtime_version.ValidateProtobufRuntimeVersion(
|
|
15
|
+
_runtime_version.Domain.PUBLIC, 6, 32, 0, "", "weaveapi/auth/v1/user.proto"
|
|
16
|
+
)
|
|
17
|
+
# @@protoc_insertion_point(imports)
|
|
18
|
+
|
|
19
|
+
_sym_db = _symbol_database.Default()
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
|
|
23
|
+
b'\n\x1bweaveapi/auth/v1/user.proto\x12\x10weaveapi.auth.v1\x1a\x1fgoogle/protobuf/timestamp.proto"\x87\x05\n\x04User\x12\x0e\n\x02id\x18\x01 \x01(\tR\x02id\x12\x14\n\x05\x65mail\x18\x02 \x01(\tR\x05\x65mail\x12\x1a\n\x08username\x18\x03 \x01(\tR\x08username\x12\x1b\n\tfull_name\x18\x04 \x01(\tR\x08\x66ullName\x12\x1d\n\navatar_url\x18\x05 \x01(\tR\tavatarUrl\x12\x45\n\x0eoauth_accounts\x18\x06 \x03(\x0b\x32\x1e.weaveapi.auth.v1.OAuthAccountR\roauthAccounts\x12)\n\x10primary_provider\x18\x07 \x01(\tR\x0fprimaryProvider\x12\x46\n\x0csubscription\x18\x08 \x01(\x0b\x32".weaveapi.auth.v1.SubscriptionInfoR\x0csubscription\x12%\n\x0e\x61\x63\x63ount_status\x18\t \x01(\tR\raccountStatus\x12%\n\x0e\x65mail_verified\x18\n \x01(\x08R\remailVerified\x12>\n\rlast_login_at\x18\x0b \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x0blastLoginAt\x12\x39\n\ncreated_at\x18\x0c \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tcreatedAt\x12\x39\n\nupdated_at\x18\r \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tupdatedAt\x12\x43\n\x0bpreferences\x18\x0e \x01(\x0b\x32!.weaveapi.auth.v1.UserPreferencesR\x0bpreferences"\xb4\x04\n\x0cOAuthAccount\x12\x1a\n\x08provider\x18\x01 \x01(\tR\x08provider\x12(\n\x10provider_user_id\x18\x02 \x01(\tR\x0eproviderUserId\x12+\n\x11provider_username\x18\x03 \x01(\tR\x10providerUsername\x12%\n\x0eprovider_email\x18\x04 \x01(\tR\rproviderEmail\x12!\n\x0c\x61\x63\x63\x65ss_token\x18\x05 \x01(\tR\x0b\x61\x63\x63\x65ssToken\x12#\n\rrefresh_token\x18\x06 \x01(\tR\x0crefreshToken\x12\x44\n\x10token_expires_at\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x0etokenExpiresAt\x12\x37\n\tlinked_at\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x08linkedAt\x12<\n\x0clast_used_at\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampR\nlastUsedAt\x12H\n\x08metadata\x18\n \x03(\x0b\x32,.weaveapi.auth.v1.OAuthAccount.MetadataEntryR\x08metadata\x1a;\n\rMetadataEntry\x12\x10\n\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n\x05value\x18\x02 \x01(\tR\x05value:\x02\x38\x01"\x9b\x02\n\rOAuthProvider\x12\x12\n\x04name\x18\x01 \x01(\tR\x04name\x12!\n\x0c\x64isplay_name\x18\x02 \x01(\tR\x0b\x64isplayName\x12\x19\n\x08icon_url\x18\x03 \x01(\tR\x07iconUrl\x12\x18\n\x07\x65nabled\x18\x04 \x01(\x08R\x07\x65nabled\x12)\n\x10supported_scopes\x18\x05 \x03(\tR\x0fsupportedScopes\x12#\n\rdefault_scope\x18\x06 \x01(\tR\x0c\x64\x65\x66\x61ultScope\x12)\n\x10supports_refresh\x18\x07 \x01(\x08R\x0fsupportsRefresh\x12#\n\rsupports_pkce\x18\x08 \x01(\x08R\x0csupportsPkce"\xd4\x03\n\x10SubscriptionInfo\x12\x16\n\x06status\x18\x01 \x01(\tR\x06status\x12\x12\n\x04tier\x18\x02 \x01(\tR\x04tier\x12,\n\x12stripe_customer_id\x18\x03 \x01(\tR\x10stripeCustomerId\x12\x34\n\x16stripe_subscription_id\x18\x04 \x01(\tR\x14stripeSubscriptionId\x12\x39\n\nstarted_at\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tstartedAt\x12\x33\n\x07\x65nds_at\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x06\x65ndsAt\x12=\n\x0c\x63\x61ncelled_at\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x0b\x63\x61ncelledAt\x12\x1d\n\nauto_renew\x18\x08 \x01(\x08R\tautoRenew\x12\x30\n\x14payment_method_last4\x18\t \x01(\tR\x12paymentMethodLast4\x12\x30\n\x14payment_method_brand\x18\n \x01(\tR\x12paymentMethodBrand"\xd0\x02\n\x0fUserPreferences\x12/\n\x13\x65mail_notifications\x18\x01 \x01(\x08R\x12\x65mailNotifications\x12\x33\n\x15webhook_notifications\x18\x02 \x01(\x08R\x14webhookNotifications\x12\x1f\n\x0bwebhook_url\x18\x03 \x01(\tR\nwebhookUrl\x12%\n\x0ewebhook_secret\x18\x04 \x01(\tR\rwebhookSecret\x12%\n\x0ewatched_models\x18\x05 \x03(\tR\rwatchedModels\x12+\n\x11watched_providers\x18\x06 \x03(\tR\x10watchedProviders\x12\x1a\n\x08timezone\x18\x07 \x01(\tR\x08timezone\x12\x1f\n\x0b\x64\x61te_format\x18\x08 \x01(\tR\ndateFormat"\xc0\x04\n\x06\x41PIKey\x12\x0e\n\x02id\x18\x01 \x01(\tR\x02id\x12\x17\n\x07user_id\x18\x02 \x01(\tR\x06userId\x12\x1d\n\nkey_prefix\x18\x03 \x01(\tR\tkeyPrefix\x12\x12\n\x04name\x18\x04 \x01(\tR\x04name\x12 \n\x0b\x64\x65scription\x18\x05 \x01(\tR\x0b\x64\x65scription\x12\x16\n\x06scopes\x18\x06 \x03(\tR\x06scopes\x12+\n\x11\x61llowed_endpoints\x18\x07 \x03(\tR\x10\x61llowedEndpoints\x12\x1f\n\x0b\x61llowed_ips\x18\x08 \x03(\tR\nallowedIps\x12<\n\x0clast_used_at\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampR\nlastUsedAt\x12#\n\rrequest_count\x18\n \x01(\x03R\x0crequestCount\x12!\n\x0ctotal_tokens\x18\x0b \x01(\x03R\x0btotalTokens\x12\x1b\n\tis_active\x18\x0c \x01(\x08R\x08isActive\x12\x39\n\nexpires_at\x18\r \x01(\x0b\x32\x1a.google.protobuf.TimestampR\texpiresAt\x12\x39\n\ncreated_at\x18\x0e \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tcreatedAt\x12\x39\n\nupdated_at\x18\x0f \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tupdatedAtB\xb9\x01\n\x14\x63om.weaveapi.auth.v1B\tUserProtoP\x01Z4github.com/weave-labs/weave-go/weaveapi/auth/v1;auth\xa2\x02\x03WAX\xaa\x02\x10Weaveapi.Auth.V1\xca\x02\x10Weaveapi\\Auth\\V1\xe2\x02\x1cWeaveapi\\Auth\\V1\\GPBMetadata\xea\x02\x12Weaveapi::Auth::V1b\x06proto3'
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
_globals = globals()
|
|
27
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
28
|
+
_builder.BuildTopDescriptorsAndMessages(
|
|
29
|
+
DESCRIPTOR, "weaveapi.auth.v1.user_pb2", _globals
|
|
30
|
+
)
|
|
31
|
+
if not _descriptor._USE_C_DESCRIPTORS:
|
|
32
|
+
_globals["DESCRIPTOR"]._loaded_options = None
|
|
33
|
+
_globals[
|
|
34
|
+
"DESCRIPTOR"
|
|
35
|
+
]._serialized_options = b"\n\024com.weaveapi.auth.v1B\tUserProtoP\001Z4github.com/weave-labs/weave-go/weaveapi/auth/v1;auth\242\002\003WAX\252\002\020Weaveapi.Auth.V1\312\002\020Weaveapi\\Auth\\V1\342\002\034Weaveapi\\Auth\\V1\\GPBMetadata\352\002\022Weaveapi::Auth::V1"
|
|
36
|
+
_globals["_OAUTHACCOUNT_METADATAENTRY"]._loaded_options = None
|
|
37
|
+
_globals["_OAUTHACCOUNT_METADATAENTRY"]._serialized_options = b"8\001"
|
|
38
|
+
_globals["_USER"]._serialized_start = 83
|
|
39
|
+
_globals["_USER"]._serialized_end = 730
|
|
40
|
+
_globals["_OAUTHACCOUNT"]._serialized_start = 733
|
|
41
|
+
_globals["_OAUTHACCOUNT"]._serialized_end = 1297
|
|
42
|
+
_globals["_OAUTHACCOUNT_METADATAENTRY"]._serialized_start = 1238
|
|
43
|
+
_globals["_OAUTHACCOUNT_METADATAENTRY"]._serialized_end = 1297
|
|
44
|
+
_globals["_OAUTHPROVIDER"]._serialized_start = 1300
|
|
45
|
+
_globals["_OAUTHPROVIDER"]._serialized_end = 1583
|
|
46
|
+
_globals["_SUBSCRIPTIONINFO"]._serialized_start = 1586
|
|
47
|
+
_globals["_SUBSCRIPTIONINFO"]._serialized_end = 2054
|
|
48
|
+
_globals["_USERPREFERENCES"]._serialized_start = 2057
|
|
49
|
+
_globals["_USERPREFERENCES"]._serialized_end = 2393
|
|
50
|
+
_globals["_APIKEY"]._serialized_start = 2396
|
|
51
|
+
_globals["_APIKEY"]._serialized_end = 2972
|
|
52
|
+
# @@protoc_insertion_point(module_scope)
|