wordlift-client 1.125.0__py3-none-any.whl → 1.127.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.
@@ -15,7 +15,7 @@
15
15
  """ # noqa: E501
16
16
 
17
17
 
18
- __version__ = "1.125.0"
18
+ __version__ = "1.127.0"
19
19
 
20
20
  # import apis into sdk package
21
21
  from wordlift_client.api.account_api import AccountApi
@@ -87,6 +87,7 @@ from wordlift_client.api.web_asyncs_metadata_api import WebAsyncsMetadataApi
87
87
  from wordlift_client.api.web_asyncs_responses_api import WebAsyncsResponsesApi
88
88
  from wordlift_client.api.web_pages_imports_api import WebPagesImportsApi
89
89
  from wordlift_client.api.web_pages_api import WebPagesApi
90
+ from wordlift_client.api.ai_visibility_api import AiVisibilityApi
90
91
 
91
92
  # import ApiClient
92
93
  from wordlift_client.api_response import ApiResponse
@@ -100,6 +101,7 @@ from wordlift_client.exceptions import ApiAttributeError
100
101
  from wordlift_client.exceptions import ApiException
101
102
 
102
103
  # import models into sdk package
104
+ from wordlift_client.models.ai_visibility_analysis_result import AIVisibilityAnalysisResult
103
105
  from wordlift_client.models.account import Account
104
106
  from wordlift_client.models.account_config import AccountConfig
105
107
  from wordlift_client.models.account_info import AccountInfo
@@ -113,6 +115,7 @@ from wordlift_client.models.analyses_response_item import AnalysesResponseItem
113
115
  from wordlift_client.models.analytics_import_request import AnalyticsImportRequest
114
116
  from wordlift_client.models.analytics_sync import AnalyticsSync
115
117
  from wordlift_client.models.analytics_sync_request import AnalyticsSyncRequest
118
+ from wordlift_client.models.analyze_url_request import AnalyzeURLRequest
116
119
  from wordlift_client.models.anchor_text import AnchorText
117
120
  from wordlift_client.models.annotation import Annotation
118
121
  from wordlift_client.models.ask_request import AskRequest
@@ -231,6 +234,7 @@ from wordlift_client.models.problem_detail import ProblemDetail
231
234
  from wordlift_client.models.project_type import ProjectType
232
235
  from wordlift_client.models.properties import Properties
233
236
  from wordlift_client.models.properties1 import Properties1
237
+ from wordlift_client.models.query_coverage import QueryCoverage
234
238
  from wordlift_client.models.question_and_answer import QuestionAndAnswer
235
239
  from wordlift_client.models.question_and_answer_request import QuestionAndAnswerRequest
236
240
  from wordlift_client.models.quick_win import QuickWin
@@ -70,4 +70,5 @@ from wordlift_client.api.web_asyncs_metadata_api import WebAsyncsMetadataApi
70
70
  from wordlift_client.api.web_asyncs_responses_api import WebAsyncsResponsesApi
71
71
  from wordlift_client.api.web_pages_imports_api import WebPagesImportsApi
72
72
  from wordlift_client.api.web_pages_api import WebPagesApi
73
+ from wordlift_client.api.ai_visibility_api import AiVisibilityApi
73
74
 
@@ -0,0 +1,326 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ WordLift API
5
+
6
+ WordLift API
7
+
8
+ The version of the OpenAPI document: 1.0
9
+ Contact: hello@wordlift.io
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
+
12
+ Do not edit the class manually.
13
+ """ # noqa: E501
14
+
15
+ import warnings
16
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
17
+ from typing import Any, Dict, List, Optional, Tuple, Union
18
+ from typing_extensions import Annotated
19
+
20
+ from pydantic import StrictStr
21
+ from typing import Optional
22
+ from wordlift_client.models.ai_visibility_analysis_result import AIVisibilityAnalysisResult
23
+ from wordlift_client.models.analyze_url_request import AnalyzeURLRequest
24
+
25
+ from wordlift_client.api_client import ApiClient, RequestSerialized
26
+ from wordlift_client.api_response import ApiResponse
27
+ from wordlift_client.rest import RESTResponseType
28
+
29
+
30
+ class AiVisibilityApi:
31
+ """NOTE: This class is auto generated by OpenAPI Generator
32
+ Ref: https://openapi-generator.tech
33
+
34
+ Do not edit the class manually.
35
+ """
36
+
37
+ def __init__(self, api_client=None) -> None:
38
+ if api_client is None:
39
+ api_client = ApiClient.get_default()
40
+ self.api_client = api_client
41
+
42
+
43
+ @validate_call
44
+ async def create_ai_visibility_audit(
45
+ self,
46
+ analyze_url_request: AnalyzeURLRequest,
47
+ authorization: Optional[StrictStr] = None,
48
+ _request_timeout: Union[
49
+ None,
50
+ Annotated[StrictFloat, Field(gt=0)],
51
+ Tuple[
52
+ Annotated[StrictFloat, Field(gt=0)],
53
+ Annotated[StrictFloat, Field(gt=0)]
54
+ ]
55
+ ] = None,
56
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
57
+ _content_type: Optional[StrictStr] = None,
58
+ _headers: Optional[Dict[StrictStr, Any]] = None,
59
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
60
+ ) -> AIVisibilityAnalysisResult:
61
+ """Create AI visibility audits for Query Fan-Out
62
+
63
+
64
+ :param analyze_url_request: (required)
65
+ :type analyze_url_request: AnalyzeURLRequest
66
+ :param authorization:
67
+ :type authorization: str
68
+ :param _request_timeout: timeout setting for this request. If one
69
+ number provided, it will be total request
70
+ timeout. It can also be a pair (tuple) of
71
+ (connection, read) timeouts.
72
+ :type _request_timeout: int, tuple(int, int), optional
73
+ :param _request_auth: set to override the auth_settings for an a single
74
+ request; this effectively ignores the
75
+ authentication in the spec for a single request.
76
+ :type _request_auth: dict, optional
77
+ :param _content_type: force content-type for the request.
78
+ :type _content_type: str, Optional
79
+ :param _headers: set to override the headers for a single
80
+ request; this effectively ignores the headers
81
+ in the spec for a single request.
82
+ :type _headers: dict, optional
83
+ :param _host_index: set to override the host_index for a single
84
+ request; this effectively ignores the host_index
85
+ in the spec for a single request.
86
+ :type _host_index: int, optional
87
+ :return: Returns the result object.
88
+ """ # noqa: E501
89
+
90
+ _param = self._create_ai_visibility_audit_serialize(
91
+ analyze_url_request=analyze_url_request,
92
+ authorization=authorization,
93
+ _request_auth=_request_auth,
94
+ _content_type=_content_type,
95
+ _headers=_headers,
96
+ _host_index=_host_index
97
+ )
98
+
99
+ _response_types_map: Dict[str, Optional[str]] = {
100
+ '200': "AIVisibilityAnalysisResult",
101
+ '422': "HTTPValidationError",
102
+ }
103
+ response_data = await self.api_client.call_api(
104
+ *_param,
105
+ _request_timeout=_request_timeout
106
+ )
107
+ await response_data.read()
108
+ return self.api_client.response_deserialize(
109
+ response_data=response_data,
110
+ response_types_map=_response_types_map,
111
+ ).data
112
+
113
+
114
+ @validate_call
115
+ async def create_ai_visibility_audit_with_http_info(
116
+ self,
117
+ analyze_url_request: AnalyzeURLRequest,
118
+ authorization: Optional[StrictStr] = None,
119
+ _request_timeout: Union[
120
+ None,
121
+ Annotated[StrictFloat, Field(gt=0)],
122
+ Tuple[
123
+ Annotated[StrictFloat, Field(gt=0)],
124
+ Annotated[StrictFloat, Field(gt=0)]
125
+ ]
126
+ ] = None,
127
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
128
+ _content_type: Optional[StrictStr] = None,
129
+ _headers: Optional[Dict[StrictStr, Any]] = None,
130
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
131
+ ) -> ApiResponse[AIVisibilityAnalysisResult]:
132
+ """Create AI visibility audits for Query Fan-Out
133
+
134
+
135
+ :param analyze_url_request: (required)
136
+ :type analyze_url_request: AnalyzeURLRequest
137
+ :param authorization:
138
+ :type authorization: str
139
+ :param _request_timeout: timeout setting for this request. If one
140
+ number provided, it will be total request
141
+ timeout. It can also be a pair (tuple) of
142
+ (connection, read) timeouts.
143
+ :type _request_timeout: int, tuple(int, int), optional
144
+ :param _request_auth: set to override the auth_settings for an a single
145
+ request; this effectively ignores the
146
+ authentication in the spec for a single request.
147
+ :type _request_auth: dict, optional
148
+ :param _content_type: force content-type for the request.
149
+ :type _content_type: str, Optional
150
+ :param _headers: set to override the headers for a single
151
+ request; this effectively ignores the headers
152
+ in the spec for a single request.
153
+ :type _headers: dict, optional
154
+ :param _host_index: set to override the host_index for a single
155
+ request; this effectively ignores the host_index
156
+ in the spec for a single request.
157
+ :type _host_index: int, optional
158
+ :return: Returns the result object.
159
+ """ # noqa: E501
160
+
161
+ _param = self._create_ai_visibility_audit_serialize(
162
+ analyze_url_request=analyze_url_request,
163
+ authorization=authorization,
164
+ _request_auth=_request_auth,
165
+ _content_type=_content_type,
166
+ _headers=_headers,
167
+ _host_index=_host_index
168
+ )
169
+
170
+ _response_types_map: Dict[str, Optional[str]] = {
171
+ '200': "AIVisibilityAnalysisResult",
172
+ '422': "HTTPValidationError",
173
+ }
174
+ response_data = await self.api_client.call_api(
175
+ *_param,
176
+ _request_timeout=_request_timeout
177
+ )
178
+ await response_data.read()
179
+ return self.api_client.response_deserialize(
180
+ response_data=response_data,
181
+ response_types_map=_response_types_map,
182
+ )
183
+
184
+
185
+ @validate_call
186
+ async def create_ai_visibility_audit_without_preload_content(
187
+ self,
188
+ analyze_url_request: AnalyzeURLRequest,
189
+ authorization: Optional[StrictStr] = None,
190
+ _request_timeout: Union[
191
+ None,
192
+ Annotated[StrictFloat, Field(gt=0)],
193
+ Tuple[
194
+ Annotated[StrictFloat, Field(gt=0)],
195
+ Annotated[StrictFloat, Field(gt=0)]
196
+ ]
197
+ ] = None,
198
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
199
+ _content_type: Optional[StrictStr] = None,
200
+ _headers: Optional[Dict[StrictStr, Any]] = None,
201
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
202
+ ) -> RESTResponseType:
203
+ """Create AI visibility audits for Query Fan-Out
204
+
205
+
206
+ :param analyze_url_request: (required)
207
+ :type analyze_url_request: AnalyzeURLRequest
208
+ :param authorization:
209
+ :type authorization: str
210
+ :param _request_timeout: timeout setting for this request. If one
211
+ number provided, it will be total request
212
+ timeout. It can also be a pair (tuple) of
213
+ (connection, read) timeouts.
214
+ :type _request_timeout: int, tuple(int, int), optional
215
+ :param _request_auth: set to override the auth_settings for an a single
216
+ request; this effectively ignores the
217
+ authentication in the spec for a single request.
218
+ :type _request_auth: dict, optional
219
+ :param _content_type: force content-type for the request.
220
+ :type _content_type: str, Optional
221
+ :param _headers: set to override the headers for a single
222
+ request; this effectively ignores the headers
223
+ in the spec for a single request.
224
+ :type _headers: dict, optional
225
+ :param _host_index: set to override the host_index for a single
226
+ request; this effectively ignores the host_index
227
+ in the spec for a single request.
228
+ :type _host_index: int, optional
229
+ :return: Returns the result object.
230
+ """ # noqa: E501
231
+
232
+ _param = self._create_ai_visibility_audit_serialize(
233
+ analyze_url_request=analyze_url_request,
234
+ authorization=authorization,
235
+ _request_auth=_request_auth,
236
+ _content_type=_content_type,
237
+ _headers=_headers,
238
+ _host_index=_host_index
239
+ )
240
+
241
+ _response_types_map: Dict[str, Optional[str]] = {
242
+ '200': "AIVisibilityAnalysisResult",
243
+ '422': "HTTPValidationError",
244
+ }
245
+ response_data = await self.api_client.call_api(
246
+ *_param,
247
+ _request_timeout=_request_timeout
248
+ )
249
+ return response_data.response
250
+
251
+
252
+ def _create_ai_visibility_audit_serialize(
253
+ self,
254
+ analyze_url_request,
255
+ authorization,
256
+ _request_auth,
257
+ _content_type,
258
+ _headers,
259
+ _host_index,
260
+ ) -> RequestSerialized:
261
+
262
+ _host = None
263
+
264
+ _collection_formats: Dict[str, str] = {
265
+ }
266
+
267
+ _path_params: Dict[str, str] = {}
268
+ _query_params: List[Tuple[str, str]] = []
269
+ _header_params: Dict[str, Optional[str]] = _headers or {}
270
+ _form_params: List[Tuple[str, str]] = []
271
+ _files: Dict[str, Union[str, bytes]] = {}
272
+ _body_params: Optional[bytes] = None
273
+
274
+ # process the path parameters
275
+ # process the query parameters
276
+ # process the header parameters
277
+ if authorization is not None:
278
+ _header_params['authorization'] = authorization
279
+ # process the form parameters
280
+ # process the body parameter
281
+ if analyze_url_request is not None:
282
+ _body_params = analyze_url_request
283
+
284
+
285
+ # set the HTTP header `Accept`
286
+ _header_params['Accept'] = self.api_client.select_header_accept(
287
+ [
288
+ 'application/json'
289
+ ]
290
+ )
291
+
292
+ # set the HTTP header `Content-Type`
293
+ if _content_type:
294
+ _header_params['Content-Type'] = _content_type
295
+ else:
296
+ _default_content_type = (
297
+ self.api_client.select_header_content_type(
298
+ [
299
+ 'application/json'
300
+ ]
301
+ )
302
+ )
303
+ if _default_content_type is not None:
304
+ _header_params['Content-Type'] = _default_content_type
305
+
306
+ # authentication setting
307
+ _auth_settings: List[str] = [
308
+ 'ApiKey'
309
+ ]
310
+
311
+ return self.api_client.param_serialize(
312
+ method='POST',
313
+ resource_path='/ai-visibility-audits',
314
+ path_params=_path_params,
315
+ query_params=_query_params,
316
+ header_params=_header_params,
317
+ body=_body_params,
318
+ post_params=_form_params,
319
+ files=_files,
320
+ auth_settings=_auth_settings,
321
+ collection_formats=_collection_formats,
322
+ _host=_host,
323
+ _request_auth=_request_auth
324
+ )
325
+
326
+
@@ -89,7 +89,7 @@ class ApiClient:
89
89
  self.default_headers[header_name] = header_value
