Skip to content

Commit

Permalink
final details
Browse files Browse the repository at this point in the history
  • Loading branch information
shibeshduw committed Aug 12, 2024
1 parent 18a9087 commit a5aec82
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docs-js/features/connectivity/destination.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -255,8 +255,8 @@ const destination = getDestinationFromServiceBinding({

:::info Creating destinations from service bindings

The SAP Cloud SDK provides the `getServiceBinding` function to retrieve the first service binding from `VCAP_SERVICES` for a given service type.
It also provides a convenience function `transformServiceBindingToDestination` that simplifies the process of transforming a service binding to a destination.
The SAP Cloud SDK provides the `getServiceBinding()` function to retrieve the first service binding from `VCAP_SERVICES` for a given service type.
It also provides the `transformServiceBindingToDestination()` function to transform known service bindings to destinations.

<details>
<summary>Example Usage</summary>
Expand All @@ -274,10 +274,10 @@ await transformServiceBindingToDestination(service);

</details>

`transformServiceBindingToDestination` supports the [default service types](#service-binding-environment-variables) as listed above.
`transformServiceBindingToDestination()` supports the [default service types](#service-binding-environment-variables) as listed above.

The created destinations will consistently include the token obtained through the `OAuth2ClientCredentials` flow for all service types, except for `s4-hana-cloud`.
If the provided service binding is not supported, an error will be thrown indicating the unsupported service type.
The transformation includes auth token flows for destinations with type `OAuth2ClientCredentials` and adds retrieved tokens to the destination.
If the provided service binding is not supported, an error is thrown.

:::

Expand Down

0 comments on commit a5aec82

Please sign in to comment.