Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions odata_api/odata_version_2_using_pyodata/configuration.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
10 changes: 8 additions & 2 deletions odata_api/odata_version_2_using_pyodata/connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
# See the Technical Reference documentation (https://fivetran.com/docs/connectors/connector-sdk/technical-reference#update)
# and the Best Practices documentation (https://fivetran.com/docs/connectors/connector-sdk/best-practices) for details

# Import json for reading configuration file
import json

# Import required classes from fivetran_connector_sdk.
# For supporting Connector operations like Update() and Schema()
from fivetran_connector_sdk import Connector
Expand Down Expand Up @@ -310,5 +313,8 @@ def update(configuration: dict, state: dict):
# This is useful for debugging while you write your code. Note this method is not called by Fivetran when executing your connector in production.
# Please test using the Fivetran debug command prior to finalizing and deploying your connector.
if __name__ == "__main__":
# Adding this code to your `connector.py` allows you to test your connector by running your file directly from your IDE:
connector.debug()
# Open the configuration.json file and load its contents into a dictionary.
with open("configuration.json", "r") as f:
configuration = json.load(f)
# Adding this code to your `connector.py` allows you to test your connector by running your file directly from your IDE.
connector.debug(configuration=configuration)
1 change: 1 addition & 0 deletions odata_api/odata_version_4/configuration.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
10 changes: 8 additions & 2 deletions odata_api/odata_version_4/connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
# See the Technical Reference documentation (https://fivetran.com/docs/connectors/connector-sdk/technical-reference#update)
# and the Best Practices documentation (https://fivetran.com/docs/connectors/connector-sdk/best-practices) for details

# Import json for reading configuration file
import json

# Import required classes from fivetran_connector_sdk.
# For supporting Connector operations like Update() and Schema()
from fivetran_connector_sdk import Connector
Expand Down Expand Up @@ -345,5 +348,8 @@ def update(configuration: dict, state: dict):
# This is useful for debugging while you write your code. Note this method is not called by Fivetran when executing your connector in production.
# Please test using the Fivetran debug command prior to finalizing and deploying your connector.
if __name__ == "__main__":
# Adding this code to your `connector.py` allows you to test your connector by running your file directly from your IDE:
connector.debug()
# Open the configuration.json file and load its contents into a dictionary.
with open("configuration.json", "r") as f:
configuration = json.load(f)
# Adding this code to your `connector.py` allows you to test your connector by running your file directly from your IDE.
connector.debug(configuration=configuration)
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
10 changes: 8 additions & 2 deletions odata_api/odata_version_4_using_python_odata/connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
# See the Technical Reference documentation (https://fivetran.com/docs/connectors/connector-sdk/technical-reference#update)
# and the Best Practices documentation (https://fivetran.com/docs/connectors/connector-sdk/best-practices) for details

# Import json for reading configuration file
import json

# Import required classes from fivetran_connector_sdk.
# For supporting Connector operations like Update() and Schema()
from fivetran_connector_sdk import Connector
Expand Down Expand Up @@ -237,5 +240,8 @@ def update(configuration: dict, state: dict):
# This is useful for debugging while you write your code. Note this method is not called by Fivetran when executing your connector in production.
# Please test using the Fivetran debug command prior to finalizing and deploying your connector.
if __name__ == "__main__":
# Adding this code to your `connector.py` allows you to test your connector by running your file directly from your IDE:
connector.debug()
# Open the configuration.json file and load its contents into a dictionary.
with open("configuration.json", "r") as f:
configuration = json.load(f)
# Adding this code to your `connector.py` allows you to test your connector by running your file directly from your IDE.
connector.debug(configuration=configuration)
1 change: 1 addition & 0 deletions owasp_api_vulns/configuration.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
2 changes: 1 addition & 1 deletion owasp_api_vulns/connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -768,5 +768,5 @@ def update(configuration: dict, state: dict):
# Open the configuration.json file and load its contents into a dictionary.
with open("configuration.json", "r") as f:
configuration = json.load(f)
# Test the connector locally
# Adding this code to your `connector.py` allows you to test your connector by running your file directly from your IDE.
connector.debug(configuration=configuration)