90
90
  self.cookie = cookie
91
91
  # Set default User-Agent.
92
- self.user_agent = 'OpenAPI-Generator/1.125.0/python'
92
+ self.user_agent = 'OpenAPI-Generator/1.127.0/python'
93
93
  self.client_side_validation = configuration.client_side_validation
94
94
 
95
95
  async def __aenter__(self):
@@ -426,7 +426,7 @@ conf = wordlift_client.Configuration(
426
426
  "OS: {env}\n"\
427
427
  "Python Version: {pyversion}\n"\
428
428
  "Version of the API: 1.0\n"\
429
- "SDK Package Version: 1.125.0".\
429
+ "SDK Package Version: 1.127.0".\
430
430
  format(env=sys.platform, pyversion=sys.version)
431
431
 
432
432
  def get_host_settings(self):
@@ -15,6 +15,7 @@
15
15
 
16
16
 
17
17
  # import models into model package
18
+ from wordlift_client.models.ai_visibility_analysis_result import AIVisibilityAnalysisResult
18
19
  from wordlift_client.models.account import Account
19
20
  from wordlift_client.models.account_config import AccountConfig
20
21
  from wordlift_client.models.account_info import AccountInfo
@@ -28,6 +29,7 @@ from wordlift_client.models.analyses_response_item import AnalysesResponseItem
28
29
  from wordlift_client.models.analytics_import_request import AnalyticsImportRequest
29
30
  from wordlift_client.models.analytics_sync import AnalyticsSync
30
31
  from wordlift_client.models.analytics_sync_request import AnalyticsSyncRequest
32
+ from wordlift_client.models.analyze_url_request import AnalyzeURLRequest
31
33
  from wordlift_client.models.anchor_text import AnchorText
32
34
  from wordlift_client.models.annotation import Annotation
33
35
  from wordlift_client.models.ask_request import AskRequest
@@ -146,6 +148,7 @@ from wordlift_client.models.problem_detail import ProblemDetail
146
148
  from wordlift_client.models.project_type import ProjectType
147
149
  from wordlift_client.models.properties import Properties
148
150
  from wordlift_client.models.properties1 import Properties1
151
+ from wordlift_client.models.query_coverage import QueryCoverage
149
152
  from wordlift_client.models.question_and_answer import QuestionAndAnswer
150
153
  from wordlift_client.models.question_and_answer_request import QuestionAndAnswerRequest
151
154
  from wordlift_client.models.quick_win import QuickWin
@@ -0,0 +1,116 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ WordLift API
5
+
6
+ WordLift API
7
+
8
+ The version of the OpenAPI document: 1.0
9
+ Contact: hello@wordlift.io
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
+
12
+ Do not edit the class manually.
13
+ """ # noqa: E501
14
+
15
+
16
+ from __future__ import annotations
17
+ import pprint
18
+ import re # noqa: F401
19
+ import json
20
+
21
+ from pydantic import BaseModel, ConfigDict, StrictFloat, StrictInt, StrictStr
22
+ from typing import Any, ClassVar, Dict, List, Union
23
+ from wordlift_client.models.query_coverage import QueryCoverage
24
+ from typing import Optional, Set
25
+ from typing_extensions import Self
26
+
27
+ class AIVisibilityAnalysisResult(BaseModel):
28
+ """
29
+ AIVisibilityAnalysisResult
30
+ """ # noqa: E501
31
+ url: StrictStr
32
+ num_queries_requested: StrictInt
33
+ coverage_threshold: Union[StrictFloat, StrictInt]
34
+ entity_name: StrictStr
35
+ query_reasoning: StrictStr
36
+ covered_count: StrictInt
37
+ total_queries: StrictInt
38
+ query_details: List[QueryCoverage]
39
+ content_chunks_count: StrictInt
40
+ coverage_score: Union[StrictFloat, StrictInt]
41
+ __properties: ClassVar[List[str]] = ["url", "num_queries_requested", "coverage_threshold", "entity_name", "query_reasoning", "covered_count", "total_queries", "query_details", "content_chunks_count", "coverage_score"]
42
+
43
+ model_config = ConfigDict(
44
+ populate_by_name=True,
45
+ validate_assignment=True,
46
+ protected_namespaces=(),
47
+ )
48
+
49
+
50
+ def to_str(self) -> str:
51
+ """Returns the string representation of the model using alias"""
52
+ return pprint.pformat(self.model_dump(by_alias=True))
53
+
54
+ def to_json(self) -> str:
55
+ """Returns the JSON representation of the model using alias"""
56
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
57
+ return json.dumps(self.to_dict())
58
+
59
+ @classmethod
60
+ def from_json(cls, json_str: str) -> Optional[Self]:
61
+ """Create an instance of AIVisibilityAnalysisResult from a JSON string"""
62
+ return cls.from_dict(json.loads(json_str))
63
+
64
+ def to_dict(self) -> Dict[str, Any]:
65
+ """Return the dictionary representation of the model using alias.
66
+
67
+ This has the following differences from calling pydantic's
68
+ `self.model_dump(by_alias=True)`:
69
+
70
+ * `None` is only added to the output dict for nullable fields that
71
+ were set at model initialization. Other fields with value `None`
72
+ are ignored.
73
+ * OpenAPI `readOnly` fields are excluded.
74
+ """
75
+ excluded_fields: Set[str] = set([
76
+ "coverage_score",
77
+ ])
78
+
79
+ _dict = self.model_dump(
80
+ by_alias=True,
81
+ exclude=excluded_fields,
82
+ exclude_none=True,
83
+ )
84
+ # override the default output from pydantic by calling `to_dict()` of each item in query_details (list)
85
+ _items = []
86
+ if self.query_details:
87
+ for _item in self.query_details:
88
+ if _item:
89
+ _items.append(_item.to_dict())
90
+ _dict['query_details'] = _items
91
+ return _dict
92
+
93
+ @classmethod
94
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
95
+ """Create an instance of AIVisibilityAnalysisResult from a dict"""
96
+ if obj is None:
97
+ return None
98
+
99
+ if not isinstance(obj, dict):
100
+ return cls.model_validate(obj)
101
+
102
+ _obj = cls.model_validate({
103
+ "url": obj.get("url"),
104
+ "num_queries_requested": obj.get("num_queries_requested"),
105
+ "coverage_threshold": obj.get("coverage_threshold"),
106
+ "entity_name": obj.get("entity_name"),
107
+ "query_reasoning": obj.get("query_reasoning"),
108
+ "covered_count": obj.get("covered_count"),
109
+ "total_queries": obj.get("total_queries"),
110
+ "query_details": [QueryCoverage.from_dict(_item) for _item in obj["query_details"]] if obj.get("query_details") is not None else None,
111
+ "content_chunks_count": obj.get("content_chunks_count"),
112
+ "coverage_score": obj.get("coverage_score")
113
+ })
114
+ return _obj
115
+
116
+
@@ -0,0 +1,93 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ WordLift API
5
+
6
+ WordLift API
7
+
8
+ The version of the OpenAPI document: 1.0
9
+ Contact: hello@wordlift.io
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
+
12
+ Do not edit the class manually.
13
+ """ # noqa: E501
14
+
15
+
16
+ from __future__ import annotations
17
+ import pprint
18
+ import re # noqa: F401
19
+ import json
20
+
21
+ from pydantic import BaseModel, ConfigDict, Field
22
+ from typing import Any, ClassVar, Dict, List, Optional, Union
23
+ from typing_extensions import Annotated
24
+ from typing import Optional, Set
25
+ from typing_extensions import Self
26
+
27
+ class AnalyzeURLRequest(BaseModel):
28
+ """
29
+ AnalyzeURLRequest
30
+ """ # noqa: E501
31
+ url: Annotated[str, Field(min_length=1, strict=True, max_length=2083)] = Field(description="The URL to analyze")
32
+ num_queries: Optional[Annotated[int, Field(le=20, strict=True, ge=1)]] = Field(default=10, description="Number of synthetic queries to generate")
33
+ coverage_threshold: Optional[Union[Annotated[float, Field(le=1, strict=True, ge=0)], Annotated[int, Field(le=1, strict=True, ge=0)]]] = Field(default=0.65, description="The threshold for answering synthetic queries")
34
+ __properties: ClassVar[List[str]] = ["url", "num_queries", "coverage_threshold"]
35
+
36
+ model_config = ConfigDict(
37
+ populate_by_name=True,
38
+ validate_assignment=True,
39
+ protected_namespaces=(),
40
+ )
41
+
42
+
43
+ def to_str(self) -> str:
44
+ """Returns the string representation of the model using alias"""
45
+ return pprint.pformat(self.model_dump(by_alias=True))
46
+
47
+ def to_json(self) -> str:
48
+ """Returns the JSON representation of the model using alias"""
49
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
50
+ return json.dumps(self.to_dict())
51
+
52
+ @classmethod
53
+ def from_json(cls, json_str: str) -> Optional[Self]:
54
+ """Create an instance of AnalyzeURLRequest from a JSON string"""
55
+ return cls.from_dict(json.loads(json_str))
56
+
57
+ def to_dict(self) -> Dict[str, Any]:
58
+ """Return the dictionary representation of the model using alias.
59
+
60
+ This has the following differences from calling pydantic's
61
+ `self.model_dump(by_alias=True)`:
62
+
63
+ * `None` is only added to the output dict for nullable fields that
64
+ were set at model initialization. Other fields with value `None`
65
+ are ignored.
66
+ """
67
+ excluded_fields: Set[str] = set([
68
+ ])
69
+
70
+ _dict = self.model_dump(
71
+ by_alias=True,
72
+ exclude=excluded_fields,
73
+ exclude_none=True,
74
+ )
75
+ return _dict
76
+
77
+ @classmethod
78
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
79
+ """Create an instance of AnalyzeURLRequest from a dict"""
80
+ if obj is None:
81
+ return None
82
+
83
+ if not isinstance(obj, dict):
84
+ return cls.model_validate(obj)
85
+
86
+ _obj = cls.model_validate({
87
+ "url": obj.get("url"),
88
+ "num_queries": obj.get("num_queries") if obj.get("num_queries") is not None else 10,
89
+ "coverage_threshold": obj.get("coverage_threshold") if obj.get("coverage_threshold") is not None else 0.65
90
+ })
91
+ return _obj
92
+
93
+
@@ -0,0 +1,94 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ WordLift API
5
+
6
+ WordLift API
7
+
8
+ The version of the OpenAPI document: 1.0
9
+ Contact: hello@wordlift.io
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
+
12
+ Do not edit the class manually.
13
+ """ # noqa: E501
14
+
15
+
16
+ from __future__ import annotations
17
+ import pprint
18
+ import re # noqa: F401
19
+ import json
20
+
21
+ from pydantic import BaseModel, ConfigDict, StrictBool, StrictFloat, StrictInt, StrictStr
22
+ from typing import Any, ClassVar, Dict, List, Union
23
+ from typing import Optional, Set
24
+ from typing_extensions import Self
25
+
26
+ class QueryCoverage(BaseModel):
27
+ """
28
+ QueryCoverage
29
+ """ # noqa: E501
30
+ query: StrictStr
31
+ is_covered: StrictBool
32
+ similarity: Union[StrictFloat, StrictInt]
33
+ best_chunk_preview: StrictStr
34
+ __properties: ClassVar[List[str]] = ["query", "is_covered", "similarity", "best_chunk_preview"]
35
+
36
+ model_config = ConfigDict(
37
+ populate_by_name=True,
38
+ validate_assignment=True,
39
+ protected_namespaces=(),
40
+ )
41
+
42
+
43
+ def to_str(self) -> str:
44
+ """Returns the string representation of the model using alias"""
45
+ return pprint.pformat(self.model_dump(by_alias=True))
46
+
47
+ def to_json(self) -> str:
48
+ """Returns the JSON representation of the model using alias"""
49
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
50
+ return json.dumps(self.to_dict())
51
+
52
+ @classmethod
53
+ def from_json(cls, json_str: str) -> Optional[Self]:
54
+ """Create an instance of QueryCoverage from a JSON string"""
55
+ return cls.from_dict(json.loads(json_str))
56
+
57
+ def to_dict(self) -> Dict[str, Any]:
58
+ """Return the dictionary representation of the model using alias.
59
+
60
+ This has the following differences from calling pydantic's
61
+ `self.model_dump(by_alias=True)`:
62
+
63
+ * `None` is only added to the output dict for nullable fields that
64
+ were set at model initialization. Other fields with value `None`
65
+ are ignored.
66
+ """
67
+ excluded_fields: Set[str] = set([
68
+ ])
69
+
70
+ _dict = self.model_dump(
71
+ by_alias=True,
72
+ exclude=excluded_fields,
73
+ exclude_none=True,
74
+ )
75
+ return _dict
76
+
77
+ @classmethod
78
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
79
+ """Create an instance of QueryCoverage from a dict"""
80
+ if obj is None:
81
+ return None
82
+
83
+ if not isinstance(obj, dict):
84
+ return cls.model_validate(obj)
85
+
86
+ _obj = cls.model_validate({
87
+ "query": obj.get("query"),
88
+ "is_covered": obj.get("is_covered"),
89
+ "similarity": obj.get("similarity"),
90
+ "best_chunk_preview": obj.get("best_chunk_preview")
91
+ })
92
+ return _obj
93
+
94
+
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: wordlift-client
3
- Version: 1.125.0
3
+ Version: 1.127.0
4
4
  Summary: WordLift API
5
5
  Home-page:
6
6
  Author: WordLift
@@ -1,17 +1,18 @@
1
- wordlift_client/__init__.py,sha256=iXu3Zo9pb4XhmLw14wLMdwaj1QXeuxRnlajLy-DvhWc,19924
2
- wordlift_client/api_client.py,sha256=OgQYk9oKCoaugvRbDU6jttk7Itwq_3jZqQC_bIbcYqs,26397
1
+ wordlift_client/__init__.py,sha256=ul82y3xlaiQQbpW4OcWTIA5NNHvP1ZBLqeIdVf2CYDc,20219
2
+ wordlift_client/api_client.py,sha256=zLm4sF5bAe5JRn7vW9KajN02NqCz9z8k6dIXNHfUe6w,26397
3
3
  wordlift_client/api_response.py,sha256=eMxw1mpmJcoGZ3gs9z6jM4oYoZ10Gjk333s9sKxGv7s,652
4
- wordlift_client/configuration.py,sha256=-tL1kSArEyQzMYyeK533c0OHwy6u3CGRxvwix-cBXik,15932
4
+ wordlift_client/configuration.py,sha256=564JXIfwgZHK6BeBhybYVlSst7o7LZ6dJi40MCrmgIA,15932
5
5
  wordlift_client/exceptions.py,sha256=KvTu-E964XhAzMXOSfVycfOL1Eeraob5bgD4CfElD7M,5912
6
6
  wordlift_client/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
7
  wordlift_client/rest.py,sha256=3D4hicZkeSFLxmhmgnlH63K7P39ToGyPk_3aQlHGznI,6817
8
- wordlift_client/api/__init__.py,sha256=ZFtlLTTprWNEj_vslrt3v3nploOs7k1X7XAAixnYIN4,5031
8
+ wordlift_client/api/__init__.py,sha256=k7DpBQqbu6cTWKxrysIfdyzj8SzA_06DYZyT80OJoQo,5097
9
9
  wordlift_client/api/account_api.py,sha256=wxVhHEPyMfNpC1_sBLp2nECfvyGIVwlqqM2Xu3EGSHI,10288
10
10
  wordlift_client/api/account_google_search_console_api.py,sha256=QruHrGZ1LMRhVrVt5k1UOAQZSkMY8zMZWkQ2DdeD5Dw,12119
11
11
  wordlift_client/api/account_stats_api.py,sha256=tQshIfkbME-WMY-sBMwUUZdSTDBeoaV0wnrtAnaFv_g,10480
12
12
  wordlift_client/api/accounts_api.py,sha256=Lk8vONdxCPROiRllJKmvbT_IrryDFDZ2bpSbrklUAZU,48479
13
13
  wordlift_client/api/add_ons_api.py,sha256=BshQhozQWz1r9VGRFXwfUQF46kqoXXhiQvngGwAuDu4,12439
14
14
  wordlift_client/api/agent_api.py,sha256=2UwVNrNKWTPWYWS5TJm2Cucn5i9n3DiaKvcIn5Ol7YI,11591
15
+ wordlift_client/api/ai_visibility_api.py,sha256=CfuOGWLl92Vx7k_w-tmj4WOBiyDfPI2sh9hvMwPAv9g,12393
15
16
  wordlift_client/api/analyses_api.py,sha256=S4VB2WoTG5WuPdg4xdrLfAR47YrUQzNmoVmVSTdcdvk,42549
16
17
  wordlift_client/api/analytics_imports_api.py,sha256=3H2K6QLm7gFck67KCnIXLrKbxsKwjteNgTHD1utDE3s,11969
17
18
  wordlift_client/api/analytics_syncs_api.py,sha256=yblLuk2iz9zjqT8rRkmVb7C1rPPxmOcLFnuMpSqq3-Q,22587
@@ -80,7 +81,7 @@ wordlift_client/api/web_asyncs_metadata_api.py,sha256=cpDQmIGc6uHu5rFXwZAy1cVgcW
80
81
  wordlift_client/api/web_asyncs_responses_api.py,sha256=h91xI3iIgGoMUcZ7Oft5xiLy0rHh_2qzZDrFTRz3P8w,10889
81
82
  wordlift_client/api/web_pages_api.py,sha256=VKPLIaQRxxDn3daP0zvXRiHj2eegsZIjxUmHKzxZXoc,10839
82
83
  wordlift_client/api/web_pages_imports_api.py,sha256=yPhNLZ1jV2dEDnYuHb7OpiFH3K2ROrRYHG4ZrAf4VMU,11719
83
- wordlift_client/models/__init__.py,sha256=JiVI6hniFzJl7yIWkF_uALxoroNrgbZjUiS2clqtgps,14386
84
+ wordlift_client/models/__init__.py,sha256=do9iR5985QQzxIqdpUgLK1w5m6otQkkw7QX5YyLXsEQ,14615
84
85
  wordlift_client/models/account.py,sha256=trGNzy3ZBGE1VsSke4aoXBQem-3jK60xVz0OWOOMWso,5523
85
86
  wordlift_client/models/account_config.py,sha256=_4YZ8IGS4h16wa9aSaL9rpeoZYR8faiwEAtovP4eBVI,2592
86
87
  wordlift_client/models/account_info.py,sha256=tCqVHqfeK5u1cQkLOBgJRUTs-e8vmGCjqZ4wgfmNIuw,7750
@@ -88,12 +89,14 @@ wordlift_client/models/account_stats.py,sha256=hMtiIDYGGMp4ytKgvgBIx40U5EyWr6-IJ
88
89
  wordlift_client/models/account_subscription.py,sha256=hJNuMXCDt9EqLvp3vfgv2xMc1Uk7UQ7gzTM320MsPbk,2858
89
90
  wordlift_client/models/active_account.py,sha256=rFDPX3X2hwMQfMnURcLEPgb9W5NGE1xmDIQhPZRMXQA,5707
90
91
  wordlift_client/models/add_on_configuration.py,sha256=8sEIAr91rjmj-A3B1vGUVlZkc_hVxOSmO_Irt4irhz4,3731
92
+ wordlift_client/models/ai_visibility_analysis_result.py,sha256=vyn8S5FK_-Wcx5BnJOUhNKwvK52P-q-VK16wSaA-TYo,4095
91
93
  wordlift_client/models/analyses_request.py,sha256=_D_X2nN1Dkq835XUs8rinSSNOgQf5nXrFUV_YFbUI6E,4553
92
94
  wordlift_client/models/analyses_response.py,sha256=Nd7Tm2Cll3zqLCAx6KpgaY-dqQgmYLwKxnICOBBdmhU,2924
93
95
  wordlift_client/models/analyses_response_item.py,sha256=A-Xu3xm-XsOLfcxQa4ULb6p_T3CUXcrz7jVmzg3cBvM,3906
94
96
  wordlift_client/models/analytics_import_request.py,sha256=yfc37Vz_NnDWJrH8GpRke9-paSFbe__v9IJknIaKWHc,2538
95
97
  wordlift_client/models/analytics_sync.py,sha256=0H_ac6_00mNBBdfninOli6Bq_Rr9RdjZKZf-qLGSWt4,5415
96
98
  wordlift_client/models/analytics_sync_request.py,sha256=TWvOIfsF2V1_zJSC8NhUwB7WXiD2fEguqAQ4KmY-Z-s,2487
99
+ wordlift_client/models/analyze_url_request.py,sha256=-NCLEKVLL2SzpdcGDzqy1gJLRywWvPfAeKzNTg0hagg,3196
97
100
  wordlift_client/models/anchor_text.py,sha256=O0vQxxJfMhzWZ66-39bilO_cc1v89iyMaypoeK3YrFQ,4364
98
101
  wordlift_client/models/annotation.py,sha256=HRjN8hQ-Xz-rUOdLYTgUhucJ-vDATKhFSj1wRFqBMtw,3795
99
102
  wordlift_client/models/ask_request.py,sha256=sot1ueKn5jB6cWK6XETvaUjDcRINCCsUm-n-0cX4lWI,2712
@@ -217,6 +220,7 @@ wordlift_client/models/problem_detail.py,sha256=4_7xA64rpygLnTPtKyCYLeOcjBKs0GID
217
220
  wordlift_client/models/project_type.py,sha256=nUZ2YFzVSArByM6HMCzVdR7GH2cab22RcwhD5ROPqPM,745
218
221
  wordlift_client/models/properties.py,sha256=MiXOK8WyyBI_n-SCFq0ZFzyiNesx3IRud9FHculCk4g,2657
219
222
  wordlift_client/models/properties1.py,sha256=bcVIqb9yCa3bLztYT3Z8hwcTbNhz_FuBvzwnES6s05s,2712
223
+ wordlift_client/models/query_coverage.py,sha256=O3_omdnagA9UyMU8DrZHgxzqRXim0KxCQof4ovB5LZc,2775
220
224
  wordlift_client/models/question_and_answer.py,sha256=y2-ZyG-KKlRQZzG-u8GX2QB_w8FiWKS24x5ngbJOQMs,5655
221
225
  wordlift_client/models/question_and_answer_request.py,sha256=yPMv-dFIkCkyMD0mwfYujvecVo0TAhEVy6gkHKOCwzc,3111
222
226
  wordlift_client/models/quick_win.py,sha256=WVcvUhh0uii0QYbEF-7CGvs-NtUO6lbZzLkcu8tZhgc,3187
@@ -276,8 +280,8 @@ wordlift_client/models/with_limits.py,sha256=rSzDb_If8APxR2Rw2U6cfFRFubnnai3Vj3-
276
280
  wordlift_client/models/word.py,sha256=FPCGb6ohwdfydE5_qG4PT-UrnMzaTktAWqEEnezwaso,3922
277
281
  wordlift_client/models/word_repetition_data.py,sha256=CQnxCnhakt12czl6a_AQIPgHlJtvR9YGBIjGV22rq14,2659
278
282
  wordlift_client/models/word_request.py,sha256=ZD13xNRYCZmF14jxEDrRRyEMAd-quDT-HsqkbUP_xWU,2627
279
- wordlift_client-1.125.0.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
280
- wordlift_client-1.125.0.dist-info/METADATA,sha256=33SE7W7PVoOAKyJeg6IEmZDZhRcF6yiRuuSR2M_t8a8,530
281
- wordlift_client-1.125.0.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
282
- wordlift_client-1.125.0.dist-info/top_level.txt,sha256=p7KFYU869ksxkpP7ADvg8baPgWkTYCzcOpDl1qrJdHk,16
283
- wordlift_client-1.125.0.dist-info/RECORD,,
283
+ wordlift_client-1.127.0.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
284
+ wordlift_client-1.127.0.dist-info/METADATA,sha256=KAnzJQceFC2xKltBI-CZthbor4g5yQrl7YjLtNB4mIc,530
285
+ wordlift_client-1.127.0.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
286
+ wordlift_client-1.127.0.dist-info/top_level.txt,sha256=p7KFYU869ksxkpP7ADvg8baPgWkTYCzcOpDl1qrJdHk,16
287
+ wordlift_client-1.127.0.dist-info/RECORD,,