✨Source Square: Add new stream Cash Drawers (#31065)
Co-authored-by: Mal Hancock <mallory@archangelic.space>
This commit is contained in:
@@ -34,5 +34,5 @@ COPY source_square ./source_square
|
||||
ENV AIRBYTE_ENTRYPOINT "python /airbyte/integration_code/main.py"
|
||||
ENTRYPOINT ["python", "/airbyte/integration_code/main.py"]
|
||||
|
||||
LABEL io.airbyte.version=1.1.3
|
||||
LABEL io.airbyte.version=1.2.0
|
||||
LABEL io.airbyte.name=airbyte/source-square
|
||||
|
||||
@@ -34,6 +34,8 @@ acceptance_tests:
|
||||
bypass_reason: "Not able to fill stream"
|
||||
- name: refunds
|
||||
bypass_reason: "Not able to fill stream"
|
||||
- name: cash_drawers
|
||||
bypass_reason: "Not able to fill stream"
|
||||
expect_records:
|
||||
path: "integration_tests/expected_records_oauth.jsonl"
|
||||
ignored_fields:
|
||||
|
||||
@@ -155,6 +155,18 @@
|
||||
"sync_mode": "incremental",
|
||||
"cursor_field": ["updated_at"],
|
||||
"destination_sync_mode": "overwrite"
|
||||
},
|
||||
{
|
||||
"stream": {
|
||||
"name": "cash_drawers",
|
||||
"json_schema": {},
|
||||
"supported_sync_modes": ["full_refresh"],
|
||||
"source_defined_cursor": true,
|
||||
"default_cursor_field": ["id"]
|
||||
},
|
||||
"sync_mode": "full_refresh",
|
||||
"cursor_field": ["id"],
|
||||
"destination_sync_mode": "overwrite"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@ data:
|
||||
connectorSubtype: api
|
||||
connectorType: source
|
||||
definitionId: 77225a51-cd15-4a13-af02-65816bd0ecf4
|
||||
dockerImageTag: 1.1.3
|
||||
dockerImageTag: 1.2.0
|
||||
dockerRepository: airbyte/source-square
|
||||
documentationUrl: https://docs.airbyte.com/integrations/sources/square
|
||||
githubIssueLabel: source-square
|
||||
|
||||
@@ -207,6 +207,32 @@ definitions:
|
||||
primary_key: "id"
|
||||
path: "/locations"
|
||||
|
||||
locations_partition_router:
|
||||
type: SubstreamPartitionRouter
|
||||
parent_stream_configs:
|
||||
- stream: "#/definitions/locations_stream"
|
||||
parent_key: "id"
|
||||
partition_field: "location_id"
|
||||
|
||||
cash_drawers_stream:
|
||||
$ref: "#/definitions/base_stream"
|
||||
$parameters:
|
||||
name: "cash_drawers"
|
||||
primary_key: "id"
|
||||
path: "/cash-drawers/shifts"
|
||||
retriever:
|
||||
$ref: "#/definitions/retriever"
|
||||
partition_router:
|
||||
$ref: "#/definitions/locations_partition_router"
|
||||
requester:
|
||||
$ref: "#/definitions/requester"
|
||||
request_parameters:
|
||||
location_id: "{{ stream_partition.location_id }}"
|
||||
record_selector:
|
||||
$ref: "#/definitions/selector"
|
||||
extractor:
|
||||
field_path: ["cash_drawer_shifts"]
|
||||
|
||||
categories_stream:
|
||||
$ref: "#/definitions/base_catalog_objects_stream"
|
||||
$parameters:
|
||||
@@ -303,6 +329,7 @@ streams:
|
||||
- "#/definitions/refunds_stream"
|
||||
- "#/definitions/payments_stream"
|
||||
- "#/definitions/orders_stream"
|
||||
- "#/definitions/cash_drawers_stream"
|
||||
|
||||
check:
|
||||
stream_names:
|
||||
|
||||
@@ -0,0 +1,59 @@
|
||||
{
|
||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
||||
"title": "Cash Drawer Shifts Schema",
|
||||
"additionalProperties": true,
|
||||
"type": ["object", "null"],
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": ["string", "null"]
|
||||
},
|
||||
"state": {
|
||||
"type": ["string", "null"]
|
||||
},
|
||||
"opened_at": {
|
||||
"type": ["string", "null"]
|
||||
},
|
||||
"ended_at": {
|
||||
"type": ["string", "null"]
|
||||
},
|
||||
"closed_at": {
|
||||
"type": ["string", "null"]
|
||||
},
|
||||
"description": {
|
||||
"type": ["string", "null"]
|
||||
},
|
||||
"opened_cash_money": {
|
||||
"type": ["object", "null"],
|
||||
"properties": {
|
||||
"amount": {
|
||||
"type": ["number", "null"]
|
||||
},
|
||||
"currency": {
|
||||
"type": ["string", "null"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"expected_cash_money": {
|
||||
"type": ["object", "null"],
|
||||
"properties": {
|
||||
"amount": {
|
||||
"type": ["number", "null"]
|
||||
},
|
||||
"currency": {
|
||||
"type": ["string", "null"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"closed_cash_money": {
|
||||
"type": ["object", "null"],
|
||||
"properties": {
|
||||
"amount": {
|
||||
"type": ["number", "null"]
|
||||
},
|
||||
"currency": {
|
||||
"type": ["string", "null"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user