# Dynamic bearer token refresh for CData Sync API connector with bearer token authentication

**URL:** <https://community.cdata.com/t/dynamic-bearer-token-refresh-for-cdata-sync-api-connector-with-bearer-token-authentication/1270>\
**Category:** CData Sync\
**Tags:** question, api, cdata-sync, bearertoken\
**Created:** [February 20, 2026, 5:39pm UTC](https://community.cdata.com/t/dynamic-bearer-token-refresh-for-cdata-sync-api-connector-with-bearer-token-authentication/1270 "2026-02-20T17:39:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![CJIW](https://avatars.discourse-cdn.com/v4/letter/c/e56c9b/32.png) [@CJIW](https://community.cdata.com/u/CJIW)\
**Post date:** [February 20, 2026, 5:39pm UTC](https://community.cdata.com/t/dynamic-bearer-token-refresh-for-cdata-sync-api-connector-with-bearer-token-authentication/1270/1 "2026-02-20T17:39:47Z")

</div>

In CData Sync API connector with Bearer token authentication, currently it’s not possible to provide and configure an endpoint from which a new token can be acquired. What are the other possible ways then to update the token dynamically then?

[This thread](https://community.cdata.com/cdata-arc-48/dynamic-bearer-token-authorization-in-the-rest-connector-220?tid=220&fid=48)&nbsp;discusses a solution in CData Arc but I am not sure if that will be applicable here in CData Sync.

This [another thread](https://community.cdata.com/data-sources-91/using-bearer-token-authentication-with-a-manual-token-411?tid=411&fid=91) discusses adding a manual bearer token in custom header for CData Sync, but how can the token value be updated dynamically?

Is it possible to acquire the token in the Pre-Job event and then set it as an environment variable? Are environment variables (set up in the Pre-Job event) accessible in the Connection configuration?
