You need to provide “source_oidc_credentials” and “destination_oidc_credentials” run your transformation via API/SDK
Below is the code sample how to use OIDC credentials in your transformations
transformations = t
Transformation(
external_id="<external_id>",
name="<name>",
query="<Query>",
destination=TransformationDestination.raw("<Database>", "<Table>"),
conflict_mode="<upsert>",
source_oidc_credentials=OidcCredentials(
client_id="<CLIENT_ID>",
client_secret="<CLIENT_SECRET>",
scopes=f"<scopes>",
token_uri=<"TOKEN_URL">,
cdf_project_name=<"COGNITE_PROJECT">
),
destination_oidc_credentials=OidcCredentials(
client_id="<CLIENT_ID>",
client_secret="<CLIENT_SECRET>",
scopes=f"<scopes>",
token_uri=<"TOKEN_URL">,
cdf_project_name=<"COGNITE_PROJECT">
),
),
]
Scopes and token_uri: The Scopes and token_uri can be taken from the
following location in Fusion:
- Navigate to Transformations (Integrate Transform data)
- Click on “New Transformations”
- Click on “Schedule and Run”
- Click on “Use OIDC” in “Read credentials”
- Click on “Set read OIDC credentials”