airbyte-agent-shopify 0.1.16__py3-none-any.whl → 0.1.21__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.
@@ -13,14 +13,14 @@ from .models import (
13
13
  CustomerAddressList,
14
14
  MarketingConsent,
15
15
  OrderAddress,
16
- LineItem,
17
- Fulfillment,
18
16
  Transaction,
19
17
  Refund,
18
+ LineItem,
19
+ Fulfillment,
20
20
  Order,
21
21
  OrderList,
22
- ProductVariant,
23
22
  ProductImage,
23
+ ProductVariant,
24
24
  Product,
25
25
  ProductList,
26
26
  ProductVariantList,
@@ -88,6 +88,7 @@ from .models import (
88
88
  MetafieldProductImagesListResultMeta,
89
89
  CustomerAddressListResultMeta,
90
90
  FulfillmentOrdersListResultMeta,
91
+ ShopifyCheckResult,
91
92
  ShopifyExecuteResult,
92
93
  ShopifyExecuteResultWithMeta,
93
94
  CustomersListResult,
@@ -186,14 +187,14 @@ __all__ = [
186
187
  "CustomerAddressList",
187
188
  "MarketingConsent",
188
189
  "OrderAddress",
189
- "LineItem",
190
- "Fulfillment",
191
190
  "Transaction",
192
191
  "Refund",
192
+ "LineItem",
193
+ "Fulfillment",
193
194
  "Order",
194
195
  "OrderList",
195
- "ProductVariant",
196
196
  "ProductImage",
197
+ "ProductVariant",
197
198
  "Product",
198
199
  "ProductList",
199
200
  "ProductVariantList",
@@ -261,6 +262,7 @@ __all__ = [
261
262
  "MetafieldProductImagesListResultMeta",
262
263
  "CustomerAddressListResultMeta",
263
264
  "FulfillmentOrdersListResultMeta",
265
+ "ShopifyCheckResult",
264
266
  "ShopifyExecuteResult",
265
267
  "ShopifyExecuteResultWithMeta",
266
268
  "CustomersListResult",
@@ -496,6 +496,9 @@ def convert_openapi_to_connector_model(spec: OpenAPIConnector) -> ConnectorModel
496
496
  # Extract untested flag
497
497
  untested = getattr(operation, "x_airbyte_untested", None) or False
498
498
 
499
+ # Extract preferred_for_check flag
500
+ preferred_for_check = getattr(operation, "x_airbyte_preferred_for_check", None) or False
501
+
499
502
  # Create endpoint definition
500
503
  endpoint = EndpointDefinition(
501
504
  method=method_name.upper(),
@@ -520,6 +523,7 @@ def convert_openapi_to_connector_model(spec: OpenAPIConnector) -> ConnectorModel
520
523
  graphql_body=graphql_body,
521
524
  file_field=file_field,
522
525
  untested=untested,
526
+ preferred_for_check=preferred_for_check,
523
527
  )
524
528
 
525
529
  # Add to entities map
@@ -164,6 +164,11 @@ class HostedExecutor:
164
164
  span.record_exception(e)
165
165
  raise
166
166
 
167
+ async def check(self) -> ExecutionResult:
168
+ """Perform a health check via the cloud API."""
169
+ config = ExecutionConfig(entity="*", action="check", params={})
170
+ return await self.execute(config)
171
+
167
172
  def _parse_execution_result(self, response: dict) -> ExecutionResult:
168
173
  """Parse API response into ExecutionResult.
169
174
 
@@ -70,6 +70,14 @@ class _OperationContext:
70
70
  self.validate_required_body_fields = executor._validate_required_body_fields
71
71
  self.extract_records = executor._extract_records
72
72
 
73
+ @property
74
+ def standard_handler(self) -> _StandardOperationHandler | None:
75
+ """Return the standard operation handler, or None if not registered."""
76
+ for h in self.executor._operation_handlers:
77
+ if isinstance(h, _StandardOperationHandler):
78
+ return h
79
+ return None
80
+
73
81
 
74
82
  class _OperationHandler(Protocol):
75
83
  """Protocol for operation handlers."""
@@ -544,6 +552,79 @@ class LocalExecutor:
544
552
  # These are "expected" execution errors - return them in ExecutionResult
545
553
  return ExecutionResult(success=False, data={}, error=str(e))
546
554
 
555
+ async def check(self) -> ExecutionResult:
556
+ """Perform a health check by running a lightweight list operation.
557
+
558
+ Finds the operation marked with preferred_for_check=True, or falls back
559
+ to the first list operation. Executes it with limit=1 to verify
560
+ connectivity and credentials.
561
+
562
+ Returns:
563
+ ExecutionResult with data containing status, error, and checked operation details.
564
+ """
565
+ check_entity = None
566
+ check_endpoint = None
567
+
568
+ # Look for preferred check operation
569
+ for (ent_name, op_action), endpoint in self._operation_index.items():
570
+ if getattr(endpoint, "preferred_for_check", False):
571
+ check_entity = ent_name
572
+ check_endpoint = endpoint
573
+ break
574
+
575
+ # Fallback to first list operation
576
+ if check_endpoint is None:
577
+ for (ent_name, op_action), endpoint in self._operation_index.items():
578
+ if op_action == Action.LIST:
579
+ check_entity = ent_name
580
+ check_endpoint = endpoint
581
+ break
582
+
583
+ if check_endpoint is None or check_entity is None:
584
+ return ExecutionResult(
585
+ success=True,
586
+ data={
587
+ "status": "unhealthy",
588
+ "error": "No list operation available for health check",
589
+ },
590
+ )
591
+
592
+ # Find the standard handler to execute the list operation
593
+ standard_handler = next(
594
+ (h for h in self._operation_handlers if isinstance(h, _StandardOperationHandler)),
595
+ None,
596
+ )
597
+
598
+ if standard_handler is None:
599
+ return ExecutionResult(
600
+ success=True,
601
+ data={
602
+ "status": "unhealthy",
603
+ "error": "No standard handler available",
604
+ },
605
+ )
606
+
607
+ try:
608
+ await standard_handler.execute_operation(check_entity, Action.LIST, {"limit": 1})
609
+ return ExecutionResult(
610
+ success=True,
611
+ data={
612
+ "status": "healthy",
613
+ "checked_entity": check_entity,
614
+ "checked_action": "list",
615
+ },
616
+ )
617
+ except Exception as e:
618
+ return ExecutionResult(
619
+ success=True,
620
+ data={
621
+ "status": "unhealthy",
622
+ "error": str(e),
623
+ "checked_entity": check_entity,
624
+ "checked_action": "list",
625
+ },
626
+ )
627
+
547
628
  async def _execute_operation(
548
629
  self,
549
630
  entity: str,
@@ -154,6 +154,18 @@ class ExecutorProtocol(Protocol):
154
154
  """
155
155
  ...
156
156
 
157
+ async def check(self) -> ExecutionResult:
158
+ """Perform a health check to verify connectivity and credentials.
159
+
160
+ Returns:
161
+ ExecutionResult with data containing:
162
+ - status: "healthy" or "unhealthy"
163
+ - error: Error message if unhealthy
164
+ - checked_entity: Entity used for the check
165
+ - checked_action: Action used for the check
166
+ """
167
+ ...
168
+
157
169
 
158
170
  # ============================================================================
159
171
  # Executor Exceptions
@@ -380,7 +380,11 @@ def describe_entities(model: ConnectorModelProtocol) -> list[dict[str, Any]]:
380
380
  return entities
381
381
 
382
382
 
383
- def generate_tool_description(model: ConnectorModelProtocol) -> str:
383
+ def generate_tool_description(
384
+ model: ConnectorModelProtocol,
385
+ *,
386
+ enable_hosted_mode_features: bool = True,
387
+ ) -> str:
384
388
  """Generate AI tool description from connector metadata.
385
389
 
386
390
  Produces a detailed description that includes:
@@ -393,6 +397,7 @@ def generate_tool_description(model: ConnectorModelProtocol) -> str:
393
397
 
394
398
  Args:
395
399
  model: Object conforming to ConnectorModelProtocol (e.g., ConnectorModel)
400
+ enable_hosted_mode_features: When False, omit hosted-mode search guidance from the docstring.
396
401
 
397
402
  Returns:
398
403
  Formatted description string suitable for AI tool documentation
@@ -402,8 +407,9 @@ def generate_tool_description(model: ConnectorModelProtocol) -> str:
402
407
  # at the first empty line and only keeps the initial section.
403
408
 
404
409
  # Entity/action parameter details (including pagination params like limit, starting_after)
405
- search_field_paths = _collect_search_field_paths(model)
406
- lines.append("ENTITIES AND PARAMETERS:")
410
+ search_field_paths = _collect_search_field_paths(model) if enable_hosted_mode_features else {}
411
+ # Avoid a "PARAMETERS:" header because some docstring parsers treat it as a params section marker.
412
+ lines.append("ENTITIES (ACTIONS + PARAMS):")
407
413
  for entity in model.entities:
408
414
  lines.append(f" {entity.name}:")
409
415
  actions = getattr(entity, "actions", []) or []
@@ -427,8 +433,9 @@ def generate_tool_description(model: ConnectorModelProtocol) -> str:
427
433
  lines.append(" To paginate: pass starting_after=<last_id> while has_more is true")
428
434
 
429
435
  lines.append("GUIDELINES:")
430
- lines.append(' - Prefer cached search over direct API calls when using execute(): action="search" whenever possible.')
431
- lines.append(" - Direct API actions (list/get/download) are slower and should be used only if search cannot answer the query.")
436
+ if enable_hosted_mode_features:
437
+ lines.append(' - Prefer cached search over direct API calls when using execute(): action="search" whenever possible.')
438
+ lines.append(" - Direct API actions (list/get/download) are slower and should be used only if search cannot answer the query.")
432
439
  lines.append(" - Keep results small: use params.fields, params.query.filter, small params.limit, and cursor pagination.")
433
440
  lines.append(" - If output is too large, refine the query with tighter filters/fields/limit.")
434
441
 
@@ -86,6 +86,16 @@ class Operation(BaseModel):
86
86
  "Validation will generate a warning instead of an error when cassettes are missing."
87
87
  ),
88
88
  )
89
+ x_airbyte_preferred_for_check: bool | None = Field(
90
+ None,
91
+ alias="x-airbyte-preferred-for-check",
92
+ description=(
93
+ "Mark this list operation as the preferred operation for health checks. "
94
+ "When the CHECK action is executed, this operation will be used instead of "
95
+ "falling back to the first available list operation. Choose a lightweight, "
96
+ "always-available endpoint (e.g., users, accounts)."
97
+ ),
98
+ )
89
99
 
90
100
  # Future extensions (commented out, defined for future use)
91
101
  # from .extensions import PaginationConfig
@@ -3,7 +3,7 @@
3
3
  import logging
4
4
  import platform
5
5
  import sys
6
- from datetime import datetime
6
+ from datetime import UTC, datetime
7
7
 
8
8
  from ..observability import ObservabilitySession
9
9
 
@@ -56,7 +56,7 @@ class SegmentTracker:
56
56
 
57
57
  try:
58
58
  event = ConnectorInitEvent(
59
- timestamp=datetime.utcnow(),
59
+ timestamp=datetime.now(UTC),
60
60
  session_id=self.session.session_id,
61
61
  user_id=self.session.user_id,
62
62
  execution_context=self.session.execution_context,
@@ -99,7 +99,7 @@ class SegmentTracker:
99
99
 
100
100
  try:
101
101
  event = OperationEvent(
102
- timestamp=datetime.utcnow(),
102
+ timestamp=datetime.now(UTC),
103
103
  session_id=self.session.session_id,
104
104
  user_id=self.session.user_id,
105
105
  execution_context=self.session.execution_context,
@@ -129,7 +129,7 @@ class SegmentTracker:
129
129
 
130
130
  try:
131
131
  event = SessionEndEvent(
132
- timestamp=datetime.utcnow(),
132
+ timestamp=datetime.now(UTC),
133
133
  session_id=self.session.session_id,
134
134
  user_id=self.session.user_id,
135
135
  execution_context=self.session.execution_context,
@@ -15,7 +15,16 @@ from .schema.security import AirbyteAuthConfig
15
15
 
16
16
 
17
17
  class Action(str, Enum):
18
- """Supported actions for Entity operations."""
18
+ """Supported actions for Entity operations.
19
+
20
+ Standard CRUD actions:
21
+ GET, CREATE, UPDATE, DELETE, LIST
22
+
23
+ Special actions:
24
+ API_SEARCH - Search via API endpoint
25
+ DOWNLOAD - Download file content
26
+ AUTHORIZE - OAuth authorization flow
27
+ """
19
28
 
20
29
  GET = "get"
21
30
  CREATE = "create"
@@ -223,6 +232,12 @@ class EndpointDefinition(BaseModel):
223
232
  description="Mark operation as untested to skip cassette validation (from x-airbyte-untested extension)",
224
233
  )
225
234
 
235
+ # Health check support (Airbyte extension)
236
+ preferred_for_check: bool = Field(
237
+ False,
238
+ description="Mark this list operation as preferred for health checks (from x-airbyte-preferred-for-check extension)",
239
+ )
240
+
226
241
 
227
242
  class EntityDefinition(BaseModel):
228
243
  """Definition of an API entity."""
@@ -810,11 +810,31 @@ def validate_connector_readiness(connector_dir: str | Path) -> Dict[str, Any]:
810
810
 
811
811
  success = operations_missing_cassettes == 0 and cassettes_invalid == 0 and total_operations > 0
812
812
 
813
+ # Check for preferred_for_check on at least one list operation
814
+ has_preferred_check = False
815
+ for entity in config.entities:
816
+ for action_val in entity.actions:
817
+ endpoint = entity.endpoints.get(action_val)
818
+ if endpoint and getattr(endpoint, "preferred_for_check", False):
819
+ has_preferred_check = True
820
+ break
821
+ if has_preferred_check:
822
+ break
823
+
824
+ readiness_warnings = []
825
+ if not has_preferred_check:
826
+ readiness_warnings.append(
827
+ "No operation has x-airbyte-preferred-for-check: true. "
828
+ "Add this extension to a lightweight list operation (e.g., users.list) "
829
+ "to enable reliable health checks."
830
+ )
831
+
813
832
  return {
814
833
  "success": success,
815
834
  "connector_name": config.name,
816
835
  "connector_path": str(connector_path),
817
836
  "validation_results": validation_results,
837
+ "readiness_warnings": readiness_warnings,
818
838
  "summary": {
819
839
  "total_operations": total_operations,
820
840
  "operations_with_cassettes": operations_with_cassettes,
@@ -74,6 +74,7 @@ if TYPE_CHECKING:
74
74
  from .models import ShopifyAuthConfig
75
75
  # Import response models and envelope models at runtime
76
76
  from .models import (
77
+ ShopifyCheckResult,
77
78
  ShopifyExecuteResult,
78
79
  ShopifyExecuteResultWithMeta,
79
80
  CustomersListResult,
@@ -900,6 +901,40 @@ class ShopifyConnector:
900
901
  # No extractors - return raw response data
901
902
  return result.data
902
903
 
904
+ # ===== HEALTH CHECK METHOD =====
905
+
906
+ async def check(self) -> ShopifyCheckResult:
907
+ """
908
+ Perform a health check to verify connectivity and credentials.
909
+
910
+ Executes a lightweight list operation (limit=1) to validate that
911
+ the connector can communicate with the API and credentials are valid.
912
+
913
+ Returns:
914
+ ShopifyCheckResult with status ("healthy" or "unhealthy") and optional error message
915
+
916
+ Example:
917
+ result = await connector.check()
918
+ if result.status == "healthy":
919
+ print("Connection verified!")
920
+ else:
921
+ print(f"Check failed: {result.error}")
922
+ """
923
+ result = await self._executor.check()
924
+
925
+ if result.success and isinstance(result.data, dict):
926
+ return ShopifyCheckResult(
927
+ status=result.data.get("status", "unhealthy"),
928
+ error=result.data.get("error"),
929
+ checked_entity=result.data.get("checked_entity"),
930
+ checked_action=result.data.get("checked_action"),
931
+ )
932
+ else:
933
+ return ShopifyCheckResult(
934
+ status="unhealthy",
935
+ error=result.error or "Unknown error during health check",
936
+ )
937
+
903
938
  # ===== INTROSPECTION METHODS =====
904
939
 
905
940
  @classmethod
@@ -908,6 +943,7 @@ class ShopifyConnector:
908
943
  func: _F | None = None,
909
944
  *,
910
945
  update_docstring: bool = True,
946
+ enable_hosted_mode_features: bool = True,
911
947
  max_output_chars: int | None = DEFAULT_MAX_OUTPUT_CHARS,
912
948
  ) -> _F | Callable[[_F], _F]:
913
949
  """
@@ -926,12 +962,16 @@ class ShopifyConnector:
926
962
 
927
963
  Args:
928
964
  update_docstring: When True, append connector capabilities to __doc__.
965
+ enable_hosted_mode_features: When False, omit hosted-mode search sections from docstrings.
929
966
  max_output_chars: Max serialized output size before raising. Use None to disable.
930
967
  """
931
968
 
932
969
  def decorate(inner: _F) -> _F:
933
970
  if update_docstring:
934
- description = generate_tool_description(ShopifyConnectorModel)
971
+ description = generate_tool_description(
972
+ ShopifyConnectorModel,
973
+ enable_hosted_mode_features=enable_hosted_mode_features,
974
+ )
935
975
  original_doc = inner.__doc__ or ""
936
976
  if original_doc.strip():
937
977
  full_doc = f"{original_doc.strip()}\n{description}"
@@ -388,6 +388,7 @@ ShopifyConnectorModel: ConnectorModel = ConnectorModel(
388
388
  },
389
389
  record_extractor='$.customers',
390
390
  meta_extractor={'next_page_url': '@link.next'},
391
+ preferred_for_check=True,
391
392
  ),
392
393
  Action.GET: EndpointDefinition(
393
394
  method='GET',
@@ -119,6 +119,55 @@ class OrderAddress(BaseModel):
119
119
  latitude: Union[float | None, Any] = Field(default=None)
120
120
  longitude: Union[float | None, Any] = Field(default=None)
121
121
 
122
+ class Transaction(BaseModel):
123
+ """An order transaction"""
124
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
125
+
126
+ id: Union[int, Any] = Field(default=None)
127
+ order_id: Union[int | None, Any] = Field(default=None)
128
+ kind: Union[str | None, Any] = Field(default=None)
129
+ gateway: Union[str | None, Any] = Field(default=None)
130
+ status: Union[str | None, Any] = Field(default=None)
131
+ message: Union[str | None, Any] = Field(default=None)
132
+ created_at: Union[str | None, Any] = Field(default=None)
133
+ test: Union[bool | None, Any] = Field(default=None)
134
+ authorization: Union[str | None, Any] = Field(default=None)
135
+ location_id: Union[int | None, Any] = Field(default=None)
136
+ user_id: Union[int | None, Any] = Field(default=None)
137
+ parent_id: Union[int | None, Any] = Field(default=None)
138
+ processed_at: Union[str | None, Any] = Field(default=None)
139
+ device_id: Union[int | None, Any] = Field(default=None)
140
+ error_code: Union[str | None, Any] = Field(default=None)
141
+ source_name: Union[str | None, Any] = Field(default=None)
142
+ receipt: Union[dict[str, Any] | None, Any] = Field(default=None)
143
+ currency_exchange_adjustment: Union[dict[str, Any] | None, Any] = Field(default=None)
144
+ amount: Union[str | None, Any] = Field(default=None)
145
+ currency: Union[str | None, Any] = Field(default=None)
146
+ payment_id: Union[str | None, Any] = Field(default=None)
147
+ total_unsettled_set: Union[dict[str, Any] | None, Any] = Field(default=None)
148
+ manual_payment_gateway: Union[bool | None, Any] = Field(default=None)
149
+ admin_graphql_api_id: Union[str | None, Any] = Field(default=None)
150
+
151
+ class Refund(BaseModel):
152
+ """An order refund"""
153
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
154
+
155
+ id: Union[int, Any] = Field(default=None)
156
+ order_id: Union[int | None, Any] = Field(default=None)
157
+ created_at: Union[str | None, Any] = Field(default=None)
158
+ note: Union[str | None, Any] = Field(default=None)
159
+ user_id: Union[int | None, Any] = Field(default=None)
160
+ processed_at: Union[str | None, Any] = Field(default=None)
161
+ restock: Union[bool | None, Any] = Field(default=None)
162
+ duties: Union[list[dict[str, Any]] | None, Any] = Field(default=None)
163
+ total_duties_set: Union[dict[str, Any] | None, Any] = Field(default=None)
164
+ return_: Union[dict[str, Any] | None, Any] = Field(default=None, alias="return")
165
+ refund_line_items: Union[list[dict[str, Any]] | None, Any] = Field(default=None)
166
+ transactions: Union[list[Transaction] | None, Any] = Field(default=None)
167
+ order_adjustments: Union[list[dict[str, Any]] | None, Any] = Field(default=None)
168
+ admin_graphql_api_id: Union[str | None, Any] = Field(default=None)
169
+ refund_shipping_lines: Union[list[dict[str, Any]] | None, Any] = Field(default=None)
170
+
122
171
  class LineItem(BaseModel):
123
172
  """LineItem type definition"""
124
173
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -176,55 +225,6 @@ class Fulfillment(BaseModel):
176
225
  name: Union[str | None, Any] = Field(default=None)
177
226
  admin_graphql_api_id: Union[str | None, Any] = Field(default=None)
178
227
 
179
- class Transaction(BaseModel):
180
- """An order transaction"""
181
- model_config = ConfigDict(extra="allow", populate_by_name=True)
182
-
183
- id: Union[int, Any] = Field(default=None)
184
- order_id: Union[int | None, Any] = Field(default=None)
185
- kind: Union[str | None, Any] = Field(default=None)
186
- gateway: Union[str | None, Any] = Field(default=None)
187
- status: Union[str | None, Any] = Field(default=None)
188
- message: Union[str | None, Any] = Field(default=None)
189
- created_at: Union[str | None, Any] = Field(default=None)
190
- test: Union[bool | None, Any] = Field(default=None)
191
- authorization: Union[str | None, Any] = Field(default=None)
192
- location_id: Union[int | None, Any] = Field(default=None)
193
- user_id: Union[int | None, Any] = Field(default=None)
194
- parent_id: Union[int | None, Any] = Field(default=None)
195
- processed_at: Union[str | None, Any] = Field(default=None)
196
- device_id: Union[int | None, Any] = Field(default=None)
197
- error_code: Union[str | None, Any] = Field(default=None)
198
- source_name: Union[str | None, Any] = Field(default=None)
199
- receipt: Union[dict[str, Any] | None, Any] = Field(default=None)
200
- currency_exchange_adjustment: Union[dict[str, Any] | None, Any] = Field(default=None)
201
- amount: Union[str | None, Any] = Field(default=None)
202
- currency: Union[str | None, Any] = Field(default=None)
203
- payment_id: Union[str | None, Any] = Field(default=None)
204
- total_unsettled_set: Union[dict[str, Any] | None, Any] = Field(default=None)
205
- manual_payment_gateway: Union[bool | None, Any] = Field(default=None)
206
- admin_graphql_api_id: Union[str | None, Any] = Field(default=None)
207
-
208
- class Refund(BaseModel):
209
- """An order refund"""
210
- model_config = ConfigDict(extra="allow", populate_by_name=True)
211
-
212
- id: Union[int, Any] = Field(default=None)
213
- order_id: Union[int | None, Any] = Field(default=None)
214
- created_at: Union[str | None, Any] = Field(default=None)
215
- note: Union[str | None, Any] = Field(default=None)
216
- user_id: Union[int | None, Any] = Field(default=None)
217
- processed_at: Union[str | None, Any] = Field(default=None)
218
- restock: Union[bool | None, Any] = Field(default=None)
219
- duties: Union[list[dict[str, Any]] | None, Any] = Field(default=None)
220
- total_duties_set: Union[dict[str, Any] | None, Any] = Field(default=None)
221
- return_: Union[dict[str, Any] | None, Any] = Field(default=None, alias="return")
222
- refund_line_items: Union[list[dict[str, Any]] | None, Any] = Field(default=None)
223
- transactions: Union[list[Transaction] | None, Any] = Field(default=None)
224
- order_adjustments: Union[list[dict[str, Any]] | None, Any] = Field(default=None)
225
- admin_graphql_api_id: Union[str | None, Any] = Field(default=None)
226
- refund_shipping_lines: Union[list[dict[str, Any]] | None, Any] = Field(default=None)
227
-
228
228
  class Order(BaseModel):
229
229
  """A Shopify order"""
230
230
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -329,6 +329,22 @@ class OrderList(BaseModel):
329
329
 
330
330
  orders: Union[list[Order], Any] = Field(default=None)
331
331
 
332
+ class ProductImage(BaseModel):
333
+ """A product image"""
334
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
335
+
336
+ id: Union[int, Any] = Field(default=None)
337
+ product_id: Union[int | None, Any] = Field(default=None)
338
+ position: Union[int | None, Any] = Field(default=None)
339
+ created_at: Union[str | None, Any] = Field(default=None)
340
+ updated_at: Union[str | None, Any] = Field(default=None)
341
+ alt: Union[str | None, Any] = Field(default=None)
342
+ width: Union[int | None, Any] = Field(default=None)
343
+ height: Union[int | None, Any] = Field(default=None)
344
+ src: Union[str | None, Any] = Field(default=None)
345
+ variant_ids: Union[list[int] | None, Any] = Field(default=None)
346
+ admin_graphql_api_id: Union[str | None, Any] = Field(default=None)
347
+
332
348
  class ProductVariant(BaseModel):
333
349
  """A product variant"""
334
350
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -360,22 +376,6 @@ class ProductVariant(BaseModel):
360
376
  requires_shipping: Union[bool | None, Any] = Field(default=None)
361
377
  admin_graphql_api_id: Union[str | None, Any] = Field(default=None)
362
378
 
363
- class ProductImage(BaseModel):
364
- """A product image"""
365
- model_config = ConfigDict(extra="allow", populate_by_name=True)
366
-
367
- id: Union[int, Any] = Field(default=None)
368
- product_id: Union[int | None, Any] = Field(default=None)
369
- position: Union[int | None, Any] = Field(default=None)
370
- created_at: Union[str | None, Any] = Field(default=None)
371
- updated_at: Union[str | None, Any] = Field(default=None)
372
- alt: Union[str | None, Any] = Field(default=None)
373
- width: Union[int | None, Any] = Field(default=None)
374
- height: Union[int | None, Any] = Field(default=None)
375
- src: Union[str | None, Any] = Field(default=None)
376
- variant_ids: Union[list[int] | None, Any] = Field(default=None)
377
- admin_graphql_api_id: Union[str | None, Any] = Field(default=None)
378
-
379
379
  class Product(BaseModel):
380
380
  """A Shopify product"""
381
381
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1064,6 +1064,25 @@ class FulfillmentOrdersListResultMeta(BaseModel):
1064
1064
 
1065
1065
  next_page_url: Union[str | None, Any] = Field(default=None)
1066
1066
 
1067
+ # ===== CHECK RESULT MODEL =====
1068
+
1069
+ class ShopifyCheckResult(BaseModel):
1070
+ """Result of a health check operation.
1071
+
1072
+ Returned by the check() method to indicate connectivity and credential status.
1073
+ """
1074
+ model_config = ConfigDict(extra="forbid")
1075
+
1076
+ status: str
1077
+ """Health check status: 'healthy' or 'unhealthy'."""
1078
+ error: str | None = None
1079
+ """Error message if status is 'unhealthy', None otherwise."""
1080
+ checked_entity: str | None = None
1081
+ """Entity name used for the health check."""
1082
+ checked_action: str | None = None
1083
+ """Action name used for the health check."""
1084
+
1085
+
1067
1086
  # ===== RESPONSE ENVELOPE MODELS =====
1068
1087
 
1069
1088
  # Type variables for generic envelope models
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: airbyte-agent-shopify
3
- Version: 0.1.16
3
+ Version: 0.1.21
4
4
  Summary: Airbyte Shopify Connector for AI platforms
5
5
  Project-URL: Homepage, https://github.com/airbytehq/airbyte-agent-connectors
6
6
  Project-URL: Documentation, https://docs.airbyte.com/ai-agents/
@@ -119,10 +119,11 @@ async def shopify_execute(entity: str, action: str, params: dict | None = None):
119
119
  return await connector.execute(entity, action, params or {})
120
120
  ```
121
121
 
122
-
123
122
  ## Full documentation
124
123
 
125
- This connector supports the following entities and actions.
124
+ ### Entities and actions
125
+
126
+ This connector supports the following entities and actions. For more details, see this connector's [full reference documentation](REFERENCE.md).
126
127
 
127
128
  | Entity | Actions |
128
129
  |--------|---------|
@@ -160,14 +161,17 @@ This connector supports the following entities and actions.
160
161
  | Fulfillment Orders | [List](./REFERENCE.md#fulfillment-orders-list), [Get](./REFERENCE.md#fulfillment-orders-get) |
161
162
 
162
163
 
163
- For all authentication options, see the connector's [authentication documentation](AUTH.md).
164
+ ### Authentication and configuration
165
+
166
+ For all authentication and configuration options, see the connector's [authentication documentation](AUTH.md).
164
167
 
165
- For detailed documentation on available actions and parameters, see this connector's [full reference documentation](./REFERENCE.md).
168
+ ### Shopify API docs
166
169
 
167
- For the service's official API docs, see the [Shopify API reference](https://shopify.dev/docs/api/admin-rest).
170
+ See the official [Shopify API reference](https://shopify.dev/docs/api/admin-rest).
168
171
 
169
172
  ## Version information
170
173
 
171
- - **Package version:** 0.1.16
174
+ - **Package version:** 0.1.21
172
175
  - **Connector version:** 0.1.2
173
- - **Generated with Connector SDK commit SHA:** 71f48c102ce98c9298e5102761e740f0d97eb71b
176
+ - **Generated with Connector SDK commit SHA:** e4eb233f8dd57ad9bc825064625222a988db2cc6
177
+ - **Changelog:** [View changelog](https://github.com/airbytehq/airbyte-agent-connectors/blob/main/connectors/shopify/CHANGELOG.md)
@@ -1,28 +1,28 @@
1
- airbyte_agent_shopify/__init__.py,sha256=uFn4x1bUldfWTPBITTIGYrjD5bRufgEVvKVviDOUd_0,9661
2
- airbyte_agent_shopify/connector.py,sha256=uDA7DNbgXNQQ94sp2Kinq2Rgu2FgBZEWzbgKTLEteZM,93793
3
- airbyte_agent_shopify/connector_model.py,sha256=AVa7n--wns14y5tdsiKymVUMS7HboqVD8sdzvKPlBRM,691010
4
- airbyte_agent_shopify/models.py,sha256=hBMmLBLBlmqU8TdcJGpm3fQyyDVP3BEpDJ5C2cInBso,60917
1
+ airbyte_agent_shopify/__init__.py,sha256=PwhhDf0vQAlVsyozc8tVdQOSmOfCUvojDtyCCX7kMVo,9711
2
+ airbyte_agent_shopify/connector.py,sha256=Cb-QAQkxfmusiOQrJ-T0H_AnT7EC5DnXrVvu190OVGA,95344
3
+ airbyte_agent_shopify/connector_model.py,sha256=sOJVGigcB608cmTP4pqI1v9kgnRRUS8pbQSrs8NCyhg,691056
4
+ airbyte_agent_shopify/models.py,sha256=OB0rD380IQXbvGPtqbsX0IA3qm47fN6mAIR1nfqwmyk,61514
5
5
  airbyte_agent_shopify/types.py,sha256=AwQ4PR2wZmHNuryriCFdRxf9q48J1mnPwspUB1b-L_o,10221
6
6
  airbyte_agent_shopify/_vendored/__init__.py,sha256=ILl7AHXMui__swyrjxrh9yRa4dLiwBvV6axPWFWty80,38
7
7
  airbyte_agent_shopify/_vendored/connector_sdk/__init__.py,sha256=T5o7roU6NSpH-lCAGZ338sE5dlh4ZU6i6IkeG1zpems,1949
8
8
  airbyte_agent_shopify/_vendored/connector_sdk/auth_strategies.py,sha256=5Sb9moUp623o67Q2wMa8iZldJH08y4gQdoutoO_75Iw,42088
9
9
  airbyte_agent_shopify/_vendored/connector_sdk/auth_template.py,sha256=nju4jqlFC_KI82ILNumNIyiUtRJcy7J94INIZ0QraI4,4454
10
- airbyte_agent_shopify/_vendored/connector_sdk/connector_model_loader.py,sha256=AW9bsdggzuc3ydy2bYYF33L6LxLKLQer9Wm47IOuQw0,41492
10
+ airbyte_agent_shopify/_vendored/connector_sdk/connector_model_loader.py,sha256=ecm0Cdj1SyhDOpEi2wUzzrJNkgt0wViB0Q-YTrDPsjU,41698
11
11
  airbyte_agent_shopify/_vendored/connector_sdk/constants.py,sha256=AtzOvhDMWbRJgpsQNWl5tkogHD6mWgEY668PgRmgtOY,2737
12
12
  airbyte_agent_shopify/_vendored/connector_sdk/exceptions.py,sha256=ss5MGv9eVPmsbLcLWetuu3sDmvturwfo6Pw3M37Oq5k,481
13
13
  airbyte_agent_shopify/_vendored/connector_sdk/extensions.py,sha256=XWRRoJOOrwUHSKbuQt5DU7CCu8ePzhd_HuP7c_uD77w,21376
14
14
  airbyte_agent_shopify/_vendored/connector_sdk/http_client.py,sha256=09Fclbq4wrg38EM2Yh2kHiykQVXqdAGby024elcEz8E,28027
15
- airbyte_agent_shopify/_vendored/connector_sdk/introspection.py,sha256=kRVI4TDQDLdcCnTBUML8ycAtdqAQufVh-027sMkb4i8,19165
15
+ airbyte_agent_shopify/_vendored/connector_sdk/introspection.py,sha256=e9uWn2ofpeehoBbzNgts_bjlKLn8ayA1Y3OpDC3b7ZA,19517
16
16
  airbyte_agent_shopify/_vendored/connector_sdk/secrets.py,sha256=J9ezMu4xNnLW11xY5RCre6DHP7YMKZCqwGJfk7ufHAM,6855
17
- airbyte_agent_shopify/_vendored/connector_sdk/types.py,sha256=in8gHsn5nsScujOfHZmkOgNmqmJKiPyNNjg59m5fGWc,8807
17
+ airbyte_agent_shopify/_vendored/connector_sdk/types.py,sha256=sRZ4rRkJXGfqdjfF3qb0kzrw_tu1cn-CmFSZKMMgF7o,9269
18
18
  airbyte_agent_shopify/_vendored/connector_sdk/utils.py,sha256=G4LUXOC2HzPoND2v4tQW68R9uuPX9NQyCjaGxb7Kpl0,1958
19
- airbyte_agent_shopify/_vendored/connector_sdk/validation.py,sha256=4MPrxYmQh8TbCU0KdvvRKe35Lg1YYLEBd0u4aKySl_E,32122
19
+ airbyte_agent_shopify/_vendored/connector_sdk/validation.py,sha256=2Qof3QiOEEupTsT6F1MvMDCZTPl4IuzkeUUvn_IYFjg,32905
20
20
  airbyte_agent_shopify/_vendored/connector_sdk/cloud_utils/__init__.py,sha256=4799Hv9f2zxDVj1aLyQ8JpTEuFTp_oOZMRz-NZCdBJg,134
21
21
  airbyte_agent_shopify/_vendored/connector_sdk/cloud_utils/client.py,sha256=YxdRpQr9XjDzih6csSseBVGn9kfMtaqbOCXP0TPuzFY,7189
22
22
  airbyte_agent_shopify/_vendored/connector_sdk/executor/__init__.py,sha256=EmG9YQNAjSuYCVB4D5VoLm4qpD1KfeiiOf7bpALj8p8,702
23
- airbyte_agent_shopify/_vendored/connector_sdk/executor/hosted_executor.py,sha256=ydHcG-biRS1ITT5ELwPShdJW-KYpvK--Fos1ipNgHho,6995
24
- airbyte_agent_shopify/_vendored/connector_sdk/executor/local_executor.py,sha256=tVbfstxOrm5qJt1NawTwjhIIpDgPCC4wSrKM5eALPSQ,74064
25
- airbyte_agent_shopify/_vendored/connector_sdk/executor/models.py,sha256=lYVT_bNcw-PoIks4WHNyl2VY-lJVf2FntzINSOBIheE,5845
23
+ airbyte_agent_shopify/_vendored/connector_sdk/executor/hosted_executor.py,sha256=AC5aJtdcMPQfRuam0ZGE4QdhUBu2oGEmNZ6oVQLHTE8,7212
24
+ airbyte_agent_shopify/_vendored/connector_sdk/executor/local_executor.py,sha256=abtQOMZhJBrvE3ioKi-g-R_GZJZozYJNczYySQEEIX8,76981
25
+ airbyte_agent_shopify/_vendored/connector_sdk/executor/models.py,sha256=mUUBnuShKXxVIfsTOhMiI2rn2a-50jJG7SFGKT_P6Jk,6281
26
26
  airbyte_agent_shopify/_vendored/connector_sdk/http/__init__.py,sha256=y8fbzZn-3yV9OxtYz8Dy6FFGI5v6TOqADd1G3xHH3Hw,911
27
27
  airbyte_agent_shopify/_vendored/connector_sdk/http/config.py,sha256=6J7YIIwHC6sRu9i-yKa5XvArwK2KU60rlnmxzDZq3lw,3283
28
28
  airbyte_agent_shopify/_vendored/connector_sdk/http/exceptions.py,sha256=eYdYmxqcwA6pgrSoRXNfR6_nRBGRH6upp2-r1jcKaZo,3586
@@ -46,12 +46,12 @@ airbyte_agent_shopify/_vendored/connector_sdk/schema/base.py,sha256=IoAucZQ0j0xT
46
46
  airbyte_agent_shopify/_vendored/connector_sdk/schema/components.py,sha256=nJIPieavwX3o3ODvdtLHPk84d_V229xmg6LDfwEHjzc,8119
47
47
  airbyte_agent_shopify/_vendored/connector_sdk/schema/connector.py,sha256=mSZk1wr2YSdRj9tTRsPAuIlCzd_xZLw-Bzl1sMwE0rE,3731
48
48
  airbyte_agent_shopify/_vendored/connector_sdk/schema/extensions.py,sha256=5hgpFHK7fzpzegCkJk882DeIP79bCx_qairKJhvPMZ8,9590
49
- airbyte_agent_shopify/_vendored/connector_sdk/schema/operations.py,sha256=RpzGtAI4yvAtMHAfMUMcUwgHv_qJojnKlNb75_agUF8,5729
49
+ airbyte_agent_shopify/_vendored/connector_sdk/schema/operations.py,sha256=St-A75m6sZUZlsoM6WcoPaShYu_X1K19pdyPvJbabOE,6214
50
50
  airbyte_agent_shopify/_vendored/connector_sdk/schema/security.py,sha256=1CVCavrPdHHyk7B6JtUD75yRS_hWLCemZF1zwGbdqxg,9036
51
51
  airbyte_agent_shopify/_vendored/connector_sdk/telemetry/__init__.py,sha256=RaLgkBU4dfxn1LC5Y0Q9rr2PJbrwjxvPgBLmq8_WafE,211
52
52
  airbyte_agent_shopify/_vendored/connector_sdk/telemetry/config.py,sha256=tLmQwAFD0kP1WyBGWBS3ysaudN9H3e-3EopKZi6cGKg,885
53
53
  airbyte_agent_shopify/_vendored/connector_sdk/telemetry/events.py,sha256=8Y1NbXiwISX-V_wRofY7PqcwEXD0dLMnntKkY6XFU2s,1328
54
- airbyte_agent_shopify/_vendored/connector_sdk/telemetry/tracker.py,sha256=Ftrk0_ddfM7dZG8hF9xBuPwhbc9D6JZ7Q9qs5o3LEyA,5579
55
- airbyte_agent_shopify-0.1.16.dist-info/METADATA,sha256=vzGjdAedaMX_-w0h9_jQ-v5AUi21PZgAwyFf1OIAvYI,7842
56
- airbyte_agent_shopify-0.1.16.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
57
- airbyte_agent_shopify-0.1.16.dist-info/RECORD,,
54
+ airbyte_agent_shopify/_vendored/connector_sdk/telemetry/tracker.py,sha256=SginFQbHqVUVYG82NnNzG34O-tAQ_wZYjGDcuo0q4Kk,5584
55
+ airbyte_agent_shopify-0.1.21.dist-info/METADATA,sha256=fTADX3J6fivQ9s2kLhgiuraAgiMkafFJA9E6sKVUabY,7999
56
+ airbyte_agent_shopify-0.1.21.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
57
+ airbyte_agent_shopify-0.1.21.dist-info/RECORD,,