Skip to content

Commit 2f11bfa

Browse files
lmossmanOleksandr Bazarnov
andauthored
chore: fix more fields in declarative_component_schema (#525)
Co-authored-by: Oleksandr Bazarnov <[email protected]>
1 parent 99327c2 commit 2f11bfa

File tree

2 files changed

+97
-94
lines changed

2 files changed

+97
-94
lines changed

airbyte_cdk/sources/declarative/declarative_component_schema.yaml

Lines changed: 62 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,8 @@ definitions:
299299
- "$ref": "#/definitions/CustomAuthenticator"
300300
- "$ref": "#/definitions/OAuthAuthenticator"
301301
- "$ref": "#/definitions/JwtAuthenticator"
302-
- "$ref": "#/definitions/NoAuth"
303302
- "$ref": "#/definitions/SessionTokenAuthenticator"
303+
- "$ref": "#/definitions/NoAuth"
304304
- "$ref": "#/definitions/LegacySessionTokenAuthenticator"
305305
examples:
306306
- authenticators:
@@ -1417,7 +1417,6 @@ definitions:
14171417
- "$ref": "#/definitions/CustomIncrementalSync"
14181418
primary_key:
14191419
title: Primary Key
1420-
description: The primary key of the stream.
14211420
"$ref": "#/definitions/PrimaryKey"
14221421
default: ""
14231422
schema_loader:
@@ -1468,18 +1467,18 @@ definitions:
14681467
requester:
14691468
description: Requester component that describes how to prepare HTTP requests to send to the source API.
14701469
anyOf:
1471-
- "$ref": "#/definitions/CustomRequester"
14721470
- "$ref": "#/definitions/HttpRequester"
1471+
- "$ref": "#/definitions/CustomRequester"
14731472
download_target_extractor:
14741473
description: Responsible for fetching the url where the file is located. This is applied on each records and not on the HTTP response
14751474
anyOf:
1476-
- "$ref": "#/definitions/CustomRecordExtractor"
14771475
- "$ref": "#/definitions/DpathExtractor"
1476+
- "$ref": "#/definitions/CustomRecordExtractor"
14781477
file_extractor:
14791478
description: Responsible for fetching the content of the file. If not defined, the assumption is that the whole response body is the file content
14801479
anyOf:
1481-
- "$ref": "#/definitions/CustomRecordExtractor"
14821480
- "$ref": "#/definitions/DpathExtractor"
1481+
- "$ref": "#/definitions/CustomRecordExtractor"
14831482
filename_extractor:
14841483
description: Defines the name to store the file. Stream name is automatically added to the file path. File unique ID can be used to avoid overwriting files. Random UUID will be used if the extractor is not provided.
14851484
type: string
@@ -1919,7 +1918,7 @@ definitions:
19191918
deprecated: true
19201919
deprecation_message: "Use `url` field instead."
19211920
title: API Base URL
1922-
description: Deprecated, use the `url` instead. Base URL of the API source. Do not put sensitive information (e.g. API tokens) into this field - Use the Authentication component for this.
1921+
description: Deprecated, use the `url` instead. Base URL of the API source. Do not put sensitive information (e.g. API tokens) into this field - Use the Authenticator component for this.
19231922
linkable: true
19241923
type: string
19251924
interpolation_context:
@@ -1937,8 +1936,8 @@ definitions:
19371936
- "https://connect.squareup.com/v2/quotes/{{ stream_partition['id'] }}/quote_line_groups"
19381937
- "https://example.com/api/v1/resource/{{ next_page_token['id'] }}"
19391938
url:
1940-
title: The URL of an API endpoint
1941-
description: The URL of the API source. Do not put sensitive information (e.g. API tokens) into this field - Use the Authentication component for this.
1939+
title: API Endpoint URL
1940+
description: The URL of the source API endpoint. Do not put sensitive information (e.g. API tokens) into this field - Use the Authenticator component for this.
19421941
type: string
19431942
interpolation_context:
19441943
- config
@@ -1958,7 +1957,7 @@ definitions:
19581957
deprecated: true
19591958
deprecation_message: "Use `url` field instead."
19601959
title: URL Path
1961-
description: Deprecated, use the `url` instead. Path the specific API endpoint that this stream represents. Do not put sensitive information (e.g. API tokens) into this field - Use the Authentication component for this.
1960+
description: Deprecated, use the `url` instead. Path the specific API endpoint that this stream represents. Do not put sensitive information (e.g. API tokens) into this field - Use the Authenticator component for this.
19621961
type: string
19631962
interpolation_context:
19641963
- config
@@ -1989,7 +1988,6 @@ definitions:
19891988
linkable: true
19901989
description: Authentication method to use for requests sent to the API.
19911990
anyOf:
1992-
- "$ref": "#/definitions/NoAuth"
19931991
- "$ref": "#/definitions/ApiKeyAuthenticator"
19941992
- "$ref": "#/definitions/BasicHttpAuthenticator"
19951993
- "$ref": "#/definitions/BearerAuthenticator"
@@ -1998,11 +1996,52 @@ definitions:
19981996
- "$ref": "#/definitions/SessionTokenAuthenticator"
19991997
- "$ref": "#/definitions/SelectiveAuthenticator"
20001998
- "$ref": "#/definitions/CustomAuthenticator"
1999+
- "$ref": "#/definitions/NoAuth"
20012000
- "$ref": "#/definitions/LegacySessionTokenAuthenticator"
20022001
fetch_properties_from_endpoint:
20032002
title: Fetch Properties from Endpoint
20042003
description: Allows for retrieving a dynamic set of properties from an API endpoint which can be injected into outbound request using the stream_partition.extra_fields.
20052004
"$ref": "#/definitions/PropertiesFromEndpoint"
2005+
request_parameters:
2006+
title: Query Parameters
2007+
description: Specifies the query parameters that should be set on an outgoing HTTP request given the inputs.
2008+
anyOf:
2009+
- type: object
2010+
title: Key/Value Pairs
2011+
additionalProperties:
2012+
anyOf:
2013+
- type: string
2014+
- $ref: "#/definitions/QueryProperties"
2015+
- type: string
2016+
title: Interpolated Value
2017+
interpolation_context:
2018+
- next_page_token
2019+
- stream_interval
2020+
- stream_partition
2021+
- stream_slice
2022+
examples:
2023+
- unit: "day"
2024+
- query: 'last_event_time BETWEEN TIMESTAMP "{{ stream_interval.start_time }}" AND TIMESTAMP "{{ stream_interval.end_time }}"'
2025+
- searchIn: "{{ ','.join(config.get('search_in', [])) }}"
2026+
- sort_by[asc]: updated_at
2027+
request_headers:
2028+
title: Request Headers
2029+
description: Return any non-auth headers. Authentication headers will overwrite any overlapping headers returned from this method.
2030+
anyOf:
2031+
- type: object
2032+
title: Key/Value Pairs
2033+
additionalProperties:
2034+
type: string
2035+
- type: string
2036+
title: Interpolated Value
2037+
interpolation_context:
2038+
- next_page_token
2039+
- stream_interval
2040+
- stream_partition
2041+
- stream_slice
2042+
examples:
2043+
- Output-Format: JSON
2044+
- Version: "{{ config['version'] }}"
20062045
request_body_data:
20072046
deprecated: true
20082047
deprecation_message: "Use `request_body` field instead."
@@ -2045,7 +2084,7 @@ definitions:
20452084
field: "updated_at"
20462085
order: "ascending"
20472086
request_body:
2048-
title: Request Body Payload to be send as a part of the API request.
2087+
title: Request Body
20492088
description: Specifies how to populate the body of the request with a payload. Can contain nested objects.
20502089
anyOf:
20512090
- "$ref": "#/definitions/RequestBodyPlainText"
@@ -2081,46 +2120,6 @@ definitions:
20812120
query:
20822121
param1: "value1"
20832122
param2: "{{ config['param2_value'] }}"
2084-
request_headers:
2085-
title: Request Headers
2086-
description: Return any non-auth headers. Authentication headers will overwrite any overlapping headers returned from this method.
2087-
anyOf:
2088-
- type: object
2089-
title: Key/Value Pairs
2090-
additionalProperties:
2091-
type: string
2092-
- type: string
2093-
title: Interpolated Value
2094-
interpolation_context:
2095-
- next_page_token
2096-
- stream_interval
2097-
- stream_partition
2098-
- stream_slice
2099-
examples:
2100-
- Output-Format: JSON
2101-
- Version: "{{ config['version'] }}"
2102-
request_parameters:
2103-
title: Query Parameters
2104-
description: Specifies the query parameters that should be set on an outgoing HTTP request given the inputs.
2105-
anyOf:
2106-
- type: object
2107-
title: Key/Value Pairs
2108-
additionalProperties:
2109-
anyOf:
2110-
- type: string
2111-
- $ref: "#/definitions/QueryProperties"
2112-
- type: string
2113-
title: Interpolated Value
2114-
interpolation_context:
2115-
- next_page_token
2116-
- stream_interval
2117-
- stream_partition
2118-
- stream_slice
2119-
examples:
2120-
- unit: "day"
2121-
- query: 'last_event_time BETWEEN TIMESTAMP "{{ stream_interval.start_time }}" AND TIMESTAMP "{{ stream_interval.end_time }}"'
2122-
- searchIn: "{{ ','.join(config.get('search_in', [])) }}"
2123-
- sort_by[asc]: updated_at
21242123
error_handler:
21252124
title: Error Handler
21262125
description: Error handler component that defines how to handle errors.
@@ -3100,7 +3099,7 @@ definitions:
31003099
type: array
31013100
default: []
31023101
items:
3103-
- type: string
3102+
type: string
31043103
interpolation_context:
31053104
- config
31063105
parent_key:
@@ -3155,14 +3154,19 @@ definitions:
31553154
anyOf:
31563155
- type: string
31573156
title: Single Key
3157+
description: The single top-level field to use as the primary key.
31583158
- type: array
31593159
title: Composite Key
3160+
description: An array of top-level fields representing a composite primary key.
31603161
items:
31613162
type: string
31623163
- type: array
31633164
title: Composite Key of Nested Fields
3165+
description: An array of arrays representing a composite primary key where the fields are nested fields.
31643166
items:
31653167
type: array
3168+
title: Nested Field Path
3169+
description: Path to the nested field in the record.
31663170
items:
31673171
type: string
31683172
default: ""
@@ -3194,8 +3198,8 @@ definitions:
31943198
retriever:
31953199
description: Requester component that describes how to fetch the properties to query from a remote API endpoint.
31963200
anyOf:
3197-
- "$ref": "#/definitions/CustomRetriever"
31983201
- "$ref": "#/definitions/SimpleRetriever"
3202+
- "$ref": "#/definitions/CustomRetriever"
31993203
$parameters:
32003204
type: object
32013205
additionalProperties: true
@@ -3426,6 +3430,7 @@ definitions:
34263430
additionalProperties: true
34273431
LegacySessionTokenAuthenticator:
34283432
title: Session Token Authenticator
3433+
deprecated: true
34293434
description: Deprecated - use SessionTokenAuthenticator instead. Authenticator for requests authenticated using session tokens. A session token is a random value generated by a server to identify a specific user for the duration of one interaction session.
34303435
type: object
34313436
required:
@@ -3534,15 +3539,15 @@ definitions:
35343539
- "$ref": "#/definitions/HttpRequester"
35353540
- "$ref": "#/definitions/CustomRequester"
35363541
decoder:
3537-
title: Decoder
3542+
title: HTTP Response Format
35383543
description: Component decoding the response so records can be extracted.
35393544
anyOf:
3540-
- "$ref": "#/definitions/CsvDecoder"
3541-
- "$ref": "#/definitions/GzipDecoder"
35423545
- "$ref": "#/definitions/JsonDecoder"
3546+
- "$ref": "#/definitions/XmlDecoder"
3547+
- "$ref": "#/definitions/CsvDecoder"
35433548
- "$ref": "#/definitions/JsonlDecoder"
3549+
- "$ref": "#/definitions/GzipDecoder"
35443550
- "$ref": "#/definitions/IterableDecoder"
3545-
- "$ref": "#/definitions/XmlDecoder"
35463551
- "$ref": "#/definitions/ZipfileDecoder"
35473552
- "$ref": "#/definitions/CustomDecoder"
35483553
record_selector:

0 commit comments

Comments
 (0)